7 lines
20 KiB
JavaScript
7 lines
20 KiB
JavaScript
"use strict";(self.webpackChunktradingview=self.webpackChunktradingview||[]).push([[8090],{14472:(e,t,i)=>{i.r(t),i.d(t,{LineDataSourceDefinitionsViewModel:()=>m,LineDataSourceTabTypes:()=>r,pointPriceBarTitle:()=>f});var r,n=i(50151),s=i(11542),o=i(95804),l=(i(40167),i(95338)),a=i(60567),c=i(22613),h=i(73863),d=i(97578),u=i(81634),p=i(36313);!function(e){e.Visibility="visibility",e.Coordinates="coordinates",e.Style="style",e.Text="text",e.Inputs="inputs"}(r||(r={}));const _=s.t(null,void 0,i(40091)),g=s.t(null,void 0,i(78930)),P=s.t(null,void 0,i(92516)),y=s.t(null,void 0,i(70320)),S=s.t(null,void 0,i(21429)),f=s.t(null,{context:"linetool point"},i(80166));class m{constructor(e,t){this._yCoordinateStepWV=null,this._propertyPages=[],this._source=t,this._undoModel=e,this._ownerSource=(0,n.ensureNotNull)(this._source.ownerSource()),this._propertyApplier=new u.PropertyApplierWithoutSavingChart((()=>e)),this._createPropertyRages()}destroy(){null!==this._yCoordinateStepWV&&(this._source.ownerSourceChanged().unsubscribeAll(this),this._ownerSource.priceStepChanged().unsubscribeAll(this)),this._source.pointAdded().unsubscribeAll(this),this._propertyPages.forEach((e=>{(0,l.destroyDefinitions)(e.definitions.value())}))}propertyPages(){return Promise.resolve(this._propertyPages)}_createPropertyRages(){this._propertyPages=[];const e=this._createInputsPropertyPage();null!==e&&this._propertyPages.push(e);const t=this._createStylePropertyPage();null!==t&&this._propertyPages.push(t);const i=this._createTextPropertyPage();null!==i&&this._propertyPages.push(i);const r=this._createCoordinatesPropertyPage();null!==r&&(r.visible=this._source.hasEditableCoordinates(),this._propertyPages.push(r));const n=this._createVisibilitiesPropertyPage();this._propertyPages.push(n)}_createVisibilitiesPropertyPage(){const e=this._source.properties().childs().intervalsVisibilities.childs();return(0,a.createPropertyPage)((0,h.getIntervalsVisibilitiesPropertiesDefinitions)(this._propertyApplier,e,new o.TranslatedString(this._source.name(),this._source.title(p.TitleDisplayTarget.StatusLine,!0))),"visibility",_)}_createCoordinatesPropertyPage(){const e=this._coordinatesPropertyDefinitions();return null!==e?(e.definitions.length<this._source.pointsCount()&&this._source.pointAdded().subscribe(this,this._updateCoordinatesPropertyDefinitons),(0,a.createPropertyPage)(e,"coordinates",g)):null}_getYCoordinateStepWV(){return null===this._yCoordinateStepWV&&(this._yCoordinateStepWV=new c.WatchedValue(function(e){if(null!==e){const t=e.priceStep();if(null!==t)return t}return 1}(this._source.ownerSource())),this._ownerSource.priceStepChanged().subscribe(this,(()=>this._updateYCoordinateStep())),this._source.ownerSourceChanged().subscribe(this,(()=>{this._ownerSource.priceStepChanged().unsubscribeAll(this),this._ownerSource=(0,n.ensureNotNull)(this._source.ownerSource()),this._ownerSource.priceStepChanged().subscribe(this,(()=>this._updateYCoordinateStep()))}))),this._yCoordinateStepWV}_coordinatesPropertyDefinitions(){
|
|
const e=this._source.points(),t=this._source.pointsProperty().childs().points,i=[],r=this._getYCoordinateStepWV();return e.forEach(((e,n)=>{const s=t[n].childs();s&&i.push((0,d.getCoordinatesPropertiesDefinitions)(this._propertyApplier,s,e,r,f.format({count:(n+1).toString()}),this._source.name()))})),{definitions:i}}_createStylePropertyPage(){const e=this._stylePropertyDefinitions();return null!==e?(0,a.createPropertyPage)(e,"style",P):null}_stylePropertyDefinitions(){return null}_createTextPropertyPage(){const e=this._textPropertyDefinitions();return null!==e?(0,a.createPropertyPage)(e,"text",y):null}_textPropertyDefinitions(){return null}_createInputsPropertyPage(){const e=this._inputsPropertyDefinitions();return null!==e?(0,a.createPropertyPage)(e,"inputs",S):null}_inputsPropertyDefinitions(){return null}_updateYCoordinateStep(){const e=this._ownerSource.priceStep();this._getYCoordinateStepWV().setValue(e||1)}_updateCoordinatesPropertyDefinitons(){const e=this._coordinatesPropertyDefinitions();if(null!==e){(0,n.ensureDefined)(this._propertyPages.find((e=>"coordinates"===e.id))).definitions.setValue(e.definitions),this._source.points().length===this._source.pointsCount()&&this._source.pointAdded().unsubscribeAll(this)}}}},40882:(e,t,i)=>{i.r(t),i.d(t,{LineToolFibSpiral:()=>q});var r=i(41414),n=i(58978),s=i(50151),o=i(24633),l=i(69558),a=i(37293),c=i(31558),h=i(78176),d=i(70031),u=i(88636),p=i(65045);const _={intervalsVisibilities:{...a.intervalsVisibilitiesDefaults},counterclockwise:!1,linewidth:2,linestyle:l.LINESTYLE_SOLID},g={linecolor:(0,n.getHexColorByName)("color-sky-blue-500")},P=new Map([[o.StdTheme.Light,g],[o.StdTheme.Dark,g]]),y=(0,h.extractThemedColors)((0,s.ensureDefined)(P.get(o.StdTheme.Light)),(0,s.ensureDefined)(P.get(o.StdTheme.Dark))),S=(0,h.extractAllPropertiesKeys)((0,s.ensureDefined)(P.get(o.StdTheme.Light))),f=(0,h.extractAllPropertiesKeys)(_),m=[...new Set([...S,...f,...c.commonLineToolPropertiesStateKeys])];class v extends u.LineDataSourceProperty{constructor(e){super(e),this.addChild("linesColors",new p.LineToolColorsProperty([(0,s.ensureDefined)(this.child("linecolor"))])),this.addChild("linesWidths",new p.LineToolWidthsProperty([(0,s.ensureDefined)(this.child("linewidth"))]))}static create(e,t){return new this({defaultName:"linetoolfibspiral",factoryDefaultsSupplier:()=>(0,d.factoryDefaultsForCurrentTheme)(_,P),nonThemedDefaultsKeys:f,themedDefaultsKeys:S,allStateKeys:m,themedColors:y,replaceThemedColorsOnThemeChange:!0,state:t,theme:e})}}var b=i(94602),w=i(25672),T=i(80819),D=i(54707),C=i(2383),x=i(58221),I=i(4539),A=i(20820);const k=[0,1,2,3,5,8,13,21,34,55,89];class R extends A.MediaCoordinatesPaneRenderer{constructor(){super(...arguments),this._data=null}setData(e){this._data=e}hitTest(e){if(null===this._data||this._data.points.length<2)return null;const t=this._data.points[0],i=this._data.points[1].subtract(t),r=e.subtract(t),n=i.normalized(),s=n.transposed(),o=r.normalized();let l=Math.acos(n.dotProduct(o));Math.asin(s.dotProduct(o))<0&&(l=2*Math.PI-l)
|
|
;const a=this._data.counterclockwise?-1:1,c=r.length(),h=(0,I.interactionTolerance)().curve;for(let e=0;e<4;e++){const t=a*l/(.5*Math.PI);let r=this._continiusFib(t+4*e);if(null!==r&&(r=r*i.length()/5,Math.abs(r-c)<h))return new C.HitTestResult(C.HitTarget.MovePoint)}return null}_drawImpl(e){if(null===this._data||this._data.points.length<2)return;const t=e.context;t.lineCap="round",t.strokeStyle=this._data.color;const i=this._data.points[0],r=this._data.points[1];t.translate(i.x,i.y);let n=r.subtract(i);const s=n.length();n=n.normalized();let o=Math.acos(n.x);Math.asin(n.y)<0&&(o=2*Math.PI-o),t.rotate(o),t.scale(s/5,s/5),t.lineWidth=this._data.linewidth,(0,x.setLineStyle)(t,this._data.linestyle);const l=Math.PI/100;t.moveTo(0,0);const a=this._data.counterclockwise?-1:1;for(let e=0;e<50*(k.length-1);e++){const i=a*e*l,r=this._continiusFib(e/50);if(null===r)break;const n=Math.cos(i)*r,s=Math.sin(i)*r;t.lineTo(n,s)}t.scale(5/s,5/s),t.rotate(-o),t.stroke()}_continiusFib(e){const t=Math.floor(e),i=Math.ceil(e);if(i>=k.length)return null;let r=e-t;r=Math.pow(r,1.15);return k[t]+(k[i]-k[t])*r}}class M extends D.LineSourcePaneView{constructor(){super(...arguments),this._trendLineRenderer=new T.TrendLineRenderer,this._spiralRenderer=new R,this._renderer=null}renderer(e){return this._invalidated&&this._updateImpl(e),this._renderer}_updateImpl(e){if(super._updateImpl(e),this._renderer=null,this._points.length<2)return;const t=new b.CompositeRenderer,i=this._source.properties().childs();{const e={points:[this._points[0],this._points[1]],color:i.linecolor.value(),linewidth:i.linewidth.value(),linestyle:i.linestyle.value(),extendleft:!1,extendright:!0,leftend:w.LineEnd.Normal,rightend:w.LineEnd.Normal};this._trendLineRenderer.setData(e),t.append(this._trendLineRenderer)}{const e={points:this._points,color:i.linecolor.value(),linewidth:i.linewidth.value(),linestyle:i.linestyle.value(),counterclockwise:i.counterclockwise.value()};this._spiralRenderer.setData(e),t.append(this._spiralRenderer)}this.addAnchors(t),this._renderer=t}}var V=i(11542),L=i(95804),W=i(95338),E=i(14472),N=i(91682);const F=new L.TranslatedString("change {title} line color",V.t(null,void 0,i(7455))),B=new L.TranslatedString("change {title} line width",V.t(null,void 0,i(46040))),H=new L.TranslatedString("change {title} line style",V.t(null,void 0,i(30843))),z=new L.TranslatedString("change {title} counterclockwise",V.t(null,void 0,i(60003))),K=V.t(null,void 0,i(3554)),O=V.t(null,void 0,i(33004));class Y extends E.LineDataSourceDefinitionsViewModel{_stylePropertyDefinitions(){const e=this._source.properties().childs(),t=this._source.name(),i=(0,N.removeSpaces)(t),r=new L.TranslatedString(t,this._source.translatedType());return{definitions:[(0,W.createLinePropertyDefinition)({color:(0,W.getColorDefinitionProperty)(this._propertyApplier,e.linecolor,null,F.format({title:r})),width:(0,W.convertToDefinitionProperty)(this._propertyApplier,e.linewidth,B.format({title:r})),style:(0,W.convertToDefinitionProperty)(this._propertyApplier,e.linestyle,H.format({title:r}))},{
|
|
id:`${i}Line`,title:K}),(0,W.createCheckablePropertyDefinition)({checked:(0,W.convertToDefinitionProperty)(this._propertyApplier,e.counterclockwise,z.format({title:r}))},{id:`${i}Counterclockwise`,title:O})]}}}class q extends r.LineDataSource{constructor(e,t,i,r){super(e,t??q.createProperties(e.backgroundTheme().spawnOwnership()),i,r),this._setPaneViews([new M(this,e)])}pointsCount(){return 2}name(){return"Fib Spiral"}template(){return this._properties.template()}static createProperties(e,t){const i=v.create(e,t);return this._configureProperties(i),i}async _getPropertyDefinitionsViewModelClass(){return Y}static _addCollectedProperties(e){}}},31558:(e,t,i)=>{i.d(t,{commonLineToolPropertiesStateKeys:()=>r});const r=["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 n,s,o;!function(e){e[e.NotShared=0]="NotShared",e[e.SharedInLayout=1]="SharedInLayout",e[e.GloballyShared=2]="GloballyShared"}(n||(n={})),function(e){e.BeforeAllAction="BeforeAll",e.CustomAction="CustomAction"}(s||(s={})),function(e){e.FloatingToolbarButton="FloatingToolbarButton",e.Default="Default"}(o||(o={}))},54707:(e,t,i)=>{i.d(t,{LineSourcePaneView:()=>P,anchorResizeCursorType:()=>_,createLineSourcePaneViewPoint:()=>g});var r=i(58978),n=i(50151),s=i(39612),o=i(2383),l=i(45801),a=i(73914),c=i(43838),h=i(4753);const d=r.colorsPalette["color-tv-blue-600"];var u,p;function _(e,t){const i=e.x-t.x,r=e.y-t.y;if(!Number.isFinite(i)||!Number.isFinite(r)||0===i&&0===r)return c.PaneCursorType.Default;let s=Math.atan2(r,i);return s<0&&(s+=2*Math.PI),s>=p.deg337_5||s<p.deg22_5||s>=p.deg157_5&&s<p.deg202_5?c.PaneCursorType.HorizontalResize:s>=p.deg22_5&&s<p.deg67_5||s>=p.deg202_5&&s<p.deg247_5?c.PaneCursorType.DiagonalNwSeResize:s>=p.deg67_5&&s<p.deg112_5||s>=p.deg247_5&&s<p.deg292_5?c.PaneCursorType.VerticalResize:s>=p.deg112_5&&s<p.deg157_5||s>=p.deg292_5&&s<p.deg337_5?c.PaneCursorType.DiagonalNeSwResize:void(0,n.assert)(!1,"unexpected angle")}function g(e,t){return e.pointIndex=t,e}!function(e){e[e.RegularAnchorRadius=6]="RegularAnchorRadius",e[e.TouchAnchorRadius=13]="TouchAnchorRadius",e[e.RegularStrokeWidth=1]="RegularStrokeWidth",e[e.TouchStrokeWidth=3]="TouchStrokeWidth",e[e.RegularSelectedStrokeWidth=3]="RegularSelectedStrokeWidth",e[e.TouchSelectedStrokeWidth=0]="TouchSelectedStrokeWidth"}(u||(u={})),function(e){e[e.deg22_5=Math.PI/8]="deg22_5",
|
|
e[e.deg67_5=3*Math.PI/8]="deg67_5",e[e.deg112_5=5*Math.PI/8]="deg112_5",e[e.deg157_5=7*Math.PI/8]="deg157_5",e[e.deg202_5=9*Math.PI/8]="deg202_5",e[e.deg247_5=11*Math.PI/8]="deg247_5",e[e.deg292_5=13*Math.PI/8]="deg292_5",e[e.deg337_5=15*Math.PI/8]="deg337_5"}(p||(p={}));class P{constructor(e,t,i){this._invalidated=!0,this._points=[],this._middlePoint=null,this._selectionRenderers=[],this._lineAnchorRenderers=[],this._source=e,this._model=t,this._ownerSource=i??null}priceToCoordinate(e){const t=this._getOwnerSource(),i=t?.priceScale();if(null==i)return null;const r=null!==t?t.firstValue():null;return null===r?null:i.priceToCoordinate(e,r)}anchorColor(){return d}isHoveredSource(){return this._source===this._model.hoveredSource()}isSelectedSource(){return this._model.selection().isSelected(this._source)}isBeingEdited(){return this._model.lineBeingEdited()===this._source}isEditMode(){return!this._model.isSnapshot()}areAnchorsVisible(){return(this.isHoveredSource()&&!this.isLocked()||this.isSelectedSource())&&this.isEditMode()}update(){this._invalidated=!0}isLocked(){return Boolean(this._source.isLocked&&this._source.isLocked())}addAnchors(e,t={}){let i=this._getPoints();this._model.lineBeingCreated()===this._source&&(i=i.slice(0,-1));const r=this._source.points(),n=i.map(((e,t)=>{const i=r[t],n=(0,a.lineSourcePaneViewPointToLineAnchorPoint)(e);return i&&(n.snappingPrice=i.price,n.snappingIndex=i.index),n}));e.append(this.createLineAnchor({...t,points:n},0))}createLineAnchor(e,t){const i=e.points.map((e=>e.point)),r=this._getOwnerSource();if(this.isLocked()){const n=this._getSelectionRenderer(t);return n.setData({bgColors:this._lineAnchorColors(i),points:e.points,visible:this.areAnchorsVisible(),hittestResult:o.HitTarget.Regular,ownerSourceId:r?.id(),barSpacing:this._model.timeScale().barSpacing()}),n}const n=(0,s.lastMouseOrTouchEventInfo)().isTouch,l=this._getLineAnchorRenderer(t),a=this.isHoveredSource()?this._model.lastHittestData()?.pointIndex??null:null;return l.setData({...e,color:this.anchorColor(),backgroundColors:this._lineAnchorColors(i),hoveredPointIndex:a,linePointBeingEdited:this.isBeingEdited()?this._model.linePointBeingEdited():null,radius:this._anchorRadius(),strokeWidth:n?u.TouchStrokeWidth:u.RegularStrokeWidth,selected:this.isSelectedSource(),selectedStrokeWidth:n?u.TouchSelectedStrokeWidth:u.RegularSelectedStrokeWidth,visible:this.areAnchorsVisible(),clickHandler:e.clickHandler,ownerSourceId:r?.id()}),l}_getOwnerSource(){return this._ownerSource??this._source.ownerSource()}_anchorRadius(){return(0,s.lastMouseOrTouchEventInfo)().isTouch?u.TouchAnchorRadius:u.RegularAnchorRadius}_lineAnchorColors(e){const t=(0,n.ensureNotNull)(this._model.paneForSource(this._source)).height();return e.map((e=>this._model.backgroundColorAtYPercentFromTop(e.y/t)))}_updateImpl(e){this._points=[];this._model.timeScale().isEmpty()||this._validatePriceScale()&&(this._source.points().forEach(((e,t)=>{const i=this._source.pointToScreenPoint(e,this._ownerSource??void 0);i&&this._points.push(g(i,t))})),
|
|
2===this._points.length&&(this._middlePoint=this._source.calcMiddlePoint(this._points[0],this._points[1])),this._invalidated=!1)}_validatePriceScale(){const e=this._getOwnerSource()?.priceScale();return null!=e&&!e.isEmpty()}_getSource(){return this._source}_getPoints(){return this._points}_getModel(){return this._model}_height(){const e=this._getOwnerSource()?.priceScale();return null!=e?e.height():0}_width(){return this._model.timeScale().width()}_needLabelExclusionPath(e,t){const i=this._source.properties().childs();return"middle"===(t??i.vertLabelsAlign.value())&&(0,h.needTextExclusionPath)(e)}_addAlertRenderer(e,t,i=this._source.properties().linecolor.value()){}_getAlertRenderer(e,t=this._source.properties().linecolor.value(),i){return null}_getSelectionRenderer(e){for(;this._selectionRenderers.length<=e;)this._selectionRenderers.push(new l.SelectionRenderer);return this._selectionRenderers[e]}_getLineAnchorRenderer(e){for(;this._lineAnchorRenderers.length<=e;)this._lineAnchorRenderers.push(new a.LineAnchorRenderer);return this._lineAnchorRenderers[e]}}},88636:(e,t,i)=>{i.d(t,{LineDataSourceProperty:()=>l});var r=i(90054),n=i(16738),s=i(50151),o=i(78176);class l extends o.DefaultProperty{constructor({templateKeys:e,...t}){super({ignoreAllowSavingDefaults:!0,saveNonDefaultUserPreferencesOnly:!0,...t}),this._templateKeys=(0,s.ensureDefined)(e||this._allDefaultsKeys)}template(){return(0,o.extractState)(this.state(),this._templateKeys,[])}applyTemplate(e){this.mergeAndFire((0,o.extractState)((0,n.default)((0,r.default)(this._factoryDefaultsSupplier()),e),this._templateKeys))}}},73914:(e,t,i)=>{i.d(t,{LineAnchorRenderer:()=>y,lineSourcePaneViewPointToLineAnchorPoint:()=>S,lineSourcePaneViewPointToLineAnchorPoint2:()=>f,mapLineSourcePaneViewPointToLineAnchorPoint:()=>m});var r=i(10555),n=i(6453),s=i(50151),o=i(58221),l=i(87465),a=i(2383),c=i(43838),h=i(4539),d=i(10307);function u(e,t,i,r){const{point:n}=t,s=i+r/2;(0,o.drawRoundRect)(e,n.x-s,n.y-s,2*s,2*s,(i+r)/2),e.closePath(),e.lineWidth=r}function p(e,t,i,r){e.globalAlpha=.2,u(e,t,i,r),e.stroke(),e.globalAlpha=1}function _(e,t,i,r){u(e,t,i-r,r),e.fill(),e.stroke()}function g(e,t,i,r){const{point:n}=t;e.globalAlpha=.2,e.beginPath(),e.arc(n.x,n.y,i+r/2,0,2*Math.PI,!0),e.closePath(),e.lineWidth=r,e.stroke(),e.globalAlpha=1}function P(e,t,i,r){const{point:n}=t;e.beginPath(),e.arc(n.x,n.y,i-r/2,0,2*Math.PI,!0),e.closePath(),e.lineWidth=r,e.fill(),e.stroke()}class y extends d.BitmapCoordinatesPaneRenderer{constructor(e){super(),this._data=e??null}setData(e){this._data=e}hitTest(e){if(null===this._data||this._data.disableInteractions)return null;const{radius:t,points:i}=this._data,r=t+(0,h.interactionTolerance)().anchor;for(const t of i){if(t.point.subtract(e).length()<=r)return new a.HitTestResult(t.hitTarget??a.HitTarget.ChangePoint,{areaName:a.AreaName.AnchorPoint,pointIndex:t.pointIndex,cursorType:t.cursorType??c.PaneCursorType.Default,activeItem:t.activeItem,snappingPrice:t.snappingPrice,snappingIndex:t.snappingIndex,nonDiscreteIndex:t.nonDiscreteIndex,
|
|
possibleMovingDirections:t.possibleMovingDirections,clickHandler:this._data.clickHandler,tapHandler:this._data.clickHandler,ownerSourceId:this._data.ownerSourceId})}return null}doesIntersectWithBox(e){return null!==this._data&&this._data.points.some((t=>(0,n.pointInBox)(t.point,e)))}_drawImpl(e){if(null===this._data||!this._data.visible)return;const t=[],i=[],r=[],n=[];for(let e=0;e<this._data.points.length;++e){const s=this._data.points[e],o=this._data.backgroundColors[e];s.square?(t.push(s),i.push(o)):(r.push(s),n.push(o))}t.length&&this._drawPoints(e,t,i,_,p),r.length&&this._drawPoints(e,r,n,P,g)}_drawPoints(e,t,i,n,o){const{context:a,horizontalPixelRatio:c,verticalPixelRatio:h}=e,d=(0,s.ensureNotNull)(this._data),u=d.radius;let p=Math.max(1,Math.floor((d.strokeWidth||2)*c));d.selected&&(p+=Math.max(1,Math.floor(c/2)));const _=Math.max(1,Math.floor(c));let g=Math.round(u*c*2);g%2!=_%2&&(g+=1);const P=_%2/2;a.strokeStyle=d.color;for(let e=0;e<t.length;++e){const s=t[e];if(!((0,l.isInteger)(s.pointIndex)&&d.linePointBeingEdited===s.pointIndex)){a.fillStyle=i[e];if(n(a,{...s,point:new r.Point(Math.round(s.point.x*c)+P,Math.round(s.point.y*h)+P)},g/2,p),!d.disableInteractions){if(null!==d.hoveredPointIndex&&s.pointIndex===d.hoveredPointIndex){const e=Math.max(1,Math.floor(d.selectedStrokeWidth*c));let t=Math.round(u*c*2);t%2!=_%2&&(t+=1);o(a,{...s,point:new r.Point(Math.round(s.point.x*c)+P,Math.round(s.point.y*h)+P)},t/2,e)}}}}}}function S(e,t=e.pointIndex,i,r,n,s,o,l,a,c){return{point:e,pointIndex:t,cursorType:i,square:r,hitTarget:n,snappingPrice:s,snappingIndex:o,nonDiscreteIndex:l,activeItem:a,possibleMovingDirections:c}}function f(e){return S(e.point,e.pointIndex,e.cursorType,e.square,e.hitTarget,e.snappingPrice,e.snappingIndex,e.nonDiscreteIndex,e.activeItem,e.possibleMovingDirections)}function m(e){return S(e)}},70031:(e,t,i)=>{i.d(t,{factoryDefaultsForCurrentTheme:()=>a});var r=i(16738),n=i(90054),s=i(50151),o=i(45345),l=i(24633);function a(e,t){const i=o.watchedTheme.value()??l.StdTheme.Light,a=(0,n.default)(e);return(0,r.default)(a,(0,s.ensureDefined)(t.get(i))),a}}}]); |