PageSourceSearch

https://trailence.org/chunk-CL3IXEz4.js

js trailence.org collected 2026-09-24 15:11:02 UTC 3,228 bytes, 1 lines download raw bytes

1import{An as gy,Cn as fh,F as Hh,Kt as ZI,M as HT,Or as sl,Qt as aT,Sn as fT,an as bh,cr as pT,g as EE,kt as WD,m as Dh,ut as Ri,vt as UD,w as Ge}from"./chunk-hDFLhPjY.js";import{k as H4,un as lI}from"./chunk-DvgwK5vQ.js";var y=[`range`];function w(n,b){if(n&1&&(Ri(0,`ion-label`,2),HT(1),sl()),n&2){let e=aT();EE(),Hh(e.minValueLabel?e.minValueLabel:e.config.formatter(e.config.values[0]))}}function L(n,b){if(n&1&&(Ri(0,`ion-label`,3),HT(1),sl()),n&2){let e=aT();EE(),Hh(e.maxValueLabel?e.maxValueLabel:e.config.formatter(e.config.values[e.config.values.length-1]))}}var k=(()=>{class n{constructor(){this.valueChange=new Ge,this.valueFormatter=e=>this.config.formatter(this.getValueFromIndex(e)),this.ionValue=0}ngOnInit(){this.refresh()}ngOnChanges(){this.refresh()}getValueFromIndex(e){return e<0?this.config.values[0]:e>=this.config.values.length?this.config.values.at(-1):this.config.values[e]}getRealValueFromIndex(e){return this.config.realValues?e<0?this.config.realValues[0]:e>=this.config.realValues.length?this.config.realValues.at(-1):this.config.realValues[e]:this.getValueFromIndex(e)}getIndexFromValue(e){for(let t=0;t<this.config.values.length;++t)if(e<=this.config.values[t])return t;return this.config.values.at(-1)}getIndexFromRealValue(e){if(!this.config.realValues)return this.getIndexFromValue(e);for(let t=0;t<this.config.realValues.length;++t)if(e<=this.config.realValues[t])return t;return this.config.realValues.at(-1)}refresh(){typeof this.value==`number`?this.ionValue=this.getIndexFromRealValue(this.value):this.ionValue={lower:this.value.from===void 0?0:this.getIndexFromRealValue(this.value.from),upper:this.value.to===void 0?this.config.values.length-1:this.getIndexFromRealValue(this.value.to)},this.valueFormatter=e=>this.config.formatter(this.getValueFromIndex(e))}ionValueChanged(e){if(this.ionValue=e,typeof e==`number`){let t=this.getRealValueFromIndex(e);if(t===this.value)return;this.value=t}else{let t={from:this.getRealValueFromIndex(e.lower),to:this.getRealValueFromIndex(e.upper)};if(typeof this.value!=`number`&&t.from===this.value.from&&t.to===this.value.to)return;this.value=t}this.valueChange.emit(this.value)}static{this.ɵfac=function(t){return new(t||n)}}static{this.ɵcmp=ZI({type:n,selectors:[[`app-filter-numeric-custom`]],viewQuery:function(t,i){if(t&1&&bh(y,5),t&2){let r;fT(r=pT())&&(i.ionRange=r.first)}},inputs:{config:`config`,value:`value`,minValueLabel:`minValueLabel`,maxValueLabel:`maxValueLabel`},outputs:{valueChange:`valueChange`},features:[gy],decls:4,vars:11,consts:[[`range`,``],[`mode`,`md`,1,`always-show-knob-pin`,3,`ionInput`,`dualKnobs`,`pin`,`pinFormatter`,`ticks`,`snaps`,`min`,`max`,`step`,`value`],[`slot`,`start`],[`slot`,`end`]],template:function(t,i){t&1&&(Ri(0,`ion-range`,1,0),Dh(`ionInput`,function(_){return i.ionValueChanged(_.detail.value)}),UD(2,w,2,1,`ion-label`,2),UD(3,L,2,1,`ion-label`,3),sl()),t&2&&(fh(`dualKnobs`,i.config.range)(`pin`,!0)(`pinFormatter`,i.valueFormatter)(`ticks`,!0)(`snaps`,!0)(`min`,0)(`max`,i.config.values.length-1)(`step`,1)(`value`,i.ionValue),EE(2),WD(i.minValueLabel!==null?2:-1),EE(),WD(i.maxValueLabel!==null?3:-1))},dependencies:[H4,lI],encapsulation:2,changeDetection:1})}}return n})();export{k as t};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.