@reformer/builder 3.0.0-beta.6 → 3.0.0-beta.7

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 (167) hide show
  1. package/README.md +32 -198
  2. package/bin/reformer-builder.d.mts +7 -9
  3. package/bin/reformer-builder.mjs +43 -54
  4. package/dist/assets/css/index-DgRudQqc.css +1 -0
  5. package/dist/assets/css/monaco-runtime-Ch4loDnq.css +1 -0
  6. package/dist/assets/i18n/en-DHElWsPO.js +1 -0
  7. package/dist/assets/i18n/ru-DXsuKRv9.js +1 -0
  8. package/dist/assets/js/index-BSeq6-8S.js +67 -0
  9. package/dist/assets/js/index-CQvmAVe0.js +115 -0
  10. package/dist/assets/js/naming-9aaM0Wbc.js +1 -0
  11. package/dist/assets/js/rules-CM1OzesO.js +1 -0
  12. package/dist/assets/js/selectors-BiPlGN2c.js +1 -0
  13. package/dist/assets/monaco/html-R9lQ-L9C.js +1 -0
  14. package/dist/assets/monaco/javascript-COUjr2au.js +1 -0
  15. package/dist/assets/monaco/jsonMode-C3DAkvde.js +12 -0
  16. package/dist/assets/monaco/monaco-runtime-DNdOZY7f.js +924 -0
  17. package/dist/assets/monaco/typescript-CVSiBX9O.js +1 -0
  18. package/dist/assets/monaco/xml-ee1lph4p.js +1 -0
  19. package/dist/assets/monaco/yaml-DXPc9WLc.js +1 -0
  20. package/dist/assets/{byok-D0ncJaTq.js → plugins/ai-byok-DgeZQTZb.js} +55 -55
  21. package/dist/assets/plugins/ai-jKAVkXuU.js +178 -0
  22. package/dist/assets/plugins/ai-knowledge-docs-DCjqodcj.js +1 -0
  23. package/dist/assets/plugins/ai-knowledge-index-bUfNPqlZ.js +1 -0
  24. package/dist/assets/plugins/codegen-B0riFOHC.js +416 -0
  25. package/dist/assets/{MarkdownPreview-DXY3eJ1Z.js → plugins/editor-markdown-MarkdownPreview-DyHZvj8H.js} +20 -20
  26. package/dist/assets/plugins/editor-markdown-oiBrRpM4.js +2 -0
  27. package/dist/assets/plugins/editor-schema-CVPAk-MV.js +4 -0
  28. package/dist/assets/plugins/plugin-manager-BmjjSqYy.js +1 -0
  29. package/dist/assets/plugins/templates-DNeIl0cD.js +2 -0
  30. package/dist/assets/vendor/ajv-CCplthOF.js +8 -0
  31. package/dist/assets/vendor/collapsible-base-DZxAKbAF-h07cIL_F.js +1 -0
  32. package/dist/assets/vendor/highlight.js/common-g0-hl6Ud.js +5 -0
  33. package/dist/assets/vendor/index-jGqhTST4.js +6 -0
  34. package/dist/assets/vendor/lucide-react/eye-COs0olKf.js +1 -0
  35. package/dist/assets/vendor/lucide-react/file-code-corner-BMVX-Qf1.js +1 -0
  36. package/dist/assets/vendor/lucide-react/rotate-ccw-D0mVnqJN.js +1 -0
  37. package/dist/assets/vendor/lucide-react/wrench-BX6KiYsu.js +1 -0
  38. package/dist/assets/vendor/message-base-B5jT1FuY-GU8TkaN4.js +1 -0
  39. package/dist/assets/vendor/reformer-cdk/async-boundary-DPu-1Ifi.js +1 -0
  40. package/dist/assets/vendor/reformer-cdk/define-steps-CyGUrx9p-B_03D9I7.js +1 -0
  41. package/dist/assets/vendor/reformer-cdk/file-upload-C_DEa-OT.js +1 -0
  42. package/dist/assets/vendor/reformer-cdk/form-array-DRkRfAUh.js +1 -0
  43. package/dist/assets/vendor/reformer-cdk/form-wizard-DFqFjH7E.js +1 -0
  44. package/dist/assets/vendor/reformer-cdk/index-BXFomK5m.js +1 -0
  45. package/dist/assets/vendor/reformer-cdk/list-BrqYwhrQ.js +1 -0
  46. package/dist/assets/vendor/reformer-form-registry/index-s1IAa6Lm.js +1 -0
  47. package/dist/assets/vendor/reformer-form-registry/loader-BK2c_fCA-D59m3JOQ.js +2 -0
  48. package/dist/assets/vendor/reformer-form-registry/react-B8lbN6s4.js +1 -0
  49. package/dist/assets/vendor/reformer-form-registry/storage-BbhnRE7V.js +1 -0
  50. package/dist/assets/vendor/reformer-form-registry/types-DoMH_n1U-BSN9tyeo.js +1 -0
  51. package/dist/assets/vendor/reformer-renderer-json/validate-C5Gll2Yt.js +8 -0
  52. package/dist/assets/vendor/reformer-ui-kit/alert-base-WOl_V-qI-CYoSap05.js +1 -0
  53. package/dist/assets/vendor/reformer-ui-kit/component-catalog-BKjWf5Yx.js +1 -0
  54. package/dist/assets/{typescript-BuFxP6n6.js → vendor/typescript/typescript-Dp5hP5cS.js} +1 -1
  55. package/dist/index.html +4 -4
  56. package/package.json +15 -18
  57. package/runtime-config.schema.json +17 -60
  58. package/dist/assets/App-DRJnHAjE.js +0 -1137
  59. package/dist/assets/BootError-CiPUX-Tr.js +0 -1
  60. package/dist/assets/ChatPanel-CnU7eT8N.js +0 -82
  61. package/dist/assets/CodeEditor-Wv0NRzV8.js +0 -1
  62. package/dist/assets/RawJsonEditor-c354H_pY.js +0 -1
  63. package/dist/assets/abap-DLDM7-KI.js +0 -1
  64. package/dist/assets/apex-DNDY2TF8.js +0 -1
  65. package/dist/assets/azcli-Y6nb8tq_.js +0 -1
  66. package/dist/assets/bat-BwHxbl9M.js +0 -1
  67. package/dist/assets/bicep-CFznDFnq.js +0 -2
  68. package/dist/assets/boot-5_JU0zay.js +0 -2
  69. package/dist/assets/cameligo-Bf6VGUru.js +0 -1
  70. package/dist/assets/clojure-Dnu-v4kV.js +0 -1
  71. package/dist/assets/coffee-Bd8akH9Z.js +0 -1
  72. package/dist/assets/cpp-BbWJElDN.js +0 -1
  73. package/dist/assets/csharp-Co3qMtFm.js +0 -1
  74. package/dist/assets/csp-D-4FJmMZ.js +0 -1
  75. package/dist/assets/cypher-cTPe9QuQ.js +0 -1
  76. package/dist/assets/dart-BOtBlQCF.js +0 -1
  77. package/dist/assets/dockerfile-BG73LgW2.js +0 -1
  78. package/dist/assets/ecl-BEgZUVRK.js +0 -1
  79. package/dist/assets/editor-BzOv8av-.css +0 -1
  80. package/dist/assets/editor.api-CMCnIB-P.js +0 -865
  81. package/dist/assets/elixir-BkW5O-1t.js +0 -1
  82. package/dist/assets/flow9-BeJ5waoc.js +0 -1
  83. package/dist/assets/freemarker2-C645vQBx.js +0 -3
  84. package/dist/assets/fsharp-PahG7c26.js +0 -1
  85. package/dist/assets/go-acbASCJo.js +0 -1
  86. package/dist/assets/graphql-BxJiqAUM.js +0 -1
  87. package/dist/assets/handlebars-B5DnoJkq.js +0 -1
  88. package/dist/assets/hcl-DtV1sZF8.js +0 -1
  89. package/dist/assets/html-TNLrm0oH.js +0 -1
  90. package/dist/assets/index--0tYkbnz.js +0 -3
  91. package/dist/assets/index-BKc-soqk.css +0 -1
  92. package/dist/assets/index-BLGbxQaR.js +0 -104
  93. package/dist/assets/index-Bb-H-IRh.js +0 -1
  94. package/dist/assets/index-BivFj4xA.js +0 -10
  95. package/dist/assets/index-C_YSTVSM.js +0 -68
  96. package/dist/assets/index-Crsub4wy.js +0 -5028
  97. package/dist/assets/index-D2vdVqoN.js +0 -11
  98. package/dist/assets/index-DBBur3Kg.js +0 -4709
  99. package/dist/assets/index-DzAasWzr.css +0 -1
  100. package/dist/assets/ini-Kd9XrMLS.js +0 -1
  101. package/dist/assets/java-CXBNlu9o.js +0 -1
  102. package/dist/assets/javascript-YmJoSFNK.js +0 -1
  103. package/dist/assets/jsonMode-BgHFRVOe.css +0 -1
  104. package/dist/assets/jsonMode-CUyarZ9Q.js +0 -70
  105. package/dist/assets/julia-cl7-CwDS.js +0 -1
  106. package/dist/assets/kotlin-s7OhZKlX.js +0 -1
  107. package/dist/assets/less-9HpZscsL.js +0 -2
  108. package/dist/assets/lexon-OrD6JF1K.js +0 -1
  109. package/dist/assets/liquid-CsrVJLkL.js +0 -1
  110. package/dist/assets/load-DahhU28W.js +0 -11
  111. package/dist/assets/lua-Cyyb5UIc.js +0 -1
  112. package/dist/assets/m3-B8OfTtLu.js +0 -1
  113. package/dist/assets/mdx-DDXJg3VI.js +0 -1
  114. package/dist/assets/mips-CiqrrVzr.js +0 -1
  115. package/dist/assets/monaco-languages-CfiXabIS.js +0 -2
  116. package/dist/assets/monaco-setup-DPehMZ7o.js +0 -12
  117. package/dist/assets/msdax-DmeGPVcC.js +0 -1
  118. package/dist/assets/mysql-C_tMU-Nz.js +0 -1
  119. package/dist/assets/objective-c-BDtDVThU.js +0 -1
  120. package/dist/assets/pascal-vHIfCaH5.js +0 -1
  121. package/dist/assets/pascaligo-DtZ0uQbO.js +0 -1
  122. package/dist/assets/perl-Ub6l9XKa.js +0 -1
  123. package/dist/assets/pgsql-BlNEE0v7.js +0 -1
  124. package/dist/assets/php-BBUBE1dy.js +0 -1
  125. package/dist/assets/pla-DSh2-awV.js +0 -1
  126. package/dist/assets/postiats-CocnycG-.js +0 -1
  127. package/dist/assets/powerquery-tScXyioY.js +0 -1
  128. package/dist/assets/powershell-COWaemsV.js +0 -1
  129. package/dist/assets/protobuf-Brw8urJB.js +0 -2
  130. package/dist/assets/pug-8SOpv6rk.js +0 -1
  131. package/dist/assets/python-DpnOD9VM.js +0 -1
  132. package/dist/assets/qsharp-Bw9ernYp.js +0 -1
  133. package/dist/assets/r-j7ic8hl3.js +0 -1
  134. package/dist/assets/razor-BsF1GcFZ.js +0 -1
  135. package/dist/assets/redis-Bu5POkcn.js +0 -1
  136. package/dist/assets/redshift-Bs9aos_-.js +0 -1
  137. package/dist/assets/reformer-ui-kit-11-Bml4F8Os.js +0 -1
  138. package/dist/assets/reformer-ui-kit-BWUaVvO0.js +0 -1
  139. package/dist/assets/restructuredtext-CqXO7rUv.js +0 -1
  140. package/dist/assets/ruby-zBfavPgS.js +0 -1
  141. package/dist/assets/rust-BzKRNQWT.js +0 -1
  142. package/dist/assets/sb-BBc9UKZt.js +0 -1
  143. package/dist/assets/scala-D9hQfWCl.js +0 -1
  144. package/dist/assets/scheme-BPhDTwHR.js +0 -1
  145. package/dist/assets/scss-CBJaRo0y.js +0 -3
  146. package/dist/assets/shell-DiJ1NA_G.js +0 -1
  147. package/dist/assets/solidity-Db0IVjzk.js +0 -1
  148. package/dist/assets/sophia-CnS9iZB_.js +0 -1
  149. package/dist/assets/sparql-CJmd_6j2.js +0 -1
  150. package/dist/assets/sql-ClhHkBeG.js +0 -1
  151. package/dist/assets/st-CHwy0fLd.js +0 -1
  152. package/dist/assets/swift-CnmFD0ga.js +0 -1
  153. package/dist/assets/systemverilog-Bs9z6M-B.js +0 -1
  154. package/dist/assets/tcl-Dm6ycUr_.js +0 -1
  155. package/dist/assets/twig-Csy3S7wG.js +0 -1
  156. package/dist/assets/typescript-D7ER-DvA.js +0 -1
  157. package/dist/assets/typespec-Btyra-wh.js +0 -1
  158. package/dist/assets/useFormField-BLbvmpme-CM4hze15.js +0 -1
  159. package/dist/assets/vb-Db0cS2oM.js +0 -1
  160. package/dist/assets/wgsl-BTesnYfV.js +0 -298
  161. package/dist/assets/xml-5MzZ4-DY.js +0 -1
  162. package/dist/assets/yaml-Ch0E2rII.js +0 -1
  163. /package/dist/assets/{codicon-Brq4_Ui5.ttf → fonts/codicon-Brq4_Ui5.ttf} +0 -0
  164. /package/dist/assets/{css-DdJfP1eB.js → monaco/css-DdJfP1eB.js} +0 -0
  165. /package/dist/assets/{editor.worker-CRaYpIdo.js → monaco/editor.worker-CRaYpIdo.js} +0 -0
  166. /package/dist/assets/{json.worker-C5PEkLU0.js → monaco/json.worker-C5PEkLU0.js} +0 -0
  167. /package/dist/assets/{markdown-BFxVWTOG.js → monaco/markdown-BFxVWTOG.js} +0 -0
