@spectrum-web-components/dialog 0.31.1-react.2 → 0.31.1-react.21

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.
@@ -6,19 +6,46 @@
6
6
  "kind": "javascript-module",
7
7
  "path": "sp-dialog-base.ts",
8
8
  "declarations": [],
9
- "exports": []
9
+ "exports": [
10
+ {
11
+ "kind": "custom-element-definition",
12
+ "name": "sp-dialog-base",
13
+ "declaration": {
14
+ "name": "DialogBase",
15
+ "module": "/src/DialogBase.js"
16
+ }
17
+ }
18
+ ]
10
19
  },
11
20
  {
12
21
  "kind": "javascript-module",
13
22
  "path": "sp-dialog-wrapper.ts",
14
23
  "declarations": [],
15
- "exports": []
24
+ "exports": [
25
+ {
26
+ "kind": "custom-element-definition",
27
+ "name": "sp-dialog-wrapper",
28
+ "declaration": {
29
+ "name": "DialogWrapper",
30
+ "module": "/src/DialogWrapper.js"
31
+ }
32
+ }
33
+ ]
16
34
  },
17
35
  {
18
36
  "kind": "javascript-module",
19
37
  "path": "sp-dialog.ts",
20
38
  "declarations": [],
21
- "exports": []
39
+ "exports": [
40
+ {
41
+ "kind": "custom-element-definition",
42
+ "name": "sp-dialog",
43
+ "declaration": {
44
+ "name": "Dialog",
45
+ "module": "/src/Dialog.js"
46
+ }
47
+ }
48
+ ]
22
49
  },
23
50
  {
24
51
  "kind": "javascript-module",
@@ -94,7 +121,8 @@
94
121
  "type": {
95
122
  "text": "boolean"
96
123
  },
97
- "privacy": "protected"
124
+ "privacy": "protected",
125
+ "readonly": true
98
126
  },
99
127
  {
100
128
  "kind": "field",
@@ -102,7 +130,8 @@
102
130
  "type": {
103
131
  "text": "boolean"
104
132
  },
105
- "privacy": "protected"
133
+ "privacy": "protected",
134
+ "readonly": true
106
135
  },
107
136
  {
108
137
  "kind": "field",
@@ -110,7 +139,8 @@
110
139
  "type": {
111
140
  "text": "boolean"
112
141
  },
113
- "privacy": "protected"
142
+ "privacy": "protected",
143
+ "readonly": true
114
144
  },
115
145
  {
116
146
  "kind": "field",
@@ -454,7 +484,8 @@
454
484
  "type": {
455
485
  "text": "Dialog"
456
486
  },
457
- "privacy": "protected"
487
+ "privacy": "protected",
488
+ "readonly": true
458
489
  },
459
490
  {
460
491
  "kind": "method",
@@ -792,6 +823,7 @@
792
823
  "text": "Dialog"
793
824
  },
794
825
  "privacy": "protected",
826
+ "readonly": true,
795
827
  "inheritedFrom": {
796
828
  "name": "DialogBase",
797
829
  "module": "src/DialogBase.ts"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@spectrum-web-components/dialog",
3
- "version": "0.31.1-react.2+971de948d",
3
+ "version": "0.31.1-react.21+44f0b1df9",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -73,17 +73,17 @@
73
73
  "lit-html"
74
74
  ],
75
75
  "dependencies": {
76
- "@spectrum-web-components/base": "^0.31.1-react.2+971de948d",
77
- "@spectrum-web-components/button": "^0.31.1-react.2+971de948d",
78
- "@spectrum-web-components/button-group": "^0.31.1-react.2+971de948d",
79
- "@spectrum-web-components/divider": "^0.31.1-react.2+971de948d",
80
- "@spectrum-web-components/icons-workflow": "^0.31.1-react.2+971de948d",
81
- "@spectrum-web-components/modal": "^0.31.1-react.2+971de948d",
82
- "@spectrum-web-components/shared": "^0.31.1-react.2+971de948d",
83
- "@spectrum-web-components/underlay": "^0.31.1-react.2+971de948d"
76
+ "@spectrum-web-components/base": "^0.31.1-react.21+44f0b1df9",
77
+ "@spectrum-web-components/button": "^0.31.1-react.21+44f0b1df9",
78
+ "@spectrum-web-components/button-group": "^0.31.1-react.21+44f0b1df9",
79
+ "@spectrum-web-components/divider": "^0.31.1-react.21+44f0b1df9",
80
+ "@spectrum-web-components/icons-workflow": "^0.31.1-react.21+44f0b1df9",
81
+ "@spectrum-web-components/modal": "^0.31.1-react.21+44f0b1df9",
82
+ "@spectrum-web-components/shared": "^0.31.1-react.21+44f0b1df9",
83
+ "@spectrum-web-components/underlay": "^0.31.1-react.21+44f0b1df9"
84
84
  },
