@manuscripts/body-editor 3.12.65 → 3.12.66
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/components/authors-affiliations/ModalTabs.js +2 -2
- package/dist/cjs/components/keyboard-shortcuts-modal/FormattedShortcut.js +48 -0
- package/dist/cjs/components/keyboard-shortcuts-modal/KeyboardShortcutsModal.js +195 -0
- package/dist/cjs/components/keyboard-shortcuts-modal/keyboard-shortcuts.js +249 -0
- package/dist/cjs/index.js +4 -1
- package/dist/cjs/lib/platform.js +1 -1
- package/dist/cjs/menus.js +19 -1
- package/dist/cjs/versions.js +1 -1
- package/dist/cjs/views/ReactSubView.js +4 -7
- package/dist/es/components/authors-affiliations/ModalTabs.js +2 -2
- package/dist/es/components/keyboard-shortcuts-modal/FormattedShortcut.js +41 -0
- package/dist/es/components/keyboard-shortcuts-modal/KeyboardShortcutsModal.js +157 -0
- package/dist/es/components/keyboard-shortcuts-modal/keyboard-shortcuts.js +246 -0
- package/dist/es/index.js +1 -0
- package/dist/es/lib/platform.js +1 -1
- package/dist/es/menus.js +19 -1
- package/dist/es/versions.js +1 -1
- package/dist/es/views/ReactSubView.js +4 -7
- package/dist/types/components/keyboard-shortcuts-modal/FormattedShortcut.d.ts +17 -0
- package/dist/types/components/keyboard-shortcuts-modal/KeyboardShortcutsModal.d.ts +11 -0
- package/dist/types/components/keyboard-shortcuts-modal/keyboard-shortcuts.d.ts +33 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types/versions.d.ts +1 -1
- package/package.json +2 -2
|
@@ -22,10 +22,10 @@ exports.ModalTabs = void 0;
|
|
|
22
22
|
const style_guide_1 = require("@manuscripts/style-guide");
|
|
23
23
|
const react_1 = __importDefault(require("react"));
|
|
24
24
|
const styled_components_1 = __importDefault(require("styled-components"));
|
|
25
|
-
const ModalTabs = ({ tabLabels, tabErrorIndicators, tabWarningIndicators, }) => (react_1.default.createElement(StyledTabList,
|
|
25
|
+
const ModalTabs = ({ tabLabels, tabErrorIndicators, tabWarningIndicators, }) => (react_1.default.createElement(StyledTabList, { "data-cy": "ModalTabs" }, tabLabels.map((label, i) => {
|
|
26
26
|
const hasError = tabErrorIndicators?.[i];
|
|
27
27
|
const showWarning = tabWarningIndicators?.[i] && !hasError;
|
|
28
|
-
return (react_1.default.createElement(StyledTab, { key: label },
|
|
28
|
+
return (react_1.default.createElement(StyledTab, { key: label, "data-cy": "ModalTab" },
|
|
29
29
|
label,
|
|
30
30
|
(showWarning || hasError) && (react_1.default.createElement(TabIndicatorGroup, { role: "presentation" },
|
|
31
31
|
showWarning ? react_1.default.createElement(TabWarningDot, { "aria-hidden": true }) : null,
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/*!
|
|
3
|
+
* © 2025 Atypon Systems LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
18
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
19
|
+
};
|
|
20
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
21
|
+
exports.formattedShortCut = void 0;
|
|
22
|
+
const style_guide_1 = require("@manuscripts/style-guide");
|
|
23
|
+
const react_1 = __importDefault(require("react"));
|
|
24
|
+
const platform_1 = require("../../lib/platform");
|
|
25
|
+
const keyMap = {
|
|
26
|
+
CommandOrControl: platform_1.isMac ? '⌘' : 'Ctrl',
|
|
27
|
+
Option: platform_1.isMac ? '⌥' : 'Alt',
|
|
28
|
+
Shift: platform_1.isMac ? '⇧' : 'Shift',
|
|
29
|
+
ArrowUp: '↑',
|
|
30
|
+
ArrowDown: '↓',
|
|
31
|
+
ArrowLeft: '←',
|
|
32
|
+
ArrowRight: '→',
|
|
33
|
+
BracketLeft: '[',
|
|
34
|
+
BracketRight: ']',
|
|
35
|
+
Escape: 'Esc',
|
|
36
|
+
Tab: 'Tab',
|
|
37
|
+
Enter: '↵',
|
|
38
|
+
};
|
|
39
|
+
const formattedShortCut = (accelerator) => {
|
|
40
|
+
const parts = accelerator.split('+').map((p) => p.trim());
|
|
41
|
+
return (react_1.default.createElement(react_1.default.Fragment, null, parts.map((part, index) => {
|
|
42
|
+
const content = keyMap[part] ?? part;
|
|
43
|
+
return (react_1.default.createElement(react_1.default.Fragment, { key: `${part}-${index}` },
|
|
44
|
+
react_1.default.createElement(style_guide_1.Shortcut, null, content),
|
|
45
|
+
index < parts.length - 1 && (react_1.default.createElement(style_guide_1.ShortcutConnector, null, "+"))));
|
|
46
|
+
})));
|
|
47
|
+
};
|
|
48
|
+
exports.formattedShortCut = formattedShortCut;
|
|
@@ -0,0 +1,195 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
35
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
+
exports.KeyboardShortcutsModal = exports.KEYBOARD_SHORTCUTS_MODAL_ID = void 0;
|
|
37
|
+
exports.openKeyboardShortcuts = openKeyboardShortcuts;
|
|
38
|
+
const style_guide_1 = require("@manuscripts/style-guide");
|
|
39
|
+
const react_1 = __importStar(require("react"));
|
|
40
|
+
const styled_components_1 = __importStar(require("styled-components"));
|
|
41
|
+
const platform_1 = require("../../lib/platform");
|
|
42
|
+
const editor_props_1 = require("../../plugins/editor-props");
|
|
43
|
+
const ReactSubView_1 = require("../../views/ReactSubView");
|
|
44
|
+
const ModalTabs_1 = require("../authors-affiliations/ModalTabs");
|
|
45
|
+
const FormattedShortcut_1 = require("./FormattedShortcut");
|
|
46
|
+
const keyboard_shortcuts_1 = require("./keyboard-shortcuts");
|
|
47
|
+
const TAB_LABELS = keyboard_shortcuts_1.EDITOR_KEYBOARD_SHORTCUT_TABS.map((t) => t.label);
|
|
48
|
+
const KEYBOARD_SHORTCUTS_MODAL_TITLE_ID = 'keyboard-shortcuts-modal-title';
|
|
49
|
+
exports.KEYBOARD_SHORTCUTS_MODAL_ID = 'keyboard-shortcuts-modal';
|
|
50
|
+
const KeyboardShortcutsModal = ({ editorProps, isOpen, onClose, }) => {
|
|
51
|
+
const [tabIndex, setTabIndex] = (0, react_1.useState)(0);
|
|
52
|
+
const containerRef = (0, react_1.useRef)(null);
|
|
53
|
+
(0, style_guide_1.useFocusCycle)(containerRef, isOpen);
|
|
54
|
+
return (react_1.default.createElement(styled_components_1.ThemeProvider, { theme: editorProps.theme },
|
|
55
|
+
react_1.default.createElement(style_guide_1.StyledModal, { isOpen: isOpen, onRequestClose: onClose, shouldCloseOnOverlayClick: true, ariaLabelledby: KEYBOARD_SHORTCUTS_MODAL_TITLE_ID, id: exports.KEYBOARD_SHORTCUTS_MODAL_ID },
|
|
56
|
+
react_1.default.createElement(style_guide_1.ModalContainer, { ref: containerRef },
|
|
57
|
+
react_1.default.createElement(style_guide_1.ModalHeader, null,
|
|
58
|
+
react_1.default.createElement(style_guide_1.CloseButton, { onClick: onClose, "data-cy": "modal-close-button" })),
|
|
59
|
+
react_1.default.createElement(StyledModalBody, null,
|
|
60
|
+
react_1.default.createElement(StyledModalSidebar, null,
|
|
61
|
+
react_1.default.createElement(StyledModalSidebarHeader, null,
|
|
62
|
+
react_1.default.createElement(StyledModalSidebarTitle, { as: "h2", id: KEYBOARD_SHORTCUTS_MODAL_TITLE_ID }, "Keyboard shortcuts")),
|
|
63
|
+
react_1.default.createElement(StyledSidebarContent, null,
|
|
64
|
+
react_1.default.createElement(ShortcutTabs, { selectedIndex: tabIndex, onChange: setTabIndex },
|
|
65
|
+
react_1.default.createElement(ModalTabsWrapper, null,
|
|
66
|
+
react_1.default.createElement(ModalTabs_1.ModalTabs, { tabLabels: TAB_LABELS })),
|
|
67
|
+
react_1.default.createElement(style_guide_1.InspectorTabPanels, null, keyboard_shortcuts_1.EDITOR_KEYBOARD_SHORTCUT_TABS.map((tab) => (react_1.default.createElement(ShortcutTabPanel, { key: tab.id }, tab.sections.map((section, sectionIndex) => (react_1.default.createElement(Section, { key: `${tab.id}:${sectionIndex}` },
|
|
68
|
+
react_1.default.createElement(SectionTitle, null, section.title),
|
|
69
|
+
react_1.default.createElement(ShortcutTable, null, section.rows.map((row, rowIndex) => (react_1.default.createElement(ShortcutRow, { key: `${tab.id}-${sectionIndex}-${rowIndex}` },
|
|
70
|
+
react_1.default.createElement(ShortcutLabel, null, row.label),
|
|
71
|
+
react_1.default.createElement(ShortcutKeys, null, (0, FormattedShortcut_1.formattedShortCut)(platform_1.isMac ? row.shortcut.mac : row.shortcut.pc))))))))))))))),
|
|
72
|
+
react_1.default.createElement(ButtonsContainer, null,
|
|
73
|
+
react_1.default.createElement(style_guide_1.PrimaryButton, { onClick: onClose }, "Close"))))))));
|
|
74
|
+
};
|
|
75
|
+
exports.KeyboardShortcutsModal = KeyboardShortcutsModal;
|
|
76
|
+
const ShortcutTabs = (0, styled_components_1.default)(style_guide_1.InspectorTabs) `
|
|
77
|
+
display: flex;
|
|
78
|
+
flex-direction: column;
|
|
79
|
+
min-height: 0;
|
|
80
|
+
`;
|
|
81
|
+
const ModalTabsWrapper = (0, styled_components_1.default)('div') `
|
|
82
|
+
margin: 0 ${(props) => props.theme.grid.unit * 8}px ${(props) => props.theme.grid.unit * 3}px;
|
|
83
|
+
`;
|
|
84
|
+
const ShortcutTabPanel = (0, styled_components_1.default)(style_guide_1.InspectorTabPanel).attrs({
|
|
85
|
+
tabIndex: -1,
|
|
86
|
+
unmount: false,
|
|
87
|
+
}) `
|
|
88
|
+
margin-top: ${(props) => props.theme.grid.unit * 3}px;
|
|
89
|
+
overflow-y: auto;
|
|
90
|
+
flex: 1;
|
|
91
|
+
min-height: 0;
|
|
92
|
+
`;
|
|
93
|
+
const StyledModalSidebar = (0, styled_components_1.default)(style_guide_1.ModalSidebar) `
|
|
94
|
+
position: relative;
|
|
95
|
+
background: white;
|
|
96
|
+
max-width: none;
|
|
97
|
+
width: min(664px, 90vw);
|
|
98
|
+
display: flex;
|
|
99
|
+
flex-direction: column;
|
|
100
|
+
padding: 0;
|
|
101
|
+
`;
|
|
102
|
+
const StyledModalSidebarHeader = (0, styled_components_1.default)(style_guide_1.ModalSidebarHeader) `
|
|
103
|
+
margin: 0 ${(props) => props.theme.grid.unit * 8}px;
|
|
104
|
+
padding: 0;
|
|
105
|
+
`;
|
|
106
|
+
const StyledModalSidebarTitle = (0, styled_components_1.default)(style_guide_1.ModalSidebarTitle) `
|
|
107
|
+
margin: ${(props) => props.theme.grid.unit * 6}px 0;
|
|
108
|
+
padding: 0;
|
|
109
|
+
`;
|
|
110
|
+
const StyledModalBody = (0, styled_components_1.default)(style_guide_1.ModalBody) `
|
|
111
|
+
flex: 1;
|
|
112
|
+
min-height: 0;
|
|
113
|
+
display: flex;
|
|
114
|
+
flex-direction: column;
|
|
115
|
+
`;
|
|
116
|
+
const StyledSidebarContent = (0, styled_components_1.default)(style_guide_1.SidebarContent) `
|
|
117
|
+
display: flex;
|
|
118
|
+
flex-direction: column;
|
|
119
|
+
overflow: hidden;
|
|
120
|
+
flex: 1;
|
|
121
|
+
min-height: 0;
|
|
122
|
+
gap: ${(props) => props.theme.grid.unit * 2}px;
|
|
123
|
+
padding: 0;
|
|
124
|
+
`;
|
|
125
|
+
const Section = styled_components_1.default.section `
|
|
126
|
+
margin: 0 0 ${(props) => props.theme.grid.unit * 4}px;
|
|
127
|
+
|
|
128
|
+
&:last-child {
|
|
129
|
+
margin-bottom: 0;
|
|
130
|
+
}
|
|
131
|
+
`;
|
|
132
|
+
const SectionTitle = styled_components_1.default.h3 `
|
|
133
|
+
margin: 0 ${(props) => props.theme.grid.unit * 8}px ${(props) => props.theme.grid.unit * 2}px;
|
|
134
|
+
font-size: ${(props) => props.theme.font.size.large};
|
|
135
|
+
font-weight: ${(props) => props.theme.font.weight.normal};
|
|
136
|
+
line-height: ${(props) => props.theme.font.lineHeight.large};
|
|
137
|
+
color: ${(props) => props.theme.colors.text.greyMuted};
|
|
138
|
+
`;
|
|
139
|
+
const ShortcutTable = styled_components_1.default.div `
|
|
140
|
+
border-collapse: collapse;
|
|
141
|
+
font-size: ${(props) => props.theme.font.size.normal};
|
|
142
|
+
margin: 0 ${(props) => props.theme.grid.unit * 8}px;
|
|
143
|
+
`;
|
|
144
|
+
const ShortcutRow = styled_components_1.default.div `
|
|
145
|
+
display: flex;
|
|
146
|
+
justify-content: space-between;
|
|
147
|
+
align-items: center;
|
|
148
|
+
padding: ${({ theme }) => theme.grid.unit * 1.5}px 0;
|
|
149
|
+
`;
|
|
150
|
+
const ShortcutLabel = styled_components_1.default.div `
|
|
151
|
+
padding: ${(props) => props.theme.grid.unit * 1.5}px
|
|
152
|
+
${(props) => props.theme.grid.unit * 2}px
|
|
153
|
+
${(props) => props.theme.grid.unit * 1.5}px 0;
|
|
154
|
+
vertical-align: top;
|
|
155
|
+
color: ${(props) => props.theme.colors.text.secondary};
|
|
156
|
+
`;
|
|
157
|
+
const ShortcutKeys = styled_components_1.default.div `
|
|
158
|
+
padding: ${(props) => props.theme.grid.unit * 1.5}px 0;
|
|
159
|
+
vertical-align: top;
|
|
160
|
+
text-align: right;
|
|
161
|
+
white-space: nowrap;
|
|
162
|
+
font-variant-numeric: tabular-nums;
|
|
163
|
+
`;
|
|
164
|
+
const ButtonsContainer = (0, styled_components_1.default)(style_guide_1.ButtonGroup) `
|
|
165
|
+
padding: ${(props) => props.theme.grid.unit * 4}px 0;
|
|
166
|
+
margin: 0 ${(props) => props.theme.grid.unit * 8}px;
|
|
167
|
+
flex-shrink: 0;
|
|
168
|
+
`;
|
|
169
|
+
let dialog = null;
|
|
170
|
+
async function openKeyboardShortcuts(view) {
|
|
171
|
+
if (!view || dialog) {
|
|
172
|
+
return;
|
|
173
|
+
}
|
|
174
|
+
const { state } = view;
|
|
175
|
+
const editorProps = (0, editor_props_1.getEditorProps)(state);
|
|
176
|
+
const cleanup = () => {
|
|
177
|
+
if (dialog) {
|
|
178
|
+
dialog.remove();
|
|
179
|
+
dialog = null;
|
|
180
|
+
}
|
|
181
|
+
const modal = document.getElementById(exports.KEYBOARD_SHORTCUTS_MODAL_ID);
|
|
182
|
+
if (modal) {
|
|
183
|
+
modal.remove();
|
|
184
|
+
}
|
|
185
|
+
requestAnimationFrame(() => {
|
|
186
|
+
view.focus();
|
|
187
|
+
});
|
|
188
|
+
};
|
|
189
|
+
dialog = await (0, ReactSubView_1.createSubViewAsync)(editorProps, exports.KeyboardShortcutsModal, {
|
|
190
|
+
editorProps,
|
|
191
|
+
isOpen: true,
|
|
192
|
+
onClose: cleanup,
|
|
193
|
+
}, state.doc, () => -1, view);
|
|
194
|
+
document.body.appendChild(dialog);
|
|
195
|
+
}
|
|
@@ -0,0 +1,249 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/*!
|
|
3
|
+
* © 2025 Atypon Systems LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
+
exports.EDITOR_KEYBOARD_SHORTCUT_TABS = void 0;
|
|
19
|
+
exports.EDITOR_KEYBOARD_SHORTCUT_TABS = [
|
|
20
|
+
{
|
|
21
|
+
id: 'text-editing',
|
|
22
|
+
label: 'Text editing',
|
|
23
|
+
sections: [
|
|
24
|
+
{
|
|
25
|
+
title: 'Formatting',
|
|
26
|
+
rows: [
|
|
27
|
+
{
|
|
28
|
+
label: 'Bold',
|
|
29
|
+
shortcut: { mac: 'CommandOrControl+B', pc: 'CommandOrControl+B' },
|
|
30
|
+
},
|
|
31
|
+
{
|
|
32
|
+
label: 'Italic',
|
|
33
|
+
shortcut: { mac: 'CommandOrControl+I', pc: 'CommandOrControl+I' },
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
label: 'Underline',
|
|
37
|
+
shortcut: { mac: 'CommandOrControl+U', pc: 'CommandOrControl+U' },
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
label: 'Strikethrough',
|
|
41
|
+
shortcut: {
|
|
42
|
+
mac: 'CommandOrControl+Shift+X',
|
|
43
|
+
pc: 'CommandOrControl+Shift+X',
|
|
44
|
+
},
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
label: 'Superscript',
|
|
48
|
+
shortcut: {
|
|
49
|
+
mac: 'Option+CommandOrControl+=',
|
|
50
|
+
pc: 'CommandOrControl+Option+=',
|
|
51
|
+
},
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
label: 'Subscript',
|
|
55
|
+
shortcut: {
|
|
56
|
+
mac: 'Option+CommandOrControl+-',
|
|
57
|
+
pc: 'CommandOrControl+Option+-',
|
|
58
|
+
},
|
|
59
|
+
},
|
|
60
|
+
],
|
|
61
|
+
},
|
|
62
|
+
{
|
|
63
|
+
title: 'General',
|
|
64
|
+
rows: [
|
|
65
|
+
{
|
|
66
|
+
label: 'Select all',
|
|
67
|
+
shortcut: { mac: 'CommandOrControl+A', pc: 'CommandOrControl+A' },
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
label: 'Undo',
|
|
71
|
+
shortcut: { mac: 'CommandOrControl+Z', pc: 'CommandOrControl+Z' },
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
label: 'Redo',
|
|
75
|
+
shortcut: {
|
|
76
|
+
mac: 'Shift+CommandOrControl+Z',
|
|
77
|
+
pc: 'CommandOrControl+Y',
|
|
78
|
+
},
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
label: 'Activate search',
|
|
82
|
+
shortcut: {
|
|
83
|
+
mac: 'CommandOrControl+F',
|
|
84
|
+
pc: 'CommandOrControl+F',
|
|
85
|
+
},
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
label: 'Activate search/replace',
|
|
89
|
+
shortcut: {
|
|
90
|
+
mac: 'CommandOrControl+Shift+H',
|
|
91
|
+
pc: 'CommandOrControl+Shift+H',
|
|
92
|
+
},
|
|
93
|
+
},
|
|
94
|
+
],
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
title: 'Enter',
|
|
98
|
+
rows: [
|
|
99
|
+
{
|
|
100
|
+
label: 'Insert line break',
|
|
101
|
+
shortcut: { mac: 'Shift+Enter', pc: 'Shift+Enter' },
|
|
102
|
+
},
|
|
103
|
+
{
|
|
104
|
+
label: 'Insert section',
|
|
105
|
+
shortcut: {
|
|
106
|
+
mac: 'CommandOrControl+Enter',
|
|
107
|
+
pc: 'CommandOrControl+Enter',
|
|
108
|
+
},
|
|
109
|
+
},
|
|
110
|
+
{
|
|
111
|
+
label: 'Insert sub section',
|
|
112
|
+
shortcut: {
|
|
113
|
+
mac: 'Shift+CommandOrControl+Enter',
|
|
114
|
+
pc: 'Shift+CommandOrControl+Enter',
|
|
115
|
+
},
|
|
116
|
+
},
|
|
117
|
+
],
|
|
118
|
+
},
|
|
119
|
+
{
|
|
120
|
+
title: 'Lists',
|
|
121
|
+
rows: [
|
|
122
|
+
{
|
|
123
|
+
label: 'New list item',
|
|
124
|
+
shortcut: { mac: 'Enter', pc: 'Enter' },
|
|
125
|
+
},
|
|
126
|
+
{
|
|
127
|
+
label: 'Indent list item',
|
|
128
|
+
shortcut: { mac: 'CommandOrControl+]', pc: 'CommandOrControl+]' },
|
|
129
|
+
},
|
|
130
|
+
{
|
|
131
|
+
label: 'Outdent list item',
|
|
132
|
+
shortcut: { mac: 'CommandOrControl+[', pc: 'CommandOrControl+[' },
|
|
133
|
+
},
|
|
134
|
+
{
|
|
135
|
+
label: 'Ordered list',
|
|
136
|
+
shortcut: {
|
|
137
|
+
mac: 'CommandOrControl+Option+O',
|
|
138
|
+
pc: 'CommandOrControl+Option+O',
|
|
139
|
+
},
|
|
140
|
+
},
|
|
141
|
+
{
|
|
142
|
+
label: 'Bullet list',
|
|
143
|
+
shortcut: {
|
|
144
|
+
mac: 'CommandOrControl+Option+K',
|
|
145
|
+
pc: 'CommandOrControl+Option+K',
|
|
146
|
+
},
|
|
147
|
+
},
|
|
148
|
+
],
|
|
149
|
+
},
|
|
150
|
+
],
|
|
151
|
+
},
|
|
152
|
+
{
|
|
153
|
+
id: 'insert-elements',
|
|
154
|
+
label: 'Insert elements',
|
|
155
|
+
sections: [
|
|
156
|
+
{
|
|
157
|
+
title: 'Insert',
|
|
158
|
+
rows: [
|
|
159
|
+
{
|
|
160
|
+
label: 'Insert figure',
|
|
161
|
+
shortcut: {
|
|
162
|
+
mac: 'CommandOrControl + Option + P',
|
|
163
|
+
pc: 'CommandOrControl + Option + P',
|
|
164
|
+
},
|
|
165
|
+
},
|
|
166
|
+
{
|
|
167
|
+
label: 'Insert table',
|
|
168
|
+
shortcut: {
|
|
169
|
+
mac: 'CommandOrControl + Option + T',
|
|
170
|
+
pc: 'CommandOrControl + Option + T',
|
|
171
|
+
},
|
|
172
|
+
},
|
|
173
|
+
{
|
|
174
|
+
label: 'Insert equation block',
|
|
175
|
+
shortcut: {
|
|
176
|
+
mac: 'CommandOrControl + Option + E',
|
|
177
|
+
pc: 'CommandOrControl + Option + E',
|
|
178
|
+
},
|
|
179
|
+
},
|
|
180
|
+
{
|
|
181
|
+
label: 'Insert box',
|
|
182
|
+
shortcut: {
|
|
183
|
+
mac: 'CommandOrControl + Option + B',
|
|
184
|
+
pc: 'CommandOrControl + Option + B',
|
|
185
|
+
},
|
|
186
|
+
},
|
|
187
|
+
{
|
|
188
|
+
label: 'Insert link',
|
|
189
|
+
shortcut: {
|
|
190
|
+
mac: 'CommandOrControl + Option + H',
|
|
191
|
+
pc: 'CommandOrControl + Option + H',
|
|
192
|
+
},
|
|
193
|
+
},
|
|
194
|
+
{
|
|
195
|
+
label: 'Insert footnote',
|
|
196
|
+
shortcut: {
|
|
197
|
+
mac: 'CommandOrControl + Option + F',
|
|
198
|
+
pc: 'CommandOrControl + Option + F',
|
|
199
|
+
},
|
|
200
|
+
},
|
|
201
|
+
{
|
|
202
|
+
label: 'Insert citation',
|
|
203
|
+
shortcut: {
|
|
204
|
+
mac: 'CommandOrControl + Option + C',
|
|
205
|
+
pc: 'CommandOrControl + Option + C',
|
|
206
|
+
},
|
|
207
|
+
},
|
|
208
|
+
{
|
|
209
|
+
label: 'Insert cross-reference',
|
|
210
|
+
shortcut: {
|
|
211
|
+
mac: 'CommandOrControl + Option + R',
|
|
212
|
+
pc: 'CommandOrControl + Option + R',
|
|
213
|
+
},
|
|
214
|
+
},
|
|
215
|
+
{
|
|
216
|
+
label: 'Insert Inline equation',
|
|
217
|
+
shortcut: {
|
|
218
|
+
mac: 'Shift + CommandOrControl + Option + E',
|
|
219
|
+
pc: 'Shift + CommandOrControl + E',
|
|
220
|
+
},
|
|
221
|
+
},
|
|
222
|
+
],
|
|
223
|
+
},
|
|
224
|
+
],
|
|
225
|
+
},
|
|
226
|
+
{
|
|
227
|
+
id: 'navigation',
|
|
228
|
+
label: 'Navigation',
|
|
229
|
+
sections: [
|
|
230
|
+
{
|
|
231
|
+
title: 'Navigation',
|
|
232
|
+
rows: [
|
|
233
|
+
{
|
|
234
|
+
label: 'Next table cell / focus nearest element',
|
|
235
|
+
shortcut: { mac: 'Tab', pc: 'Tab' },
|
|
236
|
+
},
|
|
237
|
+
{
|
|
238
|
+
label: 'Previous table cell / focus nearest element back',
|
|
239
|
+
shortcut: { mac: 'Shift + Tab', pc: 'Shift + Tab' },
|
|
240
|
+
},
|
|
241
|
+
{
|
|
242
|
+
label: 'Exit editor to container',
|
|
243
|
+
shortcut: { mac: 'Escape', pc: 'Escape' },
|
|
244
|
+
},
|
|
245
|
+
],
|
|
246
|
+
},
|
|
247
|
+
],
|
|
248
|
+
},
|
|
249
|
+
];
|
package/dist/cjs/index.js
CHANGED
|
@@ -32,7 +32,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
32
32
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
33
33
|
};
|
|
34
34
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
35
|
-
exports.affiliationLabel = exports.authorLabel = exports.bibliographyItemTypes = exports.metadata = exports.getClosestMatch = exports.getNewMatch = exports.detectInconsistencyPluginKey = exports.searchReplacePluginKey = exports.bibliographyPluginKey = exports.footnotesPluginKey = exports.objectsPluginKey = exports.selectedSuggestionKey = exports.PopperManager = exports.CollabProvider = exports.LanguageDropdown = exports.TypeSelector = exports.OutlineItemIcon = exports.ManuscriptOutline = void 0;
|
|
35
|
+
exports.affiliationLabel = exports.authorLabel = exports.bibliographyItemTypes = exports.metadata = exports.getClosestMatch = exports.getNewMatch = exports.detectInconsistencyPluginKey = exports.searchReplacePluginKey = exports.bibliographyPluginKey = exports.footnotesPluginKey = exports.objectsPluginKey = exports.selectedSuggestionKey = exports.PopperManager = exports.CollabProvider = exports.openKeyboardShortcuts = exports.KeyboardShortcutsModal = exports.LanguageDropdown = exports.TypeSelector = exports.OutlineItemIcon = exports.ManuscriptOutline = void 0;
|
|
36
36
|
__exportStar(require("./commands"), exports);
|
|
37
37
|
var ManuscriptOutline_1 = require("./components/outline/ManuscriptOutline");
|
|
38
38
|
Object.defineProperty(exports, "ManuscriptOutline", { enumerable: true, get: function () { return ManuscriptOutline_1.ManuscriptOutline; } });
|
|
@@ -42,6 +42,9 @@ var TypeSelector_1 = require("./components/toolbar/type-selector/TypeSelector");
|
|
|
42
42
|
Object.defineProperty(exports, "TypeSelector", { enumerable: true, get: function () { return TypeSelector_1.TypeSelector; } });
|
|
43
43
|
var LanguageDropdown_1 = require("./components/LanguageDropdown");
|
|
44
44
|
Object.defineProperty(exports, "LanguageDropdown", { enumerable: true, get: function () { return __importDefault(LanguageDropdown_1).default; } });
|
|
45
|
+
var KeyboardShortcutsModal_1 = require("./components/keyboard-shortcuts-modal/KeyboardShortcutsModal");
|
|
46
|
+
Object.defineProperty(exports, "KeyboardShortcutsModal", { enumerable: true, get: function () { return KeyboardShortcutsModal_1.KeyboardShortcutsModal; } });
|
|
47
|
+
Object.defineProperty(exports, "openKeyboardShortcuts", { enumerable: true, get: function () { return KeyboardShortcutsModal_1.openKeyboardShortcuts; } });
|
|
45
48
|
__exportStar(require("./components/toolbar/ListMenuItem"), exports);
|
|
46
49
|
__exportStar(require("./components/toolbar/InsertTableDialog"), exports);
|
|
47
50
|
__exportStar(require("./menus"), exports);
|
package/dist/cjs/lib/platform.js
CHANGED
package/dist/cjs/menus.js
CHANGED
|
@@ -23,6 +23,7 @@ const commands_1 = require("./commands");
|
|
|
23
23
|
const InsertTableDialog_1 = require("./components/toolbar/InsertTableDialog");
|
|
24
24
|
const ListMenuItem_1 = require("./components/toolbar/ListMenuItem");
|
|
25
25
|
const InsertSpecialCharacter_1 = require("./components/views/InsertSpecialCharacter");
|
|
26
|
+
const KeyboardShortcutsModal_1 = require("./components/keyboard-shortcuts-modal/KeyboardShortcutsModal");
|
|
26
27
|
const hierarchy_1 = require("./lib/hierarchy");
|
|
27
28
|
const template_1 = require("./lib/template");
|
|
28
29
|
const utils_1 = require("./lib/utils");
|
|
@@ -576,6 +577,23 @@ const getEditorMenus = (editor) => {
|
|
|
576
577
|
},
|
|
577
578
|
],
|
|
578
579
|
};
|
|
579
|
-
|
|
580
|
+
const help = {
|
|
581
|
+
id: 'help',
|
|
582
|
+
label: 'Help',
|
|
583
|
+
isEnabled: true,
|
|
584
|
+
submenu: [
|
|
585
|
+
{
|
|
586
|
+
id: 'help-keyboard-shortcuts',
|
|
587
|
+
label: 'Keyboard shortcuts',
|
|
588
|
+
isEnabled: true,
|
|
589
|
+
shortcut: {
|
|
590
|
+
mac: 'CommandOrControl+Shift+/',
|
|
591
|
+
pc: 'CommandOrControl+Shift+/',
|
|
592
|
+
},
|
|
593
|
+
run: () => (0, KeyboardShortcutsModal_1.openKeyboardShortcuts)(view),
|
|
594
|
+
},
|
|
595
|
+
],
|
|
596
|
+
};
|
|
597
|
+
return [edit, insert, metadata, format, help];
|
|
580
598
|
};
|
|
581
599
|
exports.getEditorMenus = getEditorMenus;
|
package/dist/cjs/versions.js
CHANGED
|
@@ -55,14 +55,11 @@ function createSubViewAsync(props, Component, componentProps, node, getPos, view
|
|
|
55
55
|
const container = document.createElement('div');
|
|
56
56
|
const Wrapped = createView(props, Component, componentProps, node, getPos, view, classNames, container);
|
|
57
57
|
const root = (0, client_1.createRoot)(container);
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
(
|
|
61
|
-
root.render(react_1.default.createElement(Wrapped, null));
|
|
62
|
-
});
|
|
63
|
-
resolve(container);
|
|
58
|
+
return new Promise((resolve) => {
|
|
59
|
+
(0, react_dom_1.flushSync)(() => {
|
|
60
|
+
root.render(react_1.default.createElement(Wrapped, null));
|
|
64
61
|
});
|
|
62
|
+
resolve(container);
|
|
65
63
|
});
|
|
66
|
-
return res;
|
|
67
64
|
}
|
|
68
65
|
exports.default = createSubView;
|
|
@@ -16,10 +16,10 @@
|
|
|
16
16
|
import { InspectorTab, InspectorTabList } from '@manuscripts/style-guide';
|
|
17
17
|
import React from 'react';
|
|
18
18
|
import styled from 'styled-components';
|
|
19
|
-
export const ModalTabs = ({ tabLabels, tabErrorIndicators, tabWarningIndicators, }) => (React.createElement(StyledTabList,
|
|
19
|
+
export const ModalTabs = ({ tabLabels, tabErrorIndicators, tabWarningIndicators, }) => (React.createElement(StyledTabList, { "data-cy": "ModalTabs" }, tabLabels.map((label, i) => {
|
|
20
20
|
const hasError = tabErrorIndicators?.[i];
|
|
21
21
|
const showWarning = tabWarningIndicators?.[i] && !hasError;
|
|
22
|
-
return (React.createElement(StyledTab, { key: label },
|
|
22
|
+
return (React.createElement(StyledTab, { key: label, "data-cy": "ModalTab" },
|
|
23
23
|
label,
|
|
24
24
|
(showWarning || hasError) && (React.createElement(TabIndicatorGroup, { role: "presentation" },
|
|
25
25
|
showWarning ? React.createElement(TabWarningDot, { "aria-hidden": true }) : null,
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* © 2025 Atypon Systems LLC
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
import { Shortcut, ShortcutConnector } from '@manuscripts/style-guide';
|
|
17
|
+
import React from 'react';
|
|
18
|
+
import { isMac } from '../../lib/platform';
|
|
19
|
+
const keyMap = {
|
|
20
|
+
CommandOrControl: isMac ? '⌘' : 'Ctrl',
|
|
21
|
+
Option: isMac ? '⌥' : 'Alt',
|
|
22
|
+
Shift: isMac ? '⇧' : 'Shift',
|
|
23
|
+
ArrowUp: '↑',
|
|
24
|
+
ArrowDown: '↓',
|
|
25
|
+
ArrowLeft: '←',
|
|
26
|
+
ArrowRight: '→',
|
|
27
|
+
BracketLeft: '[',
|
|
28
|
+
BracketRight: ']',
|
|
29
|
+
Escape: 'Esc',
|
|
30
|
+
Tab: 'Tab',
|
|
31
|
+
Enter: '↵',
|
|
32
|
+
};
|
|
33
|
+
export const formattedShortCut = (accelerator) => {
|
|
34
|
+
const parts = accelerator.split('+').map((p) => p.trim());
|
|
35
|
+
return (React.createElement(React.Fragment, null, parts.map((part, index) => {
|
|
36
|
+
const content = keyMap[part] ?? part;
|
|
37
|
+
return (React.createElement(React.Fragment, { key: `${part}-${index}` },
|
|
38
|
+
React.createElement(Shortcut, null, content),
|
|
39
|
+
index < parts.length - 1 && (React.createElement(ShortcutConnector, null, "+"))));
|
|
40
|
+
})));
|
|
41
|
+
};
|
|
@@ -0,0 +1,157 @@
|
|
|
1
|
+
import { ButtonGroup, CloseButton, InspectorTabPanel, InspectorTabPanels, InspectorTabs, ModalBody, ModalContainer, ModalHeader, ModalSidebar, ModalSidebarHeader, ModalSidebarTitle, PrimaryButton, SidebarContent, StyledModal, useFocusCycle, } from '@manuscripts/style-guide';
|
|
2
|
+
import React, { useRef, useState } from 'react';
|
|
3
|
+
import styled, { ThemeProvider } from 'styled-components';
|
|
4
|
+
import { isMac } from '../../lib/platform';
|
|
5
|
+
import { getEditorProps } from '../../plugins/editor-props';
|
|
6
|
+
import { createSubViewAsync } from '../../views/ReactSubView';
|
|
7
|
+
import { ModalTabs } from '../authors-affiliations/ModalTabs';
|
|
8
|
+
import { formattedShortCut } from './FormattedShortcut';
|
|
9
|
+
import { EDITOR_KEYBOARD_SHORTCUT_TABS } from './keyboard-shortcuts';
|
|
10
|
+
const TAB_LABELS = EDITOR_KEYBOARD_SHORTCUT_TABS.map((t) => t.label);
|
|
11
|
+
const KEYBOARD_SHORTCUTS_MODAL_TITLE_ID = 'keyboard-shortcuts-modal-title';
|
|
12
|
+
export const KEYBOARD_SHORTCUTS_MODAL_ID = 'keyboard-shortcuts-modal';
|
|
13
|
+
export const KeyboardShortcutsModal = ({ editorProps, isOpen, onClose, }) => {
|
|
14
|
+
const [tabIndex, setTabIndex] = useState(0);
|
|
15
|
+
const containerRef = useRef(null);
|
|
16
|
+
useFocusCycle(containerRef, isOpen);
|
|
17
|
+
return (React.createElement(ThemeProvider, { theme: editorProps.theme },
|
|
18
|
+
React.createElement(StyledModal, { isOpen: isOpen, onRequestClose: onClose, shouldCloseOnOverlayClick: true, ariaLabelledby: KEYBOARD_SHORTCUTS_MODAL_TITLE_ID, id: KEYBOARD_SHORTCUTS_MODAL_ID },
|
|
19
|
+
React.createElement(ModalContainer, { ref: containerRef },
|
|
20
|
+
React.createElement(ModalHeader, null,
|
|
21
|
+
React.createElement(CloseButton, { onClick: onClose, "data-cy": "modal-close-button" })),
|
|
22
|
+
React.createElement(StyledModalBody, null,
|
|
23
|
+
React.createElement(StyledModalSidebar, null,
|
|
24
|
+
React.createElement(StyledModalSidebarHeader, null,
|
|
25
|
+
React.createElement(StyledModalSidebarTitle, { as: "h2", id: KEYBOARD_SHORTCUTS_MODAL_TITLE_ID }, "Keyboard shortcuts")),
|
|
26
|
+
React.createElement(StyledSidebarContent, null,
|
|
27
|
+
React.createElement(ShortcutTabs, { selectedIndex: tabIndex, onChange: setTabIndex },
|
|
28
|
+
React.createElement(ModalTabsWrapper, null,
|
|
29
|
+
React.createElement(ModalTabs, { tabLabels: TAB_LABELS })),
|
|
30
|
+
React.createElement(InspectorTabPanels, null, EDITOR_KEYBOARD_SHORTCUT_TABS.map((tab) => (React.createElement(ShortcutTabPanel, { key: tab.id }, tab.sections.map((section, sectionIndex) => (React.createElement(Section, { key: `${tab.id}:${sectionIndex}` },
|
|
31
|
+
React.createElement(SectionTitle, null, section.title),
|
|
32
|
+
React.createElement(ShortcutTable, null, section.rows.map((row, rowIndex) => (React.createElement(ShortcutRow, { key: `${tab.id}-${sectionIndex}-${rowIndex}` },
|
|
33
|
+
React.createElement(ShortcutLabel, null, row.label),
|
|
34
|
+
React.createElement(ShortcutKeys, null, formattedShortCut(isMac ? row.shortcut.mac : row.shortcut.pc))))))))))))))),
|
|
35
|
+
React.createElement(ButtonsContainer, null,
|
|
36
|
+
React.createElement(PrimaryButton, { onClick: onClose }, "Close"))))))));
|
|
37
|
+
};
|
|
38
|
+
const ShortcutTabs = styled(InspectorTabs) `
|
|
39
|
+
display: flex;
|
|
40
|
+
flex-direction: column;
|
|
41
|
+
min-height: 0;
|
|
42
|
+
`;
|
|
43
|
+
const ModalTabsWrapper = styled('div') `
|
|
44
|
+
margin: 0 ${(props) => props.theme.grid.unit * 8}px ${(props) => props.theme.grid.unit * 3}px;
|
|
45
|
+
`;
|
|
46
|
+
const ShortcutTabPanel = styled(InspectorTabPanel).attrs({
|
|
47
|
+
tabIndex: -1,
|
|
48
|
+
unmount: false,
|
|
49
|
+
}) `
|
|
50
|
+
margin-top: ${(props) => props.theme.grid.unit * 3}px;
|
|
51
|
+
overflow-y: auto;
|
|
52
|
+
flex: 1;
|
|
53
|
+
min-height: 0;
|
|
54
|
+
`;
|
|
55
|
+
const StyledModalSidebar = styled(ModalSidebar) `
|
|
56
|
+
position: relative;
|
|
57
|
+
background: white;
|
|
58
|
+
max-width: none;
|
|
59
|
+
width: min(664px, 90vw);
|
|
60
|
+
display: flex;
|
|
61
|
+
flex-direction: column;
|
|
62
|
+
padding: 0;
|
|
63
|
+
`;
|
|
64
|
+
const StyledModalSidebarHeader = styled(ModalSidebarHeader) `
|
|
65
|
+
margin: 0 ${(props) => props.theme.grid.unit * 8}px;
|
|
66
|
+
padding: 0;
|
|
67
|
+
`;
|
|
68
|
+
const StyledModalSidebarTitle = styled(ModalSidebarTitle) `
|
|
69
|
+
margin: ${(props) => props.theme.grid.unit * 6}px 0;
|
|
70
|
+
padding: 0;
|
|
71
|
+
`;
|
|
72
|
+
const StyledModalBody = styled(ModalBody) `
|
|
73
|
+
flex: 1;
|
|
74
|
+
min-height: 0;
|
|
75
|
+
display: flex;
|
|
76
|
+
flex-direction: column;
|
|
77
|
+
`;
|
|
78
|
+
const StyledSidebarContent = styled(SidebarContent) `
|
|
79
|
+
display: flex;
|
|
80
|
+
flex-direction: column;
|
|
81
|
+
overflow: hidden;
|
|
82
|
+
flex: 1;
|
|
83
|
+
min-height: 0;
|
|
84
|
+
gap: ${(props) => props.theme.grid.unit * 2}px;
|
|
85
|
+
padding: 0;
|
|
86
|
+
`;
|
|
87
|
+
const Section = styled.section `
|
|
88
|
+
margin: 0 0 ${(props) => props.theme.grid.unit * 4}px;
|
|
89
|
+
|
|
90
|
+
&:last-child {
|
|
91
|
+
margin-bottom: 0;
|
|
92
|
+
}
|
|
93
|
+
`;
|
|
94
|
+
const SectionTitle = styled.h3 `
|
|
95
|
+
margin: 0 ${(props) => props.theme.grid.unit * 8}px ${(props) => props.theme.grid.unit * 2}px;
|
|
96
|
+
font-size: ${(props) => props.theme.font.size.large};
|
|
97
|
+
font-weight: ${(props) => props.theme.font.weight.normal};
|
|
98
|
+
line-height: ${(props) => props.theme.font.lineHeight.large};
|
|
99
|
+
color: ${(props) => props.theme.colors.text.greyMuted};
|
|
100
|
+
`;
|
|
101
|
+
const ShortcutTable = styled.div `
|
|
102
|
+
border-collapse: collapse;
|
|
103
|
+
font-size: ${(props) => props.theme.font.size.normal};
|
|
104
|
+
margin: 0 ${(props) => props.theme.grid.unit * 8}px;
|
|
105
|
+
`;
|
|
106
|
+
const ShortcutRow = styled.div `
|
|
107
|
+
display: flex;
|
|
108
|
+
justify-content: space-between;
|
|
109
|
+
align-items: center;
|
|
110
|
+
padding: ${({ theme }) => theme.grid.unit * 1.5}px 0;
|
|
111
|
+
`;
|
|
112
|
+
const ShortcutLabel = styled.div `
|
|
113
|
+
padding: ${(props) => props.theme.grid.unit * 1.5}px
|
|
114
|
+
${(props) => props.theme.grid.unit * 2}px
|
|
115
|
+
${(props) => props.theme.grid.unit * 1.5}px 0;
|
|
116
|
+
vertical-align: top;
|
|
117
|
+
color: ${(props) => props.theme.colors.text.secondary};
|
|
118
|
+
`;
|
|
119
|
+
const ShortcutKeys = styled.div `
|
|
120
|
+
padding: ${(props) => props.theme.grid.unit * 1.5}px 0;
|
|
121
|
+
vertical-align: top;
|
|
122
|
+
text-align: right;
|
|
123
|
+
white-space: nowrap;
|
|
124
|
+
font-variant-numeric: tabular-nums;
|
|
125
|
+
`;
|
|
126
|
+
const ButtonsContainer = styled(ButtonGroup) `
|
|
127
|
+
padding: ${(props) => props.theme.grid.unit * 4}px 0;
|
|
128
|
+
margin: 0 ${(props) => props.theme.grid.unit * 8}px;
|
|
129
|
+
flex-shrink: 0;
|
|
130
|
+
`;
|
|
131
|
+
let dialog = null;
|
|
132
|
+
export async function openKeyboardShortcuts(view) {
|
|
133
|
+
if (!view || dialog) {
|
|
134
|
+
return;
|
|
135
|
+
}
|
|
136
|
+
const { state } = view;
|
|
137
|
+
const editorProps = getEditorProps(state);
|
|
138
|
+
const cleanup = () => {
|
|
139
|
+
if (dialog) {
|
|
140
|
+
dialog.remove();
|
|
141
|
+
dialog = null;
|
|
142
|
+
}
|
|
143
|
+
const modal = document.getElementById(KEYBOARD_SHORTCUTS_MODAL_ID);
|
|
144
|
+
if (modal) {
|
|
145
|
+
modal.remove();
|
|
146
|
+
}
|
|
147
|
+
requestAnimationFrame(() => {
|
|
148
|
+
view.focus();
|
|
149
|
+
});
|
|
150
|
+
};
|
|
151
|
+
dialog = await createSubViewAsync(editorProps, KeyboardShortcutsModal, {
|
|
152
|
+
editorProps,
|
|
153
|
+
isOpen: true,
|
|
154
|
+
onClose: cleanup,
|
|
155
|
+
}, state.doc, () => -1, view);
|
|
156
|
+
document.body.appendChild(dialog);
|
|
157
|
+
}
|
|
@@ -0,0 +1,246 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* © 2025 Atypon Systems LLC
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
export const EDITOR_KEYBOARD_SHORTCUT_TABS = [
|
|
17
|
+
{
|
|
18
|
+
id: 'text-editing',
|
|
19
|
+
label: 'Text editing',
|
|
20
|
+
sections: [
|
|
21
|
+
{
|
|
22
|
+
title: 'Formatting',
|
|
23
|
+
rows: [
|
|
24
|
+
{
|
|
25
|
+
label: 'Bold',
|
|
26
|
+
shortcut: { mac: 'CommandOrControl+B', pc: 'CommandOrControl+B' },
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
label: 'Italic',
|
|
30
|
+
shortcut: { mac: 'CommandOrControl+I', pc: 'CommandOrControl+I' },
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
label: 'Underline',
|
|
34
|
+
shortcut: { mac: 'CommandOrControl+U', pc: 'CommandOrControl+U' },
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
label: 'Strikethrough',
|
|
38
|
+
shortcut: {
|
|
39
|
+
mac: 'CommandOrControl+Shift+X',
|
|
40
|
+
pc: 'CommandOrControl+Shift+X',
|
|
41
|
+
},
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
label: 'Superscript',
|
|
45
|
+
shortcut: {
|
|
46
|
+
mac: 'Option+CommandOrControl+=',
|
|
47
|
+
pc: 'CommandOrControl+Option+=',
|
|
48
|
+
},
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
label: 'Subscript',
|
|
52
|
+
shortcut: {
|
|
53
|
+
mac: 'Option+CommandOrControl+-',
|
|
54
|
+
pc: 'CommandOrControl+Option+-',
|
|
55
|
+
},
|
|
56
|
+
},
|
|
57
|
+
],
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
title: 'General',
|
|
61
|
+
rows: [
|
|
62
|
+
{
|
|
63
|
+
label: 'Select all',
|
|
64
|
+
shortcut: { mac: 'CommandOrControl+A', pc: 'CommandOrControl+A' },
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
label: 'Undo',
|
|
68
|
+
shortcut: { mac: 'CommandOrControl+Z', pc: 'CommandOrControl+Z' },
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
label: 'Redo',
|
|
72
|
+
shortcut: {
|
|
73
|
+
mac: 'Shift+CommandOrControl+Z',
|
|
74
|
+
pc: 'CommandOrControl+Y',
|
|
75
|
+
},
|
|
76
|
+
},
|
|
77
|
+
{
|
|
78
|
+
label: 'Activate search',
|
|
79
|
+
shortcut: {
|
|
80
|
+
mac: 'CommandOrControl+F',
|
|
81
|
+
pc: 'CommandOrControl+F',
|
|
82
|
+
},
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
label: 'Activate search/replace',
|
|
86
|
+
shortcut: {
|
|
87
|
+
mac: 'CommandOrControl+Shift+H',
|
|
88
|
+
pc: 'CommandOrControl+Shift+H',
|
|
89
|
+
},
|
|
90
|
+
},
|
|
91
|
+
],
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
title: 'Enter',
|
|
95
|
+
rows: [
|
|
96
|
+
{
|
|
97
|
+
label: 'Insert line break',
|
|
98
|
+
shortcut: { mac: 'Shift+Enter', pc: 'Shift+Enter' },
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
label: 'Insert section',
|
|
102
|
+
shortcut: {
|
|
103
|
+
mac: 'CommandOrControl+Enter',
|
|
104
|
+
pc: 'CommandOrControl+Enter',
|
|
105
|
+
},
|
|
106
|
+
},
|
|
107
|
+
{
|
|
108
|
+
label: 'Insert sub section',
|
|
109
|
+
shortcut: {
|
|
110
|
+
mac: 'Shift+CommandOrControl+Enter',
|
|
111
|
+
pc: 'Shift+CommandOrControl+Enter',
|
|
112
|
+
},
|
|
113
|
+
},
|
|
114
|
+
],
|
|
115
|
+
},
|
|
116
|
+
{
|
|
117
|
+
title: 'Lists',
|
|
118
|
+
rows: [
|
|
119
|
+
{
|
|
120
|
+
label: 'New list item',
|
|
121
|
+
shortcut: { mac: 'Enter', pc: 'Enter' },
|
|
122
|
+
},
|
|
123
|
+
{
|
|
124
|
+
label: 'Indent list item',
|
|
125
|
+
shortcut: { mac: 'CommandOrControl+]', pc: 'CommandOrControl+]' },
|
|
126
|
+
},
|
|
127
|
+
{
|
|
128
|
+
label: 'Outdent list item',
|
|
129
|
+
shortcut: { mac: 'CommandOrControl+[', pc: 'CommandOrControl+[' },
|
|
130
|
+
},
|
|
131
|
+
{
|
|
132
|
+
label: 'Ordered list',
|
|
133
|
+
shortcut: {
|
|
134
|
+
mac: 'CommandOrControl+Option+O',
|
|
135
|
+
pc: 'CommandOrControl+Option+O',
|
|
136
|
+
},
|
|
137
|
+
},
|
|
138
|
+
{
|
|
139
|
+
label: 'Bullet list',
|
|
140
|
+
shortcut: {
|
|
141
|
+
mac: 'CommandOrControl+Option+K',
|
|
142
|
+
pc: 'CommandOrControl+Option+K',
|
|
143
|
+
},
|
|
144
|
+
},
|
|
145
|
+
],
|
|
146
|
+
},
|
|
147
|
+
],
|
|
148
|
+
},
|
|
149
|
+
{
|
|
150
|
+
id: 'insert-elements',
|
|
151
|
+
label: 'Insert elements',
|
|
152
|
+
sections: [
|
|
153
|
+
{
|
|
154
|
+
title: 'Insert',
|
|
155
|
+
rows: [
|
|
156
|
+
{
|
|
157
|
+
label: 'Insert figure',
|
|
158
|
+
shortcut: {
|
|
159
|
+
mac: 'CommandOrControl + Option + P',
|
|
160
|
+
pc: 'CommandOrControl + Option + P',
|
|
161
|
+
},
|
|
162
|
+
},
|
|
163
|
+
{
|
|
164
|
+
label: 'Insert table',
|
|
165
|
+
shortcut: {
|
|
166
|
+
mac: 'CommandOrControl + Option + T',
|
|
167
|
+
pc: 'CommandOrControl + Option + T',
|
|
168
|
+
},
|
|
169
|
+
},
|
|
170
|
+
{
|
|
171
|
+
label: 'Insert equation block',
|
|
172
|
+
shortcut: {
|
|
173
|
+
mac: 'CommandOrControl + Option + E',
|
|
174
|
+
pc: 'CommandOrControl + Option + E',
|
|
175
|
+
},
|
|
176
|
+
},
|
|
177
|
+
{
|
|
178
|
+
label: 'Insert box',
|
|
179
|
+
shortcut: {
|
|
180
|
+
mac: 'CommandOrControl + Option + B',
|
|
181
|
+
pc: 'CommandOrControl + Option + B',
|
|
182
|
+
},
|
|
183
|
+
},
|
|
184
|
+
{
|
|
185
|
+
label: 'Insert link',
|
|
186
|
+
shortcut: {
|
|
187
|
+
mac: 'CommandOrControl + Option + H',
|
|
188
|
+
pc: 'CommandOrControl + Option + H',
|
|
189
|
+
},
|
|
190
|
+
},
|
|
191
|
+
{
|
|
192
|
+
label: 'Insert footnote',
|
|
193
|
+
shortcut: {
|
|
194
|
+
mac: 'CommandOrControl + Option + F',
|
|
195
|
+
pc: 'CommandOrControl + Option + F',
|
|
196
|
+
},
|
|
197
|
+
},
|
|
198
|
+
{
|
|
199
|
+
label: 'Insert citation',
|
|
200
|
+
shortcut: {
|
|
201
|
+
mac: 'CommandOrControl + Option + C',
|
|
202
|
+
pc: 'CommandOrControl + Option + C',
|
|
203
|
+
},
|
|
204
|
+
},
|
|
205
|
+
{
|
|
206
|
+
label: 'Insert cross-reference',
|
|
207
|
+
shortcut: {
|
|
208
|
+
mac: 'CommandOrControl + Option + R',
|
|
209
|
+
pc: 'CommandOrControl + Option + R',
|
|
210
|
+
},
|
|
211
|
+
},
|
|
212
|
+
{
|
|
213
|
+
label: 'Insert Inline equation',
|
|
214
|
+
shortcut: {
|
|
215
|
+
mac: 'Shift + CommandOrControl + Option + E',
|
|
216
|
+
pc: 'Shift + CommandOrControl + E',
|
|
217
|
+
},
|
|
218
|
+
},
|
|
219
|
+
],
|
|
220
|
+
},
|
|
221
|
+
],
|
|
222
|
+
},
|
|
223
|
+
{
|
|
224
|
+
id: 'navigation',
|
|
225
|
+
label: 'Navigation',
|
|
226
|
+
sections: [
|
|
227
|
+
{
|
|
228
|
+
title: 'Navigation',
|
|
229
|
+
rows: [
|
|
230
|
+
{
|
|
231
|
+
label: 'Next table cell / focus nearest element',
|
|
232
|
+
shortcut: { mac: 'Tab', pc: 'Tab' },
|
|
233
|
+
},
|
|
234
|
+
{
|
|
235
|
+
label: 'Previous table cell / focus nearest element back',
|
|
236
|
+
shortcut: { mac: 'Shift + Tab', pc: 'Shift + Tab' },
|
|
237
|
+
},
|
|
238
|
+
{
|
|
239
|
+
label: 'Exit editor to container',
|
|
240
|
+
shortcut: { mac: 'Escape', pc: 'Escape' },
|
|
241
|
+
},
|
|
242
|
+
],
|
|
243
|
+
},
|
|
244
|
+
],
|
|
245
|
+
},
|
|
246
|
+
];
|
package/dist/es/index.js
CHANGED
|
@@ -18,6 +18,7 @@ export { ManuscriptOutline } from './components/outline/ManuscriptOutline';
|
|
|
18
18
|
export { OutlineItemIcon } from './components/outline/Outline';
|
|
19
19
|
export { TypeSelector } from './components/toolbar/type-selector/TypeSelector';
|
|
20
20
|
export { default as LanguageDropdown } from './components/LanguageDropdown';
|
|
21
|
+
export { KeyboardShortcutsModal, openKeyboardShortcuts, } from './components/keyboard-shortcuts-modal/KeyboardShortcutsModal';
|
|
21
22
|
export * from './components/toolbar/ListMenuItem';
|
|
22
23
|
export * from './components/toolbar/InsertTableDialog';
|
|
23
24
|
export * from './menus';
|
package/dist/es/lib/platform.js
CHANGED
|
@@ -13,4 +13,4 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
export const isMac = /Mac/.test(
|
|
16
|
+
export const isMac = typeof navigator !== 'undefined' && /Mac/.test(navigator.userAgent);
|
package/dist/es/menus.js
CHANGED
|
@@ -20,6 +20,7 @@ import { activateSearchReplace, addInlineComment, blockActive, canInsert, copySe
|
|
|
20
20
|
import { openInsertTableDialog } from './components/toolbar/InsertTableDialog';
|
|
21
21
|
import { ListMenuItem } from './components/toolbar/ListMenuItem';
|
|
22
22
|
import { openInsertSpecialCharacterDialog } from './components/views/InsertSpecialCharacter';
|
|
23
|
+
import { openKeyboardShortcuts } from './components/keyboard-shortcuts-modal/KeyboardShortcutsModal';
|
|
23
24
|
import { deleteClosestParentElement, findClosestParentElementNodeName, } from './lib/hierarchy';
|
|
24
25
|
import { templateAllows } from './lib/template';
|
|
25
26
|
import { isEditAllowed } from './lib/utils';
|
|
@@ -573,5 +574,22 @@ export const getEditorMenus = (editor) => {
|
|
|
573
574
|
},
|
|
574
575
|
],
|
|
575
576
|
};
|
|
576
|
-
|
|
577
|
+
const help = {
|
|
578
|
+
id: 'help',
|
|
579
|
+
label: 'Help',
|
|
580
|
+
isEnabled: true,
|
|
581
|
+
submenu: [
|
|
582
|
+
{
|
|
583
|
+
id: 'help-keyboard-shortcuts',
|
|
584
|
+
label: 'Keyboard shortcuts',
|
|
585
|
+
isEnabled: true,
|
|
586
|
+
shortcut: {
|
|
587
|
+
mac: 'CommandOrControl+Shift+/',
|
|
588
|
+
pc: 'CommandOrControl+Shift+/',
|
|
589
|
+
},
|
|
590
|
+
run: () => openKeyboardShortcuts(view),
|
|
591
|
+
},
|
|
592
|
+
],
|
|
593
|
+
};
|
|
594
|
+
return [edit, insert, metadata, format, help];
|
|
577
595
|
};
|
package/dist/es/versions.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const VERSION = '3.12.
|
|
1
|
+
export const VERSION = '3.12.66';
|
|
2
2
|
export const MATHJAX_VERSION = '3.2.2';
|
|
@@ -49,14 +49,11 @@ export function createSubViewAsync(props, Component, componentProps, node, getPo
|
|
|
49
49
|
const container = document.createElement('div');
|
|
50
50
|
const Wrapped = createView(props, Component, componentProps, node, getPos, view, classNames, container);
|
|
51
51
|
const root = createRoot(container);
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
root.render(React.createElement(Wrapped, null));
|
|
56
|
-
});
|
|
57
|
-
resolve(container);
|
|
52
|
+
return new Promise((resolve) => {
|
|
53
|
+
flushSync(() => {
|
|
54
|
+
root.render(React.createElement(Wrapped, null));
|
|
58
55
|
});
|
|
56
|
+
resolve(container);
|
|
59
57
|
});
|
|
60
|
-
return res;
|
|
61
58
|
}
|
|
62
59
|
export default createSubView;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* © 2025 Atypon Systems LLC
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
import { JSX } from 'react';
|
|
17
|
+
export declare const formattedShortCut: (accelerator: string) => JSX.Element;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { EditorView } from 'prosemirror-view';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import type { EditorProps } from '../../configs/ManuscriptsEditor';
|
|
4
|
+
export declare const KEYBOARD_SHORTCUTS_MODAL_ID = "keyboard-shortcuts-modal";
|
|
5
|
+
export type KeyboardShortcutsModalProps = {
|
|
6
|
+
editorProps: EditorProps;
|
|
7
|
+
isOpen: boolean;
|
|
8
|
+
onClose: () => void;
|
|
9
|
+
};
|
|
10
|
+
export declare const KeyboardShortcutsModal: React.FC<KeyboardShortcutsModalProps>;
|
|
11
|
+
export declare function openKeyboardShortcuts(view?: EditorView): Promise<void>;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* © 2025 Atypon Systems LLC
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
type EditorShortcutRow = {
|
|
17
|
+
label: string;
|
|
18
|
+
shortcut: {
|
|
19
|
+
mac: string;
|
|
20
|
+
pc: string;
|
|
21
|
+
};
|
|
22
|
+
};
|
|
23
|
+
type EditorShortcutSection = {
|
|
24
|
+
title: string;
|
|
25
|
+
rows: EditorShortcutRow[];
|
|
26
|
+
};
|
|
27
|
+
type EditorShortcutTab = {
|
|
28
|
+
id: string;
|
|
29
|
+
label: string;
|
|
30
|
+
sections: EditorShortcutSection[];
|
|
31
|
+
};
|
|
32
|
+
export declare const EDITOR_KEYBOARD_SHORTCUT_TABS: EditorShortcutTab[];
|
|
33
|
+
export {};
|
package/dist/types/index.d.ts
CHANGED
|
@@ -18,6 +18,7 @@ export { ManuscriptOutline } from './components/outline/ManuscriptOutline';
|
|
|
18
18
|
export { OutlineItemIcon } from './components/outline/Outline';
|
|
19
19
|
export { TypeSelector } from './components/toolbar/type-selector/TypeSelector';
|
|
20
20
|
export { default as LanguageDropdown } from './components/LanguageDropdown';
|
|
21
|
+
export { KeyboardShortcutsModal, openKeyboardShortcuts, } from './components/keyboard-shortcuts-modal/KeyboardShortcutsModal';
|
|
21
22
|
export * from './components/toolbar/ListMenuItem';
|
|
22
23
|
export * from './components/toolbar/InsertTableDialog';
|
|
23
24
|
export * from './menus';
|
package/dist/types/versions.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "3.12.
|
|
1
|
+
export declare const VERSION = "3.12.66";
|
|
2
2
|
export declare const MATHJAX_VERSION = "3.2.2";
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@manuscripts/body-editor",
|
|
3
3
|
"description": "Prosemirror components for editing and viewing manuscripts",
|
|
4
|
-
"version": "3.12.
|
|
4
|
+
"version": "3.12.66",
|
|
5
5
|
"repository": "github:Atypon-OpenSource/manuscripts-body-editor",
|
|
6
6
|
"license": "Apache-2.0",
|
|
7
7
|
"main": "dist/cjs",
|
|
@@ -40,7 +40,7 @@
|
|
|
40
40
|
"@citation-js/plugin-pubmed": "0.3.0",
|
|
41
41
|
"@citation-js/plugin-ris": "0.7.18",
|
|
42
42
|
"@iarna/word-count": "1.1.2",
|
|
43
|
-
"@manuscripts/style-guide": "3.5.
|
|
43
|
+
"@manuscripts/style-guide": "3.5.32",
|
|
44
44
|
"@manuscripts/track-changes-plugin": "2.3.16",
|
|
45
45
|
"@manuscripts/transform": "4.3.52",
|
|
46
46
|
"@popperjs/core": "2.11.8",
|