mlform 0.1.2 → 0.1.4

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 (299) hide show
  1. package/README.md +241 -88
  2. package/dist/design-system-CrrSGfFB.js +1352 -0
  3. package/dist/engine-nnhWPT2L.js +5301 -0
  4. package/dist/kit-Dt_1Fxlc.js +76 -0
  5. package/dist/mlform/design-system.mjs +2 -0
  6. package/dist/mlform/engine.mjs +3 -0
  7. package/dist/mlform/kit.mjs +3 -0
  8. package/dist/mlform/primitives.mjs +2 -0
  9. package/dist/mlform/questionnaire.mjs +640 -0
  10. package/dist/mlform/transport.mjs +2 -0
  11. package/dist/mlform.mjs +4 -709
  12. package/dist/primitives-Pi-ztAr6.js +5063 -0
  13. package/dist/transport-A1RsnZhD.js +2143 -0
  14. package/dist/types/src/design-system/constants.d.ts +34 -0
  15. package/dist/types/src/design-system/contract/component-keys.d.ts +2 -0
  16. package/dist/types/src/design-system/contract/component-tokens.d.ts +5 -0
  17. package/dist/types/src/design-system/contract/global-tokens.d.ts +7 -0
  18. package/dist/types/src/design-system/contract/index.d.ts +4 -0
  19. package/dist/types/src/design-system/contract/token-keys.d.ts +12 -0
  20. package/dist/types/src/design-system/index.d.ts +8 -0
  21. package/dist/types/src/design-system/recipes/contrast.d.ts +2 -0
  22. package/dist/types/src/design-system/recipes/default.d.ts +2 -0
  23. package/dist/types/src/design-system/recipes/index.d.ts +4 -0
  24. package/dist/types/src/design-system/recipes/minimal.d.ts +2 -0
  25. package/dist/types/src/design-system/recipes/soft.d.ts +2 -0
  26. package/dist/types/src/design-system/registry/builtins.d.ts +5 -0
  27. package/dist/types/src/design-system/registry/create-registry.d.ts +2 -0
  28. package/dist/types/src/design-system/registry/deep-freeze.d.ts +5 -0
  29. package/dist/types/src/design-system/registry/define-recipe.d.ts +2 -0
  30. package/dist/types/src/design-system/registry/define-theme.d.ts +2 -0
  31. package/dist/types/src/design-system/registry/define-token-maps.d.ts +6 -0
  32. package/dist/types/src/design-system/registry/index.d.ts +5 -0
  33. package/dist/types/src/design-system/resolve/diagnostics.d.ts +9 -0
  34. package/dist/types/src/design-system/resolve/index.d.ts +5 -0
  35. package/dist/types/src/design-system/resolve/merge-config.d.ts +2 -0
  36. package/dist/types/src/design-system/resolve/migrate-tokens.d.ts +44 -0
  37. package/dist/types/src/design-system/resolve/resolve-mode.d.ts +6 -0
  38. package/dist/types/src/design-system/resolve/resolve-recipe.d.ts +2 -0
  39. package/dist/types/src/design-system/resolve/resolve-theme.d.ts +2 -0
  40. package/dist/types/src/design-system/resolve/resolve-tokens.d.ts +2 -0
  41. package/dist/types/src/design-system/runtime/apply-tokens.d.ts +4 -0
  42. package/dist/types/src/design-system/runtime/attach-design-system.d.ts +11 -0
  43. package/dist/types/src/design-system/runtime/create-stylesheet.d.ts +11 -0
  44. package/dist/types/src/design-system/runtime/declarations.d.ts +5 -0
  45. package/dist/types/src/design-system/runtime/design-system-controller.d.ts +9 -0
  46. package/dist/types/src/design-system/runtime/host-state.d.ts +3 -0
  47. package/dist/types/src/design-system/runtime/hydrate-design-system.d.ts +25 -0
  48. package/dist/types/src/design-system/runtime/index.d.ts +8 -0
  49. package/dist/types/src/design-system/themes/cobalt.d.ts +2 -0
  50. package/dist/types/src/design-system/themes/graphite.d.ts +2 -0
  51. package/dist/types/src/design-system/themes/index.d.ts +5 -0
  52. package/dist/types/src/design-system/themes/neutral.d.ts +2 -0
  53. package/dist/types/src/design-system/themes/sage.d.ts +2 -0
  54. package/dist/types/src/design-system/themes/sunset.d.ts +2 -0
  55. package/dist/types/src/design-system/tokens/base.d.ts +5 -0
  56. package/dist/types/src/design-system/tokens/contrast.d.ts +8 -0
  57. package/dist/types/src/design-system/tokens/density.d.ts +9 -0
  58. package/dist/types/src/design-system/tokens/forced-colors.d.ts +12 -0
  59. package/dist/types/src/design-system/tokens/index.d.ts +5 -0
  60. package/dist/types/src/design-system/tokens/motion.d.ts +2 -0
  61. package/dist/types/src/design-system/types.d.ts +225 -0
  62. package/dist/types/src/engine/builtins/fields/boolean.d.ts +8 -0
  63. package/dist/types/src/engine/builtins/fields/category.d.ts +11 -0
  64. package/dist/types/src/engine/builtins/fields/date.d.ts +9 -0
  65. package/dist/types/src/engine/builtins/fields/long-text.d.ts +10 -0
  66. package/dist/types/src/engine/builtins/fields/multi-choice.d.ts +12 -0
  67. package/dist/types/src/engine/builtins/fields/number.d.ts +11 -0
  68. package/dist/types/src/engine/builtins/fields/rating.d.ts +9 -0
  69. package/dist/types/src/engine/builtins/fields/series.d.ts +20 -0
  70. package/dist/types/src/engine/builtins/fields/single-choice.d.ts +12 -0
  71. package/dist/types/src/engine/builtins/fields/text.d.ts +10 -0
  72. package/dist/types/src/engine/builtins/index.d.ts +97 -0
  73. package/dist/types/src/engine/builtins/reports/classifier.d.ts +8 -0
  74. package/dist/types/src/engine/builtins/reports/regressor.d.ts +8 -0
  75. package/dist/types/src/engine/builtins/shared.d.ts +49 -0
  76. package/dist/types/src/engine/comparison.d.ts +2 -0
  77. package/dist/types/src/engine/constants.d.ts +51 -0
  78. package/dist/types/src/engine/declarative/explanation.d.ts +2 -0
  79. package/dist/types/src/engine/declarative/field.d.ts +2 -0
  80. package/dist/types/src/engine/declarative/presentation.d.ts +61 -0
  81. package/dist/types/src/engine/declarative/report.d.ts +2 -0
  82. package/dist/types/src/engine/equality.d.ts +4 -0
  83. package/dist/types/src/engine/errors.d.ts +28 -0
  84. package/dist/types/src/engine/explanations/controller.d.ts +13 -0
  85. package/dist/types/src/engine/explanations/index.d.ts +1 -0
  86. package/dist/types/src/engine/fields/controller.d.ts +30 -0
  87. package/dist/types/src/engine/fields/index.d.ts +1 -0
  88. package/dist/types/src/engine/form.d.ts +2 -0
  89. package/dist/types/src/engine/index.d.ts +11 -0
  90. package/dist/types/src/engine/paths.d.ts +2 -0
  91. package/dist/types/src/engine/registry/index.d.ts +26 -0
  92. package/dist/types/src/engine/reports/controller.d.ts +19 -0
  93. package/dist/types/src/engine/reports/index.d.ts +1 -0
  94. package/dist/types/src/engine/schema/index.d.ts +7 -0
  95. package/dist/types/src/engine/state/engine.d.ts +60 -0
  96. package/dist/types/src/engine/state/index.d.ts +3 -0
  97. package/dist/types/src/engine/state/snapshots.d.ts +5 -0
  98. package/dist/types/src/engine/state/store.d.ts +13 -0
  99. package/dist/types/src/engine/submission/abort.d.ts +15 -0
  100. package/dist/types/src/engine/submission/explanations.d.ts +2 -0
  101. package/dist/types/src/engine/submission/index.d.ts +5 -0
  102. package/dist/types/src/engine/submission/lifecycle.d.ts +16 -0
  103. package/dist/types/src/engine/submission/pipeline.d.ts +2 -0
  104. package/dist/types/src/engine/submission/reports.d.ts +12 -0
  105. package/dist/types/src/engine/submission/request.d.ts +23 -0
  106. package/dist/types/src/engine/submission/result.d.ts +4 -0
  107. package/dist/types/src/engine/submission/submitter.d.ts +40 -0
  108. package/dist/types/src/engine/types/explanation.d.ts +109 -0
  109. package/dist/types/src/engine/types/field.d.ts +172 -0
  110. package/dist/types/src/engine/types/form.d.ts +120 -0
  111. package/dist/types/src/engine/types/index.d.ts +9 -0
  112. package/dist/types/src/engine/types/pipeline.d.ts +31 -0
  113. package/dist/types/src/engine/types/registry.d.ts +17 -0
  114. package/dist/types/src/engine/types/report.d.ts +87 -0
  115. package/dist/types/src/engine/types/transport.d.ts +41 -0
  116. package/dist/types/src/engine/utils.d.ts +9 -0
  117. package/dist/types/src/engine/validation/conditions.d.ts +11 -0
  118. package/dist/types/src/engine/validation/field.d.ts +29 -0
  119. package/dist/types/src/engine/validation/form.d.ts +35 -0
  120. package/dist/types/src/engine/validation/index.d.ts +3 -0
  121. package/dist/types/src/engine/values.d.ts +2 -0
  122. package/dist/types/src/index.d.ts +7 -0
  123. package/dist/types/src/kit/constants.d.ts +4 -0
  124. package/dist/types/src/kit/defaults.d.ts +11 -0
  125. package/dist/types/src/kit/index.d.ts +4 -0
  126. package/dist/types/src/kit/mount-form.d.ts +3 -0
  127. package/dist/types/src/kit/types.d.ts +52 -0
  128. package/dist/types/src/primitives/base-async-report-element.d.ts +19 -0
  129. package/dist/types/src/primitives/base-explanation-element.d.ts +21 -0
  130. package/dist/types/src/primitives/base-field-element.d.ts +21 -0
  131. package/dist/types/src/primitives/base-report-element.d.ts +15 -0
  132. package/dist/types/src/primitives/components/declarative-explanation.d.ts +5 -0
  133. package/dist/types/src/primitives/components/declarative-field.d.ts +6 -0
  134. package/dist/types/src/primitives/components/declarative-report.d.ts +5 -0
  135. package/dist/types/src/primitives/components/explanation-panel.d.ts +22 -0
  136. package/dist/types/src/primitives/components/field-frame.d.ts +21 -0
  137. package/dist/types/src/primitives/components/form-errors.d.ts +19 -0
  138. package/dist/types/src/primitives/components/form-root.d.ts +29 -0
  139. package/dist/types/src/primitives/components/presentation.d.ts +4 -0
  140. package/dist/types/src/primitives/components/report-frame.d.ts +22 -0
  141. package/dist/types/src/primitives/components/submit-button.d.ts +21 -0
  142. package/dist/types/src/primitives/components/unsupported-component.d.ts +14 -0
  143. package/dist/types/src/primitives/constants.d.ts +94 -0
  144. package/dist/types/src/primitives/controller-binding.d.ts +32 -0
  145. package/dist/types/src/primitives/fields/boolean-field.d.ts +6 -0
  146. package/dist/types/src/primitives/fields/category-field.d.ts +6 -0
  147. package/dist/types/src/primitives/fields/date-field.d.ts +6 -0
  148. package/dist/types/src/primitives/fields/long-text-field.d.ts +6 -0
  149. package/dist/types/src/primitives/fields/multi-choice-field.d.ts +6 -0
  150. package/dist/types/src/primitives/fields/number-field.d.ts +8 -0
  151. package/dist/types/src/primitives/fields/rating-field.d.ts +6 -0
  152. package/dist/types/src/primitives/fields/series-field.d.ts +8 -0
  153. package/dist/types/src/primitives/fields/single-choice-field.d.ts +6 -0
  154. package/dist/types/src/primitives/fields/text-field.d.ts +6 -0
  155. package/dist/types/src/primitives/index.d.ts +8 -0
  156. package/dist/types/src/primitives/mount-form.d.ts +4 -0
  157. package/dist/types/src/primitives/register.d.ts +0 -0
  158. package/dist/types/src/primitives/registry.d.ts +3 -0
  159. package/dist/types/src/primitives/reports/classifier-report.d.ts +5 -0
  160. package/dist/types/src/primitives/reports/regressor-report.d.ts +5 -0
  161. package/dist/types/src/primitives/types.d.ts +128 -0
  162. package/dist/types/src/primitives/utils.d.ts +3 -0
  163. package/dist/types/src/questionnaire/constants.d.ts +31 -0
  164. package/dist/types/src/questionnaire/defaults.d.ts +8 -0
  165. package/dist/types/src/questionnaire/engine/controller.d.ts +12 -0
  166. package/dist/types/src/questionnaire/engine/schema.d.ts +9 -0
  167. package/dist/types/src/questionnaire/errors.d.ts +3 -0
  168. package/dist/types/src/questionnaire/index.d.ts +6 -0
  169. package/dist/types/src/questionnaire/mount.d.ts +3 -0
  170. package/dist/types/src/questionnaire/primitives/components/questionnaire-root.d.ts +23 -0
  171. package/dist/types/src/questionnaire/primitives/components/step-indicator.d.ts +14 -0
  172. package/dist/types/src/questionnaire/primitives/register.d.ts +0 -0
  173. package/dist/types/src/questionnaire/types.d.ts +69 -0
  174. package/dist/types/src/shared/errors.d.ts +3 -0
  175. package/dist/types/src/shared/index.d.ts +1 -0
  176. package/dist/types/src/transport/capabilities.d.ts +7 -0
  177. package/dist/types/src/transport/clone.d.ts +6 -0
  178. package/dist/types/src/transport/composition/fallback.d.ts +2 -0
  179. package/dist/types/src/transport/composition/fanout.d.ts +3 -0
  180. package/dist/types/src/transport/composition/hedged.d.ts +2 -0
  181. package/dist/types/src/transport/composition/index.d.ts +7 -0
  182. package/dist/types/src/transport/composition/load-balancing.d.ts +2 -0
  183. package/dist/types/src/transport/composition/pipeline.d.ts +2 -0
  184. package/dist/types/src/transport/composition/racing.d.ts +2 -0
  185. package/dist/types/src/transport/composition/routing.d.ts +3 -0
  186. package/dist/types/src/transport/constants.d.ts +34 -0
  187. package/dist/types/src/transport/errors.d.ts +36 -0
  188. package/dist/types/src/transport/index.d.ts +9 -0
  189. package/dist/types/src/transport/internal.d.ts +110 -0
  190. package/dist/types/src/transport/middleware/auth.d.ts +2 -0
  191. package/dist/types/src/transport/middleware/cache.d.ts +2 -0
  192. package/dist/types/src/transport/middleware/circuit-breaker.d.ts +2 -0
  193. package/dist/types/src/transport/middleware/dedup.d.ts +2 -0
  194. package/dist/types/src/transport/middleware/index.d.ts +12 -0
  195. package/dist/types/src/transport/middleware/logging.d.ts +2 -0
  196. package/dist/types/src/transport/middleware/metrics.d.ts +2 -0
  197. package/dist/types/src/transport/middleware/pipe.d.ts +2 -0
  198. package/dist/types/src/transport/middleware/rate-limit.d.ts +2 -0
  199. package/dist/types/src/transport/middleware/retry.d.ts +2 -0
  200. package/dist/types/src/transport/middleware/timeout.d.ts +2 -0
  201. package/dist/types/src/transport/middleware/tracing.d.ts +2 -0
  202. package/dist/types/src/transport/middleware/transform.d.ts +3 -0
  203. package/dist/types/src/transport/policy-context.d.ts +3 -0
  204. package/dist/types/src/transport/protocols/graphql.d.ts +2 -0
  205. package/dist/types/src/transport/protocols/grpc.d.ts +5 -0
  206. package/dist/types/src/transport/protocols/index.d.ts +5 -0
  207. package/dist/types/src/transport/protocols/json.d.ts +2 -0
  208. package/dist/types/src/transport/protocols/sse.d.ts +2 -0
  209. package/dist/types/src/transport/protocols/websocket.d.ts +2 -0
  210. package/dist/types/src/transport/runtime.d.ts +4 -0
  211. package/dist/types/src/transport/state/cache-store.d.ts +2 -0
  212. package/dist/types/src/transport/state/circuit-breaker.d.ts +2 -0
  213. package/dist/types/src/transport/state/health.d.ts +2 -0
  214. package/dist/types/src/transport/state/index.d.ts +5 -0
  215. package/dist/types/src/transport/state/rate-limiter.d.ts +2 -0
  216. package/dist/types/src/transport/state/session.d.ts +2 -0
  217. package/dist/types/src/transport/types/capabilities.d.ts +35 -0
  218. package/dist/types/src/transport/types/core.d.ts +57 -0
  219. package/dist/types/src/transport/types/events.d.ts +50 -0
  220. package/dist/types/src/transport/types/index.d.ts +7 -0
  221. package/dist/types/src/transport/types/middleware.d.ts +3 -0
  222. package/dist/types/src/transport/types/options.d.ts +258 -0
  223. package/dist/types/src/transport/types/session.d.ts +48 -0
  224. package/dist/types/src/transport/types/state.d.ts +46 -0
  225. package/package.json +93 -37
  226. package/dist/FieldStrategy-pPekBtH-.js +0 -2318
  227. package/dist/ModelTypes-B9_veCKB.js +0 -5
  228. package/dist/ReportStrategy-DY3GC_mJ.js +0 -23
  229. package/dist/boolean-field-Cd3uhIPj.js +0 -104
  230. package/dist/category-field-D_Ms1x9u.js +0 -73
  231. package/dist/classifier-prediction-C5QzorTo.js +0 -193
  232. package/dist/custom-element-ttkHUa8w.js +0 -13
  233. package/dist/date-field-Cg_ja679.js +0 -162
  234. package/dist/error-card-BwjPChwf.js +0 -195
  235. package/dist/field-wrapper-DqIQl76d.js +0 -177
  236. package/dist/ml-layout-Dx63KKf7.js +0 -332
  237. package/dist/mlform/extensions.mjs +0 -38
  238. package/dist/mlform/strategies.mjs +0 -292
  239. package/dist/number-field-CC2DrVEb.js +0 -165
  240. package/dist/property-jKFNMQpR.js +0 -561
  241. package/dist/range-field-Cr7LEtsJ.js +0 -98
  242. package/dist/regressor-prediction-C18dHlfK.js +0 -236
  243. package/dist/src/core/app/DescriptorItem.d.ts +0 -6
  244. package/dist/src/core/app/DescriptorRegistry.d.ts +0 -13
  245. package/dist/src/core/app/DescriptorService.d.ts +0 -22
  246. package/dist/src/core/app/DescriptorStrategy.d.ts +0 -11
  247. package/dist/src/core/app/index.d.ts +0 -4
  248. package/dist/src/core/domain/index.d.ts +0 -24
  249. package/dist/src/core/index.d.ts +0 -3
  250. package/dist/src/core/ui/error-card.d.ts +0 -38
  251. package/dist/src/core/ui/field-wrapper.d.ts +0 -23
  252. package/dist/src/core/ui/index.d.ts +0 -3
  253. package/dist/src/core/ui/ml-layout.d.ts +0 -23
  254. package/dist/src/extensions/app/FieldStrategy.d.ts +0 -10
  255. package/dist/src/extensions/app/ReportStrategy.d.ts +0 -9
  256. package/dist/src/extensions/app/index.d.ts +0 -2
  257. package/dist/src/extensions/domain/BaseField.d.ts +0 -7
  258. package/dist/src/extensions/domain/BaseModel.d.ts +0 -6
  259. package/dist/src/extensions/domain/index.d.ts +0 -2
  260. package/dist/src/extensions/index.d.ts +0 -3
  261. package/dist/src/extensions/ui/field-element.d.ts +0 -9
  262. package/dist/src/extensions/ui/index.d.ts +0 -1
  263. package/dist/src/index.d.ts +0 -1
  264. package/dist/src/mlform/index.d.ts +0 -1
  265. package/dist/src/mlform/mlform.d.ts +0 -27
  266. package/dist/src/mlform/mlform.types.d.ts +0 -11
  267. package/dist/src/strategies/app/BooleanStrategy.d.ts +0 -12
  268. package/dist/src/strategies/app/CategoryStrategy.d.ts +0 -13
  269. package/dist/src/strategies/app/ClassifierStrategy.d.ts +0 -15
  270. package/dist/src/strategies/app/DateStrategy.d.ts +0 -15
  271. package/dist/src/strategies/app/NumberStrategy.d.ts +0 -29
  272. package/dist/src/strategies/app/RegressorStrategy.d.ts +0 -15
  273. package/dist/src/strategies/app/TextStrategy.d.ts +0 -16
  274. package/dist/src/strategies/app/index.d.ts +0 -7
  275. package/dist/src/strategies/domain/BooleanField.d.ts +0 -10
  276. package/dist/src/strategies/domain/CategoryField.d.ts +0 -11
  277. package/dist/src/strategies/domain/ClassifierModel.d.ts +0 -11
  278. package/dist/src/strategies/domain/DateField.d.ts +0 -13
  279. package/dist/src/strategies/domain/FieldTypes.d.ts +0 -7
  280. package/dist/src/strategies/domain/ModelTypes.d.ts +0 -4
  281. package/dist/src/strategies/domain/NumberField.d.ts +0 -15
  282. package/dist/src/strategies/domain/RegressorModel.d.ts +0 -11
  283. package/dist/src/strategies/domain/TextField.d.ts +0 -14
  284. package/dist/src/strategies/domain/index.d.ts +0 -9
  285. package/dist/src/strategies/index.d.ts +0 -1
  286. package/dist/src/strategies/ui/boolean-field.d.ts +0 -13
  287. package/dist/src/strategies/ui/category-field.d.ts +0 -14
  288. package/dist/src/strategies/ui/classifier-prediction.d.ts +0 -39
  289. package/dist/src/strategies/ui/date-field.d.ts +0 -18
  290. package/dist/src/strategies/ui/index.d.ts +0 -8
  291. package/dist/src/strategies/ui/number-field.d.ts +0 -19
  292. package/dist/src/strategies/ui/range-field.d.ts +0 -17
  293. package/dist/src/strategies/ui/regressor-prediction.d.ts +0 -29
  294. package/dist/src/strategies/ui/text-field.d.ts +0 -17
  295. package/dist/state-CLlTRyl1.js +0 -12
  296. package/dist/test/_fixtures/DummyField.d.ts +0 -9
  297. package/dist/test/setup.d.ts +0 -1
  298. package/dist/test/unit/DummyField.test.d.ts +0 -1
  299. package/dist/text-field-DwP-Fa1w.js +0 -114
