@omicronenergy/oscd-shell 0.0.5 → 0.0.7
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/foundation/cyrb64.d.ts +6 -0
- package/dist/foundation/cyrb64.js +26 -0
- package/dist/foundation/cyrb64.js.map +1 -0
- package/dist/foundation.d.ts +1 -0
- package/dist/foundation.js +2 -0
- package/dist/foundation.js.map +1 -0
- package/dist/locales/de.d.ts +10 -0
- package/dist/locales/de.js +15 -0
- package/dist/locales/de.js.map +1 -0
- package/dist/locales.d.ts +13 -0
- package/dist/locales.js +21 -0
- package/dist/locales.js.map +1 -0
- package/dist/oscd-shell.d.ts +115 -0
- package/dist/oscd-shell.js +732 -0
- package/dist/oscd-shell.js.map +1 -0
- package/package.json +32 -29
- package/.editorconfig +0 -22
- package/.github/actions/setup-node-env/action.yml +0 -49
- package/.github/workflows/release-please.yml +0 -84
- package/.github/workflows/test.yml +0 -18
- package/.github/workflows/update-screenshots.yml +0 -29
- package/.husky/commit-msg +0 -1
- package/.husky/pre-commit +0 -1
- package/.release-please-manifest.json +0 -1
- package/CHANGELOG.md +0 -73
- package/CONTRIBUTING.md +0 -393
- package/commitlint.config.js +0 -1
- package/demo/AddPlugins.js +0 -42
- package/demo/DemoPluginSrc.js +0 -9
- package/demo/embedded.html +0 -17
- package/demo/index.html +0 -95
- package/foundation/cyrb64.ts +0 -27
- package/foundation/edit-event.ts +0 -273
- package/foundation/open-event.ts +0 -21
- package/foundation.ts +0 -28
- package/lit-localize.json +0 -15
- package/localization/de.xlf +0 -75
- package/oscd-shell.editing.spec.ts +0 -813
- package/oscd-shell.plugging.spec.ts +0 -78
- package/oscd-shell.spec.ts +0 -431
- package/oscd-shell.test.ts +0 -382
- package/oscd-shell.ts +0 -906
- package/release-please-config.json +0 -21
- package/rollup.config.js +0 -51
- package/screenshots/Chromium/baseline/app-bar-de.png +0 -0
- package/screenshots/Chromium/baseline/app-bar-en.png +0 -0
- package/screenshots/Chromium/baseline/document-name-de.png +0 -0
- package/screenshots/Chromium/baseline/document-name-en.png +0 -0
- package/screenshots/Chromium/baseline/editor-plugins-de.png +0 -0
- package/screenshots/Chromium/baseline/editor-plugins-en.png +0 -0
- package/screenshots/Chromium/baseline/editor-plugins-selected-de.png +0 -0
- package/screenshots/Chromium/baseline/editor-plugins-selected-en.png +0 -0
- package/screenshots/Chromium/baseline/editor-plugins-with-doc-de.png +0 -0
- package/screenshots/Chromium/baseline/editor-plugins-with-doc-en.png +0 -0
- package/screenshots/Chromium/baseline/log-entries-de.png +0 -0
- package/screenshots/Chromium/baseline/log-entries-en.png +0 -0
- package/screenshots/Chromium/baseline/log-entries-redone-de.png +0 -0
- package/screenshots/Chromium/baseline/log-entries-redone-en.png +0 -0
- package/screenshots/Chromium/baseline/log-entries-undone-de.png +0 -0
- package/screenshots/Chromium/baseline/log-entries-undone-en.png +0 -0
- package/screenshots/Chromium/baseline/log-screen-de.png +0 -0
- package/screenshots/Chromium/baseline/log-screen-en.png +0 -0
- package/screenshots/Chromium/baseline/menu-drawer-de.png +0 -0
- package/screenshots/Chromium/baseline/menu-drawer-en.png +0 -0
- package/screenshots/Chromium/baseline/menu-plugins-de.png +0 -0
- package/screenshots/Chromium/baseline/menu-plugins-en.png +0 -0
- package/screenshots/Chromium/baseline/menu-plugins-triggered-de.png +0 -0
- package/screenshots/Chromium/baseline/menu-plugins-triggered-en.png +0 -0
- package/screenshots/Firefox/baseline/app-bar-de.png +0 -0
- package/screenshots/Firefox/baseline/app-bar-en.png +0 -0
- package/screenshots/Firefox/baseline/document-name-de.png +0 -0
- package/screenshots/Firefox/baseline/document-name-en.png +0 -0
- package/screenshots/Firefox/baseline/editor-plugins-de.png +0 -0
- package/screenshots/Firefox/baseline/editor-plugins-en.png +0 -0
- package/screenshots/Firefox/baseline/editor-plugins-selected-de.png +0 -0
- package/screenshots/Firefox/baseline/editor-plugins-selected-en.png +0 -0
- package/screenshots/Firefox/baseline/editor-plugins-with-doc-de.png +0 -0
- package/screenshots/Firefox/baseline/editor-plugins-with-doc-en.png +0 -0
- package/screenshots/Firefox/baseline/log-entries-de.png +0 -0
- package/screenshots/Firefox/baseline/log-entries-en.png +0 -0
- package/screenshots/Firefox/baseline/log-entries-redone-de.png +0 -0
- package/screenshots/Firefox/baseline/log-entries-redone-en.png +0 -0
- package/screenshots/Firefox/baseline/log-entries-undone-de.png +0 -0
- package/screenshots/Firefox/baseline/log-entries-undone-en.png +0 -0
- package/screenshots/Firefox/baseline/log-screen-de.png +0 -0
- package/screenshots/Firefox/baseline/log-screen-en.png +0 -0
- package/screenshots/Firefox/baseline/menu-drawer-de.png +0 -0
- package/screenshots/Firefox/baseline/menu-drawer-en.png +0 -0
- package/screenshots/Firefox/baseline/menu-plugins-de.png +0 -0
- package/screenshots/Firefox/baseline/menu-plugins-en.png +0 -0
- package/screenshots/Firefox/baseline/menu-plugins-triggered-de.png +0 -0
- package/screenshots/Firefox/baseline/menu-plugins-triggered-en.png +0 -0
- package/screenshots/Webkit/baseline/app-bar-de.png +0 -0
- package/screenshots/Webkit/baseline/app-bar-en.png +0 -0
- package/screenshots/Webkit/baseline/document-name-de.png +0 -0
- package/screenshots/Webkit/baseline/document-name-en.png +0 -0
- package/screenshots/Webkit/baseline/editor-plugins-de.png +0 -0
- package/screenshots/Webkit/baseline/editor-plugins-en.png +0 -0
- package/screenshots/Webkit/baseline/editor-plugins-selected-de.png +0 -0
- package/screenshots/Webkit/baseline/editor-plugins-selected-en.png +0 -0
- package/screenshots/Webkit/baseline/editor-plugins-with-doc-de.png +0 -0
- package/screenshots/Webkit/baseline/editor-plugins-with-doc-en.png +0 -0
- package/screenshots/Webkit/baseline/log-entries-de.png +0 -0
- package/screenshots/Webkit/baseline/log-entries-en.png +0 -0
- package/screenshots/Webkit/baseline/log-entries-redone-de.png +0 -0
- package/screenshots/Webkit/baseline/log-entries-redone-en.png +0 -0
- package/screenshots/Webkit/baseline/log-entries-undone-de.png +0 -0
- package/screenshots/Webkit/baseline/log-entries-undone-en.png +0 -0
- package/screenshots/Webkit/baseline/log-screen-de.png +0 -0
- package/screenshots/Webkit/baseline/log-screen-en.png +0 -0
- package/screenshots/Webkit/baseline/menu-drawer-de.png +0 -0
- package/screenshots/Webkit/baseline/menu-drawer-en.png +0 -0
- package/screenshots/Webkit/baseline/menu-plugins-de.png +0 -0
- package/screenshots/Webkit/baseline/menu-plugins-en.png +0 -0
- package/screenshots/Webkit/baseline/menu-plugins-triggered-de.png +0 -0
- package/screenshots/Webkit/baseline/menu-plugins-triggered-en.png +0 -0
- package/tsconfig.json +0 -23
- package/utils/testing.spec.ts +0 -210
- package/utils/testing.ts +0 -65
- package/web-dev-server.config.js +0 -24
- package/web-test-runner.config.js +0 -180
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Hashes `str` using the cyrb64 variant of
|
|
3
|
+
* https://github.com/bryc/code/blob/master/jshash/experimental/cyrb53.js
|
|
4
|
+
* @returns digest - a rather insecure hash, very quickly
|
|
5
|
+
*/
|
|
6
|
+
export function cyrb64(str) {
|
|
7
|
+
/* eslint-disable no-bitwise */
|
|
8
|
+
let h1 = 0xdeadbeef;
|
|
9
|
+
let h2 = 0x41c6ce57;
|
|
10
|
+
/* eslint-disable-next-line no-plusplus */
|
|
11
|
+
for (let i = 0, ch; i < str.length; i++) {
|
|
12
|
+
ch = str.charCodeAt(i);
|
|
13
|
+
h1 = Math.imul(h1 ^ ch, 2654435761);
|
|
14
|
+
h2 = Math.imul(h2 ^ ch, 1597334677);
|
|
15
|
+
}
|
|
16
|
+
h1 =
|
|
17
|
+
Math.imul(h1 ^ (h1 >>> 16), 2246822507) ^
|
|
18
|
+
Math.imul(h2 ^ (h2 >>> 13), 3266489909);
|
|
19
|
+
h2 =
|
|
20
|
+
Math.imul(h2 ^ (h2 >>> 16), 2246822507) ^
|
|
21
|
+
Math.imul(h1 ^ (h1 >>> 13), 3266489909);
|
|
22
|
+
return ((h2 >>> 0).toString(16).padStart(8, '0') +
|
|
23
|
+
(h1 >>> 0).toString(16).padStart(8, '0'));
|
|
24
|
+
/* eslint-enable no-bitwise */
|
|
25
|
+
}
|
|
26
|
+
//# sourceMappingURL=cyrb64.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cyrb64.js","sourceRoot":"","sources":["../../foundation/cyrb64.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,MAAM,UAAU,MAAM,CAAC,GAAW;IAChC,+BAA+B;IAC/B,IAAI,EAAE,GAAG,UAAU,CAAC;IACpB,IAAI,EAAE,GAAG,UAAU,CAAC;IACpB,0CAA0C;IAC1C,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,EAAE,EAAE,CAAC,GAAG,GAAG,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;QACxC,EAAE,GAAG,GAAG,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC;QACvB,EAAE,GAAG,IAAI,CAAC,IAAI,CAAC,EAAE,GAAG,EAAE,EAAE,UAAU,CAAC,CAAC;QACpC,EAAE,GAAG,IAAI,CAAC,IAAI,CAAC,EAAE,GAAG,EAAE,EAAE,UAAU,CAAC,CAAC;IACtC,CAAC;IACD,EAAE;QACA,IAAI,CAAC,IAAI,CAAC,EAAE,GAAG,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,UAAU,CAAC;YACvC,IAAI,CAAC,IAAI,CAAC,EAAE,GAAG,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,UAAU,CAAC,CAAC;IAC1C,EAAE;QACA,IAAI,CAAC,IAAI,CAAC,EAAE,GAAG,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,UAAU,CAAC;YACvC,IAAI,CAAC,IAAI,CAAC,EAAE,GAAG,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,UAAU,CAAC,CAAC;IAC1C,OAAO,CACL,CAAC,EAAE,KAAK,CAAC,CAAC,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,EAAE,GAAG,CAAC;QACxC,CAAC,EAAE,KAAK,CAAC,CAAC,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,EAAE,GAAG,CAAC,CACzC,CAAC;IACF,8BAA8B;AAChC,CAAC","sourcesContent":["/**\n * Hashes `str` using the cyrb64 variant of\n * https://github.com/bryc/code/blob/master/jshash/experimental/cyrb53.js\n * @returns digest - a rather insecure hash, very quickly\n */\nexport function cyrb64(str: string): string {\n /* eslint-disable no-bitwise */\n let h1 = 0xdeadbeef;\n let h2 = 0x41c6ce57;\n /* eslint-disable-next-line no-plusplus */\n for (let i = 0, ch; i < str.length; i++) {\n ch = str.charCodeAt(i);\n h1 = Math.imul(h1 ^ ch, 2654435761);\n h2 = Math.imul(h2 ^ ch, 1597334677);\n }\n h1 =\n Math.imul(h1 ^ (h1 >>> 16), 2246822507) ^\n Math.imul(h2 ^ (h2 >>> 13), 3266489909);\n h2 =\n Math.imul(h2 ^ (h2 >>> 16), 2246822507) ^\n Math.imul(h1 ^ (h1 >>> 13), 3266489909);\n return (\n (h2 >>> 0).toString(16).padStart(8, '0') +\n (h1 >>> 0).toString(16).padStart(8, '0')\n );\n /* eslint-enable no-bitwise */\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { cyrb64 } from './foundation/cyrb64.js';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"foundation.js","sourceRoot":"","sources":["../foundation.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAC","sourcesContent":["export { cyrb64 } from './foundation/cyrb64.js';\n"]}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export declare const templates: {
|
|
2
|
+
s1b528387ae29637a: string;
|
|
3
|
+
s2ceb11be2290bb1b: string;
|
|
4
|
+
s60320a18282b2b33: string;
|
|
5
|
+
s690714fde574c188: string;
|
|
6
|
+
s6d8c02aee480af7a: string;
|
|
7
|
+
s737e3dbdf9c08cdf: string;
|
|
8
|
+
s7417792bbe720149: string;
|
|
9
|
+
s8f4be9f086eb530f: string;
|
|
10
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
// Do not modify this file by hand!
|
|
2
|
+
// Re-generate this file by running lit-localize
|
|
3
|
+
/* eslint-disable no-irregular-whitespace */
|
|
4
|
+
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
5
|
+
export const templates = {
|
|
6
|
+
's1b528387ae29637a': `Dateiendung`,
|
|
7
|
+
's2ceb11be2290bb1b': `Abbrechen`,
|
|
8
|
+
's60320a18282b2b33': `Umbenennen`,
|
|
9
|
+
's690714fde574c188': `Dateiname`,
|
|
10
|
+
's6d8c02aee480af7a': `Menü`,
|
|
11
|
+
's737e3dbdf9c08cdf': `Datei schließen`,
|
|
12
|
+
's7417792bbe720149': `Wiederholen`,
|
|
13
|
+
's8f4be9f086eb530f': `Rückgängig`,
|
|
14
|
+
};
|
|
15
|
+
//# sourceMappingURL=de.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"de.js","sourceRoot":"","sources":["../../locales/de.ts"],"names":[],"mappings":"AACI,mCAAmC;AACnC,gDAAgD;AAKhD,4CAA4C;AAC5C,uDAAuD;AAEvD,MAAM,CAAC,MAAM,SAAS,GAAG;IACvB,mBAAmB,EAAE,aAAa;IACxC,mBAAmB,EAAE,WAAW;IAChC,mBAAmB,EAAE,YAAY;IACjC,mBAAmB,EAAE,WAAW;IAChC,mBAAmB,EAAE,MAAM;IAC3B,mBAAmB,EAAE,iBAAiB;IACtC,mBAAmB,EAAE,aAAa;IAClC,mBAAmB,EAAE,YAAY;CAC5B,CAAC","sourcesContent":["\n // Do not modify this file by hand!\n // Re-generate this file by running lit-localize\n\n \n \n\n /* eslint-disable no-irregular-whitespace */\n /* eslint-disable @typescript-eslint/no-explicit-any */\n\n export const templates = {\n 's1b528387ae29637a': `Dateiendung`,\n's2ceb11be2290bb1b': `Abbrechen`,\n's60320a18282b2b33': `Umbenennen`,\n's690714fde574c188': `Dateiname`,\n's6d8c02aee480af7a': `Menü`,\n's737e3dbdf9c08cdf': `Datei schließen`,\n's7417792bbe720149': `Wiederholen`,\n's8f4be9f086eb530f': `Rückgängig`,\n };\n "]}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The locale code that templates in this source code are written in.
|
|
3
|
+
*/
|
|
4
|
+
export declare const sourceLocale = "en";
|
|
5
|
+
/**
|
|
6
|
+
* The other locale codes that this application is localized into. Sorted
|
|
7
|
+
* lexicographically.
|
|
8
|
+
*/
|
|
9
|
+
export declare const targetLocales: readonly ["de"];
|
|
10
|
+
/**
|
|
11
|
+
* All valid project locale codes. Sorted lexicographically.
|
|
12
|
+
*/
|
|
13
|
+
export declare const allLocales: readonly ["de", "en"];
|
package/dist/locales.js
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
// Do not modify this file by hand!
|
|
2
|
+
// Re-generate this file by running lit-localize.
|
|
3
|
+
/**
|
|
4
|
+
* The locale code that templates in this source code are written in.
|
|
5
|
+
*/
|
|
6
|
+
export const sourceLocale = `en`;
|
|
7
|
+
/**
|
|
8
|
+
* The other locale codes that this application is localized into. Sorted
|
|
9
|
+
* lexicographically.
|
|
10
|
+
*/
|
|
11
|
+
export const targetLocales = [
|
|
12
|
+
`de`,
|
|
13
|
+
];
|
|
14
|
+
/**
|
|
15
|
+
* All valid project locale codes. Sorted lexicographically.
|
|
16
|
+
*/
|
|
17
|
+
export const allLocales = [
|
|
18
|
+
`de`,
|
|
19
|
+
`en`,
|
|
20
|
+
];
|
|
21
|
+
//# sourceMappingURL=locales.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"locales.js","sourceRoot":"","sources":["../locales.ts"],"names":[],"mappings":"AAAA,mCAAmC;AACnC,iDAAiD;AAEjD;;GAEG;AACH,MAAM,CAAC,MAAM,YAAY,GAAG,IAAI,CAAC;AAEjC;;;GAGG;AACH,MAAM,CAAC,MAAM,aAAa,GAAG;IAC3B,IAAI;CACI,CAAC;AAEX;;GAEG;AACH,MAAM,CAAC,MAAM,UAAU,GAAG;IACxB,IAAI;IACJ,IAAI;CACI,CAAC","sourcesContent":["// Do not modify this file by hand!\n// Re-generate this file by running lit-localize.\n\n/**\n * The locale code that templates in this source code are written in.\n */\nexport const sourceLocale = `en`;\n\n/**\n * The other locale codes that this application is localized into. Sorted\n * lexicographically.\n */\nexport const targetLocales = [\n `de`,\n] as const;\n\n/**\n * All valid project locale codes. Sorted lexicographically.\n */\nexport const allLocales = [\n `de`,\n `en`,\n] as const;\n"]}
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
import '@webcomponents/scoped-custom-element-registry';
|
|
2
|
+
import { LitElement, TemplateResult } from 'lit';
|
|
3
|
+
import { OscdAppBar } from '@omicronenergy/oscd-ui/app-bar/OscdAppBar.js';
|
|
4
|
+
import { OscdDialog } from '@omicronenergy/oscd-ui/dialog/OscdDialog.js';
|
|
5
|
+
import { OscdDivider } from '@omicronenergy/oscd-ui/divider/OscdDivider.js';
|
|
6
|
+
import { OscdFilledIconButton } from '@omicronenergy/oscd-ui/iconbutton/OscdFilledIconButton.js';
|
|
7
|
+
import { OscdFilledSelect } from '@omicronenergy/oscd-ui/select/OscdFilledSelect.js';
|
|
8
|
+
import { OscdFilledTextField } from '@omicronenergy/oscd-ui/textfield/OscdFilledTextField.js';
|
|
9
|
+
import { OscdIcon } from '@omicronenergy/oscd-ui/icon/OscdIcon.js';
|
|
10
|
+
import { OscdList } from '@omicronenergy/oscd-ui/list/OscdList.js';
|
|
11
|
+
import { OscdListItem } from '@omicronenergy/oscd-ui/list/OscdListItem.js';
|
|
12
|
+
import { OscdMenu } from '@omicronenergy/oscd-ui/menu/OscdMenu.js';
|
|
13
|
+
import { OscdMenuItem } from '@omicronenergy/oscd-ui/menu/OscdMenuItem.js';
|
|
14
|
+
import { OscdNavigationDrawer } from '@omicronenergy/oscd-ui/navigation-drawer/OscdNavigationDrawer.js';
|
|
15
|
+
import { OscdNavigationDrawerHeader } from '@omicronenergy/oscd-ui/navigation-drawer/OscdNavigationDrawerHeader.js';
|
|
16
|
+
import { OscdSecondaryTab } from '@omicronenergy/oscd-ui/tabs/OscdSecondaryTab.js';
|
|
17
|
+
import { OscdSelectOption } from '@omicronenergy/oscd-ui/select/OscdSelectOption.js';
|
|
18
|
+
import { OscdTabs } from '@omicronenergy/oscd-ui/tabs/OscdTabs.js';
|
|
19
|
+
import { OscdTextButton } from '@omicronenergy/oscd-ui/button/OscdTextButton.js';
|
|
20
|
+
import { XMLEditor } from '@omicronenergy/oscd-editor';
|
|
21
|
+
import { OpenEvent } from '@omicronenergy/oscd-api';
|
|
22
|
+
import { allLocales, targetLocales } from './locales.js';
|
|
23
|
+
export type Plugin = {
|
|
24
|
+
name: string;
|
|
25
|
+
translations?: Record<(typeof targetLocales)[number], string>;
|
|
26
|
+
src: string;
|
|
27
|
+
icon: string;
|
|
28
|
+
requireDoc?: boolean;
|
|
29
|
+
};
|
|
30
|
+
export type PluginSet = {
|
|
31
|
+
menu: Plugin[];
|
|
32
|
+
editor: Plugin[];
|
|
33
|
+
background: Plugin[];
|
|
34
|
+
};
|
|
35
|
+
type Control = {
|
|
36
|
+
icon: string;
|
|
37
|
+
getName: () => string;
|
|
38
|
+
isDisabled: () => boolean;
|
|
39
|
+
action?: () => void | Promise<void>;
|
|
40
|
+
};
|
|
41
|
+
type RenderedPlugin = Control & {
|
|
42
|
+
tagName: string;
|
|
43
|
+
};
|
|
44
|
+
type LocaleTag = (typeof allLocales)[number];
|
|
45
|
+
declare const OpenSCD_base: typeof LitElement & import("@open-wc/scoped-elements/lit-element.js").ScopedElementsHostConstructor;
|
|
46
|
+
export declare class OpenSCD extends OpenSCD_base {
|
|
47
|
+
#private;
|
|
48
|
+
static get scopedElements(): {
|
|
49
|
+
'oscd-app-bar': typeof OscdAppBar;
|
|
50
|
+
'oscd-dialog': typeof OscdDialog;
|
|
51
|
+
'oscd-icon': typeof OscdIcon;
|
|
52
|
+
'oscd-filled-text-field': typeof OscdFilledTextField;
|
|
53
|
+
'oscd-filled-select': typeof OscdFilledSelect;
|
|
54
|
+
'oscd-select-option': typeof OscdSelectOption;
|
|
55
|
+
'oscd-filled-icon-button': typeof OscdFilledIconButton;
|
|
56
|
+
'oscd-list': typeof OscdList;
|
|
57
|
+
'oscd-list-item': typeof OscdListItem;
|
|
58
|
+
'oscd-divider': typeof OscdDivider;
|
|
59
|
+
'oscd-menu-item': typeof OscdMenuItem;
|
|
60
|
+
'oscd-navigation-drawer': typeof OscdNavigationDrawer;
|
|
61
|
+
'oscd-navigation-drawer-header': typeof OscdNavigationDrawerHeader;
|
|
62
|
+
'oscd-secondary-tab': typeof OscdSecondaryTab;
|
|
63
|
+
'oscd-tabs': typeof OscdTabs;
|
|
64
|
+
'oscd-text-button': typeof OscdTextButton;
|
|
65
|
+
'oscd-menu': typeof OscdMenu;
|
|
66
|
+
};
|
|
67
|
+
get doc(): XMLDocument;
|
|
68
|
+
xmlEditor: XMLEditor;
|
|
69
|
+
get last(): number;
|
|
70
|
+
get canUndo(): boolean;
|
|
71
|
+
get canRedo(): boolean;
|
|
72
|
+
/** The set of `XMLDocument`s currently loaded */
|
|
73
|
+
docs: Record<string, XMLDocument>;
|
|
74
|
+
/** The name of the [[`doc`]] currently being edited */
|
|
75
|
+
docName: string;
|
|
76
|
+
/** The file endings of editable files */
|
|
77
|
+
editable: string[];
|
|
78
|
+
isEditable(docName: string): boolean;
|
|
79
|
+
get editableDocs(): string[];
|
|
80
|
+
get plugins(): PluginSet;
|
|
81
|
+
set plugins(plugins: Partial<PluginSet>);
|
|
82
|
+
get loadedPlugins(): PluginSet;
|
|
83
|
+
addLoadedPlugin(tagName: string, kind: keyof PluginSet, plugin: Plugin, index: number): void;
|
|
84
|
+
handleOpenDoc({ detail: { docName, doc } }: OpenEvent): void;
|
|
85
|
+
/** Undo the last `n` [[Edit]]s committed */
|
|
86
|
+
undo(n?: number): void;
|
|
87
|
+
/** Redo the last `n` [[Edit]]s that have been undone */
|
|
88
|
+
redo(n?: number): void;
|
|
89
|
+
editFileUI: OscdDialog;
|
|
90
|
+
menuUI: OscdNavigationDrawer;
|
|
91
|
+
fileNameUI: HTMLInputElement;
|
|
92
|
+
fileExtensionUI: HTMLInputElement;
|
|
93
|
+
fileMenuUI: OscdMenu;
|
|
94
|
+
fileMenuButtonUI?: OscdFilledIconButton;
|
|
95
|
+
get locale(): LocaleTag;
|
|
96
|
+
set locale(tag: LocaleTag);
|
|
97
|
+
private editorIndex;
|
|
98
|
+
get editor(): string;
|
|
99
|
+
private controls;
|
|
100
|
+
get menu(): Required<Control>[];
|
|
101
|
+
get editors(): RenderedPlugin[];
|
|
102
|
+
private hotkeys;
|
|
103
|
+
private handleKeyPress;
|
|
104
|
+
constructor();
|
|
105
|
+
updated(changedProps: Map<string, unknown>): void;
|
|
106
|
+
render(): TemplateResult<1>;
|
|
107
|
+
firstUpdated(): void;
|
|
108
|
+
static styles: import("lit").CSSResult;
|
|
109
|
+
}
|
|
110
|
+
declare global {
|
|
111
|
+
interface HTMLElementTagNameMap {
|
|
112
|
+
'oscd-shell': OpenSCD;
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
export {};
|