(self.webpackChunktradingview=self.webpackChunktradingview||[]).push([[1829],{56138:e=>{e.exports={wrapper:"wrapper-VB9J73Gf",focused:"focused-VB9J73Gf",readonly:"readonly-VB9J73Gf",disabled:"disabled-VB9J73Gf","size-small":"size-small-VB9J73Gf","size-medium":"size-medium-VB9J73Gf","size-large":"size-large-VB9J73Gf","font-size-small":"font-size-small-VB9J73Gf","font-size-medium":"font-size-medium-VB9J73Gf","font-size-large":"font-size-large-VB9J73Gf","border-none":"border-none-VB9J73Gf",shadow:"shadow-VB9J73Gf","border-thin":"border-thin-VB9J73Gf","border-thick":"border-thick-VB9J73Gf","intent-default":"intent-default-VB9J73Gf","intent-success":"intent-success-VB9J73Gf","intent-warning":"intent-warning-VB9J73Gf","intent-danger":"intent-danger-VB9J73Gf","intent-primary":"intent-primary-VB9J73Gf","corner-top-left":"corner-top-left-VB9J73Gf","corner-top-right":"corner-top-right-VB9J73Gf","corner-bottom-right":"corner-bottom-right-VB9J73Gf","corner-bottom-left":"corner-bottom-left-VB9J73Gf",childrenContainer:"childrenContainer-VB9J73Gf"}},28733:e=>{e.exports={defaultSelect:"defaultSelect-OM7V5ndi"}},64995:e=>{e.exports={itemWrap:"itemWrap-srH7jxJB",item:"item-srH7jxJB",icon:"icon-srH7jxJB",selected:"selected-srH7jxJB",label:"label-srH7jxJB"}},53787:e=>{e.exports={lineEndSelect:"lineEndSelect-gw7ESiZg",right:"right-gw7ESiZg"}},66787:e=>{e.exports={lineStyleSelect:"lineStyleSelect-GcXENVb4",multipleStyles:"multipleStyles-GcXENVb4"}},20443:e=>{e.exports={lineWidthSelect:"lineWidthSelect-EUDB1YgB",bar:"bar-EUDB1YgB",isActive:"isActive-EUDB1YgB",item:"item-EUDB1YgB"}},3923:e=>{e.exports={container:"container-dhpv13DH",active:"active-dhpv13DH",disabled:"disabled-dhpv13DH",icon:"icon-dhpv13DH"}},87025:e=>{e.exports={wrap:"wrap-b6_0ORMg",disabled:"disabled-b6_0ORMg"}},38343:e=>{e.exports={checkboxWrapper:"checkboxWrapper-tHySGrzM"}},74457:e=>{e.exports={checkbox:"checkbox-hpyVsWoD",container:"container-hpyVsWoD",hintButton:"hintButton-hpyVsWoD",description:"description-hpyVsWoD"}},20438:e=>{e.exports={dropdown:"dropdown-gZlS9p6t",dropdownMenu:"dropdownMenu-gZlS9p6t",gradientColor:"gradientColor-gZlS9p6t",lineWidthSelect:"lineWidthSelect-gZlS9p6t"}},59177:e=>{e.exports={row:"row-nGXZ4vJz",empty:"empty-nGXZ4vJz",noMargins:"noMargins-nGXZ4vJz",wrap:"wrap-nGXZ4vJz",breakpointNormal:"breakpointNormal-nGXZ4vJz",breakpointMedium:"breakpointMedium-nGXZ4vJz",breakpointSmall:"breakpointSmall-nGXZ4vJz"}},5643:e=>{e.exports={coordinates:"coordinates-mb1bDWNb",input:"input-mb1bDWNb",selectionCoordinates:"selectionCoordinates-mb1bDWNb",selectionCoordinates__inputs:"selectionCoordinates__inputs-mb1bDWNb",selectionCoordinates__description:"selectionCoordinates__description-mb1bDWNb",hintButton:"hintButton-mb1bDWNb"}},41027:e=>{e.exports={wrapper:"wrapper-NVcHMTVy",checkbox:"checkbox-NVcHMTVy",colorSelect:"colorSelect-NVcHMTVy",hintButton:"hintButton-NVcHMTVy"}},22419:e=>{e.exports={withoutPadding:"withoutPadding-KtEcG0Q0"}},42830:e=>{e.exports={input:"input-mIsHGNhw",control:"control-mIsHGNhw",item:"item-mIsHGNhw",cell:"cell-mIsHGNhw", fragmentCell:"fragmentCell-mIsHGNhw",largeWidth:"largeWidth-mIsHGNhw",withTitle:"withTitle-mIsHGNhw",title:"title-mIsHGNhw",hidden:"hidden-mIsHGNhw"}},58653:e=>{e.exports={line:"line-j5rMaiWF",control:"control-j5rMaiWF",valueInput:"valueInput-j5rMaiWF",valueUnit:"valueUnit-j5rMaiWF",input:"input-j5rMaiWF"}},42683:e=>{e.exports={unit:"unit-ZtRdVxiD",input:"input-ZtRdVxiD",normal:"normal-ZtRdVxiD",big:"big-ZtRdVxiD",dropdown:"dropdown-ZtRdVxiD",dropdownMenu:"dropdownMenu-ZtRdVxiD"}},93107:e=>{e.exports={numberChildInput:"numberChildInput-F77bfoWJ",numberChildInput_width_normal:"numberChildInput_width_normal-F77bfoWJ",numberChildInput_width_big:"numberChildInput_width_big-F77bfoWJ",optionalSetChild:"optionalSetChild-F77bfoWJ",dropdown:"dropdown-F77bfoWJ",dropdown_width_normal:"dropdown_width_normal-F77bfoWJ",dropdown_width_big:"dropdown_width_big-F77bfoWJ",dropdown__menu:"dropdown__menu-F77bfoWJ",dropdown__menu_width_normal:"dropdown__menu_width_normal-F77bfoWJ",dropdown__menu_width_big:"dropdown__menu_width_big-F77bfoWJ"}},60039:e=>{e.exports={optionalTwoColors:"optionalTwoColors-LDRcAXEV",colorPicker:"colorPicker-LDRcAXEV",dropdown:"dropdown-LDRcAXEV",dropdownMenu:"dropdownMenu-LDRcAXEV"}},49107:e=>{e.exports={dropdown:"dropdown-RxdEkbF0",normal:"normal-RxdEkbF0",big:"big-RxdEkbF0",dropdownMenu:"dropdownMenu-RxdEkbF0"}},28023:e=>{e.exports={range:"range-GLEBGed4",valueInput:"valueInput-GLEBGed4",rangeSlider:"rangeSlider-GLEBGed4",rangeSlider_mixed:"rangeSlider_mixed-GLEBGed4",input:"input-GLEBGed4",hintButton:"hintButton-GLEBGed4"}},18923:e=>{e.exports={select:"select-hJtsYZ3G",preContent:"preContent-hJtsYZ3G",normal:"normal-hJtsYZ3G",big:"big-hJtsYZ3G",dropdownMenu:"dropdownMenu-hJtsYZ3G",wrap:"wrap-hJtsYZ3G",colorsWrap:"colorsWrap-hJtsYZ3G"}},57471:e=>{e.exports={colorPicker:"colorPicker-VK3h8amb",fontStyleButton:"fontStyleButton-VK3h8amb",dropdown:"dropdown-VK3h8amb",dropdownMenu:"dropdownMenu-VK3h8amb",hintButton:"hintButton-VK3h8amb",title:"title-VK3h8amb"}},52907:e=>{e.exports={twoColors:"twoColors-C2hZXnYv",colorPicker:"colorPicker-C2hZXnYv"}},11019:e=>{e.exports={dropdown:"dropdown-eLkGg0Ft",menu:"menu-eLkGg0Ft"}},27094:e=>{e.exports={button:"button-tFul0OhX","button-children":"button-children-tFul0OhX",hiddenArrow:"hiddenArrow-tFul0OhX",invisibleFocusHandler:"invisibleFocusHandler-tFul0OhX"}},74237:e=>{e.exports={buttonWrap:"buttonWrap-icygBqe7",desktopSize:"desktopSize-icygBqe7",drawer:"drawer-icygBqe7",menuBox:"menuBox-icygBqe7"}},51075:e=>{e.exports={btnContent:"btnContent-ivexqeZZ",contentPart:"contentPart-ivexqeZZ"}},42785:e=>{e.exports={placeholder:"placeholder-V6ceS6BN"}},85739:e=>{e.exports={checkbox:"checkbox-aOSYFxuH"}},94205:e=>{e.exports={range:"range-mFgGeMmT",disabled:"disabled-mFgGeMmT",rangeSlider:"rangeSlider-mFgGeMmT",rangeSliderMiddleWrap:"rangeSliderMiddleWrap-mFgGeMmT",rangeSliderMiddle:"rangeSliderMiddle-mFgGeMmT",dragged:"dragged-mFgGeMmT",pointer:"pointer-mFgGeMmT",rangePointerWrap:"rangePointerWrap-mFgGeMmT"}},36779:e=>{e.exports={button:"button-iLKiGOdQ",hovered:"hovered-iLKiGOdQ", disabled:"disabled-iLKiGOdQ",focused:"focused-iLKiGOdQ",active:"active-iLKiGOdQ",hidden:"hidden-iLKiGOdQ"}},70670:(e,t,n)=>{"use strict";n.d(t,{useControlDisclosure:()=>i});var o=n(59654);function i(e){const{intent:t,highlight:n,...i}=e,{isFocused:r,...a}=(0,o.useDisclosure)(i);return{...a,isFocused:r,highlight:n??r,intent:t??(r?"primary":"default")}}},66728:(e,t,n)=>{"use strict";n.d(t,{FontSizeSelect:()=>c});var o=n(79474),i=n(14487),r=n.n(i),a=n(28986),l=n(40197),s=n(28733);function c(e){const{id:t,fontSize:n,fontSizes:i=[],className:c,disabled:d,fontSizeChange:u}=e;return o.createElement(a.Select,{id:t,disabled:d,className:r()(c,s.defaultSelect),menuClassName:s.defaultSelect,items:(p=i,p.map((e=>({value:e.value,content:e.title})))),value:n,onChange:u,...(0,l.filterDataProps)(e)});var p}},72958:(e,t,n)=>{"use strict";n.d(t,{DisplayItem:()=>d,DropItem:()=>u,IconDropdown:()=>c});var o=n(79474),i=n(14487),r=n.n(i),a=n(28986),l=n(66334),s=n(64995);function c(e){const{menuItemClassName:t,...n}=e;return o.createElement(a.Select,{...n,menuItemClassName:r()(t,s.itemWrap)})}function d(e){return o.createElement("div",{className:r()(s.item,s.selected,e.className)},o.createElement(l.Icon,{className:s.icon,icon:e.icon}))}function u(e){return o.createElement("div",{className:s.item},o.createElement(l.Icon,{className:r()(s.icon,e.iconClassName),icon:e.icon}),o.createElement("div",{className:s.label},e.label))}},12091:(e,t,n)=>{"use strict";n.d(t,{defaultLineStyleItems:()=>c,lineStyleItemValues:()=>s});var o=n(60135),i=n(80140),r=n(85658),a=n(1018),l=n(26317);const s=[{type:i.LINESTYLE_SOLID,icon:r,label:o.t(null,void 0,n(27912))},{type:i.LINESTYLE_DASHED,icon:a,label:o.t(null,void 0,n(98847))},{type:i.LINESTYLE_DOTTED,icon:l,label:o.t(null,void 0,n(33987))}],c=s.map((e=>e.type))},68814:(e,t,n)=>{"use strict";n.d(t,{LineStyleSelect:()=>d});var o=n(79474),i=n(14487),r=n.n(i),a=n(72958),l=n(12091),s=n(51528),c=n(66787);class d extends o.PureComponent{render(){const{id:e,lineStyle:t,className:n,lineStyleChange:i,disabled:d,additionalItems:u,allowedLineStyles:p}=this.props;let m=function(e){let t=[...l.lineStyleItemValues];return void 0!==e&&(t=t.filter((t=>e.includes(t.type)))),t.map((e=>({value:e.type,selectedContent:o.createElement(a.DisplayItem,{icon:e.icon}),content:o.createElement(a.DropItem,{icon:e.icon,label:e.label})})))}(p);return u&&(m=[{readonly:!0,content:u},...m]),o.createElement(a.IconDropdown,{id:e,disabled:d,className:r()(c.lineStyleSelect,n),hideArrowButton:!0,items:m,value:t,onChange:i,"data-name":"line-style-select",addPlaceholderToItems:!1,placeholder:o.createElement(a.DisplayItem,{icon:s,className:c.multipleStyles})})}}},81264:(e,t,n)=>{"use strict";n.d(t,{Transparency:()=>s});var o=n(79474),i=n(14487),r=n(71691),a=n(11284),l=n(87025);function s(e){const{value:t,disabled:n,onChange:s,className:c}=e;return o.createElement("div",{className:i(l.wrap,c,{[l.disabled]:n})},o.createElement(r.Opacity,{hideInput:!0,color:a.colorsPalette["color-tv-blue-500"],opacity:1-t/100,onChange:function(e){n||s(100-100*e)},disabled:n }))}},28390:(e,t,n)=>{"use strict";n.d(t,{useActiveDescendant:()=>r});var o=n(79474),i=n(73064);function r(e,t=[]){const[n,r]=(0,o.useState)(!1),a=(0,i.useFunctionalRefObject)(e);return(0,o.useLayoutEffect)((()=>{const e=a.current;if(null===e)return;const t=e=>{switch(e.type){case"active-descendant-focus":r(!0);break;case"active-descendant-blur":r(!1)}};return e.addEventListener("active-descendant-focus",t),e.addEventListener("active-descendant-blur",t),()=>{e.removeEventListener("active-descendant-focus",t),e.removeEventListener("active-descendant-blur",t)}}),t),[a,n]}},58530:(e,t,n)=>{"use strict";n.d(t,{useWatchedValueReadonly:()=>o.useWatchedValueReadonly});var o=n(57069)},13146:(e,t,n)=>{"use strict";n.d(t,{LineStyleSelect:()=>a});var o=n(79474),i=n(68814),r=n(1556);function a(e){const{property:t}=e,[n,a]=(0,r.useDefinitionProperty)({property:t});return o.createElement(i.LineStyleSelect,{...e,lineStyle:n,lineStyleChange:a})}},97367:(e,t,n)=>{"use strict";n.d(t,{LineWidthSelect:()=>d});var o=n(79474),i=n(14487),r=n(28986),a=n(20443);const l=[1,2,3,4];function s(e){const{id:t,value:n,items:s=l,disabled:c,onChange:d,className:u}=e;return o.createElement(r.Select,{id:t,disabled:c,hideArrowButton:!0,className:i(a.lineWidthSelect,u),items:(p=s,p.map((e=>({value:e,selectedContent:m(e,!0),content:m(e)})))),value:n,onChange:d,"data-name":"line-width-select"});var p;function m(e,t){const r={borderTopWidth:e};return o.createElement("div",{className:a.item},o.createElement("div",{className:i(a.bar,{[a.isActive]:e===n&&!t}),style:r}," "))}}var c=n(1556);function d(e){const{property:t}=e,[n,i]=(0,c.useDefinitionProperty)({property:t});return o.createElement(s,{...e,value:n,onChange:i})}},99189:(e,t,n)=>{"use strict";n.d(t,{ControlCustomHeightContext:()=>l,ControlCustomWidthContext:()=>r});var o,i=n(79474);!function(e){e.Small="small",e.Normal="normal",e.Big="big"}(o||(o={}));const r=i.createContext({});var a;!function(e){e.Normal="normal",e.Big="big"}(a||(a={}));const l=i.createContext({})},73951:(e,t,n)=>{"use strict";n.d(t,{Section:()=>cn});var o=n(79474),i=n(73405),r=n(1556),a=n(67328);function l(e){const{definition:{id:t,properties:{checked:n,disabled:i,visible:l},title:s,solutionId:c,infoTooltip:d},offset:u}=e,[p]=(0,r.useDefinitionProperty)({property:i,defaultValue:!1}),[m]=(0,r.useDefinitionProperty)({property:l,defaultValue:!0});return m?o.createElement(a.CommonSection,{id:t,offset:u,checked:n,title:s,solutionId:c,infoTooltip:d,disabled:e.disabled||p}):null}var s=n(14487),c=n.n(s),d=n(48504),u=n(91599),p=n(11614),m=n(21566),h=n(13146),f=n(97367),b=n(12745),v=n(85842);function y(e){return"mixed"===e}function g(e,t,n){const[i,r]=(0,o.useState)(e),a=(0,o.useRef)(i);return(0,o.useEffect)((()=>{r(e)}),[e,n]),[i,function(e){a.current=e,r(e)},function(){t(a.current)},function(){a.current=e,r(e)}]}var E,w=n(23351),C=n(72896),D=n(85728),S=n(47470),x=n(45958);function V(e){const{property:t,...n}=e,[i,a]=(0,o.useState)(performance.now()),[l,s]=(0,r.useDefinitionProperty)({property:t,handler:()=>a(performance.now())}),c=g(l,s,i) ;return o.createElement(k,{...n,valueHash:i,sharedBuffer:c})}function k(e){const{sharedBuffer:t,min:n,max:i,step:r,...a}=e,[l,s,c,d]=t,u=(0,o.useRef)(null),p=(0,o.useRef)(null),m={flushed:!1};return o.createElement(N,{...a,ref:p,onValueChange:function(e,t){s(e),"step"!==t||m.flushed||(c(),m.flushed=!0)},onKeyDown:function(e){if(e.defaultPrevented||m.flushed)return;switch((0,w.hashFromEvent)(e.nativeEvent)){case 27:d(),m.flushed=!0;break;case 13:e.preventDefault();const t=(0,v.ensureNotNull)(p.current).getClampedValue();null!==t&&(s(t),c(),m.flushed=!0)}},onBlur:function(e){const t=(0,v.ensureNotNull)(u.current);if(!t.contains(document.activeElement)&&!t.contains(e.relatedTarget)){const e=(0,v.ensureNotNull)(p.current).getClampedValue();null===e||m.flushed||(s(e),c(),m.flushed=!0)}},value:l,roundByStep:!1,containerReference:function(e){u.current=e},inputMode:x.CheckMobile.iOS()?void 0:"numeric",min:n,max:i,step:r,stretch:!1})}!function(e){e.Input="input",e.Step="step"}(E||(E={}));const P={mode:"float",min:-Number.MAX_VALUE,max:Number.MAX_VALUE,step:1,precision:0,inheritPrecisionFromStep:!0};class N extends o.PureComponent{constructor(e){super(e),this._selection=null,this._restoreSelection=!1,this._input=null,this._handleSelectionChange=()=>{this._restoreSelection||document.activeElement!==(0,v.ensureNotNull)(this._input)||this._saveSelection((0,v.ensureNotNull)(this._input))},this._handleInputReference=e=>{this._input=e,this.props.inputReference&&this.props.inputReference(e)},this._onFocus=e=>{this._saveSelection((0,v.ensureNotNull)(this._input)),this.setState({focused:!0}),this.props.onFocus&&this.props.onFocus(e)},this._onBlur=e=>{this._selection=null,this.setState({displayValue:M(this.props,this.props.value,L(this.props)),focused:!1}),this.props.onBlur&&this.props.onBlur(e)},this._onValueChange=e=>{const t=e.currentTarget,n=t.value,o=function(e,t,n){switch(n){case"integer":return T.test(t)?t:e;case"float":return t=t.replace(/,/g,"."),I.test(t)?t:e;case"fractional":return _.test(t)?t:e}}(this.state.displayValue,n,this.props.mode),i=B(o),r=this._checkValueBoundaries(i);var a,l;this.setState({displayValue:o}),o!==n&&(a=this.state.displayValue,l=(l=o).replace(/,/g,"."),(a=a.replace(/,/g,".")).includes(".")||!l.includes("."))?(this._restoreSelection=!0,this.forceUpdate()):this._saveSelection(t),r.value&&M(this.props,i)===o&&this.props.onValueChange(i,"input")},this._onValueByStepChange=e=>{const{roundByStep:t=!0,step:n=1}=this.props,o=B(this.state.displayValue);let i;if(isNaN(o)){const{defaultValue:e}=this.props;if(void 0===e)return;i=e}else{const r=new b.Big(o),a=new b.Big(n),l=r.mod(a);let s=r.plus(e*n);!l.eq(0)&&t&&(s=s.plus((e>0?0:1)*n).minus(l)),i=s.toNumber()}this._checkValueBoundaries(i).value&&(this.setState({displayValue:M(this.props,i,L(this.props))}),this.props.onValueChange(i,"step"))},this.state={value:A(this.props.value),displayValue:M(this.props,this.props.value,L(this.props)),focused:!1,valueHash:this.props.valueHash}}componentDidMount(){ document.addEventListener("selectionchange",this._handleSelectionChange)}componentWillUnmount(){document.removeEventListener("selectionchange",this._handleSelectionChange)}componentDidUpdate(){const e=(0,v.ensureNotNull)(this._input),t=this._selection;if(null!==t&&this._restoreSelection&&document.activeElement===e){const{start:n,end:o,direction:i}=t;e.setSelectionRange(n,o,i)}this._restoreSelection=!1}render(){return o.createElement(C.NumberInputView,{type:"text",inputMode:this.props.inputMode,name:this.props.name,fontSizeStyle:"medium",value:this.state.displayValue,className:this.props.className,placeholder:this.props.placeholder,forceShowControls:this.props.forceShowControls,disabled:this.props.disabled,stretch:this.props.stretch,error:Boolean(this.props.error),errorMessage:this.props.error,onValueChange:this._onValueChange,onValueByStepChange:this._onValueByStepChange,containerReference:this.props.containerReference,inputReference:this._handleInputReference,onClick:this.props.onClick,onFocus:this._onFocus,onBlur:this._onBlur,onKeyDown:this.props.onKeyDown,autoSelectOnFocus:!0,"data-name":this.props["data-name"],highlight:this.props.highlight})}getClampedValue(){const{min:e,max:t}=this.props,n=B(this.state.displayValue);return isNaN(n)?null:(0,D.clamp)(n,e,t)}static getDerivedStateFromProps(e,t){const{valueHash:n}=e,o=A(e.value);if(t.value!==o||t.valueHash!==n){return{value:o,valueHash:n,displayValue:M(e,o,t.focused&&t.valueHash===n?void 0:L(e))}}return null}_saveSelection(e){const{selectionStart:t,selectionEnd:n,selectionDirection:o}=e;null!==t&&null!==n&&null!==o&&(this._selection={start:t,end:n,direction:o})}_checkValueBoundaries(e){const{min:t,max:n}=this.props,o=function(e,t,n){const o=e>=t,i=e<=n;return{passMin:o,passMax:i,pass:o&&i,clamped:(0,D.clamp)(e,t,n)}}(e,t,n);return{value:o.pass}}}N.defaultProps=P;const T=/^-?[0-9]*$/,I=/^(-?([0-9]+\.?[0-9]*)|(-?[0-9]*))$/,_=/^(-?([0-9]+'?[0-9]*([0-9]+'?)[0-9]*)|(-?[0-9]*))$/;function M(e,t,n){return y(t=A(t))?"—":(null!==t&&void 0!==n&&(n=Math.max(R(t),n)),function(e,t){if(null===e)return"";return new S.NumericFormatter({precision:t}).format(e,{ignoreLocaleNumberFormat:!0})}(t,n))}function L(e){let t=0;return e.inheritPrecisionFromStep&&e.step<=1&&(t=R(e.step)),Math.max(e.precision,t)||void 0}function R(e){const t=Math.trunc(e).toString();return(0,D.clamp)(S.NumericFormatter.formatNoE(e).length-t.length-1,0,15)}function B(e,t){const n=new S.NumericFormatter({precision:t}).parse(e,{ignoreLocaleNumberFormat:!0});return n.res?n.value:NaN}function A(e){return"number"==typeof e&&Number.isFinite(e)||y(e)?e:null}var F=n(55482),W=n(14946),O=n(82347),z=n(12091);function G(e){const{color:t,thickness:n,thicknessItems:i,noAlpha:a,lineStyle:l,allowedLineStyles:s}=e,[c,d]=(0,r.useDefinitionProperty)({property:t}),[u,p]=(0,r.useDefinitionProperty)(n?{property:n}:{defaultValue:void 0}),[m,h]=(0,r.useDefinitionProperty)(l?{property:l}:{defaultValue:void 0}),f=(0,o.useMemo)((()=>s?z.defaultLineStyleItems.filter((e=>s.includes(e))):z.defaultLineStyleItems),[s]) ;return o.createElement(W.ColorSelect,{...e,color:function(){if(!c)return null;if("mixed"===c)return"mixed";return(0,F.rgbToHexString)((0,F.parseRgb)(c))}(),onColorChange:function(e){const t=c&&"mixed"!==c?(0,O.alphaToTransparency)((0,F.parseRgba)(c)[3]):0;d((0,O.generateColor)(String(e),t,!0))},thickness:u,lineStyle:m,thicknessItems:i,lineStyleItems:f,onThicknessChange:p,onLineStyleChange:h,opacity:a?void 0:c&&"mixed"!==c?(0,F.parseRgba)(c)[3]:void 0,onOpacityChange:a?void 0:function(e){d((0,O.generateColor)(c,(0,O.alphaToTransparency)(e),!0))}})}var H=n(68459),J=n(72958),K=n(40197),Z=n(21786),j=n(80633),$=n(53787);const U=[{type:H.LineEnd.Normal,icon:Z,label:u.t(null,void 0,n(93894))},{type:H.LineEnd.Arrow,icon:j,label:u.t(null,void 0,n(51979))}];class Y extends o.PureComponent{constructor(e){super(e),this._items=[],this._items=U.map((t=>({value:t.type,selectedContent:o.createElement(J.DisplayItem,{icon:t.icon}),content:o.createElement(J.DropItem,{icon:t.icon,iconClassName:c()(e.isRight&&$.right),label:t.label})})))}render(){const{id:e,lineEnd:t,className:n,lineEndChange:i,isRight:r,disabled:a}=this.props;return o.createElement(J.IconDropdown,{id:e,disabled:a,className:c()($.lineEndSelect,r&&$.right,n),items:this._items,value:t,onChange:i,hideArrowButton:!0,...(0,K.filterDataProps)(this.props)})}}function X(e){const{property:t}=e,[n,i]=(0,r.useDefinitionProperty)({property:t});return o.createElement(Y,{...e,lineEnd:n,lineEndChange:i})}var q,Q=n(46224),ee=n(59177);function te(e){const{children:t,className:n,breakPoint:i="Normal"}=e;return o.createElement(Q.CellWrap,{className:s(ee.wrap,n,ee[`breakpoint${i}`])},o.Children.map(t,(e=>o.isValidElement(e)?o.createElement("span",{key:null===e.key?void 0:e.key,className:s(ee.row,r(e)&&ee.empty,a(e)&&ee.noMargins)},e):e)));function r(e){return!(!o.isValidElement(e)||e.type!==o.Fragment||!Array.isArray(e.props.children))&&e.props.children.every((e=>null===e))}function a(e){return o.isValidElement(e)&&Boolean(e.props?.["data-no-margins"])}}!function(e){e.MobileNormal="Normal",e.MobileMedium="Medium",e.MobileSmall="Small"}(q||(q={}));const ne={1:"float",0:"integer"};var oe=n(58530),ie=n(20819),re=n(9774),ae=n(70670),le=n(47893),se=n(55501),ce=n(46269),de=n(21404),ue=n(1642),pe=n(69144),me=n(85739);function he(e){const{isDisabled:t,hint:n,label:i,isChecked:r,checkboxClassName:a,labelClassName:l,indeterminate:c,isActive:d,checkboxTabIndex:u,checkboxReference:p,checkboxDataRole:m,checkboxDataName:h,...f}=e;return o.createElement(ue.PopupMenuItem,{...f,isDisabled:t,shortcut:n,dontClosePopup:!0,labelRowClassName:l,label:o.createElement(pe.Checkbox,{reference:p,disabled:t,label:i,checked:c?"mixed":r,onChange:fe,className:s(me.checkbox,a),tabIndex:u,"data-role":m,"data-name":h})})}function fe(){}var be=n(99274);function ve(e){const[t,n]=(0,de.useRovingTabindexElement)(null);return o.createElement(he,{...e,className:be.item,checkboxClassName:be.checkbox,checkboxReference:t,checkboxTabIndex:n,checkboxDataRole:"menuitem",onKeyDown:function(e){const n=(0,le.hashFromEvent)(e) ;13!==n&&32!==n||(e.preventDefault(),t.current instanceof HTMLElement&&t.current.click())},"aria-disabled":e.isDisabled||void 0})}var ye=n(60714),ge=n(51075);function Ee(e){return!e.readonly&&!e.disabled}function we(e){const{selectedItems:t,placeholder:n}=e;if(!t.length)return o.createElement("span",null,n);const i=t.map((e=>e.selectedContent??e.content??e.value?.toString())).reduce(((e,t,n)=>t?(e.push(o.createElement("span",{key:n,className:ge.contentPart},t)),e.push(o.createElement("span",{key:`separator_${n}`},","," ")),e):e),[]);return i.length&&i.splice(-1),o.createElement("span",{className:ge.btnContent},i)}function Ce(e,t){const{id:n,items:i,menuClassName:r,menuItemClassName:a,tabIndex:l,disabled:s,highlight:c,intent:u,hideArrowButton:p,placeholder:m,value:h,"aria-labelledby":f,onFocus:b,onBlur:v,onClick:y,onChange:g,onKeyDown:E,openMenuOnEnter:w=!0,"aria-describedby":C,"aria-invalid":D,...S}=e,{listboxId:x,isOpened:V,isFocused:k,buttonTabIndex:P,highlight:N,intent:T,open:I,onOpen:_,close:M,toggle:L,buttonFocusBindings:R,onButtonClick:B,buttonRef:A,listboxRef:F,listboxTabIndex:W,buttonAria:O}=(0,ae.useControlDisclosure)({id:n,disabled:s,buttonTabIndex:l,intent:u,highlight:c,onFocus:b,onBlur:v,onClick:y}),z=i.filter(Ee).filter((e=>h.some((t=>e.value===t)))),G=(0,d.joinDomIds)(f,n),H=G.length>0?G:void 0,J=(0,o.useMemo)((()=>({role:"listbox","aria-labelledby":f})),[f]),K=(0,se.useKeyboardToggle)(L,V||w),Z=(0,se.useKeyboardOpen)(V,I),j=(0,se.useKeyboardEventHandler)([K,Z]),$=(0,re.useMergedRefs)([A,t]);return o.createElement(ce.ControlDisclosureView,{...S,...O,...R,id:n,role:"button",tabIndex:P,"aria-owns":O["aria-controls"],"aria-haspopup":"listbox","aria-labelledby":H,disabled:s,hideArrowButton:p,isFocused:k,isOpened:V,highlight:N,intent:T,ref:$,onClick:B,onClose:M,onKeyDown:j,onOpen:_,listboxTabIndex:W,listboxId:x,listboxClassName:r,listboxAria:J,"aria-describedby":C,"aria-invalid":D,listboxReference:F,onListboxKeyDown:function(e){switch((0,le.hashFromEvent)(e)){case 27:case 9:return void(V&&(e.preventDefault(),M()))}(0,ye.handleAccessibleMenuKeyDown)(e)},onListboxFocus:e=>(0,ye.handleAccessibleMenuFocus)(e,A),buttonChildren:o.createElement(we,{selectedItems:z??null,placeholder:m})},i.map(((e,t)=>{if(e.readonly)return o.createElement(o.Fragment,{key:`readonly_item_${t}`},e.content);const i=function(e,t){return t?.id??(0,d.createDomId)(e,"item",t?.value)}(n,e);return o.createElement(ve,{key:i,id:i,className:a,"aria-selected":h===e.value,isChecked:h.includes(e.value),label:e.content??e.value?.toString()??"",onClick:()=>function(e){const t=new Set(h);t.has(e)?t.delete(e):t.add(e);g(Array.from(t))}(e.value),isDisabled:e.disabled})})))}Ce.displayName="Multiselect";const De=o.forwardRef(Ce);function Se(e){return o.createElement(G,{...e})}var xe=n(28986),Ve=n(20425);function ke(e){const{property:t,options:n,...i}=e,[a,l]=(0,r.useDefinitionProperty)({property:t}),s=(0,Ve.useForceUpdate)();return(0,o.useEffect)((()=>{const e=()=>s();return Array.isArray(n)||n.subscribe(e),()=>{Array.isArray(n)||n.unsubscribe(e)}}),[]), o.createElement(xe.Select,{...i,onChange:l,value:a,items:(Array.isArray(n)?n:n.value()).map((e=>e.readonly?{content:e.title,readonly:e.readonly}:{content:e.title,value:e.value,disabled:e.disabled,id:e.id}))})}var Pe=n(9779),Ne=n(99189),Te=n(18923);function Ie(e){const{definition:t}=e,{checked:a,hideCheckbox:l,placeHolder:s,checkableListOptions:d,definitions:p,id:m}=t,[h,f]=(0,o.useState)(V()),[b,y]=(0,o.useState)(k()),g=(0,o.useContext)(Ne.ControlCustomWidthContext),[E]=(0,r.useDefinitionProperty)({property:a,defaultValue:!0});(0,o.useEffect)((()=>{const e={},t=()=>{const e=V();f(e)};return t(),d.forEach((n=>{n.properties.visible&&n.properties.visible.subscribe(e,t)})),()=>{d.forEach((n=>{n.properties.visible&&n.properties.visible.unsubscribe(e,t)}))}}),[t]),(0,o.useEffect)((()=>{const e={},t=()=>{const e=k();y(e)};return t(),h.forEach((n=>{n.properties.checked&&n.properties.checked.subscribe(e,t)})),()=>{h.forEach((n=>{n.properties.checked&&n.properties.checked.unsubscribe(e,t)}))}}),[h]);const w=[],C=[],D=[],S=[];p.value().forEach((e=>{(0,i.isPropertyDefinition)(e)&&((0,i.isColorDefinition)(e)?w.push(e):(0,i.isTwoColorDefinition)(e)?C.push(e):(0,i.isLineDefinition)(e)?D.push(e):(0,i.isOptionsDefinition)(e)&&S.push(e))}));const x=!E||0===b.length;return o.createElement(o.Fragment,null,o.createElement(ie.PropertyTable.Row,null,o.createElement(ie.PropertyTable.Cell,{placement:"first",verticalAlign:"adaptive",className:Te.cell,checkableTitle:!0},o.createElement(Pe.CheckableTitle,{name:`is-enabled-${t.id}`,title:t.title,property:l?void 0:a})),o.createElement(ie.PropertyTable.Cell,{placement:"last"},o.createElement("div",{className:Te.wrap},o.createElement(De,{className:c()(Te.select,g[m]&&Te[g[m]]),menuClassName:c()(Te.dropdownMenu,g[m]&&Te[g[m]]),placeholder:s||u.t(null,void 0,n(81242)),disabled:!E,onChange:function(e){const t=new Set(e);h.forEach((e=>{!t.has(e.id)||e.properties.checked?.value()?!t.has(e.id)&&e.properties.checked?.value()&&e.properties.checked.setValue(!1):(0,v.ensureDefined)(e.properties.checked).setValue(!0)}))},value:b,items:h.map((e=>({id:e.id,content:e.notFormatedTitle?o.createElement("span",{className:Te.preContent},(0,v.ensureDefined)(e.title)):(0,v.ensureDefined)(e.title),value:e.id})))}),w.length||D.length?o.createElement("div",{className:Te.colorsWrap},D.map((e=>o.createElement(G,{key:e.id,color:(0,v.ensureDefined)(e.properties.color),thickness:e.properties.width,thicknessItems:e.widthValues,disabled:x}))),w.map((e=>o.createElement(Se,{key:e.id,color:e.properties.color,disabled:x})))):null,C.length?C.map((e=>o.createElement("div",{key:e.id,className:Te.colorsWrap},o.createElement(Se,{color:e.properties.color1,disabled:x,noAlpha:e.noAlpha1}),o.createElement(Se,{color:e.properties.color2,disabled:x,noAlpha:e.noAlpha2})))):null))),S.map((e=>o.createElement(ie.PropertyTable.WrapRowInner,{key:e.id},o.createElement(ie.PropertyTable.Cell,{placement:"first"}),o.createElement(ie.PropertyTable.Cell,{placement:"last"},o.createElement(ke,{className:c()(Te.select,g[e.id]&&Te[g[e.id]]), menuClassName:c()(Te.dropdownMenu,g[e.id]&&Te[g[e.id]]),property:e.properties.option,options:e.options,disabled:x}))))));function V(){return d.filter((e=>void 0===e.properties.visible||e.properties.visible.value()))}function k(){return h.filter((e=>(0,v.ensureDefined)(e.properties?.checked).value())).map((e=>e.id))}}var _e=n(58653);function Me(e){const{definition:{id:t,properties:{checked:i,disabled:l,visible:c,leftEnd:b,rightEnd:v,value:y,extendLeft:g,extendRight:E,style:w,width:C,color:D},title:S,valueMin:x,valueMax:k,valueStep:P,valueUnit:N,extendLeftTitle:T,extendRightTitle:I,solutionId:_,widthValues:M},offset:L}=e,[R]=(0,r.useDefinitionProperty)({property:i,defaultValue:!0}),[B]=(0,r.useDefinitionProperty)({property:l,defaultValue:!1}),[A]=(0,r.useDefinitionProperty)({property:c,defaultValue:!0}),F=(0,oe.useWatchedValueReadonly)({watchedValue:x,defaultValue:void 0}),W=(0,oe.useWatchedValueReadonly)({watchedValue:k,defaultValue:void 0}),O=(0,oe.useWatchedValueReadonly)({watchedValue:P,defaultValue:void 0}),z=(0,oe.useWatchedValueReadonly)({watchedValue:N,defaultValue:void 0}),H=e.disabled||!R;return A?o.createElement(o.Fragment,null,o.createElement(a.CommonSection,{id:t,offset:L,checked:i,title:S,solutionId:_,disabled:e.disabled||B},o.createElement(te,{className:_e.line,breakPoint:"Small"},D&&o.createElement("span",{className:_e.control},o.createElement(G,{color:D,thickness:C,disabled:H,thicknessItems:M,lineStyle:w})),!D&&C&&o.createElement("span",{className:_e.control},o.createElement(f.LineWidthSelect,{id:(0,d.createDomId)(t,"line-width-select"),items:M,property:C,disabled:H})),!D&&w&&o.createElement("span",{className:_e.control},o.createElement(h.LineStyleSelect,{id:(0,d.createDomId)(t,"line-style-select"),property:w,disabled:H})),(b||v||y)&&o.createElement(o.Fragment,null,o.createElement(o.Fragment,null,b&&o.createElement(X,{id:(0,d.createDomId)(t,"left-end-select"),"data-name":"left-end-select",className:_e.control,property:b,disabled:H}),v&&o.createElement(X,{id:(0,d.createDomId)(t,"right-end-select"),"data-name":"right-end-select",className:_e.control,property:v,disabled:H,isRight:!0})),function(){const{definition:{valueType:t}}=e;return y&&o.createElement("span",{className:s(_e.valueInput,_e.control)},o.createElement(V,{className:_e.input,property:y,min:F,max:W,step:O,disabled:H,mode:void 0!==t?ne[t]:void 0,name:"line-value-input"}),o.createElement("span",{className:_e.valueUnit},z))}()))),(g||E)&&o.createElement(o.Fragment,null,function(){if(void 0!==g&&void 0!==E){const e=(0,m.createPropertyDefinitionsCheckableListOptionsGroup)([(0,p.createCheckablePropertyDefinition)({checked:g,disabled:l},{id:`${t}ExtendLeft`,title:T}),(0,p.createCheckablePropertyDefinition)({checked:E,disabled:l},{id:`${t}ExtendRight`,title:I})],void 0,[],"lineExtend",u.t(null,void 0,n(62726)),void 0,void 0,u.t(null,void 0,n(18656)));return o.createElement(Ie,{definition:e})}if(void 0!==g)return o.createElement(a.CommonSection,{id:`${t}ExtendLeft`,offset:L,checked:g,title:T,disabled:e.disabled||B}) ;if(void 0!==E)return o.createElement(a.CommonSection,{id:`${t}ExtendRight`,offset:L,checked:E,title:I,disabled:e.disabled||B});return}())):null}var Le=n(43787),Re=n(20438);const Be=[{title:u.t(null,void 0,n(49253)),value:Le.ColorType.Solid},{title:u.t(null,void 0,n(77728)),value:Le.ColorType.Gradient}],Ae=[1,2,3,4];function Fe(e){const{id:t,disabled:n,noAlpha:i,properties:a}=e,{color:l,gradientColor1:s,gradientColor2:c,type:u,width:p}=a,[m]=(0,r.useDefinitionProperty)({property:u,defaultValue:Le.ColorType.Solid});return o.createElement(te,null,u&&o.createElement(ke,{id:(0,d.createDomId)(t,"background-type-options-dropdown"),"data-name":"background-type-options-dropdown",className:Re.dropdown,menuClassName:Re.dropdownMenu,disabled:n,property:u,options:Be}),m!==Le.ColorType.Solid&&m&&s&&c?o.createElement("div",{className:Re.gradientColor},o.createElement(Se,{color:s,disabled:n,noAlpha:i}),o.createElement(Se,{color:c,disabled:n,noAlpha:i}),p&&o.createElement(f.LineWidthSelect,{className:Re.lineWidthSelect,property:p,items:Ae,disabled:!!n})):o.createElement(G,{color:l,disabled:n,noAlpha:i,thickness:p,thicknessItems:Ae}))}function We(e){const{definition:{id:t,properties:n,title:i,noAlpha:l,solutionId:s},offset:c}=e,{color:d,checked:u,disabled:p,visible:m}=n,[h]=(0,r.useDefinitionProperty)({property:u,defaultValue:!0}),[f]=(0,r.useDefinitionProperty)({property:p,defaultValue:!1}),[b]=(0,r.useDefinitionProperty)({property:m,defaultValue:!0}),v=e.disabled||!h;return b?o.createElement(a.CommonSection,{id:t,offset:c,checked:u,title:i,solutionId:s,disabled:e.disabled||f},o.createElement(Q.CellWrap,null,n.hasOwnProperty("type")?o.createElement(Fe,{id:t,properties:n,disabled:v,noAlpha:l}):o.createElement(Se,{color:d,disabled:v,noAlpha:l}))):null}var Oe=n(81264);function ze(e){const{property:t,...n}=e,[i,a]=(0,r.useDefinitionProperty)({property:t});return o.createElement(Oe.Transparency,{...n,value:i,onChange:a})}function Ge(e){const{definition:{id:t,properties:{transparency:n,checked:i,disabled:l,visible:s},title:c,solutionId:d},offset:u}=e,[p]=(0,r.useDefinitionProperty)({property:i,defaultValue:!0}),[m]=(0,r.useDefinitionProperty)({property:l,defaultValue:!1}),[h]=(0,r.useDefinitionProperty)({property:s,defaultValue:!0}),f=e.disabled||!p;return h?o.createElement(a.CommonSection,{id:t,offset:u,checked:i,title:c,solutionId:d,disabled:e.disabled||m},o.createElement(Q.CellWrap,null,o.createElement(ze,{property:n,disabled:f}))):null}var He=n(52907);function Je(e){const{definition:{id:t,properties:{color1:n,color2:i,checked:l,disabled:s,visible:c},title:d,noAlpha1:u,noAlpha2:p,solutionId:m},offset:h}=e,[f]=(0,r.useDefinitionProperty)({property:l,defaultValue:!0}),[b]=(0,r.useDefinitionProperty)({property:s,defaultValue:!1}),[v]=(0,r.useDefinitionProperty)({property:c,defaultValue:!0}),y=e.disabled||!f||b;return v?o.createElement(a.CommonSection,{id:t,offset:h,checked:l,solutionId:m,title:d,disabled:e.disabled||b},o.createElement(Q.CellWrap,{className:He.twoColors},g(n,u),g(i,p))):null;function g(e,t){return o.createElement("span",{ className:He.colorPicker},o.createElement(Se,{color:e,disabled:y,noAlpha:t}))}}var Ke=n(42683);function Ze(e){const{definition:{id:t,properties:{checked:n,value:i,unitOptionsValue:l,disabled:c,visible:u},min:p,max:m,step:h,title:f,unit:b,unitOptions:y,type:g,solutionId:E},offset:w}=e,[C]=(0,r.useDefinitionProperty)({property:n,defaultValue:!0}),[D]=(0,r.useDefinitionProperty)({property:c,defaultValue:!1}),[S]=(0,r.useDefinitionProperty)({property:u,defaultValue:!0}),x=(0,oe.useWatchedValueReadonly)({watchedValue:p,defaultValue:void 0}),k=(0,oe.useWatchedValueReadonly)({watchedValue:m,defaultValue:void 0}),P=(0,oe.useWatchedValueReadonly)({watchedValue:h,defaultValue:void 0}),N=(0,oe.useWatchedValueReadonly)({watchedValue:b,defaultValue:void 0}),T=(0,o.useContext)(Ne.ControlCustomWidthContext),I=D||e.disabled||!C;return S?o.createElement(a.CommonSection,{id:t,offset:w,checked:n,title:f,solutionId:E,disabled:e.disabled||D},o.createElement(Q.CellWrap,null,o.createElement(te,null,o.createElement(V,{className:s(Ke.input,T[t]&&Ke[T[t]]),property:i,min:x,max:k,step:P,disabled:I,mode:ne[g],name:"number-input","data-name":t}),l&&o.createElement(ke,{id:(0,d.createDomId)(t,"unit-options-dropdown"),"data-name":"unit-options-dropdown",className:Ke.dropdown,menuClassName:Ke.dropdownMenu,disabled:I,property:l,options:(0,v.ensureDefined)(y)})),N&&o.createElement("span",{className:Ke.unit},N))):null}function je(e){const{definition:{id:t,properties:{checked:n,disabled:i,visible:l},childrenDefinitions:s,title:c,solutionId:d,dialogContent:u},offset:p}=e,[m]=(0,r.useDefinitionProperty)({property:n,defaultValue:!0}),[h]=(0,r.useDefinitionProperty)({property:i,defaultValue:!1}),[f]=(0,r.useDefinitionProperty)({property:l,defaultValue:!0}),b=e.disabled||!m;return f?o.createElement(o.Fragment,null,o.createElement(a.CommonSection,{id:t,offset:p,checked:n,solutionId:d,title:c,disabled:e.disabled||h,dialogContent:u}),s.map((e=>o.createElement(ie.PropertyTable.WrapRowInner,{key:`wrapper-${e.id}`},o.createElement(cn,{key:e.id,disabled:b,definition:e,offset:!0}))))):null}var $e=n(66728);function Ue(e){const{property:t}=e,[n,i]=(0,r.useDefinitionProperty)({property:t});return o.createElement($e.FontSizeSelect,{...e,fontSize:n,fontSizeChange:i,"data-name":"font-size-select"})}var Ye=n(66334),Xe=n(3923);function qe(e){const{className:t,checked:n,icon:i,disabled:r,onClick:a}=e;return o.createElement("div",{className:c()(t,Xe.container,n&&!r&&Xe.active,r&&Xe.disabled),onClick:r?void 0:a,"data-role":"button",...(0,K.filterDataProps)(e)},o.createElement(Ye.Icon,{className:Xe.icon,icon:i}))}function Qe(e){const{icon:t,className:n,property:i,disabled:a}=e,[l,s]=(0,r.useDefinitionProperty)({property:i});return o.createElement(qe,{className:n,icon:t,checked:l,onClick:function(){s(!l)},disabled:a,...(0,K.filterDataProps)(e)})}var et=n(88169),tt=n(88340);function nt(e){const{property:t,...n}=e,[i,a]=(0,r.useDefinitionProperty)({property:t}),l=(0,o.useCallback)((e=>a(e.target.value)),[a]);return o.createElement(tt.Textarea,{...n,value:i,onChange:l})} var ot=n(19320),it=n(34943),rt=n(57471);const at=e=>({content:e.title,title:e.title,value:e.value,id:e.id}),lt=e=>({content:e.title,title:e.title,value:e.value,id:e.id});function st(e){const{definition:{id:t,properties:{color:n,size:i,checked:l,disabled:s,bold:c,italic:u,text:p,alignmentHorizontal:m,alignmentVertical:h,orientation:f,backgroundVisible:b,backgroundColor:v,borderVisible:y,borderColor:g,borderWidth:E,wrap:w},title:C,solutionId:D,sizeItems:S,alignmentTitle:x,alignmentHorizontalItems:V,alignmentVerticalItems:k,orientationTitle:P,orientationItems:N,backgroundTitle:T,borderTitle:I,borderWidthItems:_,wrapTitle:M,placeholder:L},offset:R}=e,B=(0,o.useContext)(Ne.ControlCustomHeightContext),[A]=(0,r.useDefinitionProperty)({property:l,defaultValue:!0}),[F]=(0,r.useDefinitionProperty)({property:s,defaultValue:!1}),[W,O]=(0,r.useDefinitionProperty)({property:h,defaultValue:void 0}),[z,H]=(0,r.useDefinitionProperty)({property:f,defaultValue:"horizontal"}),[J,K]=(0,r.useDefinitionProperty)({property:m,defaultValue:void 0}),[Z]=(0,r.useDefinitionProperty)({property:b,defaultValue:!1}),[j]=(0,r.useDefinitionProperty)({property:y,defaultValue:!1}),$=e.disabled||!A;return o.createElement(o.Fragment,null,function(){if(C)return o.createElement(a.CommonSection,{id:t,offset:R,checked:l,title:C,solutionId:D,disabled:e.disabled||F},o.createElement(te,{breakPoint:"Small"},X(),q()));return o.createElement(ie.PropertyTable.Row,null,o.createElement(ie.PropertyTable.Cell,{placement:"first",colSpan:2,offset:R,"data-qa-id":`property-dialog-item ${t}`},X(),q(),D&&!1))}(),p&&o.createElement(ie.PropertyTable.Row,null,o.createElement(ie.PropertyTable.Cell,{placement:"first",colSpan:2,offset:R,"data-qa-id":`property-dialog-item ${t}`},o.createElement(nt,{className:et.InputClasses.FontSizeMedium,rows:(U=B[t],"big"===U?9:5),stretch:!0,property:p,disabled:$,onFocus:function(e){e.target.select()},name:"text-input",placeholder:L}))),(m||h)&&o.createElement(ie.PropertyTable.Row,null,o.createElement(ie.PropertyTable.Cell,{placement:"first",verticalAlign:"adaptive",offset:R,"data-qa-id":`property-dialog-item ${t}`},o.createElement(Q.CellWrap,null,o.createElement("span",{className:rt.title},x))),o.createElement(ie.PropertyTable.Cell,{placement:"last",verticalAlign:"adaptive","data-qa-id":`property-dialog-item ${t}`},o.createElement(te,{breakPoint:"Small"},void 0!==W&&void 0!==k&&o.createElement(xe.Select,{id:(0,d.createDomId)(t,"alignment-vertical-select"),"data-name":"alignment-vertical-select",className:rt.dropdown,menuClassName:rt.dropdownMenu,disabled:$,value:W,items:k.map(at),onChange:O}),void 0!==J&&void 0!==V&&o.createElement(xe.Select,{id:(0,d.createDomId)(t,"alignment-horizontal-select"),"data-name":"alignment-horizontal-select",className:rt.dropdown,menuClassName:rt.dropdownMenu,disabled:$,value:J,items:V.map(at),onChange:K})))),void 0!==f&&void 0!==N&&o.createElement(ie.PropertyTable.Row,null,o.createElement(ie.PropertyTable.Cell,{placement:"first",verticalAlign:"adaptive",offset:R,"data-qa-id":`property-dialog-item ${t}` },o.createElement(Q.CellWrap,null,o.createElement("span",{className:rt.title},P))),o.createElement(ie.PropertyTable.Cell,{placement:"last",verticalAlign:"adaptive","data-qa-id":`property-dialog-item ${t}`},o.createElement(te,{breakPoint:"Small"},o.createElement(xe.Select,{id:(0,d.createDomId)(t,"orientation-select"),"data-name":"orientation-select",className:rt.dropdown,menuClassName:rt.dropdownMenu,disabled:$,value:z,items:N.map(lt),onChange:H})))),ee(T,b,v,!!b&&!Z),ee(I,y,g,!!y&&!j,E,_),w&&o.createElement(a.CommonSection,{id:`${t}Wrap`,offset:R,checked:w,title:M,disabled:e.disabled||F}));var U;function Y(e,t,n){return e?o.createElement(Qe,{className:rt.fontStyleButton,icon:t,property:e,disabled:$,"data-name":n}):null}function X(){return o.createElement(o.Fragment,null,n&&o.createElement("div",{className:rt.colorPicker},o.createElement(Se,{color:n,disabled:$})),i&&S&&o.createElement(Ue,{id:(0,d.createDomId)(t,"font-size-select"),property:i,fontSizes:S,disabled:$}))}function q(){return o.createElement(o.Fragment,null,Y(c,ot,"toggle-bold"),Y(u,it,"toggle-italic"))}function ee(e,n,i,r,l,s){return i||n?o.createElement(a.CommonSection,{id:`${t}ColorSelect`,offset:R,checked:n,title:e,disabled:$},i&&o.createElement(G,{color:i,thickness:l,thicknessItems:s,disabled:$||r})):null}}var ct=n(19308),dt=n(7321);function ut(e){const{property:t,mathOperations:n="+/*",mode:i="float",disabled:a,...l}=e,[s,c]=(0,o.useState)(performance.now()),[d,u]=(0,r.useDefinitionProperty)({property:t,handler:()=>c(performance.now())}),[p,m,h,f]=g(d,u,s),b=(0,o.useMemo)((()=>{const e=new RegExp(`^[${n.split("").join("\\")}-]?(${"float"===i?"(\\d+\\.\\d*)|":""}(\\d*))$`);return t=>(0,dt.isString)(t)&&e.test(t)}),[n,i]);return o.createElement(ct.FormInput,{...l,type:"text",value:p,onChange:function(e){const{value:t}=e.currentTarget;m(b(t)?t:p)},onKeyDown:function(e){if(e.defaultPrevented)return;switch((0,w.hashFromEvent)(e.nativeEvent)){case 27:f();break;case 13:v()}},onBlur:function(){v()},disabled:a,stretch:!1,autoSelectOnFocus:!0});function v(){p.length&&h()}}var pt=n(5643);function mt(e){const{definition:{properties:{x:t,y:n,disabled:i},id:r,title:a,solutionId:l},definition:s,offset:c}=e,d=i&&i.value()||e.disabled;return o.createElement(ie.PropertyTable.Row,null,o.createElement(ie.PropertyTable.Cell,{verticalAlign:"top",placement:"first",offset:c,"data-qa-id":`property-dialog-item ${r}`},o.createElement("span",{className:pt.coordinates},a)),(t||n)&&o.createElement(ie.PropertyTable.Cell,{placement:"last",offset:c,"data-qa-id":`property-dialog-item ${r}`},o.createElement(te,{breakPoint:"Medium"},"coordinates"===s.propType?o.createElement(ht,{definition:s,disabled:d}):o.createElement(ft,{definition:s,disabled:d})),l&&!1))}function ht(e){const{definition:{properties:{x:t,y:n},minX:i,maxX:r,stepX:a,minY:l,maxY:s,stepY:c,typeX:d,typeY:u},disabled:p}=e,m=(0,oe.useWatchedValueReadonly)({watchedValue:i,defaultValue:void 0}),h=(0,oe.useWatchedValueReadonly)({watchedValue:r,defaultValue:void 0}),f=(0,oe.useWatchedValueReadonly)({watchedValue:a, defaultValue:void 0}),b=(0,oe.useWatchedValueReadonly)({watchedValue:l,defaultValue:void 0}),v=(0,oe.useWatchedValueReadonly)({watchedValue:s,defaultValue:void 0}),y=(0,oe.useWatchedValueReadonly)({watchedValue:c,defaultValue:void 0});return o.createElement(o.Fragment,null,n&&o.createElement(V,{className:pt.input,property:n,min:b,max:v,step:y,disabled:p,name:"y-input",mode:void 0!==u?ne[u]:"integer"}),t&&o.createElement(V,{className:pt.input,property:t,min:m,max:h,step:f,disabled:p,name:"x-input",mode:void 0!==d?ne[d]:"integer"}))}function ft(e){const{definition:{properties:{x:t,y:i},mathOperationsX:r,mathOperationsY:a,modeX:l,modeY:s},disabled:c}=e;return o.createElement("div",{className:pt.selectionCoordinates},o.createElement("div",{className:pt.selectionCoordinates__inputs},i&&o.createElement(ut,{property:i,mathOperations:a,mode:s,disabled:c,className:pt.input,placeholder:u.t(null,void 0,n(51669))}),t&&o.createElement(ut,{property:t,mathOperations:r,mode:l,disabled:c,className:pt.input,placeholder:u.t(null,void 0,n(28175))})),o.createElement("div",{className:pt.selectionCoordinates__description},u.t(null,void 0,n(9866))))}var bt=n(49107);function vt(e){const{definition:{id:t,properties:{checked:n,option:i,disabled:l,visible:s,color:u,width:p,style:m},title:h,solutionId:f,options:b,infoTooltip:v},offset:y}=e,[g]=(0,r.useDefinitionProperty)({property:n,defaultValue:!0}),[E]=(0,r.useDefinitionProperty)({property:l,defaultValue:!1}),[w]=(0,r.useDefinitionProperty)({property:s,defaultValue:!0}),C=(0,o.useContext)(Ne.ControlCustomWidthContext),D=e.disabled||!g;return w?o.createElement(a.CommonSection,{id:t,offset:y,checked:n,title:h,solutionId:f,disabled:e.disabled||E,infoTooltip:v},o.createElement(Q.CellWrap,null,o.createElement(te,null,o.createElement(ke,{id:(0,d.createDomId)(t,"options-dropdown"),"data-name":"options-dropdown",className:c()(bt.dropdown,C[t]&&bt[C[t]]),menuClassName:c()(bt.dropdownMenu,C[t]&&bt[C[t]]),disabled:D||E,property:i,options:b}),u&&(void 0!==p||void 0!==m?o.createElement(G,{disabled:D,color:u,thickness:p,thicknessItems:p?[1,2,3,4]:void 0,lineStyle:m}):o.createElement(Se,{color:u,disabled:D}))))):null}var yt=n(42532);var gt,Et=n(39944),wt=n(81458),Ct=n(94205);!function(e){e[e.None=0]="None",e[e.From=1]="From",e[e.To=2]="To"}(gt||(gt={}));class Dt extends o.PureComponent{constructor(e){super(e),this._container=null,this._pointer=null,this._rafPosition=null,this._rafDragStop=null,this._refContainer=e=>{this._container=e},this._refPointer=e=>{this._pointer=e},this._handlePosition=e=>{null!==this._rafPosition||this.props.disabled||(this._rafPosition=requestAnimationFrame((()=>{const{from:t,to:n,min:o,max:i}=this.props,r=this._getNewPosition(e),a=1===this._detectPointerMode(e),l=a?(0,D.clamp)(r,o,n):t,s=a?n:(0,D.clamp)(r,t,i);l<=s&&this._handleChange(l,s),this._rafPosition=null})))},this._handleDragStop=()=>{null!==this._rafDragStop||this.props.disabled||(this._rafDragStop=requestAnimationFrame((()=>{this.setState({pointerDragMode:0}),this._rafDragStop=null,this.props.onCommit()})))}, this._onSliderClick=e=>{x.CheckMobile.any()||(this._handlePosition(e.nativeEvent),this._dragSubscribe())},this._mouseUp=e=>{this._dragUnsubscribe(),this._handlePosition(e),this._handleDragStop()},this._mouseMove=e=>{this._handlePosition(e)},this._onTouchStart=e=>{this._handlePosition(e.nativeEvent.touches[0])},this._handleTouch=e=>{this._handlePosition(e.nativeEvent.touches[0])},this._handleTouchEnd=()=>{this._handleDragStop()},this.state={pointerDragMode:0}}componentWillUnmount(){null!==this._rafPosition&&(cancelAnimationFrame(this._rafPosition),this._rafPosition=null),null!==this._rafDragStop&&(cancelAnimationFrame(this._rafDragStop),this._rafDragStop=null),this._dragUnsubscribe()}render(){const{className:e,disabled:t,from:n,to:i,min:r,max:a}=this.props,{pointerDragMode:l}=this.state,c=0!==l,d=a-r,u=0===d?r:(n-r)/d,p=0===d?a:(i-r)/d,m=(0,wt.isRtl)()?"right":"left";return o.createElement("div",{className:s(e,Ct.range,t&&Ct.disabled)},o.createElement("div",{className:Ct.rangeSlider,ref:this._refContainer,onMouseDown:this._onSliderClick,onTouchStart:this._onTouchStart,onTouchMove:this._handleTouch,onTouchEnd:this._handleTouchEnd},o.createElement("div",{className:Ct.rangeSliderMiddleWrap},o.createElement("div",{className:s(Ct.rangeSliderMiddle,c&&Ct.dragged),style:{[m]:100*u+"%",width:100*(p-u)+"%"}})),o.createElement("div",{className:Ct.rangePointerWrap},o.createElement("div",{className:s(Ct.pointer,c&&Ct.dragged),style:{[m]:100*u+"%"},ref:this._refPointer})),o.createElement("div",{className:Ct.rangePointerWrap},o.createElement("div",{className:s(Ct.pointer,c&&Ct.dragged),style:{[m]:100*p+"%"}}))))}_dragSubscribe(){const e=(0,v.ensureNotNull)(this._container).ownerDocument;e&&(e.addEventListener("mouseup",this._mouseUp),e.addEventListener("mousemove",this._mouseMove))}_dragUnsubscribe(){const e=(0,v.ensureNotNull)(this._container).ownerDocument;e&&(e.removeEventListener("mousemove",this._mouseMove),e.removeEventListener("mouseup",this._mouseUp))}_getNewPosition(e){const{min:t,max:n}=this.props,o=n-t,i=(0,v.ensureNotNull)(this._container),r=(0,v.ensureNotNull)(this._pointer),a=i.getBoundingClientRect(),l=r.offsetWidth;let s=e.clientX-l/2-a.left;return(0,wt.isRtl)()&&(s=a.width-s-l),(0,D.clamp)(s/(a.width-l),0,1)*o+t}_detectPointerMode(e){const{from:t,to:n}=this.props,{pointerDragMode:o}=this.state;if(0!==o)return o;const i=this._getNewPosition(e),r=Math.abs(t-i),a=Math.abs(n-i),l=r===a?io.createElement(te,{breakPoint:"Medium"},o.createElement(o.Fragment,null,o.createElement("span",{className:xt.valueInput},o.createElement(k,{className:xt.input,sharedBuffer:P,min:E,max:y(M)?w:M,step:1,disabled:A,name:"from-input",mode:"integer",defaultValue:E}),e?o.createElement("span",{className:xt.rangeSlider},"—"):o.createElement(Dt,{className:c()(xt.rangeSlider,B&&xt.rangeSlider_mixed),from:B?E:N,to:B?w:M,min:E,max:w,onChange:W,onCommit:O,disabled:A}))),o.createElement(o.Fragment,null,o.createElement("span",{className:xt.valueInput},o.createElement(k,{className:xt.input,sharedBuffer:_,min:y(N)?E:N,max:w,step:1,disabled:A,name:"to-input",mode:"integer",defaultValue:w}),u&&!1)))))}()));function W(e,t){T(Math.round(e)),L(Math.round(t))}function O(){F.flushed||(I(),R(),F.flushed=!0)}}var kt=n(83186),Pt=n(42830);function Nt(e){const{definitions:t,name:n,offset:i}=e,r=c()(Pt.cell,Pt.fragmentCell,t.some((e=>void 0!==e.solutionId))&&Pt.largeWidth);return o.createElement(ie.PropertyTable.Row,null,o.createElement(ie.PropertyTable.Cell,{className:r,offset:i,placement:"first",verticalAlign:"adaptive",colSpan:2,"data-qa-id":`property-dialog-item ${n}`,checkableTitle:!0},t.map((e=>o.createElement("div",{className:Pt.item,key:e.id,"data-qa-id":`property-dialog-item ${e.id}`},o.createElement(It,{definition:e}))))))}function Tt(e){const{definition:t,offset:n}=e;return o.createElement(ie.PropertyTable.Row,null,o.createElement(ie.PropertyTable.Cell,{className:Pt.cell,offset:n,placement:"first",verticalAlign:"adaptive",colSpan:2,checkableTitle:!0},o.createElement(It,{definition:t})))}function It(e){const{definition:{id:t,properties:{disabled:n,checked:i,color:a,level:l,width:s,style:u},solutionId:p,title:m,widthValues:f,styleValues:b,locked:v}}=e,[y]=(0,r.useDefinitionProperty)({property:i,defaultValue:!0}),[g]=(0,r.useDefinitionProperty)({property:n,defaultValue:!1}),E=g||!y;return o.createElement(o.Fragment,null,o.createElement(Pe.CheckableTitle,{name:`is-enabled-${t}`,className:c()(m&&Pt.withTitle,v&&Pt.hidden),title:m&&o.createElement("span",{className:Pt.title},m),property:i,disabled:g}),l&&o.createElement(V,{className:c()(Pt.input,Pt.control),property:l,disabled:E}),a&&o.createElement(G,{className:Pt.control,disabled:E,color:a,thickness:s,thicknessItems:f,lineStyle:u,allowedLineStyles:b}),!a&&u&&o.createElement(h.LineStyleSelect,{id:(0,d.createDomId)(t,"leveled-line-style-select"),className:Pt.control,property:u,disabled:E,allowedLineStyles:b}),p&&!1)}var _t=n(11019);function Mt(e){ const{definition:{id:t,properties:{option1:n,option2:i,checked:l,disabled:s},title:c,solutionId:u,optionsItems1:p,optionsItems2:m},offset:h}=e,[f]=(0,r.useDefinitionProperty)({property:l,defaultValue:!0}),[b]=(0,r.useDefinitionProperty)({property:s,defaultValue:!1}),v=e.disabled||!f;return o.createElement(a.CommonSection,{id:t,offset:h,checked:l,title:c,solutionId:u,disabled:e.disabled||b},o.createElement(te,{className:_t.twoOptions},o.createElement(ke,{id:(0,d.createDomId)(t,"two-options-dropdown-1"),"data-name":"two-options-dropdown-1",className:_t.dropdown,menuClassName:_t.menu,property:n,disabled:v,options:p}),o.createElement(ke,{id:(0,d.createDomId)(t,"two-options-dropdown-2"),"data-name":"two-options-dropdown-2",className:_t.dropdown,menuClassName:_t.menu,property:i,disabled:v,options:m})))}var Lt=n(57069),Rt=n(60039);function Bt(e){const{definition:{id:t,properties:{color1:n,color2:i,option:r},options:l,color1Visible:s,color2Visible:u,title:p,noAlpha1:m,noAlpha2:h,solutionId:f},offset:b}=e,v=(0,Lt.useWatchedValueReadonly)({watchedValue:s,defaultValue:!1}),y=(0,Lt.useWatchedValueReadonly)({watchedValue:u,defaultValue:!1}),g=(0,o.useContext)(Ne.ControlCustomWidthContext);return o.createElement(a.CommonSection,{id:t,offset:b,solutionId:f,title:p},o.createElement(Q.CellWrap,{className:Rt.optionalTwoColors},o.createElement(te,null,o.createElement(ke,{id:(0,d.createDomId)(t,"options-dropdown"),"data-name":"options-dropdown",className:c()(Rt.dropdown,g[t]&&Rt[g[t]]),menuClassName:c()(Rt.dropdownMenu,g[t]&&Rt[g[t]]),property:r,options:l}),o.createElement(o.Fragment,null,v&&E(n,m),y&&E(i,h)))));function E(e,t){return o.createElement("span",{className:Rt.colorPicker},o.createElement(Se,{color:e,noAlpha:t}))}}var At=n(62352),Ft=n(28187),Wt=n(65399),Ot=n(24981),zt=n(74129),Gt=n(22419);function Ht(e){const{source:t,inputs:n,model:i,inputsTabProperty:r,studyMetaInfo:a}=e.definition,l=(0,o.useMemo)((()=>(0,zt.getStudyInfo)(a,t)),[a]),s=(0,o.useCallback)(((e,n,o,a)=>{const l=a??r.inputs;(0,Ot.setPropertyThroughUndoModel)({value:e,id:n,name:o,model:i,isStudyLineTool:!(0,At.isStudy)(t),property:l})}),[i,t,r]);return o.createElement(Wt.UserInputsTabContent,{className:Gt.withoutPadding,property:r,studyInfo:l,inputs:n,setProperty:s,tzName:(0,Ft.getTimezoneName)(i)})}var Jt=n(11284),Kt=n(32563),Zt=n(41027);function jt(e){const{definition:{id:t,title:n,properties:i,solutionId:l},offset:s}=e,{checked:c,emoji:d,backgroundColor:u}=i,[p]=(0,r.useDefinitionProperty)({property:c,defaultValue:!1}),[m,h]=(0,r.useDefinitionProperty)({property:d,defaultValue:"🙂"}),[f,b]=(0,r.useDefinitionProperty)({property:u,defaultValue:Jt.colorsPalette["color-tv-blue-a600"]}),[v]=(0,r.useDefinitionProperty)({property:i.disabled,defaultValue:!1}),y=e.disabled||!p;return o.createElement(a.CommonSection,{id:t,offset:s,checked:c,title:n,solutionId:l,disabled:e.disabled||v},o.createElement(Kt.EmojiPicker,{value:m,disabled:y,onSelect:h}),o.createElement(W.ColorSelect,{className:Zt.colorSelect,disabled:y,color:function(){if("mixed"===f)return f;return(0, F.rgbToHexString)((0,F.parseRgb)(f))}(),opacity:f&&"mixed"!==f?(0,F.parseRgba)(f)[3]:void 0,onColorChange:function(e){const t=f&&"mixed"!==f?(0,O.alphaToTransparency)((0,F.parseRgba)(f)[3]):0;b((0,O.generateColor)(String(e),t,!0))},onOpacityChange:function(e){b((0,O.generateColor)(f,(0,O.alphaToTransparency)(e),!0))}}))}function $t(e){const{definition:{id:t,properties:{disabled:n,visible:i},childrenDefinitions:l,title:s},offset:c}=e,[d]=(0,r.useDefinitionProperty)({property:n,defaultValue:!1}),[u]=(0,r.useDefinitionProperty)({property:i,defaultValue:!0}),p=e.disabled;return u?o.createElement(o.Fragment,null,s&&o.createElement(a.CommonSection,{id:t,offset:c,title:s,disabled:e.disabled||d}),l.map((e=>o.createElement(ie.PropertyTable.WrapRowInner,{key:`wrapper-${e.id}`},o.createElement(cn,{key:e.id,disabled:p,definition:e,offset:e.offset??Boolean(s)}))))):null}var Ut=n(74457);function Yt(e){const{label:t,checked:n,disabled:i,onChange:r,hint:a,dataName:l,dataQaId:s,description:c,onCheckboxFocus:d,onCheckboxBlur:u}=e;return o.createElement(o.Fragment,null,o.createElement("div",{className:Ut.container},o.createElement("div",{onMouseDown:d,onMouseUp:u},o.createElement(pe.Checkbox,{checked:n,disabled:i,onChange:function(){r(!n)},label:t,labelAlignBaseline:!0,className:Ut.checkbox,"data-name":l,dataQaId:s})),!1),c&&o.createElement("div",{className:Ut.description},c))}var Xt=n(38343);function qt(e){const{definition:{id:t,properties:{checked:n,visible:i,disabled:a},title:l,solutionId:s,infoTooltip:c},offset:d}=e,[u]=(0,r.useDefinitionProperty)({property:i,defaultValue:!0}),[p]=(0,r.useDefinitionProperty)({property:a,defaultValue:!1}),[m,h]=(0,r.useDefinitionProperty)({property:n,defaultValue:Boolean(n?.value())});return u?o.createElement(ie.PropertyTable.Row,null,o.createElement(ie.PropertyTable.Cell,{placement:"first",verticalAlign:"adaptive",offset:d,"data-qa-id":`property-dialog-item ${t}`,checkableTitle:!0,colSpan:2},o.createElement("div",{className:Xt.checkboxWrapper},o.createElement(Yt,{dataQaId:t,label:l??"",checked:Boolean(m),disabled:Boolean(p),description:c,hint:s?{solutionId:s,title:l??""}:void 0,dataName:t,onChange:e=>{h(e)}})))):null}var Qt=n(93107);function en(e){const{definition:{id:t,properties:{checked:n,visible:i,disabled:l,option:s},title:d,options:u,solutionId:p,childrenDefinition:m},offset:h,disabled:f}=e,b=(0,o.useContext)(Ne.ControlCustomWidthContext),[v]=(0,r.useDefinitionProperty)({property:l,defaultValue:!1}),[y]=(0,r.useDefinitionProperty)({property:n,defaultValue:!0}),[g]=(0,r.useDefinitionProperty)({property:i,defaultValue:!0}),E=f||!y;return g?o.createElement(a.CommonSection,{id:t,offset:h,checked:n,title:d,solutionId:p,disabled:f||v},o.createElement(Q.CellWrap,null,o.createElement(te,null,o.createElement(ke,{property:s,options:u,disabled:E||v,className:c()(Qt.dropdown,"normal"===b[t]&&Qt.dropdown_width_normal,"big"===b[t]&&Qt.dropdown_width_big),menuClassName:c()(Qt.dropdown__menu,"normal"===b[t]&&Qt.dropdown__menu_width_normal,"big"===b[t]&&Qt.dropdown__menu_width_big), "data-name":"options-dropdown","data-qa-id":"options-dropdown"}),o.createElement(tn,{definition:m,disabled:E})))):null}function tn(e){const{definition:t,disabled:n}=e;switch(t.propType){case"color":return o.createElement(nn,{definition:t,disabled:n});case"twoColors":return o.createElement(on,{definition:t,disabled:n});case"line":return o.createElement(rn,{definition:t,disabled:n});case"options":return o.createElement(ln,{definition:t,disabled:n});case"number":return o.createElement(sn,{definition:t,disabled:n});default:return null}}function nn(e){const{definition:{properties:{color:t,disabled:n}},disabled:i}=e,[a]=(0,r.useDefinitionProperty)({property:n,defaultValue:!1});return o.createElement(Se,{color:t,disabled:i||a})}function on(e){const{definition:{properties:{color1:t,color2:n,disabled:i},color1Visible:a,color2Visible:l,noAlpha1:s,noAlpha2:c},disabled:d}=e,[u]=(0,r.useDefinitionProperty)({property:i,defaultValue:!1}),p=(0,Lt.useWatchedValueReadonly)({watchedValue:a,defaultValue:!1}),m=(0,Lt.useWatchedValueReadonly)({watchedValue:l,defaultValue:!1});return o.createElement("div",{className:Qt.optionalSetChild},p&&o.createElement(Se,{color:t,disabled:d||u,noAlpha:s}),m&&o.createElement(Se,{color:n,disabled:d||u,noAlpha:c}))}function rn(e){const{definition:{properties:{color:t,width:n,style:i}},disabled:r}=e;return o.createElement(G,{disabled:r,color:t,thickness:n,lineStyle:i,thicknessItems:n?an:void 0})}const an=[1,2,3,4];function ln(e){const{definition:{properties:{option:t},id:n,options:i},disabled:r}=e,a=(0,o.useContext)(Ne.ControlCustomWidthContext);return o.createElement(ke,{property:t,options:i,disabled:r,className:c()(Qt.dropdown,"normal"===a[n]&&Qt.dropdown_width_normal,"big"===a[n]&&Qt.dropdown_width_big),menuClassName:c()(Qt.dropdown__menu,"normal"===a[n]&&Qt.dropdown__menu_width_normal,"big"===a[n]&&Qt.dropdown__menu_width_big)})}function sn(e){const{definition:{id:t,properties:{value:n},min:i,max:r,unit:a},disabled:l}=e,s=(0,o.useContext)(Ne.ControlCustomWidthContext),d=(0,Lt.useWatchedValueReadonly)({watchedValue:i,defaultValue:void 0}),u=(0,Lt.useWatchedValueReadonly)({watchedValue:r,defaultValue:void 0}),p=(0,Lt.useWatchedValueReadonly)({watchedValue:a,defaultValue:void 0});return o.createElement("div",{className:Qt.optionalSetChild},o.createElement(V,{property:n,min:d,max:u,disabled:l,className:c()(Qt.numberChildInput,"normal"===s[t]&&Qt.numberChildInput_width_normal,"big"===s[t]&&Qt.numberChildInput_width_big)}),p&&o.createElement("span",null,p))}function cn(e){const{definition:t,offset:n,disabled:r}=e;if(function(e){(0,o.useEffect)((()=>{if(void 0===e)return;const t={...e.properties};return Object.entries(t).forEach((([n,o])=>{void 0!==o&&o.subscribe(t,(()=>yt.logger.logNormal(`Property "${n}" in definition "${e.id}" was updated to value "${o.value()}"`)))})),()=>{Object.entries(t).forEach((([,e])=>{e?.unsubscribeAll(t)}))}}),[e])}((0,i.isPropertyDefinitionsGroup)(t)?void 0:t),(0,i.isPropertyDefinitionsGroup)(t))return o.createElement(dn,{definition:t,offset:n,disabled:r});switch(t.propType){ case"line":return o.createElement(Me,{...e,definition:t});case"checkable":return o.createElement(l,{...e,definition:t});case"color":return o.createElement(We,{...e,definition:t});case"transparency":return o.createElement(Ge,{...e,definition:t});case"twoColors":return o.createElement(Je,{...e,definition:t});case"optionalTwoColors":return o.createElement(Bt,{...e,definition:t});case"fourColors":case"session":case"multiSession":case"soundSelect":case"soundVolume":case"image":default:return null;case"number":return o.createElement(Ze,{...e,definition:t});case"symbol":return o.createElement(Et.SymbolSection,{...e,definition:t});case"text":return o.createElement(st,{...e,definition:t});case"checkableSet":return o.createElement(je,{...e,definition:t});case"set":return o.createElement($t,{...e,definition:t});case"options":return o.createElement(vt,{...e,definition:t});case"range":return o.createElement(Vt,{...e,definition:t});case"coordinates":case"selectionCoordinates":return o.createElement(mt,{...e,definition:t});case"twoOptions":return o.createElement(Mt,{...e,definition:t});case"leveledLine":return o.createElement(Tt,{...e,definition:t});case"emoji":return o.createElement(jt,{...e,definition:t});case"studyInputs":return o.createElement(Ht,{...e,definition:t});case"checkableWithDescription":return o.createElement(qt,{...e,definition:t});case"optionalSet":return o.createElement(en,{definition:t,disabled:r})}}function dn(e){const{definition:t}=e,n=(0,oe.useWatchedValueReadonly)({watchedValue:t.definitions});return(0,oe.useWatchedValueReadonly)({watchedValue:t.visible,defaultValue:!0})?(0,i.isCheckableListOptionsDefinition)(t)?o.createElement(Ie,{definition:t}):o.createElement(o.Fragment,null,t.title&&o.createElement(kt.GroupTitleSection,{title:t.title,name:t.id}),n&&function(e){const t=[];return e.reduce(((e,t)=>{if((0,i.isPropertyDefinitionsGroup)(t)||"leveledLine"!==t.propType)e.push(t);else{const n=e[e.length-1];Array.isArray(n)?n.push(t):e.push([t])}return e}),t)}(n).map((n=>Array.isArray(n)?o.createElement(Nt,{key:n[0].id,name:t.id,definitions:n}):o.createElement(cn,{key:n.id,...e,definition:n}))),"general"===t.groupType&&o.createElement(ie.PropertyTable.GroupSeparator,{size:1})):null}},46269:(e,t,n)=>{"use strict";n.d(t,{ControlDisclosureView:()=>m});var o=n(79474),i=n(14487),r=n.n(i),a=n(9774),l=n(88169),s=n(29914),c=n(78484),d=n(19840),u=n(91965),p=n(27094);const m=o.forwardRef(((e,t)=>{const{listboxId:n,className:i,listboxClassName:m,listboxTabIndex:h,hideArrowButton:f,matchButtonAndListboxWidths:b,popupPosition:v,disabled:y,isOpened:g,scrollWrapReference:E,repositionOnScroll:w,closeOnHeaderOverlap:C,listboxReference:D,size:S="small",onClose:x,onOpen:V,onListboxFocus:k,onListboxBlur:P,onListboxKeyDown:N,buttonChildren:T,children:I,caretClassName:_,buttonContainerClassName:M,listboxAria:L,dataQaId:R,...B}=e,A=(0,o.useRef)(null),F=!f&&o.createElement(c.EndSlot,null,o.createElement(u.Caret,{isDropped:g,disabled:!0,className:_}));return o.createElement(d.PopupMenuDisclosureView,{buttonRef:A,listboxId:n, listboxClassName:m,listboxTabIndex:h,isOpened:g,onClose:x,onOpen:V,listboxReference:D,scrollWrapReference:E,onListboxFocus:k,onListboxBlur:P,onListboxKeyDown:N,listboxAria:L,dataQaId:(0,s.dataQaIds)("popup-menu-container",R),matchButtonAndListboxWidths:b,popupPosition:v,button:o.createElement(l.ControlSkeleton,{...B,"data-qa-id":(0,s.dataQaIds)("ui-kit-disclosure-control",R),"data-role":"listbox",disabled:y,className:r()(p.button,i),size:S,ref:(0,a.useMergedRefs)([A,t]),middleSlot:o.createElement(c.MiddleSlot,null,o.createElement("span",{className:r()(p["button-children"],f&&p.hiddenArrow,M)},T)),endSlot:F}),popupChildren:I,repositionOnScroll:w,closeOnHeaderOverlap:C})}));m.displayName="ControlDisclosureView"},15923:(e,t,n)=>{"use strict";n.d(t,{ControlDisclosure:()=>d});var o=n(79474),i=n(9774),r=n(55501),a=n(46269),l=n(70670),s=n(23351),c=n(27094);const d=o.forwardRef(((e,t)=>{const{id:n,tabIndex:d,disabled:u,highlight:p,intent:m,children:h,onClick:f,onFocus:b,onBlur:v,listboxAria:y,onListboxKeyDown:g,...E}=e,w=(0,o.useRef)({"aria-labelledby":n}),{listboxId:C,isOpened:D,isFocused:S,buttonTabIndex:x,listboxTabIndex:V,highlight:k,intent:P,onOpen:N,close:T,toggle:I,buttonFocusBindings:_,onButtonClick:M,buttonRef:L,listboxRef:R,buttonAria:B}=(0,l.useControlDisclosure)({id:n,disabled:u,buttonTabIndex:d,intent:m,highlight:p,onFocus:b,onBlur:v,onClick:f}),A=(0,r.useKeyboardToggle)(I),F=(0,r.useKeyboardClose)(D,T),W=(0,r.useKeyboardEventHandler)([A,F]);return o.createElement(a.ControlDisclosureView,{...E,..._,...B,id:n,role:"button",tabIndex:x,disabled:u,isOpened:D,isFocused:S,ref:(0,i.useMergedRefs)([L,t]),highlight:k,intent:P,onClose:T,onOpen:N,onClick:M,onKeyDown:W,listboxId:C,listboxTabIndex:V,listboxReference:R,listboxAria:y??w.current,onListboxKeyDown:function(e){if(27===(0,s.hashFromEvent)(e))return e.preventDefault(),void T();g?.(e)}},h,o.createElement("span",{className:c.invisibleFocusHandler,tabIndex:0,"aria-hidden":!0,onFocus:()=>T()}))}));d.displayName="ControlDisclosure"},32563:(e,t,n)=>{"use strict";n.d(t,{EmojiPicker:()=>N});var o=n(79474),i=n(82287),r=n(29844),a=n(41277),l=n(65946);var s=n(29344),c=n(17896),d=n(77690),u=n(86738),p=n(47893),m=n(73283),h=n(54466);function f(e){!function(e,t){(0,o.useEffect)((()=>{const n=t||document;return n.addEventListener("scroll",e),()=>n.removeEventListener("scroll",e)}),[e])}(e,document)}var b=n(86739),v=n(73873),y=n(14487),g=n.n(y),E=n(56138);function w(e){const{children:t,highlight:n,disabled:i,reference:r,...a}=e,l=n?"primary":"default";return o.createElement("div",{...a,ref:r,className:g()(E.wrapper,E[`intent-${l}`],E["border-thin"],E["size-medium"],n&&E.highlight,n&&E.focused,i&&E.disabled),"data-role":"button"},o.createElement("div",{className:g()(E.childrenContainer,i&&E.disabled)},t),n&&o.createElement("span",{className:E.shadow}))}var C=n(7717),D=n(74237);const S=()=>null,x=(0,m.mergeThemes)(u.DEFAULT_MENU_THEME,{menuBox:D.menuBox}),V=378,k=18,P=200;function N(e){const{value:t,disabled:n,onSelect:a,onClose:u,canBeEmpty:m,renderButton:y=T}=e,g=(0, o.useRef)(null),{current:E}=(0,o.useRef)((w=t,i.getJSON("RecentlyUsedEmojis",[w]).filter((e=>e!==C.EMPTY_EMOJI))));var w;const N=(0,o.useRef)(null),[I,_]=(0,o.useState)(E),[M,L]=(0,o.useState)(!1),R=(0,o.useRef)(null),B=(0,o.useCallback)((()=>{L(!1),u?.(),R.current=null}),[u]);f((0,o.useCallback)((()=>{!R.current||Date.now()-R.current{if(e!==C.EMPTY_EMOJI){const t=Array.from(new Set([e,...I])).slice(0,k);i.setJSON("RecentlyUsedEmojis",t),_(t)}a(e),B()}),[I,a]),F=(0,o.useMemo)((()=>m?[C.EMPTY_EMOJI,...I].slice(0,k):I),[I,m]),W=(O=F,(0,o.useMemo)((()=>{const e=(0,l.emojiGroups)();return e[0].emojis=O,e}),[O]));var O;return o.createElement(o.Fragment,null,o.createElement("div",{ref:g,className:D.buttonWrap},y({emoji:t,isOpened:M,disabled:n,onClick:function(){if(M)return void B();n||(L(!0),R.current=Date.now())}})),o.createElement(h.MatchMedia,{rule:v.DialogBreakpoints.TabletSmall},(e=>M&&o.createElement(c.DrawerManager,null,e?o.createElement(d.Drawer,{className:D.drawer,position:"Bottom",onClose:B,"data-qa-id":"emojipicker-menu"},o.createElement(r.EmojiList,{emojis:W,onSelect:A,height:V})):o.createElement(s.PopupMenu,{theme:x,onKeyDown:G,isOpened:!0,position:(0,b.getPopupPositioner)(g.current,{horizontalDropDirection:b.HorizontalDropDirection.FromLeftToRight,horizontalAttachEdge:b.HorizontalAttachEdge.Left}),closeOnClickOutside:!1,onClickOutside:H,onClose:S,controller:N,onOpen:z,tabIndex:-1,dataQaId:"emojipicker-menu"},o.createElement(r.EmojiList,{className:D.desktopSize,emojis:W,onSelect:A,height:V}))))));function z(){N.current?.focus()}function G(e){27===(0,p.hashFromEvent)(e)&&(e.preventDefault(),e.stopPropagation(),B())}function H(e){const t=e.target;t instanceof Node&&g.current?.contains(t)||B()}}function T(e){const{emoji:t,isOpened:n,disabled:i,onClick:r}=e;return o.createElement(w,{highlight:n,disabled:i,"data-name":"emoji-picker"},o.createElement(a.EmojiWrap,{emoji:t,onClick:r}))}},55501:(e,t,n)=>{"use strict";n.d(t,{useKeyboardActionHandler:()=>o.useKeyboardActionHandler,useKeyboardClose:()=>o.useKeyboardClose,useKeyboardEventHandler:()=>o.useKeyboardEventHandler,useKeyboardOpen:()=>o.useKeyboardOpen,useKeyboardToggle:()=>o.useKeyboardToggle});var o=n(4724)},28986:(e,t,n)=>{"use strict";n.d(t,{Select:()=>w});var o=n(79474),i=n(69947),r=n(48504),a=n(51970),l=n(9774),s=n(83683),c=n(1642),d=n(88434),u=n(89315);var p=n(6831),m=n(55501),h=n(46269),f=n(70670),b=n(81458),v=n(42785);function y(e){return!e.readonly}function g(e,t){return t?.id??(0,r.createDomId)(e,"item",t?.value)}function E(e){const{selectedItem:t,placeholder:n}=e;if(!t)return o.createElement("span",{className:v.placeholder},n);const i=t.selectedContent??t.content??t.value;return o.createElement("span",null,i)}const w=o.forwardRef(((e,t)=>{ const{id:n,menuClassName:v,menuItemClassName:w,tabIndex:C,disabled:D,highlight:S,intent:x,hideArrowButton:V,placeholder:k,addPlaceholderToItems:P=!1,value:N,"aria-labelledby":T,onFocus:I,onBlur:_,onClick:M,onChange:L,onKeyDown:R,repositionOnScroll:B=!0,openMenuOnEnter:A=!0,"aria-describedby":F,"aria-invalid":W,...O}=e;let{items:z}=e;if(k&&P){z=[{value:void 0,content:k,id:(0,r.createDomId)(n,"placeholder")},...z]}const{listboxId:G,isOpened:H,isFocused:J,buttonTabIndex:K,listboxTabIndex:Z,highlight:j,intent:$,open:U,onOpen:Y,close:X,toggle:q,buttonFocusBindings:Q,onButtonClick:ee,buttonRef:te,listboxRef:ne,buttonAria:oe}=(0,f.useControlDisclosure)({id:n,disabled:D,buttonTabIndex:C,intent:x,highlight:S,onFocus:I,onBlur:_,onClick:M});!function(e,t,n){const i=(0,a.usePrevious)(e);(0,o.useEffect)((()=>{e&&!i&&t?.(),!e&&i&&n?.()}),[e])}(H,e.onOpen,e.onClose);const ie=z.filter(y),re=ie.find((e=>e.value===N)),[ae,le]=o.useState(k&&P?ie[0].value:re?.value),[se,ce,de]=(0,s.useKeepActiveItemIntoView)({activeItem:re});(0,i.useIsomorphicLayoutEffect)((()=>le(re?.value)),[N]);const ue=(0,r.joinDomIds)(T,n),pe=ue.length>0?ue:void 0,me=(0,o.useMemo)((()=>({role:"listbox","aria-labelledby":T,"aria-activedescendant":g(n,re)})),[T,re]),he=(0,o.useCallback)((e=>e.value===ae),[ae]),fe=(0,o.useCallback)((()=>(X(),L&&L(ae))),[X,L,ae]),be=(0,p.useItemsKeyboardNavigation)("vertical",b.isRtl,ie,he,(t=>{le(t.value),e.onItemNavigated?.(t)}),!1,{next:[40],previous:[38]}),ve=(0,m.useKeyboardToggle)(q,H||A),ye=(0,m.useKeyboardToggle)(fe),ge=(0,m.useKeyboardClose)(H,xe),Ee=(0,m.useKeyboardOpen)(H,U),we=(0,m.useKeyboardEventHandler)([ve,ge,Ee]),Ce=(0,m.useKeyboardEventHandler)([be,ye,ge]),De=function(e){const t=(0,o.useRef)(""),n=(0,o.useMemo)((()=>(0,d.default)((()=>{t.current=""}),500)),[]),i=(0,o.useMemo)((()=>(0,u.default)(e,200)),[e]);return(0,o.useCallback)((e=>{e.key.length>0&&e.key.length<3&&(t.current+=e.key,i(t.current,e),n())}),[n,i])}(((t,n)=>{const o=function(e,t,n){return e.find((e=>{const o=t.toLowerCase();return!e.readonly&&(n?n(e).toLowerCase().startsWith(o):!e.readonly&&("string"==typeof e.content&&e.content.toLowerCase().startsWith(o)||"string"==typeof e.textContent&&e.textContent.toLowerCase().startsWith(o)||String(e.value??"").toLowerCase().startsWith(o)))}))}(ie,t,e.getSearchKey);void 0!==o&&L&&(n.stopPropagation(),H||U(),L(o.value))}));return o.createElement(h.ControlDisclosureView,{...O,...oe,...Q,id:n,role:"button",tabIndex:K,"aria-owns":oe["aria-controls"],"aria-haspopup":"listbox","aria-labelledby":pe,disabled:D,hideArrowButton:V,isFocused:J,isOpened:H,highlight:j,intent:$,ref:(0,l.useMergedRefs)([te,t]),onClick:ee,onOpen:function(){de(re,{duration:0}),Y()},onClose:xe,onKeyDown:function(e){we(e),R&&R(e);e.defaultPrevented||De(e)},listboxId:G,listboxTabIndex:Z,listboxClassName:v,listboxAria:me,"aria-describedby":F,"aria-invalid":W,listboxReference:ne,scrollWrapReference:se,onListboxKeyDown:function(e){Ce(e),e.defaultPrevented||De(e)},buttonChildren:o.createElement(E,{selectedItem:re??null,placeholder:k}),repositionOnScroll:B },z.map(((t,i)=>{if(t.readonly)return o.createElement(o.Fragment,{key:`readonly_item_${i}`},t.content);const r=g(n,t);return o.createElement(c.PopupMenuItem,{key:r,id:r,className:w,role:"option","aria-selected":N===t.value,isActive:ae===t.value,label:t.content??t.value,onClick:Se,onClickArg:t.value,isDisabled:t.disabled,reference:e=>ce(t,e),onMouseOver:()=>e.onItemMouseOver?.(t),onMouseOut:()=>e.onItemMouseOut?.(t)})})));function Se(e){L&&(L(e),le(e))}function xe(){le(re?.value),X()}}));w.displayName="Select"},57058:(e,t,n)=>{"use strict";n.d(t,{RemoveButton:()=>u});var o=n(91599),i=n(79474),r=n(14487),a=n.n(r),l=n(66334),s=n(28390),c=n(6693),d=n(36779);function u(e){const{className:t,isActive:r,onClick:u,onMouseDown:p,title:m,hidden:h,"data-name":f="remove-button",icon:b,...v}=e,[y,g]=(0,s.useActiveDescendant)(null);return i.createElement(l.Icon,{...v,"data-name":f,className:a()(d.button,"apply-common-tooltip",r&&d.active,h&&d.hidden,g&&d.focused,t),icon:b||c,onClick:u,onMouseDown:p,title:m??o.t(null,void 0,n(91126)),ariaLabel:m??o.t(null,void 0,n(91126)),ref:y})}},99274:e=>{e.exports={checkbox:"checkbox-hcyAOCXc",item:"item-hcyAOCXc"}},60714:(e,t,n)=>{"use strict";n.d(t,{focusFirstMenuItem:()=>d,handleAccessibleMenuFocus:()=>s,handleAccessibleMenuKeyDown:()=>c,queryMenuElements:()=>m});var o=n(78122),i=n(87918),r=n(23351),a=n(45280);const l=[37,39,38,40];function s(e,t){if(!e.target)return;const n=e.relatedTarget?.getAttribute("aria-activedescendant");if(e.relatedTarget!==t.current){const e=n&&document.getElementById(n);if(!e||e!==t.current)return}d(e.target)}function c(e){if(e.defaultPrevented)return;const t=(0,r.hashFromEvent)(e);if(!l.includes(t))return;const n=document.activeElement;if(!(document.activeElement instanceof HTMLElement))return;const a=m(e.currentTarget).sort(o.navigationOrderComparator);if(0===a.length)return;const s=document.activeElement.closest('[data-role="menuitem"]')||document.activeElement.parentElement?.querySelector('[data-role="menuitem"]');if(!(s instanceof HTMLElement))return;const c=a.indexOf(s);if(-1===c)return;const d=h(s),f=d.indexOf(document.activeElement),b=-1!==f,v=e=>{n&&(0,i.becomeSecondaryElement)(n),(0,i.becomeMainElement)(e),e.focus()};switch((0,o.mapKeyCodeToDirection)(t)){case"inlinePrev":if(!d.length)return;e.preventDefault(),v(0===f?a[c]:b?u(d,f,-1):d[d.length-1]);break;case"inlineNext":if(!d.length)return;e.preventDefault(),f===d.length-1?v(a[c]):v(b?u(d,f,1):d[0]);break;case"blockPrev":{e.preventDefault();const t=u(a,c,-1);if(b){const e=p(t,f);v(e||t);break}v(t);break}case"blockNext":{e.preventDefault();const t=u(a,c,1);if(b){const e=p(t,f);v(e||t);break}v(t)}}}function d(e){const[t]=m(e);t&&((0,i.becomeMainElement)(t),t.focus())}function u(e,t,n){return e[(t+e.length+n)%e.length]}function p(e,t){const n=h(e);return n.length?n[(t+n.length)%n.length]:null}function m(e){return Array.from(e.querySelectorAll('[data-role="menuitem"]:not([disabled]):not([aria-disabled="true" i])')).filter((0,a.createScopedVisibleElementFilter)(e))}function h(e){ return Array.from(e.querySelectorAll('[tabindex]:not([disabled]):not([aria-disabled="true" i])')).filter((0,a.createScopedVisibleElementFilter)(e))}},86739:(e,t,n)=>{"use strict";n.d(t,{HorizontalAttachEdge:()=>i,HorizontalDropDirection:()=>a,VerticalAttachEdge:()=>o,VerticalDropDirection:()=>r,getPopupPositioner:()=>c});var o,i,r,a,l=n(85842);!function(e){e[e.Top=0]="Top",e[e.Bottom=1]="Bottom",e[e.AutoStrict=2]="AutoStrict"}(o||(o={})),function(e){e[e.Left=0]="Left",e[e.Right=1]="Right"}(i||(i={})),function(e){e[e.FromTopToBottom=0]="FromTopToBottom",e[e.FromBottomToTop=1]="FromBottomToTop"}(r||(r={})),function(e){e[e.FromLeftToRight=0]="FromLeftToRight",e[e.FromRightToLeft=1]="FromRightToLeft"}(a||(a={}));const s={verticalAttachEdge:o.Bottom,horizontalAttachEdge:i.Left,verticalDropDirection:r.FromTopToBottom,horizontalDropDirection:a.FromLeftToRight,verticalMargin:0,horizontalMargin:0,matchButtonAndListboxWidths:!1};function c(e,t){return n=>{const{contentWidth:c,contentHeight:d,availableHeight:u}=n,p=(0,l.ensureNotNull)(e).getBoundingClientRect(),{horizontalAttachEdge:m=s.horizontalAttachEdge,horizontalDropDirection:h=s.horizontalDropDirection,horizontalMargin:f=s.horizontalMargin,verticalMargin:b=s.verticalMargin,matchButtonAndListboxWidths:v=s.matchButtonAndListboxWidths}=t;let y=t.verticalAttachEdge??s.verticalAttachEdge,g=t.verticalDropDirection??s.verticalDropDirection;y===o.AutoStrict&&(u{"use strict";n.d(t,{createPropertyDefinitionsCheckableListOptionsGroup:()=>i});var o=n(89659);function i(e,t,n,i,r,a,l,s){return{id:i,title:r,visible:a,groupType:"checkableListOptions",checked:t,definitions:new o.WatchedValue(n),checkableListOptions:e,hideCheckbox:l,placeHolder:s}}},11614:(e,t,n)=>{"use strict";function o(e,t){return{propType:"checkable",properties:e,notFormatedTitle:!1,...t}}n.d(t,{createCheckablePropertyDefinition:()=>o})},42644:(e,t,n)=>{"use strict";n.d(t,{getColorDefinitionProperty:()=>c,getStdColorDefinitionProperty:()=>d});var o=n(55482),i=n(82347),r=n(20707),a=n(74970),l=n(93204);function s(e,t){if((0,i.isHexColor)(e)){const n=(0,o.parseRgb)(e);return(0,o.rgbaToString)((0,o.rgba)(n,(100-t)/100))}return e}function c(e,t,n,o,i){let l;if(null!==n){const e=(0,r.combineProperty)(s,t.weakReference(),n.weakReference());l=(0,a.makeProxyDefinitionProperty)(e.ownership())}else l=(0,a.makeProxyDefinitionProperty)(t.weakReference(),[()=>s(t.value(),0),e=>e]);return l.setValue=n=>{i&&e.beginUndoMacro(o),e.setProperty(t,n,o),i&&e.endUndoMacro()},l}function d(e,t,n,o,i){const s=(0,a.makeProxyDefinitionProperty)((0,r.combineProperty)((e=>t.value(e)),function(e){const t=(0,l.createPrimitiveProperty)(e.value()),n=e=>t.setValue(e);return t.destroy=()=>{e.release(),e.unsubscribe(n)},e.subscribe(n),t }(n).ownership(),t.weakReference()).ownership());var c;return s.setValue=(c=n=>{e.setProperty(t,n,o)},i?(...t)=>{e.beginUndoMacro(o),c(...t),e.endUndoMacro()}:c),s}},74970:(e,t,n)=>{"use strict";n.d(t,{convertToDefinitionProperty:()=>r,makeProxyDefinitionProperty:()=>i});var o=n(64906);function i(e,t,n){const o=new Map,i=void 0!==t?t[0]:e=>e,r=void 0!==t?void 0!==t[1]?t[1]:t[0]:e=>e,a={value:()=>i(e.value()),setValue:t=>{e.setValue(r(t))},subscribe:(t,n)=>{const i=e=>{n(a)};o.set(n,i),e.subscribe(t,i)},unsubscribe:(t,n)=>{const i=o.get(n);i&&(e.unsubscribe(t,i),o.delete(n))},unsubscribeAll:t=>{e.unsubscribeAll(t),o.clear()},destroy:()=>{e.release(),n?.()}};return a}function r(e,t,n,r,a,l,s){const c=i(t.weakReference(),r,l),d=void 0!==r?void 0!==r[1]?r[1]:r[0]:e=>e,u=a??(o=>e.setProperty(t,d(o),n));return c.setValue=e=>{s&&(0,o.trackEvent)(s.category,s.event,s.label?.(e)),u(e)},c}},90082:(e,t,n)=>{"use strict";n.d(t,{createLinePropertyDefinition:()=>s});var o=n(68459),i=n(80140);const r=[i.LINESTYLE_SOLID,i.LINESTYLE_DOTTED,i.LINESTYLE_DASHED],a=[1,2,3,4],l=[o.LineEnd.Normal,o.LineEnd.Arrow];function s(e,t){const n={propType:"line",properties:e,...t};return void 0!==n.properties.style&&(n.styleValues=r),void 0!==n.properties.width&&(n.widthValues=a),void 0===n.properties.leftEnd&&void 0===n.properties.rightEnd||void 0!==n.endsValues||(n.endsValues=l),void 0!==n.properties.value&&void 0===n.valueType&&(n.valueType=1),n}},1341:(e,t,n)=>{"use strict";var o;function i(e,t){return{propType:"number",properties:e,type:1,...t}}n.d(t,{createNumberPropertyDefinition:()=>i}),function(e){e[e.Integer=0]="Integer",e[e.Float=1]="Float"}(o||(o={}))},54484:(e,t,n)=>{"use strict";function o(e,t){return{propType:"options",properties:e,...t}}n.d(t,{createOptionsPropertyDefinition:()=>o})},73405:(e,t,n)=>{"use strict";n.d(t,{convertFromReadonlyWVToDefinitionProperty:()=>H,convertFromWVToDefinitionProperty:()=>G,convertToDefinitionProperty:()=>O.convertToDefinitionProperty,createCheckablePropertyDefinition:()=>o.createCheckablePropertyDefinition,createCheckableSetPropertyDefinition:()=>i,createColorPropertyDefinition:()=>r,createCoordinatesPropertyDefinition:()=>k,createEmojiPropertyDefinition:()=>L,createImagePropertyDefinition:()=>M,createLeveledLinePropertyDefinition:()=>d,createLinePropertyDefinition:()=>a.createLinePropertyDefinition,createNumberPropertyDefinition:()=>u.createNumberPropertyDefinition,createOptionalTwoColorsPropertyDefinition:()=>V,createOptionsPropertyDefinition:()=>p.createOptionsPropertyDefinition,createPropertyDefinitionsCheckableListOptionsGroup:()=>F.createPropertyDefinitionsCheckableListOptionsGroup,createPropertyDefinitionsGeneralGroup:()=>A,createPropertyDefinitionsLeveledLinesGroup:()=>W,createRangePropertyDefinition:()=>N,createSelectionCoordinatesPropertyDefinition:()=>P,createSessionPropertyDefinition:()=>_,createStudyInputsPropertyDefinition:()=>R,createSymbolPropertyDefinition:()=>I,createTextPropertyDefinition:()=>S,createTransparencyPropertyDefinition:()=>T,createTwoColorsPropertyDefinition:()=>x, createTwoOptionsPropertyDefinition:()=>m,destroyDefinitions:()=>ne,getColorDefinitionProperty:()=>j.getColorDefinitionProperty,getLockPriceScaleDefinitionProperty:()=>K,getPriceScaleSelectionStrategyDefinitionProperty:()=>J,getScaleRatioDefinitionProperty:()=>Z,getSymbolDefinitionProperty:()=>$,isCheckableListOptionsDefinition:()=>te,isColorDefinition:()=>q,isLineDefinition:()=>X,isOptionsDefinition:()=>ee,isPropertyDefinition:()=>U,isPropertyDefinitionsGroup:()=>Y,isTwoColorDefinition:()=>Q,makeProxyDefinitionProperty:()=>O.makeProxyDefinitionProperty});var o=n(11614);function i(e,t,n){return{propType:"checkableSet",properties:e,childrenDefinitions:n,...t}}function r(e,t){return{propType:"color",properties:e,noAlpha:!1,...t}}var a=n(90082),l=n(80140);const s=[l.LINESTYLE_SOLID,l.LINESTYLE_DOTTED,l.LINESTYLE_DASHED],c=[1,2,3,4];function d(e,t){const n={propType:"leveledLine",properties:e,...t};return void 0!==n.properties.style&&(n.styleValues=s),void 0!==n.properties.width&&(n.widthValues=c),n}var u=n(1341),p=n(54484);function m(e,t){return{propType:"twoOptions",properties:e,...t}}var h,f=n(91599),b=n(95385);!function(e){e.Horizontal="horizontal",e.Vertical="vertical"}(h||(h={}));const v=[{id:b.VerticalAlign.Top,value:b.VerticalAlign.Bottom,title:f.t(null,void 0,n(65388))},{id:b.VerticalAlign.Middle,value:b.VerticalAlign.Middle,title:f.t(null,void 0,n(55636))},{id:b.VerticalAlign.Bottom,value:b.VerticalAlign.Top,title:f.t(null,void 0,n(65244))}],y=[{id:b.HorizontalAlign.Left,value:b.HorizontalAlign.Left,title:f.t(null,void 0,n(48816))},{id:b.HorizontalAlign.Center,value:b.HorizontalAlign.Center,title:f.t(null,void 0,n(93283))},{id:b.HorizontalAlign.Right,value:b.HorizontalAlign.Right,title:f.t(null,void 0,n(98415))}],g=[{id:"horizontal",value:"horizontal",title:f.t(null,void 0,n(88837))},{id:"vertical",value:"vertical",title:f.t(null,void 0,n(503))}],E=[8,10,11,12,14,16,18,20,22,24,28,32,40].map((e=>({title:String(e),value:e}))),w=[1,2,3,4],C=f.t(null,void 0,n(74953)),D=f.t(null,void 0,n(37223));function S(e,t){const n={propType:"text",properties:e,...t,isEditable:t.isEditable||!1};return void 0!==n.properties.size&&void 0===n.sizeItems&&(n.sizeItems=E),void 0!==n.properties.alignmentVertical&&void 0===n.alignmentVerticalItems&&(n.alignmentVerticalItems=v),void 0!==n.properties.alignmentHorizontal&&void 0===n.alignmentHorizontalItems&&(n.alignmentHorizontalItems=y),(n.alignmentVerticalItems||n.alignmentHorizontalItems)&&void 0===n.alignmentTitle&&(n.alignmentTitle=C),void 0!==n.properties.orientation&&(void 0===n.orientationItems&&(n.orientationItems=g),void 0===n.orientationTitle&&(n.orientationTitle=D)),void 0!==n.properties.borderWidth&&void 0===n.borderWidthItems&&(n.borderWidthItems=w),n}function x(e,t){return{propType:"twoColors",properties:e,noAlpha1:!1,noAlpha2:!1,...t}}function V(e,t){return{propType:"optionalTwoColors",properties:e,noAlpha1:!1,noAlpha2:!1,...t}}function k(e,t){return{propType:"coordinates",properties:e,...t}}function P(e,t){return{propType:"selectionCoordinates",properties:e,...t}} function N(e,t){return{propType:"range",properties:e,...t}}function T(e,t){return{propType:"transparency",properties:e,...t}}function I(e,t){return{propType:"symbol",properties:e,...t}}function _(e,t){return{propType:"session",properties:e,...t}}function M(e,t){return{propType:"image",properties:e,...t}}function L(e,t){return{propType:"emoji",properties:e,...t}}function R(e,t){return{propType:"studyInputs",properties:e,...t}}var B=n(89659);function A(e,t,n,o){return{id:t,title:n,visible:o,groupType:"general",definitions:new B.WatchedValue(e)}}var F=n(21566);function W(e,t,n){return{id:t,title:n,groupType:"leveledLines",definitions:new B.WatchedValue(e)}}var O=n(74970);function z(e,t,n){const o=new Map,i=void 0!==t?t[0]:e=>e,r=void 0!==t?void 0!==t[1]?t[1]:t[0]:e=>e,a={value:()=>i(e.value()),setValue:t=>{e.setValue?.(r(t))},subscribe:(t,n)=>{const i=()=>{n(a)};let r=o.get(t);void 0===r?(r=new Map,r.set(n,i),o.set(t,r)):r.set(n,i),e.subscribe(i)},unsubscribe:(t,n)=>{const i=o.get(t);if(void 0!==i){const t=i.get(n);void 0!==t&&(e.unsubscribe(t),i.delete(n))}},unsubscribeAll:t=>{const n=o.get(t);void 0!==n&&(n.forEach(((t,n)=>{e.unsubscribe(t)})),n.clear())}};return n&&(a.destroy=()=>n()),a}function G(e,t,n,o,i){const r=z(t,o,i),a=void 0!==o?void 0!==o[1]?o[1]:o[0]:e=>e;return r.setValue=o=>e.setWatchedValue(t,a(o),n),r}function H(e,t){return function(e,t,n,o){const i=new Map,r={subscribe:(n,o)=>{const r=e=>n(t(e));i.set(n,r),e.subscribe(r,o)},unsubscribe:t=>{if(t){const n=i.get(t);n&&(e.unsubscribe(n),i.delete(t))}else i.clear(),e.unsubscribe()},value:()=>t(e.value())};return z(r,n,o)}(e,(e=>e),t,(()=>e.release()))}function J(e,t){const n=(0,O.makeProxyDefinitionProperty)(t.weakReference());return n.setValue=t=>e.setPriceScaleSelectionStrategy(t),n}function K(e,t,n,o){const i=(0,O.makeProxyDefinitionProperty)(t.weakReference());return i.setValue=t=>{const i={lockScale:t};e.setPriceScaleMode(i,n,o)},i}function Z(e,t,n,o){const i=(0,O.makeProxyDefinitionProperty)(t.weakReference(),o);return i.setValue=o=>{e.setScaleRatioProperty(t,o,n)},i}var j=n(42644);function $(e,t,n,o,i,r){const a=[(l=n,s=t,e=>{const t=l(s);if(e===s.value()&&null!==t){const e=t.ticker||t.full_name;if(e)return e}return e}),e=>e];var l,s;const c=(0,O.convertToDefinitionProperty)(e,t,i,a);r&&(c.setValue=r);const d=new Map;c.subscribe=(e,n)=>{const o=e=>{n(c)};d.set(n,o),t.subscribe(e,o)},c.unsubscribe=(e,n)=>{const o=d.get(n);o&&(t.unsubscribe(e,o),d.delete(n))};const u={};return o.subscribe(u,(()=>{d.forEach(((e,t)=>{t(c)}))})),c.destroy=()=>{o.unsubscribeAll(u),d.clear()},c}function U(e){return e.hasOwnProperty("propType")}function Y(e){return e.hasOwnProperty("groupType")}function X(e){return"line"===e.propType}function q(e){return"color"===e.propType}function Q(e){return"twoColors"===e.propType}function ee(e){return"options"===e.propType}function te(e){return"checkableListOptions"===e.groupType}function ne(e){e.forEach((e=>{if(U(e)){Object.keys(e.properties).forEach((t=>{const n=e.properties[t];void 0!==n&&void 0!==n.destroy&&n.destroy()})) }else ne(e.definitions.value()),e.visible?.destroy()}))}},24981:(e,t,n)=>{"use strict";n.d(t,{setPropertyThroughUndoModel:()=>d});var o=n(72769),i=n(60135),r=n(34773),a=n(85842),l=n(82372),s=n(40451);const c=new o.TranslatedString("change {propertyName} property",i.t(null,{context:"undo input change"},n(1717)));function d(e){const{id:t,model:n,name:i,property:d,value:u,isStudyLineTool:p=!1}=e,m=(0,a.ensureDefined)(e.property.child(t)),h=new o.TranslatedString(i,(0,l.getTranslatedInputTitle)(i));s.logger.logNormal(`Changing property "${t}" value from "${d.value()}" to "${u}"`),n.setProperty(m,u,c.format({propertyName:h}),p&&r.lineToolsDoNotAffectChartInvalidation)}},32509:e=>{e.exports=''},78025:e=>{e.exports=''},6693:e=>{e.exports=''},1018:e=>{e.exports=''},26317:e=>{e.exports=''},51528:e=>{e.exports=''},85658:e=>{e.exports=''},80633:e=>{e.exports=''},21786:e=>{e.exports=''},19320:e=>{ e.exports=''},34943:e=>{e.exports=''}}]);