"use strict";(self.webpackChunktradingview=self.webpackChunktradingview||[]).push([[6477],{22523:(e,t,i)=>{i.d(t,{DateAndPriceBaseProperties:()=>p,allPropertiesStateKeysBase:()=>y,nonThemedFactoryDefaultsBase:()=>h,themedFactoryDefaultsBase:()=>m});var s=i(50151),r=i(58978),o=i(24633),a=i(65045),l=i(52859),n=i(37293),c=i(43337),u=i(88636);const d=(0,r.getHexColorByName)("color-tv-blue-500"),h={linewidth:2,fontsize:12,fillLabelBackground:!0,fillBackground:!0,backgroundTransparency:60,showVolume:!0,intervalsVisibilities:{...n.intervalsVisibilitiesDefaults},customText:{visible:!1,fontsize:12,bold:!1,italic:!1}},m=new Map([[o.StdTheme.Light,{textcolor:(0,r.getHexColorByName)("color-black"),labelBackgroundColor:(0,r.getHexColorByName)("color-white"),linecolor:d,backgroundColor:(0,l.generateColor)(d,85),shadow:"rgba(0, 0, 0, 0.2)",customText:{color:d}}],[o.StdTheme.Dark,{textcolor:(0,r.getHexColorByName)("color-white"),labelBackgroundColor:(0,r.getHexColorByName)("color-cold-gray-800"),linecolor:d,backgroundColor:(0,l.generateColor)(d,85),shadow:"rgba(0, 0, 0, 0.4)",customText:{color:d}}]]),y=["customText.text"];function f(e){const{showVolume:t=!0,...i}=e;return{...i,showVolume:t}}class p extends u.LineDataSourceProperty{constructor({nonThemedDefaultsKeys:e,themedDefaultsKeys:t,state:i,...r}){super({nonThemedDefaultsKeys:e,themedDefaultsKeys:t,templateKeys:[...e??[],...t??[],...y],state:i?f(i):void 0,...r});const o=i?.customText;this._textProperty=new c.Property(o?.text??""),this.childs().customText?.addChild("text",this._textProperty),this.addChild("textsColors",new a.LineToolColorsProperty([(0,s.ensureDefined)(this.childs().customText?.child("color"))]))}template(){const e=super.template();return e.customText.text=this._textProperty.value(),e}}},31558:(e,t,i)=>{i.d(t,{commonLineToolPropertiesStateKeys:()=>s});const s=["symbolStateVersion","zOrderVersion","frozen","title","interval","symbol","currencyId","unitId","visible","intervalsVisibilities.ticks","intervalsVisibilities.seconds","intervalsVisibilities.secondsFrom","intervalsVisibilities.secondsTo","intervalsVisibilities.minutes","intervalsVisibilities.minutesFrom","intervalsVisibilities.minutesTo","intervalsVisibilities.hours","intervalsVisibilities.hoursFrom","intervalsVisibilities.hoursTo","intervalsVisibilities.days","intervalsVisibilities.daysFrom","intervalsVisibilities.daysTo","intervalsVisibilities.weeks","intervalsVisibilities.weeksFrom","intervalsVisibilities.weeksTo","intervalsVisibilities.months","intervalsVisibilities.monthsFrom","intervalsVisibilities.monthsTo","intervalsVisibilities.ranges"];var r,o,a;!function(e){e[e.NotShared=0]="NotShared",e[e.SharedInLayout=1]="SharedInLayout",e[e.GloballyShared=2]="GloballyShared"}(r||(r={})),function(e){e.BeforeAllAction="BeforeAll",e.CustomAction="CustomAction"}(o||(o={})),function(e){e.FloatingToolbarButton="FloatingToolbarButton",e.Default="Default"}(a||(a={}))},88636:(e,t,i)=>{i.d(t,{LineDataSourceProperty:()=>l});var s=i(90054),r=i(16738),o=i(50151),a=i(78176);class l extends a.DefaultProperty{
constructor({templateKeys:e,...t}){super({ignoreAllowSavingDefaults:!0,saveNonDefaultUserPreferencesOnly:!0,...t}),this._templateKeys=(0,o.ensureDefined)(e||this._allDefaultsKeys)}template(){return(0,a.extractState)(this.state(),this._templateKeys,[])}applyTemplate(e){this.mergeAndFire((0,a.extractState)((0,r.default)((0,s.default)(this._factoryDefaultsSupplier()),e),this._templateKeys))}}},27223:(e,t,i)=>{i.r(t),i.d(t,{LineToolPriceRange:()=>b});var s=i(41414),r=i(50151),o=i(24633),a=i(78176),l=i(70031),n=i(22523),c=i(31558);const u={...n.nonThemedFactoryDefaultsBase,extendLeft:!1,extendRight:!1,showPriceRange:!0,showPercentPriceRange:!0,showPipsPriceRange:!0},d=n.themedFactoryDefaultsBase,h=(0,a.extractThemedColors)((0,r.ensureDefined)(d.get(o.StdTheme.Light)),(0,r.ensureDefined)(d.get(o.StdTheme.Dark))),m=(0,a.extractAllPropertiesKeys)((0,r.ensureDefined)(d.get(o.StdTheme.Light))),y=(0,a.extractAllPropertiesKeys)(u),f=[...new Set([...m,...y,...c.commonLineToolPropertiesStateKeys,...n.allPropertiesStateKeysBase])];class p extends n.DateAndPriceBaseProperties{static create(e,t){return new this({defaultName:"linetoolpricerange",factoryDefaultsSupplier:()=>(0,l.factoryDefaultsForCurrentTheme)(u,d),nonThemedDefaultsKeys:y,themedDefaultsKeys:m,allStateKeys:f,themedColors:h,replaceThemedColorsOnThemeChange:!0,state:t,theme:e})}}class b extends s.LineDataSource{constructor(e,t,s,r){super(e,t??b.createProperties(e.backgroundTheme().spawnOwnership()),s,r),Promise.all([i.e(6290),i.e(986),i.e(6668),i.e(1583)]).then(i.bind(i,23784)).then((e=>{this._setPaneViews([new e.PriceRangePaneView(this,this._model)])}))}pointsCount(){return 2}name(){return"Price Range"}template(){return this._properties.template()}static createProperties(e,t){const i=p.create(e,t);return this._configureProperties(i),i}async _getPropertyDefinitionsViewModelClass(){return(await Promise.all([i.e(3198),i.e(5410),i.e(2745),i.e(8823),i.e(8537)]).then(i.bind(i,86763))).GeneralDatePriceRangeDefinitionsViewModel}}},70031:(e,t,i)=>{i.d(t,{factoryDefaultsForCurrentTheme:()=>n});var s=i(16738),r=i(90054),o=i(50151),a=i(45345),l=i(24633);function n(e,t){const i=a.watchedTheme.value()??l.StdTheme.Light,n=(0,r.default)(e);return(0,s.default)(n,(0,o.ensureDefined)(t.get(i))),n}}}]);