@lblod/ember-rdfa-editor-lblod-plugins 22.0.1 → 22.0.2
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
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# @lblod/ember-rdfa-editor-lblod-plugins
|
|
2
2
|
|
|
3
|
+
## 22.0.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`3f90b8a`](https://github.com/lblod/ember-rdfa-editor-lblod-plugins/commit/3f90b8ac9a07a884e28d838aa39d4eec42fffbd9) Thanks [@elpoelma](https://github.com/elpoelma)! - Fix structure-control card labels
|
|
8
|
+
|
|
9
|
+
- [#458](https://github.com/lblod/ember-rdfa-editor-lblod-plugins/pull/458) [`d1f3a8c`](https://github.com/lblod/ember-rdfa-editor-lblod-plugins/commit/d1f3a8c10c84fcfd02fbea2df18f10523d548287) Thanks [@piemonkey](https://github.com/piemonkey)! - Add support for relative urls to lpdc endpoint configuration
|
|
10
|
+
|
|
3
11
|
## 22.0.1
|
|
4
12
|
|
|
5
13
|
### Patch Changes
|
|
@@ -22,10 +22,13 @@ import { not } from 'ember-truth-helpers';
|
|
|
22
22
|
import { recalculateNumbers } from '@lblod/ember-rdfa-editor-lblod-plugins/plugins/structure-plugin/recalculate-structure-numbers';
|
|
23
23
|
import { moveStructure } from '@lblod/ember-rdfa-editor-lblod-plugins/plugins/structure-plugin/move-structure';
|
|
24
24
|
import { transactionCombinator } from '@lblod/ember-rdfa-editor/utils/transaction-utils';
|
|
25
|
+
import { service } from '@ember/service';
|
|
26
|
+
import IntlService from 'ember-intl/services/intl';
|
|
25
27
|
interface Sig {
|
|
26
28
|
Args: { controller: SayController };
|
|
27
29
|
}
|
|
28
30
|
export default class StructureControlCardComponent extends Component<Sig> {
|
|
31
|
+
@service declare intl: IntlService;
|
|
29
32
|
get controller(): SayController {
|
|
30
33
|
return this.args.controller;
|
|
31
34
|
}
|
|
@@ -43,7 +46,8 @@ export default class StructureControlCardComponent extends Component<Sig> {
|
|
|
43
46
|
return null;
|
|
44
47
|
}
|
|
45
48
|
get structureName(): string {
|
|
46
|
-
|
|
49
|
+
const type = this.structure?.node.attrs.structureType;
|
|
50
|
+
return this.intl.t(`structure-plugin.types.${type}`) ?? 'Unknown structure';
|
|
47
51
|
}
|
|
48
52
|
get canMoveUp() {
|
|
49
53
|
return this.controller.checkCommand(moveStructure('up'));
|
|
@@ -60,9 +60,11 @@ export const fetchLpdcs = async ({
|
|
|
60
60
|
};
|
|
61
61
|
};
|
|
62
62
|
}> => {
|
|
63
|
-
const endpoint = config?.endpoint
|
|
63
|
+
const endpoint = `${config?.endpoint}/doc/instantie`;
|
|
64
64
|
|
|
65
|
-
const url =
|
|
65
|
+
const url = endpoint.startsWith('/')
|
|
66
|
+
? new URL(endpoint, window.location.origin)
|
|
67
|
+
: new URL(endpoint);
|
|
66
68
|
|
|
67
69
|
if (filter?.name) {
|
|
68
70
|
url.searchParams.append('zoekterm', filter.name);
|
|
@@ -72,7 +74,7 @@ export const fetchLpdcs = async ({
|
|
|
72
74
|
url.searchParams.append('pageIndex', pageNumber.toString());
|
|
73
75
|
}
|
|
74
76
|
|
|
75
|
-
const results = await fetch(url
|
|
77
|
+
const results = await fetch(url, {
|
|
76
78
|
method: 'GET',
|
|
77
79
|
headers: {
|
|
78
80
|
Accept: 'application/json',
|
|
@@ -2,12 +2,14 @@ import { NodeWithPos } from '@curvenote/prosemirror-utils';
|
|
|
2
2
|
import Component from '@glimmer/component';
|
|
3
3
|
import { NodeType, SayController, Schema } from '@lblod/ember-rdfa-editor';
|
|
4
4
|
import { Option } from '@lblod/ember-rdfa-editor-lblod-plugins/utils/option';
|
|
5
|
+
import IntlService from 'ember-intl/services/intl';
|
|
5
6
|
interface Sig {
|
|
6
7
|
Args: {
|
|
7
8
|
controller: SayController;
|
|
8
9
|
};
|
|
9
10
|
}
|
|
10
11
|
export default class StructureControlCardComponent extends Component<Sig> {
|
|
12
|
+
intl: IntlService;
|
|
11
13
|
get controller(): SayController;
|
|
12
14
|
get schema(): Schema;
|
|
13
15
|
get structureType(): NodeType | undefined;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lblod/ember-rdfa-editor-lblod-plugins",
|
|
3
|
-
"version": "22.0.
|
|
3
|
+
"version": "22.0.2",
|
|
4
4
|
"description": "Ember addon providing lblod specific plugins for the ember-rdfa-editor",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ember-addon",
|
|
@@ -102,7 +102,7 @@
|
|
|
102
102
|
"@glint/template": "^1.4.0",
|
|
103
103
|
"@graphy/content.ttl.write": "^4.3.7",
|
|
104
104
|
"@graphy/memory.dataset.fast": "4.3.3",
|
|
105
|
-
"@lblod/ember-rdfa-editor": "10.0.
|
|
105
|
+
"@lblod/ember-rdfa-editor": "10.0.1",
|
|
106
106
|
"@rdfjs/types": "^1.1.0",
|
|
107
107
|
"@release-it/keep-a-changelog": "^4.0.0",
|
|
108
108
|
"@tsconfig/ember": "^3.0.8",
|
package/pnpm-lock.yaml
CHANGED
|
@@ -160,8 +160,8 @@ importers:
|
|
|
160
160
|
specifier: 4.3.3
|
|
161
161
|
version: 4.3.3
|
|
162
162
|
'@lblod/ember-rdfa-editor':
|
|
163
|
-
specifier: 10.0.
|
|
164
|
-
version: 10.0.
|
|
163
|
+
specifier: 10.0.1
|
|
164
|
+
version: 10.0.1(2ef3gpurqxbttnmniw6grhzpuy)
|
|
165
165
|
'@rdfjs/types':
|
|
166
166
|
specifier: ^1.1.0
|
|
167
167
|
version: 1.1.0
|
|
@@ -1586,8 +1586,8 @@ packages:
|
|
|
1586
1586
|
'@jridgewell/trace-mapping@0.3.25':
|
|
1587
1587
|
resolution: {integrity: sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==}
|
|
1588
1588
|
|
|
1589
|
-
'@lblod/ember-rdfa-editor@10.0.
|
|
1590
|
-
resolution: {integrity: sha512-
|
|
1589
|
+
'@lblod/ember-rdfa-editor@10.0.1':
|
|
1590
|
+
resolution: {integrity: sha512-wYI3LIPQIMrulE1E1PzCrOhOpVgMEiEmGmMdThTYTljnZpzTJggGNqrJJCpVJ6wvaM4KFPZq3PtuRYeTfZlfeQ==}
|
|
1591
1591
|
engines: {node: 16.* || 18.* || >= 20}
|
|
1592
1592
|
peerDependencies:
|
|
1593
1593
|
'@appuniversum/ember-appuniversum': ^3.4.2
|
|
@@ -10718,7 +10718,7 @@ snapshots:
|
|
|
10718
10718
|
'@jridgewell/resolve-uri': 3.1.2
|
|
10719
10719
|
'@jridgewell/sourcemap-codec': 1.4.15
|
|
10720
10720
|
|
|
10721
|
-
'@lblod/ember-rdfa-editor@10.0.
|
|
10721
|
+
'@lblod/ember-rdfa-editor@10.0.1(2ef3gpurqxbttnmniw6grhzpuy)':
|
|
10722
10722
|
dependencies:
|
|
10723
10723
|
'@appuniversum/ember-appuniversum': 3.4.2(yenc6o4wruytt4u2jbwlbsqcl4)
|
|
10724
10724
|
'@babel/core': 7.24.7
|