@epa-wg/custom-element-dist 0.0.27 → 0.0.29

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.
Files changed (187) hide show
  1. package/.storybook/main.ts +2 -2
  2. package/README.md +4 -4
  3. package/coverage/coverage-final.json +21 -22
  4. package/coverage/index.html +19 -34
  5. package/coverage/src/custom-element/coverage.svg +1 -1
  6. package/coverage/src/custom-element/custom-element.js/coverage.svg +1 -1
  7. package/coverage/src/custom-element/custom-element.js.html +491 -368
  8. package/coverage/src/custom-element/http-request.js.html +12 -12
  9. package/coverage/src/custom-element/index.html +19 -19
  10. package/coverage/src/custom-element/local-storage.js.html +52 -52
  11. package/coverage/src/custom-element/location-element.js.html +4 -4
  12. package/coverage/src/custom-element/module-url.js.html +1 -1
  13. package/coverage/src/index.html +1 -1
  14. package/coverage/src/mocks/handlers.ts.html +1 -1
  15. package/coverage/src/mocks/index.html +1 -1
  16. package/coverage/src/stories/attributes.test.stories.ts.html +11 -2
  17. package/coverage/src/stories/css.test.stories.ts.html +8 -2
  18. package/coverage/src/stories/dom-merge.test.stories.ts.html +3 -3
  19. package/coverage/src/stories/external-template.test.stories.ts.html +8 -2
  20. package/coverage/src/stories/form.test.stories.ts.html +8 -2
  21. package/coverage/src/stories/http-request.stories.ts.html +1 -1
  22. package/coverage/src/stories/index.html +1 -1
  23. package/coverage/src/stories/local-storage.test.stories.ts.html +24 -18
  24. package/coverage/src/stories/location-element.test.stories.ts.html +8 -2
  25. package/coverage/src/stories/module-url.test.stories.ts.html +8 -2
  26. package/coverage/src/stories/set-url.test.stories.ts.html +8 -2
  27. package/coverage/src/stories/slice-events.test.stories.ts.html +8 -2
  28. package/coverage/src/stories/slots.test.stories.ts.html +8 -2
  29. package/coverage/src/stories/testStoryBook.ts.html +12 -12
  30. package/coverage/src/stories/version-select.test.stories.ts.html +8 -2
  31. package/coverage/src/sum.ts.html +1 -1
  32. package/dist/custom-element-BOIPgtxz.js +565 -0
  33. package/dist/custom-element-CUsSENWc.cjs +97 -0
  34. package/dist/custom-element-bundle.cjs +1 -1
  35. package/dist/custom-element-bundle.js +22 -21
  36. package/dist/demo/a.svg +26 -26
  37. package/dist/demo/demo.css +0 -3
  38. package/dist/demo/s.xml +18 -3
  39. package/dist/demo/s.xslt +37 -54
  40. package/dist/demo/ss.html +24 -57
  41. package/package.json +13 -13
  42. package/public/demo/a.svg +26 -26
  43. package/public/demo/demo.css +0 -3
  44. package/public/demo/s.xml +18 -3
  45. package/public/demo/s.xslt +37 -54
  46. package/public/demo/ss.html +24 -57
  47. package/src/custom-element/custom-element.js +61 -20
  48. package/src/custom-element/demo/a.svg +26 -26
  49. package/src/custom-element/demo/demo.css +0 -3
  50. package/src/custom-element/demo/s.xml +18 -3
  51. package/src/custom-element/demo/s.xslt +37 -54
  52. package/src/custom-element/demo/ss.html +24 -57
  53. package/src/custom-element/ide/web-types-dce.json +1 -1
  54. package/src/custom-element/ide/web-types-xsl.json +1 -1
  55. package/src/dce-social-preview.png +0 -0
  56. package/src/material/angular.css +987 -0
  57. package/src/material/components/autocomplete.html +241 -0
  58. package/src/material/components/dropdown.html +115 -0
  59. package/src/material/components/icon-link.html +161 -0
  60. package/src/material/components/menu.html +235 -0
  61. package/src/material/components.html +121 -0
  62. package/src/material/demo.css +31 -0
  63. package/src/material/index.html +111 -0
  64. package/src/material/material.css +357 -0
  65. package/src/material/theme/README.md +18 -0
  66. package/src/material/theme/semantic.css +112 -0
  67. package/src/mocks/versions.mock.ts +8 -8
  68. package/src/stories/attributes.test.stories.ts +3 -0
  69. package/src/stories/css.test.stories.ts +2 -0
  70. package/src/stories/dom-merge.test.stories.ts +2 -2
  71. package/src/stories/external-template.test.stories.ts +2 -0
  72. package/src/stories/form.test.stories.ts +2 -0
  73. package/src/stories/local-storage.test.stories.ts +2 -0
  74. package/src/stories/location-element.test.stories.ts +2 -0
  75. package/src/stories/module-url.test.stories.ts +2 -0
  76. package/src/stories/set-url.test.stories.ts +2 -0
  77. package/src/stories/slice-events.test.stories.ts +2 -0
  78. package/src/stories/slots.test.stories.ts +2 -0
  79. package/src/stories/version-select.test.stories.ts +2 -0
  80. package/storybook-static/assets/Color-ERTF36HU-CQkSD2nd.js +1 -0
  81. package/storybook-static/assets/Configure-DOhzHFEs.js +165 -0
  82. package/storybook-static/assets/DocsRenderer-CFRXHY34-BSJkbsd6.js +2 -0
  83. package/storybook-static/assets/{attributes.test.stories-Bt5V18qO.js → attributes.test.stories-BJBuuXgZ.js} +4 -4
  84. package/storybook-static/assets/{css.test.stories-CGYy2daE.js → css.test.stories-pgbBc17d.js} +1 -1
  85. package/storybook-static/assets/custom-element-BDGsYgbP.js +97 -0
  86. package/storybook-static/assets/{dom-merge.test.stories-XlsZ0UvX.js → dom-merge.test.stories-CXcYP_-J.js} +5 -5
  87. package/storybook-static/assets/entry-preview-C313OLrj.js +26 -0
  88. package/storybook-static/assets/{entry-preview-docs-BMKNVQXA.js → entry-preview-docs-B7ORr9w5.js} +2 -2
  89. package/storybook-static/assets/{external-template.test.stories-Bt_Pflu8.js → external-template.test.stories-CpJ68Ghy.js} +13 -13
  90. package/storybook-static/assets/{form.test.stories-B0NoI8wm.js → form.test.stories-D35lyqd8.js} +2 -2
  91. package/storybook-static/assets/{handlers-B5969HUu.js → handlers-CW9pDZnt.js} +6 -6
  92. package/storybook-static/assets/{http-request.stories-B2skuTFV.js → http-request.stories-CBbknCOO.js} +6 -6
  93. package/storybook-static/assets/iframe-DOi4N7qI.js +2 -0
  94. package/storybook-static/assets/{index-C7lvoJNv.js → index-B3QjF0Ed.js} +1 -1
  95. package/storybook-static/assets/index-BSz1w4Gl.js +234 -0
  96. package/storybook-static/assets/index-BdcJ-iJ7.js +8 -0
  97. package/storybook-static/assets/index-CaL3Qp7t.js +634 -0
  98. package/storybook-static/assets/index-DgFM0Ce3.js +1 -0
  99. package/storybook-static/assets/index-YxUFxnQR.js +1 -0
  100. package/storybook-static/assets/{local-storage.test.stories-DfY6feqG.js → local-storage.test.stories-BY-PWhuk.js} +5 -5
  101. package/storybook-static/assets/{location-element.test.stories-944AotIJ.js → location-element.test.stories-3auBYEaU.js} +3 -3
  102. package/storybook-static/assets/{module-url.test.stories-DSKcwApl.js → module-url.test.stories-B7L9cL60.js} +6 -6
  103. package/storybook-static/assets/{preview-0Jj89qip.js → preview-BRPR-UXC.js} +1 -1
  104. package/storybook-static/assets/{preview-DB9FwMii.js → preview-BWzBA1C2.js} +1 -1
  105. package/storybook-static/assets/preview-BhhEZcNS.js +1 -0
  106. package/storybook-static/assets/{preview-CadgX-4y.js → preview-C992A1Y-.js} +2 -2
  107. package/storybook-static/assets/preview-CcS4DQh8.js +1 -0
  108. package/storybook-static/assets/{preview-AJR7rVPD.js → preview-CfWMRsRq.js} +1 -1
  109. package/storybook-static/assets/{preview-FpHGYA1q.js → preview-DHPc-V4N.js} +1 -1
  110. package/storybook-static/assets/preview-DYzi3Z2p.js +1 -0
  111. package/storybook-static/assets/{preview-4Up_z4Em.js → preview-caVMbCIR.js} +2 -2
  112. package/storybook-static/assets/preview-ncvtW_hb.js +34 -0
  113. package/storybook-static/assets/{set-url.test.stories-DjLHKkEh.js → set-url.test.stories-CuSuDLIx.js} +3 -3
  114. package/storybook-static/assets/{slice-events.test.stories-8I_BrHd6.js → slice-events.test.stories-BkRKsKem.js} +4 -4
  115. package/storybook-static/assets/{slots.test.stories-CvZz4jyP.js → slots.test.stories-BJCUWFkE.js} +8 -8
  116. package/storybook-static/assets/{version-select.test.stories-DSxmJylI.js → version-select.test.stories-B3ybJn_Z.js} +2 -2
  117. package/storybook-static/demo/a.svg +26 -26
  118. package/storybook-static/demo/demo.css +0 -3
  119. package/storybook-static/demo/s.xml +18 -3
  120. package/storybook-static/demo/s.xslt +37 -54
  121. package/storybook-static/demo/ss.html +24 -57
  122. package/storybook-static/iframe.html +1 -1
  123. package/storybook-static/index.html +3 -7
  124. package/storybook-static/project.json +1 -1
  125. package/storybook-static/sb-addons/essentials-actions-3/manager-bundle.js +1 -1
  126. package/storybook-static/sb-addons/essentials-backgrounds-4/manager-bundle.js +9 -9
  127. package/storybook-static/sb-addons/essentials-controls-2/manager-bundle.js +76 -94
  128. package/storybook-static/sb-addons/essentials-measure-7/manager-bundle.js +1 -1
  129. package/storybook-static/sb-addons/essentials-outline-8/manager-bundle.js +1 -1
  130. package/storybook-static/sb-addons/essentials-toolbars-6/manager-bundle.js +1 -1
  131. package/storybook-static/sb-addons/essentials-viewport-5/manager-bundle.js +1 -1
  132. package/storybook-static/sb-addons/interactions-9/manager-bundle.js +211 -0
  133. package/storybook-static/sb-addons/interactions-9/manager-bundle.js.LEGAL.txt +0 -0
  134. package/storybook-static/sb-manager/globals-module-info.js +11 -0
  135. package/storybook-static/sb-manager/globals-runtime.js +27803 -26928
  136. package/storybook-static/sb-manager/runtime.js +10341 -10136
  137. package/storybook-static/sb-preview/runtime.js +3841 -3828
  138. package/.idea/custom-element-dist.iml +0 -9
  139. package/.idea/misc.xml +0 -6
  140. package/.idea/modules.xml +0 -8
  141. package/.idea/vcs.xml +0 -6
  142. package/coverage/src/custom-element/demo/coverage.svg +0 -10
  143. package/coverage/src/custom-element/demo/index.html +0 -116
  144. package/coverage/src/custom-element/demo/z.js/coverage.svg +0 -10
  145. package/coverage/src/custom-element/demo/z.js.html +0 -112
  146. package/dist/custom-element-BMMsP1Dy.js +0 -533
  147. package/dist/custom-element-CPSk7s0j.cjs +0 -87
  148. package/dist/demo/s1.xslt +0 -60
  149. package/dist/demo/z.html +0 -33
  150. package/dist/demo/z.js +0 -9
  151. package/dist/demo/z.xml +0 -60
  152. package/dist/demo/z1.html +0 -34
  153. package/public/demo/s1.xslt +0 -60
  154. package/public/demo/z.html +0 -33
  155. package/public/demo/z.js +0 -9
  156. package/public/demo/z.xml +0 -60
  157. package/public/demo/z1.html +0 -34
  158. package/src/custom-element/demo/s1.xslt +0 -60
  159. package/src/custom-element/demo/z.html +0 -33
  160. package/src/custom-element/demo/z.js +0 -9
  161. package/src/custom-element/demo/z.xml +0 -60
  162. package/src/custom-element/demo/z1.html +0 -34
  163. package/storybook-static/assets/Color-KGDBMAHA-CJo5gHY3.js +0 -1
  164. package/storybook-static/assets/Configure-DdXbGKhY.js +0 -173
  165. package/storybook-static/assets/DocsRenderer-PKQXORMH-DLnpL5hE.js +0 -2
  166. package/storybook-static/assets/custom-element-D8hcDZHh.js +0 -265
  167. package/storybook-static/assets/entry-preview-BKQ8UCxI.js +0 -8
  168. package/storybook-static/assets/iframe-Dfrt81rk.js +0 -2
  169. package/storybook-static/assets/index-Ay195x2L.js +0 -605
  170. package/storybook-static/assets/index-C3ChPTMh.js +0 -1
  171. package/storybook-static/assets/index-C8k3Z-3Y.js +0 -28
  172. package/storybook-static/assets/index-DGdNYaqV.js +0 -8
  173. package/storybook-static/assets/index-Gpdhz4ab.js +0 -1
  174. package/storybook-static/assets/lit-element-DzhCn-8W.js +0 -19
  175. package/storybook-static/assets/preview-BJPLiuSt.js +0 -1
  176. package/storybook-static/assets/preview-BMWqy4Bi.js +0 -1
  177. package/storybook-static/assets/preview-BnWGZYux.js +0 -1
  178. package/storybook-static/assets/preview-Djh1_Tal.js +0 -20
  179. package/storybook-static/demo/s1.xslt +0 -60
  180. package/storybook-static/demo/z.html +0 -33
  181. package/storybook-static/demo/z.js +0 -9
  182. package/storybook-static/demo/z.xml +0 -60
  183. package/storybook-static/demo/z1.html +0 -34
  184. package/storybook-static/sb-addons/chromatic-com-storybook-9/manager-bundle.js +0 -336
  185. package/storybook-static/sb-addons/chromatic-com-storybook-9/manager-bundle.js.LEGAL.txt +0 -77
  186. package/storybook-static/sb-addons/interactions-10/manager-bundle.js +0 -234
  187. /package/{storybook-static/sb-addons/interactions-10/manager-bundle.js.LEGAL.txt → src/material/guide/getting-started/index.html} +0 -0
