Commit 2f1132b470bd1678f8c08590087124e5818e9fe3

Authored by ly525
1 parent d9fd3464

update plugin list style

front-end/h5/src/components/core/editor/shortcuts-panel/index.js
... ... @@ -93,6 +93,7 @@ export default {
93 93 clickFn={this.onClickShortcut.bind(this, plugin)}
94 94 title={plugin.title}
95 95 faIcon={plugin.icon}
  96 + disabled={plugin.disabled}
96 97 />
97 98 </a-col>
98 99 ))
... ...
front-end/h5/src/components/core/editor/shortcuts-panel/shortcut-button.js
... ... @@ -12,6 +12,10 @@ export default {
12 12 clickFn: {
13 13 required: false,
14 14 type: Function
  15 + },
  16 + disabled: {
  17 + type: Boolean,
  18 + default: false
15 19 }
16 20 },
17 21 render: (h, { props, listeners, slots }) => {
... ... @@ -20,6 +24,7 @@ export default {
20 24 <a-button
21 25 class="shortcut-button"
22 26 onClick={onClick}
  27 + disabled={props.disabled}
23 28 >
24 29 <i
25 30 class={['shortcut-icon', 'fa', `fa-${props.faIcon}`]}
... ...
front-end/h5/src/components/core/styles/index.scss
... ... @@ -41,6 +41,10 @@
41 41 flex-direction: column;
42 42 color: #393e46;
43 43 width: 100%;
  44 +
  45 + &:disabled {
  46 + cursor: not-allowed;
  47 + }
44 48 .shortcut-icon {
45 49 padding: 4px;
46 50 // display: block;
... ...
front-end/h5/src/mixins/load-plugins.js
... ... @@ -16,18 +16,42 @@ export const pluginsList = [
16 16 },
17 17 {
18 18 title: '文字',
19   - icon: 'font',
  19 + icon: 'text-width',
20 20 component: LbpText,
21 21 visible: true,
22 22 name: LbpText.name
23 23 },
24 24 {
25   - title: '按钮',
  25 + title: '普通按钮',
26 26 icon: 'hand-pointer-o',
27 27 component: LbpButton,
28 28 visible: true,
29 29 name: LbpButton.name
30 30 },
  31 + {
  32 + title: '轮播图',
  33 + icon: 'photo',
  34 + component: LbpFormRadioGroup,
  35 + visible: true,
  36 + name: LbpFormRadioGroup.name,
  37 + disabled: true
  38 + },
  39 + {
  40 + title: '地图',
  41 + icon: 'map-o',
  42 + component: LbpFormRadioGroup,
  43 + visible: true,
  44 + name: LbpFormRadioGroup.name,
  45 + disabled: true
  46 + },
  47 + {
  48 + title: '视频',
  49 + icon: 'file-video-o',
  50 + component: LbpFormRadioGroup,
  51 + visible: true,
  52 + name: LbpFormRadioGroup.name,
  53 + disabled: true
  54 + },
31 55 // {
32 56 // title: '视频',
33 57 // icon: 'play-circle-o',
... ... @@ -58,7 +82,14 @@ export const pluginsList = [
58 82 // },
59 83 {
60 84 title: '表单单选',
61   - icon: 'hand-pointer-o',
  85 + icon: 'check-square-o',
  86 + component: LbpFormRadioGroup,
  87 + visible: true,
  88 + name: LbpFormRadioGroup.name
  89 + },
  90 + {
  91 + title: '表单单选',
  92 + icon: 'dot-circle-o',
62 93 component: LbpFormRadioGroup,
63 94 visible: true,
64 95 name: LbpFormRadioGroup.name
... ...