Skip to content

Commit f23f271

Browse files
committed
Update editor toolbar and mobile toolbar to remove alignment and super/sub scripts
1 parent 00660e1 commit f23f271

2 files changed

Lines changed: 10 additions & 7 deletions

File tree

contentcuration/contentcuration/frontend/shared/views/TipTapEditor/TipTapEditor/components/EditorToolbar.vue

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -391,7 +391,9 @@
391391
// 'script',
392392
'lists',
393393
'clearFormat',
394-
'align',
394+
// Perseus flavoured markdown does not support alignment,
395+
// so we disable this for now until we stop using markdown as the primary target
396+
// 'align',
395397
'clipboard',
396398
'textFormat',
397399
];

contentcuration/contentcuration/frontend/shared/views/TipTapEditor/TipTapEditor/components/toolbar/MobileFormattingBar.vue

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -81,13 +81,17 @@
8181
:is-active="action.isActive"
8282
@click="action.handler"
8383
/>
84+
<!-- Perseus flavoured markdown does not support alignment,
85+
so we disable this for now until we stop using markdown as the primary target
8486
<ToolbarDivider />
8587
<ToolbarButton
8688
:title="alignAction.title"
8789
:icon="alignAction.icon"
8890
:is-active="alignAction.isActive"
8991
@click="alignAction.handler"
90-
/>
92+
/> -->
93+
<!-- Perseus flavoured markdown does not support super and sub script,
94+
so we disable this for now until we stop using markdown as the primary target
9195
<ToolbarDivider />
9296
<ToolbarButton
9397
v-for="action in scriptActions"
@@ -96,7 +100,7 @@
96100
:icon="action.icon"
97101
:is-active="action.isActive"
98102
@click="action.handler"
99-
/>
103+
/> -->
100104
<ToolbarDivider />
101105
<ToolbarButton
102106
v-for="tool in insertTools"
@@ -138,8 +142,7 @@
138142
textFormattingToolbar$,
139143
} = getTipTapEditorStrings();
140144
141-
const { textActions, listActions, scriptActions, insertTools, alignAction } =
142-
useToolbarActions(emit);
145+
const { textActions, listActions, insertTools } = useToolbarActions(emit);
143146
144147
const { canIncreaseFormat, canDecreaseFormat, increaseFormat, decreaseFormat } =
145148
useFormatControls();
@@ -206,9 +209,7 @@
206209
keyboardOffset,
207210
textActions,
208211
listActions,
209-
scriptActions,
210212
insertTools,
211-
alignAction,
212213
toggleToolbar,
213214
canIncreaseFormat,
214215
canDecreaseFormat,

0 commit comments

Comments
 (0)