@lblod/ember-rdfa-editor-lblod-plugins 4.0.2 → 5.0.1
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/CHANGELOG.md +24 -1
- package/addon/components/article-structure-plugin/structure-card.hbs +52 -18
- package/addon/components/article-structure-plugin/structure-card.ts +23 -2
- package/addon/components/hover-tooltip.hbs +8 -0
- package/addon/components/hover-tooltip.ts +39 -0
- package/addon/components/rdfa-date-plugin/card.hbs +1 -1
- package/addon/components/table-of-contents-plugin/ember-nodes/table-of-contents.ts +16 -1
- package/addon/plugins/article-structure-plugin/index.ts +12 -6
- package/addon/plugins/article-structure-plugin/structures/article-paragraph.ts +1 -0
- package/addon/plugins/article-structure-plugin/structures/article.ts +1 -0
- package/addon/plugins/article-structure-plugin/structures/chapter.ts +1 -0
- package/addon/plugins/article-structure-plugin/structures/section.ts +1 -0
- package/addon/plugins/article-structure-plugin/structures/subsection.ts +2 -0
- package/addon/plugins/article-structure-plugin/structures/title.ts +1 -0
- package/addon/plugins/besluit-plugin/commands/insert-title.ts +2 -2
- package/addon/plugins/rdfa-date-plugin/index.ts +1 -3
- package/addon/plugins/standard-template-plugin/index.ts +2 -2
- package/addon/plugins/standard-template-plugin/utils/nodes.ts +2 -2
- package/addon/plugins/table-of-contents-plugin/index.ts +2 -0
- package/app/components/hover-tooltip.js +1 -0
- package/components/article-structure-plugin/structure-card.d.ts +3 -1
- package/components/hover-tooltip.d.ts +18 -0
- package/package.json +1 -1
- package/plugins/article-structure-plugin/index.d.ts +6 -6
- package/plugins/rdfa-date-plugin/index.d.ts +1 -1
- package/plugins/standard-template-plugin/index.d.ts +1 -1
- package/plugins/standard-template-plugin/utils/nodes.d.ts +1 -1
- package/plugins/table-of-contents-plugin/index.d.ts +2 -0
- package/translations/en-US.yaml +14 -2
- package/translations/nl-BE.yaml +14 -2
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,26 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [5.0.1] - 2023-04-07
|
|
11
|
+
### Fixed
|
|
12
|
+
- fix deprecated use of modifier without specifying eagerness
|
|
13
|
+
- add missing translations
|
|
14
|
+
- make application route in dummy app a javascript file to avoid [issues](https://github.com/typed-ember/ember-cli-typescript/issues/780)
|
|
15
|
+
|
|
16
|
+
## [5.0.0] - 2023-04-07
|
|
17
|
+
|
|
18
|
+
### Added
|
|
19
|
+
- add a hover-tooltip utility component
|
|
20
|
+
- docs: add tooltips to the remove structure buttons
|
|
21
|
+
|
|
22
|
+
### Changed
|
|
23
|
+
- Change date labels based on designer feedback
|
|
24
|
+
- split out structure removal card into two buttons
|
|
25
|
+
|
|
26
|
+
### Fixed
|
|
27
|
+
- BREAKING: Rename decision title node from title to besluit_title to avoid conflicts
|
|
28
|
+
- properly initialize ember-intl
|
|
29
|
+
|
|
10
30
|
## [4.0.2] - 2023-04-04
|
|
11
31
|
|
|
12
32
|
### Fixed
|
|
@@ -35,6 +55,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
35
55
|
- Update schema on dummy page to make articles insertable in empty document
|
|
36
56
|
- Add padding to structure card
|
|
37
57
|
- Placeholder text when inserting date
|
|
58
|
+
- Feature/improve toc scroll
|
|
38
59
|
|
|
39
60
|
### Removed:
|
|
40
61
|
- Removal of prosemirror-plugin dependency of `CitationPlugin::CitationInsert` component.
|
|
@@ -391,7 +412,9 @@ add onclick handler to pencil icon in variable plugin
|
|
|
391
412
|
|
|
392
413
|
# Changelog
|
|
393
414
|
|
|
394
|
-
[unreleased]: https://github.com/lblod/ember-rdfa-editor-lblod-plugins/compare/
|
|
415
|
+
[unreleased]: https://github.com/lblod/ember-rdfa-editor-lblod-plugins/compare/v5.0.1...HEAD
|
|
416
|
+
[5.0.1]: https://github.com/lblod/ember-rdfa-editor-lblod-plugins/compare/v5.0.0...v5.0.1
|
|
417
|
+
[5.0.0]: https://github.com/lblod/ember-rdfa-editor-lblod-plugins/compare/v4.0.2...v5.0.0
|
|
395
418
|
[4.0.2]: https://github.com/lblod/ember-rdfa-editor-lblod-plugins/compare/v4.0.1...v4.0.2
|
|
396
419
|
[4.0.1]: https://github.com/lblod/ember-rdfa-editor-lblod-plugins/compare/v4.0.0...v4.0.1
|
|
397
420
|
[4.0.0]: https://github.com/lblod/ember-rdfa-editor-lblod-plugins/compare/v3.1.0...v4.0.0
|
|
@@ -26,24 +26,58 @@
|
|
|
26
26
|
</AuButton>
|
|
27
27
|
</Item>
|
|
28
28
|
<Item>
|
|
29
|
-
|
|
30
|
-
<
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
29
|
+
<AuButtonGroup>
|
|
30
|
+
<HoverTooltip>
|
|
31
|
+
<:hover as |hover|>
|
|
32
|
+
<AuButton
|
|
33
|
+
@icon="bin"
|
|
34
|
+
@iconAlignment="left"
|
|
35
|
+
@skin="link"
|
|
36
|
+
@alert={{true}}
|
|
37
|
+
@disabled={{this.currentStructureType.noUnwrap}}
|
|
38
|
+
aria-describedby="remove-tooltip"
|
|
39
|
+
{{hover.velcroHook}}
|
|
40
|
+
{{hover.handleHover}}
|
|
41
|
+
{{on 'click' (fn this.removeStructure false)}}>
|
|
42
|
+
{{this.remove}}
|
|
43
|
+
</AuButton>
|
|
44
|
+
</:hover>
|
|
45
|
+
<:tooltip as |tooltip|>
|
|
46
|
+
<AuPill
|
|
47
|
+
id="remove-tooltip"
|
|
48
|
+
role="tooltip"
|
|
49
|
+
{{tooltip}}
|
|
50
|
+
>
|
|
51
|
+
{{t 'article-structure-plugin.remove.help-text'}}
|
|
52
|
+
</AuPill>
|
|
53
|
+
</:tooltip>
|
|
54
|
+
</HoverTooltip>
|
|
55
|
+
<HoverTooltip>
|
|
56
|
+
<:hover as |hover|>
|
|
57
|
+
<AuButton
|
|
58
|
+
@icon="bin"
|
|
59
|
+
@iconAlignment="left"
|
|
60
|
+
@skin="link"
|
|
61
|
+
aria-describedby="remove-content-tooltip"
|
|
62
|
+
@alert={{true}}
|
|
63
|
+
{{hover.velcroHook}}
|
|
64
|
+
{{hover.handleHover}}
|
|
65
|
+
{{on 'click' (fn this.removeStructure true)}}>
|
|
66
|
+
{{this.removeWithContent}}
|
|
67
|
+
</AuButton>
|
|
68
|
+
</:hover>
|
|
69
|
+
<:tooltip as |tooltip|>
|
|
70
|
+
<AuPill
|
|
71
|
+
id="remove-content-tooltip"
|
|
72
|
+
role="tooltip"
|
|
73
|
+
{{tooltip}}
|
|
74
|
+
>
|
|
75
|
+
{{t 'article-structure-plugin.remove-with-content.help-text'}}
|
|
76
|
+
</AuPill>
|
|
77
|
+
</:tooltip>
|
|
78
|
+
</HoverTooltip>
|
|
79
|
+
|
|
80
|
+
</AuButtonGroup>
|
|
47
81
|
</Item>
|
|
48
82
|
</AuList>
|
|
49
83
|
</c.content>
|
|
@@ -35,9 +35,9 @@ export default class EditorPluginsStructureCardComponent extends Component<Args>
|
|
|
35
35
|
}
|
|
36
36
|
|
|
37
37
|
@action
|
|
38
|
-
removeStructure() {
|
|
38
|
+
removeStructure(withContent: boolean) {
|
|
39
39
|
if (this.structure && this.currentStructureType) {
|
|
40
|
-
if (
|
|
40
|
+
if (withContent || this.currentStructureType.noUnwrap) {
|
|
41
41
|
this.controller.doCommand(
|
|
42
42
|
removeStructure(this.structure, this.structureTypes),
|
|
43
43
|
{ view: this.controller.mainEditorView }
|
|
@@ -88,6 +88,27 @@ export default class EditorPluginsStructureCardComponent extends Component<Args>
|
|
|
88
88
|
return;
|
|
89
89
|
}
|
|
90
90
|
|
|
91
|
+
get remove() {
|
|
92
|
+
const translation = this.currentStructureType?.translations?.remove;
|
|
93
|
+
if (translation) {
|
|
94
|
+
return this.intl.t(translation);
|
|
95
|
+
} else {
|
|
96
|
+
return this.intl.t('article-structure-plugin.remove.default');
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
get removeWithContent() {
|
|
101
|
+
const translation =
|
|
102
|
+
this.currentStructureType?.translations?.removeWithContent;
|
|
103
|
+
if (translation) {
|
|
104
|
+
return this.intl.t(translation);
|
|
105
|
+
} else {
|
|
106
|
+
return this.intl.t(
|
|
107
|
+
'article-structure-plugin.remove-with-content.default'
|
|
108
|
+
);
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
|
|
91
112
|
get isOutsideStructure() {
|
|
92
113
|
return !this.structure;
|
|
93
114
|
}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import Component from '@glimmer/component';
|
|
2
|
+
import { modifier } from 'ember-modifier';
|
|
3
|
+
import { tracked } from '@glimmer/tracking';
|
|
4
|
+
|
|
5
|
+
interface Args {
|
|
6
|
+
placement?: string;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
export default class HoverTooltip extends Component<Args> {
|
|
10
|
+
hover = modifier(
|
|
11
|
+
(element) => {
|
|
12
|
+
element.addEventListener('mouseenter', this.showTooltip);
|
|
13
|
+
element.addEventListener('mouseleave', this.hideTooltip);
|
|
14
|
+
element.addEventListener('focus', this.showTooltip);
|
|
15
|
+
element.addEventListener('blur', this.hideTooltip);
|
|
16
|
+
return () => {
|
|
17
|
+
element.removeEventListener('mouseenter', this.showTooltip);
|
|
18
|
+
element.removeEventListener('mouseleave', this.hideTooltip);
|
|
19
|
+
element.removeEventListener('focus', this.showTooltip);
|
|
20
|
+
element.removeEventListener('blur', this.hideTooltip);
|
|
21
|
+
};
|
|
22
|
+
},
|
|
23
|
+
{ eager: false }
|
|
24
|
+
);
|
|
25
|
+
|
|
26
|
+
@tracked tooltipOpen = false;
|
|
27
|
+
|
|
28
|
+
get placement() {
|
|
29
|
+
return this.args.placement ?? 'top';
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
showTooltip = () => {
|
|
33
|
+
this.tooltipOpen = true;
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
hideTooltip = () => {
|
|
37
|
+
this.tooltipOpen = false;
|
|
38
|
+
};
|
|
39
|
+
}
|
|
@@ -47,7 +47,7 @@
|
|
|
47
47
|
{{#each this.formats as |format|}}
|
|
48
48
|
<AuFormRow>
|
|
49
49
|
<AuControlRadio
|
|
50
|
-
@label={{format.label}}
|
|
50
|
+
@label={{if format.label format.label (if this.onlyDate format.dateFormat format.dateTimeFormat)}}
|
|
51
51
|
@identifier={{format.key}}
|
|
52
52
|
@name="dateFormat"
|
|
53
53
|
@value={{format.key}}
|
|
@@ -83,7 +83,22 @@ export default class TableOfContentsComponent extends Component<EmberNodeArgs> {
|
|
|
83
83
|
const selection = Selection.near(resolvedPos, 1);
|
|
84
84
|
if (selection) {
|
|
85
85
|
tr.setSelection(selection);
|
|
86
|
-
|
|
86
|
+
const coords = this.controller.mainEditorView.coordsAtPos(
|
|
87
|
+
selection.from
|
|
88
|
+
);
|
|
89
|
+
const config = this.config[0];
|
|
90
|
+
if (config.scrollContainer) {
|
|
91
|
+
const scrollContainer: HTMLElement = config.scrollContainer;
|
|
92
|
+
const alreadyScrolled = scrollContainer.scrollTop;
|
|
93
|
+
const MAGIC_NUMBER_TOPBAR_HEIGHT: number =
|
|
94
|
+
config.scrollingPadding ?? 150;
|
|
95
|
+
scrollContainer.scrollTo(
|
|
96
|
+
0,
|
|
97
|
+
coords.top + alreadyScrolled - MAGIC_NUMBER_TOPBAR_HEIGHT
|
|
98
|
+
);
|
|
99
|
+
} else {
|
|
100
|
+
tr.scrollIntoView();
|
|
101
|
+
}
|
|
87
102
|
}
|
|
88
103
|
return tr;
|
|
89
104
|
});
|
|
@@ -1,6 +1,11 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import {
|
|
2
|
+
EditorState,
|
|
3
|
+
Fragment,
|
|
4
|
+
PNode,
|
|
5
|
+
Schema,
|
|
6
|
+
Transaction,
|
|
7
|
+
} from '@lblod/ember-rdfa-editor';
|
|
2
8
|
import IntlService from 'ember-intl/services/intl';
|
|
3
|
-
import { Transaction } from '@lblod/ember-rdfa-editor';
|
|
4
9
|
|
|
5
10
|
export type SpecName = string;
|
|
6
11
|
|
|
@@ -8,11 +13,12 @@ export type StructureSpec = {
|
|
|
8
13
|
name: SpecName;
|
|
9
14
|
translations: {
|
|
10
15
|
insert: string;
|
|
11
|
-
move
|
|
12
|
-
up
|
|
13
|
-
down
|
|
16
|
+
move?: {
|
|
17
|
+
up?: string;
|
|
18
|
+
down?: string;
|
|
14
19
|
};
|
|
15
|
-
remove
|
|
20
|
+
remove?: string;
|
|
21
|
+
removeWithContent?: string;
|
|
16
22
|
};
|
|
17
23
|
constructor: (args: {
|
|
18
24
|
schema: Schema;
|
|
@@ -21,6 +21,7 @@ export const articleParagraphSpec: StructureSpec = {
|
|
|
21
21
|
down: 'article-structure-plugin.move-down.paragraph',
|
|
22
22
|
},
|
|
23
23
|
remove: 'article-structure-plugin.remove.paragraph',
|
|
24
|
+
removeWithContent: 'article-structure-plugin.remove-with-content.paragraph',
|
|
24
25
|
},
|
|
25
26
|
continuous: false,
|
|
26
27
|
noUnwrap: true,
|
|
@@ -27,6 +27,7 @@ export const articleSpec: StructureSpec = {
|
|
|
27
27
|
down: 'article-structure-plugin.move-down.article',
|
|
28
28
|
},
|
|
29
29
|
remove: 'article-structure-plugin.remove.article',
|
|
30
|
+
removeWithContent: 'article-structure-plugin.remove-with-content.article',
|
|
30
31
|
},
|
|
31
32
|
continuous: true,
|
|
32
33
|
constructor: ({ schema, number, content, intl }) => {
|
|
@@ -22,6 +22,7 @@ export const chapterSpec: StructureSpec = {
|
|
|
22
22
|
down: 'article-structure-plugin.move-down.chapter',
|
|
23
23
|
},
|
|
24
24
|
remove: 'article-structure-plugin.remove.chapter',
|
|
25
|
+
removeWithContent: 'article-structure-plugin.remove-with-content.chapter',
|
|
25
26
|
},
|
|
26
27
|
constructor: ({ schema, number, content, intl }) => {
|
|
27
28
|
const numberConverted = romanize(number ?? 1);
|
|
@@ -22,6 +22,7 @@ export const sectionSpec: StructureSpec = {
|
|
|
22
22
|
down: 'article-structure-plugin.move-down.section',
|
|
23
23
|
},
|
|
24
24
|
remove: 'article-structure-plugin.remove.section',
|
|
25
|
+
removeWithContent: 'article-structure-plugin.remove-with-content.section',
|
|
25
26
|
},
|
|
26
27
|
constructor: ({ schema, number, content, intl }) => {
|
|
27
28
|
const numberConverted = romanize(number || 1);
|
|
@@ -23,6 +23,8 @@ export const subsectionSpec: StructureSpec = {
|
|
|
23
23
|
down: 'article-structure-plugin.move-down.subsection',
|
|
24
24
|
},
|
|
25
25
|
remove: 'article-structure-plugin.remove.subsection',
|
|
26
|
+
removeWithContent:
|
|
27
|
+
'article-structure-plugin.remove-with-content.subsection',
|
|
26
28
|
},
|
|
27
29
|
constructor: ({ schema, number, intl, content }) => {
|
|
28
30
|
const numberConverted = romanize(number ?? 1);
|
|
@@ -22,6 +22,7 @@ export const titleSpec: StructureSpec = {
|
|
|
22
22
|
down: 'article-structure-plugin.move-down.title',
|
|
23
23
|
},
|
|
24
24
|
remove: 'article-structure-plugin.remove.title',
|
|
25
|
+
removeWithContent: 'article-structure-plugin.remove-with-content.title',
|
|
25
26
|
},
|
|
26
27
|
constructor: ({ schema, number, content, intl }) => {
|
|
27
28
|
const numberConverted = romanize(number ?? 1);
|
|
@@ -10,7 +10,7 @@ export default function insertTitle(intl: IntlService): Command {
|
|
|
10
10
|
if (!besluit) {
|
|
11
11
|
return false;
|
|
12
12
|
}
|
|
13
|
-
if (!besluit.node.canReplaceWith(0, 0, schema.nodes.
|
|
13
|
+
if (!besluit.node.canReplaceWith(0, 0, schema.nodes.besluit_title)) {
|
|
14
14
|
return false;
|
|
15
15
|
}
|
|
16
16
|
|
|
@@ -19,7 +19,7 @@ export default function insertTitle(intl: IntlService): Command {
|
|
|
19
19
|
tr.insert(
|
|
20
20
|
besluit.pos + 1,
|
|
21
21
|
schema.node(
|
|
22
|
-
'
|
|
22
|
+
'besluit_title',
|
|
23
23
|
{ __rdfaId: uuid() },
|
|
24
24
|
schema.node(
|
|
25
25
|
'paragraph',
|
|
@@ -1,12 +1,10 @@
|
|
|
1
1
|
export const defaultDateFormats: DateFormat[] = [
|
|
2
2
|
{
|
|
3
|
-
label: 'Short Date',
|
|
4
3
|
key: 'short',
|
|
5
4
|
dateFormat: 'dd/MM/yy',
|
|
6
5
|
dateTimeFormat: 'dd/MM/yy HH:mm',
|
|
7
6
|
},
|
|
8
7
|
{
|
|
9
|
-
label: 'Long Date',
|
|
10
8
|
key: 'long',
|
|
11
9
|
dateFormat: 'EEEE dd MMMM yyyy',
|
|
12
10
|
dateTimeFormat: 'PPPPp',
|
|
@@ -14,7 +12,7 @@ export const defaultDateFormats: DateFormat[] = [
|
|
|
14
12
|
];
|
|
15
13
|
|
|
16
14
|
export type DateFormat = {
|
|
17
|
-
label
|
|
15
|
+
label?: string;
|
|
18
16
|
key: string;
|
|
19
17
|
dateFormat: string;
|
|
20
18
|
dateTimeFormat: string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
besluit,
|
|
3
|
-
|
|
3
|
+
besluit_title,
|
|
4
4
|
description,
|
|
5
5
|
motivering,
|
|
6
6
|
article_container,
|
|
@@ -13,7 +13,7 @@ import {
|
|
|
13
13
|
|
|
14
14
|
export const besluitNodes = {
|
|
15
15
|
besluit,
|
|
16
|
-
|
|
16
|
+
besluit_title,
|
|
17
17
|
description,
|
|
18
18
|
motivering,
|
|
19
19
|
article_container,
|
|
@@ -16,7 +16,7 @@ import { StructureSpec } from '../../article-structure-plugin';
|
|
|
16
16
|
import { v4 as uuid } from 'uuid';
|
|
17
17
|
import { unwrap } from '@lblod/ember-rdfa-editor-lblod-plugins/utils/option';
|
|
18
18
|
|
|
19
|
-
export const
|
|
19
|
+
export const besluit_title: NodeSpec = {
|
|
20
20
|
content: 'paragraph+',
|
|
21
21
|
inline: false,
|
|
22
22
|
defining: true,
|
|
@@ -308,7 +308,7 @@ export const besluit_article_content: NodeSpec = {
|
|
|
308
308
|
|
|
309
309
|
export const besluit: NodeSpec = {
|
|
310
310
|
group: 'block',
|
|
311
|
-
content: 'block*
|
|
311
|
+
content: 'block*besluit_title?block*description?block*motivering?block*',
|
|
312
312
|
inline: false,
|
|
313
313
|
defining: true,
|
|
314
314
|
isolating: true,
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from '@lblod/ember-rdfa-editor-lblod-plugins/components/hover-tooltip';
|
|
@@ -11,7 +11,7 @@ export default class EditorPluginsStructureCardComponent extends Component<Args>
|
|
|
11
11
|
removeStructureContent: boolean;
|
|
12
12
|
get controller(): SayController;
|
|
13
13
|
moveStructure(direction: 'up' | 'down'): void;
|
|
14
|
-
removeStructure(): void;
|
|
14
|
+
removeStructure(withContent: boolean): void;
|
|
15
15
|
setRemoveStructureContent(value: boolean): void;
|
|
16
16
|
get structureTypes(): ArticleStructurePluginOptions;
|
|
17
17
|
get structureNodeSpecs(): import("prosemirror-model").NodeType[];
|
|
@@ -22,6 +22,8 @@ export default class EditorPluginsStructureCardComponent extends Component<Args>
|
|
|
22
22
|
node: import("prosemirror-model").Node;
|
|
23
23
|
} | undefined;
|
|
24
24
|
get currentStructureType(): import("@lblod/ember-rdfa-editor-lblod-plugins/plugins/article-structure-plugin").StructureSpec | undefined;
|
|
25
|
+
get remove(): string;
|
|
26
|
+
get removeWithContent(): string;
|
|
25
27
|
get isOutsideStructure(): boolean;
|
|
26
28
|
get canMoveDown(): boolean;
|
|
27
29
|
get canMoveUp(): boolean;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import Component from '@glimmer/component';
|
|
2
|
+
interface Args {
|
|
3
|
+
placement?: string;
|
|
4
|
+
}
|
|
5
|
+
export default class HoverTooltip extends Component<Args> {
|
|
6
|
+
hover: import("ember-modifier").FunctionBasedModifier<{
|
|
7
|
+
Args: {
|
|
8
|
+
Named: Record<string, unknown>;
|
|
9
|
+
Positional: unknown[];
|
|
10
|
+
};
|
|
11
|
+
Element: Element;
|
|
12
|
+
}>;
|
|
13
|
+
tooltipOpen: boolean;
|
|
14
|
+
get placement(): string;
|
|
15
|
+
showTooltip: () => void;
|
|
16
|
+
hideTooltip: () => void;
|
|
17
|
+
}
|
|
18
|
+
export {};
|
package/package.json
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { Fragment, PNode, Schema,
|
|
1
|
+
import { EditorState, Fragment, PNode, Schema, Transaction } from '@lblod/ember-rdfa-editor';
|
|
2
2
|
import IntlService from 'ember-intl/services/intl';
|
|
3
|
-
import { Transaction } from '@lblod/ember-rdfa-editor';
|
|
4
3
|
export type SpecName = string;
|
|
5
4
|
export type StructureSpec = {
|
|
6
5
|
name: SpecName;
|
|
7
6
|
translations: {
|
|
8
7
|
insert: string;
|
|
9
|
-
move
|
|
10
|
-
up
|
|
11
|
-
down
|
|
8
|
+
move?: {
|
|
9
|
+
up?: string;
|
|
10
|
+
down?: string;
|
|
12
11
|
};
|
|
13
|
-
remove
|
|
12
|
+
remove?: string;
|
|
13
|
+
removeWithContent?: string;
|
|
14
14
|
};
|
|
15
15
|
constructor: (args: {
|
|
16
16
|
schema: Schema;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export declare const besluitNodes: {
|
|
2
2
|
besluit: import("prosemirror-model").NodeSpec;
|
|
3
|
-
|
|
3
|
+
besluit_title: import("prosemirror-model").NodeSpec;
|
|
4
4
|
description: import("prosemirror-model").NodeSpec;
|
|
5
5
|
motivering: import("prosemirror-model").NodeSpec;
|
|
6
6
|
article_container: import("prosemirror-model").NodeSpec;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { NodeSpec } from '@lblod/ember-rdfa-editor';
|
|
2
2
|
import { StructureSpec } from '../../article-structure-plugin';
|
|
3
|
-
export declare const
|
|
3
|
+
export declare const besluit_title: NodeSpec;
|
|
4
4
|
export declare const description: NodeSpec;
|
|
5
5
|
export declare const motivering: NodeSpec;
|
|
6
6
|
export declare const article_container: NodeSpec;
|
package/translations/en-US.yaml
CHANGED
|
@@ -7,6 +7,7 @@ article-structure-plugin:
|
|
|
7
7
|
section: Insert section
|
|
8
8
|
subsection: Insert subsection
|
|
9
9
|
move-up:
|
|
10
|
+
default: Move structure up
|
|
10
11
|
paragraph: Move paragraph up
|
|
11
12
|
article: Move article up
|
|
12
13
|
title: Move title up
|
|
@@ -14,6 +15,7 @@ article-structure-plugin:
|
|
|
14
15
|
section: Move section up
|
|
15
16
|
subsection: Move subsection up
|
|
16
17
|
move-down:
|
|
18
|
+
default: Move structure down
|
|
17
19
|
paragraph: Move paragraph down
|
|
18
20
|
article: Move article down
|
|
19
21
|
title: Move title down
|
|
@@ -23,13 +25,23 @@ article-structure-plugin:
|
|
|
23
25
|
title:
|
|
24
26
|
structure-card: Structure Card
|
|
25
27
|
remove:
|
|
28
|
+
default: Remove structure
|
|
26
29
|
article: Remove Article
|
|
27
30
|
paragraph: Remove Paragraph
|
|
28
31
|
subsection: Remove subsection
|
|
29
32
|
section: Remove section
|
|
30
33
|
chapter: Remove chapter
|
|
31
34
|
title: Remove title
|
|
32
|
-
|
|
35
|
+
help-text: Remove the heading, but keep the content
|
|
36
|
+
remove-with-content:
|
|
37
|
+
default: Remove structure with content
|
|
38
|
+
article: Remove Article with content
|
|
39
|
+
paragraph: Remove Paragraph with content
|
|
40
|
+
subsection: Remove subsection with content
|
|
41
|
+
section: Remove section with content
|
|
42
|
+
chapter: Remove chapter with content
|
|
43
|
+
title: Remove title with content
|
|
44
|
+
help-text: Remove the heading, and also remove all content up to the next heading of the same level
|
|
33
45
|
placeholder:
|
|
34
46
|
generic:
|
|
35
47
|
heading: Insert title
|
|
@@ -166,4 +178,4 @@ variable-plugin:
|
|
|
166
178
|
|
|
167
179
|
table-of-contents-plugin:
|
|
168
180
|
title: Table of Contents
|
|
169
|
-
toggle: Show Table of Contents
|
|
181
|
+
toggle: Show Table of Contents
|
package/translations/nl-BE.yaml
CHANGED
|
@@ -13,6 +13,7 @@ article-structure-plugin:
|
|
|
13
13
|
chapter: Hoofdstuk naar boven verplaatsen
|
|
14
14
|
section: Afdeling naar boven verplaatsen
|
|
15
15
|
subsection: Onderafdeling naar boven verplaatsen
|
|
16
|
+
default: Structuur naar boven verplaatsen
|
|
16
17
|
move-down:
|
|
17
18
|
paragraph: Paragraaf naar beneden verplaatsen
|
|
18
19
|
article: Artikel naar beneden verplaatsen
|
|
@@ -20,16 +21,27 @@ article-structure-plugin:
|
|
|
20
21
|
chapter: Hoofdstuk naar beneden verplaatsen
|
|
21
22
|
section: Afdeling naar beneden verplaatsen
|
|
22
23
|
subsection: Onderafdeling naar beneden verplaatsen
|
|
24
|
+
default: Structuur naar beneden verplaatsen
|
|
23
25
|
title:
|
|
24
26
|
structure-card: Structuur card
|
|
25
27
|
remove:
|
|
28
|
+
default: Structuur verwijderen
|
|
26
29
|
article: Artikel verwijderen
|
|
27
30
|
paragraph: Paragraaf verwijderen
|
|
28
31
|
subsection: Onderafdeling verwijderen
|
|
29
32
|
section: Afdeling verwijderen
|
|
30
33
|
chapter: Hoofdstuk verwijderen
|
|
31
34
|
title: Titel verwijderen
|
|
32
|
-
|
|
35
|
+
help-text: Verwijder de hoofding, maar behoud de inhoud
|
|
36
|
+
remove-with-content:
|
|
37
|
+
default: Structuur verwijderen met inhoud
|
|
38
|
+
article: Artikel en inhoud verwijderen
|
|
39
|
+
subsection: Onderafdeling en inhoud verwijderen
|
|
40
|
+
section: Afdeling en inhoud verwijderen
|
|
41
|
+
chapter: Hoofdstuk en inhoud verwijderen
|
|
42
|
+
title: Titel en inhoud verwijderen
|
|
43
|
+
paragraph: Paragraaf en inhoud verwijderen
|
|
44
|
+
help-text: Verwijder de hoofding, en alle inhoud tot aan de volgende hoofding van hetzelfde niveau
|
|
33
45
|
placeholder:
|
|
34
46
|
generic:
|
|
35
47
|
heading: Voeg titel in
|
|
@@ -168,4 +180,4 @@ table-of-contents-plugin:
|
|
|
168
180
|
variable-plugin:
|
|
169
181
|
insert-variable: Voeg variabele in
|
|
170
182
|
button: Voeg in
|
|
171
|
-
enter-variable-value: Selecteer waarde
|
|
183
|
+
enter-variable-value: Selecteer waarde
|