ele-config.js 7.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302
  1. import $config from '@client/config'
  2. export default [{
  3. title: '常用组件',
  4. components: [{
  5. elName: 'Ds-text',
  6. title: '文字',
  7. img: require('@/common/images/elementIcon/text.png'),
  8. // 每个组件设置props来展示哪些显示哪些编辑项
  9. valueType: '', // 标识数据类型,用于表单组件
  10. defaultStyle: {
  11. height: 40
  12. }
  13. },
  14. {
  15. elName: 'Ds-image',
  16. title: '图片',
  17. img: require('@/common/images/elementIcon/image.png'),
  18. valueType: '',
  19. defaultStyle: {
  20. width: 375,
  21. height: 200
  22. }
  23. },
  24. {
  25. elName: 'Ds-banner',
  26. title: 'Banner',
  27. img: require('@/common/images/elementIcon/banner.png'),
  28. valueType: '',
  29. defaultStyle: {
  30. height: 160
  31. }
  32. },
  33. // {
  34. // elName: 'Ds-avatar',
  35. // title: '随机头像',
  36. // img: require('@/common/images/elementIcon/avatar.png'),
  37. // valueType: '',
  38. // defaultStyle: {
  39. // width: 150,
  40. // height: 50
  41. // }
  42. // },
  43. {
  44. elName: 'Ds-button',
  45. title: '按钮',
  46. img: require('@/common/images/elementIcon/button.png'),
  47. // 每个组件设置props来展示哪些显示哪些编辑项
  48. valueType: '', // 标识数据类型,用于表单组件
  49. defaultStyle: {
  50. width: 150,
  51. height: 50,
  52. }
  53. },
  54. {
  55. elName: 'Ds-image-carousel',
  56. title: '图片轮播',
  57. img: require('@/common/images/elementIcon/carousel.png'),
  58. valueType: '', // 标识数据类型,用于表单组件,
  59. defaultStyle: {
  60. height: 140
  61. }
  62. },
  63. {
  64. elName: 'Ds-notice',
  65. title: '通知栏',
  66. img: require('@/common/images/elementIcon/notice.png'),
  67. valueType: '',
  68. defaultStyle: {
  69. height: 40,
  70. width: $config.canvasH5Width,
  71. }
  72. },
  73. // {
  74. // elName: 'Ds-tabars',
  75. // title: '页面导航',
  76. // img: require('@/common/images/elementIcon/tabars.png'),
  77. // valueType: '',
  78. // defaultStyle: {
  79. // height: 50,
  80. // width: $config.canvasH5Width,
  81. // }
  82. // },
  83. ]
  84. },
  85. {
  86. title: '基础组件',
  87. components: [{
  88. elName: 'Ds-rectangle-border',
  89. title: '矩形边框',
  90. img: require('@/common/images/elementIcon/border.png'),
  91. valueType: '',
  92. defaultStyle: {
  93. width: 120,
  94. height: 100,
  95. borderColor: "#999999",
  96. borderStyle: 'solid',
  97. borderWidth: 2
  98. }
  99. }, {
  100. elName: 'Ds-circle-border',
  101. title: '圆形边框',
  102. img: require('@/common/images/elementIcon/circle-border.png'),
  103. valueType: '',
  104. defaultStyle: {
  105. width: 100,
  106. height: 100,
  107. borderColor: "#999999",
  108. borderStyle: 'solid',
  109. borderWidth: 2,
  110. borderRadius: $config.canvasH5Width
  111. }
  112. },
  113. {
  114. elName: 'Ds-rectangle-border',
  115. title: '分割线',
  116. img: require('@/common/images/elementIcon/splitLine.png'),
  117. valueType: '',
  118. defaultStyle: {
  119. height: 1,
  120. width: 300,
  121. backgroundColor: '#999999'
  122. }
  123. },
  124. {
  125. elName: 'Ds-iframe',
  126. title: '内嵌iframe',
  127. img: require('@/common/images/elementIcon/iframe.png'),
  128. valueType: '',
  129. defaultStyle: {
  130. width: $config.canvasH5Width,
  131. height: 300,
  132. paddingTop: 10,
  133. paddingBottom: 10,
  134. scrolling: 'no'
  135. }
  136. }
  137. ]
  138. },
  139. // {
  140. // title: '表单组件',
  141. // components: [{
  142. // elName: 'Ds-input',
  143. // title: '文本框',
  144. // img: require('@/common/images/elementIcon/form.png'),
  145. // valueType: 'input',
  146. // defaultStyle: {
  147. // height: 52,
  148. // width: $config.canvasH5Width,
  149. // }
  150. // },
  151. // {
  152. // elName: 'Ds-radio',
  153. // title: '单选框',
  154. // img: require('@/common/images/elementIcon/radio.jpg'),
  155. // valueType: 'radio',
  156. //
  157. // defaultStyle: {
  158. // height: 52,
  159. // width: $config.canvasH5Width,
  160. // }
  161. // },
  162. // {
  163. // elName: 'Ds-checkbox',
  164. // title: '复选框',
  165. // img: require('@/common/images/elementIcon/checkbox.jpg'),
  166. // valueType: 'checkbox',
  167. // defaultStyle: {
  168. // height: 30,
  169. // width: $config.canvasH5Width,
  170. // }
  171. // },
  172. // {
  173. // elName: 'Ds-rate',
  174. // title: '评分',
  175. // img: require('@/common/images/elementIcon/rate.jpg'),
  176. // defaultStyle: {
  177. // height: 30,
  178. // width: $config.canvasH5Width / 2,
  179. // }
  180. // },
  181. // {
  182. // elName: 'Ds-stepper',
  183. // title: '步进器',
  184. // img: require('@/common/images/elementIcon/stepper.jpg'),
  185. // defaultStyle: {
  186. // height: 30,
  187. // width: $config.canvasH5Width / 2,
  188. // }
  189. // },
  190. // {
  191. // elName: 'Ds-switch',
  192. // title: '开关',
  193. // img: require('@/common/images/elementIcon/Switch.jpg'),
  194. // defaultStyle: {
  195. // height: 52,
  196. // width: $config.canvasH5Width,
  197. // }
  198. // }
  199. // ]
  200. // },
  201. {
  202. title: '功能组件',
  203. components: [{
  204. elName: 'Ds-qrcode',
  205. title: '二维码',
  206. img: require('@/common/images/elementIcon/qcode.png'),
  207. valueType: '',
  208. defaultStyle: {
  209. width: 120,
  210. height: 120,
  211. }
  212. }, {
  213. elName: 'Ds-bg-music',
  214. title: '音乐',
  215. img: require('@/common/images/elementIcon/music.png'),
  216. valueType: '',
  217. defaultStyle: {
  218. height: 52,
  219. width: 52,
  220. }
  221. },
  222. {
  223. elName: 'Ds-video',
  224. title: '视频',
  225. img: require('@/common/images/elementIcon/video.png'),
  226. valueType: '',
  227. defaultStyle: {
  228. width: $config.canvasH5Width,
  229. height: 200,
  230. }
  231. }, {
  232. elName: 'Ds-map',
  233. title: '地图',
  234. img: require('@/common/images/elementIcon/map.png'),
  235. valueType: '',
  236. defaultStyle: {
  237. width: $config.canvasH5Width,
  238. height: 200,
  239. }
  240. },
  241. ]
  242. },
  243. // {
  244. // title: '图表组件',
  245. // components: [{
  246. // elName: 'Ds-linechart',
  247. // title: '折线图',
  248. // img: require('@/common/images/elementIcon/lineCharts.jpg'),
  249. // valueType: '',
  250. // defaultStyle: {
  251. // width: $config.canvasH5Width,
  252. // height: 350,
  253. // }
  254. // },
  255. // {
  256. // elName: 'Ds-piechart',
  257. // title: '饼图',
  258. // img: require('@/common/images/elementIcon/pieCharts.jpg'),
  259. // valueType: '',
  260. // defaultStyle: {
  261. // width: $config.canvasH5Width,
  262. // height: 350,
  263. // }
  264. // }, {
  265. // elName: 'Ds-wordcloud',
  266. // title: '词云',
  267. // img: require('@/common/images/elementIcon/wordcloud.jpg'),
  268. // valueType: '',
  269. // defaultStyle: {
  270. // width: $config.canvasH5Width,
  271. // height: 370,
  272. // }
  273. // }, {
  274. // elName: 'Ds-funnel',
  275. // title: '漏斗图',
  276. // img: require('@/common/images/elementIcon/funnel.jpg'),
  277. // valueType: '',
  278. // defaultStyle: {
  279. // width: $config.canvasH5Width,
  280. // height: 370,
  281. // }
  282. // }
  283. // ]
  284. // },
  285. {
  286. title: '业务组件',
  287. components: [
  288. {
  289. elName: 'Ds-source-form',
  290. title: '留资表单',
  291. img: require('@/common/images/elementIcon/form.png'),
  292. valueType: 'input',
  293. defaultStyle: {
  294. height: 590,
  295. width: $config.canvasH5Width,
  296. }
  297. },
  298. ]
  299. }
  300. ]