@thibezer/ui-components-kit 2.24.1 → 2.25.0

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 (154) hide show
  1. package/CHANGELOG.md +83 -1
  2. package/dist/botao.cjs +12 -1
  3. package/dist/botao.js +162 -3
  4. package/dist/camadas.cjs +311 -1
  5. package/dist/camadas.js +3244 -148
  6. package/dist/campo-texto.cjs +16 -1
  7. package/dist/campo-texto.js +308 -7
  8. package/dist/canvas.cjs +22 -22
  9. package/dist/canvas.js +230 -233
  10. package/dist/card.cjs +20 -1
  11. package/dist/card.js +145 -2
  12. package/dist/components/ui-canvas-prancha/index.d.ts +1 -1
  13. package/dist/components/ui-canvas-prancha/prancha-teclado.d.ts +26 -0
  14. package/dist/components/ui-canvas-prancha/ui-canvas-prancha-base.d.ts +9 -0
  15. package/dist/components/ui-canvas-prancha/ui-canvas-prancha.d.ts +2 -2
  16. package/dist/components/ui-editor-prancha/editor-barra.d.ts +19 -0
  17. package/dist/components/ui-editor-prancha/editor-modos.d.ts +35 -0
  18. package/dist/components/ui-editor-prancha/editor-tipos.d.ts +4 -0
  19. package/dist/components/ui-editor-prancha/index.d.ts +1 -0
  20. package/dist/components/ui-editor-prancha/ui-editor-prancha.d.ts +63 -7
  21. package/dist/core/alvo-digitavel.d.ts +3 -0
  22. package/dist/core.cjs +1 -1
  23. package/dist/core.js +43 -54
  24. package/dist/{cores-utils-BrdynxRd.js → cores-utils-DMyqWvZh.js} +2 -2
  25. package/dist/cores.cjs +32 -1
  26. package/dist/cores.js +300 -13
  27. package/dist/custom-elements.json +11945 -11071
  28. package/dist/data.cjs +28 -1
  29. package/dist/data.js +286 -99
  30. package/dist/{feature_caixa-2Sxv3tGa.js → feature_caixa-BVc5LenS.js} +42 -42
  31. package/dist/{feature_desenho-BVHivWIB.js → feature_desenho-CC8Mp5Gp.js} +2 -2
  32. package/dist/feedback.cjs +52 -1
  33. package/dist/feedback.js +655 -25
  34. package/dist/forms.cjs +66 -1
  35. package/dist/forms.js +1216 -39
  36. package/dist/{geometria-px-DUs5FgLE.js → geometria-px-DHMPUsxC.js} +47 -47
  37. package/dist/index.cjs +67 -1
  38. package/dist/index.js +1476 -274
  39. package/dist/kit-base-BmkPi5Rz.cjs +2 -0
  40. package/dist/kit-base-CBXA66aM.js +1084 -0
  41. package/dist/mapa.cjs +5 -5
  42. package/dist/mapa.js +16 -17
  43. package/dist/modal.cjs +18 -1
  44. package/dist/modal.js +235 -29
  45. package/dist/motor.js +49 -49
  46. package/dist/prancha-nucleo.cjs +3 -1
  47. package/dist/prancha-nucleo.js +3120 -277
  48. package/dist/prancha.cjs +38 -1
  49. package/dist/prancha.js +3470 -228
  50. package/dist/register.cjs +1 -1
  51. package/dist/register.js +3 -20
  52. package/dist/seletor-mapa-base.cjs +13 -13
  53. package/dist/seletor-mapa-base.js +3 -5
  54. package/dist/tabela.cjs +142 -1
  55. package/dist/tabela.js +3773 -92
  56. package/dist/tipos-elementos.d.ts +7 -3
  57. package/dist/tipos-vue.d.ts +6 -3
  58. package/dist/tools.cjs +16 -1
  59. package/dist/tools.js +1564 -26
  60. package/dist/{ui-seletor-cor-Cd8jkzXG.js → ui-seletor-cor-CPjA9vhZ.js} +8 -9
  61. package/dist/ui-seletor-cor-D_ifitEN.cjs +83 -0
  62. package/dist/utils-ClVgqVyJ.cjs +1 -0
  63. package/dist/utils-DrHoxxmf.js +83 -0
  64. package/package.json +43 -2
  65. package/dist/acessibilidade-CSzX-DkG.cjs +0 -1
  66. package/dist/acessibilidade-CUlSXc2X.js +0 -38
  67. package/dist/altura-controle-ukMRPckR.cjs +0 -1
  68. package/dist/altura-controle-vxQiXG4q.js +0 -62
  69. package/dist/alvo-digitavel-CzCvNVQ3.js +0 -23
  70. package/dist/alvo-digitavel-DbH0hYFf.cjs +0 -1
  71. package/dist/degrade-CIxvOTUv.cjs +0 -1
  72. package/dist/degrade-gDa5sW__.js +0 -119
  73. package/dist/feature_caixa-CnYPKVFS.cjs +0 -1
  74. package/dist/feature_caixa-DCs9ZeSk.js +0 -1038
  75. package/dist/feature_historico-BAIYk1Me.cjs +0 -3
  76. package/dist/feature_historico-C4h9y5fu.js +0 -3039
  77. package/dist/form-atalhos-7JTYvumA.cjs +0 -1
  78. package/dist/form-atalhos-DDTlpgaB.js +0 -203
  79. package/dist/form-erros-CwPz7Jr4.cjs +0 -1
  80. package/dist/form-erros-DT5HklfD.js +0 -184
  81. package/dist/form-submissao-C-SPRKgT.js +0 -61
  82. package/dist/form-submissao-DxKO5MHI.cjs +0 -1
  83. package/dist/form-validacao-BlQFxUVj.js +0 -104
  84. package/dist/form-validacao-DIeyQVH5.cjs +0 -1
  85. package/dist/geometria-px-DKrWq_XY.js +0 -639
  86. package/dist/leaflet-CEPcxGWV.cjs +0 -1
  87. package/dist/leaflet-DOq10gfg.js +0 -84
  88. package/dist/leaflet-loader-94z5VsdY.cjs +0 -2
  89. package/dist/leaflet-loader-Cjcdgj5R.js +0 -21
  90. package/dist/listener-bag-D5omxZ9h.cjs +0 -1
  91. package/dist/listener-bag-DQgv7OON.js +0 -34
  92. package/dist/motor-By2te6PZ.js +0 -1400
  93. package/dist/motor-CkMxd378.cjs +0 -1
  94. package/dist/opcoes-CupvWVIm.js +0 -24
  95. package/dist/opcoes-vdAUY5OI.cjs +0 -1
  96. package/dist/parts-CaoQiCfI.js +0 -7
  97. package/dist/parts-vQa2873h.cjs +0 -1
  98. package/dist/prancha-paleta-BZ-9QDgh.js +0 -5276
  99. package/dist/prancha-paleta-Bb24vP71.cjs +0 -17
  100. package/dist/ssr-safe-5cWfJP-s.js +0 -10
  101. package/dist/ssr-safe-CiHD1adl.cjs +0 -1
  102. package/dist/svg-seguro-ChVJ2L2z.js +0 -74
  103. package/dist/svg-seguro-J2RM1Ssf.cjs +0 -1
  104. package/dist/ui-badge-DE58YSBY.cjs +0 -28
  105. package/dist/ui-badge-KgmI3jOD.js +0 -201
  106. package/dist/ui-botao-Dz8YvmiA.cjs +0 -12
  107. package/dist/ui-botao-zLkcMMyP.js +0 -168
  108. package/dist/ui-bus-CUd99VJi.js +0 -177
  109. package/dist/ui-bus-XqBLlTYQ.cjs +0 -1
  110. package/dist/ui-camadas-DoHPnbQm.js +0 -3133
  111. package/dist/ui-camadas-Vx7wYD4D.cjs +0 -311
  112. package/dist/ui-campo-texto-Dliyt9qr.cjs +0 -16
  113. package/dist/ui-campo-texto-btevggO3.js +0 -379
  114. package/dist/ui-card-7IEYbCN0.js +0 -150
  115. package/dist/ui-card-Bx8EyzYY.cjs +0 -20
  116. package/dist/ui-card-C-EJoKnm.js +0 -150
  117. package/dist/ui-card-DFnRp9bl.js +0 -146
  118. package/dist/ui-card-DrWVJQKw.cjs +0 -20
  119. package/dist/ui-card-DsIjHMmG.cjs +0 -20
  120. package/dist/ui-controle-cores-B1w_Yl69.cjs +0 -32
  121. package/dist/ui-controle-cores-BRjMvmMn.js +0 -291
  122. package/dist/ui-controle-cores-BcH9k2Fa.js +0 -292
  123. package/dist/ui-controle-cores-CvSTP6gJ.cjs +0 -32
  124. package/dist/ui-editor-prancha-CIngI6yI.js +0 -2886
  125. package/dist/ui-editor-prancha-DorSe6sC.cjs +0 -31
  126. package/dist/ui-linha-2kY7TNUJ.cjs +0 -38
  127. package/dist/ui-linha-B4mBRm1x.cjs +0 -61
  128. package/dist/ui-linha-DTEIIww4.js +0 -1167
  129. package/dist/ui-linha-KFF86FW5.js +0 -752
  130. package/dist/ui-modal-BrXzVZ65.js +0 -216
  131. package/dist/ui-modal-lARKzEVZ.cjs +0 -18
  132. package/dist/ui-paleta-ferramentas-Bu6JaT0s.js +0 -1245
  133. package/dist/ui-paleta-ferramentas-D3Jhwt26.cjs +0 -21
  134. package/dist/ui-paleta-ferramentas-DebHYiwd.js +0 -1615
  135. package/dist/ui-paleta-ferramentas-Dgejtluh.js +0 -1423
  136. package/dist/ui-paleta-ferramentas-hzyo8wBt.cjs +0 -22
  137. package/dist/ui-paleta-ferramentas-jWuICjW8.cjs +0 -22
  138. package/dist/ui-seletor-cor-0RLjcME6.cjs +0 -83
  139. package/dist/ui-seletor-cor-CMuuW-Ym.cjs +0 -83
  140. package/dist/ui-seletor-cor-DFIQ1sin.js +0 -405
  141. package/dist/ui-skeleton-BLEV6h3k.js +0 -653
  142. package/dist/ui-skeleton-B_XTaGrX.cjs +0 -52
  143. package/dist/ui-switch-BXIDwC-Y.cjs +0 -66
  144. package/dist/ui-switch-Ctxk-jKS.js +0 -1212
  145. package/dist/ui-tabela-CXxqbwXv.cjs +0 -7
  146. package/dist/ui-tabela-Cd0vOwnT.js +0 -1459
  147. package/dist/ui-tabela-propriedades-C5cIF5ES.js +0 -3779
  148. package/dist/ui-tabela-propriedades-CJyo568n.js +0 -3517
  149. package/dist/ui-tabela-propriedades-D96Djx-q.cjs +0 -136
  150. package/dist/ui-tabela-propriedades-Wa34hfIr.cjs +0 -142
  151. package/dist/ui-tabela-propriedades-ahQhQauu.js +0 -2329
  152. package/dist/ui-tabela-propriedades-w9JWhjHy.cjs +0 -142
  153. package/dist/zero-js-triggers-CJT988bR.js +0 -83
  154. package/dist/zero-js-triggers-CgM9IIQB.cjs +0 -1
package/dist/forms.js CHANGED
@@ -1,42 +1,1219 @@
1
+ var C = Object.defineProperty;
2
+ var z = (o, i, t) => i in o ? C(o, i, { enumerable: !0, configurable: !0, writable: !0, value: t }) : o[i] = t;
3
+ var s = (o, i, t) => z(o, typeof i != "symbol" ? i + "" : i, t);
1
4
  /* empty css */