package/dist/demo/s1.xslt DELETED
@@ -1,60 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xhtml="http://www.w3.org/1999/xhtml"
3
- xmlns:dce="urn:schemas-epa-wg:dce" xmlns:exsl="http://exslt.org/common" version="1.0"
4
- exclude-result-prefixes="exsl">
5
- <xsl:template match="ignore">
6
- <xsl:choose>
7
- <xsl:when test="//attr">
8
- <xsl:value-of select="//attr"/>
9
- </xsl:when>
10
- <xsl:otherwise>
11
- <xsl:value-of select="def"/>
12
- </xsl:otherwise>
13
- </xsl:choose>
14
- <xsl:value-of select="."/>
15
- </xsl:template>
16
- <xsl:template mode="payload" match="attributes">
17
- <dce-root xmlns="http://www.w3.org/1999/xhtml" xmlns:xhtml="http://www.w3.org/1999/xhtml" data-dce-id="1">
18
- <u xmlns="" data-dce-id="2">
19
- <dce-text data-dce-id="3">
20
- <xsl:call-template name="slot">
21
- <xsl:with-param name="slotname" select="''"/>
22
- <xsl:with-param name="defaultvalue">
23
- <dce-text xmlns="" data-dce-id="4">is green</dce-text>
24
- </xsl:with-param>
25
- </xsl:call-template>
26
- </dce-text>
27
- </u>
28
- </dce-root>
29
- </xsl:template>
30
- <xsl:template match="/">
31
- <xsl:apply-templates mode="payload" select="/datadom/attributes"/>
32
- </xsl:template>
33
-
34
- <xsl:template match="@*|node()" mode="copy-html">
35
- <xsl:copy><xsl:apply-templates select="@*|node()" mode="copy-html"/></xsl:copy>
36
- </xsl:template>
37
- <xsl:template match="node()[starts-with(name(),'xhtml:')]" mode="copy-html">
38
- <xsl:element name="{local-name()}"><xsl:apply-templates select="@*|node()" mode="copy-html"/></xsl:element>
39
- </xsl:template>
40
-
41
-
42
- <xsl:template name="slot">
43
- <xsl:param name="slotname"/>
44
- <xsl:param name="defaultvalue"/>
45
- <xsl:choose>
46
- <xsl:when test="//payload/*[@slot=$slotname]">
47
- <xsl:apply-templates mode="copy-html" select="//payload/*[@slot=$slotname]"/>
48
- </xsl:when>
49
- <xsl:otherwise>
50
- <xsl:apply-templates mode="copy-html" select="$defaultvalue"/>
51
- </xsl:otherwise>
52
- </xsl:choose>
53
- </xsl:template>
54
- <xsl:variable name="js-injected-body">
55
- <xsl:call-template name="slot">
56
- <xsl:with-param name="slotname" select="''"/>
57
- <xsl:with-param name="defaultvalue"/>
58
- </xsl:call-template>
59
- </xsl:variable>
60
- </xsl:stylesheet>
package/dist/demo/z.html DELETED
@@ -1,33 +0,0 @@
1
- <!DOCTYPE html>
2
- <html lang="en" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xhtml="http://www.w3.org/1999/xhtml">
3
- <head>
4
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
5
- <title>DOM merge - Declarative Custom Element implementation demo</title>
6
- <link rel="icon" href="./wc-square.svg"/>
7
- <script type="importmap">
8
- {
9
- "imports": {
10
- "@epa-wg/custom-element/": "../",
11
- "@epa-wg/custom-element-dist/": "../"
12
- }
13
- }
14
- </script>
15
- <script type="module" src="../http-request.js"></script>
16
- <script type="module" src="../location-element.js"></script>
17
- <script type="module" src="../custom-element.js"></script>
18
- <style>
19
- @import "./demo.css";
20
- dt{ font-weight: bold}
21
- dd{ padding: 0;}
22
- h1,h3{ margin: 0;}
23
- nav{ gap:0; }
24
- </style>
25
- </head>
26
- <body>
27
-
28
- <custom-element src="./html-template.html#dwc-logo">
29
- <template><i>loading SVG from templates file ...</i></template>
30
- </custom-element>
31
-
32
- </body>
33
- </html>
package/dist/demo/z.js DELETED
@@ -1,9 +0,0 @@
1
- import circle from "circle";
2
- import circle2 from "lib-root/circle.js";
3
- console.log(circle())
4
- try{
5
-
6
- console.log(import.meta.resolve('lib-root/a.js'))
7
- }catch( err ){
8
- console.error(err.message)
9
- }
package/dist/demo/z.xml DELETED
@@ -1,60 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <dce-root data-dce-id="1" xmlns:dce="urn:schemas-epa-wg:dce" xmlns:xhtml="http://www.w3.org/1999/xhtml">
3
- <location-element slice="window-url" data-dce-id="2"/>
4
- <table data-dce-id="3">
5
- <tr data-dce-id="4">
6
- <th data-dce-id="5">
7
- <u data-dce-id="6">URL properties</u>
8
- </th>
9
- </tr>
10
- <tr data-dce-id="7">
11
- <th data-dce-id="8">href</th>
12
- <td data-dce-id="9">http://localhost:63342/custom-element/demo/a.html?_ijt=qca6trk5kne6eo4s4tomq4egmm&amp;_ij_reload=RELOAD_ON_SAVE</td>
13
- </tr>
14
- <tr data-dce-id="7">
15
- <th data-dce-id="8">origin</th>
16
- <td data-dce-id="9">http://localhost:63342</td>
17
- </tr>
18
- <tr data-dce-id="7">
19
- <th data-dce-id="8">protocol</th>
20
- <td data-dce-id="9">http:</td>
21
- </tr>
22
- <tr data-dce-id="7">
23
- <th data-dce-id="8">host</th>
24
- <td data-dce-id="9">localhost:63342</td>
25
- </tr>
26
- <tr data-dce-id="7">
27
- <th data-dce-id="8">hostname</th>
28
- <td data-dce-id="9">localhost</td>
29
- </tr>
30
- <tr data-dce-id="7">
31
- <th data-dce-id="8">port</th>
32
- <td data-dce-id="9">63342</td>
33
- </tr>
34
- <tr data-dce-id="7">
35
- <th data-dce-id="8">pathname</th>
36
- <td data-dce-id="9">/custom-element/demo/a.html</td>
37
- </tr>
38
- <tr data-dce-id="7">
39
- <th data-dce-id="8">search</th>
40
- <td data-dce-id="9">?_ijt=qca6trk5kne6eo4s4tomq4egmm&amp;_ij_reload=RELOAD_ON_SAVE</td>
41
- </tr>
42
- <tr data-dce-id="7">
43
- <th data-dce-id="8">hash</th>
44
- <td data-dce-id="9"/>
45
- </tr>
46
- <tr data-dce-id="10">
47
- <th data-dce-id="11">
48
- <u data-dce-id="12">URL parameters</u>
49
- </th>
50
- </tr>
51
- <tr data-dce-id="13">
52
- <th data-dce-id="14">_ijt</th>
53
- <td data-dce-id="15">qca6trk5kne6eo4s4tomq4egmm</td>
54
- </tr>
55
- <tr data-dce-id="13">
56
- <th data-dce-id="14">_ij_reload</th>
57
- <td data-dce-id="15">RELOAD_ON_SAVE</td>
58
- </tr>
59
- </table>
60
- </dce-root>
package/dist/demo/z1.html DELETED
@@ -1,34 +0,0 @@
1
- <!DOCTYPE html>
2
- <html lang="en" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xhtml="http://www.w3.org/1999/xhtml">
3
- <head>
4
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
5
- <title>DOM merge - Declarative Custom Element implementation demo</title>
6
- <link rel="icon" href="./wc-square.svg"/>
7
- <script type="importmap">
8
- {
9
- "imports": {
10
- "@epa-wg/custom-element/": "../",
11
- "@epa-wg/custom-element-dist/": "../"
12
- }
13
- }
14
- </script>
15
- <script type="module" src="../http-request.js"></script>
16
- <script type="module" src="../location-element.js"></script>
17
- <script type="module" src="../custom-element.js"></script>
18
- <style>
19
- @import "./demo.css";
20
- dt{ font-weight: bold}
21
- dd{ padding: 0;}
22
- h1,h3{ margin: 0;}
23
- nav{ gap:0; }
24
- </style>
25
- </head>
26
- <body>
27
- <button onclick="window.location.hash = `#@epa-wg/custom-element-dist@0.0.27/storybook-static/index.html`">set in page URL</button>
28
-
29
- <custom-element src="@epa-wg/custom-element-dist/demo/npm-versions.html#npm-version"
30
- package-name="@epa-wg/custom-element-dist"
31
- ></custom-element>
32
-
33
- </body>
34
- </html>
@@ -1,60 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xhtml="http://www.w3.org/1999/xhtml"
3
- xmlns:dce="urn:schemas-epa-wg:dce" xmlns:exsl="http://exslt.org/common" version="1.0"
4
- exclude-result-prefixes="exsl">
5
- <xsl:template match="ignore">
6
- <xsl:choose>
7
- <xsl:when test="//attr">
8
- <xsl:value-of select="//attr"/>
9
- </xsl:when>
10
- <xsl:otherwise>
11
- <xsl:value-of select="def"/>
12
- </xsl:otherwise>
13
- </xsl:choose>
14
- <xsl:value-of select="."/>
15
- </xsl:template>
16
- <xsl:template mode="payload" match="attributes">
17
- <dce-root xmlns="http://www.w3.org/1999/xhtml" xmlns:xhtml="http://www.w3.org/1999/xhtml" data-dce-id="1">
18
- <u xmlns="" data-dce-id="2">
19
- <dce-text data-dce-id="3">
20
- <xsl:call-template name="slot">
21
- <xsl:with-param name="slotname" select="''"/>
22
- <xsl:with-param name="defaultvalue">
23
- <dce-text xmlns="" data-dce-id="4">is green</dce-text>
24
- </xsl:with-param>
25
- </xsl:call-template>
26
- </dce-text>
27
- </u>
28
- </dce-root>
29
- </xsl:template>
30
- <xsl:template match="/">
31
- <xsl:apply-templates mode="payload" select="/datadom/attributes"/>
32
- </xsl:template>
33
-
34
- <xsl:template match="@*|node()" mode="copy-html">
35
- <xsl:copy><xsl:apply-templates select="@*|node()" mode="copy-html"/></xsl:copy>
36
- </xsl:template>
37
- <xsl:template match="node()[starts-with(name(),'xhtml:')]" mode="copy-html">
38
- <xsl:element name="{local-name()}"><xsl:apply-templates select="@*|node()" mode="copy-html"/></xsl:element>
39
- </xsl:template>
40
-
41
-
42
- <xsl:template name="slot">
43
- <xsl:param name="slotname"/>
44
- <xsl:param name="defaultvalue"/>
45
- <xsl:choose>
46
- <xsl:when test="//payload/*[@slot=$slotname]">
47
- <xsl:apply-templates mode="copy-html" select="//payload/*[@slot=$slotname]"/>
48
- </xsl:when>
49
- <xsl:otherwise>
50
- <xsl:apply-templates mode="copy-html" select="$defaultvalue"/>
51
- </xsl:otherwise>
52
- </xsl:choose>
53
- </xsl:template>
54
- <xsl:variable name="js-injected-body">
55
- <xsl:call-template name="slot">
56
- <xsl:with-param name="slotname" select="''"/>
57
- <xsl:with-param name="defaultvalue"/>
58
- </xsl:call-template>
59
- </xsl:variable>
60
- </xsl:stylesheet>
@@ -1,33 +0,0 @@
1
- <!DOCTYPE html>
2
- <html lang="en" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xhtml="http://www.w3.org/1999/xhtml">
3
- <head>
4
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
5
- <title>DOM merge - Declarative Custom Element implementation demo</title>
6
- <link rel="icon" href="./wc-square.svg"/>
7
- <script type="importmap">
8
- {
9
- "imports": {
10
- "@epa-wg/custom-element/": "../",
11
- "@epa-wg/custom-element-dist/": "../"
12
- }
13
- }
14
- </script>
15
- <script type="module" src="../http-request.js"></script>
16
- <script type="module" src="../location-element.js"></script>
17
- <script type="module" src="../custom-element.js"></script>
18
- <style>
19
- @import "./demo.css";
20
- dt{ font-weight: bold}
21
- dd{ padding: 0;}
22
- h1,h3{ margin: 0;}
23
- nav{ gap:0; }
24
- </style>
25
- </head>
26
- <body>
27
-
28
- <custom-element src="./html-template.html#dwc-logo">
29
- <template><i>loading SVG from templates file ...</i></template>
30
- </custom-element>
31
-
32
- </body>
33
- </html>
package/public/demo/z.js DELETED
@@ -1,9 +0,0 @@
1
- import circle from "circle";
2
- import circle2 from "lib-root/circle.js";
3
- console.log(circle())
4
- try{
5
-
6
- console.log(import.meta.resolve('lib-root/a.js'))
7
- }catch( err ){
8
- console.error(err.message)
9
- }
package/public/demo/z.xml DELETED
@@ -1,60 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <dce-root data-dce-id="1" xmlns:dce="urn:schemas-epa-wg:dce" xmlns:xhtml="http://www.w3.org/1999/xhtml">
3
- <location-element slice="window-url" data-dce-id="2"/>
4
- <table data-dce-id="3">
5
- <tr data-dce-id="4">
6
- <th data-dce-id="5">
7
- <u data-dce-id="6">URL properties</u>
8
- </th>
9
- </tr>
10
- <tr data-dce-id="7">
11
- <th data-dce-id="8">href</th>
12
- <td data-dce-id="9">http://localhost:63342/custom-element/demo/a.html?_ijt=qca6trk5kne6eo4s4tomq4egmm&amp;_ij_reload=RELOAD_ON_SAVE</td>
13
- </tr>
14
- <tr data-dce-id="7">
15
- <th data-dce-id="8">origin</th>
16
- <td data-dce-id="9">http://localhost:63342</td>
17
- </tr>
18
- <tr data-dce-id="7">
19
- <th data-dce-id="8">protocol</th>
20
- <td data-dce-id="9">http:</td>
21
- </tr>
22
- <tr data-dce-id="7">
23
- <th data-dce-id="8">host</th>
24
- <td data-dce-id="9">localhost:63342</td>
25
- </tr>
26
- <tr data-dce-id="7">
27
- <th data-dce-id="8">hostname</th>
28
- <td data-dce-id="9">localhost</td>
29
- </tr>
30
- <tr data-dce-id="7">
31
- <th data-dce-id="8">port</th>
32
- <td data-dce-id="9">63342</td>
33
- </tr>
34
- <tr data-dce-id="7">
35
- <th data-dce-id="8">pathname</th>
36
- <td data-dce-id="9">/custom-element/demo/a.html</td>
37
- </tr>
38
- <tr data-dce-id="7">
39
- <th data-dce-id="8">search</th>
40
- <td data-dce-id="9">?_ijt=qca6trk5kne6eo4s4tomq4egmm&amp;_ij_reload=RELOAD_ON_SAVE</td>
41
- </tr>
42
- <tr data-dce-id="7">
43
- <th data-dce-id="8">hash</th>
44
- <td data-dce-id="9"/>
45
- </tr>
46
- <tr data-dce-id="10">
47
- <th data-dce-id="11">
48
- <u data-dce-id="12">URL parameters</u>
49
- </th>
50
- </tr>
51
- <tr data-dce-id="13">
52
- <th data-dce-id="14">_ijt</th>
53
- <td data-dce-id="15">qca6trk5kne6eo4s4tomq4egmm</td>
54
- </tr>
55
- <tr data-dce-id="13">
56
- <th data-dce-id="14">_ij_reload</th>
57
- <td data-dce-id="15">RELOAD_ON_SAVE</td>
58
- </tr>
59
- </table>
60
- </dce-root>
@@ -1,34 +0,0 @@
1
- <!DOCTYPE html>
2
- <html lang="en" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xhtml="http://www.w3.org/1999/xhtml">
3
- <head>
4
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
5
- <title>DOM merge - Declarative Custom Element implementation demo</title>
6
- <link rel="icon" href="./wc-square.svg"/>
7
- <script type="importmap">
8
- {
9
- "imports": {
10
- "@epa-wg/custom-element/": "../",
11
- "@epa-wg/custom-element-dist/": "../"
12
- }
13
- }
14
- </script>
15
- <script type="module" src="../http-request.js"></script>
16
- <script type="module" src="../location-element.js"></script>
17
- <script type="module" src="../custom-element.js"></script>
18
- <style>
19
- @import "./demo.css";
20
- dt{ font-weight: bold}
21
- dd{ padding: 0;}
22
- h1,h3{ margin: 0;}
23
- nav{ gap:0; }
24
- </style>
25
- </head>
26
- <body>
27
- <button onclick="window.location.hash = `#@epa-wg/custom-element-dist@0.0.27/storybook-static/index.html`">set in page URL</button>
28
-
29
- <custom-element src="@epa-wg/custom-element-dist/demo/npm-versions.html#npm-version"
30
- package-name="@epa-wg/custom-element-dist"
31
- ></custom-element>
32
-
33
- </body>
34
- </html>
@@ -1,60 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xhtml="http://www.w3.org/1999/xhtml"
3
- xmlns:dce="urn:schemas-epa-wg:dce" xmlns:exsl="http://exslt.org/common" version="1.0"
4
- exclude-result-prefixes="exsl">
5
- <xsl:template match="ignore">
6
- <xsl:choose>
7
- <xsl:when test="//attr">
8
- <xsl:value-of select="//attr"/>
9
- </xsl:when>
10
- <xsl:otherwise>
11
- <xsl:value-of select="def"/>
12
- </xsl:otherwise>
13
- </xsl:choose>
14
- <xsl:value-of select="."/>
15
- </xsl:template>
16
- <xsl:template mode="payload" match="attributes">
17
- <dce-root xmlns="http://www.w3.org/1999/xhtml" xmlns:xhtml="http://www.w3.org/1999/xhtml" data-dce-id="1">
18
- <u xmlns="" data-dce-id="2">
19
- <dce-text data-dce-id="3">
20
- <xsl:call-template name="slot">
21
- <xsl:with-param name="slotname" select="''"/>
22
- <xsl:with-param name="defaultvalue">
23
- <dce-text xmlns="" data-dce-id="4">is green</dce-text>
24
- </xsl:with-param>
25
- </xsl:call-template>
26
- </dce-text>
27
- </u>
28
- </dce-root>
29
- </xsl:template>
30
- <xsl:template match="/">
31
- <xsl:apply-templates mode="payload" select="/datadom/attributes"/>
32
- </xsl:template>
33
-
34
- <xsl:template match="@*|node()" mode="copy-html">
35
- <xsl:copy><xsl:apply-templates select="@*|node()" mode="copy-html"/></xsl:copy>
36
- </xsl:template>
37
- <xsl:template match="node()[starts-with(name(),'xhtml:')]" mode="copy-html">
38
- <xsl:element name="{local-name()}"><xsl:apply-templates select="@*|node()" mode="copy-html"/></xsl:element>
39
- </xsl:template>
40
-
41
-
42
- <xsl:template name="slot">
43
- <xsl:param name="slotname"/>
44
- <xsl:param name="defaultvalue"/>
45
- <xsl:choose>
46
- <xsl:when test="//payload/*[@slot=$slotname]">
47
- <xsl:apply-templates mode="copy-html" select="//payload/*[@slot=$slotname]"/>
48
- </xsl:when>
49
- <xsl:otherwise>
50
- <xsl:apply-templates mode="copy-html" select="$defaultvalue"/>
51
- </xsl:otherwise>
52
- </xsl:choose>
53
- </xsl:template>
54
- <xsl:variable name="js-injected-body">
55
- <xsl:call-template name="slot">
56
- <xsl:with-param name="slotname" select="''"/>
57
- <xsl:with-param name="defaultvalue"/>
58
- </xsl:call-template>
59
- </xsl:variable>
60
- </xsl:stylesheet>
@@ -1,33 +0,0 @@
1
- <!DOCTYPE html>
2
- <html lang="en" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xhtml="http://www.w3.org/1999/xhtml">
3
- <head>
4
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
5
- <title>DOM merge - Declarative Custom Element implementation demo</title>
6
- <link rel="icon" href="./wc-square.svg"/>
7
- <script type="importmap">
8
- {
9
- "imports": {
10
- "@epa-wg/custom-element/": "../",
11
- "@epa-wg/custom-element-dist/": "../"
12
- }
13
- }
14
- </script>
15
- <script type="module" src="../http-request.js"></script>
16
- <script type="module" src="../location-element.js"></script>
17
- <script type="module" src="../custom-element.js"></script>
18
- <style>
19
- @import "./demo.css";
20
- dt{ font-weight: bold}
21
- dd{ padding: 0;}
22
- h1,h3{ margin: 0;}
23
- nav{ gap:0; }
24
- </style>
25
- </head>
26
- <body>
27
-
28
- <custom-element src="./html-template.html#dwc-logo">
29
- <template><i>loading SVG from templates file ...</i></template>
30
- </custom-element>
31
-
32
- </body>
33
- </html>
@@ -1,9 +0,0 @@
1
- import circle from "circle";
2
- import circle2 from "lib-root/circle.js";
3
- console.log(circle())
4
- try{
5
-
6
- console.log(import.meta.resolve('lib-root/a.js'))
7
- }catch( err ){
8
- console.error(err.message)
9
- }
@@ -1,60 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <dce-root data-dce-id="1" xmlns:dce="urn:schemas-epa-wg:dce" xmlns:xhtml="http://www.w3.org/1999/xhtml">
3
- <location-element slice="window-url" data-dce-id="2"/>
4
- <table data-dce-id="3">
5
- <tr data-dce-id="4">
6
- <th data-dce-id="5">
7
- <u data-dce-id="6">URL properties</u>
8
- </th>
9
- </tr>
10
- <tr data-dce-id="7">
11
- <th data-dce-id="8">href</th>
12
- <td data-dce-id="9">http://localhost:63342/custom-element/demo/a.html?_ijt=qca6trk5kne6eo4s4tomq4egmm&amp;_ij_reload=RELOAD_ON_SAVE</td>
13
- </tr>
14
- <tr data-dce-id="7">
15
- <th data-dce-id="8">origin</th>
16
- <td data-dce-id="9">http://localhost:63342</td>
17
- </tr>
18
- <tr data-dce-id="7">
19
- <th data-dce-id="8">protocol</th>
20
- <td data-dce-id="9">http:</td>
21
- </tr>
22
- <tr data-dce-id="7">
23
- <th data-dce-id="8">host</th>
24
- <td data-dce-id="9">localhost:63342</td>
25
- </tr>
26
- <tr data-dce-id="7">
27
- <th data-dce-id="8">hostname</th>
28
- <td data-dce-id="9">localhost</td>
29
- </tr>
30
- <tr data-dce-id="7">
31
- <th data-dce-id="8">port</th>
32
- <td data-dce-id="9">63342</td>
33
- </tr>
34
- <tr data-dce-id="7">
35
- <th data-dce-id="8">pathname</th>
36
- <td data-dce-id="9">/custom-element/demo/a.html</td>
37
- </tr>
38
- <tr data-dce-id="7">
39
- <th data-dce-id="8">search</th>
40
- <td data-dce-id="9">?_ijt=qca6trk5kne6eo4s4tomq4egmm&amp;_ij_reload=RELOAD_ON_SAVE</td>
41
- </tr>
42
- <tr data-dce-id="7">
43
- <th data-dce-id="8">hash</th>
44
- <td data-dce-id="9"/>
45
- </tr>
46
- <tr data-dce-id="10">
47
- <th data-dce-id="11">
48
- <u data-dce-id="12">URL parameters</u>
49
- </th>
50
- </tr>
51
- <tr data-dce-id="13">
52
- <th data-dce-id="14">_ijt</th>
53
- <td data-dce-id="15">qca6trk5kne6eo4s4tomq4egmm</td>
54
- </tr>
55
- <tr data-dce-id="13">
56
- <th data-dce-id="14">_ij_reload</th>
57
- <td data-dce-id="15">RELOAD_ON_SAVE</td>
58
- </tr>
59
- </table>
60
- </dce-root>
@@ -1,34 +0,0 @@
1
- <!DOCTYPE html>
2
- <html lang="en" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xhtml="http://www.w3.org/1999/xhtml">
3
- <head>
4
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
5
- <title>DOM merge - Declarative Custom Element implementation demo</title>
6
- <link rel="icon" href="./wc-square.svg"/>
7
- <script type="importmap">
8
- {
9
- "imports": {
10
- "@epa-wg/custom-element/": "../",
11
- "@epa-wg/custom-element-dist/": "../"
12
- }
13
- }
14
- </script>
15
- <script type="module" src="../http-request.js"></script>
16
- <script type="module" src="../location-element.js"></script>
17
- <script type="module" src="../custom-element.js"></script>
18
- <style>
19
- @import "./demo.css";
20
- dt{ font-weight: bold}
21
- dd{ padding: 0;}
22
- h1,h3{ margin: 0;}
23
- nav{ gap:0; }
24
- </style>
25
- </head>
26
- <body>
27
- <button onclick="window.location.hash = `#@epa-wg/custom-element-dist@0.0.27/storybook-static/index.html`">set in page URL</button>
28
-
29
- <custom-element src="@epa-wg/custom-element-dist/demo/npm-versions.html#npm-version"
30
- package-name="@epa-wg/custom-element-dist"
31
- ></custom-element>
32
-
33
- </body>
34
- </html>