@@ -1 +0,0 @@
1
- import{a as vt,b as pt,r as f,W as mt,j as A}from"./index-BivFj4xA.js";var yt=pt();const br=vt(yt);function gt(...t){return e=>{for(const r of t)typeof r=="function"?r(e):r!=null&&(r.current=e)}}function bt(t){return Object.getOwnPropertyDescriptor(t.props,"ref")?.get?.isReactWarning?t.ref:Object.getOwnPropertyDescriptor(t,"ref")?.get?.isReactWarning?t.props.ref:t.props.ref??t.ref}function wt(t,e){const r={...t};for(const i of Object.keys(e)){const s=t[i],n=e[i];i.startsWith("on")&&typeof s=="function"&&typeof n=="function"?r[i]=(...o)=>{n(...o),s(...o)}:i==="className"&&typeof s=="string"&&typeof n=="string"?r[i]=[n,s].filter(Boolean).join(" "):i==="style"&&typeof s=="object"&&typeof n=="object"?r[i]={...n,...s}:i==="disabled"?r[i]=!!s||!!n:n!==void 0&&(r[i]=n)}return r}const K=f.forwardRef(({children:t,...e},r)=>{const i=f.Children.only(t);if(!f.isValidElement(i))return null;const s=i.props,n=wt(e,s),o=bt(i),a=gt(r,o);return f.cloneElement(i,{...n,ref:a})});K.displayName="Slot";var Et=Symbol.for("preact-signals");function re(){if(x>1)x--;else{var t,e=!1;for((function(){var s=Q;for(Q=void 0;s!==void 0;)s.S.v===s.v&&(s.S.i=s.i),s=s.o})();B!==void 0;){var r=B;for(B=void 0,Z++;r!==void 0;){var i=r.u;if(r.u=void 0,r.f&=-3,!(8&r.f)&&Me(r))try{r.c()}catch(s){e||(t=s,e=!0)}r=i}}if(Z=0,x--,e)throw t}}function q(t){if(x>0)return t();le=++kt,x++;try{return t()}finally{re()}}var p=void 0;function ie(t){var e=p;p=void 0;try{return t()}finally{p=e}}var $,B=void 0,x=0,Z=0,kt=0,le=0,Q=void 0,X=0;function Ve(t){if(p!==void 0){var e=t.n;if(e===void 0||e.t!==p)return e={i:0,S:t,p:p.s,n:void 0,t:p,e:void 0,x:void 0,r:e},p.s!==void 0&&(p.s.n=e),p.s=e,t.n=e,32&p.f&&t.S(e),e;if(e.i===-1)return e.i=0,e.n!==void 0&&(e.n.p=e.p,e.p!==void 0&&(e.p.n=e.n),e.p=p.s,e.n=void 0,p.s.n=e,p.s=e),e}}function E(t,e){this.v=t,this.i=0,this.n=void 0,this.t=void 0,this.l=0,this.W=e?.watched,this.Z=e?.unwatched,this.name=e?.name}E.prototype.brand=Et;E.prototype.h=function(){return!0};E.prototype.S=function(t){var e=this,r=this.t;r!==t&&t.e===void 0&&(t.x=r,this.t=t,r!==void 0?r.e=t:ie(function(){var i;(i=e.W)==null||i.call(e)}))};E.prototype.U=function(t){var e=this;if(this.t!==void 0){var r=t.e,i=t.x;r!==void 0&&(r.x=i,t.e=void 0),i!==void 0&&(i.e=r,t.x=void 0),t===this.t&&(this.t=i,i===void 0&&ie(function(){var s;(s=e.Z)==null||s.call(e)}))}};E.prototype.subscribe=function(t){var e=this;return b(function(){var r=e.value,i=p;p=void 0;try{t(r)}finally{p=i}},{name:"sub"})};E.prototype.valueOf=function(){return this.value};E.prototype.toString=function(){return this.value+""};E.prototype.toJSON=function(){return this.value};E.prototype.peek=function(){var t=p;p=void 0;try{return this.value}finally{p=t}};Object.defineProperty(E.prototype,"value",{get:function(){var t=Ve(this);return t!==void 0&&(t.i=this.i),this.v},set:function(t){if(t!==this.v){if(Z>100)throw new Error("Cycle detected");(function(r){x!==0&&Z===0&&r.l!==le&&(r.l=le,Q={S:r,v:r.v,i:r.i,o:Q})})(this),this.v=t,this.i++,X++,x++;try{for(var e=this.t;e!==void 0;e=e.x)e.t.N()}finally{re()}}}});function w(t,e){return new E(t,e)}function Me(t){for(var e=t.s;e!==void 0;e=e.n)if(e.S.i!==e.i||!e.S.h()||e.S.i!==e.i)return!0;return!1}function Pe(t){for(var e=t.s;e!==void 0;e=e.n){var r=e.S.n;if(r!==void 0&&(e.r=r),e.S.n=e,e.i=-1,e.n===void 0){t.s=e;break}}}function Oe(t){for(var e=t.s,r=void 0;e!==void 0;){var i=e.p;e.i===-1?(e.S.U(e),i!==void 0&&(i.n=e.n),e.n!==void 0&&(e.n.p=i)):r=e,e.S.n=e.r,e.r!==void 0&&(e.r=void 0),e=i}t.s=r}function M(t,e){E.call(this,void 0),this.x=t,this.s=void 0,this.g=X-1,this.f=4,this.W=e?.watched,this.Z=e?.unwatched,this.name=e?.name}M.prototype=new E;M.prototype.h=function(){if(this.f&=-3,1&this.f)return!1;if((36&this.f)==32||(this.f&=-5,this.g===X))return!0;if(this.g=X,this.f|=1,this.i>0&&!Me(this))return this.f&=-2,!0;var t=p;try{Pe(this),p=this;var e=this.x();(16&this.f||this.v!==e||this.i===0)&&(this.v=e,this.f&=-17,this.i++)}catch(r){this.v=r,this.f|=16,this.i++}return p=t,Oe(this),this.f&=-2,!0};M.prototype.S=function(t){if(this.t===void 0){this.f|=36;for(var e=this.s;e!==void 0;e=e.n)e.S.S(e)}E.prototype.S.call(this,t)};M.prototype.U=function(t){if(this.t!==void 0&&(E.prototype.U.call(this,t),this.t===void 0)){this.f&=-33;for(var e=this.s;e!==void 0;e=e.n)e.S.U(e)}};M.prototype.N=function(){if(!(2&this.f)){this.f|=6;for(var t=this.t;t!==void 0;t=t.x)t.t.N()}};Object.defineProperty(M.prototype,"value",{get:function(){if(1&this.f)throw new Error("Cycle detected");var t=Ve(this);if(this.h(),t!==void 0&&(t.i=this.i),16&this.f)throw this.v;return this.v}});function v(t,e){return new M(t,e)}function je(t){var e=t.m;if(t.m=void 0,typeof e=="function"){x++;var r=p;p=void 0;try{e()}catch(i){throw t.f&=-2,t.f|=8,ve(t),i}finally{p=r,re()}}}function ve(t){for(var e=t.s;e!==void 0;e=e.n)e.S.U(e);t.x=void 0,t.s=void 0,je(t)}function _t(t){if(p!==this)throw new Error("Out-of-order effect");Oe(this),p=t,this.f&=-2,8&this.f&&ve(this),re()}function O(t,e){this.x=t,this.m=void 0,this.s=void 0,this.u=void 0,this.f=32,this.name=e?.name,$&&$.push(this)}O.prototype.c=function(){var t=this.S();try{if(8&this.f||this.x===void 0)return;var e=this.x();typeof e=="function"&&(this.m=e)}finally{t()}};O.prototype.S=function(){if(1&this.f)throw new Error("Cycle detected");this.f|=1,this.f&=-9,je(this),Pe(this),x++;var t=p;return p=this,_t.bind(this,t)};O.prototype.N=function(){2&this.f||(this.f|=2,this.u=B,B=this)};O.prototype.d=function(){this.f|=8,1&this.f||ve(this)};O.prototype.dispose=function(){this.d()};function b(t,e){var r=new O(t,e);try{r.c()}catch(s){throw r.d(),s}var i=r.d.bind(r);return i[Symbol.dispose]=i,i}function pe(t){return function(){var e=arguments,r=this;return q(function(){return ie(function(){return t.apply(r,[].slice.call(e))})})}}function At(){var t=$;return $=[],function(){var e=$;return $&&t&&(t=t.concat($)),$=t,e}}var Ie=function(t){for(var e in t){var r=t[e];typeof r=="function"?t[e]=pe(r):typeof r=="object"&&r!==null&&!("brand"in r)&&Ie(r)}};function St(t){return function(){var e,r,i=At();try{r=t.apply(void 0,[].slice.call(arguments))}catch(s){throw $=void 0,s}finally{e=i()}return Ie(r),r[Symbol.dispose]=pe(function(){if(e)for(var s=0;s<e.length;s++)e[s].dispose();e=void 0}),r}}const wr=Object.freeze(Object.defineProperty({__proto__:null,Computed:M,Effect:O,Signal:E,action:pe,batch:q,computed:v,createModel:St,effect:b,signal:w,untracked:ie},Symbol.toStringTag,{value:"Module"})),I=new WeakMap;function $t(t){I.set(t,(I.get(t)??0)+1)}function xt(t){const e=I.get(t);e!==void 0&&(e<=1?I.delete(t):I.set(t,e-1))}function Y(t){return I.has(t)}const ee=t=>!(t===null||typeof t!="object"||Array.isArray(t)||t instanceof Date||typeof Blob<"u"&&t instanceof Blob||typeof File<"u"&&t instanceof File),F=(t,e)=>t===""?String(e):`${t}.${e}`,ue=t=>/^\d+$/.test(t),N=t=>{if(Array.isArray(t))return t.map(N);if(ee(t)){const e={};for(const r of Object.keys(t))e[r]=N(t[r]);return e}return t},te=(t,e)=>{if(t===e)return!0;if(Array.isArray(t)&&Array.isArray(e))return t.length!==e.length?!1:t.every((r,i)=>te(r,e[i]));if(ee(t)&&ee(e)){const r=Object.keys(t),i=Object.keys(e);return r.length!==i.length?!1:r.every(s=>te(t[s],e[s]))}return!1};let Ft=class{constructor(e,r){this.path=r;const i=w(e);i.__path=r,this.signal=i,this.initial=N(e)}kind="leaf";signal;initial;rebase(e){this.path=e,this.signal.__path=e}read(){return this.signal.value}peek(){return this.signal.peek()}set(e){this.signal.value=e}resetToInitial(){this.signal.value=N(this.initial)}captureInitial(){this.initial=N(this.signal.peek())}dirty(){return!te(this.signal.peek(),this.initial)}},De=class{constructor(e,r){this.path=r;for(const i of Object.keys(e))this.children.set(i,W(e[i],F(r,i)))}kind="group";children=new Map;rebase(e){this.path=e;for(const[r,i]of this.children)i.rebase(F(e,r))}read(){const e={};for(const[r,i]of this.children)e[r]=i.read();return e}peek(){const e={};for(const[r,i]of this.children)e[r]=i.peek();return e}set(e){if(e==null||typeof e!="object")return;const r=e;q(()=>{for(const[i,s]of this.children)i in r&&(s.kind==="leaf"&&Y(s.signal)||s.set(r[i]))})}resetToInitial(){q(()=>{for(const e of this.children.values())e.resetToInitial()})}captureInitial(){for(const e of this.children.values())e.captureInitial()}dirty(){for(const e of this.children.values())if(e.dirty())return!0;return!1}},Ct=class{constructor(e,r){this.path=r,this.items=w(e.map((i,s)=>W(i,F(r,s)))),this.initial=N(e)}kind="array";items;initial;rebase(e){this.path=e,this.items.peek().forEach((r,i)=>r.rebase(F(e,i)))}reindex(){this.items.peek().forEach((e,r)=>e.rebase(F(this.path,r)))}push(e){const r=this.items.peek();this.items.value=[...r,W(e,F(this.path,r.length))]}insertAt(e,r){const i=[...this.items.peek()];i.splice(e,0,W(r,F(this.path,e))),this.items.value=i,this.reindex()}removeAt(e){const r=[...this.items.peek()];r.splice(e,1),this.items.value=r,this.reindex()}move(e,r){const i=[...this.items.peek()],[s]=i.splice(e,1);s&&i.splice(r,0,s),this.items.value=i,this.reindex()}swap(e,r){const i=[...this.items.peek()];e<0||r<0||e>=i.length||r>=i.length||e===r||([i[e],i[r]]=[i[r],i[e]],this.items.value=i,this.reindex())}clear(){this.items.value=[]}read(){return this.items.value.map(e=>e.read())}peek(){return this.items.peek().map(e=>e.peek())}set(e){const r=Array.isArray(e)?e:[];this.items.value=r.map((i,s)=>W(i,F(this.path,s)))}resetToInitial(){this.set(N(this.initial))}captureInitial(){this.initial=N(this.peek())}dirty(){return!te(this.peek(),this.initial)}};function W(t,e){return Array.isArray(t)?new Ct(t,e):ee(t)?new De(t,e):new Ft(t,e)}const ke=new WeakMap;function Nt(t){const e=v(()=>t.read());return{get value(){return e.value},peek:()=>e.peek(),subscribe:r=>e.subscribe(r),valueOf:()=>e.value,toString:()=>String(e.value),toJSON:()=>e.value,brand:e.brand}}function Te(t){if(t.kind==="leaf")return t.signal;const e=ke.get(t);if(e)return e;const r=Nt(t),i=t.kind==="group",s=a=>i?t.children.get(a):ue(a)?t.items.value[Number(a)]:void 0,n=i?{}:{get length(){return t.items.value.length}},o=new Proxy(n,{get:(a,u,d)=>{if(u==="__path")return t.path;if(u==="__kind")return t.kind;if(typeof u!="string")return Reflect.get(r,u,r);const c=s(u);return c?Te(c):!i&&Reflect.has(a,u)?Reflect.get(a,u,d):Reflect.get(r,u,r)},has:(a,u)=>typeof u=="string"&&(s(u)!==void 0||!i&&Reflect.has(a,u)),ownKeys:()=>i?[...t.children.keys()]:Reflect.ownKeys(n),getOwnPropertyDescriptor:(a,u)=>typeof u=="string"&&s(u)?{enumerable:!0,configurable:!0}:i?void 0:Reflect.getOwnPropertyDescriptor(a,u)});return ke.set(t,o),o}function Vt(t){if(t==null||typeof t!="object")return!1;const e=t.__kind;return e==="group"||e==="array"}function Mt(t,e){if(!e)return;let r=t;for(const i of e.split(".")){if(!r)return;if(r.kind==="group")r=r.children.get(i);else if(r.kind==="array")r=r.items.peek()[Number(i)];else return}return r&&r.kind==="leaf"?r.signal:void 0}function j(t){if(t)return t.kind==="group"?We(t):t.kind==="array"?Pt(t):t.read()}function Pt(t){const e={get length(){return t.items.value.length},push:r=>t.push(r),insertAt:(r,i)=>t.insertAt(r,i),removeAt:r=>t.removeAt(r),move:(r,i)=>t.move(r,i),swap:(r,i)=>t.swap(r,i),clear:()=>t.clear(),at:r=>j(t.items.value[r]),map:r=>t.items.value.map((i,s)=>r(j(i),s)),forEach:r=>t.items.value.forEach((i,s)=>r(j(i),s)),toArray:()=>t.peek(),[Symbol.iterator]:function*(){const r=t.items.value;for(let i=0;i<r.length;i++)yield j(r[i])}};return new Proxy(e,{get:(r,i,s)=>i==="__path"?t.path:typeof i=="string"&&ue(i)?j(t.items.value[Number(i)]):Reflect.get(r,i,s),has:(r,i)=>typeof i=="string"&&ue(i)?Number(i)<t.items.value.length:Reflect.has(r,i)})}const _e=new Set(["$","get","set","patch","isDirty","reset","captureInitial","signalAt"]),Ae=new WeakMap,Re=new WeakMap;function We(t){const e=Ae.get(t);if(e)return e;const r={$:Te(t),get:()=>t.peek(),set:s=>t.set(s),patch:s=>t.set(s),isDirty:()=>t.dirty(),reset:()=>t.resetToInitial(),captureInitial:()=>t.captureInitial(),signalAt:s=>Mt(t,s)},i=new Proxy({},{get:(s,n)=>{if(n==="__path")return t.path;if(typeof n!="string")return;const o=t.children.get(n);if(o)return j(o);if(_e.has(n))return r[n]},set:(s,n,o)=>{if(typeof n!="string")return!1;const a=t.children.get(n);return a?(a.set(o),!0):!1},has:(s,n)=>typeof n=="string"&&(t.children.has(n)||_e.has(n)),ownKeys:()=>[...t.children.keys()],getOwnPropertyDescriptor:(s,n)=>typeof n=="string"&&t.children.has(n)?{enumerable:!0,configurable:!0}:void 0});return Ae.set(t,i),Re.set(i,t),i}function ce(t,e){if(t.kind==="leaf"){e(t.signal);return}if(t.kind==="group"){for(const r of t.children.values())ce(r,e);return}for(const r of t.items.value)ce(r,e)}function Be(t,e){const r=Re.get(t);r&&ce(r,e)}function Ue(t){const e=new De(t,"");return We(e)}const Ot="runOutsideEffect";function jt(t){return typeof t=="object"&&t!==null&&typeof t.then=="function"}function Ge(t,e){try{const r=t();jt(r)&&r.then(void 0,i=>void 0)}catch{}}function It(t){return(...e)=>{V(()=>t(...e))}}function V(t){let e=!1;return queueMicrotask(()=>{e||Ge(t,Ot)}),()=>{e=!0}}function Dt(t,e){return()=>{e(()=>Ge(t,"safeDebouncedCallback"))}}function Tt(t,e,r,i){return b(()=>{const s=t.map(o=>o.value);if(i?.when&&!i.when(...s))return;const n=r(...s);e.peek()!==n&&(e.value=n)})}function Rt(t,e,r){return b(()=>{const i=t.value;if(r?.when&&!r.when())return;const s=r?.transform?r.transform(i):i;e.peek()!==s&&(e.value=s)})}function Wt(t,e,r){let i=!0;return b(()=>{const s=t.value;i&&(i=!1,!r?.immediate)||e(s)})}function Bt(t,e){let r=!1;return b(()=>{const i=t.value;r||V(()=>{const s=e(i);if(t.peek()!==s){r=!0;try{t.value=s}finally{r=!1}}})})}function Ut(t,e,r){const i=r?.resetValue??null;return b(()=>{const s=e();V(()=>{s&&t.peek()!==i&&(t.value=i)})})}function Gt(t,e,r){const i=r?.transform;let s=!1;const n=b(()=>{const a=t.value;s||V(()=>{s=!0;try{const u=i?i(a):a;e.peek()!==u&&(e.value=u)}finally{s=!1}})}),o=b(()=>{const a=e.value;s||V(()=>{s=!0;try{t.peek()!==a&&(t.value=a)}finally{s=!1}})});return()=>{n(),o()}}function Lt(t,e){let r=!0;return b(()=>{if(t.forEach(i=>i.value),r){r=!1;return}V(()=>e())})}const Le=new WeakMap;function qe(t,e){Le.set(t,e)}function D(t){return Le.get(t)}let U=null;function qt(t,e){const r=U;U=t;try{return e()}finally{U=r}}function R(t){if(!U)throw new Error(`[@reformer/core/validation] "${t}" вызван вне схемы валидации — операторы валидации можно вызывать только внутри прогона validateModel(...) (напрямую или через apply/each).`);return U}function me(t,e){let r=t.errors.get(e);return r||t.errors.set(e,r=[]),r}const ye=t=>t.whenStack.every(e=>e());function Ar(t,e){const r=R("validate"),i=me(r,t);if(!ye(r))return;const s=t.peek();for(const n of e){const o=n(s,r.model,r.model);o&&i.push(o)}}function Sr(t,e){const r=R("validateAsync"),i=me(r,t);if(!ye(r))return;const s=t.peek(),n=r.signal;for(const o of e)r.pending.push(o(s,{signal:n}).then(a=>{a&&!n.aborted&&i.push(a)},()=>{}))}function $r(t,e){const r=R("validateWhen");r.whenStack.push(t);try{e()}finally{r.whenStack.pop()}}function xr(t,e){const r=R("cross"),i=me(r,t);if(!ye(r))return;const s=e(r.model.get());s&&i.push(s)}function Fr(t,e){R("each");const r=t.length;for(let i=0;i<r;i++)e(t.at(i))}function Kt(...t){const e=R("apply").model;for(const r of t)r({model:e})}function Cr(t){return t}const Se=new WeakMap;function zt(t,e){let r=Se.get(t);r||Se.set(t,r=new WeakMap);let i=r.get(e);return i||r.set(e,i={fields:new Set,ac:null}),i}const Jt=t=>{for(const e of t.values())for(const r of e)if(r.severity!=="warning")return!0;return!1};function Ht(t){return t.aborted?Promise.resolve():new Promise(e=>{t.addEventListener("abort",()=>e(),{once:!0})})}async function Ke(t,e,r){const i=zt(t,e);i.ac?.abort();const s=new AbortController;i.ac=s;const n={model:t,errors:new Map,pending:[],whenStack:[],signal:s.signal};if(qt(n,()=>e({model:t})),n.pending.length&&await Promise.race([Promise.all(n.pending),Ht(s.signal)]),s.signal.aborted)return!1;const o=new Set(n.errors.keys());for(const a of i.fields)o.has(a)||D(a)?.setErrors([]);for(const a of o)D(a)?.setErrors(n.errors.get(a)??[]);if(r?.touch)for(const a of o)D(a)?.markAsTouched();return i.fields=o,!Jt(n.errors)}function he(t,e,r={}){const{strategy:i="submit",debounce:s=0,liveAfterSubmit:n="change"}=r,o=w(!1);let a=0,u=!1,d,c;const l=async k=>{a++,o.value=!0;try{return await Ke(t,e,{touch:k})}finally{--a===0&&(o.value=!1)}},h=()=>{l(!1)},m=()=>{if(!s){h();return}c&&clearTimeout(c),c=setTimeout(h,s)},g=(k,_)=>{let S=!0;return b(()=>{if(Be(t,k),S){S=!1;return}i==="afterFirstSubmit"&&!u||_()})},y={async validate(){return u=!0,l(!0)},start(){if(d)return()=>y.dispose();const k=i==="afterFirstSubmit"?n:i;return k==="change"?d=g(_=>void _.value,m):k==="blur"&&(d=g(_=>void D(_)?.touched.value,h)),()=>y.dispose()},dispose(){c&&(clearTimeout(c),c=void 0),d?.(),d=void 0},get isValidating(){return o.value},get validating(){return o}};return y}function ze(t,e,r){return b(()=>{const i=e(),s=D(t);s&&V(()=>{i?s.enable():(s.disable(),r?.resetOnDisable&&s.reset())})})}function Zt(t,e,r){return ze(t,()=>!e(),r)}class z{_touched=w(!1);_dirty=w(!1);_status=w("valid");touched=v(()=>this._touched.value);dirty=v(()=>this._dirty.value);status=v(()=>this._status.value);disabled=v(()=>this._status.value==="disabled");getErrors(e){const r=this.errors.value;return e?r.filter(i=>{if(e.code!==void 0&&!(Array.isArray(e.code)?e.code:[e.code]).includes(i.code)||e.message!==void 0&&!i.message.toLowerCase().includes(e.message.toLowerCase()))return!1;if(e.params!==void 0){if(!i.params)return!1;for(const[s,n]of Object.entries(e.params))if(i.params[s]!==n)return!1}return!(e.predicate!==void 0&&!e.predicate(i))}):r}markAsTouched(){this._touched.value=!0,this.onMarkAsTouched()}markAsUntouched(){this._touched.value=!1,this.onMarkAsUntouched()}markAsDirty(){this._dirty.value=!0,this.onMarkAsDirty()}markAsPristine(){this._dirty.value=!1,this.onMarkAsPristine()}touchAll(){this.markAsTouched()}disable(){this._status.value="disabled",this.onDisable()}enable(){this._status.value="valid",this.onEnable()}onMarkAsTouched(){}onMarkAsUntouched(){}onMarkAsDirty(){}onMarkAsPristine(){}onDisable(){}onEnable(){}}class se{subscriptions=new Map;add(e,r){return this.subscriptions.has(e)&&this.subscriptions.get(e)?.(),this.subscriptions.set(e,r),()=>this.remove(e)}remove(e){const r=this.subscriptions.get(e);return r?(r(),this.subscriptions.delete(e),!0):!1}clear(){this.subscriptions.forEach(e=>{e()}),this.subscriptions.clear()}size(){return this.subscriptions.size}has(e){return this.subscriptions.has(e)}getKeys(){return Array.from(this.subscriptions.keys())}dispose(){this.clear()}}const G={Watch:"watch",ComputeFrom:"computeFrom",LinkFields:"linkFields",WatchField:"watchField"};let Qt=0;function L(t){return`${t}-${++Qt}`}var C=(t=>(t.THROW="throw",t.LOG="log",t.CONVERT="convert",t))(C||{});class P{static handle(e,r,i="throw"){const s=this.extractMessage(e);switch(i){case"throw":throw e;case"log":return;case"convert":return{code:"validator_error",message:s,params:{field:r}}}}static extractMessage(e){return e instanceof Error?e.message:typeof e=="string"?e:typeof e=="object"&&e!==null&&"message"in e?String(e.message):String(e)}static createValidationError(e,r,i){return{code:e,message:r,params:i?{field:i}:void 0}}static isValidationError(e){return typeof e=="object"&&e!==null&&"code"in e&&"message"in e&&typeof e.code=="string"&&typeof e.message=="string"}}class Xt{_status;status;valid;invalid;pending;disabled;constructor(e="valid"){this._status=w(e),this.status=v(()=>this._status.value),this.valid=v(()=>this._status.value==="valid"),this.invalid=v(()=>this._status.value==="invalid"),this.pending=v(()=>this._status.value==="pending"),this.disabled=v(()=>this._status.value==="disabled")}startValidation(){this._status.value!=="disabled"&&(this._status.value="pending")}completeValidation(e){this._status.value!=="disabled"&&(this._status.value=e?"invalid":"valid")}setErrors(e){this._status.value!=="disabled"&&(this._status.value=e?"invalid":"valid")}disable(){this._status.value="disabled"}enable(e=!1){this._status.value=e?"invalid":"valid"}}class Je extends z{_value;_errors;_componentProps;statusMachine;value;valid;invalid;pending;status;disabled;errors;componentProps;shouldShowError;validators;asyncValidators;updateOn;initialValue;currentAbortController;debounceMs;validateDebounceTimer;pendingValidation;disposers=new se;component;constructor(e){super(),this.validators=e.validators||[],this.asyncValidators=e.asyncValidators||[],this.updateOn=e.updateOn||"blur",this.debounceMs=e.debounce||0,this.component=e.component,this._value=e.valueSignal??w(e.value),this.initialValue=this._value.peek(),this._errors=w([]),this._componentProps=w(e.componentProps||{}),this.statusMachine=new Xt(e.disabled?"disabled":"valid"),this.value=v(()=>this._value.value),this.valid=v(()=>this.statusMachine.valid.value),this.invalid=v(()=>this.statusMachine.invalid.value),this.pending=v(()=>this.statusMachine.pending.value),this.status=v(()=>this.statusMachine.status.value),this.disabled=v(()=>this.statusMachine.disabled.value),this.errors=v(()=>this._errors.value),this.componentProps=v(()=>this._componentProps.value),this.shouldShowError=v(()=>this.statusMachine.invalid.value&&(this._touched.value||this._dirty.value))}getValue(){return this._value.peek()}setValue(e,r){if(this._value.value=e,this._dirty.value=!0,r?.emitEvent===!1)return;const i=this.validators.length>0||this.asyncValidators.length>0,s=this._errors.value.length>0;if(this.updateOn==="change"){this.validate();return}s&&i&&this.validate()}patchValue(e){this.setValue(e)}reset(e){this._value.value=e!==void 0?e:this.initialValue,this._errors.value=[],this._touched.value=!1,this._dirty.value=!1,this.statusMachine.setErrors(!1)}resetToInitial(){this.reset(this.initialValue)}cancelPendingValidation(){this.pendingValidation&&(this.pendingValidation.abortController.abort(),this.pendingValidation.resolve(!1),this.pendingValidation=void 0),this.validateDebounceTimer&&(clearTimeout(this.validateDebounceTimer),this.validateDebounceTimer=void 0),this.currentAbortController&&(this.currentAbortController.abort(),this.currentAbortController=void 0)}async validate(e){const r=e?.debounce??this.debounceMs;if(this.cancelPendingValidation(),r<=0||this.asyncValidators.length===0)return this.validateImmediate();const i=new AbortController;return new Promise(s=>{this.pendingValidation={resolve:s,abortController:i},this.validateDebounceTimer=setTimeout(async()=>{if(this.validateDebounceTimer=void 0,i.signal.aborted){s(!1);return}this.pendingValidation=void 0;const n=await this.validateImmediate(i);s(n)},r),i.signal.addEventListener("abort",()=>{this.validateDebounceTimer&&(clearTimeout(this.validateDebounceTimer),this.validateDebounceTimer=void 0),s(!1)},{once:!0})})}async validateImmediate(e){const r=e??new AbortController;e||this.currentAbortController?.abort(),this.currentAbortController=r;const{signal:i}=r,s=[];for(const n of this.validators){const o=n(this._value.value);o&&s.push(o)}if(i.aborted)return!1;if(s.length>0){this._errors.value=s;const n=s.some(o=>o.severity!=="warning");if(this.statusMachine.setErrors(n),n)return!1}if(this.asyncValidators.length>0){if(i.aborted)return!1;this.statusMachine.startValidation();try{const n=await Promise.all(this.asyncValidators.map(async a=>{if(i.aborted)throw new DOMException("Validation aborted","AbortError");try{const u=await a(this._value.value,{signal:i});if(i.aborted)throw new DOMException("Validation aborted","AbortError");return u}catch(u){if(u instanceof DOMException&&u.name==="AbortError")throw u;return P.handle(u,"FieldNode AsyncValidator",C.CONVERT)}}));if(i.aborted)return!1;const o=n.filter(a=>a!==null);if(o.length>0){this._errors.value=o;const a=o.some(u=>u.severity!=="warning");if(this.statusMachine.completeValidation(a),a)return!1}}catch(n){if(n instanceof DOMException&&n.name==="AbortError")return!1;throw n}}return i.aborted?!1:((this.validators.length>0||this.asyncValidators.length>0)&&(this._errors.value=[],this.statusMachine.completeValidation(!1)),!this._errors.value.some(n=>n.severity!=="warning"))}setErrors(e){this._errors.value=e;const r=e.some(i=>i.severity!=="warning");this.statusMachine.setErrors(r)}clearErrors(){this._errors.value=[],this.statusMachine.setErrors(!1)}onMarkAsTouched(){this.updateOn==="blur"&&this.validate()}onDisable(){this.statusMachine.disable(),this._errors.value=[]}onEnable(){this.statusMachine.enable(this._errors.value.length>0),this.validate()}updateComponentProps(e){this._componentProps.value={...this._componentProps.value,...e}}setUpdateOn(e){this.updateOn=e}getUpdateOn(){return this.updateOn}watch(e){const r=new AbortController,i=b(()=>{const n=this.value.value;e(n,r.signal)}),s=L(G.Watch);return this.disposers.add(s,()=>{r.abort(),i()})}computeFrom(e,r){const i=b(()=>{const n=e.map(a=>a.value),o=r(...n);this.setValue(o,{emitEvent:!1})}),s=L(G.ComputeFrom);return this.disposers.add(s,i)}dispose(){try{this.disposers.dispose()}finally{this.cancelPendingValidation()}}}function ge(t){const{getChildren:e,ownErrors:r,disabled:i}=t,s=v(()=>r.value.length>0?!1:e().every(l=>l.disabled.value||l.valid.value)),n=v(()=>!s.value),o=v(()=>e().some(l=>l.pending.value)),a=v(()=>e().some(l=>l.touched.value)),u=v(()=>e().some(l=>l.dirty.value)),d=v(()=>{const l=[...r.value];for(const h of e())l.push(...h.errors.value);return l}),c=v(()=>i?.value?"disabled":o.value?"pending":n.value?"invalid":"valid");return{valid:s,invalid:n,pending:o,touched:a,dirty:u,errors:d,status:c}}function $e(t){return typeof t=="object"&&t!==null&&"getProxy"in t&&typeof t.getProxy=="function"}const xe="$";function Yt(t,e){let r;const i=()=>{if(!r){const s={};e.forEach((n,o)=>{s[o]=n&&$e(n)?n.getProxy():n}),r=s}return r};return new Proxy(t,{get:(s,n)=>{if(n===xe)return i();if(n in s)return s[n];if(typeof n=="string"&&e.has(n)){const o=e.get(n);return o&&$e(o)?o.getProxy():o}},set:(s,n,o)=>typeof n=="string"&&e.has(n)?!1:(s[n]=o,!0),has:(s,n)=>n===xe||typeof n=="string"&&e.has(n)?!0:n in s,ownKeys:s=>{const n=Reflect.ownKeys(s),o=Array.from(e.keys());return[...new Set([...n,...o])]},getOwnPropertyDescriptor:(s,n)=>typeof n=="string"&&e.has(n)?{enumerable:!0,configurable:!0}:Reflect.getOwnPropertyDescriptor(s,n)})}class He{constructor(e){this.form=e}_submitting=w(!1);submitting=v(()=>this._submitting.value);async submit(e,r){const{skipValidation:i=!1,skipTouch:s=!1}=r||{};if(s||this.form.markAsTouched(),!i&&!await this.form.validate())return null;this._submitting.value=!0;try{return await e(this.form.getValue())}finally{this._submitting.value=!1}}async submitWithResult(e,r){const{skipValidation:i=!1,skipTouch:s=!1}=r||{};if(s||this.form.markAsTouched(),!i&&!await this.form.validate())return{success:!1,data:null};this._submitting.value=!0;try{return{success:!0,data:await e(this.form.getValue())}}catch(n){return{success:!1,data:null,error:n instanceof Error?n:new Error(String(n))}}finally{this._submitting.value=!1}}}function er(t){const e=[];for(const r of t.split(".")){const i=/^([^[\]]+)(?:\[(\d+)\])?$/.exec(r);if(!i)return[];e.push(i[2]!==void 0?{key:i[1],index:Number(i[2])}:{key:i[1]})}return e}let T=class Ze extends z{id=crypto.randomUUID();_fields=new Map;disposers=new se;_proxyInstance;_behaviorCleanup;nodeFactory=new Qe;formSubmitter;_disabled=w(!1);_formErrors=w([]);_fieldSignals=new WeakMap;value;valid;invalid;touched;dirty;pending;errors;status;submitting;constructor(e){super(),this.formSubmitter=new He(this);const r=e.form,i=r!=null&&typeof r=="object"&&("valueSignal"in r||"value"in r),s="form"in e&&!i?e.form:e;for(const[o,a]of Object.entries(s)){const u=this.createNode(a);this._fields.set(o,u)}this.value=v(()=>{const o={};return this._fields.forEach((a,u)=>{o[u]=a.value.value}),o});const n=ge({getChildren:()=>Array.from(this._fields.values()),ownErrors:this._formErrors,disabled:this._disabled});this.valid=n.valid,this.invalid=n.invalid,this.pending=n.pending,this.touched=n.touched,this.dirty=n.dirty,this.errors=n.errors,this.status=n.status,this.submitting=this.formSubmitter.submitting}buildProxy(){return Yt(this,this._fields)}getValue(){const e={};return this._fields.forEach((r,i)=>{e[i]=r.getValue()}),e}setValue(e,r){for(const[i,s]of Object.entries(e)){const n=this._fields.get(i);if(n){const o=this._fieldSignals.get(n)??n.value;if(Y(o))continue;n.setValue(s,r)}}}patchValue(e){q(()=>{for(const[r,i]of Object.entries(e)){const s=this._fields.get(r);if(s&&i!==void 0){const n=this._fieldSignals.get(s)??s.value;if(Y(n))continue;s.setValue(i,{emitEvent:!1})}}})}reset(e){this._formErrors.value=[],this._fields.forEach((r,i)=>{const s=e?.[i];r.reset(s)})}resetToInitial(){this._formErrors.value=[],this._fields.forEach(e=>{"resetToInitial"in e&&typeof e.resetToInitial=="function"?e.resetToInitial():e.reset()})}async validate(){return this.clearErrors(),await Promise.all(Array.from(this._fields.values()).map(e=>e.validate())),Array.from(this._fields.values()).every(e=>e.valid.value||e.disabled.value)}setErrors(e){this._formErrors.value=e}clearErrors(){this._formErrors.value=[],this._fields.forEach(e=>e.clearErrors())}getField(e){return this._fields.get(e)}get fields(){return this._fields}getProxy(){return this._proxyInstance||(this._proxyInstance=this.buildProxy()),this._proxyInstance}getAllFields(){return this._fields.values()}onMarkAsTouched(){this._fields.forEach(e=>e.markAsTouched())}onMarkAsUntouched(){this._fields.forEach(e=>e.markAsUntouched())}onMarkAsDirty(){this._fields.forEach(e=>e.markAsDirty())}onMarkAsPristine(){this._fields.forEach(e=>e.markAsPristine())}async submit(e,r){return this.formSubmitter.submit(e,r)}async submitWithResult(e,r){return this.formSubmitter.submitWithResult(e,r)}getFieldByPath(e){if(e.startsWith(".")||e.endsWith("."))return;const r=er(e);if(r.length===0)return;let i=this;for(const s of r){if(!(i instanceof Ze)||(i=i.getField(s.key),!i))return;if(s.index!==void 0)if("at"in i&&"length"in i&&typeof i.at=="function"){const n=i.at(s.index);if(!n)return;i=n}else return}return i}createNode(e){return this.nodeFactory.createNode(e)}linkFields(e,r,i){const s=this._fields.get(e),n=this._fields.get(r);if(!s||!n){const u=s?r:e;throw new Error(`GroupNode.linkFields: field "${String(u)}" not found`)}const o=b(()=>{const u=s.value.value,d=i?i(u):u;n.setValue(d,{emitEvent:!1})}),a=L(G.LinkFields);return this.disposers.add(a,o)}watchField(e,r){const i=this.getFieldByPath(e);if(!i)throw new Error(`GroupNode.watchField: field "${e}" not found`);const s=b(()=>{r(i.value.value)}),n=L(G.WatchField);return this.disposers.add(n,s)}watchFieldByPath(e,r){const i=this.getFieldByPath(e);if(!i)throw new Error(`GroupNode.watchFieldByPath: field "${e}" not found`);const s=b(()=>{r(i.value.value)}),n=L(G.WatchField);return this.disposers.add(n,s)}onDisable(){this._disabled.value=!0,this._fields.forEach(e=>e.disable())}onEnable(){this._disabled.value=!1,this._fields.forEach(e=>e.enable())}attachBehaviorCleanup(e){this._behaviorCleanup=e}registerFieldSignal(e,r){this._fieldSignals.set(e,r)}dispose(){this._behaviorCleanup?.(),this._behaviorCleanup=void 0,this.disposers.dispose(),this._fields.forEach(e=>{"dispose"in e&&typeof e.dispose=="function"&&e.dispose()})}};class de extends z{items;itemSchema;initialItems;disposers=new se;_arrayErrors=w([]);value;valid;invalid;touched;dirty;pending;errors;status;length;constructor(e,r=[]){super(),this.itemSchema=e,this.initialItems=r,this.items=w([]);for(const s of r)this.push(s);this.length=v(()=>this.items.value.length),this.value=v(()=>this.items.value.map(s=>s.value.value));const i=ge({getChildren:()=>this.items.value,ownErrors:this._arrayErrors});this.valid=i.valid,this.invalid=i.invalid,this.pending=i.pending,this.touched=i.touched,this.dirty=i.dirty,this.errors=i.errors,this.status=i.status}push(e){const r=this.createItem(e);this.items.value=[...this.items.value,r]}removeAt(e){if(e<0||e>=this.items.value.length){P.handle(new Error(`ArrayNode.removeAt: index ${e} out of bounds (length: ${this.items.value.length})`),"ArrayNode.removeAt",C.LOG);return}const r=this.items.value[e];this.items.value=this.items.value.filter((i,s)=>s!==e),r&&"dispose"in r&&typeof r.dispose=="function"&&r.dispose()}insert(e,r){if(e<0||e>this.items.value.length){P.handle(new Error(`ArrayNode.insert: index ${e} out of bounds (length: ${this.items.value.length})`),"ArrayNode.insert",C.LOG);return}const i=this.createItem(r),s=[...this.items.value];s.splice(e,0,i),this.items.value=s}move(e,r){const i=this.items.value.length;if(e<0||e>=i||r<0||r>=i){P.handle(new Error(`ArrayNode.move: index out of bounds (from=${e}, to=${r}, length=${i})`),"ArrayNode.move",C.LOG);return}if(e===r)return;const s=[...this.items.value],[n]=s.splice(e,1);s.splice(r,0,n),this.items.value=s}swap(e,r){const i=this.items.value.length;if(e<0||e>=i||r<0||r>=i){P.handle(new Error(`ArrayNode.swap: index out of bounds (a=${e}, b=${r}, length=${i})`),"ArrayNode.swap",C.LOG);return}if(e===r)return;const s=[...this.items.value];[s[e],s[r]]=[s[r],s[e]],this.items.value=s}clear(){const e=[...this.items.value];this.items.value=[],e.forEach(r=>{"dispose"in r&&typeof r.dispose=="function"&&r.dispose()})}at(e){const r=this.items.value[e];if(r)return r.getProxy()}getValue(){return this.items.value.map(e=>e.getValue())}setValue(e,r){this.clear(),e.forEach(i=>this.push(i)),r?.emitEvent!==!1&&this.validate().catch(i=>{P.handle(i,"ArrayNode.setValue",C.LOG)})}patchValue(e){e.forEach((r,i)=>{this.items.value[i]&&r!==void 0&&this.items.value[i].patchValue(r)})}reset(e){this._arrayErrors.value=[],this.clear(),e&&e.forEach(r=>this.push(r))}resetToInitial(){this._arrayErrors.value=[],this.clear(),this.initialItems.forEach(e=>this.push(e))}async validate(){return(await Promise.all(this.items.value.map(e=>e.validate()))).every(Boolean)&&this._arrayErrors.value.length===0}setErrors(e){this._arrayErrors.value=e}clearErrors(){this._arrayErrors.value=[],this.items.value.forEach(e=>e.clearErrors())}onMarkAsTouched(){this.items.value.forEach(e=>e.markAsTouched())}onMarkAsUntouched(){this.items.value.forEach(e=>e.markAsUntouched())}onMarkAsDirty(){this.items.value.forEach(e=>e.markAsDirty())}onMarkAsPristine(){this.items.value.forEach(e=>e.markAsPristine())}forEach(e){this.items.value.forEach((r,i)=>{const s=r.getProxy();e(s,i)})}map(e){return this.items.value.map((r,i)=>{const s=r.getProxy();return e(s,i)})}createItem(e){if(this.isGroupSchema(this.itemSchema)){const r=new T(this.itemSchema);return e&&r.patchValue(e),r}throw new Error("ArrayNode поддерживает только GroupNode элементы. Для массива примитивов используйте обычное поле с типом массива.")}isGroupSchema(e){return typeof e=="object"&&e!==null&&!("component"in e)&&!Array.isArray(e)}dispose(){this.disposers.dispose(),this.items.value.forEach(e=>{"dispose"in e&&typeof e.dispose=="function"&&e.dispose()})}onDisable(){this.items.value.forEach(e=>{e.disable()})}onEnable(){this.items.value.forEach(e=>{e.enable()})}}class Qe{createNode(e){if(Array.isArray(e)&&e.length>=1)return this.createArrayNodeFromArray(e);if(this.isFieldConfig(e))return new Je(e);if(this.isArrayConfig(e))return new de(e.schema,e.initialItems);if(this.isGroupConfig(e))return new T(e);throw new Error(`NodeFactory: Unknown node config. Expected FieldConfig, GroupConfig, or ArrayConfig, but got: ${JSON.stringify(e)}`)}createArrayNodeFromArray(e){const[r,...i]=e,s=[];this.isGroupConfig(r)&&s.push(this.extractValues(r));for(const n of i)this.isGroupConfig(n)?s.push(this.extractValues(n)):s.push(n);return new de(r,s)}extractValues(e){if(this.isFieldConfig(e))return e.value;if(Array.isArray(e))return e.map(r=>this.extractValues(r));if(this.isGroupConfig(e)){const r={};for(const[i,s]of Object.entries(e))r[i]=this.extractValues(s);return r}return e}isFieldConfig(e){return e==null||typeof e!="object"?!1:"valueSignal"in e?!0:"value"in e?"component"in e||"componentProps"in e||"validators"in e||"asyncValidators"in e||"updateOn"in e||"debounce"in e:!1}isArrayConfig(e){return e!=null&&typeof e=="object"&&"schema"in e&&!("value"in e)}isGroupConfig(e){return e!=null&&typeof e=="object"&&!this.isFieldConfig(e)&&!this.isArrayConfig(e)}}class Xe extends z{constructor(e,r){super(),this.control=e,this.buildItem=r,this.initial=e.toArray(),this.disposeSync=b(()=>{const s=e.length,n=[],o=[];for(let d=0;d<s;d++){const c=e.at(d);if(!c)continue;let l=this.cache.get(c);l||(l=r(c),this.cache.set(c,l)),n.push(c),o.push(l)}const a=new Set(n),u=[];for(const d of this.mountedModels){if(a.has(d))continue;const c=this.cache.get(d);this.cache.delete(d),c&&u.push(c)}this.mountedModels=n,this.itemNodes.value=o,u.forEach(d=>this.disposeItemNode(d))}),this.length=v(()=>this.itemNodes.value.length),this.value=v(()=>this.itemNodes.value.map(s=>s.value.value));const i=ge({getChildren:()=>this.itemNodes.value,ownErrors:this._arrayErrors});this.valid=i.valid,this.invalid=i.invalid,this.pending=i.pending,this.touched=i.touched,this.dirty=i.dirty,this.errors=i.errors,this.status=i.status}itemNodes=w([]);cache=new WeakMap;mountedModels=[];initial;_arrayErrors=w([]);disposeSync;get items(){return this.itemNodes}value;valid;invalid;pending;touched;dirty;errors;status;length;at(e){return this.itemNodes.value[e]}map(e){return this.itemNodes.value.map((r,i)=>e(r,i))}forEach(e){this.itemNodes.value.forEach((r,i)=>e(r,i))}push(e){this.control.push(e??{})}insert(e,r){this.control.insertAt(e,r??{})}removeAt(e){this.control.removeAt(e)}move(e,r){this.control.move(e,r)}swap(e,r){this.control.swap(e,r)}clear(){this.control.clear()}getValue(){return this.control.toArray()}setValue(e){this.control.clear(),(e??[]).forEach(r=>this.control.push(r))}patchValue(e){this.setValue(e)}reset(e){this._arrayErrors.value=[],this.setValue(e??this.initial)}resetToInitial(){this.reset(this.initial)}async validate(){return(await Promise.all(this.itemNodes.value.map(e=>e.validate()))).every(Boolean)&&this._arrayErrors.value.length===0}setErrors(e){this._arrayErrors.value=e}clearErrors(){this._arrayErrors.value=[],this.itemNodes.value.forEach(e=>e.clearErrors?.())}onMarkAsTouched(){this.itemNodes.value.forEach(e=>e.markAsTouched?.())}onMarkAsUntouched(){this.itemNodes.value.forEach(e=>e.markAsUntouched?.())}onMarkAsDirty(){this.itemNodes.value.forEach(e=>e.markAsDirty?.())}onMarkAsPristine(){this.itemNodes.value.forEach(e=>e.markAsPristine?.())}onDisable(){this.itemNodes.value.forEach(e=>e.disable?.())}onEnable(){this.itemNodes.value.forEach(e=>e.enable?.())}disposeItemNode(e){e.dispose?.()}dispose(){this.disposeSync(),this.itemNodes.value.forEach(e=>this.disposeItemNode(e)),this.mountedModels=[]}}const Ye=t=>t!==null&&typeof t=="object"&&!Array.isArray(t)&&!(t instanceof Date)&&!(typeof Blob<"u"&&t instanceof Blob)&&!(typeof File<"u"&&t instanceof File);function fe(t,e,r){if(t==null||typeof t!="object"||t instanceof E||typeof t.getProxy=="function")return;if(Array.isArray(t)){for(const n of t)fe(n,e,r);return}const i=t,s=i.array;if(s&&typeof s.__path=="string"&&typeof i.item=="function"){r.set(s.__path,i.item);return}i.value instanceof E&&e.set(i.value,{component:i.component,componentProps:i.componentProps,updateOn:i.updateOn,disabled:i.disabled,debounce:i.debounce});for(const[n,o]of Object.entries(i))n!=="value"&&fe(o,e,r)}function et(t,e,r,i){const s={};for(const[n,o]of Object.entries(e)){const a=r===""?n:`${r}.${n}`;if(Array.isArray(o))continue;if(Ye(o)){s[n]=et(t,o,a,i);continue}const u=t.signalAt(a);if(!u)throw new Error(`createForm({ model }): не найден сигнал для пути "${a}"`);const d=i.get(u)??{};s[n]={...d,valueSignal:u}}return s}function tt(t,e,r){for(const[i,s]of Object.entries(t)){const n=e===""?i:`${e}.${i}`;Array.isArray(s)||(Ye(s)?tt(s,n,r):r.push(n))}}function be(t){const{model:e,schema:r,behavior:i}=t,s=new Map,n=new Map;r!==void 0&&fe(r,s,n);const o=et(e,e.get(),"",s),a=new T(o),u=e.get();for(const[l,h]of Object.entries(u)){if(!Array.isArray(h))continue;const m=n.get(l);if(!m)continue;const g=e[l],y=_=>be({model:_,schema:m(_)}),k=new Xe(g,y);a.fields.set(l,k)}const d=a.getProxy(),c=[];tt(e.get(),"",c);for(const l of c){const h=e.signalAt(l),m=a.getFieldByPath(l);if(h&&m){qe(h,m);const g=l.lastIndexOf("."),y=g===-1?a:a.getFieldByPath(l.slice(0,g));y instanceof T&&y.registerFieldSignal(m,h)}}return i&&a.attachBehaviorCleanup(i.__run(e,d)),d}const tr=t=>t!=null&&typeof t=="object"&&"model"in t&&typeof t.model?.signalAt=="function";function rt(t){return tr(t)?be(t):new T(t).getProxy()}const rr=()=>{};function it(t,e){if(!e)return;const r=typeof e=="function"?{schema:e}:e,i=Object.keys(r.steps??{}),s=i.map(l=>r.steps?.[l]).filter(l=>l!=null),n=r.schema??(()=>Kt(...s,...r.extras?[r.extras]:[])),o=l=>{const h=typeof l=="number"?i[l-1]:l;return(h!=null?r.steps?.[h]:null)??null},{strategy:a,debounce:u,liveAfterSubmit:d}=r,c=he(t,n,{strategy:a,debounce:u,liveAfterSubmit:d});return{schema:n,stepSelectors:i,validate:()=>c.validate(),validateAll:()=>c.validate(),validateStep:l=>Ke(t,o(l)??rr,{touch:!0}),createStepController:l=>{if(!a||a==="submit")return null;const h=o(l);return h?he(t,h,{strategy:a,debounce:u,liveAfterSubmit:d}):null},controller:c,validating:c.validating}}function ir(t){if(!t.model&&t.initial===void 0)throw new Error("createCoreForm: provide either `initial` (to create a model) or `model`.");const e=t.model??Ue(t.initial);t.seed?.(e);const r=rt({model:e,...t.schema?{schema:t.schema(e)}:{},...t.behavior?{behavior:t.behavior}:{}}),i=it(e,t.validation),s={model:e,form:r,...i?{validation:i}:{}};return t.setup?.(s),s}function J(t){return t==null?!1:typeof t=="object"&&"value"in t&&"setValue"in t&&"getValue"in t&&"validate"in t}function st(t){return J(t)&&"validators"in t&&"asyncValidators"in t&&typeof t.markAsTouched=="function"&&!("fields"in t)&&!("items"in t)}function nt(t){return J(t)&&"getFieldByPath"in t&&"fields"in t&&!("items"in t)&&!("push"in t)&&!("removeAt"in t)}function ot(t){return J(t)&&"items"in t&&"length"in t&&"push"in t&&"removeAt"in t&&"at"in t&&typeof t.push=="function"&&typeof t.removeAt=="function"}function sr(t){return st(t)?"FieldNode":nt(t)?"GroupNode":ot(t)?"ArrayNode":J(t)?"FormNode":"Unknown"}var Fe={exports:{}},ae={},Ce;function nr(){if(Ce)return ae;Ce=1;var t=mt;function e(l,h){return l===h&&(l!==0||1/l===1/h)||l!==l&&h!==h}var r=typeof Object.is=="function"?Object.is:e,i=t.useState,s=t.useEffect,n=t.useLayoutEffect,o=t.useDebugValue;function a(l,h){var m=h(),g=i({inst:{value:m,getSnapshot:h}}),y=g[0].inst,k=g[1];return n(function(){y.value=m,y.getSnapshot=h,u(y)&&k({inst:y})},[l,m,h]),s(function(){return u(y)&&k({inst:y}),l(function(){u(y)&&k({inst:y})})},[l]),o(m),m}function u(l){var h=l.getSnapshot;l=l.value;try{var m=h();return!r(l,m)}catch{return!0}}function d(l,h){return h()}var c=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?d:a;return ae.useSyncExternalStore=t.useSyncExternalStore!==void 0?t.useSyncExternalStore:c,ae}var Ne;function or(){return Ne||(Ne=1,Fe.exports=nr()),Fe.exports}var ne=or();function ar(t,e){if(t===e)return!0;if(t.length!==e.length)return!1;for(let r=0;r<t.length;r++)if(t[r]!==e[r])return!1;return!0}function we(t,e,r,i){const s=f.useRef(null),n=f.useRef(t);n.current=t;const o=f.useRef(e);o.current=e;const a=f.useRef(r);if(a.current=r,s.current===null){const c={};for(const l in t)c[l]=t[l].value;s.current={...c,__snapshot:null}}const u=f.useCallback(c=>{let l=!0;return b(()=>{const h=n.current;for(const m in h)h[m].value;if(l){l=!1;return}c()})},[i]),d=f.useCallback(()=>{const c=s.current,l=n.current,h={};for(const g in l)h[g]=l[g].value;let m=!1;for(const g of o.current){const{key:y,useShallowArrayEqual:k}=g,_=h[y],S=c[y];if(k){if(!ar(S,_)){m=!0;break}}else if(S!==_){m=!0;break}}if(!m&&c.__snapshot)return c.__snapshot;for(const g in l)c[g]=h[g];return c.__snapshot=a.current(h),c.__snapshot},[i]);return ne.useSyncExternalStore(u,d,d)}function lr(t){const e={value:t.value,disabled:t.disabled,errors:t.errors,pending:t.pending,valid:t.valid,invalid:t.invalid,touched:t.touched,dirty:t.dirty,shouldShowError:t.shouldShowError,componentProps:t.componentProps},r=[{key:"value"},{key:"disabled"},{key:"errors",useShallowArrayEqual:!0},{key:"pending"},{key:"valid"},{key:"invalid"},{key:"touched"},{key:"dirty"},{key:"shouldShowError"},{key:"componentProps"}],i=f.useCallback(s=>({value:s.value,pending:s.pending,disabled:s.disabled,errors:s.errors,valid:s.valid,invalid:s.invalid,touched:s.touched,dirty:s.dirty,shouldShowError:s.shouldShowError,componentProps:s.componentProps}),[]);return we(e,r,i,t)}function ur(t){const e={value:t.value,length:t.length,errors:t.errors,pending:t.pending,valid:t.valid,invalid:t.invalid,touched:t.touched,dirty:t.dirty,disabled:t.disabled},r=[{key:"value"},{key:"length"},{key:"errors",useShallowArrayEqual:!0},{key:"pending"},{key:"valid"},{key:"invalid"},{key:"touched"},{key:"dirty"},{key:"disabled"}],i=f.useCallback(s=>({value:s.value,length:s.length,pending:s.pending,errors:s.errors,valid:s.valid,invalid:s.invalid,touched:s.touched,dirty:s.dirty,disabled:s.disabled}),[]);return we(e,r,i,t)}function cr(){const t=f.useCallback(()=>({value:[],length:0,pending:!1,errors:[],valid:!0,invalid:!1,touched:!1,dirty:!1,disabled:!1}),[]);return we({},[],t)}function at(t){const e=t&&"length"in t&&"map"in t;return t?e?ur(t):lr(t):cr()}function hr(t){const e=f.useRef({value:t.value.value}),r=f.useCallback(s=>{let n=!0;return b(()=>{if(t.value.value,n){n=!1;return}s()})},[t]),i=f.useCallback(()=>{const s=t.value.value;return e.current.value===s?e.current.value:(e.current.value=s,s)},[t]);return ne.useSyncExternalStore(r,i,i)}function dr(t){const e=f.useRef({length:t.length.value}),r=f.useCallback(s=>{let n=!0;return b(()=>{if(t.length.value,n){n=!1;return}s()})},[t]),i=f.useCallback(()=>{const s=t.length.value;return e.current.length===s?e.current.length:(e.current.length=s,s)},[t]);return ne.useSyncExternalStore(r,i,i)}function fr(t){const{model:e,schema:r,strategy:i,debounce:s,liveAfterSubmit:n}=t,o=f.useMemo(()=>he(e,r,{strategy:i,debounce:s,liveAfterSubmit:n}),[e,r,i,s,n]);f.useEffect(()=>o.start(),[o]);const a=ne.useSyncExternalStore(f.useCallback(d=>o.validating.subscribe(d),[o]),()=>o.validating.peek(),()=>!1),u=f.useCallback(()=>o.validate(),[o]);return{submit:u,validate:u,isValidating:a}}function vr(t){const[e]=f.useState(t),r=e.validation?.controller;return f.useEffect(()=>r?.start(),[r]),e}const pr=Object.freeze({runtime:"reformer-core",v:1}),Nr=Object.freeze(Object.defineProperty({__proto__:null,ArrayNode:de,CORE_RUNTIME_TOKEN:pr,ErrorStrategy:C,FieldNode:Je,FormErrorHandler:P,FormNode:z,FormSubmitter:He,GroupNode:T,ModelArrayNode:Xe,NodeFactory:Qe,SubscriptionManager:se,buildValidation:it,computeFrom:Tt,copyFrom:Rt,createCoreForm:ir,createForm:rt,createFormFromModel:be,createModel:Ue,disableWhen:Zt,eachLeafSignal:Be,enableWhen:ze,getNodeForSignal:D,getNodeType:sr,isArrayNode:ot,isDerived:Y,isFieldNode:st,isFormNode:J,isGroupNode:nt,isModelContainerSignal:Vt,markDerived:$t,registerSignalNode:qe,resetWhen:Ut,revalidateWhen:Lt,runOutsideEffect:V,safeCallback:It,safeDebouncedCallback:Dt,syncFields:Gt,transformValue:Bt,unmarkDerived:xt,useArrayLength:dr,useFormBundle:vr,useFormControl:at,useFormControlValue:hr,useFormValidation:fr,watchField:Wt},Symbol.toStringTag,{value:"Module"})),mr=t=>t.message||t.code,yr=f.createContext(mr);function lt(){return f.useContext(yr)}const ut=f.createContext(null);function oe(){const t=f.useContext(ut);if(!t)throw new Error("FormField.* components must be used within <FormField.Root>. Wrap your field with <FormField.Root control={control}>.");return t}function Ee({control:t,children:e,id:r,hasDescription:i=!1}){const s=f.useId(),n=r??s,o=f.useMemo(()=>({controlId:`control-${n}`,labelId:`label-${n}`,descriptionId:`desc-${n}`,errorId:`error-${n}`}),[n]),a=at(t),u=lt(),d=f.useMemo(()=>{const{value:c,errors:l,pending:h,disabled:m,valid:g,invalid:y,touched:k,shouldShowError:_,componentProps:S}=a;return{value:c,errors:l,pending:h,disabled:m,valid:g,invalid:y,touched:k,shouldShowError:_,error:_&&l[0]?u(l[0]):void 0,label:S.label,required:!!S.required,componentProps:S,control:t,ids:o,hasDescription:i}},[a,t,o,i,u]);return A.jsx(ut.Provider,{value:d,children:e})}Ee.displayName="FormField.Root";const ct=f.forwardRef(({asChild:t=!1,children:e,forceRender:r=!1,...i},s)=>{const{label:n,required:o,ids:a}=oe(),u=e??n;return!u&&!r?null:A.jsxs(t?K:"label",{ref:s,id:a.labelId,htmlFor:t?void 0:a.controlId,...i,children:[u,o&&A.jsx("span",{"aria-hidden":"true",children:" *"})]})});ct.displayName="FormField.Label";const ht=f.forwardRef(({asChild:t=!1,children:e,...r},i)=>{const{control:s,value:n,disabled:o,shouldShowError:a,errors:u,required:d,ids:c,hasDescription:l,componentProps:h}=oe(),m=[l?c.descriptionId:null,a&&u.length>0?c.errorId:null].filter(Boolean).join(" ")||void 0,g={id:c.controlId,"aria-labelledby":c.labelId,"aria-invalid":a?!0:void 0,"aria-describedby":m,"aria-errormessage":a&&u.length>0?c.errorId:void 0,"aria-required":d?!0:void 0};if(e||t)return A.jsx(K,{ref:i,...g,...r,value:n,disabled:o,onChange:S=>s.setValue(S),onBlur:()=>s.markAsTouched(),children:e});const y=s.component,{testId:k,..._}=h??{};return A.jsx(y,{ref:i,..._,...g,...r,value:n,disabled:o,onChange:S=>s.setValue(S),onBlur:()=>s.markAsTouched()})});ht.displayName="FormField.Control";const dt=f.forwardRef(({asChild:t=!1,multi:e=!1,render:r,children:i,...s},n)=>{const{shouldShowError:o,errors:a,ids:u}=oe(),d=lt();if(!o||a.length===0)return null;const c=t?K:"p";return r?A.jsx(A.Fragment,{children:a.map((l,h)=>A.jsx(c,{ref:h===0?n:void 0,id:h===0?u.errorId:void 0,role:"alert",...s,children:r(l,h)},l.code??h))}):e?A.jsx(A.Fragment,{children:a.map((l,h)=>{const m=d(l);return A.jsx(c,{ref:h===0?n:void 0,id:h===0?u.errorId:void 0,role:"alert",...s,children:t?A.jsx("span",{children:m}):m},l.code??h)})}):A.jsx(c,{ref:n,id:u.errorId,role:"alert",...s,children:i??d(a[0])})});dt.displayName="FormField.Error";const ft=f.forwardRef(({asChild:t=!1,children:e,...r},i)=>{const{ids:s}=oe();return A.jsx(t?K:"p",{ref:i,id:s.descriptionId,...r,children:e})});ft.displayName="FormField.Description";const H=Ee;H.Root=Ee;H.Label=ct;H.Control=ht;H.Error=dt;H.Description=ft;export{Fr as $,Be as A,vr as B,Ke as C,Ar as D,Rt as E,Gt as F,he as G,at as H,H as I,oe as J,br as K,yt as L,K as M,Sr as N,lt as O,$r as R,xt as S,Ue as _,w as a,it as b,v as c,Kt as d,xr as e,$t as f,D as g,V as h,ze as i,b as j,Ut as k,E as l,Bt as m,q as n,ie as o,Vt as p,Tt as q,Y as r,It as s,Dt as t,Nr as u,wr as v,Wt as w,Lt as x,rt as y,Cr as z};
@@ -1 +0,0 @@
1
- const e={comments:{lineComment:"'",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"],["<",">"],["addhandler","end addhandler"],["class","end class"],["enum","end enum"],["event","end event"],["function","end function"],["get","end get"],["if","end if"],["interface","end interface"],["module","end module"],["namespace","end namespace"],["operator","end operator"],["property","end property"],["raiseevent","end raiseevent"],["removehandler","end removehandler"],["select","end select"],["set","end set"],["structure","end structure"],["sub","end sub"],["synclock","end synclock"],["try","end try"],["while","end while"],["with","end with"],["using","end using"],["do","loop"],["for","next"]],autoClosingPairs:[{open:"{",close:"}",notIn:["string","comment"]},{open:"[",close:"]",notIn:["string","comment"]},{open:"(",close:")",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string","comment"]},{open:"<",close:">",notIn:["string","comment"]}],folding:{markers:{start:new RegExp("^\\s*#Region\\b"),end:new RegExp("^\\s*#End Region\\b")}}},n={defaultToken:"",tokenPostfix:".vb",ignoreCase:!0,brackets:[{token:"delimiter.bracket",open:"{",close:"}"},{token:"delimiter.array",open:"[",close:"]"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"delimiter.angle",open:"<",close:">"},{token:"keyword.tag-addhandler",open:"addhandler",close:"end addhandler"},{token:"keyword.tag-class",open:"class",close:"end class"},{token:"keyword.tag-enum",open:"enum",close:"end enum"},{token:"keyword.tag-event",open:"event",close:"end event"},{token:"keyword.tag-function",open:"function",close:"end function"},{token:"keyword.tag-get",open:"get",close:"end get"},{token:"keyword.tag-if",open:"if",close:"end if"},{token:"keyword.tag-interface",open:"interface",close:"end interface"},{token:"keyword.tag-module",open:"module",close:"end module"},{token:"keyword.tag-namespace",open:"namespace",close:"end namespace"},{token:"keyword.tag-operator",open:"operator",close:"end operator"},{token:"keyword.tag-property",open:"property",close:"end property"},{token:"keyword.tag-raiseevent",open:"raiseevent",close:"end raiseevent"},{token:"keyword.tag-removehandler",open:"removehandler",close:"end removehandler"},{token:"keyword.tag-select",open:"select",close:"end select"},{token:"keyword.tag-set",open:"set",close:"end set"},{token:"keyword.tag-structure",open:"structure",close:"end structure"},{token:"keyword.tag-sub",open:"sub",close:"end sub"},{token:"keyword.tag-synclock",open:"synclock",close:"end synclock"},{token:"keyword.tag-try",open:"try",close:"end try"},{token:"keyword.tag-while",open:"while",close:"end while"},{token:"keyword.tag-with",open:"with",close:"end with"},{token:"keyword.tag-using",open:"using",close:"end using"},{token:"keyword.tag-do",open:"do",close:"loop"},{token:"keyword.tag-for",open:"for",close:"next"}],keywords:["AddHandler","AddressOf","Alias","And","AndAlso","As","Async","Boolean","ByRef","Byte","ByVal","Call","Case","Catch","CBool","CByte","CChar","CDate","CDbl","CDec","Char","CInt","Class","CLng","CObj","Const","Continue","CSByte","CShort","CSng","CStr","CType","CUInt","CULng","CUShort","Date","Decimal","Declare","Default","Delegate","Dim","DirectCast","Do","Double","Each","Else","ElseIf","End","EndIf","Enum","Erase","Error","Event","Exit","False","Finally","For","Friend","Function","Get","GetType","GetXMLNamespace","Global","GoSub","GoTo","Handles","If","Implements","Imports","In","Inherits","Integer","Interface","Is","IsNot","Let","Lib","Like","Long","Loop","Me","Mod","Module","MustInherit","MustOverride","MyBase","MyClass","NameOf","Namespace","Narrowing","New","Next","Not","Nothing","NotInheritable","NotOverridable","Object","Of","On","Operator","Option","Optional","Or","OrElse","Out","Overloads","Overridable","Overrides","ParamArray","Partial","Private","Property","Protected","Public","RaiseEvent","ReadOnly","ReDim","RemoveHandler","Resume","Return","SByte","Select","Set","Shadows","Shared","Short","Single","Static","Step","Stop","String","Structure","Sub","SyncLock","Then","Throw","To","True","Try","TryCast","TypeOf","UInteger","ULong","UShort","Using","Variant","Wend","When","While","Widening","With","WithEvents","WriteOnly","Xor"],tagwords:["If","Sub","Select","Try","Class","Enum","Function","Get","Interface","Module","Namespace","Operator","Set","Structure","Using","While","With","Do","Loop","For","Next","Property","Continue","AddHandler","RemoveHandler","Event","RaiseEvent","SyncLock"],symbols:/[=><!~?;\.,:&|+\-*\/\^%]+/,integersuffix:/U?[DI%L&S@]?/,floatsuffix:/[R#F!]?/,tokenizer:{root:[{include:"@whitespace"},[/next(?!\w)/,{token:"keyword.tag-for"}],[/loop(?!\w)/,{token:"keyword.tag-do"}],[/end\s+(?!for|do)(addhandler|class|enum|event|function|get|if|interface|module|namespace|operator|property|raiseevent|removehandler|select|set|structure|sub|synclock|try|while|with|using)/,{token:"keyword.tag-$1"}],[/[a-zA-Z_]\w*/,{cases:{"@tagwords":{token:"keyword.tag-$0"},"@keywords":{token:"keyword.$0"},"@default":"identifier"}}],[/^\s*#\w+/,"keyword"],[/\d*\d+e([\-+]?\d+)?(@floatsuffix)/,"number.float"],[/\d*\.\d+(e[\-+]?\d+)?(@floatsuffix)/,"number.float"],[/&H[0-9a-f]+(@integersuffix)/,"number.hex"],[/&0[0-7]+(@integersuffix)/,"number.octal"],[/\d+(@integersuffix)/,"number"],[/#.*#/,"number"],[/[{}()\[\]]/,"@brackets"],[/@symbols/,"delimiter"],[/["\u201c\u201d]/,{token:"string.quote",next:"@string"}]],whitespace:[[/[ \t\r\n]+/,""],[/(\'|REM(?!\w)).*$/,"comment"]],string:[[/[^"\u201c\u201d]+/,"string"],[/["\u201c\u201d]{2}/,"string.escape"],[/["\u201c\u201d]C?/,{token:"string.quote",next:"@pop"}]]}};export{e as conf,n as language};
@@ -1,298 +0,0 @@
1
- const g={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"[",close:"]"},{open:"{",close:"}"},{open:"(",close:")"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"}]};function e(i){let o=[];const a=i.split(/\t+|\r+|\n+| +/);for(let r=0;r<a.length;++r)a[r].length>0&&o.push(a[r]);return o}const s=e("true false"),c=e(`
2
- alias
3
- break
4
- case
5
- const
6
- const_assert
7
- continue
8
- continuing
9
- default
10
- diagnostic
11
- discard
12
- else
13
- enable
14
- fn
15
- for
16
- if
17
- let
18
- loop
19
- override
20
- requires
21
- return
22
- struct
23
- switch
24
- var
25
- while
26
- `),m=e(`
27
- NULL
28
- Self
29
- abstract
30
- active
31
- alignas
32
- alignof
33
- as
34
- asm
35
- asm_fragment
36
- async
37
- attribute
38
- auto
39
- await
40
- become
41
- binding_array
42
- cast
43
- catch
44
- class
45
- co_await
46
- co_return
47
- co_yield
48
- coherent
49
- column_major
50
- common
51
- compile
52
- compile_fragment
53
- concept
54
- const_cast
55
- consteval
56
- constexpr
57
- constinit
58
- crate
59
- debugger
60
- decltype
61
- delete
62
- demote
63
- demote_to_helper
64
- do
65
- dynamic_cast
66
- enum
67
- explicit
68
- export
69
- extends
70
- extern
71
- external
72
- fallthrough
73
- filter
74
- final
75
- finally
76
- friend
77
- from
78
- fxgroup
79
- get
80
- goto
81
- groupshared
82
- highp
83
- impl
84
- implements
85
- import
86
- inline
87
- instanceof
88
- interface
89
- layout
90
- lowp
91
- macro
92
- macro_rules
93
- match
94
- mediump
95
- meta
96
- mod
97
- module
98
- move
99
- mut
100
- mutable
101
- namespace
102
- new
103
- nil
104
- noexcept
105
- noinline
106
- nointerpolation
107
- noperspective
108
- null
109
- nullptr
110
- of
111
- operator
112
- package
113
- packoffset
114
- partition
115
- pass
116
- patch
117
- pixelfragment
118
- precise
119
- precision
120
- premerge
121
- priv
122
- protected
123
- pub
124
- public
125
- readonly
126
- ref
127
- regardless
128
- register
129
- reinterpret_cast
130
- require
131
- resource
132
- restrict
133
- self
134
- set
135
- shared
136
- sizeof
137
- smooth
138
- snorm
139
- static
140
- static_assert
141
- static_cast
142
- std
143
- subroutine
144
- super
145
- target
146
- template
147
- this
148
- thread_local
149
- throw
150
- trait
151
- try
152
- type
153
- typedef
154
- typeid
155
- typename
156
- typeof
157
- union
158
- unless
159
- unorm
160
- unsafe
161
- unsized
162
- use
163
- using
164
- varying
165
- virtual
166
- volatile
167
- wgsl
168
- where
169
- with
170
- writeonly
171
- yield
172
- `),l=e(`
173
- read write read_write
174
- function private workgroup uniform storage
175
- perspective linear flat
176
- center centroid sample
177
- vertex_index instance_index position front_facing frag_depth
178
- local_invocation_id local_invocation_index
179
- global_invocation_id workgroup_id num_workgroups
180
- sample_index sample_mask
181
- rgba8unorm
182
- rgba8snorm
183
- rgba8uint
184
- rgba8sint
185
- rgba16uint
186
- rgba16sint
187
- rgba16float
188
- r32uint
189
- r32sint
190
- r32float
191
- rg32uint
192
- rg32sint
193
- rg32float
194
- rgba32uint
195
- rgba32sint
196
- rgba32float
197
- bgra8unorm
198
- `),u=e(`
199
- bool
200
- f16
201
- f32
202
- i32
203
- sampler sampler_comparison
204
- texture_depth_2d
205
- texture_depth_2d_array
206
- texture_depth_cube
207
- texture_depth_cube_array
208
- texture_depth_multisampled_2d
209
- texture_external
210
- texture_external
211
- u32
212
- `),p=e(`
213
- array
214
- atomic
215
- mat2x2
216
- mat2x3
217
- mat2x4
218
- mat3x2
219
- mat3x3
220
- mat3x4
221
- mat4x2
222
- mat4x3
223
- mat4x4
224
- ptr
225
- texture_1d
226
- texture_2d
227
- texture_2d_array
228
- texture_3d
229
- texture_cube
230
- texture_cube_array
231
- texture_multisampled_2d
232
- texture_storage_1d
233
- texture_storage_2d
234
- texture_storage_2d_array
235
- texture_storage_3d
236
- vec2
237
- vec3
238
- vec4
239
- `),d=e(`
240
- vec2i vec3i vec4i
241
- vec2u vec3u vec4u
242
- vec2f vec3f vec4f
243
- vec2h vec3h vec4h
244
- mat2x2f mat2x3f mat2x4f
245
- mat3x2f mat3x3f mat3x4f
246
- mat4x2f mat4x3f mat4x4f
247
- mat2x2h mat2x3h mat2x4h
248
- mat3x2h mat3x3h mat3x4h
249
- mat4x2h mat4x3h mat4x4h
250
- `),x=e(`
251
- bitcast all any select arrayLength abs acos acosh asin asinh atan atanh atan2
252
- ceil clamp cos cosh countLeadingZeros countOneBits countTrailingZeros cross
253
- degrees determinant distance dot exp exp2 extractBits faceForward firstLeadingBit
254
- firstTrailingBit floor fma fract frexp inverseBits inverseSqrt ldexp length
255
- log log2 max min mix modf normalize pow quantizeToF16 radians reflect refract
256
- reverseBits round saturate sign sin sinh smoothstep sqrt step tan tanh transpose
257
- trunc dpdx dpdxCoarse dpdxFine dpdy dpdyCoarse dpdyFine fwidth fwidthCoarse fwidthFine
258
- textureDimensions textureGather textureGatherCompare textureLoad textureNumLayers
259
- textureNumLevels textureNumSamples textureSample textureSampleBias textureSampleCompare
260
- textureSampleCompareLevel textureSampleGrad textureSampleLevel textureSampleBaseClampToEdge
261
- textureStore atomicLoad atomicStore atomicAdd atomicSub atomicMax atomicMin
262
- atomicAnd atomicOr atomicXor atomicExchange atomicCompareExchangeWeak pack4x8snorm
263
- pack4x8unorm pack2x16snorm pack2x16unorm pack2x16float unpack4x8snorm unpack4x8unorm
264
- unpack2x16snorm unpack2x16unorm unpack2x16float storageBarrier workgroupBarrier
265
- workgroupUniformLoad
266
- `),f=e(`
267
- &
268
- &&
269
- ->
270
- /
271
- =
272
- ==
273
- !=
274
- >
275
- >=
276
- <
277
- <=
278
- %
279
- -
280
- --
281
- +
282
- ++
283
- |
284
- ||
285
- *
286
- <<
287
- >>
288
- +=
289
- -=
290
- *=
291
- /=
292
- %=
293
- &=
294
- |=
295
- ^=
296
- >>=
297
- <<=
298
- `),_=/enable|requires|diagnostic/,n=new RegExp("[_\\p{XID_Start}]\\p{XID_Continue}*","u"),t="variable.predefined",h={tokenPostfix:".wgsl",defaultToken:"invalid",unicode:!0,atoms:s,keywords:c,reserved:m,predeclared_enums:l,predeclared_types:u,predeclared_type_generators:p,predeclared_type_aliases:d,predeclared_intrinsics:x,operators:f,symbols:/[!%&*+\-\.\/:;<=>^|_~,]+/,tokenizer:{root:[[_,"keyword","@directive"],[n,{cases:{"@atoms":t,"@keywords":"keyword","@reserved":"invalid","@predeclared_enums":t,"@predeclared_types":t,"@predeclared_type_generators":t,"@predeclared_type_aliases":t,"@predeclared_intrinsics":t,"@default":"identifier"}}],{include:"@commentOrSpace"},{include:"@numbers"},[/[{}()\[\]]/,"@brackets"],["@","annotation","@attribute"],[/@symbols/,{cases:{"@operators":"operator","@default":"delimiter"}}],[/./,"invalid"]],commentOrSpace:[[/\s+/,"white"],[/\/\*/,"comment","@blockComment"],[/\/\/.*$/,"comment"]],blockComment:[[/[^\/*]+/,"comment"],[/\/\*/,"comment","@push"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],attribute:[{include:"@commentOrSpace"},[/\w+/,"annotation","@pop"]],directive:[{include:"@commentOrSpace"},[/[()]/,"@brackets"],[/,/,"delimiter"],[n,"meta.content"],[/;/,"delimiter","@pop"]],numbers:[[/0[fh]/,"number.float"],[/[1-9][0-9]*[fh]/,"number.float"],[/[0-9]*\.[0-9]+([eE][+-]?[0-9]+)?[fh]?/,"number.float"],[/[0-9]+\.[0-9]*([eE][+-]?[0-9]+)?[fh]?/,"number.float"],[/[0-9]+[eE][+-]?[0-9]+[fh]?/,"number.float"],[/0[xX][0-9a-fA-F]*\.[0-9a-fA-F]+(?:[pP][+-]?[0-9]+[fh]?)?/,"number.hex"],[/0[xX][0-9a-fA-F]+\.[0-9a-fA-F]*(?:[pP][+-]?[0-9]+[fh]?)?/,"number.hex"],[/0[xX][0-9a-fA-F]+[pP][+-]?[0-9]+[fh]?/,"number.hex"],[/0[xX][0-9a-fA-F]+[iu]?/,"number.hex"],[/[1-9][0-9]*[iu]?/,"number"],[/0[iu]?/,"number"]]}};export{g as conf,h as language};
@@ -1 +0,0 @@
1
- import{l as e}from"./editor.api-CMCnIB-P.js";import"./index-BivFj4xA.js";const o={comments:{blockComment:["<!--","-->"]},brackets:[["<",">"]],autoClosingPairs:[{open:"<",close:">"},{open:"'",close:"'"},{open:'"',close:'"'}],surroundingPairs:[{open:"<",close:">"},{open:"'",close:"'"},{open:'"',close:'"'}],onEnterRules:[{beforeText:new RegExp("<([_:\\w][_:\\w-.\\d]*)([^/>]*(?!/)>)[^<]*$","i"),afterText:/^<\/([_:\w][_:\w-.\d]*)\s*>$/i,action:{indentAction:e.IndentAction.IndentOutdent}},{beforeText:new RegExp("<(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$","i"),action:{indentAction:e.IndentAction.Indent}}]},i={defaultToken:"",tokenPostfix:".xml",ignoreCase:!0,qualifiedName:/(?:[\w\.\-]+:)?[\w\.\-]+/,tokenizer:{root:[[/[^<&]+/,""],{include:"@whitespace"},[/(<)(@qualifiedName)/,[{token:"delimiter"},{token:"tag",next:"@tag"}]],[/(<\/)(@qualifiedName)(\s*)(>)/,[{token:"delimiter"},{token:"tag"},"",{token:"delimiter"}]],[/(<\?)(@qualifiedName)/,[{token:"delimiter"},{token:"metatag",next:"@tag"}]],[/(<\!)(@qualifiedName)/,[{token:"delimiter"},{token:"metatag",next:"@tag"}]],[/<\!\[CDATA\[/,{token:"delimiter.cdata",next:"@cdata"}],[/&\w+;/,"string.escape"]],cdata:[[/[^\]]+/,""],[/\]\]>/,{token:"delimiter.cdata",next:"@pop"}],[/\]/,""]],tag:[[/[ \t\r\n]+/,""],[/(@qualifiedName)(\s*=\s*)("[^"]*"|'[^']*')/,["attribute.name","","attribute.value"]],[/(@qualifiedName)(\s*=\s*)("[^">?\/]*|'[^'>?\/]*)(?=[\?\/]\>)/,["attribute.name","","attribute.value"]],[/(@qualifiedName)(\s*=\s*)("[^">]*|'[^'>]*)/,["attribute.name","","attribute.value"]],[/@qualifiedName/,"attribute.name"],[/\?>/,{token:"delimiter",next:"@pop"}],[/(\/)(>)/,[{token:"tag"},{token:"delimiter",next:"@pop"}]],[/>/,{token:"delimiter",next:"@pop"}]],whitespace:[[/[ \t\r\n]+/,""],[/<!--/,{token:"comment",next:"@comment"}]],comment:[[/[^<\-]+/,"comment.content"],[/-->/,{token:"comment",next:"@pop"}],[/<!--/,"comment.content.invalid"],[/[<\-]/,"comment.content"]]}};export{o as conf,i as language};
@@ -1 +0,0 @@
1
- import{l as e}from"./editor.api-CMCnIB-P.js";import"./index-BivFj4xA.js";const o={comments:{lineComment:"#"},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{offSide:!0},onEnterRules:[{beforeText:/:\s*$/,action:{indentAction:e.IndentAction.Indent}}]},r={tokenPostfix:".yaml",brackets:[{token:"delimiter.bracket",open:"{",close:"}"},{token:"delimiter.square",open:"[",close:"]"}],keywords:["true","True","TRUE","false","False","FALSE","null","Null","Null","~"],numberInteger:/(?:0|[+-]?[0-9]+)/,numberFloat:/(?:0|[+-]?[0-9]+)(?:\.[0-9]+)?(?:e[-+][1-9][0-9]*)?/,numberOctal:/0o[0-7]+/,numberHex:/0x[0-9a-fA-F]+/,numberInfinity:/[+-]?\.(?:inf|Inf|INF)/,numberNaN:/\.(?:nan|Nan|NAN)/,numberDate:/\d{4}-\d\d-\d\d([Tt ]\d\d:\d\d:\d\d(\.\d+)?(( ?[+-]\d\d?(:\d\d)?)|Z)?)?/,escapes:/\\(?:[btnfr\\"']|[0-7][0-7]?|[0-3][0-7]{2})/,tokenizer:{root:[{include:"@whitespace"},{include:"@comment"},[/%[^ ]+.*$/,"meta.directive"],[/---/,"operators.directivesEnd"],[/\.{3}/,"operators.documentEnd"],[/[-?:](?= )/,"operators"],{include:"@anchor"},{include:"@tagHandle"},{include:"@flowCollections"},{include:"@blockStyle"},[/@numberInteger(?![ \t]*\S+)/,"number"],[/@numberFloat(?![ \t]*\S+)/,"number.float"],[/@numberOctal(?![ \t]*\S+)/,"number.octal"],[/@numberHex(?![ \t]*\S+)/,"number.hex"],[/@numberInfinity(?![ \t]*\S+)/,"number.infinity"],[/@numberNaN(?![ \t]*\S+)/,"number.nan"],[/@numberDate(?![ \t]*\S+)/,"number.date"],[/(".*?"|'.*?'|[^#'"]*?)([ \t]*)(:)( |$)/,["type","white","operators","white"]],{include:"@flowScalars"},[/.+?(?=(\s+#|$))/,{cases:{"@keywords":"keyword","@default":"string"}}]],object:[{include:"@whitespace"},{include:"@comment"},[/\}/,"@brackets","@pop"],[/,/,"delimiter.comma"],[/:(?= )/,"operators"],[/(?:".*?"|'.*?'|[^,\{\[]+?)(?=: )/,"type"],{include:"@flowCollections"},{include:"@flowScalars"},{include:"@tagHandle"},{include:"@anchor"},{include:"@flowNumber"},[/[^\},]+/,{cases:{"@keywords":"keyword","@default":"string"}}]],array:[{include:"@whitespace"},{include:"@comment"},[/\]/,"@brackets","@pop"],[/,/,"delimiter.comma"],{include:"@flowCollections"},{include:"@flowScalars"},{include:"@tagHandle"},{include:"@anchor"},{include:"@flowNumber"},[/[^\],]+/,{cases:{"@keywords":"keyword","@default":"string"}}]],multiString:[[/^( +).+$/,"string","@multiStringContinued.$1"]],multiStringContinued:[[/^( *).+$/,{cases:{"$1==$S2":"string","@default":{token:"@rematch",next:"@popall"}}}]],whitespace:[[/[ \t\r\n]+/,"white"]],comment:[[/#.*$/,"comment"]],flowCollections:[[/\[/,"@brackets","@array"],[/\{/,"@brackets","@object"]],flowScalars:[[/"([^"\\]|\\.)*$/,"string.invalid"],[/'([^'\\]|\\.)*$/,"string.invalid"],[/'[^']*'/,"string"],[/"/,"string","@doubleQuotedString"]],doubleQuotedString:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]],blockStyle:[[/[>|][0-9]*[+-]?$/,"operators","@multiString"]],flowNumber:[[/@numberInteger(?=[ \t]*[,\]\}])/,"number"],[/@numberFloat(?=[ \t]*[,\]\}])/,"number.float"],[/@numberOctal(?=[ \t]*[,\]\}])/,"number.octal"],[/@numberHex(?=[ \t]*[,\]\}])/,"number.hex"],[/@numberInfinity(?=[ \t]*[,\]\}])/,"number.infinity"],[/@numberNaN(?=[ \t]*[,\]\}])/,"number.nan"],[/@numberDate(?=[ \t]*[,\]\}])/,"number.date"]],tagHandle:[[/\![^ ]*/,"tag"]],anchor:[[/[&*][^ ]+/,"namespace"]]}};export{o as conf,r as language};