2
- import { A as o, U as e, a as i, c as t, s as l, b as c, d as p } from "./ui-campo-texto-btevggO3.js";
3
- import { A as n, L as T, a as I, R as U, U as u, b as A, c as C, d as S, e as d, f as L, g as h, h as E, i as O, j as R, k as x, r as F } from "./ui-switch-Ctxk-jKS.js";
4
- import { S as b, c as z, a as f, d as g, e as v, l as D, b as P, f as B, g as V, h as k, o as M, p as j, v as w } from "./form-atalhos-DDTlpgaB.js";
5
+ import { A as b, F as m, L as p, u as f, T as u, V as L, W as q, g as h, f as I, R as E, E as A, e as D, p as g, d, h as V, j as v, s as R, Y as x } from "./kit-base-CBXA66aM.js";
6
+ import { k as pt, m as ft, q as gt, r as xt, t as vt, w as _t, x as yt, y as Et, z as At, B as kt, D as wt, H as St, J as Ct } from "./kit-base-CBXA66aM.js";
7
+ import { sincronizarFeedbackErro as T } from "./campo-texto.js";
8
+ import { ATRIBUTOS_OBSERVADOS_CAMPO_TEXTO as Lt, UICampoTexto as qt, UIInput as It, criarTemplateCampoTexto as Dt, sincronizarIconeSenha as Vt, sincronizarLabelEPlaceholder as Rt } from "./campo-texto.js";
9
+ const M = ':host{display:flex;flex-direction:column;gap:4px;width:100%;box-sizing:border-box;font-family:var(--ui-fonte-base, "Inter", sans-serif)}:host([inline]){width:auto;display:inline-flex}.ui-area-texto__container{position:relative;width:100%;display:flex;flex-direction:column}.ui-area-texto__label{display:flex;align-items:center;justify-content:space-between;font-size:var(--ui-tamanho-corpo-sm, 13px);font-weight:var(--ui-peso-medio, 500);color:var(--ui-cor-texto, #e1e1e6);-webkit-user-select:none;user-select:none;margin-bottom:4px;flex-shrink:0}.ui-area-texto__asterisco{color:var(--ui-cor-texto-erro, #ff5555);margin-left:2px;font-weight:600}.ui-area-texto__wrapper{position:relative;display:flex;width:100%;background:var(--ui-degrade-interno, var(--ui-area-texto-fundo, var(--ui-fundo-elevado, var(--ui-cor-fundo-elevado, #1a1a1e))));border:1px solid var(--ui-cor-borda, rgba(255, 255, 255, .12));border-radius:var(--ui-raio-borda, 6px);box-sizing:border-box;transition:border-color .15s ease,box-shadow .15s ease,background-color .15s ease}.ui-area-texto__wrapper:focus-within{border-color:var(--ui-cor-primaria, #00E08A);box-shadow:0 0 0 2px color-mix(in srgb,var(--ui-cor-primaria, #00E08A) 18%,transparent);background:var(--ui-degrade-interno, var(--ui-area-texto-fundo, var(--ui-fundo-card, var(--ui-cor-fundo-menu, #18181c))))}.ui-area-texto__wrapper--erro{border-color:var(--ui-cor-texto-erro, #ff5555)!important;box-shadow:0 0 0 2px color-mix(in srgb,var(--ui-cor-texto-erro, #ff5555) 18%,transparent)!important}.ui-area-texto__wrapper--disabled{opacity:.5;cursor:not-allowed;background:var(--ui-area-texto-desabilitado-fundo, color-mix(in srgb, var(--ui-cor-texto, #e1e1e6) 3%, transparent))}.ui-area-texto__input{display:block;flex:1;width:100%;min-width:0;max-height:calc(var(--ui-area-linhas-max) * 1.5em + 12px);background:transparent;border:none;outline:none;color:var(--ui-cor-texto, #e1e1e6);font-family:inherit;font-size:var(--ui-tamanho-corpo-sm, 13px);line-height:1.5;padding:6px 8px;margin:0;box-sizing:border-box;resize:vertical;overflow-wrap:anywhere;touch-action:manipulation}.ui-area-texto__input::placeholder{color:var(--ui-cor-texto-secundario, #888899);opacity:.65}.ui-area-texto__input:disabled{cursor:not-allowed;resize:none}.ui-area-texto__rodape{display:flex;align-items:flex-start;justify-content:space-between;gap:8px}.ui-area-texto__helper{flex:1;min-width:0;font-size:var(--ui-tamanho-caption, 11px);color:var(--ui-cor-texto-secundario, #888899);line-height:var(--ui-altura-linha-compacta, 1.2);margin-top:2px}.ui-area-texto__helper--erro{color:var(--ui-cor-texto-erro, #ff5555);font-weight:500}.ui-area-texto__contador{margin-left:auto;flex-shrink:0;font-size:var(--ui-tamanho-caption, 11px);line-height:var(--ui-altura-linha-compacta, 1.2);margin-top:2px;color:var(--ui-cor-texto-secundario, #888899);font-variant-numeric:tabular-nums}.ui-area-texto__contador[hidden]{display:none}.ui-area-texto__contador--aviso{color:var(--ui-cor-texto-alerta, #ffb86c)}.ui-area-texto__contador--excedido{color:var(--ui-cor-texto-erro, #ff5555);font-weight:600}.ui-area-texto__anuncio{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}@media (max-width: 640px),(pointer: coarse) and (max-width: 1024px){.ui-area-texto__input{font-size:16px}.ui-area-texto__label{font-size:13px}}@media (prefers-reduced-motion: reduce){.ui-area-texto__wrapper{transition:none}}:host(.squarecircle) .ui-area-texto__wrapper,:host(.squarecircles) .ui-area-texto__wrapper,:host(.ui-squarecircle) .ui-area-texto__wrapper,:host(.ui-squarecircles) .ui-area-texto__wrapper,:host([formato="squarecircle"]) .ui-area-texto__wrapper,:host([formato="squarecircles"]) .ui-area-texto__wrapper,:host([formato="squircle"]) .ui-area-texto__wrapper{border-radius:var(--ui-raio-lg, 10px)}:host(.degrade),:host(.ui-degrade),:host(.gradiente),:host(.ui-gradiente),:host([degrade]:not([degrade="false"]):not([degrade="none"]):not([degrade="0"]):not([degrade="off"])),:host([gradiente]:not([gradiente="false"]):not([gradiente="none"]):not([gradiente="0"]):not([gradiente="off"])),:host([gradient]:not([gradient="false"]):not([gradient="none"]):not([gradient="0"]):not([gradient="off"])){--ui-fundo-elevado: var(--ui-gradiente-elevado);--ui-fundo-card: var(--ui-gradiente-card)}', F = [
10
+ "label",
11
+ "placeholder",
12
+ "value",
13
+ "obrigatorio",
14
+ "required",
15
+ "minlength",
16
+ "min-length",
17
+ "maxlength",
18
+ "max-length",
19
+ "mensagem-validacao",
20
+ "helper-text",
21
+ "erro",
22
+ "mensagem-erro",
23
+ "disabled",
24
+ "readonly",
25
+ "linhas",
26
+ "linhas-max",
27
+ "auto-altura",
28
+ "redimensionar",
29
+ "contador",
30
+ "aria-label",
31
+ ...b
32
+ ];
33
+ function H() {
34
+ return `
35
+ <style>${M}</style>
36
+ <div class="ui-area-texto__container">
37
+ <label class="ui-area-texto__label" part="rotulo" style="display: none;"></label>
38
+ <div class="ui-area-texto__wrapper" part="campo">
39
+ <textarea class="ui-area-texto__input" part="input" rows="4"></textarea>
40
+ </div>
41
+ </div>
42
+ <div class="ui-area-texto__rodape" part="rodape">
43
+ <div class="ui-area-texto__helper" part="ajuda" aria-live="polite" style="display: none;"></div>
44
+ <span class="ui-area-texto__contador" part="contador" aria-hidden="true" hidden></span>
45
+ </div>
46
+ <span class="ui-area-texto__anuncio" role="status" aria-live="polite"></span>
47
+ `;
48
+ }
49
+ const O = 0.9;
50
+ function $(o, i) {
51
+ const t = Number.isFinite(o) && o > 0 ? Math.trunc(o) : 0, e = i !== null && Number.isFinite(i) && i > 0 ? Math.trunc(i) : null;
52
+ if (e === null) return { texto: String(t), nivel: "normal", anuncio: "" };
53
+ const a = `${t} / ${e}`;
54
+ if (t > e)
55
+ return { texto: a, nivel: "excedido", anuncio: `Limite de ${e} caracteres excedido em ${t - e}.` };
56
+ if (t >= e * O) {
57
+ const r = e - t;
58
+ return {
59
+ texto: a,
60
+ nivel: "aviso",
61
+ anuncio: r === 0 ? `Limite de ${e} caracteres atingido.` : `Restam ${r} caracteres.`
62
+ };
63
+ }
64
+ return { texto: a, nivel: "normal", anuncio: "" };
65
+ }
66
+ function P(o, i) {
67
+ return !Number.isFinite(o) || !Number.isFinite(i) || o <= 0 || o <= i ? null : Math.ceil(o);
68
+ }
69
+ function _(o, i) {
70
+ const t = i.offsetHeight;
71
+ t > 0 && (i.style.minHeight = `${t}px`), o.style.height = "auto";
72
+ const e = P(o.scrollHeight, o.clientHeight);
73
+ e !== null && (o.style.height = `${e}px`), i.style.minHeight = "";
74
+ }
75
+ function B(o, i) {
76
+ o.style.height = "", i.style.minHeight = "";
77
+ }
78
+ const N = ["nenhum", "vertical", "horizontal", "ambos"], U = {
79
+ nenhum: "none",
80
+ vertical: "vertical",
81
+ horizontal: "horizontal",
82
+ ambos: "both"
83
+ }, K = ["normal", "aviso", "excedido"], j = 4, G = 50, W = 200;
84
+ class k extends m {
85
+ constructor() {
86
+ super();
87
+ s(this, "labelElement");
88
+ s(this, "wrapperElement");
89
+ s(this, "textareaElement");
90
+ s(this, "helperElement");
91
+ s(this, "contadorElement");
92
+ s(this, "anuncioElement");
93
+ s(this, "listeners", new p());
94
+ s(this, "_focado", !1);
95
+ s(this, "_textareaId");
96
+ s(this, "_defaultValue", "");
97
+ s(this, "_nivelAnunciado", "normal");
98
+ s(this, "handleInput", (t) => {
99
+ t.stopPropagation(), this.syncState(), this.emitirEdicao("ui-input", "input", this.textareaElement.value);
100
+ });
101
+ s(this, "handleChange", (t) => {
102
+ t.stopPropagation(), this.syncState(), this.emitirEdicao("ui-change", "change", this.textareaElement.value);
103
+ });
104
+ s(this, "handleFocus", () => {
105
+ this._focado = !0;
106
+ });
107
+ s(this, "handleBlur", () => {
108
+ this._focado = !1, this.syncState();
109
+ });
110
+ /** Ctrl/Cmd + Enter pede o envio sem submeter o `<form>`; Enter comum continua inserindo quebra de linha. */
111
+ s(this, "handleKeyDown", (t) => {
112
+ t.key !== "Enter" || t.isComposing || t.altKey || t.shiftKey || !(t.ctrlKey || t.metaKey) || this.disabled || this.readOnly || (t.preventDefault(), this.dispatchEvent(
113
+ new CustomEvent("ui-enviar", {
114
+ detail: { value: this.textareaElement.value },
115
+ bubbles: !0,
116
+ composed: !0
117
+ })
118
+ ));
119
+ });
120
+ /** Clique em `<label>` externo associado ao host foca o textarea. */
121
+ s(this, "handleHostClick", (t) => {
122
+ g(this, t) && !this.disabled && this.textareaElement.focus();
123
+ });
124
+ s(this, "handleResize", () => {
125
+ this.hasAttribute("auto-altura") && _(this.textareaElement, this.wrapperElement);
126
+ });
127
+ const t = this.attachShadow({ mode: "open", delegatesFocus: !0 });
128
+ t.innerHTML = H(), this.labelElement = t.querySelector(".ui-area-texto__label"), this.wrapperElement = t.querySelector(".ui-area-texto__wrapper"), this.textareaElement = t.querySelector(".ui-area-texto__input"), this.helperElement = t.querySelector(".ui-area-texto__helper"), this.contadorElement = t.querySelector(".ui-area-texto__contador"), this.anuncioElement = t.querySelector(".ui-area-texto__anuncio"), this._textareaId = f("ui-area"), this.textareaElement.id = this._textareaId, this.labelElement.htmlFor = this._textareaId, this.helperElement.id = `${this._textareaId}-ajuda`;
129
+ }
130
+ static get observedAttributes() {
131
+ return F;
132
+ }
133
+ connectedCallback() {
134
+ this.listeners.cleanup(), this.listeners.add(this.textareaElement, "input", this.handleInput), this.listeners.add(this.textareaElement, "change", this.handleChange), this.listeners.add(this.textareaElement, "focus", this.handleFocus), this.listeners.add(this.textareaElement, "blur", this.handleBlur), this.listeners.add(this.textareaElement, "keydown", this.handleKeyDown), this.listeners.add(this, "click", this.handleHostClick), this.listeners.add(typeof window < "u" ? window : null, "resize", this.handleResize), this._defaultValue = this.getAttribute("value") ?? "", this.hasAttribute("value") && !this.textareaElement.value && (this.textareaElement.value = this._defaultValue), this.syncState();
135
+ }
136
+ disconnectedCallback() {
137
+ this.listeners.cleanup();
138
+ }
139
+ attributeChangedCallback(t, e, a) {
140
+ t === "value" && a !== this.textareaElement.value && !this._focado && (this.textareaElement.value = a ?? ""), this.syncState();
141
+ }
142
+ // === API pública ===
143
+ focus(t) {
144
+ this.textareaElement.focus(t);
145
+ }
146
+ blur() {
147
+ this.textareaElement.blur();
148
+ }
149
+ /** Seleciona todo o texto. */
150
+ select() {
151
+ this.textareaElement.select();
152
+ }
153
+ /** Define a seleção; índices inválidos são ignorados pelo navegador, nunca lançam. */
154
+ setSelectionRange(t, e, a) {
155
+ try {
156
+ this.textareaElement.setSelectionRange(t, e, a);
157
+ } catch {
158
+ }
159
+ }
160
+ /** Apaga o texto programaticamente (sem disparar eventos de edição). */
161
+ limpar() {
162
+ this.value = "";
163
+ }
164
+ get value() {
165
+ return this.textareaElement ? this.textareaElement.value : this.getAttribute("value") ?? "";
166
+ }
167
+ set value(t) {
168
+ const e = t == null ? "" : String(t);
169
+ this.setAttribute("value", e);
170
+ try {
171
+ this.textareaElement.value = e;
172
+ } catch {
173
+ }
174
+ this.syncState();
175
+ }
176
+ get name() {
177
+ return this.getAttribute("name") || "";
178
+ }
179
+ set name(t) {
180
+ this.setAttribute("name", t);
181
+ }
182
+ get type() {
183
+ return "textarea";
184
+ }
185
+ get disabled() {
186
+ return this.hasAttribute("disabled") || this._formDisabled;
187
+ }
188
+ set disabled(t) {
189
+ t ? this.setAttribute("disabled", "") : this.removeAttribute("disabled");
190
+ }
191
+ get readOnly() {
192
+ return this.hasAttribute("readonly");
193
+ }
194
+ set readOnly(t) {
195
+ t ? this.setAttribute("readonly", "") : this.removeAttribute("readonly");
196
+ }
197
+ get minLength() {
198
+ return u(this.getAttribute("minlength") ?? this.getAttribute("min-length")) ?? -1;
199
+ }
200
+ set minLength(t) {
201
+ t >= 0 ? this.setAttribute("minlength", String(t)) : this.removeAttribute("minlength");
202
+ }
203
+ get maxLength() {
204
+ return u(this.getAttribute("maxlength") ?? this.getAttribute("max-length")) ?? -1;
205
+ }
206
+ set maxLength(t) {
207
+ t >= 0 ? this.setAttribute("maxlength", String(t)) : this.removeAttribute("maxlength");
208
+ }
209
+ // === Ciclo de Vida Form-Associated Custom Elements (W3C FACE) ===
210
+ formResetCallback() {
211
+ this.textareaElement.value = this._defaultValue, this.syncState();
212
+ }
213
+ formStateRestoreCallback(t, e) {
214
+ typeof t == "string" && (this.value = t);
215
+ }
216
+ atualizarValidade() {
217
+ const t = this.textareaElement ? this.textareaElement.value : "", e = L({
218
+ val: t,
219
+ rawVal: t,
220
+ disabled: this.disabled,
221
+ required: this.required,
222
+ tipo: "text",
223
+ minlength: u(this.getAttribute("minlength") ?? this.getAttribute("min-length")),
224
+ maxlength: u(this.getAttribute("maxlength") ?? this.getAttribute("max-length")),
225
+ customError: this._customErrorMessage,
226
+ mensagemValidacao: this.getAttribute("mensagem-validacao")
227
+ });
228
+ q(this.internals, e, this.textareaElement);
229
+ }
230
+ syncState() {
231
+ var a, r;
232
+ h(this, this.wrapperElement);
233
+ const t = this.textareaElement, e = this.hasAttribute("auto-altura");
234
+ t.setAttribute("rows", String(I(this.getAttribute("linhas"), 1, G, j))), t.placeholder = this.getAttribute("placeholder") ?? "", this.sincronizarRotulo(), this.sincronizarLimites(), this.sincronizarEstadoInterativo(), this.sincronizarFeedback(), this.sincronizarContador(), this.sincronizarAltura(e), (r = (a = this.internals) == null ? void 0 : a.setFormValue) == null || r.call(a, t.value), this.atualizarValidade();
235
+ }
236
+ sincronizarRotulo() {
237
+ const t = this.getAttribute("label");
238
+ if (t) {
239
+ E(this.labelElement, t, this.required, "ui-area-texto__asterisco"), this.labelElement.style.display = "flex", this.textareaElement.removeAttribute("aria-label");
240
+ return;
241
+ }
242
+ this.labelElement.style.display = "none";
243
+ const e = A(this, this.internals);
244
+ e ? this.textareaElement.setAttribute("aria-label", e) : this.textareaElement.removeAttribute("aria-label");
245
+ }
246
+ sincronizarLimites() {
247
+ const t = this.textareaElement, e = u(this.getAttribute("minlength") ?? this.getAttribute("min-length")), a = u(this.getAttribute("maxlength") ?? this.getAttribute("max-length"));
248
+ e !== null ? t.minLength = e : t.removeAttribute("minlength"), a !== null ? t.maxLength = a : t.removeAttribute("maxlength");
249
+ }
250
+ sincronizarEstadoInterativo() {
251
+ const t = this.textareaElement, e = this.disabled;
252
+ t.disabled = e, t.readOnly = this.readOnly, this.wrapperElement.classList.toggle("ui-area-texto__wrapper--disabled", e), this.required ? t.setAttribute("aria-required", "true") : t.removeAttribute("aria-required");
253
+ }
254
+ sincronizarFeedback() {
255
+ const t = this.hasAttribute("erro") || this.hasAttribute("mensagem-erro");
256
+ T(
257
+ this.wrapperElement,
258
+ this.textareaElement,
259
+ this.helperElement,
260
+ t,
261
+ this.getAttribute("mensagem-erro"),
262
+ this.getAttribute("helper-text"),
263
+ "ui-area-texto"
264
+ ), this.helperElement.style.display === "none" ? this.textareaElement.removeAttribute("aria-describedby") : this.textareaElement.setAttribute("aria-describedby", this.helperElement.id);
265
+ }
266
+ sincronizarContador() {
267
+ if (!this.hasAttribute("contador")) {
268
+ this.contadorElement.hidden = !0, this.anuncioElement.textContent = "", this._nivelAnunciado = "normal";
269
+ return;
270
+ }
271
+ const t = u(this.getAttribute("maxlength") ?? this.getAttribute("max-length"), 1), e = $(this.textareaElement.value.length, t);
272
+ this.contadorElement.hidden = !1, this.contadorElement.textContent = e.texto;
273
+ for (const a of K)
274
+ this.contadorElement.classList.toggle(`ui-area-texto__contador--${a}`, a === e.nivel);
275
+ e.nivel !== this._nivelAnunciado && (this._nivelAnunciado = e.nivel, this.anuncioElement.textContent = e.anuncio);
276
+ }
277
+ sincronizarAltura(t) {
278
+ const e = this.textareaElement, a = t ? "nenhum" : D(this.getAttribute("redimensionar"), N, "vertical");
279
+ e.style.resize = U[a];
280
+ const r = t ? u(this.getAttribute("linhas-max"), 1) : null;
281
+ r !== null ? this.style.setProperty("--ui-area-linhas-max", String(Math.min(r, W))) : this.style.removeProperty("--ui-area-linhas-max"), t ? _(e, this.wrapperElement) : B(e, this.wrapperElement);
282
+ }
283
+ emitirEdicao(t, e, a) {
284
+ this.dispatchEvent(
285
+ new CustomEvent(t, { detail: { value: a }, bubbles: !0, composed: !0 })
286
+ ), this.dispatchEvent(new Event(e, { bubbles: !0, composed: !0 }));
287
+ }
288
+ }
289
+ class X extends k {
290
+ }
291
+ d("ui-area-texto", k);
292
+ d("ui-textarea", X);
293
+ class Y {
294
+ constructor(i, t, e) {
295
+ s(this, "scrollHandler");
296
+ s(this, "resizeHandler");
297
+ s(this, "posicionar", () => {
298
+ if (this.isMobileOrBottomSheet()) {
299
+ this.content.style.top = "", this.content.style.left = "", this.content.style.minWidth = "";
300
+ return;
301
+ }
302
+ const i = this.button.getBoundingClientRect();
303
+ this.content.style.top = `${Math.round(i.bottom + 2)}px`, this.content.style.left = `${Math.round(i.left)}px`, this.content.style.minWidth = `${Math.round(Math.max(i.width, 120))}px`, this.ajustarAoViewport(i);
304
+ });
305
+ this.host = i, this.button = t, this.content = e;
306
+ }
307
+ isMobileOrBottomSheet() {
308
+ return typeof window > "u" ? !1 : window.innerWidth <= 640 || this.host.hasAttribute("bottom-sheet") || this.host.hasAttribute("modo-mobile");
309
+ }
310
+ /** Com a lista já visível (medida real): abre para cima se faltar espaço embaixo e não deixa sair pela lateral. */
311
+ ajustarAoViewport(i) {
312
+ const t = this.content.offsetHeight, e = this.content.offsetWidth;
313
+ if (t <= 0 || typeof window > "u") return;
314
+ const a = 8;
315
+ i.bottom + 2 + t > window.innerHeight - a && i.top - 2 - t >= a && (this.content.style.top = `${Math.round(i.top - 2 - t)}px`), i.left + e > window.innerWidth - a && (this.content.style.left = `${Math.max(a, Math.round(window.innerWidth - a - e))}px`);
316
+ }
317
+ ativarAcompanhamento(i) {
318
+ if (this.scrollHandler = i, this.resizeHandler = this.posicionar, window.addEventListener("scroll", this.scrollHandler, { capture: !0, passive: !0 }), window.addEventListener("resize", this.resizeHandler, { passive: !0 }), typeof this.content.showPopover == "function")
319
+ try {
320
+ this.content.showPopover();
321
+ } catch {
322
+ }
323
+ this.posicionar();
324
+ }
325
+ desativarAcompanhamento() {
326
+ if (this.scrollHandler && (window.removeEventListener("scroll", this.scrollHandler, { capture: !0 }), this.scrollHandler = void 0), this.resizeHandler && (window.removeEventListener("resize", this.resizeHandler), this.resizeHandler = void 0), typeof this.content.hidePopover == "function")
327
+ try {
328
+ this.content.hidePopover();
329
+ } catch {
330
+ }
331
+ }
332
+ }
333
+ class J {
334
+ constructor(i) {
335
+ s(this, "focusedIndex", -1);
336
+ this.listElement = i;
337
+ }
338
+ focarPrimeiroItem() {
339
+ const i = Array.from(this.listElement.querySelectorAll(".ui-lista-flutuante__item"));
340
+ if (i.length > 0) {
341
+ const t = i.findIndex((e) => e.classList.contains("ui-lista-flutuante__item--selecionado"));
342
+ this.focusedIndex = Math.max(0, t), i[this.focusedIndex].focus();
343
+ }
344
+ }
345
+ resetarFoco() {
346
+ this.focusedIndex = -1;
347
+ }
348
+ moverFoco(i) {
349
+ const t = Array.from(this.listElement.querySelectorAll(".ui-lista-flutuante__item"));
350
+ t.length !== 0 && (this.focusedIndex += i, this.focusedIndex < 0 && (this.focusedIndex = t.length - 1), this.focusedIndex >= t.length && (this.focusedIndex = 0), t[this.focusedIndex].focus());
351
+ }
352
+ tratarKeydownLista(i, t, e, a, r) {
353
+ if (i.key === "ArrowDown")
354
+ i.preventDefault(), this.moverFoco(1);
355
+ else if (i.key === "ArrowUp")
356
+ i.preventDefault(), this.moverFoco(-1);
357
+ else if (i.key === "Home" || i.key === "End") {
358
+ i.preventDefault();
359
+ const n = i.key === "End";
360
+ this.focusedIndex = n ? -1 : 0, n ? this.moverFoco(-1) : this.moverFoco(0);
361
+ } else i.key === "Tab" ? a() : i.key === "Enter" || i.key === " " ? (i.preventDefault(), this.focusedIndex >= 0 && this.focusedIndex < t.length && e(t[this.focusedIndex])) : i.key === "Escape" && (i.preventDefault(), a(), r.focus());
362
+ }
363
+ }
364
+ const Z = ':host{display:inline-block;position:relative;width:100%;box-sizing:border-box;font-family:var(--ui-fonte-base, "Inter", sans-serif)}:host([inline]){width:auto;vertical-align:middle}.ui-lista-flutuante__container{display:flex;flex-direction:column;width:100%;position:relative}.ui-lista-flutuante__label{font-family:var(--ui-fonte-base, "Inter", sans-serif);font-size:var(--ui-tamanho-corpo-sm, 13px);font-weight:var(--ui-peso-medio, 500);color:var(--ui-cor-texto, #e1e1e6);margin-bottom:4px;-webkit-user-select:none;user-select:none;flex-shrink:0}.ui-lista-flutuante__asterisco{color:var(--ui-cor-texto-erro, #ff5555);margin-left:2px}.ui-lista-flutuante__gatilho{display:flex;align-items:center;justify-content:space-between;gap:6px;width:100%;height:var(--ui-campo-altura, 34px);min-height:var(--ui-campo-altura, 34px);padding:0 8px;background:var(--ui-degrade-interno, var(--ui-lista-flutuante-fundo, var(--ui-fundo-elevado, var(--ui-cor-fundo-elevado, #1a1a1e))));color:var(--ui-cor-texto, #e1e1e6);border:1px solid var(--ui-cor-borda, rgba(255, 255, 255, .12));border-radius:var(--ui-raio-borda, 6px);font-family:var(--ui-fonte-base, "Inter", sans-serif);font-size:clamp(11px,.85rem,13px);line-height:1;cursor:pointer;box-sizing:border-box;touch-action:manipulation;-webkit-tap-highlight-color:transparent;transition:border-color .15s ease,background-color .15s ease}.ui-lista-flutuante__gatilho:hover:not(:disabled){border-color:var(--ui-cor-primaria, #00E08A)}.ui-lista-flutuante__gatilho:disabled{opacity:.5;cursor:not-allowed}.ui-lista-flutuante__texto{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;flex:1;text-align:left}.ui-lista-flutuante__seta{font-size:10px;line-height:1;display:inline-flex;align-items:center;justify-content:center;transition:transform .2s ease;color:var(--ui-cor-texto-secundario, #888899);flex-shrink:0;shape-rendering:geometricPrecision}:host([aberta]) .ui-lista-flutuante__seta{transform:rotate(180deg)}.ui-lista-flutuante__backdrop{display:none;position:fixed;top:0;left:0;width:100vw;height:100vh;background:transparent;-webkit-backdrop-filter:none;backdrop-filter:none;z-index:calc(var(--ui-z-popover, 1050) - 1)}:host([aberta]) .ui-lista-flutuante__backdrop{display:block}:host(:not([aberta])) .ui-lista-flutuante__conteudo{display:none!important}:host([aberta]) .ui-lista-flutuante__conteudo{display:block}.ui-lista-flutuante__conteudo{position:fixed;margin:0;padding:4px;list-style:none;background:var(--ui-degrade-interno, var(--ui-lista-flutuante-menu-fundo, var(--ui-fundo-elevado, var(--ui-cor-fundo-menu, #18181c))));border:1px solid var(--ui-cor-borda, rgba(255, 255, 255, .14));border-radius:var(--ui-raio-borda, 6px);box-shadow:var(--ui-sombra-lg, 0 8px 28px rgba(0, 0, 0, .55));max-height:220px;overflow-y:auto;z-index:var(--ui-z-popover, 1050);box-sizing:border-box;inset:auto}.ui-lista-flutuante__sheet-header{display:none;width:100%;margin-bottom:8px}.ui-lista-flutuante__handle{width:36px;height:4px;border-radius:2px;background:color-mix(in srgb,var(--ui-cor-texto, #e1e1e6) 25%,transparent);margin:2px auto 8px}.ui-lista-flutuante__sheet-title-bar{display:flex;align-items:center;justify-content:space-between;width:100%;padding:4px 6px 8px;border-bottom:1px solid var(--ui-cor-borda, rgba(255, 255, 255, .08));margin-bottom:6px}.ui-lista-flutuante__sheet-titulo{font-size:13px;font-weight:600;color:var(--ui-cor-primaria, #00E08A);letter-spacing:.3px;text-transform:uppercase}.ui-lista-flutuante__sheet-close{background:transparent;border:none;color:var(--ui-cor-texto-secundario, #888899);font-size:14px;cursor:pointer;padding:4px 8px;border-radius:var(--ui-raio-sm, 4px);display:flex;align-items:center;justify-content:center;touch-action:manipulation;-webkit-tap-highlight-color:transparent;transition:color .15s,background-color .15s}.ui-lista-flutuante__sheet-close:hover{color:#fff;background:color-mix(in srgb,var(--ui-cor-texto, #e1e1e6) 8%,transparent)}.ui-lista-flutuante__item{padding:6px 10px;font-family:var(--ui-fonte-base, "Inter", sans-serif);font-size:12px;line-height:1.2;color:var(--ui-cor-texto, #e1e1e6);border-radius:var(--ui-raio-sm, 4px);cursor:pointer;display:flex;align-items:center;justify-content:space-between;gap:8px;touch-action:manipulation;-webkit-tap-highlight-color:transparent;transition:background-color .12s ease,color .12s ease;-webkit-user-select:none;user-select:none}.ui-lista-flutuante__item:hover{background:var(--ui-cor-hover-menu, rgba(255, 255, 255, .08))}.ui-lista-flutuante__item--selecionado{background:color-mix(in srgb,var(--ui-cor-primaria, #00E08A) 15%,transparent);color:var(--ui-cor-primaria, #00E08A);font-weight:600}.ui-lista-flutuante__item--selecionado:after{content:"✓";font-size:11px;color:var(--ui-cor-primaria, #00E08A)}@media (max-width: 640px){.ui-lista-flutuante__gatilho{min-height:max(var(--ui-campo-altura, 38px),38px);font-size:15px}:host([aberta]) .ui-lista-flutuante__backdrop{background-color:#00000059;-webkit-backdrop-filter:none;backdrop-filter:none}.ui-lista-flutuante__conteudo{position:fixed!important;bottom:0!important;top:auto!important;left:0!important;width:100vw!important;max-width:100vw!important;min-width:100vw!important;max-height:70vh!important;max-height:70dvh!important;border-radius:var(--ui-raio-xl, 16px) var(--ui-raio-xl, 16px) 0 0!important;border-bottom:none!important;padding:10px 16px calc(24px + env(safe-area-inset-bottom,0px)) 16px!important;box-shadow:0 -8px 32px #000000b3!important;-webkit-overflow-scrolling:touch;overscroll-behavior:contain;animation:ui-bottom-sheet-slide .22s cubic-bezier(.4,0,.2,1)}.ui-lista-flutuante__sheet-header{display:flex!important;flex-direction:column!important}.ui-lista-flutuante__sheet-close{min-width:44px;min-height:44px;font-size:18px}.ui-lista-flutuante__item{padding:12px 14px!important;font-size:15px!important;margin-bottom:3px}}:host([bottom-sheet][aberta]) .ui-lista-flutuante__backdrop,:host([modo-mobile][aberta]) .ui-lista-flutuante__backdrop{background-color:#00000059;-webkit-backdrop-filter:none;backdrop-filter:none}:host([bottom-sheet]) .ui-lista-flutuante__conteudo,:host([modo-mobile]) .ui-lista-flutuante__conteudo{position:fixed!important;bottom:0!important;top:auto!important;left:0!important;width:100vw!important;max-width:100vw!important;min-width:100vw!important;max-height:70vh!important;max-height:70dvh!important;border-radius:var(--ui-raio-xl, 16px) var(--ui-raio-xl, 16px) 0 0!important;border-bottom:none!important;padding:10px 16px calc(24px + env(safe-area-inset-bottom,0px)) 16px!important;box-shadow:0 -8px 32px #000000b3!important;-webkit-overflow-scrolling:touch;overscroll-behavior:contain;animation:ui-bottom-sheet-slide .22s cubic-bezier(.4,0,.2,1)}:host([bottom-sheet]) .ui-lista-flutuante__sheet-header,:host([modo-mobile]) .ui-lista-flutuante__sheet-header{display:flex!important;flex-direction:column!important}:host([bottom-sheet]) .ui-lista-flutuante__sheet-close,:host([modo-mobile]) .ui-lista-flutuante__sheet-close{min-width:44px;min-height:44px;font-size:18px}:host([bottom-sheet]) .ui-lista-flutuante__item,:host([modo-mobile]) .ui-lista-flutuante__item{padding:12px 14px!important;font-size:15px!important;margin-bottom:3px}@keyframes ui-bottom-sheet-slide{0%{transform:translateY(100%)}to{transform:translateY(0)}}:host(.degrade),:host(.ui-degrade),:host(.gradiente),:host(.ui-gradiente),:host([degrade]:not([degrade="false"]):not([degrade="none"]):not([degrade="0"]):not([degrade="off"])),:host([gradiente]:not([gradiente="false"]):not([gradiente="none"]):not([gradiente="0"]):not([gradiente="off"])),:host([gradient]:not([gradient="false"]):not([gradient="none"]):not([gradient="0"]):not([gradient="off"])){--ui-fundo-elevado: var(--ui-gradiente-elevado)}', Q = [
365
+ "aberta",
366
+ "texto-padrao",
367
+ "value",
368
+ "disabled",
369
+ "bottom-sheet",
370
+ "modo-mobile",
371
+ "label",
372
+ "rotulo",
373
+ "placeholder",
374
+ "tamanho",
375
+ "size",
376
+ "altura",
377
+ "height",
378
+ "densidade",
379
+ "name",
380
+ "obrigatorio",
381
+ "required",
382
+ "mensagem-validacao",
383
+ "aria-label",
384
+ ...b
385
+ ];
386
+ function tt() {
387
+ return `
388
+ <style>${Z}</style>
389
+ <div class="ui-lista-flutuante__container">
390
+ <label class="ui-lista-flutuante__label" part="rotulo" style="display: none;"></label>
391
+ <div class="ui-lista-flutuante__backdrop"></div>
392
+ <button class="ui-lista-flutuante__gatilho" part="campo" aria-haspopup="listbox" aria-expanded="false" type="button">
393
+ <span class="ui-lista-flutuante__texto" part="valor"></span>
394
+ <span class="ui-lista-flutuante__seta" part="seta">▼</span>
395
+ </button>
396
+ <div class="ui-lista-flutuante__conteudo" part="lista" role="listbox" popover="manual">
397
+ <div class="ui-lista-flutuante__sheet-header">
398
+ <div class="ui-lista-flutuante__handle"></div>
399
+ <div class="ui-lista-flutuante__sheet-title-bar">
400
+ <span class="ui-lista-flutuante__sheet-titulo">Selecione uma opção</span>
401
+ <button class="ui-lista-flutuante__sheet-close" type="button" aria-label="Fechar">✕</button>
402
+ </div>
403
+ </div>
404
+ <ul class="ui-lista-flutuante__lista" style="margin: 0; padding: 0; list-style: none;"></ul>
405
+ </div>
406
+ </div>
407
+ `;
408
+ }
409
+ function y(o, i, t) {
410
+ o.innerHTML = "", i.forEach((e) => {
411
+ const a = document.createElement("li"), r = String(e.id) === String(t);
412
+ a.className = `ui-lista-flutuante__item ${r ? "ui-lista-flutuante__item--selecionado" : ""}`, a.setAttribute("data-id", e.id), a.textContent = e.label, a.role = "option", a.tabIndex = -1, a.setAttribute("part", r ? "opcao opcao-selecionada" : "opcao"), r && a.setAttribute("aria-selected", "true"), o.appendChild(a);
413
+ });
414
+ }
415
+ function et(o, i) {
416
+ o.querySelectorAll(".ui-lista-flutuante__item").forEach((e) => {
417
+ const a = e.getAttribute("data-id");
418
+ V(e, "opcao-selecionada", a === String(i)), a === String(i) ? (e.classList.add("ui-lista-flutuante__item--selecionado"), e.setAttribute("aria-selected", "true")) : (e.classList.remove("ui-lista-flutuante__item--selecionado"), e.removeAttribute("aria-selected"));
419
+ });
420
+ }
421
+ class w extends m {
422
+ constructor() {
423
+ super();
424
+ s(this, "labelElement");
425
+ s(this, "button");
426
+ s(this, "content");
427
+ s(this, "listElement");
428
+ s(this, "textoElement");
429
+ s(this, "backdropElement");
430
+ s(this, "sheetTituloElement");
431
+ s(this, "sheetCloseButton");
432
+ s(this, "idsAcessibilidade");
433
+ s(this, "listeners", new p());
434
+ s(this, "_itens", []);
435
+ s(this, "_value", "");
436
+ s(this, "_defaultValue", "");
437
+ s(this, "_defaultCapturado", !1);
438
+ s(this, "observer");
439
+ s(this, "posicionamento");
440
+ s(this, "teclado");
441
+ s(this, "toggleLista", (t) => {
442
+ t.stopPropagation(), !this.disabled && (this.hasAttribute("aberta") ? this.fechar() : this.abrir());
443
+ });
444
+ s(this, "handleKeyDown", (t) => {
445
+ if (!this.disabled) {
446
+ if (t.key === "Escape" && this.hasAttribute("aberta")) {
447
+ t.preventDefault(), this.fechar();
448
+ return;
449
+ }
450
+ (t.key === "Enter" || t.key === " " || t.key === "ArrowDown" || t.key === "ArrowUp") && (t.preventDefault(), this.hasAttribute("aberta") ? this.teclado.focarPrimeiroItem() : this.abrir());
451
+ }
452
+ });
453
+ s(this, "handleListKeyDown", (t) => {
454
+ this.hasAttribute("aberta") && this.teclado.tratarKeydownLista(
455
+ t,
456
+ this._itens,
457
+ (e) => this.selecionarItem(e),
458
+ this.fechar,
459
+ this.button
460
+ );
461
+ });
462
+ s(this, "fechar", () => {
463
+ this.hasAttribute("aberta") && (this.removeAttribute("aberta"), this.posicionamento.desativarAcompanhamento(), this.teclado.resetarFoco());
464
+ });
465
+ s(this, "handleClickFora", (t) => {
466
+ if (!this.hasAttribute("aberta")) return;
467
+ const e = t.composedPath();
468
+ !e.includes(this) && !e.includes(this.content) && this.fechar();
469
+ });
470
+ /** Clicar no rótulo foca o controle (comportamento do <select> nativo), sem abrir a lista. */
471
+ s(this, "focarGatilho", () => {
472
+ this.disabled || this.button.focus();
473
+ });
474
+ s(this, "handleHostClick", (t) => {
475
+ g(this, t) && this.focarGatilho();
476
+ });
477
+ s(this, "handleListClick", (t) => {
478
+ var n;
479
+ t.stopPropagation();
480
+ const e = (n = t.target) == null ? void 0 : n.closest("li[data-id]");
481
+ if (!e) return;
482
+ const a = e.getAttribute("data-id"), r = this._itens.find((c) => String(c.id) === String(a));
483
+ r && this.selecionarItem(r);
484
+ });
485
+ const t = this.attachShadow({ mode: "open" });
486
+ t.innerHTML = tt(), this.labelElement = t.querySelector(".ui-lista-flutuante__label"), this.button = t.querySelector(".ui-lista-flutuante__gatilho"), this.content = t.querySelector(".ui-lista-flutuante__conteudo"), this.listElement = t.querySelector(".ui-lista-flutuante__lista"), this.textoElement = t.querySelector(".ui-lista-flutuante__texto"), this.backdropElement = t.querySelector(".ui-lista-flutuante__backdrop"), this.sheetTituloElement = t.querySelector(".ui-lista-flutuante__sheet-titulo"), this.sheetCloseButton = t.querySelector(".ui-lista-flutuante__sheet-close");
487
+ const e = f("ui-select");
488
+ this.idsAcessibilidade = {
489
+ label: `${e}-label`,
490
+ gatilho: `${e}-gatilho`,
491
+ texto: `${e}-texto`,
492
+ lista: `${e}-lista`
493
+ }, this.labelElement.id = this.idsAcessibilidade.label, this.button.id = this.idsAcessibilidade.gatilho, this.textoElement.id = this.idsAcessibilidade.texto, this.content.id = this.idsAcessibilidade.lista, this.button.setAttribute("aria-controls", this.idsAcessibilidade.lista), this.posicionamento = new Y(this, this.button, this.content), this.teclado = new J(this.listElement);
494
+ }
495
+ static get observedAttributes() {
496
+ return Q;
497
+ }
498
+ connectedCallback() {
499
+ this.listeners.cleanup(), this.listeners.add(this.button, "click", this.toggleLista), this.listeners.add(this.button, "keydown", this.handleKeyDown), this.listeners.add(this.content, "keydown", this.handleListKeyDown), this.listeners.add(this.backdropElement, "click", this.fechar), this.listeners.add(this.listElement, "click", this.handleListClick), this.listeners.add(this.sheetCloseButton, "click", (t) => {
500
+ t.stopPropagation(), this.fechar();
501
+ }), this.listeners.add(document, "click", this.handleClickFora), this.listeners.add(this.labelElement, "click", this.focarGatilho), this.listeners.add(this, "click", this.handleHostClick), this._defaultCapturado || (this._defaultValue = this.getAttribute("value") || "", this._defaultCapturado = !0), this.carregarItensFilhos(), this.syncState(), this.observer = new MutationObserver(() => this.carregarItensFilhos()), this.observer.observe(this, { childList: !0, subtree: !0 });
502
+ }
503
+ carregarItensFilhos() {
504
+ const t = Array.from(this.querySelectorAll('option, ui-opcao, [role="option"], [data-opcao], [data-value]:not(input):not(select)'));
505
+ t.length > 0 && (this._itens = t.map((e, a) => {
506
+ var n;
507
+ const r = e.getAttribute("value") || e.getAttribute("data-value") || String(a + 1);
508
+ return {
509
+ id: r,
510
+ label: ((n = e.textContent) == null ? void 0 : n.trim()) || r || `Opção ${a + 1}`
511
+ };
512
+ }), y(this.listElement, this._itens, this._value), this.syncLabel());
513
+ }
514
+ disconnectedCallback() {
515
+ this.listeners.cleanup(), this.observer && this.observer.disconnect(), this.fechar();
516
+ }
517
+ attributeChangedCallback(t, e, a) {
518
+ t === "aberta" && this.button.setAttribute("aria-expanded", String(a !== null)), (t === "texto-padrao" || t === "placeholder" || t === "label" || t === "rotulo" || t === "aria-label") && this.syncLabel(), t === "value" && a !== this._value && (this.value = a || ""), t === "disabled" && (this.button.disabled = this.disabled), (t === "altura" || t === "height" || t === "tamanho" || t === "size" || t === "densidade") && v(this), R(t) && (h(this, this.button), h(this, this.content));
519
+ }
520
+ get value() {
521
+ return this._value;
522
+ }
523
+ set value(t) {
524
+ this._value = t, this.setAttribute("value", t), this.internals.setFormValue(t), this.syncLabel(), et(this.listElement, this._value), this.atualizarValidade();
525
+ }
526
+ get label() {
527
+ return this.getAttribute("label") || this.getAttribute("rotulo") || "";
528
+ }
529
+ set label(t) {
530
+ t ? this.setAttribute("label", t) : (this.removeAttribute("label"), this.removeAttribute("rotulo")), this.syncLabel();
531
+ }
532
+ get disabled() {
533
+ return this.hasAttribute("disabled") || this._formDisabled;
534
+ }
535
+ set disabled(t) {
536
+ t ? this.setAttribute("disabled", "") : this.removeAttribute("disabled"), this.button.disabled = this.disabled;
537
+ }
538
+ get name() {
539
+ return this.getAttribute("name") || "";
540
+ }
541
+ set name(t) {
542
+ this.setAttribute("name", t);
543
+ }
544
+ get type() {
545
+ return "select-one";
546
+ }
547
+ atualizarValidade() {
548
+ if (!this.internals || typeof this.internals.setValidity != "function") return;
549
+ if (this.disabled) {
550
+ this.internals.setValidity({});
551
+ return;
552
+ }
553
+ if (this._customErrorMessage) {
554
+ this.internals.setValidity({ customError: !0 }, this._customErrorMessage, this.button);
555
+ return;
556
+ }
557
+ if ((this.hasAttribute("obrigatorio") || this.hasAttribute("required")) && (!this._value || this._value.trim() === "")) {
558
+ const e = this.getAttribute("mensagem-validacao") || "Selecione um item da lista.";
559
+ this.internals.setValidity({ valueMissing: !0 }, e, this.button);
560
+ return;
561
+ }
562
+ this.internals.setValidity({});
563
+ }
564
+ // === Ciclo de Vida Form-Associated Custom Elements (W3C FACE) ===
565
+ formDisabledCallback(t) {
566
+ this._formDisabled = t, this.button.disabled = this.disabled, this.disabled && this.fechar();
567
+ }
568
+ formResetCallback() {
569
+ this.value = this._defaultValue;
570
+ }
571
+ formStateRestoreCallback(t, e) {
572
+ typeof t == "string" && (this.value = t);
573
+ }
574
+ get itens() {
575
+ return this._itens;
576
+ }
577
+ set itens(t) {
578
+ this._itens = t || [], y(this.listElement, this._itens, this._value), this.syncLabel();
579
+ }
580
+ abrir() {
581
+ this.disabled || this.hasAttribute("aberta") || (this.setAttribute("aberta", ""), this.posicionamento.posicionar(), this.posicionamento.ativarAcompanhamento(this.fechar));
582
+ }
583
+ syncLabel() {
584
+ const t = this.getAttribute("label") || this.getAttribute("rotulo");
585
+ if (t)
586
+ E(this.labelElement, t, this.required, "ui-lista-flutuante__asterisco"), this.labelElement.style.display = "block", this.sheetTituloElement.textContent = t, this.button.setAttribute("aria-labelledby", `${this.idsAcessibilidade.label} ${this.idsAcessibilidade.texto}`), this.content.setAttribute("aria-labelledby", this.idsAcessibilidade.label), this.button.removeAttribute("aria-label"), this.content.removeAttribute("aria-label");
587
+ else {
588
+ this.labelElement.style.display = "none", this.sincronizarRotuloExterno();
589
+ const a = this.getAttribute("texto-padrao") || this.getAttribute("placeholder") || "Opções";
590
+ this.sheetTituloElement.textContent = a;
591
+ }
592
+ const e = this._itens.find((a) => String(a.id) === String(this._value));
593
+ if (e)
594
+ this.textoElement.textContent = e.label;
595
+ else {
596
+ const a = this.getAttribute("texto-padrao") || this.getAttribute("placeholder") || "Opções";
597
+ this.textoElement.textContent = a;
598
+ }
599
+ }
600
+ /** Sem o atributo `label`, usa o rótulo de fora do Shadow DOM (aria-label, <label for>, <label> envolvente). */
601
+ sincronizarRotuloExterno() {
602
+ this.button.removeAttribute("aria-labelledby"), this.content.removeAttribute("aria-labelledby");
603
+ const t = A(this, this.internals);
604
+ t ? (this.button.setAttribute("aria-labelledby", `${this.idsAcessibilidade.gatilho} ${this.idsAcessibilidade.texto}`), this.button.setAttribute("aria-label", t), this.content.setAttribute("aria-label", t)) : (this.button.removeAttribute("aria-label"), this.content.removeAttribute("aria-label"));
605
+ }
606
+ syncState() {
607
+ v(this), h(this, this.button), h(this, this.content), this.hasAttribute("value") && (this._value = this.getAttribute("value") || "", this.internals.setFormValue(this._value)), this.syncLabel(), this.atualizarValidade();
608
+ }
609
+ selecionarItem(t) {
610
+ var r;
611
+ const e = (r = this.shadowRoot) == null ? void 0 : r.activeElement, a = !!e && this.content.contains(e);
612
+ this.value = t.id, this.fechar(), a && this.button.focus(), this.dispatchEvent(
613
+ new CustomEvent("ui-selecionar", {
614
+ detail: t,
615
+ bubbles: !0,
616
+ composed: !0
617
+ })
618
+ ), this.dispatchEvent(
619
+ new Event("input", {
620
+ bubbles: !0,
621
+ composed: !0
622
+ })
623
+ ), this.dispatchEvent(
624
+ new Event("change", {
625
+ bubbles: !0,
626
+ composed: !0
627
+ })
628
+ );
629
+ }
630
+ }
631
+ class it extends w {
632
+ }
633
+ d("ui-lista-flutuante", w);
634
+ d("ui-select", it);
635
+ const at = ':host{display:inline-flex;align-items:center;box-sizing:border-box;font-family:var(--ui-fonte-base, "Inter", sans-serif);vertical-align:middle}.ui-checkbox{display:inline-flex;align-items:center;gap:8px;cursor:pointer;-webkit-user-select:none;user-select:none;line-height:1;outline:none;touch-action:manipulation;-webkit-tap-highlight-color:transparent}.ui-checkbox--disabled{opacity:.5;cursor:not-allowed!important;pointer-events:none}.ui-checkbox__box{display:inline-flex;align-items:center;justify-content:center;width:16px;height:16px;min-width:16px;min-height:16px;background:var(--ui-checkbox-fundo, var(--ui-fundo-elevado, var(--ui-cor-fundo-elevado, #1a1a1e)));border:1px solid var(--ui-cor-borda, rgba(255, 255, 255, .16));border-radius:var(--ui-raio-sm, 4px);box-sizing:border-box;transition:background-color .15s ease,border-color .15s ease,box-shadow .15s ease;flex-shrink:0}.ui-checkbox:focus-visible .ui-checkbox__box,.ui-checkbox--foco .ui-checkbox__box{border-color:var(--ui-cor-primaria, #00E08A);box-shadow:0 0 0 2px color-mix(in srgb,var(--ui-cor-primaria, #00E08A) 25%,transparent)}.ui-checkbox--checked .ui-checkbox__box,.ui-checkbox--indeterminate .ui-checkbox__box{background:var(--ui-degrade-interno, var(--ui-checkbox-ativo-fundo, var(--ui-fundo-primario, var(--ui-cor-primaria, #00E08A))));border-color:var(--ui-cor-primaria, #00E08A);color:var(--ui-cor-texto-sobre-primaria, #000000)}.ui-checkbox__mark{width:12px;height:12px;display:flex;align-items:center;justify-content:center;transition:transform .15s cubic-bezier(.4,0,.2,1),opacity .15s ease;transform:scale(0);opacity:0}.ui-checkbox--checked .ui-checkbox__mark,.ui-checkbox--indeterminate .ui-checkbox__mark{transform:scale(1);opacity:1}.ui-checkbox__mark svg{width:100%;height:100%;fill:none;stroke:currentColor;stroke-width:3;stroke-linecap:round;stroke-linejoin:round;shape-rendering:geometricPrecision}.ui-checkbox__label{display:inline-flex;align-items:center;font-size:clamp(11px,.85rem,14px);color:var(--ui-cor-texto, #e1e1e6);line-height:1}.ui-checkbox--label-esquerda{flex-direction:row-reverse}@media (max-width: 640px){.ui-checkbox{min-height:40px;padding:4px 0}.ui-checkbox__box{width:20px;height:20px;min-width:20px;min-height:20px}.ui-checkbox__mark{width:14px;height:14px}.ui-checkbox__label{font-size:14px}}:host(.squarecircle) .ui-checkbox__box,:host(.squarecircles) .ui-checkbox__box,:host(.ui-squarecircle) .ui-checkbox__box,:host(.ui-squarecircles) .ui-checkbox__box,:host([formato="squarecircle"]) .ui-checkbox__box,:host([formato="squarecircles"]) .ui-checkbox__box,:host([formato="squircle"]) .ui-checkbox__box{border-radius:var(--ui-raio-squircle, 24%)}:host(.degrade),:host(.ui-degrade),:host(.gradiente),:host(.ui-gradiente),:host([degrade]:not([degrade="false"]):not([degrade="none"]):not([degrade="0"]):not([degrade="off"])),:host([gradiente]:not([gradiente="false"]):not([gradiente="none"]):not([gradiente="0"]):not([gradiente="off"])),:host([gradient]:not([gradient="false"]):not([gradient="none"]):not([gradient="0"]):not([gradient="off"])){--ui-fundo-elevado: var(--ui-gradiente-elevado);--ui-fundo-primario: var(--ui-gradiente-primario)}';
636
+ class st extends m {
637
+ constructor() {
638
+ super();
639
+ s(this, "containerElement");
640
+ s(this, "markElement");
641
+ s(this, "labelElement");
642
+ s(this, "listeners", new p());
643
+ s(this, "_defaultChecked", !1);
644
+ s(this, "_defaultIndeterminate", !1);
645
+ s(this, "handleClick", (t) => {
646
+ t.preventDefault(), this.alternar();
647
+ });
648
+ s(this, "handleHostClick", (t) => {
649
+ g(this, t) && (this.alternar(), this.containerElement.focus());
650
+ });
651
+ s(this, "handleKeyDown", (t) => {
652
+ (t.key === " " || t.key === "Enter") && (t.preventDefault(), this.alternar());
653
+ });
654
+ s(this, "handleFocus", () => {
655
+ this.containerElement.classList.add("ui-checkbox--foco");
656
+ });
657
+ s(this, "handleBlur", () => {
658
+ this.containerElement.classList.remove("ui-checkbox--foco");
659
+ });
660
+ const t = this.attachShadow({ mode: "open" });
661
+ t.innerHTML = `
662
+ <style>${at}</style>
663
+ <div class="ui-checkbox" part="base" tabindex="0" role="checkbox" aria-checked="false">
664
+ <span class="ui-checkbox__box" part="controle">
665
+ <span class="ui-checkbox__mark" part="indicador"></span>
666
+ </span>
667
+ <span class="ui-checkbox__label" part="rotulo" style="display: none;"></span>
668
+ </div>
669
+ `, this.containerElement = t.querySelector(".ui-checkbox"), this.markElement = t.querySelector(".ui-checkbox__mark"), this.labelElement = t.querySelector(".ui-checkbox__label"), this.labelElement.id = f("ui-checkbox-label");
670
+ }
671
+ static get observedAttributes() {
672
+ return [
673
+ "marcado",
674
+ "checked",
675
+ "indeterminado",
676
+ "indeterminate",
677
+ "disabled",
678
+ "formato",
679
+ "value",
680
+ "label",
681
+ "posicao-label",
682
+ "name",
683
+ "obrigatorio",
684
+ "required",
685
+ "mensagem-validacao",
686
+ ...b
687
+ ];
688
+ }
689
+ connectedCallback() {
690
+ this.listeners.cleanup(), this.listeners.add(this.containerElement, "click", this.handleClick), this.listeners.add(this.containerElement, "keydown", this.handleKeyDown), this.listeners.add(this.containerElement, "focus", this.handleFocus), this.listeners.add(this.containerElement, "blur", this.handleBlur), this.listeners.add(this, "click", this.handleHostClick), this._defaultChecked = this.hasAttribute("marcado") || this.hasAttribute("checked"), this._defaultIndeterminate = this.hasAttribute("indeterminado") || this.hasAttribute("indeterminate"), this.syncState();
691
+ }
692
+ disconnectedCallback() {
693
+ this.listeners.cleanup();
694
+ }
695
+ attributeChangedCallback(t, e, a) {
696
+ this.syncState();
697
+ }
698
+ get marcado() {
699
+ return this.hasAttribute("marcado") || this.hasAttribute("checked");
700
+ }
701
+ set marcado(t) {
702
+ t ? this.setAttribute("marcado", "") : (this.removeAttribute("marcado"), this.removeAttribute("checked")), this.syncState();
703
+ }
704
+ get checked() {
705
+ return this.marcado;
706
+ }
707
+ set checked(t) {
708
+ this.marcado = t;
709
+ }
710
+ get value() {
711
+ return this.getAttribute("value") || "on";
712
+ }
713
+ set value(t) {
714
+ this.setAttribute("value", t), this.syncState();
715
+ }
716
+ get name() {
717
+ return this.getAttribute("name") || "";
718
+ }
719
+ set name(t) {
720
+ this.setAttribute("name", t), this.syncState();
721
+ }
722
+ get indeterminado() {
723
+ return this.hasAttribute("indeterminado") || this.hasAttribute("indeterminate");
724
+ }
725
+ set indeterminado(t) {
726
+ t ? this.setAttribute("indeterminado", "") : (this.removeAttribute("indeterminado"), this.removeAttribute("indeterminate")), this.syncState();
727
+ }
728
+ get disabled() {
729
+ return this.hasAttribute("disabled") || this._formDisabled;
730
+ }
731
+ set disabled(t) {
732
+ t ? this.setAttribute("disabled", "") : this.removeAttribute("disabled"), this.syncState();
733
+ }
734
+ get type() {
735
+ return "checkbox";
736
+ }
737
+ atualizarValidade() {
738
+ if (!this.internals || typeof this.internals.setValidity != "function") return;
739
+ if (this.disabled) {
740
+ this.internals.setValidity({});
741
+ return;
742
+ }
743
+ if (this._customErrorMessage) {
744
+ this.internals.setValidity({ customError: !0 }, this._customErrorMessage, this.containerElement);
745
+ return;
746
+ }
747
+ if ((this.hasAttribute("obrigatorio") || this.hasAttribute("required")) && !this.marcado) {
748
+ const e = this.getAttribute("mensagem-validacao") || "Marque esta caixa para continuar.";
749
+ this.internals.setValidity({ valueMissing: !0 }, e, this.containerElement);
750
+ return;
751
+ }
752
+ this.internals.setValidity({});
753
+ }
754
+ /** `focus()` no host leva o foco ao controle interno (necessário para o foco de validação do formulário). */
755
+ focus(t) {
756
+ this.containerElement.focus(t);
757
+ }
758
+ alternar() {
759
+ this.disabled || (this.indeterminado ? (this.indeterminado = !1, this.marcado = !0) : this.marcado = !this.marcado, this.dispatchEvent(
760
+ new CustomEvent("ui-change", {
761
+ detail: {
762
+ marcado: this.marcado,
763
+ indeterminado: this.indeterminado,
764
+ value: this.getAttribute("value") || ""
765
+ },
766
+ bubbles: !0,
767
+ composed: !0
768
+ })
769
+ ), this.dispatchEvent(
770
+ new Event("change", {
771
+ bubbles: !0,
772
+ composed: !0
773
+ })
774
+ ));
775
+ }
776
+ syncState() {
777
+ h(this, this.containerElement);
778
+ const t = this.marcado, e = this.indeterminado, a = this.disabled, r = this.getAttribute("label"), n = this.getAttribute("posicao-label") || "direita";
779
+ this.containerElement.setAttribute(
780
+ "aria-checked",
781
+ e ? "mixed" : String(t)
782
+ ), a ? (this.containerElement.classList.add("ui-checkbox--disabled"), this.containerElement.setAttribute("tabindex", "-1"), this.containerElement.setAttribute("aria-disabled", "true")) : (this.containerElement.classList.remove("ui-checkbox--disabled"), this.containerElement.setAttribute("tabindex", "0"), this.containerElement.removeAttribute("aria-disabled")), t ? this.containerElement.classList.add("ui-checkbox--checked") : this.containerElement.classList.remove("ui-checkbox--checked"), e ? this.containerElement.classList.add("ui-checkbox--indeterminate") : this.containerElement.classList.remove("ui-checkbox--indeterminate"), n === "esquerda" ? this.containerElement.classList.add("ui-checkbox--label-esquerda") : this.containerElement.classList.remove("ui-checkbox--label-esquerda"), e ? this.markElement.innerHTML = `
783
+ <svg viewBox="0 0 24 24">
784
+ <line x1="5" y1="12" x2="19" y2="12"></line>
785
+ </svg>
786
+ ` : t ? this.markElement.innerHTML = `
787
+ <svg viewBox="0 0 24 24">
788
+ <polyline points="20 6 9 17 4 12"></polyline>
789
+ </svg>
790
+ ` : this.markElement.innerHTML = "", x({
791
+ host: this,
792
+ internals: this.internals,
793
+ controle: this.containerElement,
794
+ rotulo: this.labelElement,
795
+ texto: r
796
+ }), t ? this.internals.setFormValue(this.getAttribute("value") || "on") : this.internals.setFormValue(null), this.atualizarValidade();
797
+ }
798
+ // === Ciclo de Vida Form-Associated Custom Elements (W3C FACE) ===
799
+ formResetCallback() {
800
+ this.marcado = this._defaultChecked, this.indeterminado = this._defaultIndeterminate, this.syncState();
801
+ }
802
+ formStateRestoreCallback(t, e) {
803
+ typeof t == "string" ? this.marcado = t === (this.getAttribute("value") || "on") : typeof t == "boolean" && (this.marcado = t), this.syncState();
804
+ }
805
+ }
806
+ d("ui-checkbox", st);
807
+ const rt = ':host{display:inline-flex;align-items:center;box-sizing:border-box;font-family:var(--ui-fonte-base, "Inter", sans-serif);vertical-align:middle}.ui-radio{display:inline-flex;align-items:center;gap:8px;cursor:pointer;-webkit-user-select:none;user-select:none;line-height:1;outline:none}.ui-radio--disabled{opacity:.5;cursor:not-allowed!important;pointer-events:none}.ui-radio__circle{display:inline-flex;align-items:center;justify-content:center;width:16px;height:16px;min-width:16px;min-height:16px;background:var(--ui-radio-fundo, var(--ui-fundo-elevado, var(--ui-cor-fundo-elevado, #1a1a1e)));border:1px solid var(--ui-cor-borda, rgba(255, 255, 255, .16));border-radius:50%;box-sizing:border-box;transition:background-color .15s ease,border-color .15s ease,box-shadow .15s ease;flex-shrink:0}.ui-radio:focus-visible .ui-radio__circle,.ui-radio--foco .ui-radio__circle{border-color:var(--ui-cor-primaria, #00E08A);box-shadow:0 0 0 2px color-mix(in srgb,var(--ui-cor-primaria, #00E08A) 25%,transparent)}.ui-radio--checked .ui-radio__circle{border-color:var(--ui-cor-primaria, #00E08A)}.ui-radio__dot{width:8px;height:8px;border-radius:50%;background:var(--ui-degrade-interno, var(--ui-radio-ativo-fundo, var(--ui-fundo-primario, var(--ui-cor-primaria, #00E08A))));transition:transform .15s cubic-bezier(.4,0,.2,1),opacity .15s ease;transform:scale(0);opacity:0}.ui-radio--checked .ui-radio__dot{transform:scale(1);opacity:1}.ui-radio__label{display:inline-flex;align-items:center;font-size:clamp(11px,.85rem,14px);color:var(--ui-cor-texto, #e1e1e6);line-height:1}.ui-radio--label-esquerda{flex-direction:row-reverse}:host(.degrade),:host(.ui-degrade),:host(.gradiente),:host(.ui-gradiente),:host([degrade]:not([degrade="false"]):not([degrade="none"]):not([degrade="0"]):not([degrade="off"])),:host([gradiente]:not([gradiente="false"]):not([gradiente="none"]):not([gradiente="0"]):not([gradiente="off"])),:host([gradient]:not([gradient="false"]):not([gradient="none"]):not([gradient="0"]):not([gradient="off"])){--ui-fundo-elevado: var(--ui-gradiente-elevado);--ui-fundo-primario: var(--ui-gradiente-primario)}';
808
+ class l {
809
+ static getScopeNode(i) {
810
+ return i.closest("form") || i.getRootNode() || document;
811
+ }
812
+ /** Registra (ou re-registra, se o nome ou o escopo mudaram) o radio no grupo do seu nome atual. */
813
+ static registrar(i) {
814
+ this.desregistrar(i);
815
+ const t = i.name;
816
+ if (!t) return;
817
+ const e = this.getScopeNode(i);
818
+ let a = this.registry.get(e);
819
+ a || (a = /* @__PURE__ */ new Map(), this.registry.set(e, a));
820
+ let r = a.get(t);
821
+ r || (r = /* @__PURE__ */ new Set(), a.set(t, r)), r.add(i), this.registros.set(i, { scope: e, nome: t });
822
+ }
823
+ static desregistrar(i) {
824
+ const t = this.registros.get(i);
825
+ if (!t) return;
826
+ this.registros.delete(i);
827
+ const e = this.registry.get(t.scope), a = e == null ? void 0 : e.get(t.nome);
828
+ !e || !a || (a.delete(i), a.size === 0 && e.delete(t.nome), e.size === 0 && this.registry.delete(t.scope));
829
+ }
830
+ /** Radios do mesmo grupo que `radio`, usando o registro (não o nome atual, que pode ainda não ter sido registrado). */
831
+ static obterRadiosDoGrupo(i) {
832
+ var a;
833
+ const t = this.registros.get(i);
834
+ if (!t) return [];
835
+ const e = (a = this.registry.get(t.scope)) == null ? void 0 : a.get(t.nome);
836
+ return e ? Array.from(e) : [];
837
+ }
838
+ static desmarcarOutros(i) {
839
+ this.obterRadiosDoGrupo(i).forEach((t) => {
840
+ t !== i && (t.removeAttribute("marcado"), t.removeAttribute("checked"), t.syncState());
841
+ });
842
+ }
843
+ /** Reavalia o tabindex (roving) dos radios; use depois de entrar, sair ou mudar de grupo. */
844
+ static atualizarGrupo(i) {
845
+ i.forEach((t) => t.atualizarTabindex());
846
+ }
847
+ static tratarNavegacaoTeclado(i, t) {
848
+ if (!["ArrowDown", "ArrowRight", "ArrowUp", "ArrowLeft"].includes(i.key)) return;
849
+ i.preventDefault();
850
+ const e = this.obterRadiosDoGrupo(t).filter((c) => !c.disabled && c.isConnected);
851
+ if (e.length <= 1) return;
852
+ const a = e.indexOf(t), r = i.key === "ArrowDown" || i.key === "ArrowRight", n = (a + (r ? 1 : -1) + e.length) % e.length;
853
+ if (n !== a) {
854
+ const c = e[n];
855
+ c.selecionar(), c.focus();
856
+ }
857
+ }
858
+ }
859
+ s(l, "registry", /* @__PURE__ */ new WeakMap()), s(l, "registros", /* @__PURE__ */ new WeakMap());
860
+ class ot extends m {
861
+ constructor() {
862
+ super();
863
+ s(this, "containerElement");
864
+ s(this, "labelElement");
865
+ s(this, "listeners", new p());
866
+ s(this, "_defaultChecked", !1);
867
+ s(this, "handleClick", (t) => {
868
+ t.preventDefault(), this.selecionar(), this.containerElement.focus();
869
+ });
870
+ s(this, "handleHostClick", (t) => {
871
+ g(this, t) && (this.selecionar(), this.containerElement.focus());
872
+ });
873
+ s(this, "handleKeyDown", (t) => {
874
+ t.key === " " || t.key === "Enter" ? (t.preventDefault(), this.selecionar()) : l.tratarNavegacaoTeclado(t, this);
875
+ });
876
+ s(this, "handleFocus", () => {
877
+ this.containerElement.classList.add("ui-radio--foco");
878
+ });
879
+ s(this, "handleBlur", () => {
880
+ this.containerElement.classList.remove("ui-radio--foco");
881
+ });
882
+ const t = this.attachShadow({ mode: "open" });
883
+ t.innerHTML = `
884
+ <style>${rt}</style>
885
+ <div class="ui-radio" part="base" tabindex="0" role="radio" aria-checked="false">
886
+ <span class="ui-radio__circle" part="controle">
887
+ <span class="ui-radio__dot" part="indicador"></span>
888
+ </span>
889
+ <span class="ui-radio__label" part="rotulo" style="display: none;"></span>
890
+ </div>
891
+ `, this.containerElement = t.querySelector(".ui-radio"), this.labelElement = t.querySelector(".ui-radio__label"), this.labelElement.id = f("ui-radio-label");
892
+ }
893
+ static get observedAttributes() {
894
+ return [
895
+ "marcado",
896
+ "checked",
897
+ "name",
898
+ "nome",
899
+ "disabled",
900
+ "value",
901
+ "label",
902
+ "posicao-label",
903
+ "obrigatorio",
904
+ "required",
905
+ "mensagem-validacao",
906
+ ...b
907
+ ];
908
+ }
909
+ connectedCallback() {
910
+ this.listeners.cleanup(), this.listeners.add(this.containerElement, "click", this.handleClick), this.listeners.add(this.containerElement, "keydown", this.handleKeyDown), this.listeners.add(this.containerElement, "focus", this.handleFocus), this.listeners.add(this.containerElement, "blur", this.handleBlur), this.listeners.add(this, "click", this.handleHostClick), this._defaultChecked = this.hasAttribute("marcado") || this.hasAttribute("checked"), l.registrar(this), this.syncState(), l.atualizarGrupo(l.obterRadiosDoGrupo(this).filter((t) => t !== this));
911
+ }
912
+ disconnectedCallback() {
913
+ this.listeners.cleanup();
914
+ const t = l.obterRadiosDoGrupo(this).filter((e) => e !== this && e.isConnected);
915
+ l.desregistrar(this), l.atualizarGrupo(t);
916
+ }
917
+ attributeChangedCallback(t, e, a) {
918
+ if ((t === "name" || t === "nome") && this.isConnected) {
919
+ const r = l.obterRadiosDoGrupo(this).filter((n) => n !== this);
920
+ l.registrar(this), this.syncState(), l.atualizarGrupo([...r, ...l.obterRadiosDoGrupo(this).filter((n) => n !== this)]);
921
+ return;
922
+ }
923
+ this.syncState();
924
+ }
925
+ get marcado() {
926
+ return this.hasAttribute("marcado") || this.hasAttribute("checked");
927
+ }
928
+ set marcado(t) {
929
+ t ? this.setAttribute("marcado", "") : (this.removeAttribute("marcado"), this.removeAttribute("checked"));
930
+ }
931
+ get name() {
932
+ return this.getAttribute("name") || this.getAttribute("nome") || "";
933
+ }
934
+ set name(t) {
935
+ this.setAttribute("name", t);
936
+ }
937
+ get disabled() {
938
+ return this.hasAttribute("disabled") || this._formDisabled;
939
+ }
940
+ set disabled(t) {
941
+ t ? this.setAttribute("disabled", "") : this.removeAttribute("disabled"), this.syncState();
942
+ }
943
+ get type() {
944
+ return "radio";
945
+ }
946
+ atualizarValidade() {
947
+ if (!this.internals || typeof this.internals.setValidity != "function") return;
948
+ if (this.disabled) {
949
+ this.internals.setValidity({});
950
+ return;
951
+ }
952
+ if (this._customErrorMessage) {
953
+ this.internals.setValidity({ customError: !0 }, this._customErrorMessage, this.containerElement);
954
+ return;
955
+ }
956
+ const t = l.obterRadiosDoGrupo(this);
957
+ if ((this.required || t.length > 0 && t.some((a) => a.required)) && !(this.marcado || t.length > 0 && t.some((r) => r.marcado))) {
958
+ const r = this.getAttribute("mensagem-validacao") || "Selecione uma opção.";
959
+ this.internals.setValidity({ valueMissing: !0 }, r, this.containerElement);
960
+ return;
961
+ }
962
+ this.internals.setValidity({});
963
+ }
964
+ focus(t) {
965
+ this.containerElement.focus(t);
966
+ }
967
+ selecionar() {
968
+ this.disabled || this.marcado || (this.marcado = !0, l.desmarcarOutros(this), this.dispatchEvent(
969
+ new CustomEvent("ui-change", {
970
+ detail: {
971
+ marcado: !0,
972
+ name: this.name,
973
+ value: this.getAttribute("value") || ""
974
+ },
975
+ bubbles: !0,
976
+ composed: !0
977
+ })
978
+ ), this.dispatchEvent(
979
+ new Event("change", {
980
+ bubbles: !0,
981
+ composed: !0
982
+ })
983
+ ), l.obterRadiosDoGrupo(this).forEach((t) => t.atualizarValidade()));
984
+ }
985
+ /**
986
+ * Roving tabindex: só um radio do grupo entra na ordem de Tab (o marcado; sem marcado, o primeiro habilitado).
987
+ * Isolado de `syncState` para reavaliar os vizinhos sem mexer no valor/validade do formulário.
988
+ */
989
+ atualizarTabindex() {
990
+ if (this.disabled) {
991
+ this.containerElement.setAttribute("tabindex", "-1");
992
+ return;
993
+ }
994
+ const t = l.obterRadiosDoGrupo(this).filter((e) => e.isConnected || e === this);
995
+ if (t.length === 0) {
996
+ this.containerElement.setAttribute("tabindex", "0");
997
+ return;
998
+ }
999
+ if (t.some((e) => e.marcado))
1000
+ this.containerElement.setAttribute("tabindex", this.marcado ? "0" : "-1");
1001
+ else {
1002
+ const e = t.find((a) => !a.disabled);
1003
+ this.containerElement.setAttribute("tabindex", e === this ? "0" : "-1");
1004
+ }
1005
+ }
1006
+ syncState() {
1007
+ h(this, this.containerElement);
1008
+ const t = this.marcado, e = this.disabled, a = this.getAttribute("label"), r = this.getAttribute("posicao-label") || "direita";
1009
+ this.containerElement.setAttribute("aria-checked", String(t)), this.atualizarTabindex(), e ? (this.containerElement.classList.add("ui-radio--disabled"), this.containerElement.setAttribute("aria-disabled", "true")) : (this.containerElement.classList.remove("ui-radio--disabled"), this.containerElement.removeAttribute("aria-disabled")), t ? this.containerElement.classList.add("ui-radio--checked") : this.containerElement.classList.remove("ui-radio--checked"), r === "esquerda" ? this.containerElement.classList.add("ui-radio--label-esquerda") : this.containerElement.classList.remove("ui-radio--label-esquerda"), x({
1010
+ host: this,
1011
+ internals: this.internals,
1012
+ controle: this.containerElement,
1013
+ rotulo: this.labelElement,
1014
+ texto: a
1015
+ }), t ? this.internals.setFormValue(this.getAttribute("value") || "on") : this.internals.setFormValue(null), this.atualizarValidade();
1016
+ }
1017
+ // === Ciclo de Vida Form-Associated Custom Elements (W3C FACE) ===
1018
+ formResetCallback() {
1019
+ this.marcado = this._defaultChecked, this._defaultChecked ? this.internals.setFormValue(this.getAttribute("value") || "on") : this.internals.setFormValue(null), this.atualizarValidade();
1020
+ }
1021
+ formStateRestoreCallback(t, e) {
1022
+ typeof t == "string" ? this.marcado = t === (this.getAttribute("value") || "on") : typeof t == "boolean" && (this.marcado = t), this.syncState();
1023
+ }
1024
+ }
1025
+ d("ui-radio", ot);
1026
+ const nt = ':host{display:inline-flex;align-items:center;box-sizing:border-box;font-family:var(--ui-fonte-base, "Inter", sans-serif);vertical-align:middle}.ui-switch{display:inline-flex;align-items:center;gap:8px;cursor:pointer;-webkit-user-select:none;user-select:none;line-height:1;outline:none;touch-action:manipulation;-webkit-tap-highlight-color:transparent}.ui-switch--disabled{opacity:.5;cursor:not-allowed!important;pointer-events:none}.ui-switch__track{display:inline-flex;align-items:center;position:relative;width:36px;height:20px;background:var(--ui-switch-fundo, var(--ui-fundo-elevado, var(--ui-cor-fundo-elevado, #1a1a1e)));border:1px solid var(--ui-cor-borda, rgba(255, 255, 255, .16));border-radius:var(--ui-raio-pill, 999px);box-sizing:border-box;padding:1px;transition:background-color .2s ease,border-color .2s ease,box-shadow .2s ease;flex-shrink:0}.ui-switch:focus-visible .ui-switch__track,.ui-switch--foco .ui-switch__track{border-color:var(--ui-cor-primaria, #00E08A);box-shadow:0 0 0 2px color-mix(in srgb,var(--ui-cor-primaria, #00E08A) 25%,transparent)}.ui-switch--checked .ui-switch__track{background:var(--ui-degrade-interno, var(--ui-switch-ativo-fundo, var(--ui-fundo-primario, var(--ui-cor-primaria, #00E08A))));border-color:var(--ui-cor-primaria, #00E08A)}.ui-switch__thumb{display:block;width:16px;height:16px;background:#fff;border-radius:50%;box-shadow:var(--ui-sombra-sm, 0 1px 3px rgba(0, 0, 0, .3));transition:transform .2s cubic-bezier(.4,0,.2,1),background-color .2s ease;transform:translate(0)}.ui-switch--checked .ui-switch__thumb{transform:translate(16px);background:var(--ui-cor-texto-sobre-primaria, #000000)}.ui-switch--sm .ui-switch__track{width:28px;height:16px;padding:1px}.ui-switch--sm .ui-switch__thumb{width:12px;height:12px}.ui-switch--sm.ui-switch--checked .ui-switch__thumb{transform:translate(12px)}.ui-switch--lg .ui-switch__track{width:44px;height:24px;padding:1px}.ui-switch--lg .ui-switch__thumb{width:20px;height:20px}.ui-switch--lg.ui-switch--checked .ui-switch__thumb{transform:translate(20px)}.ui-switch__label{display:inline-flex;align-items:center;font-size:clamp(11px,.85rem,14px);color:var(--ui-cor-texto, #e1e1e6);line-height:1}.ui-switch--label-esquerda{flex-direction:row-reverse}@media (max-width: 640px){.ui-switch{min-height:40px;padding:4px 0}.ui-switch__label{font-size:14px}}:host(.degrade),:host(.ui-degrade),:host(.gradiente),:host(.ui-gradiente),:host([degrade]:not([degrade="false"]):not([degrade="none"]):not([degrade="0"]):not([degrade="off"])),:host([gradiente]:not([gradiente="false"]):not([gradiente="none"]):not([gradiente="0"]):not([gradiente="off"])),:host([gradient]:not([gradient="false"]):not([gradient="none"]):not([gradient="0"]):not([gradient="off"])){--ui-fundo-elevado: var(--ui-gradiente-elevado);--ui-fundo-primario: var(--ui-gradiente-primario)}';
1027
+ class S extends m {
1028
+ constructor() {
1029
+ super();
1030
+ s(this, "containerElement");
1031
+ s(this, "labelElement");
1032
+ s(this, "labelId");
1033
+ s(this, "listeners", new p());
1034
+ s(this, "_defaultChecked", !1);
1035
+ s(this, "handleClick", (t) => {
1036
+ t.preventDefault(), this.alternar();
1037
+ });
1038
+ s(this, "handleHostClick", (t) => {
1039
+ g(this, t) && (this.alternar(), this.containerElement.focus());
1040
+ });
1041
+ s(this, "handleKeyDown", (t) => {
1042
+ (t.key === " " || t.key === "Enter") && (t.preventDefault(), this.alternar());
1043
+ });
1044
+ s(this, "handleFocus", () => {
1045
+ this.containerElement.classList.add("ui-switch--foco");
1046
+ });
1047
+ s(this, "handleBlur", () => {
1048
+ this.containerElement.classList.remove("ui-switch--foco");
1049
+ });
1050
+ const t = this.attachShadow({ mode: "open" });
1051
+ t.innerHTML = `
1052
+ <style>${nt}</style>
1053
+ <div class="ui-switch" part="base" tabindex="0" role="switch" aria-checked="false">
1054
+ <span class="ui-switch__track" part="controle">
1055
+ <span class="ui-switch__thumb" part="indicador"></span>
1056
+ </span>
1057
+ <span class="ui-switch__label" part="rotulo" style="display: none;"></span>
1058
+ </div>
1059
+ `, this.containerElement = t.querySelector(".ui-switch"), this.labelElement = t.querySelector(".ui-switch__label"), this.labelId = f("ui-switch-label"), this.labelElement.id = this.labelId;
1060
+ }
1061
+ static get observedAttributes() {
1062
+ return [
1063
+ "ativo",
1064
+ "ligado",
1065
+ "checked",
1066
+ "disabled",
1067
+ "tamanho",
1068
+ "size",
1069
+ "label",
1070
+ "posicao-label",
1071
+ "value",
1072
+ "name",
1073
+ "obrigatorio",
1074
+ "required",
1075
+ "mensagem-validacao",
1076
+ "aria-label",
1077
+ ...b
1078
+ ];
1079
+ }
1080
+ connectedCallback() {
1081
+ this.listeners.cleanup(), this.listeners.add(this.containerElement, "click", this.handleClick), this.listeners.add(this.containerElement, "keydown", this.handleKeyDown), this.listeners.add(this.containerElement, "focus", this.handleFocus), this.listeners.add(this.containerElement, "blur", this.handleBlur), this.listeners.add(this, "click", this.handleHostClick), this._defaultChecked = this.hasAttribute("ativo") || this.hasAttribute("ligado") || this.hasAttribute("checked"), this.syncState();
1082
+ }
1083
+ disconnectedCallback() {
1084
+ this.listeners.cleanup();
1085
+ }
1086
+ attributeChangedCallback(t, e, a) {
1087
+ this.syncState();
1088
+ }
1089
+ get ativo() {
1090
+ return this.hasAttribute("ativo") || this.hasAttribute("ligado") || this.hasAttribute("checked");
1091
+ }
1092
+ set ativo(t) {
1093
+ t ? this.setAttribute("ativo", "") : (this.removeAttribute("ativo"), this.removeAttribute("ligado"), this.removeAttribute("checked")), this.syncState();
1094
+ }
1095
+ get checked() {
1096
+ return this.ativo;
1097
+ }
1098
+ set checked(t) {
1099
+ this.ativo = t;
1100
+ }
1101
+ get value() {
1102
+ return this.getAttribute("value") || "on";
1103
+ }
1104
+ set value(t) {
1105
+ this.setAttribute("value", t), this.syncState();
1106
+ }
1107
+ get name() {
1108
+ return this.getAttribute("name") || "";
1109
+ }
1110
+ set name(t) {
1111
+ this.setAttribute("name", t), this.syncState();
1112
+ }
1113
+ get disabled() {
1114
+ return this.hasAttribute("disabled") || this._formDisabled;
1115
+ }
1116
+ set disabled(t) {
1117
+ t ? this.setAttribute("disabled", "") : this.removeAttribute("disabled"), this.syncState();
1118
+ }
1119
+ get type() {
1120
+ return "checkbox";
1121
+ }
1122
+ atualizarValidade() {
1123
+ if (!this.internals || typeof this.internals.setValidity != "function") return;
1124
+ if (this.disabled) {
1125
+ this.internals.setValidity({});
1126
+ return;
1127
+ }
1128
+ if (this._customErrorMessage) {
1129
+ this.internals.setValidity({ customError: !0 }, this._customErrorMessage, this.containerElement);
1130
+ return;
1131
+ }
1132
+ if ((this.hasAttribute("obrigatorio") || this.hasAttribute("required")) && !this.ativo) {
1133
+ const e = this.getAttribute("mensagem-validacao") || "Ative este interruptor para continuar.";
1134
+ this.internals.setValidity({ valueMissing: !0 }, e, this.containerElement);
1135
+ return;
1136
+ }
1137
+ this.internals.setValidity({});
1138
+ }
1139
+ /** `focus()` no host leva o foco ao controle interno (necessário para o foco de validação do formulário). */
1140
+ focus(t) {
1141
+ this.containerElement.focus(t);
1142
+ }
1143
+ alternar() {
1144
+ this.disabled || (this.ativo = !this.ativo, this.dispatchEvent(
1145
+ new CustomEvent("ui-change", {
1146
+ detail: {
1147
+ ativo: this.ativo,
1148
+ value: this.getAttribute("value") || ""
1149
+ },
1150
+ bubbles: !0,
1151
+ composed: !0
1152
+ })
1153
+ ), this.dispatchEvent(
1154
+ new Event("change", {
1155
+ bubbles: !0,
1156
+ composed: !0
1157
+ })
1158
+ ));
1159
+ }
1160
+ syncState() {
1161
+ const t = this.ativo, e = this.disabled, a = this.getAttribute("tamanho") || this.getAttribute("size") || "md", r = this.getAttribute("label"), n = this.getAttribute("posicao-label") || "direita";
1162
+ h(this, this.containerElement), this.containerElement.setAttribute("aria-checked", String(t)), e ? (this.containerElement.classList.add("ui-switch--disabled"), this.containerElement.setAttribute("tabindex", "-1"), this.containerElement.setAttribute("aria-disabled", "true")) : (this.containerElement.classList.remove("ui-switch--disabled"), this.containerElement.setAttribute("tabindex", "0"), this.containerElement.removeAttribute("aria-disabled")), t ? this.containerElement.classList.add("ui-switch--checked") : this.containerElement.classList.remove("ui-switch--checked"), this.containerElement.classList.remove("ui-switch--sm", "ui-switch--md", "ui-switch--lg"), ["sm", "md", "lg"].includes(a) ? this.containerElement.classList.add(`ui-switch--${a}`) : this.containerElement.classList.add("ui-switch--md"), n === "esquerda" ? this.containerElement.classList.add("ui-switch--label-esquerda") : this.containerElement.classList.remove("ui-switch--label-esquerda"), x({
1163
+ host: this,
1164
+ internals: this.internals,
1165
+ controle: this.containerElement,
1166
+ rotulo: this.labelElement,
1167
+ texto: r
1168
+ }), t ? this.internals.setFormValue(this.getAttribute("value") || "on") : this.internals.setFormValue(null), this.atualizarValidade();
1169
+ }
1170
+ // === Ciclo de Vida Form-Associated Custom Elements (W3C FACE) ===
1171
+ formResetCallback() {
1172
+ this.ativo = this._defaultChecked, this.syncState();
1173
+ }
1174
+ formStateRestoreCallback(t, e) {
1175
+ typeof t == "string" ? this.ativo = t === (this.getAttribute("value") || "on") : typeof t == "boolean" && (this.ativo = t), this.syncState();
1176
+ }
1177
+ }
1178
+ class lt extends S {
1179
+ }
1180
+ d("ui-switch", S);
1181
+ d("ui-toggle", lt);
5
1182
  export {
6
- o as ATRIBUTOS_OBSERVADOS_CAMPO_TEXTO,
7
- n as ATRIBUTOS_OBSERVADOS_LISTA_FLUTUANTE,
8
- T as ListaFlutuantePosicionamento,
9
- I as ListaFlutuanteTeclado,
10
- U as RadioGrupoRegistry,
11
- b as SELETOR_CAMPOS_PADRAO,
12
- u as UIAreaTexto,
13
- e as UICampoTexto,
14
- A as UICheckbox,
15
- i as UIInput,
16
- C as UIListaFlutuante,
17
- S as UIRadio,
18
- d as UISelect,
19
- L as UISwitch,
20
- h as UITextarea,
21
- E as UIToggle,
22
- O as atualizarEstadoSelecaoLista,
23
- R as calcularContador,
24
- z as chaveDoCampo,
25
- f as criarRascunhoFormulario,
26
- t as criarTemplateCampoTexto,
27
- x as criarTemplateListaFlutuante,
28
- g as definirValorCampo,
29
- v as ehCampoMarcavel,
30
- D as lerValorCampo,
31
- P as ligarAtalhosFormulario,
32
- B as limparErros,
33
- V as listarCampos,
34
- k as localizarCampo,
35
- M as observarLimpezaDeErros,
36
- j as preencherCampos,
37
- F as renderizarItensLista,
38
- l as sincronizarFeedbackErro,
39
- c as sincronizarIconeSenha,
40
- p as sincronizarLabelEPlaceholder,
41
- w as validarCampos
1183
+ Lt as ATRIBUTOS_OBSERVADOS_CAMPO_TEXTO,
1184
+ Q as ATRIBUTOS_OBSERVADOS_LISTA_FLUTUANTE,
1185
+ Y as ListaFlutuantePosicionamento,
1186
+ J as ListaFlutuanteTeclado,
1187
+ l as RadioGrupoRegistry,
1188
+ pt as SELETOR_CAMPOS_PADRAO,
1189
+ k as UIAreaTexto,
1190
+ qt as UICampoTexto,
1191
+ st as UICheckbox,
1192
+ It as UIInput,
1193
+ w as UIListaFlutuante,
1194
+ ot as UIRadio,
1195
+ it as UISelect,
1196
+ S as UISwitch,
1197
+ X as UITextarea,
1198
+ lt as UIToggle,
1199
+ et as atualizarEstadoSelecaoLista,
1200
+ $ as calcularContador,
1201
+ ft as chaveDoCampo,
1202
+ gt as criarRascunhoFormulario,
1203
+ Dt as criarTemplateCampoTexto,
1204
+ tt as criarTemplateListaFlutuante,
1205
+ xt as definirValorCampo,
1206
+ vt as ehCampoMarcavel,
1207
+ _t as lerValorCampo,
1208
+ yt as ligarAtalhosFormulario,
1209
+ Et as limparErros,
1210
+ At as listarCampos,
1211
+ kt as localizarCampo,
1212
+ wt as observarLimpezaDeErros,
1213
+ St as preencherCampos,
1214
+ y as renderizarItensLista,
1215
+ T as sincronizarFeedbackErro,
1216
+ Vt as sincronizarIconeSenha,
1217
+ Rt as sincronizarLabelEPlaceholder,
1218
+ Ct as validarCampos
42
1219
  };