@digital-realty/ix-dialog 1.0.4 → 1.0.6
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/IxDialog.d.ts +15 -1
- package/dist/IxDialog.js +38 -8
- package/dist/IxDialog.js.map +1 -1
- package/dist/ix-dialog.d.ts +4 -1
- package/dist/ix-dialog.js +10 -1
- package/dist/ix-dialog.js.map +1 -1
- package/package.json +2 -2
package/dist/IxDialog.d.ts
CHANGED
|
@@ -1,7 +1,21 @@
|
|
|
1
1
|
import { LitElement } from 'lit';
|
|
2
2
|
import '@material/web/dialog/dialog.js';
|
|
3
|
+
import { Dialog } from '@material/web/dialog/internal/dialog.js';
|
|
3
4
|
export declare class IxDialog extends LitElement {
|
|
4
|
-
|
|
5
|
+
/** @nocollapse */
|
|
6
|
+
static shadowRootOptions: {
|
|
7
|
+
delegatesFocus: boolean;
|
|
8
|
+
mode: ShadowRootMode;
|
|
9
|
+
slotAssignment?: SlotAssignmentMode | undefined;
|
|
10
|
+
customElements?: CustomElementRegistry | undefined;
|
|
11
|
+
registry?: CustomElementRegistry | undefined;
|
|
12
|
+
};
|
|
13
|
+
readonly component: Dialog;
|
|
5
14
|
open: boolean;
|
|
15
|
+
onOpen(): void;
|
|
16
|
+
onOpened(): void;
|
|
17
|
+
onClose(): void;
|
|
18
|
+
onClosed(): void;
|
|
19
|
+
onCancel(): void;
|
|
6
20
|
render(): import("lit-html").TemplateResult<1>;
|
|
7
21
|
}
|
package/dist/IxDialog.js
CHANGED
|
@@ -1,15 +1,39 @@
|
|
|
1
1
|
import { __decorate } from "tslib";
|
|
2
|
-
import { html,
|
|
3
|
-
import { property } from 'lit/decorators.js';
|
|
2
|
+
import { html, LitElement } from 'lit';
|
|
3
|
+
import { property, query } from 'lit/decorators.js';
|
|
4
4
|
import '@material/web/dialog/dialog.js';
|
|
5
|
+
import { requestUpdateOnAriaChange } from '@material/web/internal/aria/delegate.js';
|
|
5
6
|
export class IxDialog extends LitElement {
|
|
6
7
|
constructor() {
|
|
7
8
|
super(...arguments);
|
|
8
9
|
this.open = false;
|
|
9
10
|
}
|
|
11
|
+
onOpen() {
|
|
12
|
+
this.dispatchEvent(new Event('open'));
|
|
13
|
+
}
|
|
14
|
+
onOpened() {
|
|
15
|
+
this.dispatchEvent(new Event('opened'));
|
|
16
|
+
}
|
|
17
|
+
onClose() {
|
|
18
|
+
this.dispatchEvent(new Event('close'));
|
|
19
|
+
}
|
|
20
|
+
onClosed() {
|
|
21
|
+
this.dispatchEvent(new Event('closed'));
|
|
22
|
+
}
|
|
23
|
+
onCancel() {
|
|
24
|
+
this.dispatchEvent(new Event('cancel'));
|
|
25
|
+
}
|
|
10
26
|
render() {
|
|
11
27
|
return html `
|
|
12
|
-
<md-dialog
|
|
28
|
+
<md-dialog
|
|
29
|
+
?open=${this.open}
|
|
30
|
+
class="dialog"
|
|
31
|
+
@open=${this.onOpen}
|
|
32
|
+
@opened=${this.onOpened}
|
|
33
|
+
@close=${this.onClose}
|
|
34
|
+
@closed=${this.onClosed}
|
|
35
|
+
@cancel=${this.onCancel}
|
|
36
|
+
>
|
|
13
37
|
<slot slot="headline" name="headline"></slot>
|
|
14
38
|
<slot slot="content" name="content"></slot>
|
|
15
39
|
<slot slot="actions" name="actions"></slot>
|
|
@@ -18,11 +42,17 @@ export class IxDialog extends LitElement {
|
|
|
18
42
|
`;
|
|
19
43
|
}
|
|
20
44
|
}
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
45
|
+
(() => {
|
|
46
|
+
requestUpdateOnAriaChange(IxDialog);
|
|
47
|
+
})();
|
|
48
|
+
/** @nocollapse */
|
|
49
|
+
IxDialog.shadowRootOptions = {
|
|
50
|
+
...LitElement.shadowRootOptions,
|
|
51
|
+
delegatesFocus: true,
|
|
52
|
+
};
|
|
53
|
+
__decorate([
|
|
54
|
+
query('.dialog')
|
|
55
|
+
], IxDialog.prototype, "component", void 0);
|
|
26
56
|
__decorate([
|
|
27
57
|
property({ type: Boolean, reflect: true })
|
|
28
58
|
], IxDialog.prototype, "open", void 0);
|
package/dist/IxDialog.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"IxDialog.js","sourceRoot":"","sources":["../src/IxDialog.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,IAAI,EAAE,
|
|
1
|
+
{"version":3,"file":"IxDialog.js","sourceRoot":"","sources":["../src/IxDialog.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,KAAK,CAAC;AACvC,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,gCAAgC,CAAC;AAExC,OAAO,EAAE,yBAAyB,EAAE,MAAM,yCAAyC,CAAC;AAEpF,MAAM,OAAO,QAAS,SAAQ,UAAU;IAAxC;;QAc8C,SAAI,GAAG,KAAK,CAAC;IAwC3D,CAAC;IAtCC,MAAM;QACJ,IAAI,CAAC,aAAa,CAAC,IAAI,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC;IACxC,CAAC;IAED,QAAQ;QACN,IAAI,CAAC,aAAa,CAAC,IAAI,KAAK,CAAC,QAAQ,CAAC,CAAC,CAAC;IAC1C,CAAC;IAED,OAAO;QACL,IAAI,CAAC,aAAa,CAAC,IAAI,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC;IACzC,CAAC;IAED,QAAQ;QACN,IAAI,CAAC,aAAa,CAAC,IAAI,KAAK,CAAC,QAAQ,CAAC,CAAC,CAAC;IAC1C,CAAC;IAED,QAAQ;QACN,IAAI,CAAC,aAAa,CAAC,IAAI,KAAK,CAAC,QAAQ,CAAC,CAAC,CAAC;IAC1C,CAAC;IAED,MAAM;QACJ,OAAO,IAAI,CAAA;;gBAEC,IAAI,CAAC,IAAI;;gBAET,IAAI,CAAC,MAAM;kBACT,IAAI,CAAC,QAAQ;iBACd,IAAI,CAAC,OAAO;kBACX,IAAI,CAAC,QAAQ;kBACb,IAAI,CAAC,QAAQ;;;;;;;KAO1B,CAAC;IACJ,CAAC;;AApDD;IACE,yBAAyB,CAAC,QAAQ,CAAC,CAAC;AACtC,CAAC,GAAA,CAAA;AAED,kBAAkB;AACF,0BAAiB,GAAG;IAClC,GAAG,UAAU,CAAC,iBAAiB;IAC/B,cAAc,EAAE,IAAI;CACrB,CAAC;AAGF;IADC,KAAK,CAAC,SAAS,CAAC;2CACW;AAEgB;IAA3C,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;sCAAc","sourcesContent":["import { html, LitElement } from 'lit';\nimport { property, query } from 'lit/decorators.js';\nimport '@material/web/dialog/dialog.js';\nimport { Dialog } from '@material/web/dialog/internal/dialog.js';\nimport { requestUpdateOnAriaChange } from '@material/web/internal/aria/delegate.js';\n\nexport class IxDialog extends LitElement {\n static {\n requestUpdateOnAriaChange(IxDialog);\n }\n\n /** @nocollapse */\n static override shadowRootOptions = {\n ...LitElement.shadowRootOptions,\n delegatesFocus: true,\n };\n\n @query('.dialog')\n readonly component!: Dialog;\n\n @property({ type: Boolean, reflect: true }) open = false;\n\n onOpen() {\n this.dispatchEvent(new Event('open'));\n }\n\n onOpened() {\n this.dispatchEvent(new Event('opened'));\n }\n\n onClose() {\n this.dispatchEvent(new Event('close'));\n }\n\n onClosed() {\n this.dispatchEvent(new Event('closed'));\n }\n\n onCancel() {\n this.dispatchEvent(new Event('cancel'));\n }\n\n render() {\n return html`\n <md-dialog\n ?open=${this.open}\n class=\"dialog\"\n @open=${this.onOpen}\n @opened=${this.onOpened}\n @close=${this.onClose}\n @closed=${this.onClosed}\n @cancel=${this.onCancel}\n >\n <slot slot=\"headline\" name=\"headline\"></slot>\n <slot slot=\"content\" name=\"content\"></slot>\n <slot slot=\"actions\" name=\"actions\"></slot>\n ></md-dialog\n >\n `;\n }\n}\n"]}
|
package/dist/ix-dialog.d.ts
CHANGED
package/dist/ix-dialog.js
CHANGED
|
@@ -1,3 +1,12 @@
|
|
|
1
|
+
import { css } from 'lit';
|
|
1
2
|
import { IxDialog } from './IxDialog.js';
|
|
2
|
-
|
|
3
|
+
export class IxDialogStyled extends IxDialog {
|
|
4
|
+
}
|
|
5
|
+
IxDialogStyled.styles = css `
|
|
6
|
+
.dialog {
|
|
7
|
+
max-height: 90vh;
|
|
8
|
+
max-width: 90vw;
|
|
9
|
+
}
|
|
10
|
+
`;
|
|
11
|
+
window.customElements.define('ix-dialog', IxDialogStyled);
|
|
3
12
|
//# sourceMappingURL=ix-dialog.js.map
|
package/dist/ix-dialog.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ix-dialog.js","sourceRoot":"","sources":["../src/ix-dialog.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AAEzC,MAAM,CAAC,cAAc,CAAC,MAAM,CAAC,WAAW,EAAE,
|
|
1
|
+
{"version":3,"file":"ix-dialog.js","sourceRoot":"","sources":["../src/ix-dialog.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,KAAK,CAAC;AAC1B,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AAEzC,MAAM,OAAO,cAAe,SAAQ,QAAQ;;AAC1B,qBAAM,GAAG,GAAG,CAAA;;;;;GAK3B,CAAC;AAGJ,MAAM,CAAC,cAAc,CAAC,MAAM,CAAC,WAAW,EAAE,cAAc,CAAC,CAAC","sourcesContent":["import { css } from 'lit';\nimport { IxDialog } from './IxDialog.js';\n\nexport class IxDialogStyled extends IxDialog {\n static override styles = css`\n .dialog {\n max-height: 90vh;\n max-width: 90vw;\n }\n `;\n}\n\nwindow.customElements.define('ix-dialog', IxDialogStyled);\n"]}
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"description": "Webcomponent ix-dialog following open-wc recommendations",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"author": "Digital Realty",
|
|
6
|
-
"version": "1.0.
|
|
6
|
+
"version": "1.0.6",
|
|
7
7
|
"type": "module",
|
|
8
8
|
"main": "dist/index.js",
|
|
9
9
|
"module": "dist/index.js",
|
|
@@ -95,5 +95,5 @@
|
|
|
95
95
|
"README.md",
|
|
96
96
|
"LICENSE"
|
|
97
97
|
],
|
|
98
|
-
"gitHead": "
|
|
98
|
+
"gitHead": "d57dedc86cbf4e58a5f01445702dc5f540317d00"
|
|
99
99
|
}
|