@epa-wg/custom-element-dist 0.0.32 → 0.0.34

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 (300) hide show
  1. package/.claude/settings.local.json +18 -0
  2. package/.github/workflows/deploy.yml +59 -0
  3. package/.idea/copilot.data.migration.agent.xml +6 -0
  4. package/.idea/copilot.data.migration.ask.xml +6 -0
  5. package/.idea/copilot.data.migration.edit.xml +6 -0
  6. package/.idea/custom-element-dist.iml +2 -0
  7. package/.storybook/main.ts +20 -21
  8. package/.storybook/preview.ts +23 -25
  9. package/README.md +6 -4
  10. package/coverage/block-navigation.js +1 -1
  11. package/coverage/coverage-final.json +8 -18
  12. package/coverage/index.html +45 -30
  13. package/coverage/sorter.js +21 -7
  14. package/coverage/src/custom-element/coverage.svg +1 -1
  15. package/coverage/src/custom-element/custom-element.js/coverage.svg +1 -1
  16. package/coverage/src/custom-element/custom-element.js.html +687 -480
  17. package/coverage/src/custom-element/http-request.js/coverage.svg +1 -1
  18. package/coverage/src/custom-element/http-request.js.html +39 -18
  19. package/coverage/src/custom-element/index.html +35 -35
  20. package/coverage/src/custom-element/local-storage.js.html +1 -1
  21. package/coverage/src/custom-element/location-element.js.html +31 -31
  22. package/coverage/src/custom-element/module-url.js/coverage.svg +1 -1
  23. package/coverage/src/custom-element/module-url.js.html +20 -20
  24. package/coverage/src/index.html +1 -1
  25. package/coverage/src/{stories/local-storage.test.stories.ts → material/theme/colors.js}/coverage.svg +1 -1
  26. package/coverage/src/material/theme/colors.js.html +217 -0
  27. package/coverage/src/{stories/location-element.test.stories.ts → material/theme}/coverage.svg +1 -1
  28. package/coverage/src/material/theme/index.html +116 -0
  29. package/coverage/src/mocks/handlers.ts.html +1 -1
  30. package/coverage/src/mocks/index.html +1 -1
  31. package/coverage/src/stories/coverage.svg +1 -1
  32. package/coverage/src/stories/{external-template.test.stories.ts → frame.canvas.ts}/coverage.svg +1 -1
  33. package/coverage/src/stories/frame.canvas.ts.html +175 -0
  34. package/coverage/src/stories/http-request.stories.ts.html +1 -1
  35. package/coverage/src/stories/index.html +14 -179
  36. package/coverage/src/stories/testStoryBook.ts.html +12 -12
  37. package/coverage/src/sum.ts.html +1 -1
  38. package/dist/custom-element-BoYMoUtP.js +619 -0
  39. package/dist/custom-element-BqtjrCRF.cjs +97 -0
  40. package/dist/custom-element-bundle.cjs +1 -1
  41. package/dist/custom-element-bundle.js +3 -3
  42. package/dist/demo/a.html +10 -3
  43. package/dist/demo/a.svg +26 -26
  44. package/dist/demo/attributes.html +153 -0
  45. package/dist/demo/external-templates-sb-6.html +42 -0
  46. package/dist/demo/external-templates-sb-7.html +42 -0
  47. package/dist/demo/html-template.html +5 -4
  48. package/dist/demo/module-url-sb-2.html +46 -0
  49. package/dist/demo/module-url-sb-4.html +48 -0
  50. package/dist/demo/module-url-sb-5.html +53 -0
  51. package/dist/demo/s.xml +3859 -7
  52. package/dist/demo/s.xslt +13 -48
  53. package/dist/demo/s1.xml +3706 -0
  54. package/dist/demo/ss.html +13 -4
  55. package/dist/http-request-DSaowcG1.cjs +1 -0
  56. package/dist/{http-request-BOvP4KTl.js → http-request-DTCzZ1gc.js} +15 -9
  57. package/dist/mockServiceWorker.js +31 -8
  58. package/package.json +25 -26
  59. package/public/demo/a.html +10 -3
  60. package/public/demo/a.svg +26 -26
  61. package/public/demo/attributes.html +153 -0
  62. package/public/demo/external-templates-sb-6.html +42 -0
  63. package/public/demo/external-templates-sb-7.html +42 -0
  64. package/public/demo/html-template.html +5 -4
  65. package/public/demo/module-url-sb-2.html +46 -0
  66. package/public/demo/module-url-sb-4.html +48 -0
  67. package/public/demo/module-url-sb-5.html +53 -0
  68. package/public/demo/s.xml +3859 -7
  69. package/public/demo/s.xslt +13 -48
  70. package/public/demo/s1.xml +3706 -0
  71. package/public/demo/ss.html +13 -4
  72. package/public/mockServiceWorker.js +31 -8
  73. package/src/custom-element/custom-element.d.ts +4 -0
  74. package/src/custom-element/custom-element.js +119 -50
  75. package/src/custom-element/demo/a.html +10 -3
  76. package/src/custom-element/demo/a.svg +26 -26
  77. package/src/custom-element/demo/attributes.html +153 -0
  78. package/src/custom-element/demo/html-template.html +5 -4
  79. package/src/custom-element/demo/s.xml +3859 -7
  80. package/src/custom-element/demo/s.xslt +13 -48
  81. package/src/custom-element/demo/s1.xml +3706 -0
  82. package/src/custom-element/demo/ss.html +13 -4
  83. package/src/custom-element/http-request.js +7 -0
  84. package/src/custom-element/ide/web-types-dce.json +1 -1
  85. package/src/custom-element/ide/web-types-xsl.json +1 -1
  86. package/src/custom-element/index.html +1 -1
  87. package/src/material/angular.css +987 -987
  88. package/src/material/components/action.html +262 -0
  89. package/src/material/components/autocomplete.html +167 -239
  90. package/src/material/components/badge.html +239 -0
  91. package/src/material/components/dropdown.html +7 -13
  92. package/src/material/components/icon-link.html +160 -160
  93. package/src/material/components/icon.html +252 -0
  94. package/src/material/components/input.html +569 -362
  95. package/src/material/components/menu.html +235 -234
  96. package/src/material/components.html +157 -121
  97. package/src/material/demo.css +36 -36
  98. package/src/material/index.html +109 -110
  99. package/src/material/material.css +356 -356
  100. package/src/material/theme/Base-Principles.md +339 -0
  101. package/src/material/theme/README.md +298 -18
  102. package/src/material/theme/UI Domain Model in web applications.svg +1 -0
  103. package/src/material/theme/User Semantic Theme tokens.svg +1 -0
  104. package/src/material/theme/action-pending-poc.html +62 -0
  105. package/src/material/theme/actions-color.html +141 -0
  106. package/src/material/theme/colors-light.html +631 -0
  107. package/src/material/theme/colors-native.html +51 -0
  108. package/src/material/theme/colors-poc.html +66 -0
  109. package/src/material/theme/colors.html +297 -0
  110. package/src/material/theme/colors.js +44 -0
  111. package/src/material/theme/consumer-theme.css +745 -0
  112. package/src/material/theme/semantic.css +132 -113
  113. package/src/material/theme/style-bug.html +123 -0
  114. package/src/material/theme/theme-data.css +43 -0
  115. package/src/material/theme/theme-data.xhtml +2926 -0
  116. package/src/material/theme/todo.md +274 -0
  117. package/src/material/theme/tokens/action-colors.png +0 -0
  118. package/src/material/theme/tokens/cem-article-illustration-4x1-letterbox-2000x500.png +0 -0
  119. package/src/material/theme/tokens/cem-breakpoints.md +519 -0
  120. package/src/material/theme/tokens/cem-colors.md +715 -0
  121. package/src/material/theme/tokens/cem-consumerflow-typography-matrix.svg +198 -0
  122. package/src/material/theme/tokens/cem-coupling.md +372 -0
  123. package/src/material/theme/tokens/cem-data-vs-reading-numerals.svg +164 -0
  124. package/src/material/theme/tokens/cem-dimension.md +625 -0
  125. package/src/material/theme/tokens/cem-layering.md +562 -0
  126. package/src/material/theme/tokens/cem-m3-parity.md +343 -0
  127. package/src/material/theme/tokens/cem-responsive.md +238 -0
  128. package/src/material/theme/tokens/cem-shape.md +691 -0
  129. package/src/material/theme/tokens/cem-stroke-density-illustration-4to1-v3.svg +102 -0
  130. package/src/material/theme/tokens/cem-stroke.md +480 -0
  131. package/src/material/theme/tokens/cem-timing.md +198 -0
  132. package/src/material/theme/tokens/cem-typography-model-stack.svg +64 -0
  133. package/src/material/theme/tokens/cem-voice-fonts-typography.md +718 -0
  134. package/src/material/theme/tokens/cem-voice-ladder.svg +91 -0
  135. package/src/material/theme/tokens/chips.png +0 -0
  136. package/src/material/theme/tokens/columns-page.png +0 -0
  137. package/src/material/theme/tokens/initials.png +0 -0
  138. package/src/material/theme/tokens/nav-buttons.png +0 -0
  139. package/src/material/theme/tokens/script.png +0 -0
  140. package/src/material/theme/tokens/sufler.png +0 -0
  141. package/src/material/theme/tokens/typography-icons.png +0 -0
  142. package/src/mocks/versions.mock.ts +1 -1
  143. package/src/stories/__screenshots__/attributes.test.stories.ts +1 -0
  144. package/src/stories/__screenshots__/dom-merge.test.stories.ts/dom-merge-dom-merge-OrderPreservingOn2ndTransform-1.png +0 -0
  145. package/src/stories/__screenshots__/external-template.test.stories.ts +1 -0
  146. package/src/stories/__screenshots__/module-url.test.stories.ts +1 -0
  147. package/src/stories/__screenshots__/stories.test.ts/attributes-Attributes-definition-1.png +0 -0
  148. package/src/stories/__screenshots__/stories.test.ts/attributes-Attributes-runtime-change-1.png +0 -0
  149. package/src/stories/__screenshots__/stories.test.ts/attributes-Instance-Attributes-1.png +0 -0
  150. package/src/stories/__screenshots__/stories.test.ts/attributes-Instance-Attributes-2.png +0 -0
  151. package/src/stories/__screenshots__/stories.test.ts/attributes-cloneAs-el-newTag--1.png +0 -0
  152. package/src/stories/__screenshots__/stories.test.ts/attributes-mergeAttr--from--to---1.png +0 -0
  153. package/src/stories/__screenshots__/stories.test.ts/attributes-mergeAttr--from--to---2.png +0 -0
  154. package/src/stories/__screenshots__/stories.test.ts/attributes-mergeAttr--from--to---3.png +0 -0
  155. package/src/stories/__screenshots__/stories.test.ts/attributes-mix-to-from--1.png +0 -0
  156. package/src/stories/__screenshots__/stories.test.ts/http-request-Attributes-definition-1.png +0 -0
  157. package/src/stories/__screenshots__/stories.test.ts/http-request-Attributes-runtime-change-1.png +0 -0
  158. package/src/stories/__screenshots__/stories.test.ts/http-request-Instance-Attributes-1.png +0 -0
  159. package/src/stories/__screenshots__/stories.test.ts/http-request-Instance-Attributes-2.png +0 -0
  160. package/src/stories/__screenshots__/stories.test.ts/http-request-cloneAs-el-newTag--1.png +0 -0
  161. package/src/stories/__screenshots__/stories.test.ts/http-request-http-request-headers-and-response-status-and-headers-1.png +0 -0
  162. package/src/stories/__screenshots__/stories.test.ts/http-request-http-request-with-delayed--5-seconds-response-1.png +0 -0
  163. package/src/stories/__screenshots__/stories.test.ts/http-request-http-request-with-error-1.png +0 -0
  164. package/src/stories/__screenshots__/stories.test.ts/http-request-mergeAttr--from--to---1.png +0 -0
  165. package/src/stories/__screenshots__/stories.test.ts/http-request-mergeAttr--from--to---2.png +0 -0
  166. package/src/stories/__screenshots__/stories.test.ts/http-request-mergeAttr--from--to---3.png +0 -0
  167. package/src/stories/__screenshots__/stories.test.ts/http-request-mix-to-from--1.png +0 -0
  168. package/src/stories/__screenshots__/stories.test.ts/http-request-url-and-slice-1.png +0 -0
  169. package/src/stories/__screenshots__/stories.test.ts/http-request-url-change-1.png +0 -0
  170. package/src/stories/__screenshots__/xslt-conditionals.test.stories.ts/xslt-conditionals-xslt-conditionals-MultipleIfOrderingWorkaround-1.png +0 -0
  171. package/src/stories/attributes.test.stories.ts +83 -17
  172. package/src/stories/dom-merge.test.stories.ts +25 -1
  173. package/src/stories/external-template.test.stories.ts +16 -14
  174. package/src/stories/frame.canvas.ts +31 -0
  175. package/src/stories/module-url.test.stories.ts +29 -61
  176. package/src/stories/xslt-conditionals.test.stories.ts +492 -0
  177. package/src/stories/xslt-if.test.stories.ts +89 -0
  178. package/storybook-static/assets/Color-F6OSRLHC-CzTOSlqB.js +1 -0
  179. package/storybook-static/assets/Configure-7GqRsAoJ.js +165 -0
  180. package/storybook-static/assets/DocsRenderer-CFRXHY34-Duc5rSIm.js +2 -0
  181. package/storybook-static/assets/{attributes.test.stories-D1X6EBrd.js → attributes.test.stories-DYuxF8h1.js} +109 -38
  182. package/storybook-static/assets/{css.test.stories-Cp_g2hE1.js → css.test.stories-LOmvINyb.js} +1 -1
  183. package/storybook-static/assets/custom-element-Bwx7otrT.js +97 -0
  184. package/storybook-static/assets/{dom-merge.test.stories-hbpdCka0.js → dom-merge.test.stories-CEKhWjaS.js} +47 -6
  185. package/storybook-static/assets/entry-preview-BNCt9WBs.js +26 -0
  186. package/storybook-static/assets/entry-preview-docs-CbF8-81D.js +2 -0
  187. package/storybook-static/assets/{external-template.test.stories-BK89h6sk.js → external-template.test.stories-jHu0wsJ-.js} +38 -40
  188. package/storybook-static/assets/{form.test.stories-BfoLe_rw.js → form.test.stories-CUyUnmwP.js} +1 -1
  189. package/storybook-static/assets/frame.canvas-E5n9h6j1.js +1 -0
  190. package/storybook-static/assets/{handlers-yVPwH_Nz.js → handlers-F7GUfMqr.js} +17 -14
  191. package/storybook-static/assets/http-request-BWeEEBkP.js +1 -0
  192. package/storybook-static/assets/{http-request.stories-CBFJS2Ws.js → http-request.stories-wyX5-QOv.js} +1 -1
  193. package/storybook-static/assets/iframe-BS_DPWl0.js +199 -0
  194. package/storybook-static/assets/index-CGuyH0k-.js +240 -0
  195. package/storybook-static/assets/index-DB7LLObI.js +1 -0
  196. package/storybook-static/assets/index-DO1nmyvI.js +11 -0
  197. package/storybook-static/assets/index-V1EGs-wm.js +621 -0
  198. package/storybook-static/assets/{local-storage.test.stories-C0Yzy6Am.js → local-storage.test.stories-BxOhsf1k.js} +1 -1
  199. package/storybook-static/assets/{location-element.test.stories-DNFrEu5A.js → location-element.test.stories-DqhvvUoa.js} +1 -1
  200. package/storybook-static/assets/module-url.test.stories-C1gG9G7Y.js +142 -0
  201. package/storybook-static/assets/preview-1xJJ3sKE.js +1 -0
  202. package/storybook-static/assets/preview-Bn8igYMp.js +1 -0
  203. package/storybook-static/assets/preview-CTOeX_lO.js +1 -0
  204. package/storybook-static/assets/preview-Cwy1XFu2.js +2 -0
  205. package/storybook-static/assets/preview-D6sehqkw.js +50 -0
  206. package/storybook-static/assets/preview-DfTudP20.js +1 -0
  207. package/storybook-static/assets/{set-url.test.stories-BBfLxv2u.js → set-url.test.stories-BKQNdknJ.js} +1 -1
  208. package/storybook-static/assets/{slice-events.test.stories-HcXF8XQI.js → slice-events.test.stories-ChqULCeA.js} +1 -1
  209. package/storybook-static/assets/{slots.test.stories-i6mnIFM2.js → slots.test.stories-BlyLoCRe.js} +1 -1
  210. package/storybook-static/assets/{version-select.test.stories-BsUFH6Va.js → version-select.test.stories-CPGSh1tR.js} +1 -1
  211. package/storybook-static/assets/xslt-conditionals.test.stories-YC6QPqWZ.js +633 -0
  212. package/storybook-static/assets/xslt-if.test.stories-BRSWy2-x.js +71 -0
  213. package/storybook-static/demo/a.html +10 -3
  214. package/storybook-static/demo/a.svg +26 -26
  215. package/storybook-static/demo/attributes.html +153 -0
  216. package/storybook-static/demo/external-templates-sb-6.html +42 -0
  217. package/storybook-static/demo/external-templates-sb-7.html +42 -0
  218. package/storybook-static/demo/html-template.html +5 -4
  219. package/storybook-static/demo/module-url-sb-2.html +46 -0
  220. package/storybook-static/demo/module-url-sb-4.html +48 -0
  221. package/storybook-static/demo/module-url-sb-5.html +53 -0
  222. package/storybook-static/demo/s.xml +3859 -7
  223. package/storybook-static/demo/s.xslt +13 -48
  224. package/storybook-static/demo/s1.xml +3706 -0
  225. package/storybook-static/demo/ss.html +13 -4
  226. package/storybook-static/iframe.html +2 -2
  227. package/storybook-static/index.html +6 -10
  228. package/storybook-static/index.json +1 -1
  229. package/storybook-static/mockServiceWorker.js +31 -8
  230. package/storybook-static/project.json +1 -1
  231. package/storybook-static/sb-addons/essentials-actions-2/manager-bundle.js +3 -0
  232. package/storybook-static/sb-addons/essentials-backgrounds-4/manager-bundle.js +8 -8
  233. package/storybook-static/sb-addons/essentials-controls-1/manager-bundle.js +394 -0
  234. package/storybook-static/sb-addons/essentials-docs-3/manager-bundle.js +233 -0
  235. package/storybook-static/sb-addons/essentials-measure-7/manager-bundle.js +1 -1
  236. package/storybook-static/sb-addons/essentials-outline-8/manager-bundle.js +1 -1
  237. package/storybook-static/sb-addons/essentials-toolbars-6/manager-bundle.js +1 -1
  238. package/storybook-static/sb-addons/essentials-viewport-5/manager-bundle.js +1 -1
  239. package/storybook-static/sb-addons/interactions-9/manager-bundle.js +58 -58
  240. package/storybook-static/sb-manager/globals-module-info.js +9 -0
  241. package/storybook-static/sb-manager/globals-runtime.js +10719 -10473
  242. package/storybook-static/sb-manager/runtime.js +4944 -6321
  243. package/coverage/src/stories/attributes.test.stories.ts/coverage.svg +0 -10
  244. package/coverage/src/stories/attributes.test.stories.ts.html +0 -814
  245. package/coverage/src/stories/css.test.stories.ts/coverage.svg +0 -10
  246. package/coverage/src/stories/css.test.stories.ts.html +0 -460
  247. package/coverage/src/stories/dom-merge.test.stories.ts/coverage.svg +0 -10
  248. package/coverage/src/stories/dom-merge.test.stories.ts.html +0 -706
  249. package/coverage/src/stories/external-template.test.stories.ts.html +0 -865
  250. package/coverage/src/stories/form.test.stories.ts/coverage.svg +0 -10
  251. package/coverage/src/stories/form.test.stories.ts.html +0 -661
  252. package/coverage/src/stories/local-storage.test.stories.ts.html +0 -1315
  253. package/coverage/src/stories/location-element.test.stories.ts.html +0 -523
  254. package/coverage/src/stories/module-url.test.stories.ts/coverage.svg +0 -10
  255. package/coverage/src/stories/module-url.test.stories.ts.html +0 -640
  256. package/coverage/src/stories/set-url.test.stories.ts/coverage.svg +0 -10
  257. package/coverage/src/stories/set-url.test.stories.ts.html +0 -433
  258. package/coverage/src/stories/slice-events.test.stories.ts/coverage.svg +0 -10
  259. package/coverage/src/stories/slice-events.test.stories.ts.html +0 -952
  260. package/coverage/src/stories/slots.test.stories.ts/coverage.svg +0 -10
  261. package/coverage/src/stories/slots.test.stories.ts.html +0 -742
  262. package/coverage/src/stories/version-select.test.stories.ts/coverage.svg +0 -10
  263. package/coverage/src/stories/version-select.test.stories.ts.html +0 -397
  264. package/dist/custom-element-D2wf_rqP.js +0 -576
  265. package/dist/custom-element-Dtzhbjkc.cjs +0 -97
  266. package/dist/http-request-DPrY7mGh.cjs +0 -1
  267. package/storybook-static/assets/Color-F6OSRLHC-BU3iy8jH.js +0 -1
  268. package/storybook-static/assets/Configure-DN6ifayP.js +0 -165
  269. package/storybook-static/assets/DocsRenderer-CFRXHY34-BaVEufDj.js +0 -2
  270. package/storybook-static/assets/custom-element-uuAtIYWS.js +0 -97
  271. package/storybook-static/assets/entry-preview-DHVXbf3x.js +0 -26
  272. package/storybook-static/assets/entry-preview-docs-BbcIMweR.js +0 -2
  273. package/storybook-static/assets/http-request-DNq59pnj.js +0 -1
  274. package/storybook-static/assets/iframe-CJEL_4Nu.js +0 -2
  275. package/storybook-static/assets/index-BcZLpTeD.js +0 -8
  276. package/storybook-static/assets/index-CxRwF5Or.js +0 -234
  277. package/storybook-static/assets/index-D-8MO0q_.js +0 -1
  278. package/storybook-static/assets/index-D5fBh-7N.js +0 -1
  279. package/storybook-static/assets/index-DM-KBPdl.js +0 -1
  280. package/storybook-static/assets/index-RSFf30w1.js +0 -1
  281. package/storybook-static/assets/index-SnjB5uV8.js +0 -769
  282. package/storybook-static/assets/module-url.test.stories-CXibF5Ta.js +0 -208
  283. package/storybook-static/assets/preview-BhhEZcNS.js +0 -1
  284. package/storybook-static/assets/preview-Bnd0XhaF.js +0 -52
  285. package/storybook-static/assets/preview-CNKoaWES.js +0 -1
  286. package/storybook-static/assets/preview-DAeyCMnM.js +0 -1
  287. package/storybook-static/assets/preview-DHPc-V4N.js +0 -1
  288. package/storybook-static/assets/preview-DJMlNTk8.js +0 -2
  289. package/storybook-static/assets/preview-DYzi3Z2p.js +0 -1
  290. package/storybook-static/sb-addons/chromatic-com-storybook-10/manager-bundle.js +0 -333
  291. package/storybook-static/sb-addons/chromatic-com-storybook-10/manager-bundle.js.LEGAL.txt +0 -40
  292. package/storybook-static/sb-addons/essentials-actions-3/manager-bundle.js +0 -3
  293. package/storybook-static/sb-addons/essentials-controls-2/manager-bundle.js +0 -391
  294. package/storybook-static/sb-addons/links-1/manager-bundle.js +0 -3
  295. package/storybook-static/sb-preview/globals.js +0 -33
  296. package/storybook-static/sb-preview/runtime.js +0 -7174
  297. package/test-runner-jest.config.js +0 -15
  298. /package/storybook-static/sb-addons/{essentials-actions-3 → essentials-actions-2}/manager-bundle.js.LEGAL.txt +0 -0
  299. /package/storybook-static/sb-addons/{essentials-controls-2 → essentials-controls-1}/manager-bundle.js.LEGAL.txt +0 -0
  300. /package/storybook-static/sb-addons/{links-1 → essentials-docs-3}/manager-bundle.js.LEGAL.txt +0 -0
