Skip to content

Commit 432b7e7

Browse files
committed
fix: use core from npm package
1 parent aaf435a commit 432b7e7

32 files changed

+1844
-552
lines changed

package-lock.json

Lines changed: 1340 additions & 274 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/compas-open-scd/package.json

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@
1818
"module": "open-scd.js",
1919
"type": "module",
2020
"dependencies": {
21+
"@compas-oscd/core": "^0.1.4",
22+
"@compas-oscd/xml": "^0.0.1",
2123
"@material/mwc-dialog": "0.22.1",
2224
"@material/mwc-drawer": "0.22.1",
2325
"@material/mwc-fab": "0.22.1",
@@ -36,17 +38,16 @@
3638
"@material/mwc-textarea": "0.22.1",
3739
"@material/mwc-textfield": "0.22.1",
3840
"@material/mwc-top-app-bar-fixed": "0.22.1",
41+
"@openscd/addons": "*",
42+
"@openscd/open-scd": "*",
43+
"@openscd/plugins": "*",
3944
"ace-custom-element": "^1.6.5",
4045
"csv-stringify": "^6.2.0",
4146
"lit-element": "2.5.1",
4247
"lit-html": "1.4.1",
4348
"lit-translate": "^1.2.1",
4449
"marked": "^4.0.10",
45-
"panzoom": "^9.4.2",
46-
"@compas-oscd/xml": "^0.0.1",
47-
"@openscd/open-scd": "*",
48-
"@openscd/plugins": "*",
49-
"@openscd/addons": "*"
50+
"panzoom": "^9.4.2"
5051
},
5152
"scripts": {
5253
"lint:eslint": "eslint --ext .ts,.html . --ignore-path .gitignore",
@@ -106,7 +107,7 @@
106107
"tslib": "^2.3.1",
107108
"typedoc": "^0.21.10",
108109
"typedoc-plugin-markdown": "3.10.4",
109-
"typescript": "4.3.5",
110+
"typescript": "4.9.5",
110111
"web-component-analyzer": "^1.1.6",
111112
"workbox-cli": "^6.2.4"
112113
},

packages/compas-open-scd/src/addons/CompasHistory.ts

Lines changed: 14 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,4 @@
1-
import {
2-
html,
3-
TemplateResult,
4-
customElement,
5-
} from 'lit-element';
1+
import { html, TemplateResult, customElement } from 'lit-element';
62

73
import '@material/mwc-button';
84
import '@material/mwc-dialog';
@@ -15,11 +11,12 @@ import '@material/mwc-snackbar';
1511

1612
import '@openscd/open-scd/src/filtered-list.js';
1713

18-
import {
19-
IssueDetail,
20-
} from '@openscd/core/foundation/deprecated/history.js';
14+
import { IssueDetail } from '@compas-oscd/core/foundation/deprecated/history.js';
2115

22-
import { HistoryUIDetail, OscdHistory } from '@openscd/open-scd/src/addons/History.js';
16+
import {
17+
HistoryUIDetail,
18+
OscdHistory,
19+
} from '@openscd/open-scd/src/addons/History.js';
2320
import { wizards } from '@openscd/plugins/src/wizards/wizard-library';
2421
import { newWizardEvent, SCLTag } from '@openscd/open-scd/src/foundation';
2522
import { nothing } from 'lit-html';
@@ -100,16 +97,15 @@ export class CompasHistory extends OscdHistory {
10097
<span> ${issue.title}</span>
10198
<span slot="secondary">${issue.message}</span>
10299
${this.hasEditWizard(issue.element)
103-
? html` <span slot="meta">
104-
<mwc-icon-button
105-
icon="edit"
106-
@click=${() => this.openEditWizard(issue.element)}
107-
></mwc-icon-button>
108-
</span>`
109-
: nothing}
100+
? html` <span slot="meta">
101+
<mwc-icon-button
102+
icon="edit"
103+
@click=${() => this.openEditWizard(issue.element)}
104+
></mwc-icon-button>
105+
</span>`
106+
: nothing}
110107
</mwc-list-item>
111-
</abbr
112-
>`;
108+
</abbr>`;
113109
}
114110
}
115111

packages/compas-open-scd/src/compas-editors/CompasVersions.ts

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -23,13 +23,10 @@ import { MultiSelectedEvent } from '@material/mwc-list/mwc-list-foundation';
2323

2424
import '@openscd/open-scd/src/plain-compare-list.js';
2525

26-
import { newLogEvent } from "@openscd/core/foundation/deprecated/history.js";
27-
import { newOpenDocEvent } from "@openscd/core/foundation/deprecated/open-event.js";
26+
import { newLogEvent } from '@compas-oscd/core/foundation/deprecated/history.js';
27+
import { newOpenDocEvent } from '@compas-oscd/core/foundation/deprecated/open-event.js';
2828