85
85
  "devDependencies": {
86
- "@spectrum-css/dialog": "^6.0.40"
86
+ "@spectrum-css/dialog": "^6.0.48"
87
87
  },
88
88
  "types": "./src/index.d.ts",
89
89
  "customElements": "custom-elements.json",
@@ -91,5 +91,5 @@
91
91
  "./sp-*.js",
92
92
  "./**/*.dev.js"
93
93
  ],
94
- "gitHead": "971de948df12f7082f13ab5dd5e638d456ebbb94"
94
+ "gitHead": "44f0b1df9e1ea77d9e931629a63918ceee2744c2"
95
95
  }
package/stories/index.js CHANGED
@@ -17,9 +17,10 @@ class OverlayTriggerReady extends HTMLElement {
17
17
  });
18
18
  }
19
19
  async setup() {
20
+ await nextFrame();
20
21
  await nextFrame();
21
22
  const overlay = document.querySelector(
22
- `overlay-trigger`
23
+ `overlay-trigger[open]`
23
24
  );
24
25
  overlay.addEventListener("sp-opened", this.handleTriggerOpened);
25
26
  }
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["index.ts"],
4
- "sourcesContent": ["/*\nCopyright 2022 Adobe. All rights reserved.\nThis file is licensed to you under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License. You may obtain a copy\nof the License at http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software distributed under\nthe License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\nOF ANY KIND, either express or implied. See the License for the specific language\ngoverning permissions and limitations under the License.\n*/\n\nimport { html, TemplateResult } from '@spectrum-web-components/base';\n\nfunction nextFrame(): Promise<void> {\n return new Promise((res) => requestAnimationFrame(() => res()));\n}\n\nclass OverlayTriggerReady extends HTMLElement {\n ready!: (value: boolean | PromiseLike<boolean>) => void;\n\n constructor() {\n super();\n this.readyPromise = new Promise((res) => {\n this.ready = res;\n this.setup();\n });\n }\n\n async setup(): Promise<void> {\n await nextFrame();\n\n const overlay = document.querySelector(\n `overlay-trigger`\n ) as HTMLElement;\n overlay.addEventListener('sp-opened', this.handleTriggerOpened);\n }\n\n handleTriggerOpened = async (): Promise<void> => {\n await nextFrame();\n\n this.ready(true);\n };\n\n private readyPromise: Promise<boolean> = Promise.resolve(false);\n\n get updateComplete(): Promise<boolean> {\n return this.readyPromise;\n }\n}\n\ncustomElements.define('overlay-trigger-ready', OverlayTriggerReady);\n\nexport const overlayTriggerDecorator = (\n story: () => TemplateResult\n): TemplateResult => {\n return html`\n ${story()}\n <overlay-trigger-ready></overlay-trigger-ready>\n `;\n};\n"],
5
- "mappings": ";AAYA,SAAS,YAA4B;AAErC,SAAS,YAA2B;AAChC,SAAO,IAAI,QAAQ,CAAC,QAAQ,sBAAsB,MAAM,IAAI,CAAC,CAAC;AAClE;AAEA,MAAM,4BAA4B,YAAY;AAAA,EAG1C,cAAc;AACV,UAAM;AAgBV,+BAAsB,YAA2B;AAC7C,YAAM,UAAU;AAEhB,WAAK,MAAM,IAAI;AAAA,IACnB;AAEA,SAAQ,eAAiC,QAAQ,QAAQ,KAAK;AArB1D,SAAK,eAAe,IAAI,QAAQ,CAAC,QAAQ;AACrC,WAAK,QAAQ;AACb,WAAK,MAAM;AAAA,IACf,CAAC;AAAA,EACL;AAAA,EAEA,MAAM,QAAuB;AACzB,UAAM,UAAU;AAEhB,UAAM,UAAU,SAAS;AAAA,MACrB;AAAA,IACJ;AACA,YAAQ,iBAAiB,aAAa,KAAK,mBAAmB;AAAA,EAClE;AAAA,EAUA,IAAI,iBAAmC;AACnC,WAAO,KAAK;AAAA,EAChB;AACJ;AAEA,eAAe,OAAO,yBAAyB,mBAAmB;AAE3D,aAAM,0BAA0B,CACnC,UACiB;AACjB,SAAO;AAAA,UACD,MAAM;AAAA;AAAA;AAGhB;",
4
+ "sourcesContent": ["/*\nCopyright 2022 Adobe. All rights reserved.\nThis file is licensed to you under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License. You may obtain a copy\nof the License at http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software distributed under\nthe License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\nOF ANY KIND, either express or implied. See the License for the specific language\ngoverning permissions and limitations under the License.\n*/\n\nimport { html, TemplateResult } from '@spectrum-web-components/base';\n\nfunction nextFrame(): Promise<void> {\n return new Promise((res) => requestAnimationFrame(() => res()));\n}\n\nclass OverlayTriggerReady extends HTMLElement {\n ready!: (value: boolean | PromiseLike<boolean>) => void;\n\n constructor() {\n super();\n this.readyPromise = new Promise((res) => {\n this.ready = res;\n this.setup();\n });\n }\n\n async setup(): Promise<void> {\n await nextFrame();\n await nextFrame();\n\n const overlay = document.querySelector(\n `overlay-trigger[open]`\n ) as HTMLElement;\n overlay.addEventListener('sp-opened', this.handleTriggerOpened);\n }\n\n handleTriggerOpened = async (): Promise<void> => {\n await nextFrame();\n\n this.ready(true);\n };\n\n private readyPromise: Promise<boolean> = Promise.resolve(false);\n\n get updateComplete(): Promise<boolean> {\n return this.readyPromise;\n }\n}\n\ncustomElements.define('overlay-trigger-ready', OverlayTriggerReady);\n\nexport const overlayTriggerDecorator = (\n story: () => TemplateResult\n): TemplateResult => {\n return html`\n ${story()}\n <overlay-trigger-ready></overlay-trigger-ready>\n `;\n};\n"],
5
+ "mappings": ";AAYA,SAAS,YAA4B;AAErC,SAAS,YAA2B;AAChC,SAAO,IAAI,QAAQ,CAAC,QAAQ,sBAAsB,MAAM,IAAI,CAAC,CAAC;AAClE;AAEA,MAAM,4BAA4B,YAAY;AAAA,EAG1C,cAAc;AACV,UAAM;AAiBV,+BAAsB,YAA2B;AAC7C,YAAM,UAAU;AAEhB,WAAK,MAAM,IAAI;AAAA,IACnB;AAEA,SAAQ,eAAiC,QAAQ,QAAQ,KAAK;AAtB1D,SAAK,eAAe,IAAI,QAAQ,CAAC,QAAQ;AACrC,WAAK,QAAQ;AACb,WAAK,MAAM;AAAA,IACf,CAAC;AAAA,EACL;AAAA,EAEA,MAAM,QAAuB;AACzB,UAAM,UAAU;AAChB,UAAM,UAAU;AAEhB,UAAM,UAAU,SAAS;AAAA,MACrB;AAAA,IACJ;AACA,YAAQ,iBAAiB,aAAa,KAAK,mBAAmB;AAAA,EAClE;AAAA,EAUA,IAAI,iBAAmC;AACnC,WAAO,KAAK;AAAA,EAChB;AACJ;AAEA,eAAe,OAAO,yBAAyB,mBAAmB;AAE3D,aAAM,0BAA0B,CACnC,UACiB;AACjB,SAAO;AAAA,UACD,MAAM;AAAA;AAAA;AAGhB;",
6
6
  "names": []
7
7
  }