@@ -1,561 +0,0 @@
1
- /**
2
- * @license
3
- * Copyright 2019 Google LLC
4
- * SPDX-License-Identifier: BSD-3-Clause
5
- */
6
- const x = globalThis, k = x.ShadowRoot && (x.ShadyCSS === void 0 || x.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype, j = Symbol(), I = /* @__PURE__ */ new WeakMap();
7
- let X = class {
8
- constructor(t, e, s) {
9
- if (this._$cssResult$ = !0, s !== j) throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
10
- this.cssText = t, this.t = e;
11
- }
12
- get styleSheet() {
13
- let t = this.o;
14
- const e = this.t;
15
- if (k && t === void 0) {
16
- const s = e !== void 0 && e.length === 1;
17
- s && (t = I.get(e)), t === void 0 && ((this.o = t = new CSSStyleSheet()).replaceSync(this.cssText), s && I.set(e, t));
18
- }
19
- return t;
20
- }
21
- toString() {
22
- return this.cssText;
23
- }
24
- };
25
- const it = (r) => new X(typeof r == "string" ? r : r + "", void 0, j), Ut = (r, ...t) => {
26
- const e = r.length === 1 ? r[0] : t.reduce((s, i, n) => s + ((o) => {
27
- if (o._$cssResult$ === !0) return o.cssText;
28
- if (typeof o == "number") return o;
29
- throw Error("Value passed to 'css' function must be a 'css' function result: " + o + ". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.");
30
- })(i) + r[n + 1], r[0]);
31
- return new X(e, r, j);
32
- }, rt = (r, t) => {
33
- if (k) r.adoptedStyleSheets = t.map((e) => e instanceof CSSStyleSheet ? e : e.styleSheet);
34
- else for (const e of t) {
35
- const s = document.createElement("style"), i = x.litNonce;
36
- i !== void 0 && s.setAttribute("nonce", i), s.textContent = e.cssText, r.appendChild(s);
37
- }
38
- }, q = k ? (r) => r : (r) => r instanceof CSSStyleSheet ? ((t) => {
39
- let e = "";
40
- for (const s of t.cssRules) e += s.cssText;
41
- return it(e);
42
- })(r) : r;
43
- /**
44
- * @license
45
- * Copyright 2017 Google LLC
46
- * SPDX-License-Identifier: BSD-3-Clause
47
- */
48
- const { is: nt, defineProperty: ot, getOwnPropertyDescriptor: ht, getOwnPropertyNames: at, getOwnPropertySymbols: lt, getPrototypeOf: ct } = Object, T = globalThis, V = T.trustedTypes, dt = V ? V.emptyScript : "", pt = T.reactiveElementPolyfillSupport, S = (r, t) => r, M = { toAttribute(r, t) {
49
- switch (t) {
50
- case Boolean:
51
- r = r ? dt : null;
52
- break;
53
- case Object:
54
- case Array:
55
- r = r == null ? r : JSON.stringify(r);
56
- }
57
- return r;
58
- }, fromAttribute(r, t) {
59
- let e = r;
60
- switch (t) {
61
- case Boolean:
62
- e = r !== null;
63
- break;
64
- case Number:
65
- e = r === null ? null : Number(r);
66
- break;
67
- case Object:
68
- case Array:
69
- try {
70
- e = JSON.parse(r);
71
- } catch {
72
- e = null;
73
- }
74
- }
75
- return e;
76
- } }, D = (r, t) => !nt(r, t), W = { attribute: !0, type: String, converter: M, reflect: !1, useDefault: !1, hasChanged: D };
77
- Symbol.metadata ??= Symbol("metadata"), T.litPropertyMetadata ??= /* @__PURE__ */ new WeakMap();
78
- let g = class extends HTMLElement {
79
- static addInitializer(t) {
80
- this._$Ei(), (this.l ??= []).push(t);
81
- }
82
- static get observedAttributes() {
83
- return this.finalize(), this._$Eh && [...this._$Eh.keys()];
84
- }
85
- static createProperty(t, e = W) {
86
- if (e.state && (e.attribute = !1), this._$Ei(), this.prototype.hasOwnProperty(t) && ((e = Object.create(e)).wrapped = !0), this.elementProperties.set(t, e), !e.noAccessor) {
87
- const s = Symbol(), i = this.getPropertyDescriptor(t, s, e);
88
- i !== void 0 && ot(this.prototype, t, i);
89
- }
90
- }
91
- static getPropertyDescriptor(t, e, s) {
92
- const { get: i, set: n } = ht(this.prototype, t) ?? { get() {
93
- return this[e];
94
- }, set(o) {
95
- this[e] = o;
96
- } };
97
- return { get: i, set(o) {
98
- const a = i?.call(this);
99
- n?.call(this, o), this.requestUpdate(t, a, s);
100
- }, configurable: !0, enumerable: !0 };
101
- }
102
- static getPropertyOptions(t) {
103
- return this.elementProperties.get(t) ?? W;
104
- }
105
- static _$Ei() {
106
- if (this.hasOwnProperty(S("elementProperties"))) return;
107
- const t = ct(this);
108
- t.finalize(), t.l !== void 0 && (this.l = [...t.l]), this.elementProperties = new Map(t.elementProperties);
109
- }
110
- static finalize() {
111
- if (this.hasOwnProperty(S("finalized"))) return;
112
- if (this.finalized = !0, this._$Ei(), this.hasOwnProperty(S("properties"))) {
113
- const e = this.properties, s = [...at(e), ...lt(e)];
114
- for (const i of s) this.createProperty(i, e[i]);
115
- }
116
- const t = this[Symbol.metadata];
117
- if (t !== null) {
118
- const e = litPropertyMetadata.get(t);
119
- if (e !== void 0) for (const [s, i] of e) this.elementProperties.set(s, i);
120
- }
121
- this._$Eh = /* @__PURE__ */ new Map();
122
- for (const [e, s] of this.elementProperties) {
123
- const i = this._$Eu(e, s);
124
- i !== void 0 && this._$Eh.set(i, e);
125
- }
126
- this.elementStyles = this.finalizeStyles(this.styles);
127
- }
128
- static finalizeStyles(t) {
129
- const e = [];
130
- if (Array.isArray(t)) {
131
- const s = new Set(t.flat(1 / 0).reverse());
132
- for (const i of s) e.unshift(q(i));
133
- } else t !== void 0 && e.push(q(t));
134
- return e;
135
- }
136
- static _$Eu(t, e) {
137
- const s = e.attribute;
138
- return s === !1 ? void 0 : typeof s == "string" ? s : typeof t == "string" ? t.toLowerCase() : void 0;
139
- }
140
- constructor() {
141
- super(), this._$Ep = void 0, this.isUpdatePending = !1, this.hasUpdated = !1, this._$Em = null, this._$Ev();
142
- }
143
- _$Ev() {
144
- this._$ES = new Promise((t) => this.enableUpdating = t), this._$AL = /* @__PURE__ */ new Map(), this._$E_(), this.requestUpdate(), this.constructor.l?.forEach((t) => t(this));
145
- }
146
- addController(t) {
147
- (this._$EO ??= /* @__PURE__ */ new Set()).add(t), this.renderRoot !== void 0 && this.isConnected && t.hostConnected?.();
148
- }
149
- removeController(t) {
150
- this._$EO?.delete(t);
151
- }
152
- _$E_() {
153
- const t = /* @__PURE__ */ new Map(), e = this.constructor.elementProperties;
154
- for (const s of e.keys()) this.hasOwnProperty(s) && (t.set(s, this[s]), delete this[s]);
155
- t.size > 0 && (this._$Ep = t);
156
- }
157
- createRenderRoot() {
158
- const t = this.shadowRoot ?? this.attachShadow(this.constructor.shadowRootOptions);
159
- return rt(t, this.constructor.elementStyles), t;
160
- }
161
- connectedCallback() {
162
- this.renderRoot ??= this.createRenderRoot(), this.enableUpdating(!0), this._$EO?.forEach((t) => t.hostConnected?.());
163
- }
164
- enableUpdating(t) {
165
- }
166
- disconnectedCallback() {
167
- this._$EO?.forEach((t) => t.hostDisconnected?.());
168
- }
169
- attributeChangedCallback(t, e, s) {
170
- this._$AK(t, s);
171
- }
172
- _$ET(t, e) {
173
- const s = this.constructor.elementProperties.get(t), i = this.constructor._$Eu(t, s);
174
- if (i !== void 0 && s.reflect === !0) {
175
- const n = (s.converter?.toAttribute !== void 0 ? s.converter : M).toAttribute(e, s.type);
176
- this._$Em = t, n == null ? this.removeAttribute(i) : this.setAttribute(i, n), this._$Em = null;
177
- }
178
- }
179
- _$AK(t, e) {
180
- const s = this.constructor, i = s._$Eh.get(t);
181
- if (i !== void 0 && this._$Em !== i) {
182
- const n = s.getPropertyOptions(i), o = typeof n.converter == "function" ? { fromAttribute: n.converter } : n.converter?.fromAttribute !== void 0 ? n.converter : M;
183
- this._$Em = i;
184
- const a = o.fromAttribute(e, n.type);
185
- this[i] = a ?? this._$Ej?.get(i) ?? a, this._$Em = null;
186
- }
187
- }
188
- requestUpdate(t, e, s) {
189
- if (t !== void 0) {
190
- const i = this.constructor, n = this[t];
191
- if (s ??= i.getPropertyOptions(t), !((s.hasChanged ?? D)(n, e) || s.useDefault && s.reflect && n === this._$Ej?.get(t) && !this.hasAttribute(i._$Eu(t, s)))) return;
192
- this.C(t, e, s);
193
- }
194
- this.isUpdatePending === !1 && (this._$ES = this._$EP());
195
- }
196
- C(t, e, { useDefault: s, reflect: i, wrapped: n }, o) {
197
- s && !(this._$Ej ??= /* @__PURE__ */ new Map()).has(t) && (this._$Ej.set(t, o ?? e ?? this[t]), n !== !0 || o !== void 0) || (this._$AL.has(t) || (this.hasUpdated || s || (e = void 0), this._$AL.set(t, e)), i === !0 && this._$Em !== t && (this._$Eq ??= /* @__PURE__ */ new Set()).add(t));
198
- }
199
- async _$EP() {
200
- this.isUpdatePending = !0;
201
- try {
202
- await this._$ES;
203
- } catch (e) {
204
- Promise.reject(e);
205
- }
206
- const t = this.scheduleUpdate();
207
- return t != null && await t, !this.isUpdatePending;
208
- }
209
- scheduleUpdate() {
210
- return this.performUpdate();
211
- }
212
- performUpdate() {
213
- if (!this.isUpdatePending) return;
214
- if (!this.hasUpdated) {
215
- if (this.renderRoot ??= this.createRenderRoot(), this._$Ep) {
216
- for (const [i, n] of this._$Ep) this[i] = n;
217
- this._$Ep = void 0;
218
- }
219
- const s = this.constructor.elementProperties;
220
- if (s.size > 0) for (const [i, n] of s) {
221
- const { wrapped: o } = n, a = this[i];
222
- o !== !0 || this._$AL.has(i) || a === void 0 || this.C(i, void 0, n, a);
223
- }
224
- }
225
- let t = !1;
226
- const e = this._$AL;
227
- try {
228
- t = this.shouldUpdate(e), t ? (this.willUpdate(e), this._$EO?.forEach((s) => s.hostUpdate?.()), this.update(e)) : this._$EM();
229
- } catch (s) {
230
- throw t = !1, this._$EM(), s;
231
- }
232
- t && this._$AE(e);
233
- }
234
- willUpdate(t) {
235
- }
236
- _$AE(t) {
237
- this._$EO?.forEach((e) => e.hostUpdated?.()), this.hasUpdated || (this.hasUpdated = !0, this.firstUpdated(t)), this.updated(t);
238
- }
239
- _$EM() {
240
- this._$AL = /* @__PURE__ */ new Map(), this.isUpdatePending = !1;
241
- }
242
- get updateComplete() {
243
- return this.getUpdateComplete();
244
- }
245
- getUpdateComplete() {
246
- return this._$ES;
247
- }
248
- shouldUpdate(t) {
249
- return !0;
250
- }
251
- update(t) {
252
- this._$Eq &&= this._$Eq.forEach((e) => this._$ET(e, this[e])), this._$EM();
253
- }
254
- updated(t) {
255
- }
256
- firstUpdated(t) {
257
- }
258
- };
259
- g.elementStyles = [], g.shadowRootOptions = { mode: "open" }, g[S("elementProperties")] = /* @__PURE__ */ new Map(), g[S("finalized")] = /* @__PURE__ */ new Map(), pt?.({ ReactiveElement: g }), (T.reactiveElementVersions ??= []).push("2.1.1");
260
- /**
261
- * @license
262
- * Copyright 2017 Google LLC
263
- * SPDX-License-Identifier: BSD-3-Clause
264
- */
265
- const L = globalThis, H = L.trustedTypes, J = H ? H.createPolicy("lit-html", { createHTML: (r) => r }) : void 0, Y = "$lit$", _ = `lit$${Math.random().toFixed(9).slice(2)}$`, tt = "?" + _, ut = `<${tt}>`, y = document, b = () => y.createComment(""), w = (r) => r === null || typeof r != "object" && typeof r != "function", z = Array.isArray, $t = (r) => z(r) || typeof r?.[Symbol.iterator] == "function", R = `[
266
- \f\r]`, E = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, K = /-->/g, Z = />/g, f = RegExp(`>|${R}(?:([^\\s"'>=/]+)(${R}*=${R}*(?:[^
267
- \f\r"'\`<>=]|("|')|))|$)`, "g"), F = /'/g, G = /"/g, et = /^(?:script|style|textarea|title)$/i, _t = (r) => (t, ...e) => ({ _$litType$: r, strings: t, values: e }), Ot = _t(1), m = Symbol.for("lit-noChange"), d = Symbol.for("lit-nothing"), Q = /* @__PURE__ */ new WeakMap(), A = y.createTreeWalker(y, 129);
268
- function st(r, t) {
269
- if (!z(r) || !r.hasOwnProperty("raw")) throw Error("invalid template strings array");
270
- return J !== void 0 ? J.createHTML(t) : t;
271
- }
272
- const ft = (r, t) => {
273
- const e = r.length - 1, s = [];
274
- let i, n = t === 2 ? "<svg>" : t === 3 ? "<math>" : "", o = E;
275
- for (let a = 0; a < e; a++) {
276
- const h = r[a];
277
- let c, p, l = -1, u = 0;
278
- for (; u < h.length && (o.lastIndex = u, p = o.exec(h), p !== null); ) u = o.lastIndex, o === E ? p[1] === "!--" ? o = K : p[1] !== void 0 ? o = Z : p[2] !== void 0 ? (et.test(p[2]) && (i = RegExp("</" + p[2], "g")), o = f) : p[3] !== void 0 && (o = f) : o === f ? p[0] === ">" ? (o = i ?? E, l = -1) : p[1] === void 0 ? l = -2 : (l = o.lastIndex - p[2].length, c = p[1], o = p[3] === void 0 ? f : p[3] === '"' ? G : F) : o === G || o === F ? o = f : o === K || o === Z ? o = E : (o = f, i = void 0);
279
- const $ = o === f && r[a + 1].startsWith("/>") ? " " : "";
280
- n += o === E ? h + ut : l >= 0 ? (s.push(c), h.slice(0, l) + Y + h.slice(l) + _ + $) : h + _ + (l === -2 ? a : $);
281
- }
282
- return [st(r, n + (r[e] || "<?>") + (t === 2 ? "</svg>" : t === 3 ? "</math>" : "")), s];
283
- };
284
- class C {
285
- constructor({ strings: t, _$litType$: e }, s) {
286
- let i;
287
- this.parts = [];
288
- let n = 0, o = 0;
289
- const a = t.length - 1, h = this.parts, [c, p] = ft(t, e);
290
- if (this.el = C.createElement(c, s), A.currentNode = this.el.content, e === 2 || e === 3) {
291
- const l = this.el.content.firstChild;
292
- l.replaceWith(...l.childNodes);
293
- }
294
- for (; (i = A.nextNode()) !== null && h.length < a; ) {
295
- if (i.nodeType === 1) {
296
- if (i.hasAttributes()) for (const l of i.getAttributeNames()) if (l.endsWith(Y)) {
297
- const u = p[o++], $ = i.getAttribute(l).split(_), U = /([.?@])?(.*)/.exec(u);
298
- h.push({ type: 1, index: n, name: U[2], strings: $, ctor: U[1] === "." ? yt : U[1] === "?" ? gt : U[1] === "@" ? mt : N }), i.removeAttribute(l);
299
- } else l.startsWith(_) && (h.push({ type: 6, index: n }), i.removeAttribute(l));
300
- if (et.test(i.tagName)) {
301
- const l = i.textContent.split(_), u = l.length - 1;
302
- if (u > 0) {
303
- i.textContent = H ? H.emptyScript : "";
304
- for (let $ = 0; $ < u; $++) i.append(l[$], b()), A.nextNode(), h.push({ type: 2, index: ++n });
305
- i.append(l[u], b());
306
- }
307
- }
308
- } else if (i.nodeType === 8) if (i.data === tt) h.push({ type: 2, index: n });
309
- else {
310
- let l = -1;
311
- for (; (l = i.data.indexOf(_, l + 1)) !== -1; ) h.push({ type: 7, index: n }), l += _.length - 1;
312
- }
313
- n++;
314
- }
315
- }
316
- static createElement(t, e) {
317
- const s = y.createElement("template");
318
- return s.innerHTML = t, s;
319
- }
320
- }
321
- function v(r, t, e = r, s) {
322
- if (t === m) return t;
323
- let i = s !== void 0 ? e._$Co?.[s] : e._$Cl;
324
- const n = w(t) ? void 0 : t._$litDirective$;
325
- return i?.constructor !== n && (i?._$AO?.(!1), n === void 0 ? i = void 0 : (i = new n(r), i._$AT(r, e, s)), s !== void 0 ? (e._$Co ??= [])[s] = i : e._$Cl = i), i !== void 0 && (t = v(r, i._$AS(r, t.values), i, s)), t;
326
- }
327
- class At {
328
- constructor(t, e) {
329
- this._$AV = [], this._$AN = void 0, this._$AD = t, this._$AM = e;
330
- }
331
- get parentNode() {
332
- return this._$AM.parentNode;
333
- }
334
- get _$AU() {
335
- return this._$AM._$AU;
336
- }
337
- u(t) {
338
- const { el: { content: e }, parts: s } = this._$AD, i = (t?.creationScope ?? y).importNode(e, !0);
339
- A.currentNode = i;
340
- let n = A.nextNode(), o = 0, a = 0, h = s[0];
341
- for (; h !== void 0; ) {
342
- if (o === h.index) {
343
- let c;
344
- h.type === 2 ? c = new P(n, n.nextSibling, this, t) : h.type === 1 ? c = new h.ctor(n, h.name, h.strings, this, t) : h.type === 6 && (c = new vt(n, this, t)), this._$AV.push(c), h = s[++a];
345
- }
346
- o !== h?.index && (n = A.nextNode(), o++);
347
- }
348
- return A.currentNode = y, i;
349
- }
350
- p(t) {
351
- let e = 0;
352
- for (const s of this._$AV) s !== void 0 && (s.strings !== void 0 ? (s._$AI(t, s, e), e += s.strings.length - 2) : s._$AI(t[e])), e++;
353
- }
354
- }
355
- class P {
356
- get _$AU() {
357
- return this._$AM?._$AU ?? this._$Cv;
358
- }
359
- constructor(t, e, s, i) {
360
- this.type = 2, this._$AH = d, this._$AN = void 0, this._$AA = t, this._$AB = e, this._$AM = s, this.options = i, this._$Cv = i?.isConnected ?? !0;
361
- }
362
- get parentNode() {
363
- let t = this._$AA.parentNode;
364
- const e = this._$AM;
365
- return e !== void 0 && t?.nodeType === 11 && (t = e.parentNode), t;
366
- }
367
- get startNode() {
368
- return this._$AA;
369
- }
370
- get endNode() {
371
- return this._$AB;
372
- }
373
- _$AI(t, e = this) {
374
- t = v(this, t, e), w(t) ? t === d || t == null || t === "" ? (this._$AH !== d && this._$AR(), this._$AH = d) : t !== this._$AH && t !== m && this._(t) : t._$litType$ !== void 0 ? this.$(t) : t.nodeType !== void 0 ? this.T(t) : $t(t) ? this.k(t) : this._(t);
375
- }
376
- O(t) {
377
- return this._$AA.parentNode.insertBefore(t, this._$AB);
378
- }
379
- T(t) {
380
- this._$AH !== t && (this._$AR(), this._$AH = this.O(t));
381
- }
382
- _(t) {
383
- this._$AH !== d && w(this._$AH) ? this._$AA.nextSibling.data = t : this.T(y.createTextNode(t)), this._$AH = t;
384
- }
385
- $(t) {
386
- const { values: e, _$litType$: s } = t, i = typeof s == "number" ? this._$AC(t) : (s.el === void 0 && (s.el = C.createElement(st(s.h, s.h[0]), this.options)), s);
387
- if (this._$AH?._$AD === i) this._$AH.p(e);
388
- else {
389
- const n = new At(i, this), o = n.u(this.options);
390
- n.p(e), this.T(o), this._$AH = n;
391
- }
392
- }
393
- _$AC(t) {
394
- let e = Q.get(t.strings);
395
- return e === void 0 && Q.set(t.strings, e = new C(t)), e;
396
- }
397
- k(t) {
398
- z(this._$AH) || (this._$AH = [], this._$AR());
399
- const e = this._$AH;
400
- let s, i = 0;
401
- for (const n of t) i === e.length ? e.push(s = new P(this.O(b()), this.O(b()), this, this.options)) : s = e[i], s._$AI(n), i++;
402
- i < e.length && (this._$AR(s && s._$AB.nextSibling, i), e.length = i);
403
- }
404
- _$AR(t = this._$AA.nextSibling, e) {
405
- for (this._$AP?.(!1, !0, e); t !== this._$AB; ) {
406
- const s = t.nextSibling;
407
- t.remove(), t = s;
408
- }
409
- }
410
- setConnected(t) {
411
- this._$AM === void 0 && (this._$Cv = t, this._$AP?.(t));
412
- }
413
- }
414
- class N {
415
- get tagName() {
416
- return this.element.tagName;
417
- }
418
- get _$AU() {
419
- return this._$AM._$AU;
420
- }
421
- constructor(t, e, s, i, n) {
422
- this.type = 1, this._$AH = d, this._$AN = void 0, this.element = t, this.name = e, this._$AM = i, this.options = n, s.length > 2 || s[0] !== "" || s[1] !== "" ? (this._$AH = Array(s.length - 1).fill(new String()), this.strings = s) : this._$AH = d;
423
- }
424
- _$AI(t, e = this, s, i) {
425
- const n = this.strings;
426
- let o = !1;
427
- if (n === void 0) t = v(this, t, e, 0), o = !w(t) || t !== this._$AH && t !== m, o && (this._$AH = t);
428
- else {
429
- const a = t;
430
- let h, c;
431
- for (t = n[0], h = 0; h < n.length - 1; h++) c = v(this, a[s + h], e, h), c === m && (c = this._$AH[h]), o ||= !w(c) || c !== this._$AH[h], c === d ? t = d : t !== d && (t += (c ?? "") + n[h + 1]), this._$AH[h] = c;
432
- }
433
- o && !i && this.j(t);
434
- }
435
- j(t) {
436
- t === d ? this.element.removeAttribute(this.name) : this.element.setAttribute(this.name, t ?? "");
437
- }
438
- }
439
- class yt extends N {
440
- constructor() {
441
- super(...arguments), this.type = 3;
442
- }
443
- j(t) {
444
- this.element[this.name] = t === d ? void 0 : t;
445
- }
446
- }
447
- class gt extends N {
448
- constructor() {
449
- super(...arguments), this.type = 4;
450
- }
451
- j(t) {
452
- this.element.toggleAttribute(this.name, !!t && t !== d);
453
- }
454
- }
455
- class mt extends N {
456
- constructor(t, e, s, i, n) {
457
- super(t, e, s, i, n), this.type = 5;
458
- }
459
- _$AI(t, e = this) {
460
- if ((t = v(this, t, e, 0) ?? d) === m) return;
461
- const s = this._$AH, i = t === d && s !== d || t.capture !== s.capture || t.once !== s.once || t.passive !== s.passive, n = t !== d && (s === d || i);
462
- i && this.element.removeEventListener(this.name, this, s), n && this.element.addEventListener(this.name, this, t), this._$AH = t;
463
- }
464
- handleEvent(t) {
465
- typeof this._$AH == "function" ? this._$AH.call(this.options?.host ?? this.element, t) : this._$AH.handleEvent(t);
466
- }
467
- }
468
- class vt {
469
- constructor(t, e, s) {
470
- this.element = t, this.type = 6, this._$AN = void 0, this._$AM = e, this.options = s;
471
- }
472
- get _$AU() {
473
- return this._$AM._$AU;
474
- }
475
- _$AI(t) {
476
- v(this, t);
477
- }
478
- }
479
- const Et = L.litHtmlPolyfillSupport;
480
- Et?.(C, P), (L.litHtmlVersions ??= []).push("3.3.1");
481
- const St = (r, t, e) => {
482
- const s = e?.renderBefore ?? t;
483
- let i = s._$litPart$;
484
- if (i === void 0) {
485
- const n = e?.renderBefore ?? null;
486
- s._$litPart$ = i = new P(t.insertBefore(b(), n), n, void 0, e ?? {});
487
- }
488
- return i._$AI(r), i;
489
- };
490
- /**
491
- * @license
492
- * Copyright 2017 Google LLC
493
- * SPDX-License-Identifier: BSD-3-Clause
494
- */
495
- const B = globalThis;
496
- class O extends g {
497
- constructor() {
498
- super(...arguments), this.renderOptions = { host: this }, this._$Do = void 0;
499
- }
500
- createRenderRoot() {
501
- const t = super.createRenderRoot();
502
- return this.renderOptions.renderBefore ??= t.firstChild, t;
503
- }
504
- update(t) {
505
- const e = this.render();
506
- this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(t), this._$Do = St(e, this.renderRoot, this.renderOptions);
507
- }
508
- connectedCallback() {
509
- super.connectedCallback(), this._$Do?.setConnected(!0);
510
- }
511
- disconnectedCallback() {
512
- super.disconnectedCallback(), this._$Do?.setConnected(!1);
513
- }
514
- render() {
515
- return m;
516
- }
517
- }
518
- O._$litElement$ = !0, O.finalized = !0, B.litElementHydrateSupport?.({ LitElement: O });
519
- const bt = B.litElementPolyfillSupport;
520
- bt?.({ LitElement: O });
521
- (B.litElementVersions ??= []).push("4.2.1");
522
- /**
523
- * @license
524
- * Copyright 2017 Google LLC
525
- * SPDX-License-Identifier: BSD-3-Clause
526
- */
527
- const wt = { attribute: !0, type: String, converter: M, reflect: !1, hasChanged: D }, Ct = (r = wt, t, e) => {
528
- const { kind: s, metadata: i } = e;
529
- let n = globalThis.litPropertyMetadata.get(i);
530
- if (n === void 0 && globalThis.litPropertyMetadata.set(i, n = /* @__PURE__ */ new Map()), s === "setter" && ((r = Object.create(r)).wrapped = !0), n.set(e.name, r), s === "accessor") {
531
- const { name: o } = e;
532
- return { set(a) {
533
- const h = t.get.call(this);
534
- t.set.call(this, a), this.requestUpdate(o, h, r);
535
- }, init(a) {
536
- return a !== void 0 && this.C(o, void 0, r, a), a;
537
- } };
538
- }
539
- if (s === "setter") {
540
- const { name: o } = e;
541
- return function(a) {
542
- const h = this[o];
543
- t.call(this, a), this.requestUpdate(o, h, r);
544
- };
545
- }
546
- throw Error("Unsupported decorator location: " + s);
547
- };
548
- function Mt(r) {
549
- return (t, e) => typeof e == "object" ? Ct(r, t, e) : ((s, i, n) => {
550
- const o = i.hasOwnProperty(n);
551
- return i.constructor.createProperty(n, s), o ? Object.getOwnPropertyDescriptor(i, n) : void 0;
552
- })(r, t, e);
553
- }
554
- export {
555
- St as B,
556
- Ut as a,
557
- O as i,
558
- Mt as n,
559
- it as r,
560
- Ot as x
561
- };
@@ -1,98 +0,0 @@
1
- import { FieldElement as l } from "./mlform/extensions.mjs";
2
- import { a as c, n as p, x as b } from "./property-jKFNMQpR.js";
3
- import { t as h } from "./custom-element-ttkHUa8w.js";
4
- var d = Object.defineProperty, g = Object.getOwnPropertyDescriptor, m = (e, t, r) => t in e ? d(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r, i = (e, t, r, o) => {
5
- for (var n = o > 1 ? void 0 : o ? g(t, r) : t, u = e.length - 1, s; u >= 0; u--)
6
- (s = e[u]) && (n = (o ? s(t, r, n) : s(n)) || n);
7
- return o && n && d(t, r, n), n;
8
- }, f = (e, t, r) => m(e, t + "", r);
9
- let a = class extends l {
10
- unit = "";
11
- step = "1";
12
- firstUpdated() {
13
- this.value = Number(this.defaultValue);
14
- const e = new InputEvent("input", {
15
- bubbles: !0,
16
- composed: !0
17
- });
18
- Object.defineProperty(e, "target", {
19
- value: { value: this.defaultValue },
20
- writable: !1
21
- }), this.onInput(e);
22
- }
23
- render() {
24
- return b`
25
- <div class="input-wrapper">
26
- <input
27
- type="range"
28
- @input=${this.onInput}
29
- .min=${this.min}
30
- .max=${this.max}
31
- .step=${this.step}
32
- .value=${this.value}
33
- />
34
- </div>
35
- `;
36
- }
37
- onInput(e) {
38
- this.value = Number(e.target.value), this.dispatchState(
39
- "success",
40
- `Selected Value: ${this.value.toLocaleString("en-US")} ${this.unit}`
41
- );
42
- }
43
- };
44
- f(a, "styles", [
45
- l.baseStyles,
46
- c`
47
- input[type="range"] {
48
- width: 99%;
49
- -webkit-appearance: none;
50
- appearance: none;
51
- height: 6px;
52
- border-radius: 3px;
53
- background: var(--range-track, #d1d5db);
54
- outline: none;
55
- }
56
- input[type="range"]::-webkit-slider-thumb {
57
- -webkit-appearance: none;
58
- appearance: none;
59
- width: 18px;
60
- height: 18px;
61
- border-radius: 50%;
62
- background: var(--range-thumb, var(--ml-color-accent, #1e40af));
63
- cursor: pointer;
64
- border: 2px solid #fff;
65
- box-shadow: 0 0 2px rgba(0, 0, 0, 0.2);
66
- transition: background 0.2s ease;
67
- }
68
- input[type="range"]::-moz-range-thumb {
69
- width: 18px;
70
- height: 18px;
71
- border-radius: 50%;
72
- background: var(--range-thumb, var(--ml-color-accent, #1e40af));
73
- cursor: pointer;
74
- border: 2px solid #fff;
75
- }
76
- `
77
- ]);
78
- i([
79
- p({ type: String })
80
- ], a.prototype, "unit", 2);
81
- i([
82
- p({ type: String })
83
- ], a.prototype, "step", 2);
84
- i([
85
- p({ type: String })
86
- ], a.prototype, "min", 2);
87
- i([
88
- p({ type: String })
89
- ], a.prototype, "max", 2);
90
- i([
91
- p({ type: String })
92
- ], a.prototype, "defaultValue", 2);
93
- a = i([
94
- h("range-field")
95
- ], a);
96
- export {
97
- a as RangeField
98
- };