@web-site-utilities/feedback 0.0.6 → 0.0.8
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.
- package/dist/common/components/Checkbox.d.ts +1 -1
- package/dist/common/components/QuestionMatrix.d.ts +1 -1
- package/dist/common/components/Radio.d.ts +2 -2
- package/dist/common/components/Rating.d.ts +1 -1
- package/dist/common/components/Select.d.ts +1 -2
- package/dist/common/components/Textarea.d.ts +1 -2
- package/dist/fields/Field/Field.d.ts +2 -41
- package/dist/form/index.d.ts +46 -3
- package/dist/index.cjs.js +22 -22
- package/dist/index.d.ts +47 -2
- package/dist/index.es.js +993 -896
- package/dist/index.iife.js +22 -22
- package/package.json +1 -1
package/dist/index.cjs.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react"),
|
|
2
|
-
`,Rt=typeof window<"u"&&typeof document<"u",Po=!!(typeof SC_DISABLE_SPEEDY=="boolean"?SC_DISABLE_SPEEDY:typeof process<"u"&&process.env!==void 0&&process.env.REACT_APP_SC_DISABLE_SPEEDY!==void 0&&process.env.REACT_APP_SC_DISABLE_SPEEDY!==""?process.env.REACT_APP_SC_DISABLE_SPEEDY!=="false"&&process.env.REACT_APP_SC_DISABLE_SPEEDY:typeof process<"u"&&process.env!==void 0&&process.env.SC_DISABLE_SPEEDY!==void 0&&process.env.SC_DISABLE_SPEEDY!==""&&process.env.SC_DISABLE_SPEEDY!=="false"&&process.env.SC_DISABLE_SPEEDY),Lt=Object.freeze([]),We=Object.freeze({});function Oo(e,t,r){return r===void 0&&(r=We),e.theme!==r.theme&&e.theme||t||r.theme}var wn=new Set(["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","tr","track","u","ul","use","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","marker","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"]),No=/[!"#$%&'()*+,./:;<=>?@[\\\]^`{|}~-]+/g,$o=/(^-|-$)/g;function Hr(e){return e.replace(No,"-").replace($o,"")}var Do=/(a)(d)/gi,gt=52,Vr=function(e){return String.fromCharCode(e+(e>25?39:97))};function cr(e){var t,r="";for(t=Math.abs(e);t>gt;t=t/gt|0)r=Vr(t%gt)+r;return(Vr(t%gt)+r).replace(Do,"$1-$2")}var Zt,xn=5381,Le=function(e,t){for(var r=t.length;r;)e=33*e^t.charCodeAt(--r);return e},Cn=function(e){return Le(xn,e)};function Mo(e){return cr(Cn(e)>>>0)}function Lo(e){return e.displayName||e.name||"Component"}function Qt(e){return typeof e=="string"&&!0}var An=typeof Symbol=="function"&&Symbol.for,_n=An?Symbol.for("react.memo"):60115,Fo=An?Symbol.for("react.forward_ref"):60112,zo={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},Bo={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},In={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},Uo=((Zt={})[Fo]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},Zt[_n]=In,Zt);function Gr(e){return("type"in(t=e)&&t.type.$$typeof)===_n?In:"$$typeof"in e?Uo[e.$$typeof]:zo;var t}var Wo=Object.defineProperty,Ho=Object.getOwnPropertyNames,jr=Object.getOwnPropertySymbols,Vo=Object.getOwnPropertyDescriptor,Go=Object.getPrototypeOf,Yr=Object.prototype;function Rn(e,t,r){if(typeof t!="string"){if(Yr){var n=Go(t);n&&n!==Yr&&Rn(e,n,r)}var o=Ho(t);jr&&(o=o.concat(jr(t)));for(var i=Gr(e),l=Gr(t),d=0;d<o.length;++d){var u=o[d];if(!(u in Bo||r&&r[u]||l&&u in l||i&&u in i)){var m=Vo(t,u);try{Wo(e,u,m)}catch{}}}}return e}function Ce(e){return typeof e=="function"}function yr(e){return typeof e=="object"&&"styledComponentId"in e}function Te(e,t){return e&&t?"".concat(e," ").concat(t):e||t||""}function qr(e,t){if(e.length===0)return"";for(var r=e[0],n=1;n<e.length;n++)r+=e[n];return r}function st(e){return e!==null&&typeof e=="object"&&e.constructor.name===Object.name&&!("props"in e&&e.$$typeof)}function ur(e,t,r){if(r===void 0&&(r=!1),!r&&!st(e)&&!Array.isArray(e))return t;if(Array.isArray(t))for(var n=0;n<t.length;n++)e[n]=ur(e[n],t[n]);else if(st(t))for(var n in t)e[n]=ur(e[n],t[n]);return e}function vr(e,t){Object.defineProperty(e,"toString",{value:t})}function Ae(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];return new Error("An error occurred. See https://github.com/styled-components/styled-components/blob/main/packages/styled-components/src/utils/errors.md#".concat(e," for more information.").concat(t.length>0?" Args: ".concat(t.join(", ")):""))}var jo=(function(){function e(t){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=t}return e.prototype.indexOfGroup=function(t){for(var r=0,n=0;n<t;n++)r+=this.groupSizes[n];return r},e.prototype.insertRules=function(t,r){if(t>=this.groupSizes.length){for(var n=this.groupSizes,o=n.length,i=o;t>=i;)if((i<<=1)<0)throw Ae(16,"".concat(t));this.groupSizes=new Uint32Array(i),this.groupSizes.set(n),this.length=i;for(var l=o;l<i;l++)this.groupSizes[l]=0}for(var d=this.indexOfGroup(t+1),u=(l=0,r.length);l<u;l++)this.tag.insertRule(d,r[l])&&(this.groupSizes[t]++,d++)},e.prototype.clearGroup=function(t){if(t<this.length){var r=this.groupSizes[t],n=this.indexOfGroup(t),o=n+r;this.groupSizes[t]=0;for(var i=n;i<o;i++)this.tag.deleteRule(n)}},e.prototype.getGroup=function(t){var r="";if(t>=this.length||this.groupSizes[t]===0)return r;for(var n=this.groupSizes[t],o=this.indexOfGroup(t),i=o+n,l=o;l<i;l++)r+="".concat(this.tag.getRule(l)).concat(br);return r},e})(),xt=new Map,kt=new Map,Ct=1,bt=function(e){if(xt.has(e))return xt.get(e);for(;kt.has(Ct);)Ct++;var t=Ct++;return xt.set(e,t),kt.set(t,e),t},Yo=function(e,t){Ct=t+1,xt.set(e,t),kt.set(t,e)},qo="style[".concat(Ue,"][").concat(Tn,'="').concat(Mt,'"]'),Ko=new RegExp("^".concat(Ue,'\\.g(\\d+)\\[id="([\\w\\d-]+)"\\].*?"([^"]*)')),Xo=function(e,t,r){for(var n,o=r.split(","),i=0,l=o.length;i<l;i++)(n=o[i])&&e.registerName(t,n)},Zo=function(e,t){for(var r,n=((r=t.textContent)!==null&&r!==void 0?r:"").split(br),o=[],i=0,l=n.length;i<l;i++){var d=n[i].trim();if(d){var u=d.match(Ko);if(u){var m=0|parseInt(u[1],10),p=u[2];m!==0&&(Yo(p,m),Xo(e,p,u[3]),e.getTag().insertRules(m,o)),o.length=0}else o.push(d)}}},Kr=function(e){for(var t=document.querySelectorAll(qo),r=0,n=t.length;r<n;r++){var o=t[r];o&&o.getAttribute(Ue)!==Sn&&(Zo(e,o),o.parentNode&&o.parentNode.removeChild(o))}};function Qo(){return typeof __webpack_nonce__<"u"?__webpack_nonce__:null}var kn=function(e){var t=document.head,r=e||t,n=document.createElement("style"),o=(function(d){var u=Array.from(d.querySelectorAll("style[".concat(Ue,"]")));return u[u.length-1]})(r),i=o!==void 0?o.nextSibling:null;n.setAttribute(Ue,Sn),n.setAttribute(Tn,Mt);var l=Qo();return l&&n.setAttribute("nonce",l),r.insertBefore(n,i),n},Jo=(function(){function e(t){this.element=kn(t),this.element.appendChild(document.createTextNode("")),this.sheet=(function(r){if(r.sheet)return r.sheet;for(var n=document.styleSheets,o=0,i=n.length;o<i;o++){var l=n[o];if(l.ownerNode===r)return l}throw Ae(17)})(this.element),this.length=0}return e.prototype.insertRule=function(t,r){try{return this.sheet.insertRule(r,t),this.length++,!0}catch{return!1}},e.prototype.deleteRule=function(t){this.sheet.deleteRule(t),this.length--},e.prototype.getRule=function(t){var r=this.sheet.cssRules[t];return r&&r.cssText?r.cssText:""},e})(),ea=(function(){function e(t){this.element=kn(t),this.nodes=this.element.childNodes,this.length=0}return e.prototype.insertRule=function(t,r){if(t<=this.length&&t>=0){var n=document.createTextNode(r);return this.element.insertBefore(n,this.nodes[t]||null),this.length++,!0}return!1},e.prototype.deleteRule=function(t){this.element.removeChild(this.nodes[t]),this.length--},e.prototype.getRule=function(t){return t<this.length?this.nodes[t].textContent:""},e})(),ta=(function(){function e(t){this.rules=[],this.length=0}return e.prototype.insertRule=function(t,r){return t<=this.length&&(this.rules.splice(t,0,r),this.length++,!0)},e.prototype.deleteRule=function(t){this.rules.splice(t,1),this.length--},e.prototype.getRule=function(t){return t<this.length?this.rules[t]:""},e})(),Xr=Rt,ra={isServer:!Rt,useCSSOMInjection:!Po},Pn=(function(){function e(t,r,n){t===void 0&&(t=We),r===void 0&&(r={});var o=this;this.options=V(V({},ra),t),this.gs=r,this.names=new Map(n),this.server=!!t.isServer,!this.server&&Rt&&Xr&&(Xr=!1,Kr(this)),vr(this,function(){return(function(i){for(var l=i.getTag(),d=l.length,u="",m=function(T){var w=(function(D){return kt.get(D)})(T);if(w===void 0)return"continue";var v=i.names.get(w),A=l.getGroup(T);if(v===void 0||!v.size||A.length===0)return"continue";var $="".concat(Ue,".g").concat(T,'[id="').concat(w,'"]'),G="";v!==void 0&&v.forEach(function(D){D.length>0&&(G+="".concat(D,","))}),u+="".concat(A).concat($,'{content:"').concat(G,'"}').concat(br)},p=0;p<d;p++)m(p);return u})(o)})}return e.registerId=function(t){return bt(t)},e.prototype.rehydrate=function(){!this.server&&Rt&&Kr(this)},e.prototype.reconstructWithOptions=function(t,r){return r===void 0&&(r=!0),new e(V(V({},this.options),t),this.gs,r&&this.names||void 0)},e.prototype.allocateGSInstance=function(t){return this.gs[t]=(this.gs[t]||0)+1},e.prototype.getTag=function(){return this.tag||(this.tag=(t=(function(r){var n=r.useCSSOMInjection,o=r.target;return r.isServer?new ta(o):n?new Jo(o):new ea(o)})(this.options),new jo(t)));var t},e.prototype.hasNameForId=function(t,r){return this.names.has(t)&&this.names.get(t).has(r)},e.prototype.registerName=function(t,r){if(bt(t),this.names.has(t))this.names.get(t).add(r);else{var n=new Set;n.add(r),this.names.set(t,n)}},e.prototype.insertRules=function(t,r,n){this.registerName(t,r),this.getTag().insertRules(bt(t),n)},e.prototype.clearNames=function(t){this.names.has(t)&&this.names.get(t).clear()},e.prototype.clearRules=function(t){this.getTag().clearGroup(bt(t)),this.clearNames(t)},e.prototype.clearTag=function(){this.tag=void 0},e})(),na=/&/g,oa=/^\s*\/\/.*$/gm;function On(e,t){return e.map(function(r){return r.type==="rule"&&(r.value="".concat(t," ").concat(r.value),r.value=r.value.replaceAll(",",",".concat(t," ")),r.props=r.props.map(function(n){return"".concat(t," ").concat(n)})),Array.isArray(r.children)&&r.type!=="@keyframes"&&(r.children=On(r.children,t)),r})}function aa(e){var t,r,n,o=We,i=o.options,l=i===void 0?We:i,d=o.plugins,u=d===void 0?Lt:d,m=function(w,v,A){return A.startsWith(r)&&A.endsWith(r)&&A.replaceAll(r,"").length>0?".".concat(t):w},p=u.slice();p.push(function(w){w.type===Ot&&w.value.includes("&")&&(w.props[0]=w.props[0].replace(na,r).replace(n,m))}),l.prefix&&p.push(Ro),p.push(Ao);var T=function(w,v,A,$){v===void 0&&(v=""),A===void 0&&(A=""),$===void 0&&($="&"),t=$,r=v,n=new RegExp("\\".concat(r,"\\b"),"g");var G=w.replace(oa,""),D=xo(A||v?"".concat(A," ").concat(v," { ").concat(G," }"):G);l.namespace&&(D=On(D,l.namespace));var P=[];return It(D,_o(p.concat(Io(function(_){return P.push(_)})))),P};return T.hash=u.length?u.reduce(function(w,v){return v.name||Ae(15),Le(w,v.name)},xn).toString():"",T}var ia=new Pn,dr=aa(),Nn=s.createContext({shouldForwardProp:void 0,styleSheet:ia,stylis:dr});Nn.Consumer;s.createContext(void 0);function Zr(){return s.useContext(Nn)}var sa=(function(){function e(t,r){var n=this;this.inject=function(o,i){i===void 0&&(i=dr);var l=n.name+i.hash;o.hasNameForId(n.id,l)||o.insertRules(n.id,l,i(n.rules,l,"@keyframes"))},this.name=t,this.id="sc-keyframes-".concat(t),this.rules=r,vr(this,function(){throw Ae(12,String(n.name))})}return e.prototype.getName=function(t){return t===void 0&&(t=dr),this.name+t.hash},e})(),la=function(e){return e>="A"&&e<="Z"};function Qr(e){for(var t="",r=0;r<e.length;r++){var n=e[r];if(r===1&&n==="-"&&e[0]==="-")return e;la(n)?t+="-"+n.toLowerCase():t+=n}return t.startsWith("ms-")?"-"+t:t}var $n=function(e){return e==null||e===!1||e===""},Dn=function(e){var t,r,n=[];for(var o in e){var i=e[o];e.hasOwnProperty(o)&&!$n(i)&&(Array.isArray(i)&&i.isCss||Ce(i)?n.push("".concat(Qr(o),":"),i,";"):st(i)?n.push.apply(n,_t(_t(["".concat(o," {")],Dn(i),!1),["}"],!1)):n.push("".concat(Qr(o),": ").concat((t=o,(r=i)==null||typeof r=="boolean"||r===""?"":typeof r!="number"||r===0||t in ko||t.startsWith("--")?String(r).trim():"".concat(r,"px")),";")))}return n};function xe(e,t,r,n){if($n(e))return[];if(yr(e))return[".".concat(e.styledComponentId)];if(Ce(e)){if(!Ce(i=e)||i.prototype&&i.prototype.isReactComponent||!t)return[e];var o=e(t);return xe(o,t,r,n)}var i;return e instanceof sa?r?(e.inject(r,n),[e.getName(n)]):[e]:st(e)?Dn(e):Array.isArray(e)?Array.prototype.concat.apply(Lt,e.map(function(l){return xe(l,t,r,n)})):[e.toString()]}function ca(e){for(var t=0;t<e.length;t+=1){var r=e[t];if(Ce(r)&&!yr(r))return!1}return!0}var ua=Cn(Mt),da=(function(){function e(t,r,n){this.rules=t,this.staticRulesId="",this.isStatic=(n===void 0||n.isStatic)&&ca(t),this.componentId=r,this.baseHash=Le(ua,r),this.baseStyle=n,Pn.registerId(r)}return e.prototype.generateAndInjectStyles=function(t,r,n){var o=this.baseStyle?this.baseStyle.generateAndInjectStyles(t,r,n):"";if(this.isStatic&&!n.hash)if(this.staticRulesId&&r.hasNameForId(this.componentId,this.staticRulesId))o=Te(o,this.staticRulesId);else{var i=qr(xe(this.rules,t,r,n)),l=cr(Le(this.baseHash,i)>>>0);if(!r.hasNameForId(this.componentId,l)){var d=n(i,".".concat(l),void 0,this.componentId);r.insertRules(this.componentId,l,d)}o=Te(o,l),this.staticRulesId=l}else{for(var u=Le(this.baseHash,n.hash),m="",p=0;p<this.rules.length;p++){var T=this.rules[p];if(typeof T=="string")m+=T;else if(T){var w=qr(xe(T,t,r,n));u=Le(u,w+p),m+=w}}if(m){var v=cr(u>>>0);r.hasNameForId(this.componentId,v)||r.insertRules(this.componentId,v,n(m,".".concat(v),void 0,this.componentId)),o=Te(o,v)}}return o},e})(),Pt=s.createContext(void 0);Pt.Consumer;function fa(e){var t=s.useContext(Pt),r=s.useMemo(function(){return(function(n,o){if(!n)throw Ae(14);if(Ce(n)){var i=n(o);return i}if(Array.isArray(n)||typeof n!="object")throw Ae(8);return o?V(V({},o),n):n})(e.theme,t)},[e.theme,t]);return e.children?s.createElement(Pt.Provider,{value:r},e.children):null}var Jt={};function ma(e,t,r){var n=yr(e),o=e,i=!Qt(e),l=t.attrs,d=l===void 0?Lt:l,u=t.componentId,m=u===void 0?(function(b,R){var x=typeof b!="string"?"sc":Hr(b);Jt[x]=(Jt[x]||0)+1;var y="".concat(x,"-").concat(Mo(Mt+x+Jt[x]));return R?"".concat(R,"-").concat(y):y})(t.displayName,t.parentComponentId):u,p=t.displayName,T=p===void 0?(function(b){return Qt(b)?"styled.".concat(b):"Styled(".concat(Lo(b),")")})(e):p,w=t.displayName&&t.componentId?"".concat(Hr(t.displayName),"-").concat(t.componentId):t.componentId||m,v=n&&o.attrs?o.attrs.concat(d).filter(Boolean):d,A=t.shouldForwardProp;if(n&&o.shouldForwardProp){var $=o.shouldForwardProp;if(t.shouldForwardProp){var G=t.shouldForwardProp;A=function(b,R){return $(b,R)&&G(b,R)}}else A=$}var D=new da(r,w,n?o.componentStyle:void 0);function P(b,R){return(function(x,y,he){var _e=x.attrs,Ft=x.componentStyle,U=x.defaultProps,je=x.foldedComponentIds,Ye=x.styledComponentId,qe=x.target,zt=s.useContext(Pt),Bt=Zr(),Ke=x.shouldForwardProp||Bt.shouldForwardProp,Xe=Oo(y,zt,U)||We,J=(function(I,te,pe){for(var ge,re=V(V({},te),{className:void 0,theme:pe}),Re=0;Re<I.length;Re+=1){var ve=Ce(ge=I[Re])?ge(re):ge;for(var j in ve)re[j]=j==="className"?Te(re[j],ve[j]):j==="style"?V(V({},re[j]),ve[j]):ve[j]}return te.className&&(re.className=Te(re.className,te.className)),re})(_e,y,Xe),ye=J.as||qe,O={};for(var ee in J)J[ee]===void 0||ee[0]==="$"||ee==="as"||ee==="theme"&&J.theme===Xe||(ee==="forwardedAs"?O.as=J.forwardedAs:Ke&&!Ke(ee,ye)||(O[ee]=J[ee]));var M=(function(I,te){var pe=Zr(),ge=I.generateAndInjectStyles(te,pe.styleSheet,pe.stylis);return ge})(Ft,J),Ie=Te(je,Ye);return M&&(Ie+=" "+M),J.className&&(Ie+=" "+J.className),O[Qt(ye)&&!wn.has(ye)?"class":"className"]=Ie,he&&(O.ref=he),s.createElement(ye,O)})(_,b,R)}P.displayName=T;var _=s.forwardRef(P);return _.attrs=v,_.componentStyle=D,_.displayName=T,_.shouldForwardProp=A,_.foldedComponentIds=n?Te(o.foldedComponentIds,o.styledComponentId):"",_.styledComponentId=w,_.target=n?o.target:e,Object.defineProperty(_,"defaultProps",{get:function(){return this._foldedDefaultProps},set:function(b){this._foldedDefaultProps=n?(function(R){for(var x=[],y=1;y<arguments.length;y++)x[y-1]=arguments[y];for(var he=0,_e=x;he<_e.length;he++)ur(R,_e[he],!0);return R})({},o.defaultProps,b):b}}),vr(_,function(){return".".concat(_.styledComponentId)}),i&&Rn(_,e,{attrs:!0,componentStyle:!0,displayName:!0,foldedComponentIds:!0,shouldForwardProp:!0,styledComponentId:!0,target:!0}),_}function Jr(e,t){for(var r=[e[0]],n=0,o=t.length;n<o;n+=1)r.push(t[n],e[n+1]);return r}var en=function(e){return Object.assign(e,{isCss:!0})};function ha(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(Ce(e)||st(e))return en(xe(Jr(Lt,_t([e],t,!0))));var n=e;return t.length===0&&n.length===1&&typeof n[0]=="string"?xe(n):en(xe(Jr(n,t)))}function fr(e,t,r){if(r===void 0&&(r=We),!t)throw Ae(1,t);var n=function(o){for(var i=[],l=1;l<arguments.length;l++)i[l-1]=arguments[l];return e(t,r,ha.apply(void 0,_t([o],i,!1)))};return n.attrs=function(o){return fr(e,t,V(V({},r),{attrs:Array.prototype.concat(r.attrs,o).filter(Boolean)}))},n.withConfig=function(o){return fr(e,t,V(V({},r),o))},n}var Mn=function(e){return fr(ma,e)},S=Mn;wn.forEach(function(e){S[e]=Mn(e)});const Fe={primary:"#422ad5",primaryContent:"#e0e7ff",secondary:"#f43098",secondaryContent:"#f9e4f0",accent:"#00d3bb",accentContent:"#084d49",neutral:"#09090b",neutralContent:"#e4e4e7",base100:"#ffffff",base200:"#f8f8f8",base300:"#eeeeee",baseContent:"#18181b",info:"#00bafe",infoContent:"#042e49",success:"#00d390",successContent:"#004c39",warning:"#fcb700",warningContent:"#793205",error:"#ff627d",errorContent:"#4d0218",radiusSelectors:"0.25rem",radiusField:"0.25rem",radiusBox:"0.25rem",borderWidth:"1px",fontSize:"1rem",sizeField:".3rem",sizeSelector:".3rem",allFieldsSize:"20rem",spacing:".3rem",depth:1},pa={selectedVariant:"primary",getDefaultVariantOrSelected:()=>"primary",...Fe},Ln=s.createContext({...Fe,...pa}),ga=S.div`
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react"),ha=require("react-dom");var gt={},zr;function pa(){if(zr)return gt;zr=1;var e=ha;return gt.createRoot=e.createRoot,gt.hydrateRoot=e.hydrateRoot,gt}var ga=pa(),H=function(){return H=Object.assign||function(t){for(var r,n=1,a=arguments.length;n<a;n++){r=arguments[n];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(t[i]=r[i])}return t},H.apply(this,arguments)};function It(e,t,r){if(r||arguments.length===2)for(var n=0,a=t.length,i;n<a;n++)(i||!(n in t))&&(i||(i=Array.prototype.slice.call(t,0,n)),i[n]=t[n]);return e.concat(i||Array.prototype.slice.call(t))}var k="-ms-",st="-moz-",C="-webkit-",pn="comm",Nt="rule",gr="decl",ba="@import",gn="@keyframes",ya="@layer",bn=Math.abs,br=String.fromCharCode,sr=Object.assign;function va(e,t){return B(e,0)^45?(((t<<2^B(e,0))<<2^B(e,1))<<2^B(e,2))<<2^B(e,3):0}function yn(e){return e.trim()}function fe(e,t){return(e=t.exec(e))?e[0]:e}function g(e,t,r){return e.replace(t,r)}function Tt(e,t,r){return e.indexOf(t,r)}function B(e,t){return e.charCodeAt(t)|0}function Ue(e,t,r){return e.slice(t,r)}function se(e){return e.length}function vn(e){return e.length}function ot(e,t){return t.push(e),e}function Ea(e,t){return e.map(t).join("")}function Br(e,t){return e.filter(function(r){return!fe(r,t)})}var $t=1,Ve=1,En=0,Z=0,F=0,je="";function Dt(e,t,r,n,a,i,l,d){return{value:e,root:t,parent:r,type:n,props:a,children:i,line:$t,column:Ve,length:l,return:"",siblings:d}}function ye(e,t){return sr(Dt("",null,null,"",null,null,0,e.siblings),e,{length:-e.length},t)}function Fe(e){for(;e.root;)e=ye(e.root,{children:[e]});ot(e,e.siblings)}function Sa(){return F}function Ta(){return F=Z>0?B(je,--Z):0,Ve--,F===10&&(Ve=1,$t--),F}function ae(){return F=Z<En?B(je,Z++):0,Ve++,F===10&&(Ve=1,$t++),F}function xe(){return B(je,Z)}function wt(){return Z}function Mt(e,t){return Ue(je,e,t)}function lr(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function wa(e){return $t=Ve=1,En=se(je=e),Z=0,[]}function xa(e){return je="",e}function Zt(e){return yn(Mt(Z-1,cr(e===91?e+2:e===40?e+1:e)))}function Ca(e){for(;(F=xe())&&F<33;)ae();return lr(e)>2||lr(F)>3?"":" "}function Aa(e,t){for(;--t&&ae()&&!(F<48||F>102||F>57&&F<65||F>70&&F<97););return Mt(e,wt()+(t<6&&xe()==32&&ae()==32))}function cr(e){for(;ae();)switch(F){case e:return Z;case 34:case 39:e!==34&&e!==39&&cr(F);break;case 40:e===41&&cr(e);break;case 92:ae();break}return Z}function _a(e,t){for(;ae()&&e+F!==57;)if(e+F===84&&xe()===47)break;return"/*"+Mt(t,Z-1)+"*"+br(e===47?e:ae())}function Ia(e){for(;!lr(xe());)ae();return Mt(e,Z)}function Ra(e){return xa(xt("",null,null,null,[""],e=wa(e),0,[0],e))}function xt(e,t,r,n,a,i,l,d,u){for(var f=0,p=0,T=l,w=0,E=0,A=0,$=1,G=1,D=1,P=0,_="",b=a,R=i,x=n,y=_;G;)switch(A=P,P=ae()){case 40:if(A!=108&&B(y,T-1)==58){Tt(y+=g(Zt(P),"&","&\f"),"&\f",bn(f?d[f-1]:0))!=-1&&(D=-1);break}case 34:case 39:case 91:y+=Zt(P);break;case 9:case 10:case 13:case 32:y+=Ca(A);break;case 92:y+=Aa(wt()-1,7);continue;case 47:switch(xe()){case 42:case 47:ot(ka(_a(ae(),wt()),t,r,u),u);break;default:y+="/"}break;case 123*$:d[f++]=se(y)*D;case 125*$:case 59:case 0:switch(P){case 0:case 125:G=0;case 59+p:D==-1&&(y=g(y,/\f/g,"")),E>0&&se(y)-T&&ot(E>32?Vr(y+";",n,r,T-1,u):Vr(g(y," ","")+";",n,r,T-2,u),u);break;case 59:y+=";";default:if(ot(x=Ur(y,t,r,f,p,a,d,_,b=[],R=[],T,i),i),P===123)if(p===0)xt(y,t,x,x,b,i,T,d,R);else switch(w===99&&B(y,3)===110?100:w){case 100:case 108:case 109:case 115:xt(e,x,x,n&&ot(Ur(e,x,x,0,0,a,d,_,a,b=[],T,R),R),a,R,T,d,n?b:R);break;default:xt(y,x,x,x,[""],R,0,d,R)}}f=p=E=0,$=D=1,_=y="",T=l;break;case 58:T=1+se(y),E=A;default:if($<1){if(P==123)--$;else if(P==125&&$++==0&&Ta()==125)continue}switch(y+=br(P),P*$){case 38:D=p>0?1:(y+="\f",-1);break;case 44:d[f++]=(se(y)-1)*D,D=1;break;case 64:xe()===45&&(y+=Zt(ae())),w=xe(),p=T=se(_=y+=Ia(wt())),P++;break;case 45:A===45&&se(y)==2&&($=0)}}return i}function Ur(e,t,r,n,a,i,l,d,u,f,p,T){for(var w=a-1,E=a===0?i:[""],A=vn(E),$=0,G=0,D=0;$<n;++$)for(var P=0,_=Ue(e,w+1,w=bn(G=l[$])),b=e;P<A;++P)(b=yn(G>0?E[P]+" "+_:g(_,/&\f/g,E[P])))&&(u[D++]=b);return Dt(e,t,r,a===0?Nt:d,u,f,p,T)}function ka(e,t,r,n){return Dt(e,t,r,pn,br(Sa()),Ue(e,2,-2),0,n)}function Vr(e,t,r,n,a){return Dt(e,t,r,gr,Ue(e,0,n),Ue(e,n+1,-1),n,a)}function Sn(e,t,r){switch(va(e,t)){case 5103:return C+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return C+e+e;case 4789:return st+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return C+e+st+e+k+e+e;case 5936:switch(B(e,t+11)){case 114:return C+e+k+g(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return C+e+k+g(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return C+e+k+g(e,/[svh]\w+-[tblr]{2}/,"lr")+e}case 6828:case 4268:case 2903:return C+e+k+e+e;case 6165:return C+e+k+"flex-"+e+e;case 5187:return C+e+g(e,/(\w+).+(:[^]+)/,C+"box-$1$2"+k+"flex-$1$2")+e;case 5443:return C+e+k+"flex-item-"+g(e,/flex-|-self/g,"")+(fe(e,/flex-|baseline/)?"":k+"grid-row-"+g(e,/flex-|-self/g,""))+e;case 4675:return C+e+k+"flex-line-pack"+g(e,/align-content|flex-|-self/g,"")+e;case 5548:return C+e+k+g(e,"shrink","negative")+e;case 5292:return C+e+k+g(e,"basis","preferred-size")+e;case 6060:return C+"box-"+g(e,"-grow","")+C+e+k+g(e,"grow","positive")+e;case 4554:return C+g(e,/([^-])(transform)/g,"$1"+C+"$2")+e;case 6187:return g(g(g(e,/(zoom-|grab)/,C+"$1"),/(image-set)/,C+"$1"),e,"")+e;case 5495:case 3959:return g(e,/(image-set\([^]*)/,C+"$1$`$1");case 4968:return g(g(e,/(.+:)(flex-)?(.*)/,C+"box-pack:$3"+k+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+C+e+e;case 4200:if(!fe(e,/flex-|baseline/))return k+"grid-column-align"+Ue(e,t)+e;break;case 2592:case 3360:return k+g(e,"template-","")+e;case 4384:case 3616:return r&&r.some(function(n,a){return t=a,fe(n.props,/grid-\w+-end/)})?~Tt(e+(r=r[t].value),"span",0)?e:k+g(e,"-start","")+e+k+"grid-row-span:"+(~Tt(r,"span",0)?fe(r,/\d+/):+fe(r,/\d+/)-+fe(e,/\d+/))+";":k+g(e,"-start","")+e;case 4896:case 4128:return r&&r.some(function(n){return fe(n.props,/grid-\w+-start/)})?e:k+g(g(e,"-end","-span"),"span ","")+e;case 4095:case 3583:case 4068:case 2532:return g(e,/(.+)-inline(.+)/,C+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(se(e)-1-t>6)switch(B(e,t+1)){case 109:if(B(e,t+4)!==45)break;case 102:return g(e,/(.+:)(.+)-([^]+)/,"$1"+C+"$2-$3$1"+st+(B(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~Tt(e,"stretch",0)?Sn(g(e,"stretch","fill-available"),t,r)+e:e}break;case 5152:case 5920:return g(e,/(.+?):(\d+)(\s*\/\s*(span)?\s*(\d+))?(.*)/,function(n,a,i,l,d,u,f){return k+a+":"+i+f+(l?k+a+"-span:"+(d?u:+u-+i)+f:"")+e});case 4949:if(B(e,t+6)===121)return g(e,":",":"+C)+e;break;case 6444:switch(B(e,B(e,14)===45?18:11)){case 120:return g(e,/(.+:)([^;\s!]+)(;|(\s+)?!.+)?/,"$1"+C+(B(e,14)===45?"inline-":"")+"box$3$1"+C+"$2$3$1"+k+"$2box$3")+e;case 100:return g(e,":",":"+k)+e}break;case 5719:case 2647:case 2135:case 3927:case 2391:return g(e,"scroll-","scroll-snap-")+e}return e}function Rt(e,t){for(var r="",n=0;n<e.length;n++)r+=t(e[n],n,e,t)||"";return r}function Pa(e,t,r,n){switch(e.type){case ya:if(e.children.length)break;case ba:case gr:return e.return=e.return||e.value;case pn:return"";case gn:return e.return=e.value+"{"+Rt(e.children,n)+"}";case Nt:if(!se(e.value=e.props.join(",")))return""}return se(r=Rt(e.children,n))?e.return=e.value+"{"+r+"}":""}function Oa(e){var t=vn(e);return function(r,n,a,i){for(var l="",d=0;d<t;d++)l+=e[d](r,n,a,i)||"";return l}}function Na(e){return function(t){t.root||(t=t.return)&&e(t)}}function $a(e,t,r,n){if(e.length>-1&&!e.return)switch(e.type){case gr:e.return=Sn(e.value,e.length,r);return;case gn:return Rt([ye(e,{value:g(e.value,"@","@"+C)})],n);case Nt:if(e.length)return Ea(r=e.props,function(a){switch(fe(a,n=/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":Fe(ye(e,{props:[g(a,/:(read-\w+)/,":"+st+"$1")]})),Fe(ye(e,{props:[a]})),sr(e,{props:Br(r,n)});break;case"::placeholder":Fe(ye(e,{props:[g(a,/:(plac\w+)/,":"+C+"input-$1")]})),Fe(ye(e,{props:[g(a,/:(plac\w+)/,":"+st+"$1")]})),Fe(ye(e,{props:[g(a,/:(plac\w+)/,k+"input-$1")]})),Fe(ye(e,{props:[a]})),sr(e,{props:Br(r,n)});break}return""})}}var Da={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},We=typeof process<"u"&&process.env!==void 0&&(process.env.REACT_APP_SC_ATTR||process.env.SC_ATTR)||"data-styled",Tn="active",wn="data-styled-version",Lt="6.1.19",yr=`/*!sc*/
|
|
2
|
+
`,kt=typeof window<"u"&&typeof document<"u",Ma=!!(typeof SC_DISABLE_SPEEDY=="boolean"?SC_DISABLE_SPEEDY:typeof process<"u"&&process.env!==void 0&&process.env.REACT_APP_SC_DISABLE_SPEEDY!==void 0&&process.env.REACT_APP_SC_DISABLE_SPEEDY!==""?process.env.REACT_APP_SC_DISABLE_SPEEDY!=="false"&&process.env.REACT_APP_SC_DISABLE_SPEEDY:typeof process<"u"&&process.env!==void 0&&process.env.SC_DISABLE_SPEEDY!==void 0&&process.env.SC_DISABLE_SPEEDY!==""&&process.env.SC_DISABLE_SPEEDY!=="false"&&process.env.SC_DISABLE_SPEEDY),Ft=Object.freeze([]),He=Object.freeze({});function La(e,t,r){return r===void 0&&(r=He),e.theme!==r.theme&&e.theme||t||r.theme}var xn=new Set(["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","tr","track","u","ul","use","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","marker","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"]),Fa=/[!"#$%&'()*+,./:;<=>?@[\\\]^`{|}~-]+/g,za=/(^-|-$)/g;function Wr(e){return e.replace(Fa,"-").replace(za,"")}var Ba=/(a)(d)/gi,bt=52,Hr=function(e){return String.fromCharCode(e+(e>25?39:97))};function ur(e){var t,r="";for(t=Math.abs(e);t>bt;t=t/bt|0)r=Hr(t%bt)+r;return(Hr(t%bt)+r).replace(Ba,"$1-$2")}var Qt,Cn=5381,ze=function(e,t){for(var r=t.length;r;)e=33*e^t.charCodeAt(--r);return e},An=function(e){return ze(Cn,e)};function Ua(e){return ur(An(e)>>>0)}function Va(e){return e.displayName||e.name||"Component"}function Jt(e){return typeof e=="string"&&!0}var _n=typeof Symbol=="function"&&Symbol.for,In=_n?Symbol.for("react.memo"):60115,Wa=_n?Symbol.for("react.forward_ref"):60112,Ha={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},Ga={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},Rn={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},ja=((Qt={})[Wa]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},Qt[In]=Rn,Qt);function Gr(e){return("type"in(t=e)&&t.type.$$typeof)===In?Rn:"$$typeof"in e?ja[e.$$typeof]:Ha;var t}var Ya=Object.defineProperty,qa=Object.getOwnPropertyNames,jr=Object.getOwnPropertySymbols,Ka=Object.getOwnPropertyDescriptor,Xa=Object.getPrototypeOf,Yr=Object.prototype;function kn(e,t,r){if(typeof t!="string"){if(Yr){var n=Xa(t);n&&n!==Yr&&kn(e,n,r)}var a=qa(t);jr&&(a=a.concat(jr(t)));for(var i=Gr(e),l=Gr(t),d=0;d<a.length;++d){var u=a[d];if(!(u in Ga||r&&r[u]||l&&u in l||i&&u in i)){var f=Ka(t,u);try{Ya(e,u,f)}catch{}}}}return e}function Ae(e){return typeof e=="function"}function vr(e){return typeof e=="object"&&"styledComponentId"in e}function we(e,t){return e&&t?"".concat(e," ").concat(t):e||t||""}function qr(e,t){if(e.length===0)return"";for(var r=e[0],n=1;n<e.length;n++)r+=e[n];return r}function lt(e){return e!==null&&typeof e=="object"&&e.constructor.name===Object.name&&!("props"in e&&e.$$typeof)}function dr(e,t,r){if(r===void 0&&(r=!1),!r&&!lt(e)&&!Array.isArray(e))return t;if(Array.isArray(t))for(var n=0;n<t.length;n++)e[n]=dr(e[n],t[n]);else if(lt(t))for(var n in t)e[n]=dr(e[n],t[n]);return e}function Er(e,t){Object.defineProperty(e,"toString",{value:t})}function _e(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];return new Error("An error occurred. See https://github.com/styled-components/styled-components/blob/main/packages/styled-components/src/utils/errors.md#".concat(e," for more information.").concat(t.length>0?" Args: ".concat(t.join(", ")):""))}var Za=(function(){function e(t){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=t}return e.prototype.indexOfGroup=function(t){for(var r=0,n=0;n<t;n++)r+=this.groupSizes[n];return r},e.prototype.insertRules=function(t,r){if(t>=this.groupSizes.length){for(var n=this.groupSizes,a=n.length,i=a;t>=i;)if((i<<=1)<0)throw _e(16,"".concat(t));this.groupSizes=new Uint32Array(i),this.groupSizes.set(n),this.length=i;for(var l=a;l<i;l++)this.groupSizes[l]=0}for(var d=this.indexOfGroup(t+1),u=(l=0,r.length);l<u;l++)this.tag.insertRule(d,r[l])&&(this.groupSizes[t]++,d++)},e.prototype.clearGroup=function(t){if(t<this.length){var r=this.groupSizes[t],n=this.indexOfGroup(t),a=n+r;this.groupSizes[t]=0;for(var i=n;i<a;i++)this.tag.deleteRule(n)}},e.prototype.getGroup=function(t){var r="";if(t>=this.length||this.groupSizes[t]===0)return r;for(var n=this.groupSizes[t],a=this.indexOfGroup(t),i=a+n,l=a;l<i;l++)r+="".concat(this.tag.getRule(l)).concat(yr);return r},e})(),Ct=new Map,Pt=new Map,At=1,yt=function(e){if(Ct.has(e))return Ct.get(e);for(;Pt.has(At);)At++;var t=At++;return Ct.set(e,t),Pt.set(t,e),t},Qa=function(e,t){At=t+1,Ct.set(e,t),Pt.set(t,e)},Ja="style[".concat(We,"][").concat(wn,'="').concat(Lt,'"]'),eo=new RegExp("^".concat(We,'\\.g(\\d+)\\[id="([\\w\\d-]+)"\\].*?"([^"]*)')),to=function(e,t,r){for(var n,a=r.split(","),i=0,l=a.length;i<l;i++)(n=a[i])&&e.registerName(t,n)},ro=function(e,t){for(var r,n=((r=t.textContent)!==null&&r!==void 0?r:"").split(yr),a=[],i=0,l=n.length;i<l;i++){var d=n[i].trim();if(d){var u=d.match(eo);if(u){var f=0|parseInt(u[1],10),p=u[2];f!==0&&(Qa(p,f),to(e,p,u[3]),e.getTag().insertRules(f,a)),a.length=0}else a.push(d)}}},Kr=function(e){for(var t=document.querySelectorAll(Ja),r=0,n=t.length;r<n;r++){var a=t[r];a&&a.getAttribute(We)!==Tn&&(ro(e,a),a.parentNode&&a.parentNode.removeChild(a))}};function no(){return typeof __webpack_nonce__<"u"?__webpack_nonce__:null}var Pn=function(e){var t=document.head,r=e||t,n=document.createElement("style"),a=(function(d){var u=Array.from(d.querySelectorAll("style[".concat(We,"]")));return u[u.length-1]})(r),i=a!==void 0?a.nextSibling:null;n.setAttribute(We,Tn),n.setAttribute(wn,Lt);var l=no();return l&&n.setAttribute("nonce",l),r.insertBefore(n,i),n},ao=(function(){function e(t){this.element=Pn(t),this.element.appendChild(document.createTextNode("")),this.sheet=(function(r){if(r.sheet)return r.sheet;for(var n=document.styleSheets,a=0,i=n.length;a<i;a++){var l=n[a];if(l.ownerNode===r)return l}throw _e(17)})(this.element),this.length=0}return e.prototype.insertRule=function(t,r){try{return this.sheet.insertRule(r,t),this.length++,!0}catch{return!1}},e.prototype.deleteRule=function(t){this.sheet.deleteRule(t),this.length--},e.prototype.getRule=function(t){var r=this.sheet.cssRules[t];return r&&r.cssText?r.cssText:""},e})(),oo=(function(){function e(t){this.element=Pn(t),this.nodes=this.element.childNodes,this.length=0}return e.prototype.insertRule=function(t,r){if(t<=this.length&&t>=0){var n=document.createTextNode(r);return this.element.insertBefore(n,this.nodes[t]||null),this.length++,!0}return!1},e.prototype.deleteRule=function(t){this.element.removeChild(this.nodes[t]),this.length--},e.prototype.getRule=function(t){return t<this.length?this.nodes[t].textContent:""},e})(),io=(function(){function e(t){this.rules=[],this.length=0}return e.prototype.insertRule=function(t,r){return t<=this.length&&(this.rules.splice(t,0,r),this.length++,!0)},e.prototype.deleteRule=function(t){this.rules.splice(t,1),this.length--},e.prototype.getRule=function(t){return t<this.length?this.rules[t]:""},e})(),Xr=kt,so={isServer:!kt,useCSSOMInjection:!Ma},On=(function(){function e(t,r,n){t===void 0&&(t=He),r===void 0&&(r={});var a=this;this.options=H(H({},so),t),this.gs=r,this.names=new Map(n),this.server=!!t.isServer,!this.server&&kt&&Xr&&(Xr=!1,Kr(this)),Er(this,function(){return(function(i){for(var l=i.getTag(),d=l.length,u="",f=function(T){var w=(function(D){return Pt.get(D)})(T);if(w===void 0)return"continue";var E=i.names.get(w),A=l.getGroup(T);if(E===void 0||!E.size||A.length===0)return"continue";var $="".concat(We,".g").concat(T,'[id="').concat(w,'"]'),G="";E!==void 0&&E.forEach(function(D){D.length>0&&(G+="".concat(D,","))}),u+="".concat(A).concat($,'{content:"').concat(G,'"}').concat(yr)},p=0;p<d;p++)f(p);return u})(a)})}return e.registerId=function(t){return yt(t)},e.prototype.rehydrate=function(){!this.server&&kt&&Kr(this)},e.prototype.reconstructWithOptions=function(t,r){return r===void 0&&(r=!0),new e(H(H({},this.options),t),this.gs,r&&this.names||void 0)},e.prototype.allocateGSInstance=function(t){return this.gs[t]=(this.gs[t]||0)+1},e.prototype.getTag=function(){return this.tag||(this.tag=(t=(function(r){var n=r.useCSSOMInjection,a=r.target;return r.isServer?new io(a):n?new ao(a):new oo(a)})(this.options),new Za(t)));var t},e.prototype.hasNameForId=function(t,r){return this.names.has(t)&&this.names.get(t).has(r)},e.prototype.registerName=function(t,r){if(yt(t),this.names.has(t))this.names.get(t).add(r);else{var n=new Set;n.add(r),this.names.set(t,n)}},e.prototype.insertRules=function(t,r,n){this.registerName(t,r),this.getTag().insertRules(yt(t),n)},e.prototype.clearNames=function(t){this.names.has(t)&&this.names.get(t).clear()},e.prototype.clearRules=function(t){this.getTag().clearGroup(yt(t)),this.clearNames(t)},e.prototype.clearTag=function(){this.tag=void 0},e})(),lo=/&/g,co=/^\s*\/\/.*$/gm;function Nn(e,t){return e.map(function(r){return r.type==="rule"&&(r.value="".concat(t," ").concat(r.value),r.value=r.value.replaceAll(",",",".concat(t," ")),r.props=r.props.map(function(n){return"".concat(t," ").concat(n)})),Array.isArray(r.children)&&r.type!=="@keyframes"&&(r.children=Nn(r.children,t)),r})}function uo(e){var t,r,n,a=He,i=a.options,l=i===void 0?He:i,d=a.plugins,u=d===void 0?Ft:d,f=function(w,E,A){return A.startsWith(r)&&A.endsWith(r)&&A.replaceAll(r,"").length>0?".".concat(t):w},p=u.slice();p.push(function(w){w.type===Nt&&w.value.includes("&")&&(w.props[0]=w.props[0].replace(lo,r).replace(n,f))}),l.prefix&&p.push($a),p.push(Pa);var T=function(w,E,A,$){E===void 0&&(E=""),A===void 0&&(A=""),$===void 0&&($="&"),t=$,r=E,n=new RegExp("\\".concat(r,"\\b"),"g");var G=w.replace(co,""),D=Ra(A||E?"".concat(A," ").concat(E," { ").concat(G," }"):G);l.namespace&&(D=Nn(D,l.namespace));var P=[];return Rt(D,Oa(p.concat(Na(function(_){return P.push(_)})))),P};return T.hash=u.length?u.reduce(function(w,E){return E.name||_e(15),ze(w,E.name)},Cn).toString():"",T}var mo=new On,mr=uo(),$n=s.createContext({shouldForwardProp:void 0,styleSheet:mo,stylis:mr});$n.Consumer;s.createContext(void 0);function Zr(){return s.useContext($n)}var fo=(function(){function e(t,r){var n=this;this.inject=function(a,i){i===void 0&&(i=mr);var l=n.name+i.hash;a.hasNameForId(n.id,l)||a.insertRules(n.id,l,i(n.rules,l,"@keyframes"))},this.name=t,this.id="sc-keyframes-".concat(t),this.rules=r,Er(this,function(){throw _e(12,String(n.name))})}return e.prototype.getName=function(t){return t===void 0&&(t=mr),this.name+t.hash},e})(),ho=function(e){return e>="A"&&e<="Z"};function Qr(e){for(var t="",r=0;r<e.length;r++){var n=e[r];if(r===1&&n==="-"&&e[0]==="-")return e;ho(n)?t+="-"+n.toLowerCase():t+=n}return t.startsWith("ms-")?"-"+t:t}var Dn=function(e){return e==null||e===!1||e===""},Mn=function(e){var t,r,n=[];for(var a in e){var i=e[a];e.hasOwnProperty(a)&&!Dn(i)&&(Array.isArray(i)&&i.isCss||Ae(i)?n.push("".concat(Qr(a),":"),i,";"):lt(i)?n.push.apply(n,It(It(["".concat(a," {")],Mn(i),!1),["}"],!1)):n.push("".concat(Qr(a),": ").concat((t=a,(r=i)==null||typeof r=="boolean"||r===""?"":typeof r!="number"||r===0||t in Da||t.startsWith("--")?String(r).trim():"".concat(r,"px")),";")))}return n};function Ce(e,t,r,n){if(Dn(e))return[];if(vr(e))return[".".concat(e.styledComponentId)];if(Ae(e)){if(!Ae(i=e)||i.prototype&&i.prototype.isReactComponent||!t)return[e];var a=e(t);return Ce(a,t,r,n)}var i;return e instanceof fo?r?(e.inject(r,n),[e.getName(n)]):[e]:lt(e)?Mn(e):Array.isArray(e)?Array.prototype.concat.apply(Ft,e.map(function(l){return Ce(l,t,r,n)})):[e.toString()]}function po(e){for(var t=0;t<e.length;t+=1){var r=e[t];if(Ae(r)&&!vr(r))return!1}return!0}var go=An(Lt),bo=(function(){function e(t,r,n){this.rules=t,this.staticRulesId="",this.isStatic=(n===void 0||n.isStatic)&&po(t),this.componentId=r,this.baseHash=ze(go,r),this.baseStyle=n,On.registerId(r)}return e.prototype.generateAndInjectStyles=function(t,r,n){var a=this.baseStyle?this.baseStyle.generateAndInjectStyles(t,r,n):"";if(this.isStatic&&!n.hash)if(this.staticRulesId&&r.hasNameForId(this.componentId,this.staticRulesId))a=we(a,this.staticRulesId);else{var i=qr(Ce(this.rules,t,r,n)),l=ur(ze(this.baseHash,i)>>>0);if(!r.hasNameForId(this.componentId,l)){var d=n(i,".".concat(l),void 0,this.componentId);r.insertRules(this.componentId,l,d)}a=we(a,l),this.staticRulesId=l}else{for(var u=ze(this.baseHash,n.hash),f="",p=0;p<this.rules.length;p++){var T=this.rules[p];if(typeof T=="string")f+=T;else if(T){var w=qr(Ce(T,t,r,n));u=ze(u,w+p),f+=w}}if(f){var E=ur(u>>>0);r.hasNameForId(this.componentId,E)||r.insertRules(this.componentId,E,n(f,".".concat(E),void 0,this.componentId)),a=we(a,E)}}return a},e})(),Ot=s.createContext(void 0);Ot.Consumer;function yo(e){var t=s.useContext(Ot),r=s.useMemo(function(){return(function(n,a){if(!n)throw _e(14);if(Ae(n)){var i=n(a);return i}if(Array.isArray(n)||typeof n!="object")throw _e(8);return a?H(H({},a),n):n})(e.theme,t)},[e.theme,t]);return e.children?s.createElement(Ot.Provider,{value:r},e.children):null}var er={};function vo(e,t,r){var n=vr(e),a=e,i=!Jt(e),l=t.attrs,d=l===void 0?Ft:l,u=t.componentId,f=u===void 0?(function(b,R){var x=typeof b!="string"?"sc":Wr(b);er[x]=(er[x]||0)+1;var y="".concat(x,"-").concat(Ua(Lt+x+er[x]));return R?"".concat(R,"-").concat(y):y})(t.displayName,t.parentComponentId):u,p=t.displayName,T=p===void 0?(function(b){return Jt(b)?"styled.".concat(b):"Styled(".concat(Va(b),")")})(e):p,w=t.displayName&&t.componentId?"".concat(Wr(t.displayName),"-").concat(t.componentId):t.componentId||f,E=n&&a.attrs?a.attrs.concat(d).filter(Boolean):d,A=t.shouldForwardProp;if(n&&a.shouldForwardProp){var $=a.shouldForwardProp;if(t.shouldForwardProp){var G=t.shouldForwardProp;A=function(b,R){return $(b,R)&&G(b,R)}}else A=$}var D=new bo(r,w,n?a.componentStyle:void 0);function P(b,R){return(function(x,y,pe){var Re=x.attrs,zt=x.componentStyle,U=x.defaultProps,Ye=x.foldedComponentIds,qe=x.styledComponentId,Ke=x.target,Bt=s.useContext(Ot),Ut=Zr(),Xe=x.shouldForwardProp||Ut.shouldForwardProp,Ze=La(y,Bt,U)||He,J=(function(I,te,ge){for(var be,re=H(H({},te),{className:void 0,theme:ge}),Pe=0;Pe<I.length;Pe+=1){var Ee=Ae(be=I[Pe])?be(re):be;for(var j in Ee)re[j]=j==="className"?we(re[j],Ee[j]):j==="style"?H(H({},re[j]),Ee[j]):Ee[j]}return te.className&&(re.className=we(re.className,te.className)),re})(Re,y,Ze),ve=J.as||Ke,O={};for(var ee in J)J[ee]===void 0||ee[0]==="$"||ee==="as"||ee==="theme"&&J.theme===Ze||(ee==="forwardedAs"?O.as=J.forwardedAs:Xe&&!Xe(ee,ve)||(O[ee]=J[ee]));var M=(function(I,te){var ge=Zr(),be=I.generateAndInjectStyles(te,ge.styleSheet,ge.stylis);return be})(zt,J),ke=we(Ye,qe);return M&&(ke+=" "+M),J.className&&(ke+=" "+J.className),O[Jt(ve)&&!xn.has(ve)?"class":"className"]=ke,pe&&(O.ref=pe),s.createElement(ve,O)})(_,b,R)}P.displayName=T;var _=s.forwardRef(P);return _.attrs=E,_.componentStyle=D,_.displayName=T,_.shouldForwardProp=A,_.foldedComponentIds=n?we(a.foldedComponentIds,a.styledComponentId):"",_.styledComponentId=w,_.target=n?a.target:e,Object.defineProperty(_,"defaultProps",{get:function(){return this._foldedDefaultProps},set:function(b){this._foldedDefaultProps=n?(function(R){for(var x=[],y=1;y<arguments.length;y++)x[y-1]=arguments[y];for(var pe=0,Re=x;pe<Re.length;pe++)dr(R,Re[pe],!0);return R})({},a.defaultProps,b):b}}),Er(_,function(){return".".concat(_.styledComponentId)}),i&&kn(_,e,{attrs:!0,componentStyle:!0,displayName:!0,foldedComponentIds:!0,shouldForwardProp:!0,styledComponentId:!0,target:!0}),_}function Jr(e,t){for(var r=[e[0]],n=0,a=t.length;n<a;n+=1)r.push(t[n],e[n+1]);return r}var en=function(e){return Object.assign(e,{isCss:!0})};function Eo(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(Ae(e)||lt(e))return en(Ce(Jr(Ft,It([e],t,!0))));var n=e;return t.length===0&&n.length===1&&typeof n[0]=="string"?Ce(n):en(Ce(Jr(n,t)))}function fr(e,t,r){if(r===void 0&&(r=He),!t)throw _e(1,t);var n=function(a){for(var i=[],l=1;l<arguments.length;l++)i[l-1]=arguments[l];return e(t,r,Eo.apply(void 0,It([a],i,!1)))};return n.attrs=function(a){return fr(e,t,H(H({},r),{attrs:Array.prototype.concat(r.attrs,a).filter(Boolean)}))},n.withConfig=function(a){return fr(e,t,H(H({},r),a))},n}var Ln=function(e){return fr(vo,e)},v=Ln;xn.forEach(function(e){v[e]=Ln(e)});const Be={primary:"#422ad5",primaryContent:"#e0e7ff",secondary:"#f43098",secondaryContent:"#f9e4f0",accent:"#00d3bb",accentContent:"#084d49",neutral:"#09090b",neutralContent:"#e4e4e7",base100:"#ffffff",base200:"#f8f8f8",base300:"#eeeeee",baseContent:"#18181b",info:"#00bafe",infoContent:"#042e49",success:"#00d390",successContent:"#004c39",warning:"#fcb700",warningContent:"#793205",error:"#ff627d",errorContent:"#4d0218",radiusSelectors:"0.25rem",radiusField:"0.25rem",radiusBox:"0.25rem",borderWidth:"1px",fontSize:"1rem",sizeField:".3rem",sizeSelector:".3rem",allFieldsSize:"20rem",spacing:".3rem",depth:1},So={selectedVariant:"primary",getDefaultVariantOrSelected:()=>"primary",...Be},Fn=s.createContext({...Be,...So}),To=v.div`
|
|
3
3
|
font-family:
|
|
4
4
|
ui-sans-serif,
|
|
5
5
|
system-ui,
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
--depth: ${e=>e.$theme.depth};
|
|
51
51
|
--spacing: ${e=>e.$theme.spacing};
|
|
52
52
|
--all-fields-size: ${e=>e.$theme.allFieldsSize};
|
|
53
|
-
`,
|
|
53
|
+
`,he=e=>{const t=e.selectedVariant??"primary";return console.log("ThemeProvider_theme",e.theme??Be),s.createElement(yo,{theme:e.theme??Be,children:s.createElement(To,{$theme:e.theme??Be,children:s.createElement(Fn.Provider,{value:{selectedVariant:t,getDefaultVariantOrSelected:()=>t,...e.theme??Be},children:e.children})})})},zn=()=>s.useContext(Fn),le=e=>{const{getDefaultVariantOrSelected:t,...r}=zn(),n=t();return r[e??n]},Bn=e=>{const{getDefaultVariantOrSelected:t,...r}=zn(),n=t(),a=e?`${e}Content`:`${n}Content`;return r[a]},wo=()=>{const e="http://localhost:4000/external",t=async r=>{const n=await r;if(!n.ok)switch(n.status){case 404:throw new Error("Not found");case 400:throw new Error("Bad request");default:throw new Error("Unknown error")}return(await r).json()};return{post:async(r,n,a)=>{var i;try{return t(fetch(`${e}${r}`,{method:"POST",body:JSON.stringify(n),signal:((i=a==null?void 0:a.abortController)==null?void 0:i.signal)??null,headers:{"Content-Type":"application/json",...(a==null?void 0:a.headers)??{}}}))}catch(l){throw console.log(l),l}},get:async(r,n)=>{var a;try{return t(fetch(`${e}${r}`,{method:"GET",signal:((a=n==null?void 0:n.abortController)==null?void 0:a.signal)??null,headers:{"Content-Type":"application/json",...(n==null?void 0:n.headers)??{}}}))}catch(i){throw console.log(i),i}}}},tn={meta:{name:"asd"},steps:[{title:"Overall altitude",meta:{name:"overall"},fields:[{type:"matrix",meta:{name:"asd",fieldKey:"recommendationChance"},validations:{required:!0},label:{default:"How likely are you to recommend this company to a friend or colleague?"},max:10},{type:"radio-group",meta:{name:"asd",fieldKey:"satisfactionLevel"},label:{default:"Overall, how satisfied or dissatisfied are you with our company?"},validations:{required:!0},options:[{label:"Very satisfied",id:"1"},{label:"Somewhat satisfied",id:"2"},{label:"Neither satisfied nor dissatisfied",id:"3"},{label:"Somewhat dissatisfied",id:"4"},{label:"Very dissatisfied",id:"5"}]},{type:"rating",icon:"star2",max:5,meta:{name:"asd",fieldKey:"satisfactionRating"},label:{default:"What is your general satisfaction?"},validations:{required:!0}}]},{meta:{name:"products"},title:"Product questions",fields:[{type:"checkbox-group",meta:{name:"asd",fieldKey:"productDescribeWords"},label:{default:"Which of the following words best describes your experience with our products?"},validations:{required:!0},options:[{label:"Reliable",id:"1"},{label:"High quality",id:"2"},{label:"Useful",id:"3"},{label:"Unique",id:"4"},{label:"Value for money",id:"5"},{label:"Overpriced",id:"6"},{label:"Ineffective",id:"7"},{label:"Poor quality",id:"8"},{label:"Unreliable",id:"9"}]},{type:"radio-group",meta:{name:"asd",fieldKey:"productExpectations"},label:{default:"How well products meet your expectations?"},validations:{required:!0},options:[{label:"Extremely well",id:"1"},{label:"Well",id:"2"},{label:"Somewhat well",id:"3"},{label:"Not well",id:"4"},{label:"Not at all well",id:"5"}]},{type:"matrix",meta:{name:"asd",fieldKey:"productQuality"},label:{default:"How would you rate the quality of our products?"},validations:{required:!0},max:10,minText:"Poor quality",maxText:"Good quality"}]},{meta:{name:"final-questions"},title:"Final questions",fields:[{type:"range-slide",defaultValue:77,meta:{name:"asd",fieldKey:"productsImpressionLevel"},label:{default:"What is your overall impression level of our products?"}},{type:"rating",icon:"heart",max:5,meta:{name:"asd",fieldKey:"productExpectations"},label:{default:"Do you like our service and products?"},validations:{required:!0}},{type:"select",meta:{name:"asd",fieldKey:"fromWhereDidYouHearAboutUs"},label:{default:"From where did you hear about us?"},validations:{required:!0},options:[{label:"Facebook",id:"1"},{label:"Instagram",id:"2"},{label:"Google search",id:"3"},{label:"AD",id:"4"},{label:"Other",id:"5"}]},{type:"textarea",meta:{name:"asd",fieldKey:"lastComments"},validations:{required:!1},label:{values:[{conditions:[{fieldName:"satisfactionRating",lessThan:4}],value:"How can we improve our service? (optional)"}],default:"What you would like to tell us about your experience with this company? (optional)?"}}]}]},xo=(e,t)=>new Promise(r=>{r({id:"",domainId:"",attributes:{theme:{},useSystemTheme:!0,variant:"primary"},popupForm:{meta:{name:"popupForm"},config:{canReturnToPreviousStep:!0,nextButtonText:"Next",previousButtonText:"Previous",submitButtonText:"Submit",formTitle:"We are looking forward to hear from you!",buttonText:"Feedback"},styles:{left:null,top:0,bottom:-20,right:0},form:tn},inlineForm:{meta:{name:"asd"},config:{canReturnToPreviousStep:!0,nextButtonText:"Next",previousButtonText:"Previous",submitButtonText:"Submit",formTitle:"We are looking forward to hear from you!"},form:tn}})}),Co=e=>{const[t,r]=s.useState(),[n,a]=s.useState(!0),[i,l]=s.useState(null);return s.useEffect(()=>{const d=new AbortController;return a(!0),e(d).then(r).catch(l).finally(()=>a(!1)),()=>{d.abort()}},[]),{data:t,loading:n,error:i}},Ge=v.button(e=>{const t=le(),r=Bn(),a=!e.$outlined?t:"#fff",i=e.$outlined?t:r,l=e.$outlined?i:a,d=`calc(${e.theme.sizeField} * 10)`;return{borderRadius:e.theme.radiusField,borderColor:e.disabled?"#cfcfcf":l,borderStyle:e.$dashed?"dashed":"solid",cursor:"pointer",boxShadow:"inset 0 0 20px 20px transparent",height:d,fontWeight:"600",opacity:e.disabled?.5:1,paddingInline:"1.2rem",transition:"all 0.2s ease-in-out",background:e.disabled?"#cfcfcf":a,borderWidth:e.theme.borderWidth,userSelect:e.disabled?"none":void 0,color:e.disabled?"#888888":i,"&:active":{transform:e.disabled?void 0:"scale(0.97)"},"&:hover":{opacity:e.disabled?void 0:.8,cursor:e.disabled?"auto":"pointer",boxShadow:e.disabled?void 0:"inset 0 0 20px 20px #00000017"},"@media (max-width: 900px)":{paddingInline:"0.5rem"},"@media (max-width: 700px)":{paddingInline:"0.7rem"},"@media (max-width: 400px)":{paddingInline:"0.7rem"}}}),Ao=v.div`
|
|
54
54
|
visibility: ${e=>e.$isVisible&&e.$height?"visible":"hidden"};
|
|
55
55
|
opacity: ${e=>e.$isVisible?1:0};
|
|
56
56
|
display: flex;
|
|
@@ -69,7 +69,7 @@
|
|
|
69
69
|
height: ${e=>e.$isVisible?"auto":"0"};
|
|
70
70
|
width: ${e=>e.$isVisible?"auto":"0"};
|
|
71
71
|
}
|
|
72
|
-
`,
|
|
72
|
+
`,Un=e=>{const t=s.useRef(null);return s.useEffect(()=>{t.current&&e.onSetMaxHeight(t.current.clientHeight)},[t]),s.createElement(Ao,{ref:t,$height:e.height,$isVisible:e.isVisible,children:e.children})},_o=v.ul`
|
|
73
73
|
counter-reset: step;
|
|
74
74
|
grid-auto-columns: 1fr;
|
|
75
75
|
grid-auto-flow: column;
|
|
@@ -78,8 +78,8 @@
|
|
|
78
78
|
@media (max-width: 900px) {
|
|
79
79
|
display: none;
|
|
80
80
|
}
|
|
81
|
-
`,Ta=S.li(e=>{const t=me(e.colorVariant),r=zn(e.colorVariant),n=e.shouldBeFilled?t:"var(--color-base-300)",o=e.shouldBeFilled?r:"var(--color-base-content)";return{textAlign:"center","--step-bg":n,"--step-fg":o,gridTemplateRows:"40px 1fr",gridTemplateColumns:"auto",gap:".5rem",placeItems:"center",minWidth:"4rem",display:"grid","&:not(:first-of-type):before":{width:"100%",height:"0.5rem",color:"var(--step-bg)",backgroundColor:"var(--step-bg)","--tw-content":"''",content:"var(--tw-content)",border:"1px solid",gridRowStart:"1",gridColumnStart:"1",marginInlineStart:"-100%"},"&:after":{content:"counter(step)",counterIncrement:"step",zIndex:"1",color:"var(--step-fg)",backgroundColor:"var(--step-bg)",border:"1px solid var(--step-bg)",borderRadius:"3.40282e38px",gridRowStart:"1",gridColumnStart:"1",placeSelf:"center",placeItems:"center",width:"2rem",height:"2rem",display:"grid",position:"relative"}}}),Un=e=>(console.log("props.currentStepIndex",e.currentStepIndex),s.createElement(Sa,{children:[e.steps.map((t,r)=>s.createElement(Ta,{key:t.title,colorVariant:e.colorVariant,shouldBeFilled:e.currentStepIndex>=r,children:t.title}))]})),wa={title:{marginTop:"0",marginBottom:".888889em",fontWeight:"700",fontSize:"2.25em",lineHeight:"1.11111"},subtitle:{marginTop:"2em",fontWeight:"700",marginBottom:"1em",fontSize:"1.5em",lineHeight:"1.33333"},section:{marginBottom:"1em",fontWeight:"600",fontSize:"1.25em",lineHeight:"1.6"},subsection:{marginTop:"1.5em",marginBottom:".5em",fontWeight:"600",fontSize:"1rem"},paragraph:{marginTop:"0",marginBottom:"1.25em",fontSize:"1rem"}},xa=S.div(e=>({...wa[e.$variant??"paragraph"],color:e.theme.baseContent,...e.$linear?{margin:"0"}:{}})),se=e=>s.createElement(xa,{$variant:e.variant,$linear:e.linear,children:e.children}),Ca=e=>{switch(e){case"textarea":return"";case"select":return"";case"checkbox-group":return[];case"radio-group":return"";case"matrix":return null;case"range-slide":return null;case"rating":return null;default:return null}},Wn=e=>{const t=s.useMemo(()=>e.form.steps.reduce((l,d,u)=>(l.validationsPerStep[u]={},l.steps=[...l.steps,{...d,fields:d.fields.map(m=>{const p=m.meta.fieldKey;return p?(l.validationsPerStep[u][p]={fieldType:m.type,validations:m.validations},l.state={...l.state,[p]:Ca(m.type)},{dataField:p,...m}):{...m,dataField:null}})}],l),{validationsPerStep:{},state:{},steps:[]}),[e.form]),[r,n]=s.useState(t.state),o=s.useCallback((l,d)=>{l!==null&&n(u=>({...u,[l]:d}))},[n]),i=s.useCallback(l=>l?r[l]:null,[r]);return{steps:t.steps,validationsPerStep:t.validationsPerStep,state:r,setStateByKey:o,getStateByKey:i}},Aa=ba(),_a=(e,t)=>Aa.post("/feedback-receiver",e,t);/*! @license DOMPurify 3.2.7 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.2.7/LICENSE */const{entries:Hn,setPrototypeOf:rn,isFrozen:Ia,getPrototypeOf:Ra,getOwnPropertyDescriptor:ka}=Object;let{freeze:q,seal:Q,create:Vn}=Object,{apply:mr,construct:hr}=typeof Reflect<"u"&&Reflect;q||(q=function(t){return t});Q||(Q=function(t){return t});mr||(mr=function(t,r){for(var n=arguments.length,o=new Array(n>2?n-2:0),i=2;i<n;i++)o[i-2]=arguments[i];return t.apply(r,o)});hr||(hr=function(t){for(var r=arguments.length,n=new Array(r>1?r-1:0),o=1;o<r;o++)n[o-1]=arguments[o];return new t(...n)});const yt=K(Array.prototype.forEach),Pa=K(Array.prototype.lastIndexOf),nn=K(Array.prototype.pop),Je=K(Array.prototype.push),Oa=K(Array.prototype.splice),At=K(String.prototype.toLowerCase),er=K(String.prototype.toString),tr=K(String.prototype.match),et=K(String.prototype.replace),Na=K(String.prototype.indexOf),$a=K(String.prototype.trim),ne=K(Object.prototype.hasOwnProperty),Y=K(RegExp.prototype.test),tt=Da(TypeError);function K(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);for(var r=arguments.length,n=new Array(r>1?r-1:0),o=1;o<r;o++)n[o-1]=arguments[o];return mr(e,t,n)}}function Da(e){return function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return hr(e,r)}}function E(e,t){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:At;rn&&rn(e,null);let n=t.length;for(;n--;){let o=t[n];if(typeof o=="string"){const i=r(o);i!==o&&(Ia(t)||(t[n]=i),o=i)}e[o]=!0}return e}function Ma(e){for(let t=0;t<e.length;t++)ne(e,t)||(e[t]=null);return e}function de(e){const t=Vn(null);for(const[r,n]of Hn(e))ne(e,r)&&(Array.isArray(n)?t[r]=Ma(n):n&&typeof n=="object"&&n.constructor===Object?t[r]=de(n):t[r]=n);return t}function rt(e,t){for(;e!==null;){const n=ka(e,t);if(n){if(n.get)return K(n.get);if(typeof n.value=="function")return K(n.value)}e=Ra(e)}function r(){return null}return r}const on=q(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","search","section","select","shadow","slot","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),rr=q(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","enterkeyhint","exportparts","filter","font","g","glyph","glyphref","hkern","image","inputmode","line","lineargradient","marker","mask","metadata","mpath","part","path","pattern","polygon","polyline","radialgradient","rect","slot","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),nr=q(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),La=q(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),or=q(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),Fa=q(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),an=q(["#text"]),sn=q(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","exportparts","face","for","headers","height","hidden","high","href","hreflang","id","inert","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","part","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","slot","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns","slot"]),ar=q(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),ln=q(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),vt=q(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),za=Q(/\{\{[\w\W]*|[\w\W]*\}\}/gm),Ba=Q(/<%[\w\W]*|[\w\W]*%>/gm),Ua=Q(/\$\{[\w\W]*/gm),Wa=Q(/^data-[\-\w.\u00B7-\uFFFF]+$/),Ha=Q(/^aria-[\-\w]+$/),Gn=Q(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),Va=Q(/^(?:\w+script|data):/i),Ga=Q(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),jn=Q(/^html$/i),ja=Q(/^[a-z][.\w]*(-[.\w]+)+$/i);var cn=Object.freeze({__proto__:null,ARIA_ATTR:Ha,ATTR_WHITESPACE:Ga,CUSTOM_ELEMENT:ja,DATA_ATTR:Wa,DOCTYPE_NAME:jn,ERB_EXPR:Ba,IS_ALLOWED_URI:Gn,IS_SCRIPT_OR_DATA:Va,MUSTACHE_EXPR:za,TMPLIT_EXPR:Ua});const nt={element:1,text:3,progressingInstruction:7,comment:8,document:9},Ya=function(){return typeof window>"u"?null:window},qa=function(t,r){if(typeof t!="object"||typeof t.createPolicy!="function")return null;let n=null;const o="data-tt-policy-suffix";r&&r.hasAttribute(o)&&(n=r.getAttribute(o));const i="dompurify"+(n?"#"+n:"");try{return t.createPolicy(i,{createHTML(l){return l},createScriptURL(l){return l}})}catch{return console.warn("TrustedTypes policy "+i+" could not be created."),null}},un=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}};function Yn(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Ya();const t=h=>Yn(h);if(t.version="3.2.7",t.removed=[],!e||!e.document||e.document.nodeType!==nt.document||!e.Element)return t.isSupported=!1,t;let{document:r}=e;const n=r,o=n.currentScript,{DocumentFragment:i,HTMLTemplateElement:l,Node:d,Element:u,NodeFilter:m,NamedNodeMap:p=e.NamedNodeMap||e.MozNamedAttrMap,HTMLFormElement:T,DOMParser:w,trustedTypes:v}=e,A=u.prototype,$=rt(A,"cloneNode"),G=rt(A,"remove"),D=rt(A,"nextSibling"),P=rt(A,"childNodes"),_=rt(A,"parentNode");if(typeof l=="function"){const h=r.createElement("template");h.content&&h.content.ownerDocument&&(r=h.content.ownerDocument)}let b,R="";const{implementation:x,createNodeIterator:y,createDocumentFragment:he,getElementsByTagName:_e}=r,{importNode:Ft}=n;let U=un();t.isSupported=typeof Hn=="function"&&typeof _=="function"&&x&&x.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:je,ERB_EXPR:Ye,TMPLIT_EXPR:qe,DATA_ATTR:zt,ARIA_ATTR:Bt,IS_SCRIPT_OR_DATA:Ke,ATTR_WHITESPACE:Xe,CUSTOM_ELEMENT:J}=cn;let{IS_ALLOWED_URI:ye}=cn,O=null;const ee=E({},[...on,...rr,...nr,...or,...an]);let M=null;const Ie=E({},[...sn,...ar,...ln,...vt]);let I=Object.seal(Vn(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),te=null,pe=null,ge=!0,re=!0,Re=!1,ve=!0,j=!1,lt=!0,Ee=!1,Ut=!1,Wt=!1,ke=!1,ct=!1,ut=!1,Sr=!0,Tr=!1;const eo="user-content-";let Ht=!0,Ze=!1,Pe={},Oe=null;const wr=E({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let xr=null;const Cr=E({},["audio","video","img","source","image","track"]);let Vt=null;const Ar=E({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),dt="http://www.w3.org/1998/Math/MathML",ft="http://www.w3.org/2000/svg",le="http://www.w3.org/1999/xhtml";let Ne=le,Gt=!1,jt=null;const to=E({},[dt,ft,le],er);let mt=E({},["mi","mo","mn","ms","mtext"]),ht=E({},["annotation-xml"]);const ro=E({},["title","style","font","a","script"]);let Qe=null;const no=["application/xhtml+xml","text/html"],oo="text/html";let z=null,$e=null;const ao=r.createElement("form"),_r=function(a){return a instanceof RegExp||a instanceof Function},Yt=function(){let a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!($e&&$e===a)){if((!a||typeof a!="object")&&(a={}),a=de(a),Qe=no.indexOf(a.PARSER_MEDIA_TYPE)===-1?oo:a.PARSER_MEDIA_TYPE,z=Qe==="application/xhtml+xml"?er:At,O=ne(a,"ALLOWED_TAGS")?E({},a.ALLOWED_TAGS,z):ee,M=ne(a,"ALLOWED_ATTR")?E({},a.ALLOWED_ATTR,z):Ie,jt=ne(a,"ALLOWED_NAMESPACES")?E({},a.ALLOWED_NAMESPACES,er):to,Vt=ne(a,"ADD_URI_SAFE_ATTR")?E(de(Ar),a.ADD_URI_SAFE_ATTR,z):Ar,xr=ne(a,"ADD_DATA_URI_TAGS")?E(de(Cr),a.ADD_DATA_URI_TAGS,z):Cr,Oe=ne(a,"FORBID_CONTENTS")?E({},a.FORBID_CONTENTS,z):wr,te=ne(a,"FORBID_TAGS")?E({},a.FORBID_TAGS,z):de({}),pe=ne(a,"FORBID_ATTR")?E({},a.FORBID_ATTR,z):de({}),Pe=ne(a,"USE_PROFILES")?a.USE_PROFILES:!1,ge=a.ALLOW_ARIA_ATTR!==!1,re=a.ALLOW_DATA_ATTR!==!1,Re=a.ALLOW_UNKNOWN_PROTOCOLS||!1,ve=a.ALLOW_SELF_CLOSE_IN_ATTR!==!1,j=a.SAFE_FOR_TEMPLATES||!1,lt=a.SAFE_FOR_XML!==!1,Ee=a.WHOLE_DOCUMENT||!1,ke=a.RETURN_DOM||!1,ct=a.RETURN_DOM_FRAGMENT||!1,ut=a.RETURN_TRUSTED_TYPE||!1,Wt=a.FORCE_BODY||!1,Sr=a.SANITIZE_DOM!==!1,Tr=a.SANITIZE_NAMED_PROPS||!1,Ht=a.KEEP_CONTENT!==!1,Ze=a.IN_PLACE||!1,ye=a.ALLOWED_URI_REGEXP||Gn,Ne=a.NAMESPACE||le,mt=a.MATHML_TEXT_INTEGRATION_POINTS||mt,ht=a.HTML_INTEGRATION_POINTS||ht,I=a.CUSTOM_ELEMENT_HANDLING||{},a.CUSTOM_ELEMENT_HANDLING&&_r(a.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(I.tagNameCheck=a.CUSTOM_ELEMENT_HANDLING.tagNameCheck),a.CUSTOM_ELEMENT_HANDLING&&_r(a.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(I.attributeNameCheck=a.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),a.CUSTOM_ELEMENT_HANDLING&&typeof a.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(I.allowCustomizedBuiltInElements=a.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),j&&(re=!1),ct&&(ke=!0),Pe&&(O=E({},an),M=[],Pe.html===!0&&(E(O,on),E(M,sn)),Pe.svg===!0&&(E(O,rr),E(M,ar),E(M,vt)),Pe.svgFilters===!0&&(E(O,nr),E(M,ar),E(M,vt)),Pe.mathMl===!0&&(E(O,or),E(M,ln),E(M,vt))),a.ADD_TAGS&&(O===ee&&(O=de(O)),E(O,a.ADD_TAGS,z)),a.ADD_ATTR&&(M===Ie&&(M=de(M)),E(M,a.ADD_ATTR,z)),a.ADD_URI_SAFE_ATTR&&E(Vt,a.ADD_URI_SAFE_ATTR,z),a.FORBID_CONTENTS&&(Oe===wr&&(Oe=de(Oe)),E(Oe,a.FORBID_CONTENTS,z)),Ht&&(O["#text"]=!0),Ee&&E(O,["html","head","body"]),O.table&&(E(O,["tbody"]),delete te.tbody),a.TRUSTED_TYPES_POLICY){if(typeof a.TRUSTED_TYPES_POLICY.createHTML!="function")throw tt('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof a.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw tt('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');b=a.TRUSTED_TYPES_POLICY,R=b.createHTML("")}else b===void 0&&(b=qa(v,o)),b!==null&&typeof R=="string"&&(R=b.createHTML(""));q&&q(a),$e=a}},Ir=E({},[...rr,...nr,...La]),Rr=E({},[...or,...Fa]),io=function(a){let c=_(a);(!c||!c.tagName)&&(c={namespaceURI:Ne,tagName:"template"});const f=At(a.tagName),N=At(c.tagName);return jt[a.namespaceURI]?a.namespaceURI===ft?c.namespaceURI===le?f==="svg":c.namespaceURI===dt?f==="svg"&&(N==="annotation-xml"||mt[N]):!!Ir[f]:a.namespaceURI===dt?c.namespaceURI===le?f==="math":c.namespaceURI===ft?f==="math"&&ht[N]:!!Rr[f]:a.namespaceURI===le?c.namespaceURI===ft&&!ht[N]||c.namespaceURI===dt&&!mt[N]?!1:!Rr[f]&&(ro[f]||!Ir[f]):!!(Qe==="application/xhtml+xml"&&jt[a.namespaceURI]):!1},ae=function(a){Je(t.removed,{element:a});try{_(a).removeChild(a)}catch{G(a)}},Se=function(a,c){try{Je(t.removed,{attribute:c.getAttributeNode(a),from:c})}catch{Je(t.removed,{attribute:null,from:c})}if(c.removeAttribute(a),a==="is")if(ke||ct)try{ae(c)}catch{}else try{c.setAttribute(a,"")}catch{}},kr=function(a){let c=null,f=null;if(Wt)a="<remove></remove>"+a;else{const L=tr(a,/^[\r\n\t ]+/);f=L&&L[0]}Qe==="application/xhtml+xml"&&Ne===le&&(a='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+a+"</body></html>");const N=b?b.createHTML(a):a;if(Ne===le)try{c=new w().parseFromString(N,Qe)}catch{}if(!c||!c.documentElement){c=x.createDocument(Ne,"template",null);try{c.documentElement.innerHTML=Gt?R:N}catch{}}const H=c.body||c.documentElement;return a&&f&&H.insertBefore(r.createTextNode(f),H.childNodes[0]||null),Ne===le?_e.call(c,Ee?"html":"body")[0]:Ee?c.documentElement:H},Pr=function(a){return y.call(a.ownerDocument||a,a,m.SHOW_ELEMENT|m.SHOW_COMMENT|m.SHOW_TEXT|m.SHOW_PROCESSING_INSTRUCTION|m.SHOW_CDATA_SECTION,null)},qt=function(a){return a instanceof T&&(typeof a.nodeName!="string"||typeof a.textContent!="string"||typeof a.removeChild!="function"||!(a.attributes instanceof p)||typeof a.removeAttribute!="function"||typeof a.setAttribute!="function"||typeof a.namespaceURI!="string"||typeof a.insertBefore!="function"||typeof a.hasChildNodes!="function")},Or=function(a){return typeof d=="function"&&a instanceof d};function ce(h,a,c){yt(h,f=>{f.call(t,a,c,$e)})}const Nr=function(a){let c=null;if(ce(U.beforeSanitizeElements,a,null),qt(a))return ae(a),!0;const f=z(a.nodeName);if(ce(U.uponSanitizeElement,a,{tagName:f,allowedTags:O}),lt&&a.hasChildNodes()&&!Or(a.firstElementChild)&&Y(/<[/\w!]/g,a.innerHTML)&&Y(/<[/\w!]/g,a.textContent)||a.nodeType===nt.progressingInstruction||lt&&a.nodeType===nt.comment&&Y(/<[/\w]/g,a.data))return ae(a),!0;if(!O[f]||te[f]){if(!te[f]&&Dr(f)&&(I.tagNameCheck instanceof RegExp&&Y(I.tagNameCheck,f)||I.tagNameCheck instanceof Function&&I.tagNameCheck(f)))return!1;if(Ht&&!Oe[f]){const N=_(a)||a.parentNode,H=P(a)||a.childNodes;if(H&&N){const L=H.length;for(let X=L-1;X>=0;--X){const ue=$(H[X],!0);ue.__removalCount=(a.__removalCount||0)+1,N.insertBefore(ue,D(a))}}}return ae(a),!0}return a instanceof u&&!io(a)||(f==="noscript"||f==="noembed"||f==="noframes")&&Y(/<\/no(script|embed|frames)/i,a.innerHTML)?(ae(a),!0):(j&&a.nodeType===nt.text&&(c=a.textContent,yt([je,Ye,qe],N=>{c=et(c,N," ")}),a.textContent!==c&&(Je(t.removed,{element:a.cloneNode()}),a.textContent=c)),ce(U.afterSanitizeElements,a,null),!1)},$r=function(a,c,f){if(Sr&&(c==="id"||c==="name")&&(f in r||f in ao))return!1;if(!(re&&!pe[c]&&Y(zt,c))){if(!(ge&&Y(Bt,c))){if(!M[c]||pe[c]){if(!(Dr(a)&&(I.tagNameCheck instanceof RegExp&&Y(I.tagNameCheck,a)||I.tagNameCheck instanceof Function&&I.tagNameCheck(a))&&(I.attributeNameCheck instanceof RegExp&&Y(I.attributeNameCheck,c)||I.attributeNameCheck instanceof Function&&I.attributeNameCheck(c,a))||c==="is"&&I.allowCustomizedBuiltInElements&&(I.tagNameCheck instanceof RegExp&&Y(I.tagNameCheck,f)||I.tagNameCheck instanceof Function&&I.tagNameCheck(f))))return!1}else if(!Vt[c]){if(!Y(ye,et(f,Xe,""))){if(!((c==="src"||c==="xlink:href"||c==="href")&&a!=="script"&&Na(f,"data:")===0&&xr[a])){if(!(Re&&!Y(Ke,et(f,Xe,"")))){if(f)return!1}}}}}}return!0},Dr=function(a){return a!=="annotation-xml"&&tr(a,J)},Mr=function(a){ce(U.beforeSanitizeAttributes,a,null);const{attributes:c}=a;if(!c||qt(a))return;const f={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:M,forceKeepAttr:void 0};let N=c.length;for(;N--;){const H=c[N],{name:L,namespaceURI:X,value:ue}=H,De=z(L),Kt=ue;let W=L==="value"?Kt:$a(Kt);if(f.attrName=De,f.attrValue=W,f.keepAttr=!0,f.forceKeepAttr=void 0,ce(U.uponSanitizeAttribute,a,f),W=f.attrValue,Tr&&(De==="id"||De==="name")&&(Se(L,a),W=eo+W),lt&&Y(/((--!?|])>)|<\/(style|title|textarea)/i,W)){Se(L,a);continue}if(De==="attributename"&&tr(W,"href")){Se(L,a);continue}if(f.forceKeepAttr)continue;if(!f.keepAttr){Se(L,a);continue}if(!ve&&Y(/\/>/i,W)){Se(L,a);continue}j&&yt([je,Ye,qe],Fr=>{W=et(W,Fr," ")});const Lr=z(a.nodeName);if(!$r(Lr,De,W)){Se(L,a);continue}if(b&&typeof v=="object"&&typeof v.getAttributeType=="function"&&!X)switch(v.getAttributeType(Lr,De)){case"TrustedHTML":{W=b.createHTML(W);break}case"TrustedScriptURL":{W=b.createScriptURL(W);break}}if(W!==Kt)try{X?a.setAttributeNS(X,L,W):a.setAttribute(L,W),qt(a)?ae(a):nn(t.removed)}catch{Se(L,a)}}ce(U.afterSanitizeAttributes,a,null)},so=function h(a){let c=null;const f=Pr(a);for(ce(U.beforeSanitizeShadowDOM,a,null);c=f.nextNode();)ce(U.uponSanitizeShadowNode,c,null),Nr(c),Mr(c),c.content instanceof i&&h(c.content);ce(U.afterSanitizeShadowDOM,a,null)};return t.sanitize=function(h){let a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},c=null,f=null,N=null,H=null;if(Gt=!h,Gt&&(h="<!-->"),typeof h!="string"&&!Or(h))if(typeof h.toString=="function"){if(h=h.toString(),typeof h!="string")throw tt("dirty is not a string, aborting")}else throw tt("toString is not a function");if(!t.isSupported)return h;if(Ut||Yt(a),t.removed=[],typeof h=="string"&&(Ze=!1),Ze){if(h.nodeName){const ue=z(h.nodeName);if(!O[ue]||te[ue])throw tt("root node is forbidden and cannot be sanitized in-place")}}else if(h instanceof d)c=kr("<!---->"),f=c.ownerDocument.importNode(h,!0),f.nodeType===nt.element&&f.nodeName==="BODY"||f.nodeName==="HTML"?c=f:c.appendChild(f);else{if(!ke&&!j&&!Ee&&h.indexOf("<")===-1)return b&&ut?b.createHTML(h):h;if(c=kr(h),!c)return ke?null:ut?R:""}c&&Wt&&ae(c.firstChild);const L=Pr(Ze?h:c);for(;N=L.nextNode();)Nr(N),Mr(N),N.content instanceof i&&so(N.content);if(Ze)return h;if(ke){if(ct)for(H=he.call(c.ownerDocument);c.firstChild;)H.appendChild(c.firstChild);else H=c;return(M.shadowroot||M.shadowrootmode)&&(H=Ft.call(n,H,!0)),H}let X=Ee?c.outerHTML:c.innerHTML;return Ee&&O["!doctype"]&&c.ownerDocument&&c.ownerDocument.doctype&&c.ownerDocument.doctype.name&&Y(jn,c.ownerDocument.doctype.name)&&(X="<!DOCTYPE "+c.ownerDocument.doctype.name+`>
|
|
82
|
-
`+X),j&&
|
|
81
|
+
`,Io=v.li(e=>{const t=le(e.colorVariant),r=Bn(e.colorVariant),n=e.shouldBeFilled?t:"var(--color-base-300)",a=e.shouldBeFilled?r:"var(--color-base-content)";return{textAlign:"center","--step-bg":n,"--step-fg":a,gridTemplateRows:"40px 1fr",gridTemplateColumns:"auto",gap:".5rem",placeItems:"center",minWidth:"4rem",display:"grid","&:not(:first-of-type):before":{width:"100%",height:"0.5rem",color:"var(--step-bg)",backgroundColor:"var(--step-bg)","--tw-content":"''",content:"var(--tw-content)",border:"1px solid",gridRowStart:"1",gridColumnStart:"1",marginInlineStart:"-100%"},"&:after":{content:"counter(step)",counterIncrement:"step",zIndex:"1",color:"var(--step-fg)",backgroundColor:"var(--step-bg)",border:"1px solid var(--step-bg)",borderRadius:"3.40282e38px",gridRowStart:"1",gridColumnStart:"1",placeSelf:"center",placeItems:"center",width:"2rem",height:"2rem",display:"grid",position:"relative"}}}),Vn=e=>(console.log("props.currentStepIndex",e.currentStepIndex),s.createElement(_o,{children:[e.steps.map((t,r)=>s.createElement(Io,{key:t.title,colorVariant:e.colorVariant,shouldBeFilled:e.currentStepIndex>=r,children:t.title}))]})),Ro={title:{marginTop:"0",marginBottom:".888889em",fontWeight:"700",fontSize:"2.25em",lineHeight:"1.11111"},subtitle:{marginTop:"2em",fontWeight:"700",marginBottom:"1em",fontSize:"1.5em",lineHeight:"1.33333"},section:{marginBottom:"1em",fontWeight:"600",fontSize:"1.25em",lineHeight:"1.6"},subsection:{marginTop:"1.5em",marginBottom:".5em",fontWeight:"600",fontSize:"1rem"},paragraph:{marginTop:"0",marginBottom:"1.25em",fontSize:"1rem"}},ko=v.div(e=>({...Ro[e.$variant??"paragraph"],color:e.theme.baseContent,...e.$linear?{margin:"0"}:{}})),oe=e=>s.createElement(ko,{$variant:e.variant,$linear:e.linear,children:e.children}),Po=e=>{switch(e){case"textarea":return"";case"select":return"";case"checkbox-group":return[];case"radio-group":return"";case"matrix":return null;case"range-slide":return null;case"rating":return null;default:return null}},Wn=e=>{const t=s.useMemo(()=>e.form.steps.reduce((l,d,u)=>(l.validationsPerStep[u]={},l.steps=[...l.steps,{...d,fields:d.fields.map(f=>{const p=f.meta.fieldKey;return p?(l.validationsPerStep[u][p]={fieldType:f.type,validations:f.validations},l.state={...l.state,[p]:Po(f.type)},{dataField:p,...f}):{...f,dataField:null}})}],l),{validationsPerStep:{},state:{},steps:[]}),[e.form]),[r,n]=s.useState(t.state),a=s.useCallback((l,d)=>{l!==null&&n(u=>({...u,[l]:d}))},[n]),i=s.useCallback(l=>l?r[l]:null,[r]);return{steps:t.steps,validationsPerStep:t.validationsPerStep,state:r,setStateByKey:a,getStateByKey:i}},Oo=wo(),No=(e,t)=>Oo.post("/feedback-receiver",e,t);/*! @license DOMPurify 3.2.7 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.2.7/LICENSE */const{entries:Hn,setPrototypeOf:rn,isFrozen:$o,getPrototypeOf:Do,getOwnPropertyDescriptor:Mo}=Object;let{freeze:q,seal:Q,create:Gn}=Object,{apply:hr,construct:pr}=typeof Reflect<"u"&&Reflect;q||(q=function(t){return t});Q||(Q=function(t){return t});hr||(hr=function(t,r){for(var n=arguments.length,a=new Array(n>2?n-2:0),i=2;i<n;i++)a[i-2]=arguments[i];return t.apply(r,a)});pr||(pr=function(t){for(var r=arguments.length,n=new Array(r>1?r-1:0),a=1;a<r;a++)n[a-1]=arguments[a];return new t(...n)});const vt=K(Array.prototype.forEach),Lo=K(Array.prototype.lastIndexOf),nn=K(Array.prototype.pop),et=K(Array.prototype.push),Fo=K(Array.prototype.splice),_t=K(String.prototype.toLowerCase),tr=K(String.prototype.toString),rr=K(String.prototype.match),tt=K(String.prototype.replace),zo=K(String.prototype.indexOf),Bo=K(String.prototype.trim),ne=K(Object.prototype.hasOwnProperty),Y=K(RegExp.prototype.test),rt=Uo(TypeError);function K(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);for(var r=arguments.length,n=new Array(r>1?r-1:0),a=1;a<r;a++)n[a-1]=arguments[a];return hr(e,t,n)}}function Uo(e){return function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return pr(e,r)}}function S(e,t){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:_t;rn&&rn(e,null);let n=t.length;for(;n--;){let a=t[n];if(typeof a=="string"){const i=r(a);i!==a&&($o(t)||(t[n]=i),a=i)}e[a]=!0}return e}function Vo(e){for(let t=0;t<e.length;t++)ne(e,t)||(e[t]=null);return e}function me(e){const t=Gn(null);for(const[r,n]of Hn(e))ne(e,r)&&(Array.isArray(n)?t[r]=Vo(n):n&&typeof n=="object"&&n.constructor===Object?t[r]=me(n):t[r]=n);return t}function nt(e,t){for(;e!==null;){const n=Mo(e,t);if(n){if(n.get)return K(n.get);if(typeof n.value=="function")return K(n.value)}e=Do(e)}function r(){return null}return r}const an=q(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","search","section","select","shadow","slot","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),nr=q(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","enterkeyhint","exportparts","filter","font","g","glyph","glyphref","hkern","image","inputmode","line","lineargradient","marker","mask","metadata","mpath","part","path","pattern","polygon","polyline","radialgradient","rect","slot","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),ar=q(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),Wo=q(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),or=q(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),Ho=q(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),on=q(["#text"]),sn=q(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","exportparts","face","for","headers","height","hidden","high","href","hreflang","id","inert","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","part","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","slot","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns","slot"]),ir=q(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),ln=q(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),Et=q(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),Go=Q(/\{\{[\w\W]*|[\w\W]*\}\}/gm),jo=Q(/<%[\w\W]*|[\w\W]*%>/gm),Yo=Q(/\$\{[\w\W]*/gm),qo=Q(/^data-[\-\w.\u00B7-\uFFFF]+$/),Ko=Q(/^aria-[\-\w]+$/),jn=Q(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),Xo=Q(/^(?:\w+script|data):/i),Zo=Q(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),Yn=Q(/^html$/i),Qo=Q(/^[a-z][.\w]*(-[.\w]+)+$/i);var cn=Object.freeze({__proto__:null,ARIA_ATTR:Ko,ATTR_WHITESPACE:Zo,CUSTOM_ELEMENT:Qo,DATA_ATTR:qo,DOCTYPE_NAME:Yn,ERB_EXPR:jo,IS_ALLOWED_URI:jn,IS_SCRIPT_OR_DATA:Xo,MUSTACHE_EXPR:Go,TMPLIT_EXPR:Yo});const at={element:1,text:3,progressingInstruction:7,comment:8,document:9},Jo=function(){return typeof window>"u"?null:window},ei=function(t,r){if(typeof t!="object"||typeof t.createPolicy!="function")return null;let n=null;const a="data-tt-policy-suffix";r&&r.hasAttribute(a)&&(n=r.getAttribute(a));const i="dompurify"+(n?"#"+n:"");try{return t.createPolicy(i,{createHTML(l){return l},createScriptURL(l){return l}})}catch{return console.warn("TrustedTypes policy "+i+" could not be created."),null}},un=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}};function qn(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Jo();const t=h=>qn(h);if(t.version="3.2.7",t.removed=[],!e||!e.document||e.document.nodeType!==at.document||!e.Element)return t.isSupported=!1,t;let{document:r}=e;const n=r,a=n.currentScript,{DocumentFragment:i,HTMLTemplateElement:l,Node:d,Element:u,NodeFilter:f,NamedNodeMap:p=e.NamedNodeMap||e.MozNamedAttrMap,HTMLFormElement:T,DOMParser:w,trustedTypes:E}=e,A=u.prototype,$=nt(A,"cloneNode"),G=nt(A,"remove"),D=nt(A,"nextSibling"),P=nt(A,"childNodes"),_=nt(A,"parentNode");if(typeof l=="function"){const h=r.createElement("template");h.content&&h.content.ownerDocument&&(r=h.content.ownerDocument)}let b,R="";const{implementation:x,createNodeIterator:y,createDocumentFragment:pe,getElementsByTagName:Re}=r,{importNode:zt}=n;let U=un();t.isSupported=typeof Hn=="function"&&typeof _=="function"&&x&&x.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:Ye,ERB_EXPR:qe,TMPLIT_EXPR:Ke,DATA_ATTR:Bt,ARIA_ATTR:Ut,IS_SCRIPT_OR_DATA:Xe,ATTR_WHITESPACE:Ze,CUSTOM_ELEMENT:J}=cn;let{IS_ALLOWED_URI:ve}=cn,O=null;const ee=S({},[...an,...nr,...ar,...or,...on]);let M=null;const ke=S({},[...sn,...ir,...ln,...Et]);let I=Object.seal(Gn(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),te=null,ge=null,be=!0,re=!0,Pe=!1,Ee=!0,j=!1,ct=!0,Se=!1,Vt=!1,Wt=!1,Oe=!1,ut=!1,dt=!1,Sr=!0,Tr=!1;const ia="user-content-";let Ht=!0,Qe=!1,Ne={},$e=null;const wr=S({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let xr=null;const Cr=S({},["audio","video","img","source","image","track"]);let Gt=null;const Ar=S({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),mt="http://www.w3.org/1998/Math/MathML",ft="http://www.w3.org/2000/svg",ce="http://www.w3.org/1999/xhtml";let De=ce,jt=!1,Yt=null;const sa=S({},[mt,ft,ce],tr);let ht=S({},["mi","mo","mn","ms","mtext"]),pt=S({},["annotation-xml"]);const la=S({},["title","style","font","a","script"]);let Je=null;const ca=["application/xhtml+xml","text/html"],ua="text/html";let z=null,Me=null;const da=r.createElement("form"),_r=function(o){return o instanceof RegExp||o instanceof Function},qt=function(){let o=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(Me&&Me===o)){if((!o||typeof o!="object")&&(o={}),o=me(o),Je=ca.indexOf(o.PARSER_MEDIA_TYPE)===-1?ua:o.PARSER_MEDIA_TYPE,z=Je==="application/xhtml+xml"?tr:_t,O=ne(o,"ALLOWED_TAGS")?S({},o.ALLOWED_TAGS,z):ee,M=ne(o,"ALLOWED_ATTR")?S({},o.ALLOWED_ATTR,z):ke,Yt=ne(o,"ALLOWED_NAMESPACES")?S({},o.ALLOWED_NAMESPACES,tr):sa,Gt=ne(o,"ADD_URI_SAFE_ATTR")?S(me(Ar),o.ADD_URI_SAFE_ATTR,z):Ar,xr=ne(o,"ADD_DATA_URI_TAGS")?S(me(Cr),o.ADD_DATA_URI_TAGS,z):Cr,$e=ne(o,"FORBID_CONTENTS")?S({},o.FORBID_CONTENTS,z):wr,te=ne(o,"FORBID_TAGS")?S({},o.FORBID_TAGS,z):me({}),ge=ne(o,"FORBID_ATTR")?S({},o.FORBID_ATTR,z):me({}),Ne=ne(o,"USE_PROFILES")?o.USE_PROFILES:!1,be=o.ALLOW_ARIA_ATTR!==!1,re=o.ALLOW_DATA_ATTR!==!1,Pe=o.ALLOW_UNKNOWN_PROTOCOLS||!1,Ee=o.ALLOW_SELF_CLOSE_IN_ATTR!==!1,j=o.SAFE_FOR_TEMPLATES||!1,ct=o.SAFE_FOR_XML!==!1,Se=o.WHOLE_DOCUMENT||!1,Oe=o.RETURN_DOM||!1,ut=o.RETURN_DOM_FRAGMENT||!1,dt=o.RETURN_TRUSTED_TYPE||!1,Wt=o.FORCE_BODY||!1,Sr=o.SANITIZE_DOM!==!1,Tr=o.SANITIZE_NAMED_PROPS||!1,Ht=o.KEEP_CONTENT!==!1,Qe=o.IN_PLACE||!1,ve=o.ALLOWED_URI_REGEXP||jn,De=o.NAMESPACE||ce,ht=o.MATHML_TEXT_INTEGRATION_POINTS||ht,pt=o.HTML_INTEGRATION_POINTS||pt,I=o.CUSTOM_ELEMENT_HANDLING||{},o.CUSTOM_ELEMENT_HANDLING&&_r(o.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(I.tagNameCheck=o.CUSTOM_ELEMENT_HANDLING.tagNameCheck),o.CUSTOM_ELEMENT_HANDLING&&_r(o.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(I.attributeNameCheck=o.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),o.CUSTOM_ELEMENT_HANDLING&&typeof o.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(I.allowCustomizedBuiltInElements=o.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),j&&(re=!1),ut&&(Oe=!0),Ne&&(O=S({},on),M=[],Ne.html===!0&&(S(O,an),S(M,sn)),Ne.svg===!0&&(S(O,nr),S(M,ir),S(M,Et)),Ne.svgFilters===!0&&(S(O,ar),S(M,ir),S(M,Et)),Ne.mathMl===!0&&(S(O,or),S(M,ln),S(M,Et))),o.ADD_TAGS&&(O===ee&&(O=me(O)),S(O,o.ADD_TAGS,z)),o.ADD_ATTR&&(M===ke&&(M=me(M)),S(M,o.ADD_ATTR,z)),o.ADD_URI_SAFE_ATTR&&S(Gt,o.ADD_URI_SAFE_ATTR,z),o.FORBID_CONTENTS&&($e===wr&&($e=me($e)),S($e,o.FORBID_CONTENTS,z)),Ht&&(O["#text"]=!0),Se&&S(O,["html","head","body"]),O.table&&(S(O,["tbody"]),delete te.tbody),o.TRUSTED_TYPES_POLICY){if(typeof o.TRUSTED_TYPES_POLICY.createHTML!="function")throw rt('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof o.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw rt('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');b=o.TRUSTED_TYPES_POLICY,R=b.createHTML("")}else b===void 0&&(b=ei(E,a)),b!==null&&typeof R=="string"&&(R=b.createHTML(""));q&&q(o),Me=o}},Ir=S({},[...nr,...ar,...Wo]),Rr=S({},[...or,...Ho]),ma=function(o){let c=_(o);(!c||!c.tagName)&&(c={namespaceURI:De,tagName:"template"});const m=_t(o.tagName),N=_t(c.tagName);return Yt[o.namespaceURI]?o.namespaceURI===ft?c.namespaceURI===ce?m==="svg":c.namespaceURI===mt?m==="svg"&&(N==="annotation-xml"||ht[N]):!!Ir[m]:o.namespaceURI===mt?c.namespaceURI===ce?m==="math":c.namespaceURI===ft?m==="math"&&pt[N]:!!Rr[m]:o.namespaceURI===ce?c.namespaceURI===ft&&!pt[N]||c.namespaceURI===mt&&!ht[N]?!1:!Rr[m]&&(la[m]||!Ir[m]):!!(Je==="application/xhtml+xml"&&Yt[o.namespaceURI]):!1},ie=function(o){et(t.removed,{element:o});try{_(o).removeChild(o)}catch{G(o)}},Te=function(o,c){try{et(t.removed,{attribute:c.getAttributeNode(o),from:c})}catch{et(t.removed,{attribute:null,from:c})}if(c.removeAttribute(o),o==="is")if(Oe||ut)try{ie(c)}catch{}else try{c.setAttribute(o,"")}catch{}},kr=function(o){let c=null,m=null;if(Wt)o="<remove></remove>"+o;else{const L=rr(o,/^[\r\n\t ]+/);m=L&&L[0]}Je==="application/xhtml+xml"&&De===ce&&(o='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+o+"</body></html>");const N=b?b.createHTML(o):o;if(De===ce)try{c=new w().parseFromString(N,Je)}catch{}if(!c||!c.documentElement){c=x.createDocument(De,"template",null);try{c.documentElement.innerHTML=jt?R:N}catch{}}const W=c.body||c.documentElement;return o&&m&&W.insertBefore(r.createTextNode(m),W.childNodes[0]||null),De===ce?Re.call(c,Se?"html":"body")[0]:Se?c.documentElement:W},Pr=function(o){return y.call(o.ownerDocument||o,o,f.SHOW_ELEMENT|f.SHOW_COMMENT|f.SHOW_TEXT|f.SHOW_PROCESSING_INSTRUCTION|f.SHOW_CDATA_SECTION,null)},Kt=function(o){return o instanceof T&&(typeof o.nodeName!="string"||typeof o.textContent!="string"||typeof o.removeChild!="function"||!(o.attributes instanceof p)||typeof o.removeAttribute!="function"||typeof o.setAttribute!="function"||typeof o.namespaceURI!="string"||typeof o.insertBefore!="function"||typeof o.hasChildNodes!="function")},Or=function(o){return typeof d=="function"&&o instanceof d};function ue(h,o,c){vt(h,m=>{m.call(t,o,c,Me)})}const Nr=function(o){let c=null;if(ue(U.beforeSanitizeElements,o,null),Kt(o))return ie(o),!0;const m=z(o.nodeName);if(ue(U.uponSanitizeElement,o,{tagName:m,allowedTags:O}),ct&&o.hasChildNodes()&&!Or(o.firstElementChild)&&Y(/<[/\w!]/g,o.innerHTML)&&Y(/<[/\w!]/g,o.textContent)||o.nodeType===at.progressingInstruction||ct&&o.nodeType===at.comment&&Y(/<[/\w]/g,o.data))return ie(o),!0;if(!O[m]||te[m]){if(!te[m]&&Dr(m)&&(I.tagNameCheck instanceof RegExp&&Y(I.tagNameCheck,m)||I.tagNameCheck instanceof Function&&I.tagNameCheck(m)))return!1;if(Ht&&!$e[m]){const N=_(o)||o.parentNode,W=P(o)||o.childNodes;if(W&&N){const L=W.length;for(let X=L-1;X>=0;--X){const de=$(W[X],!0);de.__removalCount=(o.__removalCount||0)+1,N.insertBefore(de,D(o))}}}return ie(o),!0}return o instanceof u&&!ma(o)||(m==="noscript"||m==="noembed"||m==="noframes")&&Y(/<\/no(script|embed|frames)/i,o.innerHTML)?(ie(o),!0):(j&&o.nodeType===at.text&&(c=o.textContent,vt([Ye,qe,Ke],N=>{c=tt(c,N," ")}),o.textContent!==c&&(et(t.removed,{element:o.cloneNode()}),o.textContent=c)),ue(U.afterSanitizeElements,o,null),!1)},$r=function(o,c,m){if(Sr&&(c==="id"||c==="name")&&(m in r||m in da))return!1;if(!(re&&!ge[c]&&Y(Bt,c))){if(!(be&&Y(Ut,c))){if(!M[c]||ge[c]){if(!(Dr(o)&&(I.tagNameCheck instanceof RegExp&&Y(I.tagNameCheck,o)||I.tagNameCheck instanceof Function&&I.tagNameCheck(o))&&(I.attributeNameCheck instanceof RegExp&&Y(I.attributeNameCheck,c)||I.attributeNameCheck instanceof Function&&I.attributeNameCheck(c,o))||c==="is"&&I.allowCustomizedBuiltInElements&&(I.tagNameCheck instanceof RegExp&&Y(I.tagNameCheck,m)||I.tagNameCheck instanceof Function&&I.tagNameCheck(m))))return!1}else if(!Gt[c]){if(!Y(ve,tt(m,Ze,""))){if(!((c==="src"||c==="xlink:href"||c==="href")&&o!=="script"&&zo(m,"data:")===0&&xr[o])){if(!(Pe&&!Y(Xe,tt(m,Ze,"")))){if(m)return!1}}}}}}return!0},Dr=function(o){return o!=="annotation-xml"&&rr(o,J)},Mr=function(o){ue(U.beforeSanitizeAttributes,o,null);const{attributes:c}=o;if(!c||Kt(o))return;const m={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:M,forceKeepAttr:void 0};let N=c.length;for(;N--;){const W=c[N],{name:L,namespaceURI:X,value:de}=W,Le=z(L),Xt=de;let V=L==="value"?Xt:Bo(Xt);if(m.attrName=Le,m.attrValue=V,m.keepAttr=!0,m.forceKeepAttr=void 0,ue(U.uponSanitizeAttribute,o,m),V=m.attrValue,Tr&&(Le==="id"||Le==="name")&&(Te(L,o),V=ia+V),ct&&Y(/((--!?|])>)|<\/(style|title|textarea)/i,V)){Te(L,o);continue}if(Le==="attributename"&&rr(V,"href")){Te(L,o);continue}if(m.forceKeepAttr)continue;if(!m.keepAttr){Te(L,o);continue}if(!Ee&&Y(/\/>/i,V)){Te(L,o);continue}j&&vt([Ye,qe,Ke],Fr=>{V=tt(V,Fr," ")});const Lr=z(o.nodeName);if(!$r(Lr,Le,V)){Te(L,o);continue}if(b&&typeof E=="object"&&typeof E.getAttributeType=="function"&&!X)switch(E.getAttributeType(Lr,Le)){case"TrustedHTML":{V=b.createHTML(V);break}case"TrustedScriptURL":{V=b.createScriptURL(V);break}}if(V!==Xt)try{X?o.setAttributeNS(X,L,V):o.setAttribute(L,V),Kt(o)?ie(o):nn(t.removed)}catch{Te(L,o)}}ue(U.afterSanitizeAttributes,o,null)},fa=function h(o){let c=null;const m=Pr(o);for(ue(U.beforeSanitizeShadowDOM,o,null);c=m.nextNode();)ue(U.uponSanitizeShadowNode,c,null),Nr(c),Mr(c),c.content instanceof i&&h(c.content);ue(U.afterSanitizeShadowDOM,o,null)};return t.sanitize=function(h){let o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},c=null,m=null,N=null,W=null;if(jt=!h,jt&&(h="<!-->"),typeof h!="string"&&!Or(h))if(typeof h.toString=="function"){if(h=h.toString(),typeof h!="string")throw rt("dirty is not a string, aborting")}else throw rt("toString is not a function");if(!t.isSupported)return h;if(Vt||qt(o),t.removed=[],typeof h=="string"&&(Qe=!1),Qe){if(h.nodeName){const de=z(h.nodeName);if(!O[de]||te[de])throw rt("root node is forbidden and cannot be sanitized in-place")}}else if(h instanceof d)c=kr("<!---->"),m=c.ownerDocument.importNode(h,!0),m.nodeType===at.element&&m.nodeName==="BODY"||m.nodeName==="HTML"?c=m:c.appendChild(m);else{if(!Oe&&!j&&!Se&&h.indexOf("<")===-1)return b&&dt?b.createHTML(h):h;if(c=kr(h),!c)return Oe?null:dt?R:""}c&&Wt&&ie(c.firstChild);const L=Pr(Qe?h:c);for(;N=L.nextNode();)Nr(N),Mr(N),N.content instanceof i&&fa(N.content);if(Qe)return h;if(Oe){if(ut)for(W=pe.call(c.ownerDocument);c.firstChild;)W.appendChild(c.firstChild);else W=c;return(M.shadowroot||M.shadowrootmode)&&(W=zt.call(n,W,!0)),W}let X=Se?c.outerHTML:c.innerHTML;return Se&&O["!doctype"]&&c.ownerDocument&&c.ownerDocument.doctype&&c.ownerDocument.doctype.name&&Y(Yn,c.ownerDocument.doctype.name)&&(X="<!DOCTYPE "+c.ownerDocument.doctype.name+`>
|
|
82
|
+
`+X),j&&vt([Ye,qe,Ke],de=>{X=tt(X,de," ")}),b&&dt?b.createHTML(X):X},t.setConfig=function(){let h=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};qt(h),Vt=!0},t.clearConfig=function(){Me=null,Vt=!1},t.isValidAttribute=function(h,o,c){Me||qt({});const m=z(h),N=z(o);return $r(m,N,c)},t.addHook=function(h,o){typeof o=="function"&&et(U[h],o)},t.removeHook=function(h,o){if(o!==void 0){const c=Lo(U[h],o);return c===-1?void 0:Fo(U[h],c,1)[0]}return nn(U[h])},t.removeHooks=function(h){U[h]=[]},t.removeAllHooks=function(){U=un()},t}var ti=qn();const ri=e=>e==null,it=e=>!ri(e),ni=(e,t)=>t?t.required&&(e==null||e==="")?"Field is required":t.basicEmailValidation&&(e==null||e==="")?"Field should be email":null:null,dn=(e,t)=>t?Object.keys(t).map(a=>{const i=ni(e[a],t[a].validations);return i?{field:a,error:i}:null},{}).filter(it):[],Kn=e=>{const[t,r]=s.useState(0),[n,a]=s.useState([]),i=s.useCallback(async()=>{try{await No({feedbackFormId:e.formId,link:window.location.pathname,rawHtml:ti.sanitize(document.getElementsByTagName("html")[0]??""),domainId:e.domainId,data:e.state,formType:e.formType,viewport:{first:document.body.clientWidth,second:document.body.clientHeight},browser:{productSub:navigator.productSub,vendor:navigator.vendor,pdfViewerEnabled:navigator.pdfViewerEnabled,maxTouchPoints:navigator.maxTouchPoints,hardwareConcurrency:navigator.hardwareConcurrency,cookieEnabled:navigator.cookieEnabled,appVersion:navigator.appVersion,platform:navigator.platform,userAgent:navigator.userAgent,language:navigator.language,onLine:navigator.onLine,webdriver:navigator.webdriver,deviceMemory:navigator.deviceMemory}})}catch(u){console.log(u)}},[e.state,e.formType]),l=s.useCallback(()=>{const u=dn(e.state,e.validationsPerStep[t]);a(u),u.length||(t<e.stepsCount-1?r(f=>f+1):i())},[e.state,e.validationsPerStep,t,i]),d=s.useCallback(()=>{t!==0&&(a([]),r(u=>u-1))},[t]);return s.useEffect(()=>{a(u=>{if(u.length){const f=dn(e.state,e.validationsPerStep[t]);if(f.length!==u.length)return f}return u})},[n,e.state,t]),{step:t,errors:n,onContinue:l,onBack:d}},ai=v.div({marginTop:"1rem",color:"var(--color-error)",height:"20px"}),Ie=({errors:e})=>{var t;return s.createElement(ai,{children:((t=(e||[])[0])==null?void 0:t.error)??null})},oi=v.input(({theme:e,colorVariant:t,selected:r})=>{const n=`calc(${e.sizeSelector} * 6);`,a=le(t);return{cursor:"pointer",appearance:"none",borderRadius:"var(--radius-selector)",verticalAlign:"middle",color:"var(--color-base-content)",width:n,border:`1px solid ${a}`,height:n,flexShrink:"0",padding:".25rem",transition:"background-color .2s,box-shadow .2s",display:"inline-block",position:"relative","&::before":{content:'""',opacity:"0",clipPath:"polygon(20% 100%,20% 80%,50% 80%,50% 80%,70% 80%,70% 100%)",width:"100%",height:"100%",boxShadow:"0 3px oklch(100% 0 0/calc(var(--depth)*.1)) inset",backgroundColor:`${a}`,fontSize:"1rem",lineHeight:".75",transition:"clip-path .3s .1s,opacity .1s .1s,rotate .3s .1s,translate .3s .1s",display:"block",rotate:"45deg",...r?{clipPath:"polygon(20% 100%,20% 80%,50% 80%,50% 0%,70% 0%,70% 100%)",opacity:"1"}:{}}}}),ii=v.label(e=>({display:"flex",fontWeight:e.selected?"500":"normal",transition:".2s ease-in-out",alignItems:"center",cursor:"pointer",gap:"calc(var(--spacing) * 2)"})),si=e=>{const t=s.useMemo(()=>`${e.id}-${e.label.replace(/\s/g,"-").toLowerCase()}`,[]),r=a=>{e.onSelect(e.value.includes(a)?e.value.filter(i=>i!==a):[...e.value,a])},n=e.value.includes(t);return s.createElement(ii,{selected:n,children:[s.createElement(oi,{id:t,type:"checkbox",selected:n,colorVariant:e.colorVariant,onChange:()=>r(t),name:e.name}),s.createElement(oe,{children:e.label,linear:!0})]})},li=v.div`
|
|
83
83
|
display: flex;
|
|
84
84
|
flex-direction: column;
|
|
85
85
|
width: var(--all-fields-size);
|
|
@@ -87,14 +87,14 @@
|
|
|
87
87
|
@media (max-width: 900px) {
|
|
88
88
|
width: 100%;
|
|
89
89
|
}
|
|
90
|
-
`,
|
|
90
|
+
`,ci=v.div`
|
|
91
91
|
display: flex;
|
|
92
92
|
gap: calc(var(--spacing) * 10);
|
|
93
93
|
@media (max-width: 900px) {
|
|
94
94
|
gap: var(--spacing);
|
|
95
95
|
flex-direction: column;
|
|
96
96
|
}
|
|
97
|
-
`,
|
|
97
|
+
`,Xn=e=>{const t=e.label.replace(/\s/g,"-").toLowerCase(),r=e.elementsPerCol||4,n=s.useMemo(()=>e.options.reduce((a,i,l)=>{var u;return(l%r===0||l===0)&&a.push([]),(u=a[a.length-1])==null||u.push(i),a},[]),[r,e.options]);return s.createElement("div",{children:[s.createElement(oe,{children:e.label,variant:"section"}),s.createElement(ci,{children:n.map((a,i)=>s.createElement(li,{key:i,children:a.map(l=>s.createElement(si,{onSelect:e.onChange,colorVariant:e.colorVariant,value:e.value,id:e.formClientId,name:t,label:l.label}))}))}),s.createElement(Ie,{errors:e.errors})]})},ui=v(Ge)(()=>({"&:not(:last-of-type):not(:first-of-type)":{borderRadius:"0",marginRight:"-1px",marginLeft:"-1px"},"&:first-of-type":{borderTopRightRadius:"0",borderBottomRightRadius:"0"},"&:last-of-type":{borderTopLeftRadius:"0",borderBottomLeftRadius:"0"},"@media (max-width: 900px)":{}})),di=e=>s.createElement(ui,{onClick:e.onChange,$outlined:!e.selected,children:e.label}),mn=v("span")(({min:e,variant:t})=>{const r=t||le();return{position:"absolute",left:e?"0":void 0,right:e?void 0:"0",bottom:"-2px",opacity:"0.5",fontWeight:"300",transform:"translateY(100%)",textTransform:"uppercase",color:r}}),mi=v.div(e=>({verticalAlign:"middle",display:"inline-flex",position:"relative",marginBottom:e.withText?"calc(var(--spacing) * 6)":"0"})),Zn=e=>s.createElement("div",{children:[s.createElement(oe,{children:e.label,variant:"section"}),s.createElement(mi,{withText:e.maxText||e.minText,children:[e.maxText?s.createElement(mn,{min:!1,children:e.maxText}):null,e.minText?s.createElement(mn,{min:!0,children:e.minText}):null,Array(e.max).fill(1).map((t,r)=>s.createElement(di,{onChange:()=>e.onChange(r+1),selected:r+1===e.value,key:`${r}`,label:`${r+1}`}))]}),s.createElement(Ie,{errors:e.errors})]}),fi=v.input(({theme:e,selected:t,colorVariant:r})=>{const n=`calc(${e.sizeSelector} * 6);`,a=le(r);return{width:n,height:n,color:e.neutral,margin:"0",cursor:"pointer",appearance:"none",verticalAlign:"middle",borderRadius:"3.40282e38px",border:`1px solid ${a}`,flexShrink:"0",padding:t?".25rem":"0.4rem",transition:".2s ease-in-out",display:"inline-block",position:"relative",boxSizing:"border-box","&::before":{content:'""',borderRadius:"3.40282e38px",background:t?a:"transparent",width:"100%",height:"100%",display:"block"}}}),hi=v.label(e=>({display:"flex",fontWeight:e.selected?"500":"normal",transition:".2s ease-in-out",alignItems:"center",cursor:"pointer",gap:"calc(var(--spacing) * 2)"})),pi=e=>{const t=s.useMemo(()=>`${e.id}-${e.label.replace(/\s/g,"-").toLowerCase()}`,[e.id]),r=a=>{e.onSelect(a)},n=e.value===t;return s.createElement(hi,{selected:n,htmlFor:t,children:[s.createElement(fi,{id:t,type:"radio",variant:e.colorVariant,selected:n,onChange:()=>r(t),name:e.name}),s.createElement(oe,{children:e.label,linear:!0})]})},gi=v.div`
|
|
98
98
|
display: flex;
|
|
99
99
|
flex-direction: column;
|
|
100
100
|
width: var(--all-fields-size);
|
|
@@ -102,47 +102,47 @@
|
|
|
102
102
|
@media (max-width: 900px) {
|
|
103
103
|
width: 100%;
|
|
104
104
|
}
|
|
105
|
-
`,
|
|
105
|
+
`,bi=v.div`
|
|
106
106
|
display: flex;
|
|
107
107
|
gap: calc(var(--spacing) * 10);
|
|
108
108
|
@media (max-width: 900px) {
|
|
109
109
|
gap: var(--spacing);
|
|
110
110
|
flex-direction: column;
|
|
111
111
|
}
|
|
112
|
-
`,
|
|
112
|
+
`,Qn=e=>{const t=e.elementsPerCol||4,r=s.useMemo(()=>e.options.reduce((n,a,i)=>{var d;return(i%t===0||i===0)&&n.push([]),(d=n[n.length-1])==null||d.push(a),n},[]),[t,e.options]);return s.createElement("div",{children:[s.createElement(oe,{children:e.label,variant:"section"}),s.createElement(bi,{children:r.map(n=>s.createElement(gi,{children:n.map(a=>s.createElement(pi,{colorVariant:e.colorVariant,onSelect:e.onChange,value:e.value,id:e.formClientId,name:`${a.id}-${e.formClientId}`,label:a.label}))}))}),s.createElement(Ie,{errors:e.errors})]})},yi=v.input(e=>{const t=le(e.colorVariant);return{cursor:"text",border:`var(--border-width)solid ${t}`,appearance:"none",backgroundColor:"var(--color-base-100)",verticalAlign:"middle",whiteSpace:"nowrap",width:"clamp(3rem,30rem,100%)",height:"calc(var(--size-field, .25rem) * 10)",fontSize:"max(var(--font-size,.875rem),.875rem)",touchAction:"manipulation",borderColor:t,borderStartStartRadius:"var(--join-ss,var(--radius-field))",borderStartEndRadius:"var(--join-se,var(--radius-field))",borderEndEndRadius:"var(--join-ee,var(--radius-field))",borderEndStartRadius:"var(--join-es,var(--radius-field))",alignItems:"center",boxSizing:"border-box",paddingInline:".75rem","&:focus":{outline:`2px solid ${t}`,outlineOffset:"3px",isolation:"isolate"}}}),vi=v.input(e=>{const r=le(e.colorVariant);return{cursor:"pointer",flex:"1",verticalAlign:"middle","--radius-selector-max":"calc(var(--radius-selector) + var(--radius-selector) + var(--radius-selector))",borderRadius:"calc(var(--radius-selector) + min(var(--range-p),var(--radius-selector-max)))",height:"var(--range-thumb-size)",backgroundColor:"#0000",border:"none",overflow:"hidden",appearance:"none",webkitAppearance:"none",margin:"0","--range-thumb":"var(--color-base-100)","--range-thumb-size":"calc(var(--size-selector,.25rem)*6)","--range-progress":r,"--range-fill":"1","--range-p":".25rem","--range-bg":r,font:"inherit",fontFeatureSettings:"inherit",fontVariationSettings:"inherit",letterSpacing:"inherit",color:"inherit",opacity:"1","&::-webkit-slider-runnable-track":{backgroundColor:"var(--range-bg)",borderRadius:"var(--radius-selector)",width:"100%",height:"calc(var(--range-thumb-size)*.5)","--range-bg":"color-mix(in oklab,currentColor 10%,#0000)"},"&::-webkit-slider-thumb":{boxSizing:"border-box",borderRadius:"calc(var(--radius-selector) + min(var(--range-p),var(--radius-selector-max)))",height:"var(--range-thumb-size)",width:"var(--range-thumb-size)",border:"var(--range-p)solid",appearance:"none",webkitAppearance:"none",color:"var(--range-progress)",boxShadow:"0 -1px oklch(0% 0 0 / calc(var(--depth) * .1)) inset, 0 8px 0 -4px oklch(100% 0 0 / calc(var(--depth) * .1)) inset, 0 0 1px 1px currentColor, 0 0 0 2rem var(--range-thumb) inset, calc((var(--range-dir, 1) * -100rem) - (var(--range-dir, 1) * var(--range-thumb-size) / 2)) 0 0 calc(100rem * var(--range-fill))",backgroundColor:r,position:"relative",top:"50%",transform:"translateY(-50%)"}}}),Ei=v.div`
|
|
113
113
|
width: clamp(3rem, 30rem, 100%);
|
|
114
|
-
`,
|
|
114
|
+
`,Si=v(yi)`
|
|
115
115
|
width: calc(var(--size-field) * 15);
|
|
116
|
-
`,
|
|
116
|
+
`,Ti=v.div`
|
|
117
117
|
display: flex;
|
|
118
118
|
align-items: center;
|
|
119
119
|
gap: calc(var(--spacing) * 2);
|
|
120
|
-
`,
|
|
120
|
+
`,wi=e=>{var a;const t=e.min||0,r=e.max||100,n=i=>{const l=Number.parseInt(i.target.value);Number.isNaN(l)?console.error("RangeSlide must be a number"):e.onChange(l)};return s.useEffect(()=>{e.onChange(e.value||e.initialValue||0)},[]),s.createElement(Ei,{children:[s.createElement(oe,{children:e.label,variant:"section"}),s.createElement(Ti,{children:[s.createElement(vi,{type:"range",min:t,max:r,useThemeColors:e.colorVariant,value:e.value,onChange:n}),s.createElement(Si,{type:"number",value:((a=e.value)==null?void 0:a.toString())??"",max:r,min:t,colorVariant:e.colorVariant,onChange:i=>e.onChange(+i.target.value)})]}),s.createElement(Ie,{errors:e.errors})]})},xi='<svg xmlns="http://www.w3.org/2000/svg" width="200" height="185"><path d="M100 184.606a15.384 15.384 0 0 1-8.653-2.678C53.565 156.28 37.205 138.695 28.182 127.7 8.952 104.264-.254 80.202.005 54.146.308 24.287 24.264 0 53.406 0c21.192 0 35.869 11.937 44.416 21.879a2.884 2.884 0 0 0 4.356 0C110.725 11.927 125.402 0 146.594 0c29.142 0 53.098 24.287 53.4 54.151.26 26.061-8.956 50.122-28.176 73.554-9.023 10.994-25.383 28.58-63.165 54.228a15.384 15.384 0 0 1-8.653 2.673Z" fill="black" fill-rule="nonzero"/></svg>',Ci='<svg xmlns="http://www.w3.org/2000/svg" width="192" height="180"><path fill="black" d="m96 137.263-58.779 42.024 22.163-68.389L.894 68.481l72.476-.243L96 0l22.63 68.238 72.476.243-58.49 42.417 22.163 68.389z" fill-rule="evenodd"/></svg>',Ai='<svg xmlns="http://www.w3.org/2000/svg" width="192" height="180"><path fill="black" d="m96 153.044-58.779 26.243 7.02-63.513L.894 68.481l63.117-13.01L96 0l31.989 55.472 63.117 13.01-43.347 47.292 7.02 63.513z" fill-rule="evenodd"/></svg>',_i={heart:encodeURIComponent(xi),star:encodeURIComponent(Ci),star2:encodeURIComponent(Ai)},fn={small:"1rem",medium:"1.5rem",large:"2rem"},Ii=v.input(e=>{const t=_i[e.icon??"star2"],r=le(e.colorVariant);return{maskImage:`url(data:image/svg+xml,${t})`,backgroundColor:r,appearance:"none",transform:e.selected?"scale(1.1)":"scale(1)",transition:"transform 0.3s",border:"none",opacity:e.selected?"1":.2,verticalAlign:"middle",display:"inline-block",WebkitMaskPosition:"50%",maskPosition:"50%",cursor:"pointer",WebkitMaskSize:"contain",maskSize:"contain",WebkitMaskRepeat:"no-repeat",maskRepeat:"no-repeat",borderRadius:"0",width:fn[e.size??"medium"],height:fn[e.size??"medium"]}}),Ri=v.div(()=>({verticalAlign:"middle",position:"relative"})),Jn=({value:e,max:t,errors:r,label:n,onChange:a})=>s.createElement(Ri,{value:1,max:5,children:[s.createElement(oe,{variant:"section",children:n}),Array(t).fill(1).map((i,l)=>s.createElement(Ii,{selected:l<e,name:`rating-${l+1}`,key:`${l}`,onChange:()=>{a(l+1)},type:"radio"})),s.createElement(Ie,{errors:r})]}),ki=v.div`
|
|
121
121
|
width: 100%;
|
|
122
|
-
`,
|
|
122
|
+
`,Pi=v.textarea(e=>{const t=le(e.colorVariant);return{border:"var(--border-width)solid #0000",appearance:"none",borderRadius:"var(--radius-field)",backgroundColor:"var(--color-base-100)",verticalAlign:"middle",width:"clamp(3rem,30rem,100%)",maxWidth:"100%",minWidth:"3rem",minHeight:"5rem",fontSize:"max(var(--font-size,.875rem),.875rem)",touchAction:"manipulation",borderColor:t,flexShrink:"1",paddingBlock:".5rem",boxSizing:"border-box",paddingInline:".75rem","&:focus":{outline:`2px solid ${t}`,outlineOffset:"3px",isolation:"isolate"}}}),ea=e=>{const t=r=>e.onChange(r.target.value);return s.createElement(ki,{children:[s.createElement(oe,{variant:"section",children:e.label}),s.createElement(Pi,{value:e.value??"",useThemeColors:e.colorVariant,rows:e.rows??3,onChange:t}),s.createElement(Ie,{errors:e.errors})]})},Oi=v.div`
|
|
123
123
|
width: 100%;
|
|
124
|
-
`,
|
|
124
|
+
`,St=e=>e!=null,Ni=(e,t)=>(n=>{if(!n)return e.default;const a=n.find(i=>i.conditions.every(l=>{const d=t(l.fieldName);if(!St(d))return!1;const u=[];return St(l.eq)?l.eq===d?u.push(!0):u.push(!1):St(l.lessThan)?l.lessThan>d?u.push(!0):u.push(!1):St(l.moreThan)&&(l.moreThan<d?u.push(!0):u.push(!1)),u.every(Boolean)}));return(a==null?void 0:a.value)??e.default})(e.values),ta=e=>{const t=()=>{const r=i=>e.setStateByKey(e.dataField,i),n=Ni(e.fieldProps.label,e.getStateByKey),a={formClientId:e.formClientId,label:n,errors:e.errors,onChange:r,value:e.getStateByKey(e.dataField),key:`${e.type}-${e.fieldProps.label}-${e.fieldProps.meta.name}`};switch(e.type){case"matrix":{const i=e.fieldProps;return s.createElement(Zn,{...i,...a,max:10})}case"radio-group":{const i=e.fieldProps;return s.createElement(Qn,{...i,...a})}case"checkbox-group":{const i=e.fieldProps;return s.createElement(Xn,{...i,...a})}case"range-slide":{const i=e.fieldProps;return s.createElement(wi,{...i,...a})}case"rating":{const i=e.fieldProps;return s.createElement(Jn,{...i,...a})}case"textarea":{const i=e.fieldProps;return s.createElement(ea,{...i,...a})}default:return null}};return s.createElement(Oi,{children:t()})},$i=v.div({position:"relative",fontSize:"var(--font-size)"}),Di=v.div`
|
|
125
125
|
display: flex;
|
|
126
126
|
align-items: center;
|
|
127
127
|
justify-content: space-between;
|
|
128
128
|
margin-top: calc(var(--spacing) * 10);
|
|
129
|
-
`,
|
|
129
|
+
`,ra=e=>{const t=s.useMemo(()=>Math.random().toString(36).substring(2,10),[]),[r,n]=s.useState(null),a=d=>{n(u=>!u||u<d?d:u)},i=Wn({form:e.inlineForm.form,formId:e.formId,domainId:e.domainId}),l=Kn({domainId:e.domainId,formType:"inlineForm",stepsCount:i.steps.length,validationsPerStep:i.validationsPerStep,formId:e.formId,state:i.state});return s.createElement($i,{children:[e.inlineForm.config.formTitle&&s.createElement(oe,{variant:"title",children:e.inlineForm.config.formTitle}),i.steps.map((d,u)=>{var f;return s.createElement(Un,{key:u+`${(f=d.meta)==null?void 0:f.name}`,height:r,onSetMaxHeight:a,isVisible:u===l.step,children:d.fields.map(p=>s.createElement(ta,{type:p.type,fieldProps:p,dataField:p.dataField,formClientId:t,onContinue:l.onContinue,errors:l.errors.filter(T=>T.field===p.dataField),getStateByKey:i.getStateByKey,setStateByKey:i.setStateByKey}))})}),s.createElement(Di,{children:[s.createElement(Ge,{children:"Back",disabled:l.step===0,onClick:l.onBack}),s.createElement(Vn,{steps:i.steps,currentStepIndex:l.step}),s.createElement(Ge,{children:"Continue",onClick:l.onContinue})]})]})},Mi=v.div(e=>({backgroundColor:"var(--color-base-100)",borderTopLeftRadius:"var(--modal-tl,var(--radius-box))",borderTopRightRadius:"var(--modal-tr,var(--radius-box))",borderBottomLeftRadius:"var(--modal-bl,var(--radius-box))",borderBottomRightRadius:"var(--modal-br,var(--radius-box))",opacity:e.$visible?"1":"0",overscrollBehavior:"contain",gridRowStart:"1",gridColumnStart:"1",width:"91.6667%",maxWidth:"1080px",margin:"auto",maxHeight:"100vh",padding:"1.5rem",transition:"translate .3s ease-out,scale .3s ease-out,opacity .2s ease-out 50ms,box-shadow .3s ease-out",overflowY:"auto",scale:"95%",boxShadow:"0 25px 50px -12px #00000040","@media (max-width: 900px)":{maxWidth:"initial",width:"auto"}})),Li=v.div(()=>({})),Fi=v.dialog(({$visible:e})=>({pointerEvents:e?"auto":"none",visibility:e?"visible":"hidden",width:"100%",maxWidth:"none",height:"100%",maxHeight:"none",color:"inherit",transition:"visibility .3s allow-discrete,background-color .3s ease-out,opacity .1s ease-out",overscrollBehavior:"contain",zIndex:"99",scrollbarGutter:"auto",backgroundColor:e?"#0006":"#0000",placeItems:"center",margin:"0",padding:"0",display:"grid",position:"fixed",overflow:"clip",top:0,border:0,outline:0})),zi=e=>{const t=s.useRef(null),r=Math.random().toString(36).substring(2,16),n=s.useCallback(i=>{i.target===t.current&&e.onClose(),i.preventDefault(),i.stopPropagation()},[e]),a=s.useCallback(i=>{i.key==="Escape"&&e.onClose(),i.preventDefault()},[]);return s.useEffect(()=>{t.current&&e.isOpen?t.current.show():t.current&&!e.isOpen&&t.current.close()},[t,e.isOpen]),s.useEffect(()=>(document.addEventListener("keyup",a),()=>{document.removeEventListener("keyup",a)}),[]),s.createElement(Fi,{$visible:e.isOpen,onClick:n,ref:t,id:r,children:s.createElement(Mi,{$visible:e.isOpen,children:[s.createElement(oe,{children:e.heading,variant:"title"}),e.children,s.createElement(Li,{children:e.footer})]})})},Bi=v.div`
|
|
130
130
|
display: flex;
|
|
131
131
|
align-items: center;
|
|
132
132
|
justify-content: space-between;
|
|
133
133
|
margin-top: calc(var(--spacing) * 10);
|
|
134
|
-
`,
|
|
134
|
+
`,Ui=v(Ge)`
|
|
135
135
|
position: fixed;
|
|
136
136
|
width: fit-content;
|
|
137
137
|
height: fit-content;
|
|
138
138
|
transform: rotate(-90deg) translateY(calc(100% - 15px));
|
|
139
139
|
padding: 10px 20px 30px 20px;
|
|
140
140
|
margin: auto;
|
|
141
|
-
left: ${e=>
|
|
142
|
-
right: ${e=>
|
|
143
|
-
top: ${e=>
|
|
144
|
-
bottom: ${e=>
|
|
141
|
+
left: ${e=>it(e.$left)?`${e.$left}px`:null};
|
|
142
|
+
right: ${e=>it(e.$right)?`${e.$right}px`:null};
|
|
143
|
+
top: ${e=>it(e.$top)?`${e.$top}px`:null};
|
|
144
|
+
bottom: ${e=>it(e.$bottom)?`${e.$bottom}px`:null};
|
|
145
145
|
&:active {
|
|
146
146
|
transform: rotate(-90deg) translateY(calc(100% - 18px));
|
|
147
147
|
}
|
|
148
|
-
`,
|
|
148
|
+
`,na=e=>{const[t,r]=s.useState(!1),[n,a]=s.useState(null),i=s.useMemo(()=>Math.random().toString(36).substring(2,10),[]),l=f=>{a(p=>!p||p<f?f:p)},d=Wn({form:e.popupForm.form,formId:e.formId,domainId:e.domainId}),u=Kn({domainId:e.domainId,formType:"inlineForm",stepsCount:d.steps.length,validationsPerStep:d.validationsPerStep,formId:e.formId,state:d.state});return s.createElement(s.Fragment,{children:[s.createElement(Ui,{children:e.popupForm.config.buttonText,onClick:()=>r(!0),$left:e.popupForm.styles.left??null,$right:e.popupForm.styles.right??null,$top:e.popupForm.styles.top??null,$bottom:e.popupForm.styles.bottom??null}),s.createElement(zi,{onClose:()=>r(!1),heading:e.popupForm.config.formTitle,isOpen:t,footer:s.createElement(Bi,{children:[s.createElement(Ge,{children:"Back",disabled:u.step===0,onClick:u.onBack}),s.createElement(Vn,{steps:d.steps,currentStepIndex:u.step}),s.createElement(Ge,{children:"Continue",onClick:u.onContinue})]}),children:d.steps.map((f,p)=>{var T;return s.createElement(Un,{key:p+`${(T=f.meta)==null?void 0:T.name}`,height:n,onSetMaxHeight:l,isVisible:p===u.step,children:f.fields.map(w=>s.createElement(ta,{type:w.type,fieldProps:w,formClientId:i,dataField:w.dataField,onContinue:u.onContinue,errors:u.errors.filter(E=>E.field===w.dataField),getStateByKey:d.getStateByKey,setStateByKey:d.setStateByKey}))})})})]})},aa=e=>{e.locale;let{data:t,loading:r,error:n}=Co(()=>xo({formId:e.formId}));const a=s.useMemo(()=>t!=null&&t.inlineForm?s.createElement(ra,{key:`inline-form-${e.formId}`,formId:e.formId,domainId:t.domainId,formTheme:t.attributes.theme,inlineForm:t.inlineForm}):null,[t==null?void 0:t.attributes.theme,t==null?void 0:t.domainId,t==null?void 0:t.inlineForm,e.formId]),i=s.useMemo(()=>t!=null&&t.popupForm?s.createElement(na,{key:`popup-form-${e.formId}`,formId:e.formId,domainId:t.domainId,formTheme:t.attributes.theme,popupForm:t.popupForm}):null,[t==null?void 0:t.attributes.theme,t==null?void 0:t.domainId,t==null?void 0:t.inlineForm,e.formId]);return!t&&r?"Loading...":!t||n?n?n.message:"Unknown error":s.createElement(he,{theme:t.attributes.theme,selectedVariant:t.attributes.variant,children:[a,i]})},hn=v.option(()=>({borderRadius:"var(--radius-field)",whiteSpace:"normal",paddingBlock:".375rem",paddingInline:".75rem",transitionProperty:"color,background-color",transitionDuration:".2s",transitionTimingFunction:"cubic-bezier(0,0,.2,1)"})),Vi=v.select(e=>({border:`var(--border-width)solid ${le(e.colorVariant)}`,backgroundColor:"var(--color-base-100)",verticalAlign:"middle",width:"clamp(3rem,30rem,100%)",height:"calc(var(--size-field,.25rem)*10)",touchAction:"manipulation",whiteSpace:"nowrap",textOverflow:"ellipsis",borderStartStartRadius:"var(--radius-field)",borderStartEndRadius:"var(--radius-field)",borderEndEndRadius:"var(--radius-field)",borderEndStartRadius:"var(--radius-field)",flexShrink:"1",alignItems:"center",gap:".375rem",paddingInline:".75rem 1.75rem",fontSize:".875rem",display:"inline-flex",position:"relative",overflow:"hidden"})),Wi=e=>{const t=r=>e.onChange(r.target.value);return s.createElement("div",{children:[s.createElement(oe,{children:e.label,variant:"section"}),s.createElement(Vi,{colorVariant:e.colorVariant,value:e.value??null,defaultChecked:!1,defaultValue:null,onChange:t,children:[s.createElement(hn,{value:"",selected:!e.value,children:"Select an option",key:""}),e.options.map(r=>s.createElement(hn,{value:r.id,selected:r.id===e.value,children:r.label,key:r.id}))]}),s.createElement(Ie,{errors:e.errors})]})},Hi=e=>{if(!e){console.error("options must be provided. Feedback module deactivated");return}if(!e.formId){console.error("formId must be provided. Feedback module deactivated");return}const t=ga.createRoot(e.container||document);typeof window<"u"&&t.render(s.createElement(aa,{formId:e.formId}))},oa=e=>e?e.formId?typeof window>"u"?null:s.createElement(aa,{formId:e.formId}):(console.error("formId must be provided. Feedback module deactivated"),null):(console.error("options must be provided. Feedback module deactivated"),null),Gi=e=>oa(e),ji=e=>s.createElement(he,{theme:e.formTheme,selectedVariant:e.variant,children:[s.createElement(ra,e)]}),Yi=e=>s.createElement(he,{theme:e.formTheme,selectedVariant:e.variant,children:[s.createElement(na,e)]}),qi={Checkbox:e=>s.createElement(he,{theme:e.formTheme,selectedVariant:e.formVariant,children:[s.createElement(Xn,e.cmpProps)]}),QuestionMatrix:e=>s.createElement(he,{theme:e.formTheme,selectedVariant:e.formVariant,children:[s.createElement(Zn,e.cmpProps)]}),Radio:e=>s.createElement(he,{theme:e.formTheme,selectedVariant:e.formVariant,children:[s.createElement(Qn,e.cmpProps)]}),Rating:e=>s.createElement(he,{theme:e.formTheme,selectedVariant:e.formVariant,children:[s.createElement(Jn,e.cmpProps)]}),Select:e=>s.createElement(he,{theme:e.formTheme,selectedVariant:e.formVariant,children:[s.createElement(Wi,e.cmpProps)]}),Textarea:e=>s.createElement(he,{theme:e.formTheme,selectedVariant:e.formVariant,children:[s.createElement(ea,e.cmpProps)]})};exports.FeedbackModule=Gi;exports.PreviewInPlaceForm=ji;exports.PreviewPopupForm=Yi;exports.SurveyFormComponents=qi;exports.initiateFeedbackModule=Hi;exports.renderFeedbackModule=oa;
|