@manuscripts/body-editor 2.0.9 → 2.0.11-JSR
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/configs/editor-plugins.js +3 -1
- package/dist/cjs/configs/editor-views.js +2 -0
- package/dist/cjs/plugins/objects.js +3 -3
- package/dist/cjs/plugins/section_title.js +50 -0
- package/dist/cjs/testing/default-editor-data.js +0 -1
- package/dist/cjs/versions.js +1 -1
- package/dist/cjs/views/bibliography_element.js +1 -1
- package/dist/cjs/views/citation_editable.js +8 -4
- package/dist/cjs/views/contributors.js +1 -1
- package/dist/cjs/views/inline_footnote.js +65 -45
- package/dist/cjs/views/section.js +79 -0
- package/dist/cjs/views/section_title.js +12 -2
- package/dist/es/configs/editor-plugins.js +3 -1
- package/dist/es/configs/editor-views.js +2 -0
- package/dist/es/plugins/objects.js +3 -3
- package/dist/es/plugins/section_title.js +47 -0
- package/dist/es/testing/default-editor-data.js +0 -1
- package/dist/es/versions.js +1 -1
- package/dist/es/views/bibliography_element.js +1 -1
- package/dist/es/views/citation_editable.js +8 -4
- package/dist/es/views/contributors.js +1 -1
- package/dist/es/views/inline_footnote.js +66 -46
- package/dist/es/views/section.js +71 -0
- package/dist/es/views/section_title.js +12 -2
- package/dist/types/components/outline/ManuscriptOutline.d.ts +0 -2
- package/dist/types/configs/ManuscriptsEditor.d.ts +1 -2
- package/dist/types/configs/editor-views.d.ts +1 -0
- package/dist/types/plugins/objects.d.ts +1 -5
- package/dist/types/plugins/section_title.d.ts +5 -0
- package/dist/types/versions.d.ts +1 -1
- package/dist/types/views/inline_footnote.d.ts +3 -1
- package/dist/types/views/section.d.ts +28 -0
- package/dist/types/views/section_title.d.ts +1 -1
- package/package.json +4 -4
- package/styles/AdvancedEditor.css +20 -272
- package/styles/Editor.css +7 -2
|
@@ -1,147 +1,22 @@
|
|
|
1
|
-
/* LVL 1 */
|
|
2
|
-
/*
|
|
3
|
-
This level is actually hidden in the editor
|
|
4
|
-
Next levels are shifted 'up' by 1
|
|
5
|
-
*/
|
|
6
|
-
.ProseMirror > div.body > section:not(.toc) {
|
|
7
|
-
counter-increment: level_1 0;
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
.ProseMirror > div > .block-section_title > h1 {
|
|
11
|
-
font-size: 16pt !important;
|
|
12
|
-
font-style: normal !important;
|
|
13
|
-
font-weight: bold !important;
|
|
14
|
-
color: #000 !important;
|
|
15
|
-
text-align: left;
|
|
16
|
-
margin-top: 8pt !important;
|
|
17
|
-
margin-bottom: 5pt !important;
|
|
18
|
-
line-height: 1.5;
|
|
19
|
-
text-indent: 0pt;
|
|
20
|
-
display: inline;
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
/* LVL 2 */
|
|
24
|
-
.ProseMirror > div.body > section:not(.toc) {
|
|
25
|
-
counter-increment: level_1;
|
|
26
|
-
counter-reset: level_2;
|
|
27
|
-
}
|
|
28
|
-
.ProseMirror > div > section > .block-section_title > h1 {
|
|
29
|
-
font-size: 15.75pt !important;
|
|
30
|
-
font-style: normal !important;
|
|
31
|
-
font-weight: bold !important;
|
|
32
|
-
color: #353535 !important;
|
|
33
|
-
text-align: left;
|
|
34
|
-
margin-top: 8pt !important;
|
|
35
|
-
margin-bottom: 5pt !important;
|
|
36
|
-
line-height: 24pt;
|
|
37
|
-
text-indent: 0pt;
|
|
38
|
-
display: inline;
|
|
39
|
-
}
|
|
40
|
-
.ProseMirror > div.body {
|
|
41
|
-
counter-reset: level_1;
|
|
42
|
-
}
|
|
43
1
|
.ProseMirror
|
|
44
2
|
> div.body
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
content:
|
|
3
|
+
section:not(.toc)
|
|
4
|
+
.block-section_title
|
|
5
|
+
h1.empty-node[data-placeholder]::before {
|
|
6
|
+
content: attr(data-section-number) '. ' attr(data-placeholder);
|
|
49
7
|
}
|
|
50
8
|
|
|
51
9
|
.ProseMirror
|
|
52
10
|
> div.body
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
content:
|
|
57
|
-
}
|
|
58
|
-
/* LVL 3 */
|
|
59
|
-
.ProseMirror > div.body > section > section:not(.toc) {
|
|
60
|
-
counter-increment: level_2;
|
|
61
|
-
counter-reset: level_3;
|
|
62
|
-
}
|
|
63
|
-
.ProseMirror > div > section > section > .block-section_title > h1 {
|
|
64
|
-
font-size: 13.5pt !important;
|
|
65
|
-
font-style: normal !important;
|
|
66
|
-
font-weight: 700 !important;
|
|
67
|
-
color: #353535 !important;
|
|
68
|
-
text-align: left;
|
|
69
|
-
margin-top: 8pt !important;
|
|
70
|
-
margin-bottom: 5pt !important;
|
|
71
|
-
line-height: 24pt;
|
|
72
|
-
text-indent: 0pt;
|
|
73
|
-
display: inline;
|
|
74
|
-
}
|
|
75
|
-
.ProseMirror
|
|
76
|
-
> div.body
|
|
77
|
-
> section
|
|
78
|
-
> section:not(.toc)
|
|
79
|
-
> .block-section_title
|
|
80
|
-
> h1::before {
|
|
81
|
-
content: counter(level_1, decimal) '.' counter(level_2, decimal) '. ';
|
|
82
|
-
}
|
|
83
|
-
.ProseMirror
|
|
84
|
-
> div.body
|
|
85
|
-
> section
|
|
86
|
-
> section:not(.toc)
|
|
87
|
-
> .block-section_title
|
|
88
|
-
> h1.empty-node[data-placeholder]::before {
|
|
89
|
-
content: counter(level_1, decimal) '.' counter(level_2, decimal) '. '
|
|
90
|
-
attr(data-placeholder);
|
|
91
|
-
}
|
|
92
|
-
/* LVL 4 */
|
|
93
|
-
.ProseMirror > div.body > section > section > section:not(.toc) {
|
|
94
|
-
counter-increment: level_3;
|
|
95
|
-
counter-reset: level_4;
|
|
96
|
-
}
|
|
97
|
-
.ProseMirror > div > section > section > section > .block-section_title > h1 {
|
|
98
|
-
font-size: 12pt !important;
|
|
99
|
-
font-style: normal !important;
|
|
100
|
-
font-weight: bold !important;
|
|
101
|
-
color: #000 !important;
|
|
102
|
-
text-align: left;
|
|
103
|
-
margin-top: 8pt !important;
|
|
104
|
-
margin-bottom: 5pt !important;
|
|
105
|
-
line-height: 1.5;
|
|
106
|
-
text-indent: 0pt;
|
|
107
|
-
display: inline;
|
|
108
|
-
}
|
|
109
|
-
.ProseMirror
|
|
110
|
-
> div.body
|
|
111
|
-
> section
|
|
112
|
-
> section
|
|
113
|
-
> section:not(.toc)
|
|
114
|
-
> .block-section_title
|
|
115
|
-
> h1::before {
|
|
116
|
-
content: counter(level_1, decimal) '.' counter(level_2, decimal) '.'
|
|
117
|
-
counter(level_3, decimal) '. ';
|
|
11
|
+
section:not(.toc)
|
|
12
|
+
.block-section_title
|
|
13
|
+
h1::before {
|
|
14
|
+
content: attr(data-section-number) '. ';
|
|
118
15
|
}
|
|
119
16
|
|
|
120
|
-
.ProseMirror
|
|
121
|
-
> div.body
|
|
122
|
-
> section
|
|
123
|
-
> section
|
|
124
|
-
> section:not(.toc)
|
|
125
|
-
> .block-section_title
|
|
126
|
-
> h1.empty-node[data-placeholder]::before {
|
|
127
|
-
content: counter(level_1, decimal) '.' counter(level_2, decimal) '.'
|
|
128
|
-
counter(level_3, decimal) '. ' attr(data-placeholder);
|
|
129
|
-
}
|
|
130
|
-
/* LVL 5 */
|
|
131
|
-
.ProseMirror > div.body > section > section > section > section:not(.toc) {
|
|
132
|
-
counter-increment: level_4;
|
|
133
|
-
counter-reset: level_5;
|
|
134
|
-
}
|
|
135
17
|
|
|
136
|
-
.ProseMirror
|
|
137
|
-
|
|
138
|
-
> section
|
|
139
|
-
> section
|
|
140
|
-
> section
|
|
141
|
-
> section
|
|
142
|
-
> .block-section_title
|
|
143
|
-
> h1 {
|
|
144
|
-
font-size: 12pt !important;
|
|
18
|
+
.ProseMirror > div .block-section_title > h1 {
|
|
19
|
+
font-size: 16pt !important;
|
|
145
20
|
font-style: normal !important;
|
|
146
21
|
font-weight: bold !important;
|
|
147
22
|
color: #000 !important;
|
|
@@ -152,147 +27,20 @@ Next levels are shifted 'up' by 1
|
|
|
152
27
|
text-indent: 0pt;
|
|
153
28
|
display: inline;
|
|
154
29
|
}
|
|
155
|
-
.ProseMirror
|
|
156
|
-
> div.body
|
|
157
|
-
> section
|
|
158
|
-
> section
|
|
159
|
-
> section
|
|
160
|
-
> section:not(.toc)
|
|
161
|
-
> .block-section_title
|
|
162
|
-
> h1::before {
|
|
163
|
-
content: counter(level_1, decimal) '.' counter(level_2, decimal) '.'
|
|
164
|
-
counter(level_3, decimal) '.' counter(level_4, decimal) '. ';
|
|
165
|
-
}
|
|
166
|
-
.ProseMirror
|
|
167
|
-
> div.body
|
|
168
|
-
> section
|
|
169
|
-
> section
|
|
170
|
-
> section
|
|
171
|
-
> section:not(.toc)
|
|
172
|
-
> .block-section_title
|
|
173
|
-
> h1.empty-node[data-placeholder]::before {
|
|
174
|
-
content: counter(level_1, decimal) '.' counter(level_2, decimal) '.'
|
|
175
|
-
counter(level_3, decimal) '.' counter(level_4, decimal) '. '
|
|
176
|
-
attr(data-placeholder);
|
|
177
|
-
}
|
|
178
|
-
/* LVL 6 */
|
|
179
|
-
.ProseMirror
|
|
180
|
-
> div.body
|
|
181
|
-
> section
|
|
182
|
-
> section
|
|
183
|
-
> section
|
|
184
|
-
> section
|
|
185
|
-
> section:not(.toc) {
|
|
186
|
-
counter-increment: level_5;
|
|
187
|
-
counter-reset: level_6;
|
|
188
|
-
}
|
|
189
|
-
.ProseMirror
|
|
190
|
-
> div
|
|
191
|
-
> section
|
|
192
|
-
> section
|
|
193
|
-
> section
|
|
194
|
-
> section
|
|
195
|
-
> section
|
|
196
|
-
> .block-section_title
|
|
197
|
-
> h1 {
|
|
30
|
+
.ProseMirror .block-section_title h1[data-title-level] {
|
|
198
31
|
font-size: 12pt !important;
|
|
199
|
-
font-style: normal !important;
|
|
200
|
-
font-weight: bold !important;
|
|
201
|
-
color: #000 !important;
|
|
202
|
-
text-align: left;
|
|
203
|
-
margin-top: 8pt !important;
|
|
204
|
-
margin-bottom: 5pt !important;
|
|
205
|
-
line-height: 1.5;
|
|
206
|
-
text-indent: 0pt;
|
|
207
|
-
display: inline;
|
|
208
32
|
}
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
> section
|
|
213
|
-
> section
|
|
214
|
-
> section
|
|
215
|
-
> section:not(.toc)
|
|
216
|
-
> .block-section_title
|
|
217
|
-
> h1::before {
|
|
218
|
-
content: counter(level_1, decimal) '.' counter(level_2, decimal) '.'
|
|
219
|
-
counter(level_3, decimal) '.' counter(level_4, decimal) '.'
|
|
220
|
-
counter(level_5, decimal) '. ';
|
|
221
|
-
}
|
|
222
|
-
.ProseMirror
|
|
223
|
-
> div.body
|
|
224
|
-
> section
|
|
225
|
-
> section
|
|
226
|
-
> section
|
|
227
|
-
> section
|
|
228
|
-
> section:not(.toc)
|
|
229
|
-
> .block-section_title
|
|
230
|
-
> h1.empty-node[data-placeholder]::before {
|
|
231
|
-
content: counter(level_1, decimal) '.' counter(level_2, decimal) '.'
|
|
232
|
-
counter(level_3, decimal) '.' counter(level_4, decimal) '.'
|
|
233
|
-
counter(level_5, decimal) '. ' attr(data-placeholder);
|
|
234
|
-
}
|
|
235
|
-
/* LVL 7 */
|
|
236
|
-
.ProseMirror
|
|
237
|
-
> div.body
|
|
238
|
-
> section
|
|
239
|
-
> section
|
|
240
|
-
> section
|
|
241
|
-
> section
|
|
242
|
-
> section
|
|
243
|
-
> section:not(.toc) {
|
|
244
|
-
counter-increment: level_6;
|
|
245
|
-
counter-reset: level_7;
|
|
246
|
-
}
|
|
247
|
-
.ProseMirror
|
|
248
|
-
> div
|
|
249
|
-
> section
|
|
250
|
-
> section
|
|
251
|
-
> section
|
|
252
|
-
> section
|
|
253
|
-
> section
|
|
254
|
-
> .block-section_title
|
|
255
|
-
> h1 {
|
|
256
|
-
font-size: 12pt !important;
|
|
257
|
-
font-style: normal !important;
|
|
258
|
-
font-weight: bold !important;
|
|
259
|
-
color: #000 !important;
|
|
260
|
-
text-align: left;
|
|
261
|
-
margin-top: 8pt !important;
|
|
262
|
-
margin-bottom: 5pt !important;
|
|
263
|
-
line-height: 1.5;
|
|
264
|
-
text-indent: 0pt;
|
|
265
|
-
display: inline;
|
|
266
|
-
}
|
|
267
|
-
.ProseMirror
|
|
268
|
-
> div.body
|
|
269
|
-
> section
|
|
270
|
-
> section
|
|
271
|
-
> section
|
|
272
|
-
> section
|
|
273
|
-
> section
|
|
274
|
-
> section:not(.toc)
|
|
275
|
-
> .block-section_title
|
|
276
|
-
> h1::before {
|
|
277
|
-
content: counter(level_1, decimal) '.' counter(level_2, decimal) '.'
|
|
278
|
-
counter(level_3, decimal) '.' counter(level_4, decimal) '.'
|
|
279
|
-
counter(level_5, decimal) '.' counter(level_6, decimal) '. ';
|
|
33
|
+
|
|
34
|
+
.ProseMirror .block-section_title h1[data-title-level='1'] {
|
|
35
|
+
font-size: 16pt !important;
|
|
280
36
|
}
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
> section
|
|
285
|
-
> section
|
|
286
|
-
> section
|
|
287
|
-
> section
|
|
288
|
-
> section:not(.toc)
|
|
289
|
-
> .block-section_title
|
|
290
|
-
> h1.empty-node[data-placeholder]::before {
|
|
291
|
-
content: counter(level_1, decimal) '.' counter(level_2, decimal) '.'
|
|
292
|
-
counter(level_3, decimal) '.' counter(level_4, decimal) '.'
|
|
293
|
-
counter(level_5, decimal) '.' counter(level_6, decimal) '. '
|
|
294
|
-
attr(data-placeholder);
|
|
37
|
+
|
|
38
|
+
.ProseMirror .block-section_title h1[data-title-level='2'] {
|
|
39
|
+
font-size: 13.5pt !important;
|
|
295
40
|
}
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
|
|
296
44
|
.ProseMirror div.backmatter::before {
|
|
297
45
|
content: '';
|
|
298
46
|
border-bottom: 1px dashed #c9c9c9;
|
package/styles/Editor.css
CHANGED
|
@@ -593,8 +593,13 @@
|
|
|
593
593
|
display: grid;
|
|
594
594
|
grid-template-columns: 52px auto 52px;
|
|
595
595
|
}
|
|
596
|
+
.ProseMirror .block-container.block-section {
|
|
597
|
+
position: relative;
|
|
598
|
+
display: grid;
|
|
599
|
+
grid-template-columns: auto;
|
|
600
|
+
}
|
|
596
601
|
|
|
597
|
-
.ProseMirror .block-container:hover {
|
|
602
|
+
.ProseMirror .block-container:not(.block-section):hover {
|
|
598
603
|
z-index: 2;
|
|
599
604
|
}
|
|
600
605
|
|
|
@@ -649,7 +654,7 @@
|
|
|
649
654
|
margin-top: 16px;
|
|
650
655
|
}
|
|
651
656
|
|
|
652
|
-
.ProseMirror .block-container:hover .block-gutter {
|
|
657
|
+
.ProseMirror .block-container:not(.block-section):hover .block-gutter {
|
|
653
658
|
opacity: 1;
|
|
654
659
|
z-index: 2;
|
|
655
660
|
}
|