29-
import {
30-
newWizardEvent,
31-
Wizard,
32-
} from '@openscd/open-scd/src/foundation.js';
29+
import { newWizardEvent, Wizard } from '@openscd/open-scd/src/foundation.js';
3330

3431
import {
3532
CompasSclDataService,
@@ -43,7 +40,7 @@ import {
4340
} from '../compas/foundation.js';
4441
import { addVersionToCompasWizard } from '../compas/CompasUploadVersion.js';
4542
import { getElementByName, styles } from './foundation.js';
46-
import { editCompasSCLWizard } from "../compas-wizards/scl.js";
43+
import { editCompasSCLWizard } from '../compas-wizards/scl.js';
4744

4845
/** An editor [[`plugin`]] for selecting the `Substation` section. */
4946
export default class CompasVersionsPlugin extends LitElement {

packages/compas-open-scd/src/compas-editors/autogen-substation.ts

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
import { LitElement, property } from 'lit-element';
2-
import {
3-
newActionEvent,
4-
} from '@openscd/core/foundation/deprecated/editor.js';
2+
import { newActionEvent } from '@compas-oscd/core/foundation/deprecated/editor.js';
53
import { createElement } from '@compas-oscd/xml';
6-
import { newLogEvent } from '@openscd/core/foundation/deprecated/history.js';
4+
import { newLogEvent } from '@compas-oscd/core/foundation/deprecated/history.js';
75
import { get } from 'lit-translate';
86

97
let cbNum = 1;

packages/compas-open-scd/src/compas-editors/sitipe/sitipe-bay.ts

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,14 @@ import '@material/mwc-icon-button';
1818
import { IconButton } from '@material/mwc-icon-button';
1919

2020
import { isPublic } from '@openscd/open-scd/src/foundation.js';
21-
import { newActionEvent } from '@openscd/core/foundation/deprecated/editor.js';
21+
import { newActionEvent } from '@compas-oscd/core/foundation/deprecated/editor.js';
2222
import { createElement } from '@compas-oscd/xml';
23-
import { newLogEvent } from '@openscd/core/foundation/deprecated/history.js';
23+
import { newLogEvent } from '@compas-oscd/core/foundation/deprecated/history.js';
2424

25-
import { ComplexAction, SimpleAction } from "@openscd/core/foundation/deprecated/editor.js";
25+
import {
26+
ComplexAction,
27+
SimpleAction,
28+
} from '@compas-oscd/core/foundation/deprecated/editor.js';
2629

2730
import '@openscd/open-scd/src/action-pane.js';
2831
import '@openscd/open-scd/src/action-icon.js';

packages/compas-open-scd/src/compas-services/Websocket.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { newPendingStateEvent } from '@openscd/core/foundation/deprecated/waiter.js';
1+
import { newPendingStateEvent } from '@compas-oscd/core/foundation/deprecated/waiter.js';
22
import {
33
APPLICATION_ERROR,
44
extractErrorMessage,

packages/compas-open-scd/src/compas-services/foundation.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { get } from 'lit-translate';
2-
import { newLogEvent } from '@openscd/core/foundation/deprecated/history.js';
2+
import { newLogEvent } from '@compas-oscd/core/foundation/deprecated/history.js';
33

44
export const NOT_FOUND_ERROR = 'NotFoundError';
55
export const APPLICATION_ERROR = 'ApplicationError';

packages/compas-open-scd/src/compas-wizards/scl.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,10 @@ import {
1010

1111
import { cloneElement } from '@compas-oscd/xml';
1212

13-
import { ComplexAction, EditorAction } from "@openscd/core/foundation/deprecated/editor.js";
13+
import {
14+
ComplexAction,
15+
EditorAction,
16+
} from '@compas-oscd/core/foundation/deprecated/editor.js';
1417

1518
import '../compas/CompasLabelsField.js';
1619

packages/compas-open-scd/src/compas/CompasAutoAlignment.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ import '@material/mwc-list';
1212
import '@material/mwc-list/mwc-check-list-item';
1313

1414
import { newWizardEvent } from '@openscd/open-scd/src/foundation.js';
15-
import { newLogEvent } from '@openscd/core/foundation/deprecated/history.js';
16-
import { newOpenDocEvent } from '@openscd/core/foundation/deprecated/open-event.js';
15+
import { newLogEvent } from '@compas-oscd/core/foundation/deprecated/history.js';
16+
import { newOpenDocEvent } from '@compas-oscd/core/foundation/deprecated/open-event.js';
1717

1818
import { CompasSclAutoAlignmentService } from '../compas-services/CompasSclAutoAlignmentService.js';
1919
import { createLogEvent } from '../compas-services/foundation.js';

0 commit comments

Comments
 (0)