index.js 623 B

1234567891011121314151617181920212223242526272829303132333435
  1. Component({
  2. externalClasses: ['l-class','l-class-self',],
  3. options: {
  4. addGlobalClass: true,
  5. },
  6. properties: {
  7. name: {
  8. type: String,
  9. value: ''
  10. },
  11. color: {
  12. type: String,
  13. value: '',
  14. },
  15. size: {
  16. type: String,
  17. value: '',
  18. },
  19. },
  20. data:{
  21. default:{
  22. size:40,
  23. color:'#45526B',
  24. },
  25. },
  26. ready:function(){
  27. if(!this.data.name) {
  28. console.error('请传入Icon组件的name属性');
  29. }
  30. },
  31. methods: {
  32. }
  33. });