Commit ce83d55e153c51674ad0737c64145f587102cc33

Authored by ly525
Committed by 小小鲁班
1 parent 15a60102

chore: remove single quote with regex

front-end/h5/src/components/core/editor/index.js
... ... @@ -45,54 +45,59 @@ import Feedback from '@/components/common/feedback/index'
45 45 const fixedTools = [
46 46 {
47 47 i18nTooltip: 'editor.fixedTool.undo',
48   - 'icon': 'mail-reply',
49   - 'action': () => undoRedoHistory.undo(),
50   - 'hotkey': 'ctrl&z,⌘&z',
51   - 'hotkeyTooltip': '(ctrl+z)'
  48 + icon: 'mail-reply',
  49 + action: () => undoRedoHistory.undo(),
  50 + hotkey: 'ctrl&z,⌘&z',
  51 + hotkeyTooltip: '(ctrl+z)'
52 52 },
53 53 {
54 54 i18nTooltip: 'editor.fixedTool.redo',
55   - 'icon': 'mail-forward',
56   - 'action': () => undoRedoHistory.redo(),
57   - 'hotkey': 'ctrl&y,⌘&u',
58   - 'hotkeyTooltip': '(ctrl+y)'
  55 + icon: 'mail-forward',
  56 + action: () => undoRedoHistory.redo(),
  57 + hotkey: 'ctrl&y,⌘&u',
  58 + hotkeyTooltip: '(ctrl+y)'
59 59 },
60 60 {
61 61 i18nTooltip: 'editor.fixedTool.preview',
62   - 'icon': 'eye',
63   - 'action': function () { this.previewVisible = true }
  62 + icon: 'eye',
  63 + action: function () { this.previewVisible = true }
64 64 },
65 65 {
66 66 i18nTooltip: 'editor.fixedTool.copyCurrentPage',
67   - 'icon': 'copy',
68   - 'action': function () { this.pageManager({ type: 'copy' }) },
69   - 'hotkey': 'ctrl&c,⌘&c'
  67 + icon: 'copy',
  68 + action: function () { this.pageManager({ type: 'copy' }) },
  69 + hotkey: 'ctrl&c,⌘&c'
  70 + },
  71 + {
  72 + i18nTooltip: 'editor.fixedTool.copyCurrentElement',
  73 + icon: 'copy',
  74 + action: function () { this.elementManager({ type: 'copy' }) }
70 75 },
71 76 {
72 77 i18nTooltip: 'editor.fixedTool.importPSD',
73   - 'text': 'Ps',
74   - 'icon': '', // 优先级: icon > text > i18nTooltip
75   - 'action': '',
76   - 'disabled': true
  78 + text: 'Ps',
  79 + icon: '', // 优先级: icon > text > i18nTooltip
  80 + action: '',
  81 + disabled: true
77 82 },
78 83 {
79 84 i18nTooltip: 'editor.fixedTool.zoomOut',
80   - 'icon': 'plus',
81   - 'action': function () { this.scaleRate += 0.25 },
82   - 'hotkey': 'ctrl&=,⌘&=',
83   - 'hotkeyTooltip': '(ctrl +)'
  85 + icon: 'plus',
  86 + action: function () { this.scaleRate += 0.25 },
  87 + hotkey: 'ctrl&=,⌘&=',
  88 + hotkeyTooltip: '(ctrl +)'
84 89 },
85 90 {
86 91 i18nTooltip: 'editor.fixedTool.zoomIn',
87   - 'icon': 'minus',
88   - 'action': function () { this.scaleRate -= 0.25 },
89   - 'hotkey': 'ctrl&-,⌘&-',
90   - 'hotkeyTooltip': '(ctrl -)'
  92 + icon: 'minus',
  93 + action: function () { this.scaleRate -= 0.25 },
  94 + hotkey: 'ctrl&-,⌘&-',
  95 + hotkeyTooltip: '(ctrl -)'
91 96 },
92 97 {
93 98 i18nTooltip: 'editor.fixedTool.issues',
94   - 'icon': 'question',
95   - 'action': function () { window.open('https://github.com/ly525/luban-h5/issues/110') }
  99 + icon: 'question',
  100 + action: function () { window.open('https://github.com/ly525/luban-h5/issues/110') }
96 101 }
97 102 ]
98 103  
... ...