Files
web/public/charting_library/bundles/9370.112f4e73192a88ff71b8.js
2024-09-18 00:59:26 -04:00

24 lines
70 KiB
JavaScript
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

(self.webpackChunktradingview=self.webpackChunktradingview||[]).push([[9370],{80671: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"}},35550:e=>{e.exports={defaultSelect:"defaultSelect-OM7V5ndi"}},71272:e=>{e.exports={itemWrap:"itemWrap-srH7jxJB",item:"item-srH7jxJB",icon:"icon-srH7jxJB",selected:"selected-srH7jxJB",label:"label-srH7jxJB"}},89654:e=>{e.exports={lineEndSelect:"lineEndSelect-gw7ESiZg",right:"right-gw7ESiZg"}},28527:e=>{e.exports={lineStyleSelect:"lineStyleSelect-GcXENVb4",multipleStyles:"multipleStyles-GcXENVb4"}},10477:e=>{e.exports={lineWidthSelect:"lineWidthSelect-EUDB1YgB",bar:"bar-EUDB1YgB",isActive:"isActive-EUDB1YgB",item:"item-EUDB1YgB"}},9309:e=>{e.exports={container:"container-dhpv13DH",active:"active-dhpv13DH",disabled:"disabled-dhpv13DH",icon:"icon-dhpv13DH"}},58510:e=>{e.exports={wrap:"wrap-b6_0ORMg",disabled:"disabled-b6_0ORMg"}},34306:e=>{e.exports={dropdown:"dropdown-gZlS9p6t",dropdownMenu:"dropdownMenu-gZlS9p6t",firstColorPicker:"firstColorPicker-gZlS9p6t"}},38188:e=>{e.exports={row:"row-nGXZ4vJz",empty:"empty-nGXZ4vJz",noMargins:"noMargins-nGXZ4vJz",wrap:"wrap-nGXZ4vJz",breakpointNormal:"breakpointNormal-nGXZ4vJz",breakpointMedium:"breakpointMedium-nGXZ4vJz",breakpointSmall:"breakpointSmall-nGXZ4vJz"}},72972: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"}},5200:e=>{e.exports={wrapper:"wrapper-NVcHMTVy",checkbox:"checkbox-NVcHMTVy",colorSelect:"colorSelect-NVcHMTVy",hintButton:"hintButton-NVcHMTVy"}},97616:e=>{e.exports={withoutPadding:"withoutPadding-KtEcG0Q0"}},93234: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"}},56659:e=>{e.exports={line:"line-j5rMaiWF",control:"control-j5rMaiWF",valueInput:"valueInput-j5rMaiWF",valueUnit:"valueUnit-j5rMaiWF",
input:"input-j5rMaiWF"}},3218:e=>{e.exports={unit:"unit-ZtRdVxiD",input:"input-ZtRdVxiD",normal:"normal-ZtRdVxiD",big:"big-ZtRdVxiD",dropdown:"dropdown-ZtRdVxiD",dropdownMenu:"dropdownMenu-ZtRdVxiD"}},80640:e=>{e.exports={optionalTwoColors:"optionalTwoColors-LDRcAXEV",colorPicker:"colorPicker-LDRcAXEV",dropdown:"dropdown-LDRcAXEV",dropdownMenu:"dropdownMenu-LDRcAXEV"}},73943:e=>{e.exports={dropdown:"dropdown-RxdEkbF0",normal:"normal-RxdEkbF0",big:"big-RxdEkbF0",dropdownMenu:"dropdownMenu-RxdEkbF0"}},18707:e=>{e.exports={range:"range-GLEBGed4",valueInput:"valueInput-GLEBGed4",rangeSlider:"rangeSlider-GLEBGed4",rangeSlider_mixed:"rangeSlider_mixed-GLEBGed4",input:"input-GLEBGed4",hintButton:"hintButton-GLEBGed4"}},47908:e=>{e.exports={select:"select-hJtsYZ3G",wrap:"wrap-hJtsYZ3G",colorsWrap:"colorsWrap-hJtsYZ3G"}},23018:e=>{e.exports={colorPicker:"colorPicker-VK3h8amb",fontStyleButton:"fontStyleButton-VK3h8amb",dropdown:"dropdown-VK3h8amb",dropdownMenu:"dropdownMenu-VK3h8amb",hintButton:"hintButton-VK3h8amb",title:"title-VK3h8amb"}},56198:e=>{e.exports={twoColors:"twoColors-C2hZXnYv",colorPicker:"colorPicker-C2hZXnYv"}},16731:e=>{e.exports={dropdown:"dropdown-eLkGg0Ft",menu:"menu-eLkGg0Ft"}},21775:e=>{e.exports={desktopSize:"desktopSize-icygBqe7",drawer:"drawer-icygBqe7",menuBox:"menuBox-icygBqe7"}},83821:e=>{e.exports={btnContent:"btnContent-ivexqeZZ",contentPart:"contentPart-ivexqeZZ"}},58128:e=>{e.exports={checkbox:"checkbox-aOSYFxuH"}},9161: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"}},11772:e=>{e.exports={button:"button-iLKiGOdQ",hovered:"hovered-iLKiGOdQ",disabled:"disabled-iLKiGOdQ",active:"active-iLKiGOdQ",hidden:"hidden-iLKiGOdQ"}},66045:(e,t,n)=>{"use strict";n.d(t,{FontSizeSelect:()=>c});var o=n(50959),i=n(97754),r=n.n(i),l=n(90405),a=n(90186),s=n(35550);function c(e){const{id:t,fontSize:n,fontSizes:i=[],className:c,disabled:d,fontSizeChange:u}=e;return o.createElement(l.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,a.filterDataProps)(e)});var p}},94697:(e,t,n)=>{"use strict";n.d(t,{DisplayItem:()=>d,DropItem:()=>u,IconDropdown:()=>c});var o=n(50959),i=n(97754),r=n.n(i),l=n(90405),a=n(9745),s=n(71272);function c(e){const{menuItemClassName:t,...n}=e;return o.createElement(l.Select,{...n,menuItemClassName:r()(t,s.itemWrap)})}function d(e){return o.createElement("div",{className:r()(s.item,s.selected,e.className)},o.createElement(a.Icon,{className:s.icon,icon:e.icon}))}function u(e){return o.createElement("div",{className:s.item},o.createElement(a.Icon,{className:r()(s.icon,e.iconClassName),icon:e.icon}),o.createElement("div",{className:s.label},e.label))}},53598:(e,t,n)=>{"use strict";n.d(t,{LineStyleSelect:()=>f})
;var o=n(11542),i=n(50959),r=n(97754),l=n.n(r),a=n(51056),s=n(94697),c=n(501),d=n(23851),u=n(57740),p=n(80427),m=n(28527);const h=[{type:a.LINESTYLE_SOLID,icon:c,label:o.t(null,void 0,n(3554))},{type:a.LINESTYLE_DASHED,icon:d,label:o.t(null,void 0,n(88123))},{type:a.LINESTYLE_DOTTED,icon:u,label:o.t(null,void 0,n(27390))}];class f extends i.PureComponent{render(){const{id:e,lineStyle:t,className:n,lineStyleChange:o,disabled:r,additionalItems:a,allowedLineStyles:c}=this.props;let d=function(e){let t=[...h];return void 0!==e&&(t=t.filter((t=>e.includes(t.type)))),t.map((e=>({value:e.type,selectedContent:i.createElement(s.DisplayItem,{icon:e.icon}),content:i.createElement(s.DropItem,{icon:e.icon,label:e.label})})))}(c);return a&&(d=[{readonly:!0,content:a},...d]),i.createElement(s.IconDropdown,{id:e,disabled:r,className:l()(m.lineStyleSelect,n),hideArrowButton:!0,items:d,value:t,onChange:o,"data-name":"line-style-select",addPlaceholderToItems:!1,placeholder:i.createElement(s.DisplayItem,{icon:p,className:m.multipleStyles})})}}},50890:(e,t,n)=>{"use strict";n.d(t,{LineWidthSelect:()=>d});var o=n(50959),i=n(97754),r=n(90405),l=n(10477);const a=[1,2,3,4];function s(e){const{id:t,value:n,items:s=a,disabled:c,onChange:d}=e;return o.createElement(r.Select,{id:t,disabled:c,hideArrowButton:!0,className:l.lineWidthSelect,items:(u=s,u.map((e=>({value:e,selectedContent:p(e,!0),content:p(e)})))),value:n,onChange:d,"data-name":"line-width-select"});var u;function p(e,t){const r={borderTopWidth:e};return o.createElement("div",{className:l.item},o.createElement("div",{className:i(l.bar,{[l.isActive]:e===n&&!t}),style:r}," "))}}var c=n(45560);function d(e){const{property:t}=e,[n,i]=(0,c.useDefinitionProperty)({property:t});return o.createElement(s,{...e,value:n,onChange:i})}},66849:(e,t,n)=>{"use strict";n.d(t,{ControlCustomHeightContext:()=>a,ControlCustomWidthContext:()=>r});var o,i=n(50959);!function(e){e.Small="small",e.Normal="normal",e.Big="big"}(o||(o={}));const r=i.createContext({});var l;!function(e){e.Normal="normal",e.Big="big"}(l||(l={}));const a=i.createContext({})},5978:(e,t,n)=>{"use strict";n.d(t,{Section:()=>on});var o=n(50959),i=n(4116),r=n(48897),l=n(45560),a=n(31356);function s(e){const{definition:{id:t,properties:{checked:n,disabled:i,visible:r},title:s,solutionId:c,infoTooltip:d},offset:u}=e,[p]=(0,l.useDefinitionProperty)({property:i,defaultValue:!1}),[m]=(0,l.useDefinitionProperty)({property:r,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 c=n(97754),d=n.n(c),u=n(22064),p=n(53598);function m(e){const{property:t}=e,[n,i]=(0,l.useDefinitionProperty)({property:t});return o.createElement(p.LineStyleSelect,{...e,lineStyle:n,lineStyleChange:i})}var h=n(50890),f=n(60521),b=n(50151);function v(e){return"mixed"===e}function y(e,t,n){const[i,r]=(0,o.useState)(e),l=(0,o.useRef)(i);return(0,o.useEffect)((()=>{r(e)}),[e,n]),[i,function(e){l.current=e,r(e)},function(){t(l.current)},function(){l.current=e,r(e)}]}
var g,E=n(68335),w=n(92399),C=n(9859),D=n(59623),S=n(49483);function V(e){const{property:t,...n}=e,[i,r]=(0,o.useState)(performance.now()),[a,s]=(0,l.useDefinitionProperty)({property:t,handler:()=>r(performance.now())}),c=y(a,s,i);return o.createElement(x,{...n,valueHash:i,sharedBuffer:c})}function x(e){const{sharedBuffer:t,min:n,max:i,step:r,...l}=e,[a,s,c,d]=t,u=(0,o.useRef)(null),p=(0,o.useRef)(null),m={flushed:!1};return o.createElement(N,{...l,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,E.hashFromEvent)(e.nativeEvent)){case 27:d(),m.flushed=!0;break;case 13:e.preventDefault();const t=(0,b.ensureNotNull)(p.current).getClampedValue();null!==t&&(s(t),c(),m.flushed=!0)}},onBlur:function(e){const t=(0,b.ensureNotNull)(u.current);if(!t.contains(document.activeElement)&&!t.contains(e.relatedTarget)){const e=(0,b.ensureNotNull)(p.current).getClampedValue();null===e||m.flushed||(s(e),c(),m.flushed=!0)}},value:a,roundByStep:!1,containerReference:function(e){u.current=e},inputMode:S.CheckMobile.iOS()?void 0:"numeric",min:n,max:i,step:r,stretch:!1})}!function(e){e.Input="input",e.Step="step"}(g||(g={}));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,b.ensureNotNull)(this._input)||this._saveSelection((0,b.ensureNotNull)(this._input))},this._handleInputReference=e=>{this._input=e,this.props.inputReference&&this.props.inputReference(e)},this._onFocus=e=>{this._saveSelection((0,b.ensureNotNull)(this._input)),this.setState({focused:!0}),this.props.onFocus&&this.props.onFocus(e)},this._onBlur=e=>{this._selection=null,this.setState({displayValue:I(this.props,this.props.value,M(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,"."),k.test(t)?t:e}}(this.state.displayValue,n,this.props.mode),i=B(o),r=this._checkValueBoundaries(i);var l,a;this.setState({displayValue:o}),o!==n&&(l=this.state.displayValue,a=(a=o).replace(/,/g,"."),(l=l.replace(/,/g,".")).includes(".")||!a.includes("."))?(this._restoreSelection=!0,this.forceUpdate()):this._saveSelection(t),r.value&&I(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 f.Big(o),l=new f.Big(n),a=r.mod(l);let s=r.plus(e*n);!a.eq(0)&&t&&(s=s.plus((e>0?0:1)*n).minus(a)),i=s.toNumber()}this._checkValueBoundaries(i).value&&(this.setState({displayValue:I(this.props,i,M(this.props))}),this.props.onValueChange(i,"step"))},this.state={
value:R(this.props.value),displayValue:I(this.props,this.props.value,M(this.props)),focused:!1,valueHash:this.props.valueHash}}componentDidMount(){document.addEventListener("selectionchange",this._handleSelectionChange)}componentWillUnmount(){document.removeEventListener("selectionchange",this._handleSelectionChange)}componentDidUpdate(){const e=(0,b.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(w.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,C.clamp)(n,e,t)}static getDerivedStateFromProps(e,t){const{valueHash:n}=e,o=R(e.value);if(t.value!==o||t.valueHash!==n){return{value:o,valueHash:n,displayValue:I(e,o,t.focused&&t.valueHash===n?void 0:M(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,C.clamp)(e,t,n)}}(e,t,n);return{value:o.pass}}}N.defaultProps=P;const T=/^-?[0-9]*$/,k=/^(-?([0-9]+\.?[0-9]*)|(-?[0-9]*))$/;function I(e,t,n){return v(t=R(t))?"—":(null!==t&&void 0!==n&&(n=Math.max(_(t),n)),function(e,t){if(null===e)return"";return new D.NumericFormatter({precision:t}).format(e,{ignoreLocaleNumberFormat:!0})}(t,n))}function M(e){let t=0;return e.inheritPrecisionFromStep&&e.step<=1&&(t=_(e.step)),Math.max(e.precision,t)||void 0}function _(e){const t=Math.trunc(e).toString();return(0,C.clamp)(D.NumericFormatter.formatNoE(e).length-t.length-1,0,15)}function B(e,t){const n=new D.NumericFormatter({precision:t}).parse(e,{ignoreLocaleNumberFormat:!0});return n.res?n.value:NaN}function R(e){return"number"==typeof e&&Number.isFinite(e)||v(e)?e:null}var L=n(24377),F=n(58593),A=n(19063);function W(e){const{color:t,thickness:n,thicknessItems:i,noAlpha:r}=e,[a,s]=(0,l.useDefinitionProperty)({property:t}),[c,d]=(0,l.useDefinitionProperty)(n?{property:n}:{defaultValue:void 0});return o.createElement(F.ColorSelect,{...e,color:function(){if(!a)return null;if("mixed"===a)return"mixed";return(0,L.rgbToHexString)((0,
L.parseRgb)(a))}(),onColorChange:function(e){const t=a&&"mixed"!==a?(0,A.alphaToTransparency)((0,L.parseRgba)(a)[3]):0;s((0,A.generateColor)(String(e),t,!0))},thickness:c,thicknessItems:i,onThicknessChange:d,opacity:r?void 0:a&&"mixed"!==a?(0,L.parseRgba)(a)[3]:void 0,onOpacityChange:r?void 0:function(e){s((0,A.generateColor)(a,(0,A.alphaToTransparency)(e),!0))}})}var G=n(11542),z=n(49857),O=n(94697),H=n(90186),J=n(43382),Z=n(98853),j=n(89654);const K=[{type:z.LineEnd.Normal,icon:J,label:G.t(null,void 0,n(65353))},{type:z.LineEnd.Arrow,icon:Z,label:G.t(null,void 0,n(11858))}];class U extends o.PureComponent{constructor(e){super(e),this._items=[],this._items=K.map((t=>({value:t.type,selectedContent:o.createElement(O.DisplayItem,{icon:t.icon}),content:o.createElement(O.DropItem,{icon:t.icon,iconClassName:d()(e.isRight&&j.right),label:t.label})})))}render(){const{id:e,lineEnd:t,className:n,lineEndChange:i,isRight:r,disabled:l}=this.props;return o.createElement(O.IconDropdown,{id:e,disabled:l,className:d()(j.lineEndSelect,r&&j.right,n),items:this._items,value:t,onChange:i,hideArrowButton:!0,...(0,H.filterDataProps)(this.props)})}}function X(e){const{property:t}=e,[n,i]=(0,l.useDefinitionProperty)({property:t});return o.createElement(U,{...e,lineEnd:n,lineEndChange:i})}var Y,$=n(78260),q=n(38188);function Q(e){const{children:t,className:n,breakPoint:i="Normal"}=e;return o.createElement($.CellWrap,{className:c(q.wrap,n,q[`breakpoint${i}`])},o.Children.map(t,(e=>o.isValidElement(e)?o.createElement("span",{key:null===e.key?void 0:e.key,className:c(q.row,r(e)&&q.empty,l(e)&&q.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 l(e){var t;return o.isValidElement(e)&&Boolean(null===(t=e.props)||void 0===t?void 0:t["data-no-margins"])}}!function(e){e.MobileNormal="Normal",e.MobileMedium="Medium",e.MobileSmall="Small"}(Y||(Y={}));const ee={1:"float",0:"integer"};var te=n(77975),ne=n(56659);function oe(e){const{definition:{id:t,properties:{checked:n,disabled:i,visible:r,leftEnd:s,rightEnd:d,value:p,extendLeft:f,extendRight:b},title:v,valueMin:y,valueMax:g,valueStep:E,valueUnit:w,extendLeftTitle:C,extendRightTitle:D,solutionId:S},offset:x}=e,[P]=(0,l.useDefinitionProperty)({property:n,defaultValue:!0}),[N]=(0,l.useDefinitionProperty)({property:i,defaultValue:!1}),[T]=(0,l.useDefinitionProperty)({property:r,defaultValue:!0}),k=(0,te.useWatchedValueReadonly)({watchedValue:y,defaultValue:void 0}),I=(0,te.useWatchedValueReadonly)({watchedValue:g,defaultValue:void 0}),M=(0,te.useWatchedValueReadonly)({watchedValue:E,defaultValue:void 0}),_=(0,te.useWatchedValueReadonly)({watchedValue:w,defaultValue:void 0}),B=e.disabled||!P;return T?o.createElement(o.Fragment,null,o.createElement(a.CommonSection,{id:t,offset:x,checked:n,title:v,solutionId:S,disabled:e.disabled||N},o.createElement(Q,{className:ne.line,breakPoint:"Small"},o.createElement(o.Fragment,null,function(){
const{definition:{properties:{color:n,width:i},widthValues:r}}=e;if(n)return o.createElement("span",{className:ne.control},o.createElement(W,{color:n,thickness:i,disabled:B,thicknessItems:r}));return i&&o.createElement("span",{className:ne.control},o.createElement(h.LineWidthSelect,{id:(0,u.createDomId)(t,"line-width-select"),items:r,property:i,disabled:B}))}(),function(){const{definition:{properties:{style:n}}}=e;return n&&o.createElement("span",{className:ne.control},o.createElement(m,{id:(0,u.createDomId)(t,"line-style-select"),property:n,disabled:B}))}()),(s||d||p)&&o.createElement(o.Fragment,null,o.createElement(o.Fragment,null,s&&o.createElement(X,{id:(0,u.createDomId)(t,"left-end-select"),"data-name":"left-end-select",className:ne.control,property:s,disabled:B}),d&&o.createElement(X,{id:(0,u.createDomId)(t,"right-end-select"),"data-name":"right-end-select",className:ne.control,property:d,disabled:B,isRight:!0})),function(){const{definition:{valueType:t}}=e;return p&&o.createElement("span",{className:c(ne.valueInput,ne.control)},o.createElement(V,{className:ne.input,property:p,min:k,max:I,step:M,disabled:B,mode:void 0!==t?ee[t]:void 0,name:"line-value-input"}),o.createElement("span",{className:ne.valueUnit},_))}()))),f&&o.createElement(a.CommonSection,{id:`${t}ExtendLeft`,offset:x,checked:f,title:C,disabled:e.disabled||N}),b&&o.createElement(a.CommonSection,{id:`${t}ExtendRight`,offset:x,checked:b,title:D,disabled:e.disabled||N})):null}var ie=n(46088),re=n(90405),le=n(36947);function ae(e){const{property:t,options:n,...i}=e,[r,a]=(0,l.useDefinitionProperty)({property:t}),s=(0,le.useForceUpdate)();return(0,o.useEffect)((()=>{const e=()=>s();return Array.isArray(n)||n.subscribe(e),()=>{Array.isArray(n)||n.unsubscribe(e)}}),[]),o.createElement(re.Select,{...i,onChange:a,value:r,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 se=n(34306);const ce=[{title:G.t(null,void 0,n(88686)),value:ie.ColorType.Solid},{title:G.t(null,void 0,n(68043)),value:ie.ColorType.Gradient}];function de(e){const{id:t,disabled:n,noAlpha:i,properties:r}=e,{color:a,gradientColor1:s,gradientColor2:c,type:d}=r,[p]=(0,l.useDefinitionProperty)({property:d,defaultValue:ie.ColorType.Solid});return o.createElement(Q,null,o.createElement(ae,{id:(0,u.createDomId)(t,"background-type-options-dropdown"),"data-name":"background-type-options-dropdown",className:se.dropdown,menuClassName:se.dropdownMenu,disabled:n,property:d,options:ce}),p===ie.ColorType.Solid?o.createElement(W,{color:a,disabled:n,noAlpha:i}):o.createElement(o.Fragment,null,o.createElement(W,{className:se.firstColorPicker,color:s,disabled:n,noAlpha:i}),o.createElement(W,{color:c,disabled:n,noAlpha:i})))}function ue(e){const{definition:{id:t,properties:n,title:i,noAlpha:r,solutionId:s},offset:c}=e,{color:d,checked:u,disabled:p,visible:m}=n,[h]=(0,l.useDefinitionProperty)({property:u,defaultValue:!0}),[f]=(0,l.useDefinitionProperty)({property:p,defaultValue:!1}),[b]=(0,
l.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($.CellWrap,null,n.hasOwnProperty("type")?o.createElement(de,{id:t,properties:n,disabled:v,noAlpha:r}):o.createElement(W,{color:d,disabled:v,noAlpha:r}))):null}var pe=n(54368),me=n(19625),he=n(58510);function fe(e){const{value:t,disabled:n,onChange:i,className:r}=e;return o.createElement("div",{className:c(he.wrap,r,{[he.disabled]:n})},o.createElement(pe.Opacity,{hideInput:!0,color:me.colorsPalette["color-tv-blue-500"],opacity:1-t/100,onChange:function(e){n||i(100-100*e)},disabled:n}))}function be(e){const{property:t,...n}=e,[i,r]=(0,l.useDefinitionProperty)({property:t});return o.createElement(fe,{...n,value:i,onChange:r})}function ve(e){const{definition:{id:t,properties:{transparency:n,checked:i,disabled:r,visible:s},title:c,solutionId:d},offset:u}=e,[p]=(0,l.useDefinitionProperty)({property:i,defaultValue:!0}),[m]=(0,l.useDefinitionProperty)({property:r,defaultValue:!1}),[h]=(0,l.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($.CellWrap,null,o.createElement(be,{property:n,disabled:f}))):null}var ye=n(56198);function ge(e){const{definition:{id:t,properties:{color1:n,color2:i,checked:r,disabled:s,visible:c},title:d,noAlpha1:u,noAlpha2:p,solutionId:m},offset:h}=e,[f]=(0,l.useDefinitionProperty)({property:r,defaultValue:!0}),[b]=(0,l.useDefinitionProperty)({property:s,defaultValue:!1}),[v]=(0,l.useDefinitionProperty)({property:c,defaultValue:!0}),y=e.disabled||!f||b;return v?o.createElement(a.CommonSection,{id:t,offset:h,checked:r,solutionId:m,title:d,disabled:e.disabled||b},o.createElement($.CellWrap,{className:ye.twoColors},g(n,u),g(i,p))):null;function g(e,t){return o.createElement("span",{className:ye.colorPicker},o.createElement(W,{color:e,disabled:y,noAlpha:t}))}}var Ee=n(66849),we=n(3218);function Ce(e){const{definition:{id:t,properties:{checked:n,value:i,unitOptionsValue:r,disabled:s,visible:d},min:p,max:m,step:h,title:f,unit:v,unitOptions:y,type:g,solutionId:E},offset:w}=e,[C]=(0,l.useDefinitionProperty)({property:n,defaultValue:!0}),[D]=(0,l.useDefinitionProperty)({property:s,defaultValue:!1}),[S]=(0,l.useDefinitionProperty)({property:d,defaultValue:!0}),x=(0,te.useWatchedValueReadonly)({watchedValue:p,defaultValue:void 0}),P=(0,te.useWatchedValueReadonly)({watchedValue:m,defaultValue:void 0}),N=(0,te.useWatchedValueReadonly)({watchedValue:h,defaultValue:void 0}),T=(0,te.useWatchedValueReadonly)({watchedValue:v,defaultValue:void 0}),k=(0,o.useContext)(Ee.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($.CellWrap,null,o.createElement(Q,null,o.createElement(V,{className:c(we.input,k[t]&&we[k[t]]),property:i,min:x,max:P,step:N,disabled:I,
mode:ee[g],name:"number-input","data-name":t}),r&&o.createElement(ae,{id:(0,u.createDomId)(t,"unit-options-dropdown"),"data-name":"unit-options-dropdown",className:we.dropdown,menuClassName:we.dropdownMenu,disabled:I,property:r,options:(0,b.ensureDefined)(y)})),T&&o.createElement("span",{className:we.unit},T))):null}function De(e){const{definition:{id:t,properties:{checked:n,disabled:i,visible:r},childrenDefinitions:s,title:c},offset:d}=e,[u]=(0,l.useDefinitionProperty)({property:n,defaultValue:!0}),[p]=(0,l.useDefinitionProperty)({property:i,defaultValue:!1}),[m]=(0,l.useDefinitionProperty)({property:r,defaultValue:!0}),h=e.disabled||!u;return m?o.createElement(o.Fragment,null,o.createElement(a.CommonSection,{id:t,offset:d,checked:n,title:c,disabled:e.disabled||p}),s.map((e=>o.createElement(on,{key:e.id,disabled:h,definition:e,offset:!0})))):null}var Se=n(66045);function Ve(e){const{property:t}=e,[n,i]=(0,l.useDefinitionProperty)({property:t});return o.createElement(Se.FontSizeSelect,{...e,fontSize:n,fontSizeChange:i,"data-name":"font-size-select"})}var xe=n(9745),Pe=n(9309);function Ne(e){const{className:t,checked:n,icon:i,disabled:r,onClick:l}=e;return o.createElement("div",{className:d()(t,Pe.container,n&&!r&&Pe.active,r&&Pe.disabled),onClick:r?void 0:l,"data-role":"button",...(0,H.filterDataProps)(e)},o.createElement(xe.Icon,{className:Pe.icon,icon:i}))}function Te(e){const{icon:t,className:n,property:i,disabled:r}=e,[a,s]=(0,l.useDefinitionProperty)({property:i});return o.createElement(Ne,{className:n,icon:t,checked:a,onClick:function(){s(!a)},disabled:r,...(0,H.filterDataProps)(e)})}var ke=n(67029),Ie=n(71891),Me=n(2568);function _e(e){const{property:t,...n}=e,[i,r]=(0,l.useDefinitionProperty)({property:t}),a=(0,o.useCallback)((e=>r(e.target.value)),[r]);return o.createElement(Me.Textarea,{...n,value:i,onChange:a})}var Be=n(8295),Re=n(29285),Le=n(23018);const Fe=e=>({content:e.title,title:e.title,value:e.value,id:e.id}),Ae=e=>({content:e.title,title:e.title,value:e.value,id:e.id});function We(e){const{definition:{id:t,properties:{color:n,size:i,checked:r,disabled:s,bold:c,italic:d,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:V,alignmentHorizontalItems:x,alignmentVerticalItems:P,orientationTitle:N,orientationItems:T,backgroundTitle:k,borderTitle:I,borderWidthItems:M,wrapTitle:_},offset:B}=e,R=(0,o.useContext)(Ee.ControlCustomHeightContext),[L]=(0,l.useDefinitionProperty)({property:r,defaultValue:!0}),[F]=(0,l.useDefinitionProperty)({property:s,defaultValue:!1}),[A,G]=(0,l.useDefinitionProperty)({property:h,defaultValue:void 0}),[z,O]=(0,l.useDefinitionProperty)({property:f,defaultValue:"horizontal"}),[H,J]=(0,l.useDefinitionProperty)({property:m,defaultValue:void 0}),[Z]=(0,l.useDefinitionProperty)({property:b,defaultValue:!1}),[j]=(0,l.useDefinitionProperty)({property:y,defaultValue:!1}),K=e.disabled||!L;return o.createElement(o.Fragment,null,function(){
if(C)return o.createElement(a.CommonSection,{id:t,offset:B,checked:r,title:C,solutionId:D,disabled:e.disabled||F},o.createElement(Q,{breakPoint:"Small"},Y(),q()));return o.createElement(Ie.PropertyTable.Row,null,o.createElement(Ie.PropertyTable.Cell,{placement:"first",colSpan:2,offset:B,"data-section-name":t},Y(),q(),D&&!1))}(),p&&o.createElement(Ie.PropertyTable.Row,null,o.createElement(Ie.PropertyTable.Cell,{placement:"first",colSpan:2,offset:B,"data-section-name":t},o.createElement(_e,{className:ke.InputClasses.FontSizeMedium,rows:(U=R[t],"big"===U?9:5),stretch:!0,property:p,disabled:K,onFocus:function(e){e.target.select()},name:"text-input"}))),(m||h)&&o.createElement(Ie.PropertyTable.Row,null,o.createElement(Ie.PropertyTable.Cell,{placement:"first",verticalAlign:"adaptive",offset:B,"data-section-name":t},o.createElement($.CellWrap,null,o.createElement("span",{className:Le.title},V))),o.createElement(Ie.PropertyTable.Cell,{placement:"last",verticalAlign:"adaptive","data-section-name":t},o.createElement(Q,{breakPoint:"Small"},void 0!==A&&void 0!==P&&o.createElement(re.Select,{id:(0,u.createDomId)(t,"alignment-vertical-select"),"data-name":"alignment-vertical-select",className:Le.dropdown,menuClassName:Le.dropdownMenu,disabled:K,value:A,items:P.map(Fe),onChange:G}),void 0!==H&&void 0!==x&&o.createElement(re.Select,{id:(0,u.createDomId)(t,"alignment-horizontal-select"),"data-name":"alignment-horizontal-select",className:Le.dropdown,menuClassName:Le.dropdownMenu,disabled:K,value:H,items:x.map(Fe),onChange:J})))),void 0!==f&&void 0!==T&&o.createElement(Ie.PropertyTable.Row,null,o.createElement(Ie.PropertyTable.Cell,{placement:"first",verticalAlign:"adaptive",offset:B,"data-section-name":t},o.createElement($.CellWrap,null,o.createElement("span",{className:Le.title},N))),o.createElement(Ie.PropertyTable.Cell,{placement:"last",verticalAlign:"adaptive","data-section-name":t},o.createElement(Q,{breakPoint:"Small"},o.createElement(re.Select,{id:(0,u.createDomId)(t,"orientation-select"),"data-name":"orientation-select",className:Le.dropdown,menuClassName:Le.dropdownMenu,disabled:K,value:z,items:T.map(Ae),onChange:O})))),ee(k,b,v,!!b&&!Z),ee(I,y,g,!!y&&!j,E,M),w&&o.createElement(a.CommonSection,{id:`${t}Wrap`,offset:B,checked:w,title:_,disabled:e.disabled||F}));var U;function X(e,t,n){return e?o.createElement(Te,{className:Le.fontStyleButton,icon:t,property:e,disabled:K,"data-name":n}):null}function Y(){return o.createElement(o.Fragment,null,n&&o.createElement("div",{className:Le.colorPicker},o.createElement(W,{color:n,disabled:K})),i&&S&&o.createElement(Ve,{id:(0,u.createDomId)(t,"font-size-select"),property:i,fontSizes:S,disabled:K}))}function q(){return o.createElement(o.Fragment,null,X(c,Be,"toggle-bold"),X(d,Re,"toggle-italic"))}function ee(e,n,i,r,l,s){return i||n?o.createElement(a.CommonSection,{id:`${t}ColorSelect`,offset:B,checked:n,title:e,disabled:K},i&&o.createElement(W,{color:i,thickness:l,thicknessItems:s,disabled:K||r})):null}}var Ge=n(86623),ze=n(37265);function Oe(e){
const{property:t,mathOperations:n="+/*",mode:i="float",disabled:r,...a}=e,[s,c]=(0,o.useState)(performance.now()),[d,u]=(0,l.useDefinitionProperty)({property:t,handler:()=>c(performance.now())}),[p,m,h,f]=y(d,u,s),b=(0,o.useMemo)((()=>{const e=new RegExp(`^[${n.split("").join("\\")}-]?(${"float"===i?"(\\d+\\.\\d*)|":""}(\\d*))$`);return t=>(0,ze.isString)(t)&&e.test(t)}),[n,i]);return o.createElement(Ge.FormInput,{...a,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,E.hashFromEvent)(e.nativeEvent)){case 27:f();break;case 13:v()}},onBlur:function(){v()},disabled:r,stretch:!1,autoSelectOnFocus:!0});function v(){p.length&&h()}}var He=n(72972);function Je(e){const{definition:{properties:{x:t,y:n,disabled:i},id:r,title:l,solutionId:a},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-section-name":r},o.createElement("span",{className:He.coordinates},l)),(t||n)&&o.createElement(Ie.PropertyTable.Cell,{placement:"last",offset:c,"data-section-name":r},o.createElement(Q,{breakPoint:"Medium"},"coordinates"===s.propType?o.createElement(Ze,{definition:s,disabled:d}):o.createElement(je,{definition:s,disabled:d})),a&&!1))}function Ze(e){const{definition:{properties:{x:t,y:n},minX:i,maxX:r,stepX:l,minY:a,maxY:s,stepY:c,typeX:d,typeY:u},disabled:p}=e,m=(0,te.useWatchedValueReadonly)({watchedValue:i,defaultValue:void 0}),h=(0,te.useWatchedValueReadonly)({watchedValue:r,defaultValue:void 0}),f=(0,te.useWatchedValueReadonly)({watchedValue:l,defaultValue:void 0}),b=(0,te.useWatchedValueReadonly)({watchedValue:a,defaultValue:void 0}),v=(0,te.useWatchedValueReadonly)({watchedValue:s,defaultValue:void 0}),y=(0,te.useWatchedValueReadonly)({watchedValue:c,defaultValue:void 0});return o.createElement(o.Fragment,null,n&&o.createElement(V,{className:He.input,property:n,min:b,max:v,step:y,disabled:p,name:"y-input",mode:void 0!==u?ee[u]:"integer"}),t&&o.createElement(V,{className:He.input,property:t,min:m,max:h,step:f,disabled:p,name:"x-input",mode:void 0!==d?ee[d]:"integer"}))}function je(e){const{definition:{properties:{x:t,y:i},mathOperationsX:r,mathOperationsY:l,modeX:a,modeY:s},disabled:c}=e;return o.createElement("div",{className:He.selectionCoordinates},o.createElement("div",{className:He.selectionCoordinates__inputs},i&&o.createElement(Oe,{property:i,mathOperations:l,mode:s,disabled:c,className:He.input,placeholder:G.t(null,void 0,n(49957))}),t&&o.createElement(Oe,{property:t,mathOperations:r,mode:a,disabled:c,className:He.input,placeholder:G.t(null,void 0,n(406))})),o.createElement("div",{className:He.selectionCoordinates__description},G.t(null,void 0,n(13748))))}var Ke=n(73943);function Ue(e){const{definition:{id:t,properties:{checked:n,option:i,disabled:r,visible:s,color:c},title:p,solutionId:m,options:h,infoTooltip:f},offset:b}=e,[v]=(0,l.useDefinitionProperty)({property:n,defaultValue:!0}),[y]=(0,
l.useDefinitionProperty)({property:r,defaultValue:!1}),[g]=(0,l.useDefinitionProperty)({property:s,defaultValue:!0}),E=(0,o.useContext)(Ee.ControlCustomWidthContext),w=e.disabled||!v;return g?o.createElement(a.CommonSection,{id:t,offset:b,checked:n,title:p,solutionId:m,disabled:e.disabled||y,infoTooltip:f},o.createElement($.CellWrap,null,o.createElement(Q,null,o.createElement(ae,{id:(0,u.createDomId)(t,"options-dropdown"),"data-name":"options-dropdown",className:d()(Ke.dropdown,E[t]&&Ke[E[t]]),menuClassName:d()(Ke.dropdownMenu,E[t]&&Ke[E[t]]),disabled:w||y,property:i,options:h}),c&&o.createElement(W,{color:c,disabled:w})))):null}var Xe=n(71953);var Ye,$e=n(63273),qe=n(9161);!function(e){e[e.None=0]="None",e[e.From=1]="From",e[e.To=2]="To"}(Ye||(Ye={}));class Qe 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),l=1===this._detectPointerMode(e),a=l?(0,C.clamp)(r,o,n):t,s=l?n:(0,C.clamp)(r,t,i);a<=s&&this._handleChange(a,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=>{S.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:l}=this.props,{pointerDragMode:a}=this.state,s=0!==a,d=l-r,u=0===d?r:(n-r)/d,p=0===d?l:(i-r)/d,m=(0,$e.isRtl)()?"right":"left";return o.createElement("div",{className:c(e,qe.range,t&&qe.disabled)},o.createElement("div",{className:qe.rangeSlider,ref:this._refContainer,onMouseDown:this._onSliderClick,onTouchStart:this._onTouchStart,onTouchMove:this._handleTouch,onTouchEnd:this._handleTouchEnd},o.createElement("div",{className:qe.rangeSliderMiddleWrap},o.createElement("div",{className:c(qe.rangeSliderMiddle,s&&qe.dragged),style:{[m]:100*u+"%",width:100*(p-u)+"%"}})),o.createElement("div",{className:qe.rangePointerWrap},o.createElement("div",{className:c(qe.pointer,s&&qe.dragged),style:{[m]:100*u+"%"},ref:this._refPointer})),o.createElement("div",{className:qe.rangePointerWrap
},o.createElement("div",{className:c(qe.pointer,s&&qe.dragged),style:{[m]:100*p+"%"}}))))}_dragSubscribe(){const e=(0,b.ensureNotNull)(this._container).ownerDocument;e&&(e.addEventListener("mouseup",this._mouseUp),e.addEventListener("mousemove",this._mouseMove))}_dragUnsubscribe(){const e=(0,b.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,b.ensureNotNull)(this._container),r=(0,b.ensureNotNull)(this._pointer),l=i.getBoundingClientRect(),a=r.offsetWidth;let s=e.clientX-a/2-l.left;return(0,$e.isRtl)()&&(s=l.width-s-a),(0,C.clamp)(s/(l.width-a),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),l=Math.abs(n-i),a=r===l?i<t?1:2:r<l?1:2;return this.setState({pointerDragMode:a}),a}_handleChange(e,t){const{from:n,to:o,onChange:i}=this.props;e===n&&t===o||i(e,t)}}var et=n(90692),tt=n(18707);function nt(e){const{definition:{id:t,properties:{checked:n,disabled:i,from:r,to:s},title:c,solutionId:u,max:p,min:m},offset:h,disabled:f}=e,[b]=(0,l.useDefinitionProperty)({property:n,defaultValue:!0}),[g]=(0,l.useDefinitionProperty)({property:i,defaultValue:!1}),E=(0,te.useWatchedValueReadonly)({watchedValue:m,defaultValue:void 0}),w=(0,te.useWatchedValueReadonly)({watchedValue:p,defaultValue:void 0}),[C,D]=(0,l.useDefinitionProperty)({property:r}),[S,V]=(0,l.useDefinitionProperty)({property:s}),P=v(C)||v(S),N=y(P?"mixed":C,(function(e){if(D(e),v(_)){const e=w||100;B(e),V(e)}})),[T,k,I]=N,M=y(P?"mixed":S,(function(e){if(V(e),v(T)){const e=E||0;k(e),D(e)}})),[_,B,R]=M,L=v(T)||v(_),F=f||v(b)||!b,A={flushed:!1};return o.createElement(a.CommonSection,{id:t,offset:h,checked:n,title:c,disabled:f||g},o.createElement($.CellWrap,{className:tt.range},function(){if(!E||!w)return null;return o.createElement(et.MatchMedia,{rule:"screen and (max-width: 460px)"},(e=>o.createElement(Q,{breakPoint:"Medium"},o.createElement(o.Fragment,null,o.createElement("span",{className:tt.valueInput},o.createElement(x,{className:tt.input,sharedBuffer:N,min:E,max:v(_)?w:_,step:1,disabled:F,name:"from-input",mode:"integer",defaultValue:E}),e?o.createElement("span",{className:tt.rangeSlider},"—"):o.createElement(Qe,{className:d()(tt.rangeSlider,L&&tt.rangeSlider_mixed),from:L?E:T,to:L?w:_,min:E,max:w,onChange:W,onCommit:G,disabled:F}))),o.createElement(o.Fragment,null,o.createElement("span",{className:tt.valueInput},o.createElement(x,{className:tt.input,sharedBuffer:M,min:v(T)?E:T,max:w,step:1,disabled:F,name:"to-input",mode:"integer",defaultValue:w}),u&&!1)))))}()));function W(e,t){k(Math.round(e)),B(Math.round(t))}function G(){A.flushed||(I(),R(),A.flushed=!0)}}var ot=n(86067),it=n(53424),rt=n(93234);function lt(e){const{definitions:t,name:n,offset:i}=e,r=d()(rt.cell,rt.fragmentCell,t.some((e=>void 0!==e.solutionId))&&rt.largeWidth)
;return o.createElement(Ie.PropertyTable.Row,null,o.createElement(Ie.PropertyTable.Cell,{className:r,offset:i,placement:"first",verticalAlign:"adaptive",colSpan:2,"data-section-name":n,checkableTitle:!0},t.map((e=>o.createElement("div",{className:rt.item,key:e.id,"data-section-name":e.id},o.createElement(st,{definition:e}))))))}function at(e){const{definition:t,offset:n}=e;return o.createElement(Ie.PropertyTable.Row,null,o.createElement(Ie.PropertyTable.Cell,{className:rt.cell,offset:n,placement:"first",verticalAlign:"adaptive",colSpan:2,checkableTitle:!0},o.createElement(st,{definition:t})))}function st(e){const{definition:{id:t,properties:{disabled:n,checked:i,color:r,level:a,width:s,style:c},solutionId:p,title:h,widthValues:f,styleValues:b}}=e,[v]=(0,l.useDefinitionProperty)({property:i,defaultValue:!0}),[y]=(0,l.useDefinitionProperty)({property:n,defaultValue:!1}),g=y||!v;return o.createElement(o.Fragment,null,o.createElement(it.CheckableTitle,{name:`is-enabled-${t}`,className:d()(h&&rt.withTitle),title:h&&o.createElement("span",{className:rt.title},h),property:i,disabled:y}),a&&o.createElement(V,{className:d()(rt.input,rt.control),property:a,disabled:g}),r&&o.createElement(W,{className:rt.control,disabled:g,color:r,thickness:s,thicknessItems:f}),c&&o.createElement(m,{id:(0,u.createDomId)(t,"leveled-line-style-select"),className:rt.control,property:c,disabled:g,allowedLineStyles:b}),p&&!1)}var ct=n(16731);function dt(e){const{definition:{id:t,properties:{option1:n,option2:i,checked:r,disabled:s},title:c,solutionId:d,optionsItems1:p,optionsItems2:m},offset:h}=e,[f]=(0,l.useDefinitionProperty)({property:r,defaultValue:!0}),[b]=(0,l.useDefinitionProperty)({property:s,defaultValue:!1}),v=e.disabled||!f;return o.createElement(a.CommonSection,{id:t,offset:h,checked:r,title:c,solutionId:d,disabled:e.disabled||b},o.createElement(Q,{className:ct.twoOptions},o.createElement(ae,{id:(0,u.createDomId)(t,"two-options-dropdown-1"),"data-name":"two-options-dropdown-1",className:ct.dropdown,menuClassName:ct.menu,property:n,disabled:v,options:p}),o.createElement(ae,{id:(0,u.createDomId)(t,"two-options-dropdown-2"),"data-name":"two-options-dropdown-2",className:ct.dropdown,menuClassName:ct.menu,property:i,disabled:v,options:m})))}var ut=n(80640);function pt(e){const{definition:{id:t,properties:{color1:n,color2:i,option:r},options:l,color1Visible:s,color2Visible:c,title:p,noAlpha1:m,noAlpha2:h,solutionId:f},offset:b}=e,v=(0,te.useWatchedValueReadonly)({watchedValue:s,defaultValue:!1}),y=(0,te.useWatchedValueReadonly)({watchedValue:c,defaultValue:!1}),g=(0,o.useContext)(Ee.ControlCustomWidthContext);return o.createElement(a.CommonSection,{id:t,offset:b,solutionId:f,title:p},o.createElement($.CellWrap,{className:ut.optionalTwoColors},o.createElement(Q,null,o.createElement(ae,{id:(0,u.createDomId)(t,"options-dropdown"),"data-name":"options-dropdown",className:d()(ut.dropdown,g[t]&&ut[g[t]]),menuClassName:d()(ut.dropdownMenu,g[t]&&ut[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:ut.colorPicker},o.createElement(W,{color:e,noAlpha:t}))}}var mt=n(5236),ht=n(97616);function ft(e){const{source:t,inputs:n,model:i,inputsTabProperty:r,studyMetaInfo:l}=e.definition;return o.createElement(mt.InputsTabContent,{className:ht.withoutPadding,property:r,model:i,study:t,studyMetaInfo:l,inputs:n})}var bt=n(56840),vt=n(38297),yt=n(83682),gt=n(173);var Et=n(20520),wt=n(37558),Ct=n(41590),Dt=n(27317),St=n(40173);function Vt(e){!function(e,t){(0,o.useEffect)((()=>{const n=t||document;return n.addEventListener("scroll",e),()=>n.removeEventListener("scroll",e)}),[e])}(e,document)}var xt=n(78135),Pt=n(24437),Nt=n(80671);function Tt(e){const{children:t,highlight:n,disabled:i,reference:r,...l}=e,a=n?"primary":"default";return o.createElement("div",{...l,ref:r,className:d()(Nt.wrapper,Nt[`intent-${a}`],Nt["border-thin"],Nt["size-medium"],n&&Nt.highlight,n&&Nt.focused,i&&Nt.disabled),"data-role":"button"},o.createElement("div",{className:d()(Nt.childrenContainer,i&&Nt.disabled)},t),n&&o.createElement("span",{className:Nt.shadow}))}var kt=n(21775);const It=()=>null,Mt=(0,St.mergeThemes)(Dt.DEFAULT_MENU_THEME,{menuBox:kt.menuBox});function _t(e){const{value:t,disabled:n,onSelect:i}=e,r=(0,o.useRef)(null),{current:l}=(0,o.useRef)(bt.getJSON("RecentlyUsedEmojis",[t])),[a,s]=(0,o.useState)(l),[c,d]=(0,o.useState)(!1),u=(0,o.useCallback)((()=>d(!1)),[]);Vt(u);const p=(0,o.useCallback)((e=>{const t=Array.from(new Set([e,...a])).slice(0,18);bt.setJSON("RecentlyUsedEmojis",t),s(t),i(e),u()}),[a,i]),m=(h=a,(0,o.useMemo)((()=>(gt.emojiGroups[0].emojis=h,[...gt.emojiGroups])),[h]));var h;return o.createElement(o.Fragment,null,o.createElement(Tt,{reference:r,highlight:c,disabled:n,"data-name":"emoji-picker"},o.createElement(yt.EmojiWrap,{emoji:t,onClick:function(){n||d(!0)}})),o.createElement(et.MatchMedia,{rule:Pt.DialogBreakpoints.TabletSmall},(e=>c&&o.createElement(wt.DrawerManager,null,e?o.createElement(Ct.Drawer,{className:kt.drawer,position:"Bottom",onClose:u},o.createElement(vt.EmojiList,{emojis:m,onSelect:p,height:378})):o.createElement(Et.PopupMenu,{theme:Mt,isOpened:!0,position:(0,xt.getPopupPositioner)(r.current,{horizontalDropDirection:xt.HorizontalDropDirection.FromLeftToRight,horizontalAttachEdge:xt.HorizontalAttachEdge.Left}),onClickOutside:u,onClose:It},o.createElement(vt.EmojiList,{className:kt.desktopSize,emojis:m,onSelect:p,height:378}))))))}var Bt=n(5200);function Rt(e){const{definition:{id:t,title:n,properties:i,solutionId:r},offset:s}=e,{checked:c,emoji:d,backgroundColor:u}=i,[p]=(0,l.useDefinitionProperty)({property:c,defaultValue:!1}),[m,h]=(0,l.useDefinitionProperty)({property:d,defaultValue:"🙂"}),[f,b]=(0,l.useDefinitionProperty)({property:u,defaultValue:me.colorsPalette["color-tv-blue-a600"]}),[v]=(0,l.useDefinitionProperty)({property:i.disabled,defaultValue:!1}),y=e.disabled||!p;return o.createElement(a.CommonSection,{id:t,offset:s,checked:c,title:n,solutionId:r,disabled:e.disabled||v},o.createElement(_t,{value:m,disabled:y,onSelect:h
}),o.createElement(F.ColorSelect,{className:Bt.colorSelect,disabled:y,color:function(){if("mixed"===f)return f;return(0,L.rgbToHexString)((0,L.parseRgb)(f))}(),opacity:f&&"mixed"!==f?(0,L.parseRgba)(f)[3]:void 0,onColorChange:function(e){const t=f&&"mixed"!==f?(0,A.alphaToTransparency)((0,L.parseRgba)(f)[3]):0;b((0,A.generateColor)(String(e),t,!0))},onOpacityChange:function(e){b((0,A.generateColor)(f,(0,A.alphaToTransparency)(e),!0))}}))}function Lt(e){const{definition:{id:t,properties:{disabled:n,visible:i},childrenDefinitions:r,title:s},offset:c}=e,[d]=(0,l.useDefinitionProperty)({property:n,defaultValue:!1}),[u]=(0,l.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}),r.map((e=>{var t;return o.createElement(on,{key:e.id,disabled:p,definition:e,offset:null!==(t=e.offset)&&void 0!==t?t:Boolean(s)})}))):null}var Ft=n(38528),At=n(36104),Wt=n(3343),Gt=n(26597),zt=n(59054),Ot=n(50238),Ht=n(16396),Jt=n(15294),Zt=n(58128);function jt(e){const{isDisabled:t,hint:n,label:i,isChecked:r,checkboxClassName:l,labelClassName:a,indeterminate:s,isActive:d,checkboxTabIndex:u,checkboxReference:p,checkboxDataRole:m,...h}=e;return o.createElement(Ht.PopupMenuItem,{...h,isDisabled:t,shortcut:n,dontClosePopup:!0,labelRowClassName:a,label:o.createElement(Jt.Checkbox,{reference:p,disabled:t,label:i,checked:r,indeterminate:s,className:c(Zt.checkbox,l),tabIndex:u,"data-role":m})})}var Kt=n(65983);function Ut(e){const[t,n]=(0,Ot.useRovingTabindexElement)(null);return o.createElement(jt,{...e,className:Kt.item,checkboxClassName:Kt.checkbox,checkboxReference:t,checkboxTabIndex:n,checkboxDataRole:"menuitem",onKeyDown:function(e){const n=(0,Wt.hashFromEvent)(e);13!==n&&32!==n||(e.preventDefault(),t.current instanceof HTMLElement&&t.current.click())},"aria-disabled":e.isDisabled||void 0})}var Xt=n(20243),Yt=n(83821);function $t(e){return!e.readonly&&!e.disabled}function qt(e){const{selectedItems:t,placeholder:n}=e;if(!t.length)return o.createElement("span",null,n);const i=t.map((e=>{var t,n,o;return null!==(n=null!==(t=e.selectedContent)&&void 0!==t?t:e.content)&&void 0!==n?n:null===(o=e.value)||void 0===o?void 0:o.toString()})).reduce(((e,t,n)=>t?(e.push(o.createElement("span",{key:n,className:Yt.contentPart},t)),e.push(o.createElement("span",{key:`separator_${n}`},","," ")),e):e),[]);return i.length&&i.splice(-1),o.createElement("span",{className:Yt.btnContent},i)}function Qt(e,t){const{id:n,items:i,menuClassName:r,menuItemClassName:l,tabIndex:a,disabled:s,highlight:c,intent:d,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:V,isOpened:x,isFocused:P,buttonTabIndex:N,highlight:T,intent:k,open:I,onOpen:M,close:_,toggle:B,buttonFocusBindings:R,onButtonClick:L,buttonRef:F,listboxRef:A,listboxTabIndex:W,buttonAria:G}=(0,At.useControlDisclosure)({id:n,disabled:s,
buttonTabIndex:a,intent:d,highlight:c,onFocus:b,onBlur:v,onClick:y}),z=i.filter($t).filter((e=>h.some((t=>e.value===t)))),O=(0,u.joinDomIds)(f,n),H=O.length>0?O:void 0,J=(0,o.useMemo)((()=>({role:"listbox","aria-labelledby":f})),[f]),Z=(0,Gt.useKeyboardToggle)(B,x||w),j=(0,Gt.useKeyboardOpen)(x,I),K=(0,Gt.useKeyboardEventHandler)([Z,j]),U=(0,Ft.useMergedRefs)([F,t]);return o.createElement(zt.ControlDisclosureView,{...S,...G,...R,id:n,role:"button",tabIndex:N,"aria-owns":G["aria-controls"],"aria-haspopup":"listbox","aria-labelledby":H,disabled:s,hideArrowButton:p,isFocused:P,isOpened:x,highlight:T,intent:k,ref:U,onClick:L,onClose:_,onKeyDown:K,onOpen:M,listboxTabIndex:W,listboxId:V,listboxClassName:r,listboxAria:J,"aria-describedby":C,"aria-invalid":D,listboxReference:A,onListboxKeyDown:function(e){switch((0,Wt.hashFromEvent)(e)){case 27:case 9:return void(x&&(e.preventDefault(),_()))}(0,Xt.handleAccessibleMenuKeyDown)(e)},onListboxFocus:e=>(0,Xt.handleAccessibleMenuFocus)(e,F),buttonChildren:o.createElement(qt,{selectedItems:null!=z?z:null,placeholder:m})},i.map(((e,t)=>{var i,r,a;if(e.readonly)return o.createElement(o.Fragment,{key:`readonly_item_${t}`},e.content);const s=function(e,t){var n;return null!==(n=null==t?void 0:t.id)&&void 0!==n?n:(0,u.createDomId)(e,"item",null==t?void 0:t.value)}(n,e);return o.createElement(Ut,{key:s,id:s,className:l,"aria-selected":h===e.value,isChecked:h.includes(e.value),label:null!==(a=null!==(i=e.content)&&void 0!==i?i:null===(r=e.value)||void 0===r?void 0:r.toString())&&void 0!==a?a:"",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})})))}Qt.displayName="Multiselect";const en=o.forwardRef(Qt);var tn=n(47908);function nn(e){const{definition:t}=e,{checkableListOptions:r,definitions:l}=t,[a,s]=(0,o.useState)(h());(0,o.useEffect)((()=>{const e={},t=()=>{const e=h();s(e)};return t(),r.forEach((n=>{var o;n.properties.checked&&(null===(o=n.properties.checked)||void 0===o||o.subscribe(e,t))})),()=>{r.forEach((n=>{var o;n.properties.checked&&(null===(o=n.properties.checked)||void 0===o||o.unsubscribe(e,t))}))}}),[t]);const c=[],d=[],u=[],p=[];l.value().forEach((e=>{(0,i.isPropertyDefinition)(e)&&((0,i.isColorDefinition)(e)?c.push(e):(0,i.isTwoColorDefinition)(e)?d.push(e):(0,i.isLineDefinition)(e)?u.push(e):(0,i.isOptionsDefinition)(e)&&p.push(e))}));const m=0===a.length;return o.createElement(o.Fragment,null,o.createElement(Ie.PropertyTable.Row,null,o.createElement(Ie.PropertyTable.Cell,{verticalAlign:"topCenter",placement:"first"},t.title),o.createElement(Ie.PropertyTable.Cell,{placement:"last"},o.createElement("div",{className:tn.wrap},o.createElement(en,{className:tn.select,placeholder:G.t(null,void 0,n(8854)),onChange:function(e){const t=new Set(e);r.forEach((e=>{var n,o;!t.has(e.id)||(null===(n=e.properties.checked)||void 0===n?void 0:n.value())?!t.has(e.id)&&(null===(o=e.properties.checked)||void 0===o?void 0:o.value())&&e.properties.checked.setValue(!1):(0,b.ensureDefined)(e.properties.checked).setValue(!0)
}))},value:a,matchButtonAndListboxWidths:!0,items:r.map((e=>({id:e.id,content:(0,b.ensureDefined)(e.title),value:e.id})))}),c.length||u.length?o.createElement("div",{className:tn.colorsWrap},u.map((e=>o.createElement(W,{key:e.id,color:(0,b.ensureDefined)(e.properties.color),thickness:e.properties.width,thicknessItems:e.widthValues,disabled:m}))),c.map((e=>o.createElement(W,{key:e.id,color:e.properties.color,disabled:m})))):null,d.length?d.map((e=>o.createElement("div",{key:e.id,className:tn.colorsWrap},o.createElement(W,{color:e.properties.color1,disabled:m,noAlpha:e.noAlpha1}),o.createElement(W,{color:e.properties.color2,disabled:m,noAlpha:e.noAlpha2})))):null))),p.map((e=>o.createElement(Ie.PropertyTable.Row,{key:e.id},o.createElement(Ie.PropertyTable.Cell,{placement:"first"}),o.createElement(Ie.PropertyTable.Cell,{placement:"last"},o.createElement(ae,{className:tn.select,property:e.properties.option,options:e.options,disabled:m}))))));function h(){return r.filter((e=>{var t;return(0,b.ensureDefined)(null===(t=e.properties)||void 0===t?void 0:t.checked).value()})).map((e=>e.id))}}function on(e){const{definition:t,offset:n,disabled:l}=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,(()=>Xe.logger.logNormal(`Property "${n}" in definition "${e.id}" was updated to value "${o.value()}"`)))})),()=>{Object.entries(t).forEach((([,e])=>{null==e||e.unsubscribeAll(t)}))}}),[e])}((0,i.isPropertyDefinitionsGroup)(t)?void 0:t),(0,i.isPropertyDefinitionsGroup)(t))return o.createElement(rn,{definition:t,offset:n,disabled:l});switch(t.propType){case"line":return o.createElement(oe,{...e,definition:t});case"checkable":return o.createElement(s,{...e,definition:t});case"color":return o.createElement(ue,{...e,definition:t});case"transparency":return o.createElement(ve,{...e,definition:t});case"twoColors":return o.createElement(ge,{...e,definition:t});case"optionalTwoColors":return o.createElement(pt,{...e,definition:t});case"fourColors":case"session":case"soundSelect":case"image":default:return null;case"number":return o.createElement(Ce,{...e,definition:t});case"symbol":return o.createElement(r.SymbolInputsButton,{...e,definition:t});case"text":return o.createElement(We,{...e,definition:t});case"checkableSet":return o.createElement(De,{...e,definition:t});case"set":return o.createElement(Lt,{...e,definition:t});case"options":return o.createElement(Ue,{...e,definition:t});case"range":return o.createElement(nt,{...e,definition:t});case"coordinates":case"selectionCoordinates":return o.createElement(Je,{...e,definition:t});case"twoOptions":return o.createElement(dt,{...e,definition:t});case"leveledLine":return o.createElement(at,{...e,definition:t});case"emoji":return o.createElement(Rt,{...e,definition:t});case"studyInputs":return o.createElement(ft,{...e,definition:t})}}function rn(e){const{definition:t}=e,n=(0,te.useWatchedValueReadonly)({watchedValue:t.definitions});return(0,te.useWatchedValueReadonly)({watchedValue:t.visible,
defaultValue:!0})?(0,i.isCheckableListOptionsDefinition)(t)?o.createElement(nn,{definition:t}):o.createElement(o.Fragment,null,t.title&&o.createElement(ot.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(lt,{key:n[0].id,name:t.id,definitions:n}):o.createElement(on,{key:n.id,...e,definition:n}))),"general"===t.groupType&&o.createElement(Ie.PropertyTable.GroupSeparator,{size:1})):null}},95276:(e,t,n)=>{"use strict";n.d(t,{ControlDisclosure:()=>d});var o=n(50959),i=n(38528),r=n(26597),l=n(59054),a=n(36104),s=n(68335),c=n(44620);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:V,listboxTabIndex:x,highlight:P,intent:N,onOpen:T,close:k,toggle:I,buttonFocusBindings:M,onButtonClick:_,buttonRef:B,listboxRef:R,buttonAria:L}=(0,a.useControlDisclosure)({id:n,disabled:u,buttonTabIndex:d,intent:m,highlight:p,onFocus:b,onBlur:v,onClick:f}),F=(0,r.useKeyboardToggle)(I),A=(0,r.useKeyboardClose)(D,k),W=(0,r.useKeyboardEventHandler)([F,A]);return o.createElement(l.ControlDisclosureView,{...E,...M,...L,id:n,role:"button",tabIndex:V,disabled:u,isOpened:D,isFocused:S,ref:(0,i.useMergedRefs)([B,t]),highlight:P,intent:N,onClose:k,onOpen:T,onClick:_,onKeyDown:W,listboxId:C,listboxTabIndex:x,listboxReference:R,listboxAria:null!=y?y:w.current,onListboxKeyDown:function(e){if(27===(0,s.hashFromEvent)(e))return e.preventDefault(),void k();null==g||g(e)}},h,o.createElement("span",{className:c.invisibleFocusHandler,tabIndex:0,"aria-hidden":!0,onFocus:()=>k()}))}));d.displayName="ControlDisclosure"},96040:(e,t,n)=>{"use strict";n.d(t,{RemoveButton:()=>c});var o=n(11542),i=n(50959),r=n(97754),l=n(9745),a=n(33765),s=n(11772);function c(e){const{className:t,isActive:c,onClick:d,onMouseDown:u,title:p,hidden:m,"data-name":h="remove-button",icon:f,...b}=e;return i.createElement(l.Icon,{...b,"data-name":h,className:r(s.button,"apply-common-tooltip",c&&s.active,m&&s.hidden,t),icon:f||a,onClick:d,onMouseDown:u,title:p||o.t(null,void 0,n(67410))})}},65983:e=>{e.exports={checkbox:"checkbox-hcyAOCXc",item:"item-hcyAOCXc"}},78135:(e,t,n)=>{"use strict";n.d(t,{HorizontalAttachEdge:()=>i,HorizontalDropDirection:()=>l,VerticalAttachEdge:()=>o,VerticalDropDirection:()=>r,getPopupPositioner:()=>c});var o,i,r,l,a=n(50151);!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"}(l||(l={}));const s={
verticalAttachEdge:o.Bottom,horizontalAttachEdge:i.Left,verticalDropDirection:r.FromTopToBottom,horizontalDropDirection:l.FromLeftToRight,verticalMargin:0,horizontalMargin:0,matchButtonAndListboxWidths:!1};function c(e,t){return n=>{var c,d;const{contentWidth:u,contentHeight:p,availableHeight:m}=n,h=(0,a.ensureNotNull)(e).getBoundingClientRect(),{horizontalAttachEdge:f=s.horizontalAttachEdge,horizontalDropDirection:b=s.horizontalDropDirection,horizontalMargin:v=s.horizontalMargin,verticalMargin:y=s.verticalMargin,matchButtonAndListboxWidths:g=s.matchButtonAndListboxWidths}=t;let E=null!==(c=t.verticalAttachEdge)&&void 0!==c?c:s.verticalAttachEdge,w=null!==(d=t.verticalDropDirection)&&void 0!==d?d:s.verticalDropDirection;E===o.AutoStrict&&(m<h.y+h.height+y+p?(E=o.Top,w=r.FromBottomToTop):(E=o.Bottom,w=r.FromTopToBottom));const C=E===o.Top?-1*y:y,D=f===i.Right?h.right:h.left,S=E===o.Top?h.top:h.bottom,V={x:D-(b===l.FromRightToLeft?u:0)+v,y:S-(w===r.FromBottomToTop?p:0)+C};return g&&(V.overrideWidth=h.width),V}}},23351:(e,t,n)=>{"use strict";n.d(t,{convertToDefinitionProperty:()=>r,makeProxyDefinitionProperty:()=>i});var o=n(51768);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,l={value:()=>i(e.value()),setValue:t=>{e.setValue(r(t))},subscribe:(t,n)=>{const i=e=>{n(l)};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(),null==n||n()}};return l}function r(e,t,n,r,l,a,s){const c=i(t.weakReference(),r,a),d=void 0!==r?void 0!==r[1]?r[1]:r[0]:e=>e,u=null!=l?l:o=>e.setProperty(t,d(o),n);return c.setValue=e=>{var t;s&&(0,o.trackEvent)(s.category,s.event,null===(t=s.label)||void 0===t?void 0:t.call(s,e)),u(e)},c}},59411:(e,t,n)=>{"use strict";n.d(t,{createLinePropertyDefinition:()=>s});var o=n(49857),i=n(51056);const r=[i.LINESTYLE_SOLID,i.LINESTYLE_DOTTED,i.LINESTYLE_DASHED],l=[1,2,3,4],a=[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=l),void 0===n.properties.leftEnd&&void 0===n.properties.rightEnd||void 0!==n.endsValues||(n.endsValues=a),void 0!==n.properties.value&&void 0===n.valueType&&(n.valueType=1),n}},14139:(e,t,n)=>{"use strict";function o(e,t){return{propType:"options",properties:e,...t}}n.d(t,{createOptionsPropertyDefinition:()=>o})},4116:(e,t,n)=>{"use strict";function o(e,t){return{propType:"checkable",properties:e,...t}}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}}n.d(t,{convertFromReadonlyWVToDefinitionProperty:()=>J,convertFromWVToDefinitionProperty:()=>H,convertToDefinitionProperty:()=>z.convertToDefinitionProperty,createCheckablePropertyDefinition:()=>o,createCheckableSetPropertyDefinition:()=>i,createColorPropertyDefinition:()=>r,createCoordinatesPropertyDefinition:()=>T,
createEmojiPropertyDefinition:()=>R,createLeveledLinePropertyDefinition:()=>d,createLinePropertyDefinition:()=>l.createLinePropertyDefinition,createNumberPropertyDefinition:()=>p,createOptionalTwoColorsPropertyDefinition:()=>N,createOptionsPropertyDefinition:()=>m.createOptionsPropertyDefinition,createPropertyDefinitionsCheckableListOptionsGroup:()=>W,createPropertyDefinitionsGeneralGroup:()=>A,createPropertyDefinitionsLeveledLinesGroup:()=>G,createRangePropertyDefinition:()=>I,createSelectionCoordinatesPropertyDefinition:()=>k,createSessionPropertyDefinition:()=>B,createStudyInputsPropertyDefinition:()=>L,createSymbolPropertyDefinition:()=>_,createTextPropertyDefinition:()=>x,createTransparencyPropertyDefinition:()=>M,createTwoColorsPropertyDefinition:()=>P,createTwoOptionsPropertyDefinition:()=>h,destroyDefinitions:()=>ae,getColorDefinitionProperty:()=>q,getLockPriceScaleDefinitionProperty:()=>j,getPriceScaleSelectionStrategyDefinitionProperty:()=>Z,getScaleRatioDefinitionProperty:()=>K,getSymbolDefinitionProperty:()=>Q,isCheckableListOptionsDefinition:()=>le,isColorDefinition:()=>oe,isLineDefinition:()=>ne,isOptionsDefinition:()=>re,isPropertyDefinition:()=>ee,isPropertyDefinitionsGroup:()=>te,isTwoColorDefinition:()=>ie,makeProxyDefinitionProperty:()=>z.makeProxyDefinitionProperty});var l=n(59411),a=n(51056);const s=[a.LINESTYLE_SOLID,a.LINESTYLE_DOTTED,a.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;function p(e,t){return{propType:"number",properties:e,type:1,...t}}!function(e){e[e.Integer=0]="Integer",e[e.Float=1]="Float"}(u||(u={}));var m=n(14139);function h(e,t){return{propType:"twoOptions",properties:e,...t}}var f,b,v,y=n(11542);!function(e){e.Top="bottom",e.Middle="middle",e.Bottom="top"}(f||(f={})),function(e){e.Left="left",e.Center="center",e.Right="right"}(b||(b={})),function(e){e.Horizontal="horizontal",e.Vertical="vertical"}(v||(v={}));const g=[{id:"bottom",value:"bottom",title:y.t(null,void 0,n(97118))},{id:"middle",value:"middle",title:y.t(null,void 0,n(68833))},{id:"top",value:"top",title:y.t(null,void 0,n(27567))}],E=[{id:"left",value:"left",title:y.t(null,void 0,n(11626))},{id:"center",value:"center",title:y.t(null,void 0,n(24197))},{id:"right",value:"right",title:y.t(null,void 0,n(50421))}],w=[{id:"horizontal",value:"horizontal",title:y.t(null,void 0,n(95406))},{id:"vertical",value:"vertical",title:y.t(null,void 0,n(69526))}],C=[10,11,12,14,16,20,24,28,32,40].map((e=>({title:String(e),value:e}))),D=[1,2,3,4],S=y.t(null,void 0,n(25485)),V=y.t(null,void 0,n(67781));function x(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=C),void 0!==n.properties.alignmentVertical&&void 0===n.alignmentVerticalItems&&(n.alignmentVerticalItems=g),void 0!==n.properties.alignmentHorizontal&&void 0===n.alignmentHorizontalItems&&(n.alignmentHorizontalItems=E),
(n.alignmentVerticalItems||n.alignmentHorizontalItems)&&void 0===n.alignmentTitle&&(n.alignmentTitle=S),void 0!==n.properties.orientation&&(void 0===n.orientationItems&&(n.orientationItems=w),void 0===n.orientationTitle&&(n.orientationTitle=V)),void 0!==n.properties.borderWidth&&void 0===n.borderWidthItems&&(n.borderWidthItems=D),n}function P(e,t){return{propType:"twoColors",properties:e,noAlpha1:!1,noAlpha2:!1,...t}}function N(e,t){return{propType:"optionalTwoColors",properties:e,noAlpha1:!1,noAlpha2:!1,...t}}function T(e,t){return{propType:"coordinates",properties:e,...t}}function k(e,t){return{propType:"selectionCoordinates",properties:e,...t}}function I(e,t){return{propType:"range",properties:e,...t}}function M(e,t){return{propType:"transparency",properties:e,...t}}function _(e,t){return{propType:"symbol",properties:e,...t}}function B(e,t){return{propType:"session",properties:e,...t}}function R(e,t){return{propType:"emoji",properties:e,...t}}function L(e,t){return{propType:"studyInputs",properties:e,...t}}var F=n(64147);function A(e,t,n,o){return{id:t,title:n,visible:o,groupType:"general",definitions:new F.WatchedValue(e)}}function W(e,t,n,o,i){return{id:n,title:o,visible:i,groupType:"checkableListOptions",definitions:new F.WatchedValue(t),checkableListOptions:e}}function G(e,t,n){return{id:t,title:n,groupType:"leveledLines",definitions:new F.WatchedValue(e)}}var z=n(23351);function O(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,l={value:()=>i(e.value()),setValue:t=>{var n;null===(n=e.setValue)||void 0===n||n.call(e,r(t))},subscribe:(t,n)=>{const i=()=>{n(l)};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&&(l.destroy=()=>n()),l}function H(e,t,n,o){const i=O(t,o),r=void 0!==o?void 0!==o[1]?o[1]:o[0]:e=>e;return i.setValue=o=>e.setWatchedValue(t,r(o),n),i}function J(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 O(r,n,o)}(e,(e=>e),t,(()=>e.release()))}function Z(e,t){const n=(0,z.makeProxyDefinitionProperty)(t.weakReference());return n.setValue=t=>e.setPriceScaleSelectionStrategy(t),n}function j(e,t,n,o){const i=(0,z.makeProxyDefinitionProperty)(t.weakReference());return i.setValue=t=>{const i={lockScale:t};e.setPriceScaleMode(i,n,o)},i}function K(e,t,n,o){const i=(0,z.makeProxyDefinitionProperty)(t.weakReference(),o);return i.setValue=o=>{e.setScaleRatioProperty(t,o,n)},i}var U=n(24377),X=n(19063),Y=n(99531);function $(e,t){if((0,X.isHexColor)(e)){const n=(0,U.parseRgb)(e);return(0,U.rgbaToString)((0,U.rgba)(n,(100-t)/100))}return e}function q(e,t,n,o,i){let r;if(null!==n){const e=(0,
Y.combineProperty)($,t.weakReference(),n.weakReference());r=(0,z.makeProxyDefinitionProperty)(e.ownership())}else r=(0,z.makeProxyDefinitionProperty)(t.weakReference(),[()=>$(t.value(),0),e=>e]);return r.setValue=n=>{i&&e.beginUndoMacro(o),e.setProperty(t,n,o),i&&e.endUndoMacro()},r}function Q(e,t,n,o,i,r){const l=[(a=n,s=t,e=>{const t=a(s);if(e===s.value()&&null!==t){const e=t.ticker||t.full_name;if(e)return e}return e}),e=>e];var a,s;const c=(0,z.convertToDefinitionProperty)(e,t,i,l);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 ee(e){return e.hasOwnProperty("propType")}function te(e){return e.hasOwnProperty("groupType")}function ne(e){return"line"===e.propType}function oe(e){return"color"===e.propType}function ie(e){return"twoColors"===e.propType}function re(e){return"options"===e.propType}function le(e){return"checkableListOptions"===e.groupType}function ae(e){e.forEach((e=>{var t;if(ee(e)){Object.keys(e.properties).forEach((t=>{const n=e.properties[t];void 0!==n&&void 0!==n.destroy&&n.destroy()}))}else ae(e.definitions.value()),null===(t=e.visible)||void 0===t||t.destroy()}))}},60925:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 18 18" width="18" height="18"><path fill="currentColor" d="M12 4h3v1h-1.04l-.88 9.64a1.5 1.5 0 0 1-1.5 1.36H6.42a1.5 1.5 0 0 1-1.5-1.36L4.05 5H3V4h3v-.5C6 2.67 6.67 2 7.5 2h3c.83 0 1.5.67 1.5 1.5V4ZM7.5 3a.5.5 0 0 0-.5.5V4h4v-.5a.5.5 0 0 0-.5-.5h-3ZM5.05 5l.87 9.55a.5.5 0 0 0 .5.45h5.17a.5.5 0 0 0 .5-.45L12.94 5h-7.9Z"/></svg>'},44996:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" width="28" height="28" fill="none"><path fill="currentColor" fillRule="evenodd" clipRule="evenodd" d="M7.5 13a1.5 1.5 0 1 0 0 3 1.5 1.5 0 0 0 0-3zM5 14.5a2.5 2.5 0 1 1 5 0 2.5 2.5 0 0 1-5 0zm9.5-1.5a1.5 1.5 0 1 0 0 3 1.5 1.5 0 0 0 0-3zM12 14.5a2.5 2.5 0 1 1 5 0 2.5 2.5 0 0 1-5 0zm9.5-1.5a1.5 1.5 0 1 0 0 3 1.5 1.5 0 0 0 0-3zM19 14.5a2.5 2.5 0 1 1 5 0 2.5 2.5 0 0 1-5 0z"/></svg>'},33765:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" width="18" height="18"><path fill="currentColor" d="M9.707 9l4.647-4.646-.707-.708L9 8.293 4.354 3.646l-.708.708L8.293 9l-4.647 4.646.708.708L9 9.707l4.646 4.647.708-.707L9.707 9z"/></svg>'},23851:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" width="28" height="28"><path fill="currentColor" d="M4 13h5v1H4v-1zM12 13h5v1h-5v-1zM20 13h5v1h-5v-1z"/></svg>'},57740:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" width="28" height="28" fill="currentColor"><circle cx="9" cy="14" r="1"/><circle cx="4" cy="14" r="1"/><circle cx="14" cy="14" r="1"/><circle cx="19" cy="14" r="1"/><circle cx="24" cy="14" r="1"/></svg>'},80427:e=>{
e.exports='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 28 28" width="28" height="28"><path fill="currentColor" d="M5.5 7a.5.5 0 0 0 0 1h17a.5.5 0 0 0 0-1h-17Zm0 6a.5.5 0 0 0 0 1h3a.5.5 0 0 0 0-1h-3Zm7 0a.5.5 0 0 0 0 1h3a.5.5 0 0 0 0-1h-3Zm6.5.5c0-.28.22-.5.5-.5h3a.5.5 0 0 1 0 1h-3a.5.5 0 0 1-.5-.5ZM7 20a1 1 0 1 1-2 0 1 1 0 0 1 2 0Zm4 0a1 1 0 1 1-2 0 1 1 0 0 1 2 0Zm3 1a1 1 0 1 0 0-2 1 1 0 0 0 0 2Zm5-1a1 1 0 1 1-2 0 1 1 0 0 1 2 0Zm3 1a1 1 0 1 0 0-2 1 1 0 0 0 0 2Z"/></svg>'},501:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" width="28" height="28"><path stroke="currentColor" d="M4 13.5h20"/></svg>'},98853:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" width="28" height="28" fill="none"><path stroke="currentColor" d="M4.5 13.5H24m-19.5 0L8 17m-3.5-3.5L8 10"/></svg>'},43382:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" width="28" height="28" fill="none"><path stroke="currentColor" d="M8.5 13.5a2 2 0 1 1-4 0 2 2 0 0 1 4 0zm0 0H24"/></svg>'},8295:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 28 28" width="28" height="28"><path fill="currentColor" d="M14 21h-3a1 1 0 0 1-1-1V8a1 1 0 0 1 1-1h3c2 0 4 1 4 3 0 1 0 2-1.5 3 1.5.5 2.5 2 2.5 4 0 2.75-2.638 4-5 4zM12 9l.004 3c.39.026.82 0 1.25 0C14.908 12 16 11.743 16 10.5c0-1.1-.996-1.5-2.5-1.5-.397 0-.927-.033-1.5 0zm0 5v5h1.5c1.5 0 3.5-.5 3.5-2.5S15 14 13.5 14c-.5 0-.895-.02-1.5 0z"/></svg>'},29285:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 28 28" width="28" height="28"><path fill="currentColor" d="M12.143 20l1.714-12H12V7h5v1h-2.143l-1.714 12H15v1h-5v-1h2.143z"/></svg>'}}]);