@@ -1,240 +1,168 @@
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 charset="UTF-8">
5
- <meta content="text/html; charset=utf-8" http-equiv="Content-Type"/>
6
- <title>Components - custom-element - Material Design</title>
7
- <link href="../../custom-element/demo/wc-square.svg" rel="icon"/>
8
- <link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet"/>
9
- <link crossorigin="anonymous" href="https://use.fontawesome.com/releases/v5.15.4/css/all.css"
10
- integrity="sha384-DyZ88mC6Up2uqS4h/KRgHuoeGwBcD4Ng9SiP4dIRy0EXTlnuz47vAwmeGwVChigm" rel="stylesheet"/>
11
-
12
- <script type="importmap">
13
- {
14
- "imports": {
15
- "@epa-wg/": "../../"
16
- }
17
- }
18
- </script>
19
- <script src="../../custom-element/module-url.js" type="module"></script>
20
- <script src="../../custom-element/custom-element.js" type="module"></script>
21
- <style>
22
- @import "../angular.css";
23
- @import "../material.css";
24
- @import "../theme/semantic.css";
25
- @import "../demo.css";
26
- main{
27
- display: flex; flex-wrap: wrap;
28
- gap: 3rem;
29
- padding: 5rem;
30
- &>p{ min-width: 90%; }
31
- html-demo-element{flex:1; width: 100%; }
32
- }
33
- </style>
34
- </head>
35
-
36
- <body>
37
- <custom-element hidden src="./icon-link.html#cem-icon-link" tag="cem-icon-link"></custom-element>
38
-
39
-
40
- <header class="cem-theme-teal">
41
- <custom-element src="../index.html#nav-head" ></custom-element>
42
- </header>
43
- <main>
44
- <p><code>cem-autocomplete</code> is autocomplete component from &lt;custom-element&gt; Material suite based on the
45
- <a href="https://material.io/components" >Material Design specification</a>.
46
- </p>
47
- <custom-element tag="cem-autocomplete" hidden>
48
- <template>
49
- <attribute name="name"></attribute>
50
- <attribute name="label"></attribute>
51
- <attribute name="placeholder"></attribute>
52
- <attribute name="type">search</attribute>
53
- <attribute name="value"></attribute>
54
- <style>
55
- dce-root
56
- { position: relative;
57
- display: flex; flex-direction: column; justify-content: center;
58
- --input-padding: 0;
59
-
60
- --cem-input-outline: inset 0 -1px 0 black;
61
- --cem-input-outline-focus: inset 0 -3px 0 var(--cem-outline-color-focus);
62
- --cem-autocomplete-container-shape: 0.25rem;
63
- --cem-autocomplete-background-color: var(--cem-list-background-color);
64
- --cem-autocomplete-container-elevation-shadow: 0px 3px 1px -2px rgba(0, 0, 0, .2), 0px 2px 2px 0px rgba(0, 0, 0, .14), 0px 1px 5px 0px rgba(0, 0, 0, .12);
65
-
66
- background-color: var(--cem-filled-text-field-container-color, var(--cem-app-surface-variant));
67
-
68
- min-height: 3.5rem;
69
-
70
- & > fieldset,
71
- & > fieldset[focus-within="0"]{display: none;}
72
-
73
- & > fieldset[focus-within="1"],
74
- & > fieldset[focus-within="2"]{ display: flex; max-height: 10rem; height: auto; overflow: auto; transition: var(--cem-drop-transition) }
75
-
76
- fieldset
77
- { position: absolute;
78
- left: 0; right: 0; top:100%;
79
- flex-direction: column; border: red; max-height: 0;
80
- transition: var(--cem-drop-transition);
81
- overflow: hidden; padding: 0;
82
-
83
- border-radius: var(--cem-autocomplete-container-shape);
84
- border-top-left-radius: 0;
85
- border-top-right-radius: 0;
86
- box-shadow: var(--cem-autocomplete-container-elevation-shadow);
87
- background-color: var(--cem-autocomplete-background-color );
88
-
89
- transition-delay: 40ms;
90
- transition-duration: 110ms;
91
-
92
- label{ padding: 0.5rem;
93
- &:hover{ background-color: var(--cem-list-background-color-hover);}
94
- &:focus-within{ background-color: var(--cem-list-background-color-focus);}
95
- input{ width: 0; overflow: hidden; display: inline-block; }
96
- }
97
- }
98
- &>label
99
- { display: flex; flex-direction: column; justify-content: center;
100
- flex: 1; padding: 0.5rem 1rem;
101
- box-shadow: var(--cem-input-outline);
102
- transition: var(--drop-transition);
103
- color: var(--cem-filled-text-field-label-text-color);
104
-
105
- input
106
- { background: none; padding: var(--input-padding);
107
- &,&:focus,&:focus-visible{ border: none; outline: none; }
108
- &:placeholder-shown{ border: none; outline:none; }
109
- &[value=""]{ height: 0; }
110
- &:focus,&:focus-visible,&[placeholder*=""]{ height: auto; }
111
-
112
- color: var(--cem-filled-text-field-input-text-color, var(--cem-app-on-surface));
113
- caret-color: var(--cem-filled-text-field-caret-color, var(--cem-app-primary));
114
- font-size: 1rem;
115
- transition: var(--drop-transition);
116
- }
117
- }
118
- &:focus-within
119
- {
120
- &> label
121
- { box-shadow: var(--cem-input-outline-focus);
122
- font-size: small; justify-content: space-between;
123
- }
124
- }
125
- label:has( input:not([value=""]) ){ font-size: small; justify-content: space-between;}
126
- slice{display: none;}
127
- }
128
- </style>
129
- <!-- <pre>-->
130
- <!-- //focused {//focused}-->
131
- <!-- //suggest {//suggest}-->
132
- <!-- //selected {//selected}-->
133
- <!-- </pre>-->
134
- <slot name="input"><label>{$label}<xhtml:input
135
- name="{$name}"
136
- type="{$type}"
137
- placeholder="{$placeholder}"
138
- value="{//selected ?? $value}"
139
- slice="selected" slice-event="input"
140
- >
141
- <slice name="focused" slice-event="blur" slice-value="0"></slice>
142
- <slice name="focused" slice-event="focus" slice-value="1"></slice>
143
- <slice name="filter" slice-event="blur input" slice-value="//selected"></slice>
144
- </xhtml:input></label></slot>
145
- <fieldset form="cem-autocomplete-form" >
146
- <attribute name="focus-within">{//focused}</attribute>
147
- <xsl:for-each select="/datadom/payload/*[normalize-space(text()) != '']">
148
- <if test="normalize-space(//selected) = '' or contains(@value, //filter)">
149
- <label value="{@value ?? .}"
150
- ><xhtml:input type="radio" value="{@value ?? .}" name="cem-autocomplete" slice="selected" slice-event="input">
151
- <slice name="focused" slice-event="blur" slice-value="0"></slice>
152
- <slice name="focused" slice-event="focus" slice-value="2"></slice>
153
- </xhtml:input>
154
- {.}</label>
155
- </if>
156
- </xsl:for-each>
157
- </fieldset>
158
- </template>
159
- </custom-element>
160
-
161
- <html-demo-element legend="No value" description="Focus to see the cursor in input with label shifted upward ">
162
- <template>
163
- <cem-autocomplete label="String field" ></cem-autocomplete>
164
- </template>
165
- </html-demo-element>
166
-
167
- <html-demo-element legend="No value with placeholder" description="focus to see the placeholder text">
168
- <template>
169
- <cem-autocomplete label="Number" type="number" placeholder="Enter the numeric value"></cem-autocomplete>
170
- </template>
171
- </html-demo-element>
172
-
173
- <html-demo-element legend="Value defined" description="The value should be visible" >
174
- <template>
175
- <cem-autocomplete label="Text" type="text" value="abc"></cem-autocomplete>
176
- </template>
177
- </html-demo-element>
178
-
179
- <html-demo-element legend="No initial value with placeholder" >
180
- <div slot="description"><code>data value="xxx</code> for selection item uses <code>data</code> attribute for value </div>
181
- <template>
182
- <cem-autocomplete label="Fruits and berries" type="text" placeholder="Enter the fruit name">
183
- <data value="apple" > 🍎 Apple </data>
184
- <data value="strawberry" > 🍓 Strawberry </data>
185
- <data value="pineapple" > 🍍 Pineapple </data>
186
- </cem-autocomplete>
187
- </template>
188
- </html-demo-element>
189
-
190
- <html-demo-element legend="Number, No initial value without placeholder" description="label takes the space till input is focused" >
191
- <template>
192
- <cem-autocomplete label="Number" type="number" >
193
- <data value="1">One </data>
194
- <data value="2">Two </data>
195
- <data value="3">Three </data>
196
- </cem-autocomplete>
197
- </template>
198
- </html-demo-element>
199
-
200
-
201
- <html-demo-element legend="Options text as value" description="The value is same as text" >
202
- <template>
203
- <cem-autocomplete label="Dinosaur" type="text" >
204
- <option>Tyrannosaurus </option>
205
- <option>Sauropod </option>
206
- <option>Velociraptor </option>
207
- </cem-autocomplete>
208
- </template>
209
- </html-demo-element>
210
-
211
- <html-demo-element legend="Options Grouping" description="filter within eac group, empty groups are hidden" >
212
- <template>
213
- <cem-autocomplete label="Number" type="text" >
214
- <optgroup label="🦖 Theropods">
215
- <option>Tyrannosaurus </option>
216
- <option>Sauropod </option>
217
- <option>Velociraptor </option>
218
- <option>Deinonychus </option>
219
- </optgroup>
220
- <optgroup label="🦕 Sauropods">
221
- <option>Diplodocus </option>
222
- <option>Saltasaurus </option>
223
- <option>Apatosaurus </option>
224
- </optgroup>
225
- </cem-autocomplete>
226
- </template>
227
- </html-demo-element>
228
-
229
-
230
- </main>
231
- <footer>
232
- <hr/>
233
- Powered by Syngrafact Corp. ©2024.<br/>
234
- <a href="../../LICENSE"> Code and documentation licensed under an Apache License 2.0 </a>
235
- </footer>
236
- <!--<script type="module" src="./html-demo-element.js"></script>-->
237
- <script type="module" src="https://unpkg.com/html-demo-element@1/html-demo-element.js"></script>
238
-
239
- </body>
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 charset="UTF-8">
5
+ <meta content="text/html; charset=utf-8" http-equiv="Content-Type"/>
6
+ <title>Components - custom-element - Material Design</title>
7
+ <link href="../../custom-element/demo/wc-square.svg" rel="icon"/>
8
+ <link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet"/>
9
+ <link crossorigin="anonymous" href="https://use.fontawesome.com/releases/v5.15.4/css/all.css"
10
+ integrity="sha384-DyZ88mC6Up2uqS4h/KRgHuoeGwBcD4Ng9SiP4dIRy0EXTlnuz47vAwmeGwVChigm" rel="stylesheet"/>
11
+
12
+ <script type="importmap">
13
+ {
14
+ "imports": {
15
+ "@epa-wg/": "../../"
16
+ }
17
+ }
18
+ </script>
19
+ <script src="../../custom-element/module-url.js" type="module"></script>
20
+ <script src="../../custom-element/custom-element.js" type="module"></script>
21
+ <style>
22
+ @import "../angular.css";
23
+ @import "../material.css";
24
+ @import "../theme/semantic.css";
25
+ @import "../demo.css";
26
+ main{
27
+ display: flex; flex-wrap: wrap;
28
+ gap: 3rem;
29
+ padding: 5rem;
30
+ &>p{ min-width: 90%; }
31
+ html-demo-element{flex:1; width: 100%; }
32
+ }
33
+ </style>
34
+ </head>
35
+
36
+ <body>
37
+ <custom-element tag="cem-icon-link" hidden src="./icon-link.html#cem-icon-link" ></custom-element>
38
+ <custom-element tag="cem-input" hidden src="./input.html#cem-input" ></custom-element>
39
+ <custom-element tag="cem-menu" hidden src="./menu.html#cem-menu"></custom-element>
40
+
41
+
42
+ <header class="cem-theme-teal">
43
+ <custom-element src="../index.html#nav-head" ></custom-element>
44
+ </header>
45
+ <main>
46
+ <p><code>cem-autocomplete</code> is autocomplete component from &lt;custom-element&gt; Material suite based on the
47
+ <a href="https://material.io/components" >Material Design specification</a>.
48
+ </p>
49
+
50
+ <custom-element tag="cem-autocomplete" hidden>
51
+ <template>
52
+ <!-- cem-input attributes -->
53
+ <attribute name="value" select="//selected[//selected/event] ?? //attributes/@value" ></attribute>
54
+ <attribute name="name" ></attribute>
55
+ <attribute name="type" ></attribute>
56
+ <attribute name="autocapitalize" ></attribute>
57
+ <attribute name="disabled" ></attribute>
58
+ <attribute name="multiple" ></attribute>
59
+ <attribute name="readonly" ></attribute>
60
+ <attribute name="required" ></attribute>
61
+ <attribute name="incremental" ></attribute>
62
+ <attribute name="max" ></attribute>
63
+ <attribute name="maxlength" ></attribute>
64
+ <attribute name="min" ></attribute>
65
+ <attribute name="minlength" ></attribute>
66
+ <attribute name="size" ></attribute>
67
+ <attribute name="step" ></attribute>
68
+ <attribute name="tabindex" ></attribute>
69
+ <attribute name="autocomplete" ></attribute>
70
+ <attribute name="form" ></attribute>
71
+ <attribute name="id" ></attribute>
72
+ <attribute name="list" ></attribute>
73
+ <attribute name="pattern" ></attribute>
74
+ <attribute name="placeholder" ></attribute>
75
+ <attribute name="title" ></attribute>
76
+ <attribute name="leading" aria-description="leading icon" ></attribute>
77
+ <attribute name="trailing" aria-description="trailing icon" ></attribute>
78
+ <attribute name="label" aria-description="label text" ></attribute>
79
+ <attribute name="supporting" aria-description="Supporting text" ></attribute>
80
+ <style>
81
+ &
82
+ {
83
+ }
84
+ </style>
85
+ <slot name="input"><cem-input></cem-input></slot>
86
+ <slot name="menu"><cem-menu></cem-menu></slot>
87
+ </template>
88
+ </custom-element>
89
+
90
+ <html-demo-element legend="No value" description="Focus to see the cursor in input with label shifted upward ">
91
+ <template>
92
+ <cem-autocomplete label="String field" ></cem-autocomplete>
93
+ </template>
94
+ </html-demo-element>
95
+
96
+ <html-demo-element legend="No value with placeholder" description="focus to see the placeholder text">
97
+ <template>
98
+ <cem-autocomplete label="Number" type="number" placeholder="Enter the numeric value"></cem-autocomplete>
99
+ </template>
100
+ </html-demo-element>
101
+
102
+ <html-demo-element legend="Value defined" description="The value should be visible" >
103
+ <template>
104
+ <cem-autocomplete label="Text" type="text" value="abc"></cem-autocomplete>
105
+ </template>
106
+ </html-demo-element>
107
+
108
+ <html-demo-element legend="No initial value with placeholder" >
109
+ <div slot="description"><code>data value="xxx</code> for selection item uses <code>data</code> attribute for value </div>
110
+ <template>
111
+ <cem-autocomplete label="Fruits and berries" type="text" placeholder="Enter the fruit name">
112
+ <data value="apple" > 🍎 Apple </data>
113
+ <data value="strawberry" > 🍓 Strawberry </data>
114
+ <data value="pineapple" > 🍍 Pineapple </data>
115
+ </cem-autocomplete>
116
+ </template>
117
+ </html-demo-element>
118
+
119
+ <html-demo-element legend="Number, No initial value without placeholder" description="label takes the space till input is focused" >
120
+ <template>
121
+ <cem-autocomplete label="Number" type="number" >
122
+ <data value="1">One </data>
123
+ <data value="2">Two </data>
124
+ <data value="3">Three </data>
125
+ </cem-autocomplete>
126
+ </template>
127
+ </html-demo-element>
128
+
129
+
130
+ <html-demo-element legend="Options text as value" description="The value is same as text" >
131
+ <template>
132
+ <cem-autocomplete label="Dinosaur" type="text" >
133
+ <option>Tyrannosaurus </option>
134
+ <option>Sauropod </option>
135
+ <option>Velociraptor </option>
136
+ </cem-autocomplete>
137
+ </template>
138
+ </html-demo-element>
139
+
140
+ <html-demo-element legend="Options Grouping" description="filter within eac group, empty groups are hidden" >
141
+ <template>
142
+ <cem-autocomplete label="Number" type="text" >
143
+ <optgroup label="🦖 Theropods">
144
+ <option>Tyrannosaurus </option>
145
+ <option>Sauropod </option>
146
+ <option>Velociraptor </option>
147
+ <option>Deinonychus </option>
148
+ </optgroup>
149
+ <optgroup label="🦕 Sauropods">
150
+ <option>Diplodocus </option>
151
+ <option>Saltasaurus </option>
152
+ <option>Apatosaurus </option>
153
+ </optgroup>
154
+ </cem-autocomplete>
155
+ </template>
156
+ </html-demo-element>
157
+
158
+
159
+ </main>
160
+ <footer>
161
+ <hr/>
162
+ <a href="../../LICENSE"> Code and documentation licensed under an Apache License 2.0 </a>
163
+ </footer>
164
+ <!--<script type="module" src="./html-demo-element.js"></script>-->
165
+ <script type="module" src="https://unpkg.com/html-demo-element@1/html-demo-element.js"></script>
166
+
167
+ </body>
240
168
  </html>