@limetech/lime-elements 35.0.0-next.2 → 35.0.0-next.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/lime-elements.cjs.js +1 -1
- package/dist/cjs/limel-input-field.cjs.entry.js +1 -1
- package/dist/cjs/limel-select.cjs.entry.js +1 -1
- package/dist/cjs/limel-slider.cjs.entry.js +1 -1
- package/dist/cjs/limel-table.cjs.entry.js +308 -6
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/components/input-field/input-field.css +14 -0
- package/dist/collection/components/select/select.css +6 -3
- package/dist/collection/components/slider/slider.css +5 -0
- package/dist/collection/components/table/columns.js +1 -1
- package/dist/collection/components/table/selection.js +111 -0
- package/dist/collection/components/table/table-selection.js +125 -0
- package/dist/collection/components/table/table.css +115 -32
- package/dist/collection/components/table/table.js +136 -3
- package/dist/collection/style/internal/shared_input-select-picker.scss +1 -0
- package/dist/collection/style/internal/z-index.scss +2 -1
- package/dist/esm/{component-2eb4e07b.js → component-834d85a1.js} +1 -1
- package/dist/esm/lime-elements.js +1 -1
- package/dist/esm/limel-checkbox.entry.js +1 -1
- package/dist/esm/limel-input-field.entry.js +1 -1
- package/dist/esm/limel-linear-progress.entry.js +1 -1
- package/dist/esm/limel-list_3.entry.js +2 -2
- package/dist/esm/limel-menu-list.entry.js +2 -2
- package/dist/esm/limel-select.entry.js +1 -1
- package/dist/esm/limel-slider.entry.js +2 -2
- package/dist/esm/limel-table.entry.js +308 -6
- package/dist/esm/loader.js +1 -1
- package/dist/esm/{util-71a23335.js → util-f1bde91c.js} +1 -1
- package/dist/lime-elements/lime-elements.esm.js +1 -1
- package/dist/lime-elements/{p-6215e45e.entry.js → p-29f054cc.entry.js} +1 -1
- package/dist/lime-elements/{p-bc0dcf01.entry.js → p-8707d77b.entry.js} +1 -1
- package/dist/lime-elements/{p-31299106.js → p-90c6fa15.js} +1 -1
- package/dist/lime-elements/{p-6cfb45a1.entry.js → p-98d50f52.entry.js} +1 -1
- package/dist/lime-elements/{p-152a6d5f.js → p-9faad6eb.js} +1 -1
- package/dist/lime-elements/{p-96e44a1e.entry.js → p-a93f4190.entry.js} +1 -1
- package/dist/lime-elements/{p-a77cbb08.entry.js → p-ca664c9f.entry.js} +1 -1
- package/dist/lime-elements/{p-13f0e4f4.entry.js → p-cd619c16.entry.js} +1 -1
- package/dist/lime-elements/{p-b5faa40d.entry.js → p-df8faeb4.entry.js} +2 -2
- package/dist/lime-elements/{p-64549ba6.entry.js → p-e275f502.entry.js} +2 -2
- package/dist/lime-elements/style/internal/shared_input-select-picker.scss +1 -0
- package/dist/lime-elements/style/internal/z-index.scss +2 -1
- package/dist/types/components/table/columns.d.ts +7 -0
- package/dist/types/components/table/selection.d.ts +79 -0
- package/dist/types/components/table/table-selection.d.ts +57 -0
- package/dist/types/components/table/table.d.ts +31 -6
- package/dist/types/components.d.ts +24 -0
- package/package.json +1 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{r as t,c as i,h as e,g as r}from"./p-92146da6.js";import{M as s,a as n}from"./p-076bd4dc.js";import{M as o,a,b as d}from"./p-902347b9.js";import{m as c}from"./p-dcc97cc2.js";import{A as l}from"./p-48105d44.js";import{
|
|
1
|
+
import{r as t,c as i,h as e,g as r}from"./p-92146da6.js";import{M as s,a as n}from"./p-076bd4dc.js";import{M as o,a,b as d}from"./p-902347b9.js";import{m as c}from"./p-dcc97cc2.js";import{A as l}from"./p-48105d44.js";import{g as m}from"./p-9faad6eb.js";
|
|
2
2
|
/*! *****************************************************************************
|
|
3
3
|
Copyright (c) Microsoft Corporation.
|
|
4
4
|
|
|
@@ -56,4 +56,4 @@ PERFORMANCE OF THIS SOFTWARE.
|
|
|
56
56
|
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
57
57
|
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
58
58
|
* THE SOFTWARE.
|
|
59
|
-
*/(this.step),this.valueBeforeDownEvent=r,this.valueStartBeforeDownEvent=s,this.mousedownOrTouchstartListener=this.handleMousedownOrTouchstart.bind(this),this.moveListener=this.handleMove.bind(this),this.pointerdownListener=this.handlePointerdown.bind(this),this.pointerupListener=this.handlePointerup.bind(this),this.thumbMouseenterListener=this.handleThumbMouseenter.bind(this),this.thumbMouseleaveListener=this.handleThumbMouseleave.bind(this),this.inputStartChangeListener=function(){t.handleInputChange(f.START)},this.inputEndChangeListener=function(){t.handleInputChange(f.END)},this.inputStartFocusListener=function(){t.handleInputFocus(f.START)},this.inputEndFocusListener=function(){t.handleInputFocus(f.END)},this.inputStartBlurListener=function(){t.handleInputBlur(f.START)},this.inputEndBlurListener=function(){t.handleInputBlur(f.END)},this.resizeListener=this.handleResize.bind(this),this.registerEventHandlers()},i.prototype.destroy=function(){this.deregisterEventHandlers()},i.prototype.getMin=function(){return this.min},i.prototype.getMax=function(){return this.max},i.prototype.getValue=function(){return this.value},i.prototype.setValue=function(t){if(this.isRange&&t<this.valueStart)throw new Error("end thumb value ("+t+") must be >= start thumb value ("+this.valueStart+")");this.updateValue(t,f.END)},i.prototype.getValueStart=function(){if(!this.isRange)throw new Error("`valueStart` is only applicable for range sliders.");return this.valueStart},i.prototype.setValueStart=function(t){if(!this.isRange)throw new Error("`valueStart` is only applicable for range sliders.");if(this.isRange&&t>this.value)throw new Error("start thumb value ("+t+") must be <= end thumb value ("+this.value+")");this.updateValue(t,f.START)},i.prototype.getStep=function(){return this.step},i.prototype.getDisabled=function(){return this.isDisabled},i.prototype.setDisabled=function(t){this.isDisabled=t,t?(this.adapter.addClass("mdc-slider--disabled"),this.isRange&&this.adapter.setInputAttribute("disabled","",f.START),this.adapter.setInputAttribute("disabled","",f.END)):(this.adapter.removeClass("mdc-slider--disabled"),this.isRange&&this.adapter.removeInputAttribute("disabled",f.START),this.adapter.removeInputAttribute("disabled",f.END))},i.prototype.getIsRange=function(){return this.isRange},i.prototype.layout=function(t){var i=(void 0===t?{}:t).skipUpdateUI;this.rect=this.adapter.getBoundingClientRect(),this.isRange&&(this.startThumbKnobWidth=this.adapter.getThumbKnobWidth(f.START),this.endThumbKnobWidth=this.adapter.getThumbKnobWidth(f.END)),i||this.updateUI()},i.prototype.handleResize=function(){this.layout()},i.prototype.handleDown=function(t){if(!this.isDisabled){this.valueStartBeforeDownEvent=this.valueStart,this.valueBeforeDownEvent=this.value;var i=null!=t.clientX?t.clientX:t.targetTouches[0].clientX;this.downEventClientX=i;var e=this.mapClientXOnSliderScale(i);this.thumb=this.getThumbFromDownEvent(i,e),null!==this.thumb&&(this.handleDragStart(t,e,this.thumb),this.updateValue(e,this.thumb,{emitInputEvent:!0}))}},i.prototype.handleMove=function(t){if(!this.isDisabled){t.preventDefault();var i=null!=t.clientX?t.clientX:t.targetTouches[0].clientX,e=null!=this.thumb;if(this.thumb=this.getThumbFromMoveEvent(i),null!==this.thumb){var r=this.mapClientXOnSliderScale(i);e||(this.handleDragStart(t,r,this.thumb),this.adapter.emitDragStartEvent(r,this.thumb)),this.updateValue(r,this.thumb,{emitInputEvent:!0})}}},i.prototype.handleUp=function(){if(!this.isDisabled&&null!==this.thumb){var t=this.thumb===f.START?this.valueStart:this.value;(this.thumb===f.START?this.valueStartBeforeDownEvent:this.valueBeforeDownEvent)!==t&&this.adapter.emitChangeEvent(t,this.thumb),this.adapter.emitDragEndEvent(t,this.thumb),this.thumb=null}},i.prototype.handleThumbMouseenter=function(){this.isDiscrete&&this.isRange&&(this.adapter.addThumbClass("mdc-slider__thumb--with-indicator",f.START),this.adapter.addThumbClass("mdc-slider__thumb--with-indicator",f.END))},i.prototype.handleThumbMouseleave=function(){this.isDiscrete&&this.isRange&&(this.adapter.isInputFocused(f.START)||this.adapter.isInputFocused(f.END)||(this.adapter.removeThumbClass("mdc-slider__thumb--with-indicator",f.START),this.adapter.removeThumbClass("mdc-slider__thumb--with-indicator",f.END)))},i.prototype.handleMousedownOrTouchstart=function(t){var i=this,e="mousedown"===t.type?"mousemove":"touchmove";this.adapter.registerBodyEventHandler(e,this.moveListener);var r=function(){i.handleUp(),i.adapter.deregisterBodyEventHandler(e,i.moveListener),i.adapter.deregisterEventHandler("mouseup",r),i.adapter.deregisterEventHandler("touchend",r)};this.adapter.registerBodyEventHandler("mouseup",r),this.adapter.registerBodyEventHandler("touchend",r),this.handleDown(t)},i.prototype.handlePointerdown=function(t){this.adapter.setPointerCapture(t.pointerId),this.adapter.registerEventHandler("pointermove",this.moveListener),this.handleDown(t)},i.prototype.handleInputChange=function(t){var i=Number(this.adapter.getInputValue(t));t===f.START?this.setValueStart(i):this.setValue(i),this.adapter.emitChangeEvent(t===f.START?this.valueStart:this.value,t),this.adapter.emitInputEvent(t===f.START?this.valueStart:this.value,t)},i.prototype.handleInputFocus=function(t){this.adapter.addThumbClass("mdc-slider__thumb--focused",t),this.isDiscrete&&(this.adapter.addThumbClass("mdc-slider__thumb--with-indicator",t),this.isRange&&this.adapter.addThumbClass("mdc-slider__thumb--with-indicator",t===f.START?f.END:f.START))},i.prototype.handleInputBlur=function(t){this.adapter.removeThumbClass("mdc-slider__thumb--focused",t),this.isDiscrete&&(this.adapter.removeThumbClass("mdc-slider__thumb--with-indicator",t),this.isRange&&this.adapter.removeThumbClass("mdc-slider__thumb--with-indicator",t===f.START?f.END:f.START))},i.prototype.handleDragStart=function(t,i,e){this.adapter.focusInput(e),t.preventDefault(),this.adapter.emitDragStartEvent(i,e)},i.prototype.getThumbFromDownEvent=function(t,i){if(!this.isRange)return f.END;var e=this.adapter.getThumbBoundingClientRect(f.START),r=this.adapter.getThumbBoundingClientRect(f.END),s=t>=e.left&&t<=e.right,n=t>=r.left&&t<=r.right;return s&&n?null:s?f.START:n?f.END:i<this.valueStart?f.START:i>this.value?f.END:i-this.valueStart<=this.value-i?f.START:f.END},i.prototype.getThumbFromMoveEvent=function(t){if(null!==this.thumb)return this.thumb;if(null===this.downEventClientX)throw new Error("`downEventClientX` is null after move event.");return Math.abs(this.downEventClientX-t)<5?this.thumb:t<this.downEventClientX?this.adapter.isRTL()?f.END:f.START:this.adapter.isRTL()?f.START:f.END},i.prototype.updateUI=function(t){this.updateThumbAndInputAttributes(t),this.updateThumbAndTrackUI(t),this.updateValueIndicatorUI(t),this.updateTickMarksUI()},i.prototype.updateThumbAndInputAttributes=function(t){if(t){var i=this.isRange&&t===f.START?this.valueStart:this.value,e=String(i);this.adapter.setInputAttribute("value",e,t),this.isRange&&t===f.START?this.adapter.setInputAttribute("min",e,f.END):this.isRange&&t===f.END&&this.adapter.setInputAttribute("max",e,f.START),this.adapter.getInputValue(t)!==e&&this.adapter.setInputValue(e,t);var r=this.adapter.getValueToAriaValueTextFn();r&&this.adapter.setInputAttribute("aria-valuetext",r(i),t)}},i.prototype.updateValueIndicatorUI=function(t){this.isDiscrete&&(this.adapter.setValueIndicatorText(this.isRange&&t===f.START?this.valueStart:this.value,t===f.START?f.START:f.END),!t&&this.isRange&&this.adapter.setValueIndicatorText(this.valueStart,f.START))},i.prototype.updateTickMarksUI=function(){if(this.isDiscrete&&this.hasTickMarks){var t=(this.value-this.valueStart)/this.step+1,i=(this.max-this.value)/this.step,e=Array.from({length:(this.valueStart-this.min)/this.step}).fill(p.INACTIVE),r=Array.from({length:t}).fill(p.ACTIVE),s=Array.from({length:i}).fill(p.INACTIVE);this.adapter.updateTickMarks(e.concat(r).concat(s))}},i.prototype.mapClientXOnSliderScale=function(t){var i=(t-this.rect.left)/this.rect.width;this.adapter.isRTL()&&(i=1-i);var e=this.min+i*(this.max-this.min);return e===this.max||e===this.min?e:Number(this.quantize(e).toFixed(this.numDecimalPlaces))},i.prototype.quantize=function(t){var i=Math.round((t-this.min)/this.step);return this.min+i*this.step},i.prototype.updateValue=function(t,i,e){var r=(void 0===e?{}:e).emitInputEvent;if(t=this.clampValue(t,i),this.isRange&&i===f.START){if(this.valueStart===t)return;this.valueStart=t}else{if(this.value===t)return;this.value=t}this.updateUI(i),r&&this.adapter.emitInputEvent(i===f.START?this.valueStart:this.value,i)},i.prototype.clampValue=function(t,i){return t=Math.min(Math.max(t,this.min),this.max),this.isRange&&i===f.START&&t>this.value?this.value:this.isRange&&i===f.END&&t<this.valueStart?this.valueStart:t},i.prototype.updateThumbAndTrackUI=function(t){var i=this,e=this.max,r=this.min,s=(this.value-this.valueStart)/(e-r),n=s*this.rect.width,o=this.adapter.isRTL(),a=g?m(window,"transform"):"transform";if(this.isRange){var d=this.adapter.isRTL()?(e-this.value)/(e-r)*this.rect.width:(this.valueStart-r)/(e-r)*this.rect.width,c=d+n;this.animFrame.request(b.SLIDER_UPDATE,(function(){!o&&t===f.START||o&&t!==f.START?(i.adapter.setTrackActiveStyleProperty("transform-origin","right"),i.adapter.setTrackActiveStyleProperty("left","unset"),i.adapter.setTrackActiveStyleProperty("right",i.rect.width-c+"px")):(i.adapter.setTrackActiveStyleProperty("transform-origin","left"),i.adapter.setTrackActiveStyleProperty("right","unset"),i.adapter.setTrackActiveStyleProperty("left",d+"px")),i.adapter.setTrackActiveStyleProperty(a,"scaleX("+s+")");var e=o?c:d,r=i.adapter.isRTL()?d:c;t!==f.START&&t&&i.initialStylesRemoved||i.adapter.setThumbStyleProperty(a,"translateX("+e+"px)",f.START),t!==f.END&&t&&i.initialStylesRemoved||i.adapter.setThumbStyleProperty(a,"translateX("+r+"px)",f.END),i.removeInitialStyles(o),i.updateOverlappingThumbsUI(e,r,t)}))}else this.animFrame.request(b.SLIDER_UPDATE,(function(){i.adapter.setThumbStyleProperty(a,"translateX("+(o?i.rect.width-n:n)+"px)",f.END),i.adapter.setTrackActiveStyleProperty(a,"scaleX("+s+")"),i.removeInitialStyles(o)}))},i.prototype.removeInitialStyles=function(t){if(!this.initialStylesRemoved){var i=t?"right":"left";this.adapter.removeThumbStyleProperty(i,f.END),this.isRange&&this.adapter.removeThumbStyleProperty(i,f.START),this.initialStylesRemoved=!0,this.resetTrackAndThumbAnimation()}},i.prototype.resetTrackAndThumbAnimation=function(){var t=this;if(this.isDiscrete){var i=g?m(window,"transition"):"transition",e="all 0s ease 0s";this.adapter.setThumbStyleProperty(i,e,f.END),this.isRange&&this.adapter.setThumbStyleProperty(i,e,f.START),this.adapter.setTrackActiveStyleProperty(i,e),requestAnimationFrame((function(){t.adapter.removeThumbStyleProperty(i,f.END),t.adapter.removeTrackActiveStyleProperty(i),t.isRange&&t.adapter.removeThumbStyleProperty(i,f.START)}))}},i.prototype.updateOverlappingThumbsUI=function(t,i,e){(this.adapter.isRTL()?i+this.endThumbKnobWidth/2>=t-this.startThumbKnobWidth/2:t+this.startThumbKnobWidth/2>=i-this.endThumbKnobWidth/2)?(this.adapter.addThumbClass("mdc-slider__thumb--top",e||f.END),this.adapter.removeThumbClass("mdc-slider__thumb--top",e===f.START?f.END:f.START)):(this.adapter.removeThumbClass("mdc-slider__thumb--top",f.START),this.adapter.removeThumbClass("mdc-slider__thumb--top",f.END))},i.prototype.convertAttributeValueToNumber=function(t,i){if(null===t)throw new Error("MDCSliderFoundation: `"+i+"` must be non-null.");var e=Number(t);if(isNaN(e))throw new Error("MDCSliderFoundation: `"+i+"` value is `"+t+"`, but must be a number.");return e},i.prototype.validateProperties=function(t){var i=t.min,e=t.max,r=t.value,s=t.valueStart,n=t.step;if(i>=e)throw new Error("MDCSliderFoundation: min must be strictly less than max. Current: [min: "+i+", max: "+e+"]");if(n<=0)throw new Error("MDCSliderFoundation: step must be a positive number. Current step: "+this.step);if(this.isRange){if(r<i||r>e||s<i||s>e)throw new Error("MDCSliderFoundation: values must be in [min, max] range. Current values: [start value: "+s+", end value: "+r+"]");if(s>r)throw new Error("MDCSliderFoundation: start value must be <= end value. Current values: [start value: "+s+", end value: "+r+"]");var o=(r-i)/n;if((s-i)/n%1!=0||o%1!=0)throw new Error("MDCSliderFoundation: Slider values must be valid based on the step value. Current values: [start value: "+s+", end value: "+r+"]")}else{if(r<i||r>e)throw new Error("MDCSliderFoundation: value must be in [min, max] range. Current value: "+r);if((o=(r-i)/n)%1!=0)throw new Error("MDCSliderFoundation: Slider value must be valid based on the step value. Current value: "+r)}},i.prototype.registerEventHandlers=function(){this.adapter.registerWindowEventHandler("resize",this.resizeListener),i.SUPPORTS_POINTER_EVENTS?(this.adapter.registerEventHandler("pointerdown",this.pointerdownListener),this.adapter.registerEventHandler("pointerup",this.pointerupListener)):(this.adapter.registerEventHandler("mousedown",this.mousedownOrTouchstartListener),this.adapter.registerEventHandler("touchstart",this.mousedownOrTouchstartListener)),this.isRange&&(this.adapter.registerThumbEventHandler(f.START,"mouseenter",this.thumbMouseenterListener),this.adapter.registerThumbEventHandler(f.START,"mouseleave",this.thumbMouseleaveListener),this.adapter.registerInputEventHandler(f.START,"change",this.inputStartChangeListener),this.adapter.registerInputEventHandler(f.START,"focus",this.inputStartFocusListener),this.adapter.registerInputEventHandler(f.START,"blur",this.inputStartBlurListener)),this.adapter.registerThumbEventHandler(f.END,"mouseenter",this.thumbMouseenterListener),this.adapter.registerThumbEventHandler(f.END,"mouseleave",this.thumbMouseleaveListener),this.adapter.registerInputEventHandler(f.END,"change",this.inputEndChangeListener),this.adapter.registerInputEventHandler(f.END,"focus",this.inputEndFocusListener),this.adapter.registerInputEventHandler(f.END,"blur",this.inputEndBlurListener)},i.prototype.deregisterEventHandlers=function(){this.adapter.deregisterWindowEventHandler("resize",this.resizeListener),i.SUPPORTS_POINTER_EVENTS?(this.adapter.deregisterEventHandler("pointerdown",this.pointerdownListener),this.adapter.deregisterEventHandler("pointerup",this.pointerupListener)):(this.adapter.deregisterEventHandler("mousedown",this.mousedownOrTouchstartListener),this.adapter.deregisterEventHandler("touchstart",this.mousedownOrTouchstartListener)),this.isRange&&(this.adapter.deregisterThumbEventHandler(f.START,"mouseenter",this.thumbMouseenterListener),this.adapter.deregisterThumbEventHandler(f.START,"mouseleave",this.thumbMouseleaveListener),this.adapter.deregisterInputEventHandler(f.START,"change",this.inputStartChangeListener),this.adapter.deregisterInputEventHandler(f.START,"focus",this.inputStartFocusListener),this.adapter.deregisterInputEventHandler(f.START,"blur",this.inputStartBlurListener)),this.adapter.deregisterThumbEventHandler(f.END,"mouseenter",this.thumbMouseenterListener),this.adapter.deregisterThumbEventHandler(f.END,"mouseleave",this.thumbMouseleaveListener),this.adapter.deregisterInputEventHandler(f.END,"change",this.inputEndChangeListener),this.adapter.deregisterInputEventHandler(f.END,"focus",this.inputEndFocusListener),this.adapter.deregisterInputEventHandler(f.END,"blur",this.inputEndBlurListener)},i.prototype.handlePointerup=function(){this.handleUp(),this.adapter.deregisterEventHandler("pointermove",this.moveListener)},i.SUPPORTS_POINTER_EVENTS=g&&Boolean(window.PointerEvent)&&!(["iPad Simulator","iPhone Simulator","iPod Simulator","iPad","iPhone","iPod"].includes(navigator.platform)||navigator.userAgent.includes("Mac")&&"ontouchend"in document),i}(s),y=function(t){function i(){var i=null!==t&&t.apply(this,arguments)||this;return i.skipInitialUIUpdate=!1,i.valueToAriaValueTextFn=null,i}return u(i,t),i.attachTo=function(t,e){return void 0===e&&(e={}),new i(t,void 0,e)},i.prototype.getDefaultFoundation=function(){var t=this;return new _({hasClass:function(i){return t.root.classList.contains(i)},addClass:function(i){t.root.classList.add(i)},removeClass:function(i){t.root.classList.remove(i)},addThumbClass:function(i,e){t.getThumbEl(e).classList.add(i)},removeThumbClass:function(i,e){t.getThumbEl(e).classList.remove(i)},getAttribute:function(i){return t.root.getAttribute(i)},getInputValue:function(i){return t.getInput(i).value},setInputValue:function(i,e){t.getInput(e).value=i},getInputAttribute:function(i,e){return t.getInput(e).getAttribute(i)},setInputAttribute:function(i,e,r){t.getInput(r).setAttribute(i,e)},removeInputAttribute:function(i,e){t.getInput(e).removeAttribute(i)},focusInput:function(i){t.getInput(i).focus()},isInputFocused:function(i){return t.getInput(i)===document.activeElement},getThumbKnobWidth:function(i){return t.getThumbEl(i).querySelector(".mdc-slider__thumb-knob").getBoundingClientRect().width},getThumbBoundingClientRect:function(i){return t.getThumbEl(i).getBoundingClientRect()},getBoundingClientRect:function(){return t.root.getBoundingClientRect()},isRTL:function(){return"rtl"===getComputedStyle(t.root).direction},setThumbStyleProperty:function(i,e,r){t.getThumbEl(r).style.setProperty(i,e)},removeThumbStyleProperty:function(i,e){t.getThumbEl(e).style.removeProperty(i)},setTrackActiveStyleProperty:function(i,e){t.trackActive.style.setProperty(i,e)},removeTrackActiveStyleProperty:function(i){t.trackActive.style.removeProperty(i)},setValueIndicatorText:function(i,e){t.getThumbEl(e).querySelector(".mdc-slider__value-indicator-text").textContent=String(i)},getValueToAriaValueTextFn:function(){return t.valueToAriaValueTextFn},updateTickMarks:function(i){var e=t.root.querySelector(".mdc-slider__tick-marks");e||((e=document.createElement("div")).classList.add("mdc-slider__tick-marks"),t.root.querySelector(".mdc-slider__track").appendChild(e)),i.length!==e.children.length?(e.innerHTML="",t.addTickMarks(e,i)):t.updateTickMarks(e,i)},setPointerCapture:function(i){t.root.setPointerCapture(i)},emitChangeEvent:function(i,e){t.emit("MDCSlider:change",{value:i,thumb:e})},emitInputEvent:function(i,e){t.emit("MDCSlider:input",{value:i,thumb:e})},emitDragStartEvent:function(i,e){t.getRipple(e).activate()},emitDragEndEvent:function(i,e){t.getRipple(e).deactivate()},registerEventHandler:function(i,e){t.listen(i,e)},deregisterEventHandler:function(i,e){t.unlisten(i,e)},registerThumbEventHandler:function(i,e,r){t.getThumbEl(i).addEventListener(e,r)},deregisterThumbEventHandler:function(i,e,r){t.getThumbEl(i).removeEventListener(e,r)},registerInputEventHandler:function(i,e,r){t.getInput(i).addEventListener(e,r)},deregisterInputEventHandler:function(i,e,r){t.getInput(i).removeEventListener(e,r)},registerBodyEventHandler:function(t,i){document.body.addEventListener(t,i)},deregisterBodyEventHandler:function(t,i){document.body.removeEventListener(t,i)},registerWindowEventHandler:function(t,i){window.addEventListener(t,i)},deregisterWindowEventHandler:function(t,i){window.removeEventListener(t,i)}})},i.prototype.initialize=function(t){var i=(void 0===t?{}:t).skipInitialUIUpdate;this.inputs=[].slice.call(this.root.querySelectorAll(".mdc-slider__input")),this.thumbs=[].slice.call(this.root.querySelectorAll(".mdc-slider__thumb")),this.trackActive=this.root.querySelector(".mdc-slider__track--active_fill"),this.ripples=this.createRipples(),i&&(this.skipInitialUIUpdate=!0)},i.prototype.initialSyncWithDOM=function(){this.foundation.layout({skipUpdateUI:this.skipInitialUIUpdate})},i.prototype.layout=function(){this.foundation.layout()},i.prototype.getValueStart=function(){return this.foundation.getValueStart()},i.prototype.setValueStart=function(t){this.foundation.setValueStart(t)},i.prototype.getValue=function(){return this.foundation.getValue()},i.prototype.setValue=function(t){this.foundation.setValue(t)},i.prototype.getDisabled=function(){return this.foundation.getDisabled()},i.prototype.setDisabled=function(t){this.foundation.setDisabled(t)},i.prototype.setValueToAriaValueTextFn=function(t){this.valueToAriaValueTextFn=t},i.prototype.getThumbEl=function(t){return t===f.END?this.thumbs[this.thumbs.length-1]:this.thumbs[0]},i.prototype.getInput=function(t){return t===f.END?this.inputs[this.inputs.length-1]:this.inputs[0]},i.prototype.getRipple=function(t){return t===f.END?this.ripples[this.ripples.length-1]:this.ripples[0]},i.prototype.addTickMarks=function(t,i){for(var e=document.createDocumentFragment(),r=0;r<i.length;r++){var s=document.createElement("div");s.classList.add(i[r]===p.ACTIVE?"mdc-slider__tick-mark--active":"mdc-slider__tick-mark--inactive"),e.appendChild(s)}t.appendChild(e)},i.prototype.updateTickMarks=function(t,i){for(var e=Array.from(t.children),r=0;r<e.length;r++)i[r]===p.ACTIVE?(e[r].classList.add("mdc-slider__tick-mark--active"),e[r].classList.remove("mdc-slider__tick-mark--inactive")):(e[r].classList.add("mdc-slider__tick-mark--inactive"),e[r].classList.remove("mdc-slider__tick-mark--active"))},i.prototype.createRipples=function(){for(var t=[],i=[].slice.call(this.root.querySelectorAll(".mdc-slider__thumb")),e=function(e){var s=i[e],n=r.inputs[e],l=v(v({},o.createAdapter(r)),{addClass:function(t){s.classList.add(t)},computeBoundingRect:function(){return s.getBoundingClientRect()},deregisterInteractionHandler:function(t,i){n.removeEventListener(t,i)},isSurfaceActive:function(){return c(n,":active")},isUnbounded:function(){return!0},registerInteractionHandler:function(t,i){n.addEventListener(t,i,a())},removeClass:function(t){s.classList.remove(t)},updateCssVariable:function(t,i){s.style.setProperty(t,i)}}),m=new o(s,new d(l));m.unbounded=!0,t.push(m)},r=this,s=0;s<i.length;s++)e(s);return t},i}(n);let k=class{constructor(e){t(this,e),this.change=i(this,"change",7),this.disabled=!1,this.readonly=!1,this.factor=1,this.unit="",this.valuemax=100,this.valuemin=0,this.changeHandler=t=>{let i=t.detail.value;const e=this.multiplyByFactor(this.step);this.isMultipleOfStep(i,e)||(i=this.roundToStep(i,e)),this.change.emit(i/this.factor)},this.inputHandler=this.inputHandler.bind(this),this.getContainerClassList=this.getContainerClassList.bind(this)}connectedCallback(){this.initialize()}componentDidLoad(){this.initialize()}initialize(){const t=this.getInputElement();if(!t)return;const i=this.getValue();t.setAttribute("value",`${this.multiplyByFactor(i)}`);const e=i<=this.valuemax;if(!(i>=this.valuemin)){const e=this.multiplyByFactor(i);t.setAttribute("min",`${e}`)}if(!e){const e=this.multiplyByFactor(i);t.setAttribute("max",`${e}`)}this.isMultipleOfStep(i,this.step)||t.removeAttribute("step"),this.createMDCSlider()}componentWillLoad(){this.setPercentageClass(this.value)}disconnectedCallback(){this.destroyMDCSlider()}getContainerClassList(){return{slider:!0,"lime-slider--readonly":this.readonly,[this.percentageClass]:!0}}render(){const t={};return this.step&&(t.step=this.multiplyByFactor(this.step)),(this.disabled||this.readonly)&&(t.disabled=!0),e("div",{class:this.getContainerClassList()},e("label",{class:"slider__label mdc-floating-label mdc-floating-label--float-above"},this.label),e("div",{class:"slider__content"},e("div",{class:"slider__content-range-container"},e("span",{class:"slider__content-min-label"},this.multiplyByFactor(this.valuemin),this.unit),e("span",{class:"slider__content-max-label"},this.multiplyByFactor(this.valuemax),this.unit)),e("div",{class:{"mdc-slider":!0,"mdc-slider--discrete":!0,"mdc-slider--disabled":this.disabled||this.readonly}},e("input",Object.assign({class:"mdc-slider__input",type:"range",min:this.multiplyByFactor(this.valuemin),max:this.multiplyByFactor(this.valuemax),value:this.multiplyByFactor(this.value),name:"volume","aria-label":"Discrete slider demo"},t)),e("div",{class:"mdc-slider__track"},e("div",{class:"mdc-slider__track--inactive"}),e("div",{class:"mdc-slider__track--active"},e("div",{class:"mdc-slider__track--active_fill"}))),e("div",{class:"mdc-slider__thumb"},e("div",{class:"mdc-slider__value-indicator-container","aria-hidden":"true"},e("div",{class:"mdc-slider__value-indicator"},e("span",{class:"mdc-slider__value-indicator-text"},this.multiplyByFactor(this.value)))),e("div",{class:"mdc-slider__thumb-knob"})))),this.renderHelperLine())}renderHelperLine(){if(this.helperText)return e("div",{class:"mdc-slider-helper-line"},e("p",{class:"mdc-slider-helper-text"},this.helperText))}watchDisabled(){this.updateDisabledState()}watchReadonly(){this.updateDisabledState()}watchValue(){if(!this.mdcSlider)return;const t=this.multiplyByFactor(this.getValue());if(this.mdcSlider.setValue(t),this.isStepConfigured())return;const i=this.multiplyByFactor(this.step);this.isMultipleOfStep(t,i)&&this.reCreateSliderWithStep()}updateDisabledState(){this.mdcSlider&&this.mdcSlider.setDisabled(this.disabled||this.readonly)}multiplyByFactor(t){return Math.round(t*this.factor)}getValue(){let t=this.value;return isFinite(t)||(t=this.valuemin),t}inputHandler(t){this.setPercentageClass(t.detail.value/this.factor)}setPercentageClass(t){this.percentageClass=function(t){return 0===t?"percent-0":t<.1?"percent-0-10":t<.2?"percent-10-20":t<.3?"percent-20-30":t<.4?"percent-30-40":t<.5?"percent-40-50":t<.6?"percent-50-60":t<.7?"percent-60-70":t<.8?"percent-70-80":t<.9?"percent-80-90":"percent-90-100"}((t-this.valuemin)/(this.valuemax-this.valuemin))}isMultipleOfStep(t,i){return!i||t%i==0}roundToStep(t,i){return Math.round(t/i)*i}getRootElement(){return this.rootElement.shadowRoot.querySelector(".mdc-slider")}getInputElement(){const t=this.getRootElement();if(t)return t.querySelector("input")}isStepConfigured(){if(!this.step)return!0;const t=this.getInputElement();return!t||t.hasAttribute("step")}reCreateSliderWithStep(){const t=this.getInputElement(),i=`${this.multiplyByFactor(this.step)}`;t.setAttribute("step",i),this.destroyMDCSlider(),this.createMDCSlider()}createMDCSlider(){const t=this.getRootElement();this.mdcSlider=new y(t),this.mdcSlider.listen("MDCSlider:change",this.changeHandler),this.mdcSlider.listen("MDCSlider:input",this.inputHandler)}destroyMDCSlider(){this.mdcSlider.unlisten("MDCSlider:change",this.changeHandler),this.mdcSlider.unlisten("MDCSlider:input",this.inputHandler),this.mdcSlider.destroy(),this.mdcSlider=void 0}get rootElement(){return r(this)}static get watchers(){return{disabled:["watchDisabled"],readonly:["watchReadonly"],value:["watchValue"]}}};k.style=':host{--mdc-theme-primary:var(\n --lime-primary-color,\n rgb(var(--color-teal-default))\n );--mdc-theme-secondary:var(\n --lime-secondary-color,\n rgb(var(--contrast-1100))\n );--mdc-theme-on-primary:var(\n --lime-on-primary-color,\n rgb(var(--contrast-100))\n );--mdc-theme-on-secondary:var(\n --lime-on-secondary-color,\n rgb(var(--contrast-100))\n );--mdc-theme-text-disabled-on-background:var(\n --lime-text-disabled-on-background-color,\n rgba(var(--contrast-1700), 0.38)\n );--mdc-theme-text-primary-on-background:var(\n --lime-text-primary-on-background-color,\n rgba(var(--contrast-1700), 0.87)\n );--mdc-theme-text-secondary-on-background:var(\n --lime-text-secondary-on-background-color,\n rgba(var(--contrast-1700), 0.54)\n );--lime-error-text-color:rgb(var(--color-red-darker));--mdc-theme-surface:var(\n --lime-surface-background-color,\n rgb(var(--contrast-100))\n );--mdc-theme-on-surface:var(\n --lime-on-surface-color,\n var(--lime-text-primary-on-background-color)\n )}@keyframes mdc-ripple-fg-radius-in{from{animation-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transform:translate(var(--mdc-ripple-fg-translate-start, 0)) scale(1)}to{transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}}@keyframes mdc-ripple-fg-opacity-in{from{animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@keyframes mdc-ripple-fg-opacity-out{from{animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}.mdc-slider__thumb{--mdc-ripple-fg-size:0;--mdc-ripple-left:0;--mdc-ripple-top:0;--mdc-ripple-fg-scale:1;--mdc-ripple-fg-translate-end:0;--mdc-ripple-fg-translate-start:0;-webkit-tap-highlight-color:rgba(0, 0, 0, 0);will-change:transform, opacity}.mdc-slider__thumb::before,.mdc-slider__thumb::after{position:absolute;border-radius:50%;opacity:0;pointer-events:none;content:""}.mdc-slider__thumb::before{transition:opacity 15ms linear, background-color 15ms linear;z-index:1;z-index:var(--mdc-ripple-z-index, 1)}.mdc-slider__thumb::after{z-index:0;z-index:var(--mdc-ripple-z-index, 0)}.mdc-slider__thumb.mdc-ripple-upgraded::before{transform:scale(var(--mdc-ripple-fg-scale, 1))}.mdc-slider__thumb.mdc-ripple-upgraded::after{top:0;left:0;transform:scale(0);transform-origin:center center}.mdc-slider__thumb.mdc-ripple-upgraded--unbounded::after{top:var(--mdc-ripple-top, 0);left:var(--mdc-ripple-left, 0)}.mdc-slider__thumb.mdc-ripple-upgraded--foreground-activation::after{animation:mdc-ripple-fg-radius-in 225ms forwards, mdc-ripple-fg-opacity-in 75ms forwards}.mdc-slider__thumb.mdc-ripple-upgraded--foreground-deactivation::after{animation:mdc-ripple-fg-opacity-out 150ms;transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}.mdc-slider__thumb::before,.mdc-slider__thumb::after{top:calc(50% - 50%);left:calc(50% - 50%);width:100%;height:100%}.mdc-slider__thumb.mdc-ripple-upgraded::before,.mdc-slider__thumb.mdc-ripple-upgraded::after{top:var(--mdc-ripple-top, calc(50% - 50%));left:var(--mdc-ripple-left, calc(50% - 50%));width:var(--mdc-ripple-fg-size, 100%);height:var(--mdc-ripple-fg-size, 100%)}.mdc-slider__thumb.mdc-ripple-upgraded::after{width:var(--mdc-ripple-fg-size, 100%);height:var(--mdc-ripple-fg-size, 100%)}.mdc-slider__thumb::before,.mdc-slider__thumb::after{background-color:#26a69a;background-color:var(--mdc-ripple-color, var(--mdc-theme-primary, #26a69a))}.mdc-slider__thumb:hover::before,.mdc-slider__thumb.mdc-ripple-surface--hover::before{opacity:0.08;opacity:var(--mdc-ripple-hover-opacity, 0.08)}.mdc-slider__thumb.mdc-ripple-upgraded--background-focused::before,.mdc-slider__thumb:not(.mdc-ripple-upgraded):focus::before{transition-duration:75ms;opacity:0.24;opacity:var(--mdc-ripple-focus-opacity, 0.24)}.mdc-slider__thumb:not(.mdc-ripple-upgraded)::after{transition:opacity 150ms linear}.mdc-slider__thumb:not(.mdc-ripple-upgraded):active::after{transition-duration:75ms;opacity:0.24;opacity:var(--mdc-ripple-press-opacity, 0.24)}.mdc-slider__thumb.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.24)}.mdc-slider{cursor:pointer;height:48px;margin:0 24px;position:relative;touch-action:pan-y}.mdc-slider .mdc-slider__track{height:4px;position:absolute;top:50%;transform:translateY(-50%);width:100%}.mdc-slider .mdc-slider__track--active,.mdc-slider .mdc-slider__track--inactive{display:flex;height:100%;position:absolute;width:100%}.mdc-slider .mdc-slider__track--active{border-radius:3px;height:6px;overflow:hidden;top:-1px}.mdc-slider .mdc-slider__track--active_fill{border-top:6px solid;box-sizing:border-box;height:100%;width:100%;position:relative;-webkit-transform-origin:left;transform-origin:left}[dir=rtl] .mdc-slider .mdc-slider__track--active_fill,.mdc-slider .mdc-slider__track--active_fill[dir=rtl]{-webkit-transform-origin:right;transform-origin:right}.mdc-slider .mdc-slider__track--inactive{border-radius:2px;height:4px;left:0;top:0}.mdc-slider .mdc-slider__track--inactive::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid transparent;border-radius:inherit;content:"";pointer-events:none}.mdc-slider .mdc-slider__track--active_fill{border-color:#26a69a;border-color:var(--mdc-theme-primary, #26a69a)}.mdc-slider.mdc-slider--disabled .mdc-slider__track--active_fill{border-color:#000;border-color:var(--mdc-theme-on-surface, #000)}.mdc-slider .mdc-slider__track--inactive{background-color:#26a69a;background-color:var(--mdc-theme-primary, #26a69a);opacity:0.24}.mdc-slider.mdc-slider--disabled .mdc-slider__track--inactive{background-color:#000;background-color:var(--mdc-theme-on-surface, #000);opacity:0.24}.mdc-slider .mdc-slider__value-indicator-container{bottom:44px;left:50%;pointer-events:none;position:absolute;transform:translateX(-50%)}.mdc-slider .mdc-slider__value-indicator{transition:transform 100ms 0ms cubic-bezier(0.4, 0, 1, 1);align-items:center;border-radius:4px;display:flex;height:32px;padding:0 12px;transform:scale(0);transform-origin:bottom}.mdc-slider .mdc-slider__value-indicator::before{border-left:6px solid transparent;border-right:6px solid transparent;border-top:6px solid;bottom:-5px;content:"";height:0;left:50%;position:absolute;transform:translateX(-50%);width:0}.mdc-slider .mdc-slider__value-indicator::after{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid transparent;border-radius:inherit;content:"";pointer-events:none}.mdc-slider .mdc-slider__thumb--with-indicator .mdc-slider__value-indicator-container{pointer-events:auto}.mdc-slider .mdc-slider__thumb--with-indicator .mdc-slider__value-indicator{transition:transform 100ms 0ms cubic-bezier(0, 0, 0.2, 1);transform:scale(1)}@media (prefers-reduced-motion){.mdc-slider .mdc-slider__value-indicator,.mdc-slider .mdc-slider__thumb--with-indicator .mdc-slider__value-indicator{transition:none}}.mdc-slider .mdc-slider__value-indicator-text{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-subtitle2-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:0.8125rem;font-size:var(--mdc-typography-subtitle2-font-size, 0.8125rem);line-height:1.125rem;line-height:var(--mdc-typography-subtitle2-line-height, 1.125rem);font-weight:500;font-weight:var(--mdc-typography-subtitle2-font-weight, 500);letter-spacing:0.0071428571em;letter-spacing:var(--mdc-typography-subtitle2-letter-spacing, 0.0071428571em);text-decoration:inherit;text-decoration:var(--mdc-typography-subtitle2-text-decoration, inherit);text-transform:inherit;text-transform:var(--mdc-typography-subtitle2-text-transform, inherit)}.mdc-slider .mdc-slider__value-indicator{background-color:#000;opacity:0.6}.mdc-slider .mdc-slider__value-indicator::before{border-top-color:#000}.mdc-slider .mdc-slider__value-indicator{color:#fff;color:var(--mdc-theme-on-primary, #fff)}.mdc-slider .mdc-slider__thumb{display:flex;height:48px;left:-24px;outline:none;position:absolute;user-select:none;width:48px}.mdc-slider .mdc-slider__thumb--top{z-index:1}.mdc-slider .mdc-slider__thumb--top .mdc-slider__thumb-knob,.mdc-slider .mdc-slider__thumb--top.mdc-slider__thumb:hover .mdc-slider__thumb-knob,.mdc-slider .mdc-slider__thumb--top.mdc-slider__thumb--focused .mdc-slider__thumb-knob{border:1px solid;box-sizing:content-box;border-color:#fff}.mdc-slider .mdc-slider__thumb-knob{box-shadow:0px 2px 1px -1px rgba(0, 0, 0, 0.2), 0px 1px 1px 0px rgba(0, 0, 0, 0.14), 0px 1px 3px 0px rgba(0, 0, 0, 0.12);border:10px solid;border-radius:50%;box-sizing:border-box;height:20px;left:50%;position:absolute;top:50%;transform:translate(-50%, -50%);width:20px}.mdc-slider .mdc-slider__thumb-knob{background-color:#26a69a;background-color:var(--mdc-theme-primary, #26a69a);border-color:#26a69a;border-color:var(--mdc-theme-primary, #26a69a)}.mdc-slider.mdc-slider--disabled .mdc-slider__thumb-knob{background-color:#000;background-color:var(--mdc-theme-on-surface, #000);border-color:#000;border-color:var(--mdc-theme-on-surface, #000)}.mdc-slider .mdc-slider__thumb::before,.mdc-slider .mdc-slider__thumb::after{background-color:#26a69a;background-color:var(--mdc-ripple-color, var(--mdc-theme-primary, #26a69a))}.mdc-slider .mdc-slider__thumb:hover::before,.mdc-slider .mdc-slider__thumb.mdc-ripple-surface--hover::before{opacity:0.08;opacity:var(--mdc-ripple-hover-opacity, 0.08)}.mdc-slider .mdc-slider__thumb.mdc-ripple-upgraded--background-focused::before,.mdc-slider .mdc-slider__thumb:not(.mdc-ripple-upgraded):focus::before{transition-duration:75ms;opacity:0.24;opacity:var(--mdc-ripple-focus-opacity, 0.24)}.mdc-slider .mdc-slider__thumb:not(.mdc-ripple-upgraded)::after{transition:opacity 150ms linear}.mdc-slider .mdc-slider__thumb:not(.mdc-ripple-upgraded):active::after{transition-duration:75ms;opacity:0.24;opacity:var(--mdc-ripple-press-opacity, 0.24)}.mdc-slider .mdc-slider__thumb.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.24)}.mdc-slider .mdc-slider__tick-marks{align-items:center;box-sizing:border-box;display:flex;height:100%;justify-content:space-between;padding:0 1px;position:absolute;width:100%}.mdc-slider .mdc-slider__tick-mark--active,.mdc-slider .mdc-slider__tick-mark--inactive{border-radius:50%;height:2px;width:2px}.mdc-slider .mdc-slider__tick-mark--active{background-color:#fff;background-color:var(--mdc-theme-on-primary, #fff);opacity:0.6}.mdc-slider.mdc-slider--disabled .mdc-slider__tick-mark--active{background-color:#fff;background-color:var(--mdc-theme-on-primary, #fff);opacity:0.6}.mdc-slider .mdc-slider__tick-mark--inactive{background-color:#26a69a;background-color:var(--mdc-theme-primary, #26a69a);opacity:0.6}.mdc-slider.mdc-slider--disabled .mdc-slider__tick-mark--inactive{background-color:#000;background-color:var(--mdc-theme-on-surface, #000);opacity:0.6}.mdc-slider.mdc-slider--disabled{opacity:0.38;cursor:auto}.mdc-slider.mdc-slider--disabled .mdc-slider__thumb{pointer-events:none}.mdc-slider--discrete .mdc-slider__thumb,.mdc-slider--discrete .mdc-slider__track--active_fill{transition:transform 80ms ease}@media (prefers-reduced-motion){.mdc-slider--discrete .mdc-slider__thumb,.mdc-slider--discrete .mdc-slider__track--active_fill{transition:none}}.mdc-slider__input{cursor:pointer;left:0;margin:0;height:100%;opacity:0;pointer-events:none;position:absolute;top:0;width:100%}.mdc-floating-label{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-subtitle1-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:0.875rem;font-size:var(--mdc-typography-subtitle1-font-size, 0.875rem);font-weight:400;font-weight:var(--mdc-typography-subtitle1-font-weight, 400);letter-spacing:0.009375em;letter-spacing:var(--mdc-typography-subtitle1-letter-spacing, 0.009375em);text-decoration:inherit;text-decoration:var(--mdc-typography-subtitle1-text-decoration, inherit);text-transform:inherit;text-transform:var(--mdc-typography-subtitle1-text-transform, inherit);position:absolute;left:0;-webkit-transform-origin:left top;transform-origin:left top;line-height:1.15rem;text-align:left;text-overflow:ellipsis;white-space:nowrap;cursor:text;overflow:hidden;will-change:transform;transition:transform 150ms cubic-bezier(0.4, 0, 0.2, 1), color 150ms cubic-bezier(0.4, 0, 0.2, 1)}[dir=rtl] .mdc-floating-label,.mdc-floating-label[dir=rtl]{right:0;left:auto;-webkit-transform-origin:right top;transform-origin:right top;text-align:right}.mdc-floating-label--float-above{cursor:auto}.mdc-floating-label--required::after{margin-left:1px;margin-right:0px;content:"*"}[dir=rtl] .mdc-floating-label--required::after,.mdc-floating-label--required[dir=rtl]::after{margin-left:0;margin-right:1px}.mdc-floating-label--float-above{transform:translateY(-106%) scale(0.75)}.mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-standard 250ms 1}@keyframes mdc-floating-label-shake-float-above-standard{0%{transform:translateX(calc(0 - 0%)) translateY(-106%) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 0%)) translateY(-106%) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 0%)) translateY(-106%) scale(0.75)}100%{transform:translateX(calc(0 - 0%)) translateY(-106%) scale(0.75)}}.slider{position:relative}.slider__label{padding-left:1.25rem;top:0.5625rem}.slider__content{display:flex;flex-direction:column;margin-top:0.25rem}.slider__content-range-container{display:flex;order:2;justify-content:space-between;width:calc(100% - 1.5rem);margin:0 auto;margin-top:-1rem}.slider__content-min-label,.slider__content-max-label{transition:opacity 0.2s ease;opacity:0.7;font-size:0.75rem;top:1.25rem}.slider:hover .slider__content-min-label,.slider:hover .slider__content-max-label{opacity:1}.mdc-slider__track:before,.mdc-slider__track:after{content:"";display:inline-block;position:absolute;top:0;bottom:0;margin:auto;width:0.375rem;height:0.375rem;border-radius:50%;background-color:rgba(var(--contrast-700), 0.6)}.mdc-slider__track:before{left:-0.75rem}.mdc-slider__track:after{right:-0.75rem}.mdc-slider__track--active_fill,.mdc-slider__track--inactive,.mdc-slider__thumb-knob{transition:background-color 0.5s ease}:host(.displays-percentage-colors) .slider.lime-slider--readonly{--mdc-theme-on-surface:var(--mdc-theme-primary)}:host(.displays-percentage-colors) .slider.percent-0{--mdc-theme-primary:var(--color-percent--0)}:host(.displays-percentage-colors) .slider.percent-0-10{--mdc-theme-primary:var(--color-percent--0to10)}:host(.displays-percentage-colors) .slider.percent-10-20{--mdc-theme-primary:var(--color-percent--10to20)}:host(.displays-percentage-colors) .slider.percent-20-30{--mdc-theme-primary:var(--color-percent--20to30)}:host(.displays-percentage-colors) .slider.percent-30-40{--mdc-theme-primary:var(--color-percent--30to40)}:host(.displays-percentage-colors) .slider.percent-40-50{--mdc-theme-primary:var(--color-percent--40to50)}:host(.displays-percentage-colors) .slider.percent-50-60{--mdc-theme-primary:var(--color-percent--50to60)}:host(.displays-percentage-colors) .slider.percent-60-70{--mdc-theme-primary:var(--color-percent--60to70)}:host(.displays-percentage-colors) .slider.percent-70-80{--mdc-theme-primary:var(--color-percent--70to80)}:host(.displays-percentage-colors) .slider.percent-80-90{--mdc-theme-primary:var(--color-percent--80to90)}:host(.displays-percentage-colors) .slider.percent-90-100{--mdc-theme-primary:var(--color-percent--90to100)}:host(.displays-percentage-colors) .slider.percent-30-40 .mdc-slider__value-indicator-text,:host(.displays-percentage-colors) .slider.percent-40-50 .mdc-slider__value-indicator-text,:host(.displays-percentage-colors) .slider.percent-70-80 .mdc-slider__value-indicator-text{color:rgb(var(--color-gray-darker))}:host(.displays-percentage-colors) .slider.percent-30-40 .mdc-slider--disabled .mdc-slider__value-indicator-text,:host(.displays-percentage-colors) .slider.percent-40-50 .mdc-slider--disabled .mdc-slider__value-indicator-text,:host(.displays-percentage-colors) .slider.percent-70-80 .mdc-slider--disabled .mdc-slider__value-indicator-text{color:rgb(var(--contrast-100))}:host(.displays-percentage-colors) .slider.percent-50-60 .mdc-slider__value-indicator-text,:host(.displays-percentage-colors) .slider.percent-60-70 .mdc-slider__value-indicator-text{color:rgb(var(--color-gray-dark))}:host(.displays-percentage-colors) .slider.percent-50-60 .mdc-slider--disabled .mdc-slider__value-indicator-text,:host(.displays-percentage-colors) .slider.percent-60-70 .mdc-slider--disabled .mdc-slider__value-indicator-text{color:rgb(var(--contrast-100))}:host{--mdc-theme-primary:var(\n --lime-primary-color,\n rgb(var(--color-teal-default))\n );--mdc-theme-secondary:var(\n --lime-secondary-color,\n rgb(var(--contrast-1100))\n );--mdc-theme-on-primary:var(\n --lime-on-primary-color,\n rgb(var(--contrast-100))\n );--mdc-theme-on-secondary:var(\n --lime-on-secondary-color,\n rgb(var(--contrast-100))\n );--mdc-theme-text-disabled-on-background:var(\n --lime-text-disabled-on-background-color,\n rgba(var(--contrast-1700), 0.38)\n );--mdc-theme-text-primary-on-background:var(\n --lime-text-primary-on-background-color,\n rgba(var(--contrast-1700), 0.87)\n );--mdc-theme-text-secondary-on-background:var(\n --lime-text-secondary-on-background-color,\n rgba(var(--contrast-1700), 0.54)\n );--lime-error-text-color:rgb(var(--color-red-darker));--mdc-theme-surface:var(\n --lime-surface-background-color,\n rgb(var(--contrast-100))\n );--mdc-theme-on-surface:var(\n --lime-on-surface-color,\n var(--lime-text-primary-on-background-color)\n )}.lime-slider--readonly .mdc-slider.mdc-slider--disabled{opacity:1}.lime-slider--readonly .mdc-slider.mdc-slider--disabled .mdc-slider__track,.lime-slider--readonly .mdc-slider.mdc-slider--disabled .mdc-slider__track--active,.lime-slider--readonly .mdc-slider.mdc-slider--disabled .mdc-slider__track--inactive,.lime-slider--readonly .mdc-slider.mdc-slider--disabled .mdc-slider__value-indicator{height:1rem;border-radius:1rem}.lime-slider--readonly .mdc-slider.mdc-slider--disabled .mdc-slider__track--active{top:0}.lime-slider--readonly .mdc-slider.mdc-slider--disabled .mdc-slider__value-indicator{transition:all 0s;transform:translateY(1.75rem)}.lime-slider--readonly .mdc-slider.mdc-slider--disabled .mdc-slider__thumb-knob{opacity:0}.lime-slider--readonly .mdc-slider.mdc-slider--disabled .mdc-slider__track--active_fill,.lime-slider--readonly .mdc-slider.mdc-slider--disabled .mdc-slider__thumb-knob{background-color:var(--mdc-theme-primary)}.lime-slider--readonly .mdc-slider.mdc-slider--disabled .mdc-slider__track--active_fill{border-color:var(--mdc-theme-primary)}.mdc-slider:not(.mdc-slider--disabled) .mdc-slider__thumb-knob:before,.mdc-slider:not(.mdc-slider--disabled) .mdc-slider__thumb-knob:after{transition:all 0.2s ease 0.2s;content:"";display:block;position:absolute;top:0;bottom:0;margin:auto;width:0.75rem;opacity:0;width:0;height:0;border:0.25rem solid transparent;border-top-color:rgba(var(--contrast-1400), 0.6)}.mdc-slider:not(.mdc-slider--disabled) .mdc-slider__thumb-knob:before{left:-1.25rem;transform:rotate(90deg)}.mdc-slider:not(.mdc-slider--disabled) .mdc-slider__thumb-knob:after{right:-1.25rem;transform:rotate(-90deg)}.mdc-slider:not(.mdc-slider--disabled) .mdc-slider__thumb-knob:hover:before{opacity:0.8;left:-1.75rem}.mdc-slider:not(.mdc-slider--disabled) .mdc-slider__thumb-knob:hover:after{opacity:0.8;right:-1.75rem}.mdc-slider .mdc-slider__value-indicator-container{z-index:1}.mdc-slider .mdc-slider__value-indicator{transition:transform 0.2s ease-out;opacity:1;transform:scale(1) translateY(2rem);border-radius:1.25rem;padding:0 0.5rem;height:1.5rem}.mdc-slider .mdc-slider__value-indicator:before{border-top-color:transparent}.mdc-slider .mdc-slider__value-indicator-text{color:var(--color-of-value-indicator)}.mdc-slider .mdc-ripple-upgraded--foreground-activation .mdc-slider__value-indicator{transform:scale(1.5) translateY(0);box-shadow:var(--shadow-depth-16)}.mdc-slider .mdc-ripple-upgraded--foreground-activation .mdc-slider__value-indicator:before{border-top-color:var(--mdc-theme-primary)}.mdc-slider:not(.mdc-slider--disabled) .mdc-slider__value-indicator{box-shadow:var(--button-shadow-normal)}.mdc-slider:not(.mdc-slider--disabled) .mdc-slider__value-indicator,.slider.lime-slider--readonly .mdc-slider__value-indicator{background-color:var(--mdc-theme-primary)}:host(:focus) .mdc-slider-helper-text,:host(:focus-visible) .mdc-slider-helper-text,:host(:focus-within) .mdc-slider-helper-text{opacity:1}.mdc-slider-helper-line{padding-right:1rem;padding-left:1rem;flex-basis:100%;width:100%}.mdc-slider-helper-text{font-family:Roboto, sans-serif;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-size:0.6875rem;font-weight:400;letter-spacing:0.0333333333em;text-decoration:inherit;text-transform:inherit;display:block;margin-top:0;line-height:normal;margin:0;transition:opacity 150ms cubic-bezier(0.4, 0, 0.2, 1);opacity:0}.mdc-slider-helper-text:before{height:0.75rem;display:inline-block;width:0;content:"";vertical-align:0}';export{k as limel_slider}
|
|
59
|
+
*/(this.step),this.valueBeforeDownEvent=r,this.valueStartBeforeDownEvent=s,this.mousedownOrTouchstartListener=this.handleMousedownOrTouchstart.bind(this),this.moveListener=this.handleMove.bind(this),this.pointerdownListener=this.handlePointerdown.bind(this),this.pointerupListener=this.handlePointerup.bind(this),this.thumbMouseenterListener=this.handleThumbMouseenter.bind(this),this.thumbMouseleaveListener=this.handleThumbMouseleave.bind(this),this.inputStartChangeListener=function(){t.handleInputChange(f.START)},this.inputEndChangeListener=function(){t.handleInputChange(f.END)},this.inputStartFocusListener=function(){t.handleInputFocus(f.START)},this.inputEndFocusListener=function(){t.handleInputFocus(f.END)},this.inputStartBlurListener=function(){t.handleInputBlur(f.START)},this.inputEndBlurListener=function(){t.handleInputBlur(f.END)},this.resizeListener=this.handleResize.bind(this),this.registerEventHandlers()},i.prototype.destroy=function(){this.deregisterEventHandlers()},i.prototype.getMin=function(){return this.min},i.prototype.getMax=function(){return this.max},i.prototype.getValue=function(){return this.value},i.prototype.setValue=function(t){if(this.isRange&&t<this.valueStart)throw new Error("end thumb value ("+t+") must be >= start thumb value ("+this.valueStart+")");this.updateValue(t,f.END)},i.prototype.getValueStart=function(){if(!this.isRange)throw new Error("`valueStart` is only applicable for range sliders.");return this.valueStart},i.prototype.setValueStart=function(t){if(!this.isRange)throw new Error("`valueStart` is only applicable for range sliders.");if(this.isRange&&t>this.value)throw new Error("start thumb value ("+t+") must be <= end thumb value ("+this.value+")");this.updateValue(t,f.START)},i.prototype.getStep=function(){return this.step},i.prototype.getDisabled=function(){return this.isDisabled},i.prototype.setDisabled=function(t){this.isDisabled=t,t?(this.adapter.addClass("mdc-slider--disabled"),this.isRange&&this.adapter.setInputAttribute("disabled","",f.START),this.adapter.setInputAttribute("disabled","",f.END)):(this.adapter.removeClass("mdc-slider--disabled"),this.isRange&&this.adapter.removeInputAttribute("disabled",f.START),this.adapter.removeInputAttribute("disabled",f.END))},i.prototype.getIsRange=function(){return this.isRange},i.prototype.layout=function(t){var i=(void 0===t?{}:t).skipUpdateUI;this.rect=this.adapter.getBoundingClientRect(),this.isRange&&(this.startThumbKnobWidth=this.adapter.getThumbKnobWidth(f.START),this.endThumbKnobWidth=this.adapter.getThumbKnobWidth(f.END)),i||this.updateUI()},i.prototype.handleResize=function(){this.layout()},i.prototype.handleDown=function(t){if(!this.isDisabled){this.valueStartBeforeDownEvent=this.valueStart,this.valueBeforeDownEvent=this.value;var i=null!=t.clientX?t.clientX:t.targetTouches[0].clientX;this.downEventClientX=i;var e=this.mapClientXOnSliderScale(i);this.thumb=this.getThumbFromDownEvent(i,e),null!==this.thumb&&(this.handleDragStart(t,e,this.thumb),this.updateValue(e,this.thumb,{emitInputEvent:!0}))}},i.prototype.handleMove=function(t){if(!this.isDisabled){t.preventDefault();var i=null!=t.clientX?t.clientX:t.targetTouches[0].clientX,e=null!=this.thumb;if(this.thumb=this.getThumbFromMoveEvent(i),null!==this.thumb){var r=this.mapClientXOnSliderScale(i);e||(this.handleDragStart(t,r,this.thumb),this.adapter.emitDragStartEvent(r,this.thumb)),this.updateValue(r,this.thumb,{emitInputEvent:!0})}}},i.prototype.handleUp=function(){if(!this.isDisabled&&null!==this.thumb){var t=this.thumb===f.START?this.valueStart:this.value;(this.thumb===f.START?this.valueStartBeforeDownEvent:this.valueBeforeDownEvent)!==t&&this.adapter.emitChangeEvent(t,this.thumb),this.adapter.emitDragEndEvent(t,this.thumb),this.thumb=null}},i.prototype.handleThumbMouseenter=function(){this.isDiscrete&&this.isRange&&(this.adapter.addThumbClass("mdc-slider__thumb--with-indicator",f.START),this.adapter.addThumbClass("mdc-slider__thumb--with-indicator",f.END))},i.prototype.handleThumbMouseleave=function(){this.isDiscrete&&this.isRange&&(this.adapter.isInputFocused(f.START)||this.adapter.isInputFocused(f.END)||(this.adapter.removeThumbClass("mdc-slider__thumb--with-indicator",f.START),this.adapter.removeThumbClass("mdc-slider__thumb--with-indicator",f.END)))},i.prototype.handleMousedownOrTouchstart=function(t){var i=this,e="mousedown"===t.type?"mousemove":"touchmove";this.adapter.registerBodyEventHandler(e,this.moveListener);var r=function(){i.handleUp(),i.adapter.deregisterBodyEventHandler(e,i.moveListener),i.adapter.deregisterEventHandler("mouseup",r),i.adapter.deregisterEventHandler("touchend",r)};this.adapter.registerBodyEventHandler("mouseup",r),this.adapter.registerBodyEventHandler("touchend",r),this.handleDown(t)},i.prototype.handlePointerdown=function(t){this.adapter.setPointerCapture(t.pointerId),this.adapter.registerEventHandler("pointermove",this.moveListener),this.handleDown(t)},i.prototype.handleInputChange=function(t){var i=Number(this.adapter.getInputValue(t));t===f.START?this.setValueStart(i):this.setValue(i),this.adapter.emitChangeEvent(t===f.START?this.valueStart:this.value,t),this.adapter.emitInputEvent(t===f.START?this.valueStart:this.value,t)},i.prototype.handleInputFocus=function(t){this.adapter.addThumbClass("mdc-slider__thumb--focused",t),this.isDiscrete&&(this.adapter.addThumbClass("mdc-slider__thumb--with-indicator",t),this.isRange&&this.adapter.addThumbClass("mdc-slider__thumb--with-indicator",t===f.START?f.END:f.START))},i.prototype.handleInputBlur=function(t){this.adapter.removeThumbClass("mdc-slider__thumb--focused",t),this.isDiscrete&&(this.adapter.removeThumbClass("mdc-slider__thumb--with-indicator",t),this.isRange&&this.adapter.removeThumbClass("mdc-slider__thumb--with-indicator",t===f.START?f.END:f.START))},i.prototype.handleDragStart=function(t,i,e){this.adapter.focusInput(e),t.preventDefault(),this.adapter.emitDragStartEvent(i,e)},i.prototype.getThumbFromDownEvent=function(t,i){if(!this.isRange)return f.END;var e=this.adapter.getThumbBoundingClientRect(f.START),r=this.adapter.getThumbBoundingClientRect(f.END),s=t>=e.left&&t<=e.right,n=t>=r.left&&t<=r.right;return s&&n?null:s?f.START:n?f.END:i<this.valueStart?f.START:i>this.value?f.END:i-this.valueStart<=this.value-i?f.START:f.END},i.prototype.getThumbFromMoveEvent=function(t){if(null!==this.thumb)return this.thumb;if(null===this.downEventClientX)throw new Error("`downEventClientX` is null after move event.");return Math.abs(this.downEventClientX-t)<5?this.thumb:t<this.downEventClientX?this.adapter.isRTL()?f.END:f.START:this.adapter.isRTL()?f.START:f.END},i.prototype.updateUI=function(t){this.updateThumbAndInputAttributes(t),this.updateThumbAndTrackUI(t),this.updateValueIndicatorUI(t),this.updateTickMarksUI()},i.prototype.updateThumbAndInputAttributes=function(t){if(t){var i=this.isRange&&t===f.START?this.valueStart:this.value,e=String(i);this.adapter.setInputAttribute("value",e,t),this.isRange&&t===f.START?this.adapter.setInputAttribute("min",e,f.END):this.isRange&&t===f.END&&this.adapter.setInputAttribute("max",e,f.START),this.adapter.getInputValue(t)!==e&&this.adapter.setInputValue(e,t);var r=this.adapter.getValueToAriaValueTextFn();r&&this.adapter.setInputAttribute("aria-valuetext",r(i),t)}},i.prototype.updateValueIndicatorUI=function(t){this.isDiscrete&&(this.adapter.setValueIndicatorText(this.isRange&&t===f.START?this.valueStart:this.value,t===f.START?f.START:f.END),!t&&this.isRange&&this.adapter.setValueIndicatorText(this.valueStart,f.START))},i.prototype.updateTickMarksUI=function(){if(this.isDiscrete&&this.hasTickMarks){var t=(this.value-this.valueStart)/this.step+1,i=(this.max-this.value)/this.step,e=Array.from({length:(this.valueStart-this.min)/this.step}).fill(p.INACTIVE),r=Array.from({length:t}).fill(p.ACTIVE),s=Array.from({length:i}).fill(p.INACTIVE);this.adapter.updateTickMarks(e.concat(r).concat(s))}},i.prototype.mapClientXOnSliderScale=function(t){var i=(t-this.rect.left)/this.rect.width;this.adapter.isRTL()&&(i=1-i);var e=this.min+i*(this.max-this.min);return e===this.max||e===this.min?e:Number(this.quantize(e).toFixed(this.numDecimalPlaces))},i.prototype.quantize=function(t){var i=Math.round((t-this.min)/this.step);return this.min+i*this.step},i.prototype.updateValue=function(t,i,e){var r=(void 0===e?{}:e).emitInputEvent;if(t=this.clampValue(t,i),this.isRange&&i===f.START){if(this.valueStart===t)return;this.valueStart=t}else{if(this.value===t)return;this.value=t}this.updateUI(i),r&&this.adapter.emitInputEvent(i===f.START?this.valueStart:this.value,i)},i.prototype.clampValue=function(t,i){return t=Math.min(Math.max(t,this.min),this.max),this.isRange&&i===f.START&&t>this.value?this.value:this.isRange&&i===f.END&&t<this.valueStart?this.valueStart:t},i.prototype.updateThumbAndTrackUI=function(t){var i=this,e=this.max,r=this.min,s=(this.value-this.valueStart)/(e-r),n=s*this.rect.width,o=this.adapter.isRTL(),a=g?m(window,"transform"):"transform";if(this.isRange){var d=this.adapter.isRTL()?(e-this.value)/(e-r)*this.rect.width:(this.valueStart-r)/(e-r)*this.rect.width,c=d+n;this.animFrame.request(b.SLIDER_UPDATE,(function(){!o&&t===f.START||o&&t!==f.START?(i.adapter.setTrackActiveStyleProperty("transform-origin","right"),i.adapter.setTrackActiveStyleProperty("left","unset"),i.adapter.setTrackActiveStyleProperty("right",i.rect.width-c+"px")):(i.adapter.setTrackActiveStyleProperty("transform-origin","left"),i.adapter.setTrackActiveStyleProperty("right","unset"),i.adapter.setTrackActiveStyleProperty("left",d+"px")),i.adapter.setTrackActiveStyleProperty(a,"scaleX("+s+")");var e=o?c:d,r=i.adapter.isRTL()?d:c;t!==f.START&&t&&i.initialStylesRemoved||i.adapter.setThumbStyleProperty(a,"translateX("+e+"px)",f.START),t!==f.END&&t&&i.initialStylesRemoved||i.adapter.setThumbStyleProperty(a,"translateX("+r+"px)",f.END),i.removeInitialStyles(o),i.updateOverlappingThumbsUI(e,r,t)}))}else this.animFrame.request(b.SLIDER_UPDATE,(function(){i.adapter.setThumbStyleProperty(a,"translateX("+(o?i.rect.width-n:n)+"px)",f.END),i.adapter.setTrackActiveStyleProperty(a,"scaleX("+s+")"),i.removeInitialStyles(o)}))},i.prototype.removeInitialStyles=function(t){if(!this.initialStylesRemoved){var i=t?"right":"left";this.adapter.removeThumbStyleProperty(i,f.END),this.isRange&&this.adapter.removeThumbStyleProperty(i,f.START),this.initialStylesRemoved=!0,this.resetTrackAndThumbAnimation()}},i.prototype.resetTrackAndThumbAnimation=function(){var t=this;if(this.isDiscrete){var i=g?m(window,"transition"):"transition",e="all 0s ease 0s";this.adapter.setThumbStyleProperty(i,e,f.END),this.isRange&&this.adapter.setThumbStyleProperty(i,e,f.START),this.adapter.setTrackActiveStyleProperty(i,e),requestAnimationFrame((function(){t.adapter.removeThumbStyleProperty(i,f.END),t.adapter.removeTrackActiveStyleProperty(i),t.isRange&&t.adapter.removeThumbStyleProperty(i,f.START)}))}},i.prototype.updateOverlappingThumbsUI=function(t,i,e){(this.adapter.isRTL()?i+this.endThumbKnobWidth/2>=t-this.startThumbKnobWidth/2:t+this.startThumbKnobWidth/2>=i-this.endThumbKnobWidth/2)?(this.adapter.addThumbClass("mdc-slider__thumb--top",e||f.END),this.adapter.removeThumbClass("mdc-slider__thumb--top",e===f.START?f.END:f.START)):(this.adapter.removeThumbClass("mdc-slider__thumb--top",f.START),this.adapter.removeThumbClass("mdc-slider__thumb--top",f.END))},i.prototype.convertAttributeValueToNumber=function(t,i){if(null===t)throw new Error("MDCSliderFoundation: `"+i+"` must be non-null.");var e=Number(t);if(isNaN(e))throw new Error("MDCSliderFoundation: `"+i+"` value is `"+t+"`, but must be a number.");return e},i.prototype.validateProperties=function(t){var i=t.min,e=t.max,r=t.value,s=t.valueStart,n=t.step;if(i>=e)throw new Error("MDCSliderFoundation: min must be strictly less than max. Current: [min: "+i+", max: "+e+"]");if(n<=0)throw new Error("MDCSliderFoundation: step must be a positive number. Current step: "+this.step);if(this.isRange){if(r<i||r>e||s<i||s>e)throw new Error("MDCSliderFoundation: values must be in [min, max] range. Current values: [start value: "+s+", end value: "+r+"]");if(s>r)throw new Error("MDCSliderFoundation: start value must be <= end value. Current values: [start value: "+s+", end value: "+r+"]");var o=(r-i)/n;if((s-i)/n%1!=0||o%1!=0)throw new Error("MDCSliderFoundation: Slider values must be valid based on the step value. Current values: [start value: "+s+", end value: "+r+"]")}else{if(r<i||r>e)throw new Error("MDCSliderFoundation: value must be in [min, max] range. Current value: "+r);if((o=(r-i)/n)%1!=0)throw new Error("MDCSliderFoundation: Slider value must be valid based on the step value. Current value: "+r)}},i.prototype.registerEventHandlers=function(){this.adapter.registerWindowEventHandler("resize",this.resizeListener),i.SUPPORTS_POINTER_EVENTS?(this.adapter.registerEventHandler("pointerdown",this.pointerdownListener),this.adapter.registerEventHandler("pointerup",this.pointerupListener)):(this.adapter.registerEventHandler("mousedown",this.mousedownOrTouchstartListener),this.adapter.registerEventHandler("touchstart",this.mousedownOrTouchstartListener)),this.isRange&&(this.adapter.registerThumbEventHandler(f.START,"mouseenter",this.thumbMouseenterListener),this.adapter.registerThumbEventHandler(f.START,"mouseleave",this.thumbMouseleaveListener),this.adapter.registerInputEventHandler(f.START,"change",this.inputStartChangeListener),this.adapter.registerInputEventHandler(f.START,"focus",this.inputStartFocusListener),this.adapter.registerInputEventHandler(f.START,"blur",this.inputStartBlurListener)),this.adapter.registerThumbEventHandler(f.END,"mouseenter",this.thumbMouseenterListener),this.adapter.registerThumbEventHandler(f.END,"mouseleave",this.thumbMouseleaveListener),this.adapter.registerInputEventHandler(f.END,"change",this.inputEndChangeListener),this.adapter.registerInputEventHandler(f.END,"focus",this.inputEndFocusListener),this.adapter.registerInputEventHandler(f.END,"blur",this.inputEndBlurListener)},i.prototype.deregisterEventHandlers=function(){this.adapter.deregisterWindowEventHandler("resize",this.resizeListener),i.SUPPORTS_POINTER_EVENTS?(this.adapter.deregisterEventHandler("pointerdown",this.pointerdownListener),this.adapter.deregisterEventHandler("pointerup",this.pointerupListener)):(this.adapter.deregisterEventHandler("mousedown",this.mousedownOrTouchstartListener),this.adapter.deregisterEventHandler("touchstart",this.mousedownOrTouchstartListener)),this.isRange&&(this.adapter.deregisterThumbEventHandler(f.START,"mouseenter",this.thumbMouseenterListener),this.adapter.deregisterThumbEventHandler(f.START,"mouseleave",this.thumbMouseleaveListener),this.adapter.deregisterInputEventHandler(f.START,"change",this.inputStartChangeListener),this.adapter.deregisterInputEventHandler(f.START,"focus",this.inputStartFocusListener),this.adapter.deregisterInputEventHandler(f.START,"blur",this.inputStartBlurListener)),this.adapter.deregisterThumbEventHandler(f.END,"mouseenter",this.thumbMouseenterListener),this.adapter.deregisterThumbEventHandler(f.END,"mouseleave",this.thumbMouseleaveListener),this.adapter.deregisterInputEventHandler(f.END,"change",this.inputEndChangeListener),this.adapter.deregisterInputEventHandler(f.END,"focus",this.inputEndFocusListener),this.adapter.deregisterInputEventHandler(f.END,"blur",this.inputEndBlurListener)},i.prototype.handlePointerup=function(){this.handleUp(),this.adapter.deregisterEventHandler("pointermove",this.moveListener)},i.SUPPORTS_POINTER_EVENTS=g&&Boolean(window.PointerEvent)&&!(["iPad Simulator","iPhone Simulator","iPod Simulator","iPad","iPhone","iPod"].includes(navigator.platform)||navigator.userAgent.includes("Mac")&&"ontouchend"in document),i}(s),y=function(t){function i(){var i=null!==t&&t.apply(this,arguments)||this;return i.skipInitialUIUpdate=!1,i.valueToAriaValueTextFn=null,i}return u(i,t),i.attachTo=function(t,e){return void 0===e&&(e={}),new i(t,void 0,e)},i.prototype.getDefaultFoundation=function(){var t=this;return new _({hasClass:function(i){return t.root.classList.contains(i)},addClass:function(i){t.root.classList.add(i)},removeClass:function(i){t.root.classList.remove(i)},addThumbClass:function(i,e){t.getThumbEl(e).classList.add(i)},removeThumbClass:function(i,e){t.getThumbEl(e).classList.remove(i)},getAttribute:function(i){return t.root.getAttribute(i)},getInputValue:function(i){return t.getInput(i).value},setInputValue:function(i,e){t.getInput(e).value=i},getInputAttribute:function(i,e){return t.getInput(e).getAttribute(i)},setInputAttribute:function(i,e,r){t.getInput(r).setAttribute(i,e)},removeInputAttribute:function(i,e){t.getInput(e).removeAttribute(i)},focusInput:function(i){t.getInput(i).focus()},isInputFocused:function(i){return t.getInput(i)===document.activeElement},getThumbKnobWidth:function(i){return t.getThumbEl(i).querySelector(".mdc-slider__thumb-knob").getBoundingClientRect().width},getThumbBoundingClientRect:function(i){return t.getThumbEl(i).getBoundingClientRect()},getBoundingClientRect:function(){return t.root.getBoundingClientRect()},isRTL:function(){return"rtl"===getComputedStyle(t.root).direction},setThumbStyleProperty:function(i,e,r){t.getThumbEl(r).style.setProperty(i,e)},removeThumbStyleProperty:function(i,e){t.getThumbEl(e).style.removeProperty(i)},setTrackActiveStyleProperty:function(i,e){t.trackActive.style.setProperty(i,e)},removeTrackActiveStyleProperty:function(i){t.trackActive.style.removeProperty(i)},setValueIndicatorText:function(i,e){t.getThumbEl(e).querySelector(".mdc-slider__value-indicator-text").textContent=String(i)},getValueToAriaValueTextFn:function(){return t.valueToAriaValueTextFn},updateTickMarks:function(i){var e=t.root.querySelector(".mdc-slider__tick-marks");e||((e=document.createElement("div")).classList.add("mdc-slider__tick-marks"),t.root.querySelector(".mdc-slider__track").appendChild(e)),i.length!==e.children.length?(e.innerHTML="",t.addTickMarks(e,i)):t.updateTickMarks(e,i)},setPointerCapture:function(i){t.root.setPointerCapture(i)},emitChangeEvent:function(i,e){t.emit("MDCSlider:change",{value:i,thumb:e})},emitInputEvent:function(i,e){t.emit("MDCSlider:input",{value:i,thumb:e})},emitDragStartEvent:function(i,e){t.getRipple(e).activate()},emitDragEndEvent:function(i,e){t.getRipple(e).deactivate()},registerEventHandler:function(i,e){t.listen(i,e)},deregisterEventHandler:function(i,e){t.unlisten(i,e)},registerThumbEventHandler:function(i,e,r){t.getThumbEl(i).addEventListener(e,r)},deregisterThumbEventHandler:function(i,e,r){t.getThumbEl(i).removeEventListener(e,r)},registerInputEventHandler:function(i,e,r){t.getInput(i).addEventListener(e,r)},deregisterInputEventHandler:function(i,e,r){t.getInput(i).removeEventListener(e,r)},registerBodyEventHandler:function(t,i){document.body.addEventListener(t,i)},deregisterBodyEventHandler:function(t,i){document.body.removeEventListener(t,i)},registerWindowEventHandler:function(t,i){window.addEventListener(t,i)},deregisterWindowEventHandler:function(t,i){window.removeEventListener(t,i)}})},i.prototype.initialize=function(t){var i=(void 0===t?{}:t).skipInitialUIUpdate;this.inputs=[].slice.call(this.root.querySelectorAll(".mdc-slider__input")),this.thumbs=[].slice.call(this.root.querySelectorAll(".mdc-slider__thumb")),this.trackActive=this.root.querySelector(".mdc-slider__track--active_fill"),this.ripples=this.createRipples(),i&&(this.skipInitialUIUpdate=!0)},i.prototype.initialSyncWithDOM=function(){this.foundation.layout({skipUpdateUI:this.skipInitialUIUpdate})},i.prototype.layout=function(){this.foundation.layout()},i.prototype.getValueStart=function(){return this.foundation.getValueStart()},i.prototype.setValueStart=function(t){this.foundation.setValueStart(t)},i.prototype.getValue=function(){return this.foundation.getValue()},i.prototype.setValue=function(t){this.foundation.setValue(t)},i.prototype.getDisabled=function(){return this.foundation.getDisabled()},i.prototype.setDisabled=function(t){this.foundation.setDisabled(t)},i.prototype.setValueToAriaValueTextFn=function(t){this.valueToAriaValueTextFn=t},i.prototype.getThumbEl=function(t){return t===f.END?this.thumbs[this.thumbs.length-1]:this.thumbs[0]},i.prototype.getInput=function(t){return t===f.END?this.inputs[this.inputs.length-1]:this.inputs[0]},i.prototype.getRipple=function(t){return t===f.END?this.ripples[this.ripples.length-1]:this.ripples[0]},i.prototype.addTickMarks=function(t,i){for(var e=document.createDocumentFragment(),r=0;r<i.length;r++){var s=document.createElement("div");s.classList.add(i[r]===p.ACTIVE?"mdc-slider__tick-mark--active":"mdc-slider__tick-mark--inactive"),e.appendChild(s)}t.appendChild(e)},i.prototype.updateTickMarks=function(t,i){for(var e=Array.from(t.children),r=0;r<e.length;r++)i[r]===p.ACTIVE?(e[r].classList.add("mdc-slider__tick-mark--active"),e[r].classList.remove("mdc-slider__tick-mark--inactive")):(e[r].classList.add("mdc-slider__tick-mark--inactive"),e[r].classList.remove("mdc-slider__tick-mark--active"))},i.prototype.createRipples=function(){for(var t=[],i=[].slice.call(this.root.querySelectorAll(".mdc-slider__thumb")),e=function(e){var s=i[e],n=r.inputs[e],l=v(v({},o.createAdapter(r)),{addClass:function(t){s.classList.add(t)},computeBoundingRect:function(){return s.getBoundingClientRect()},deregisterInteractionHandler:function(t,i){n.removeEventListener(t,i)},isSurfaceActive:function(){return c(n,":active")},isUnbounded:function(){return!0},registerInteractionHandler:function(t,i){n.addEventListener(t,i,a())},removeClass:function(t){s.classList.remove(t)},updateCssVariable:function(t,i){s.style.setProperty(t,i)}}),m=new o(s,new d(l));m.unbounded=!0,t.push(m)},r=this,s=0;s<i.length;s++)e(s);return t},i}(n);let k=class{constructor(e){t(this,e),this.change=i(this,"change",7),this.disabled=!1,this.readonly=!1,this.factor=1,this.unit="",this.valuemax=100,this.valuemin=0,this.changeHandler=t=>{let i=t.detail.value;const e=this.multiplyByFactor(this.step);this.isMultipleOfStep(i,e)||(i=this.roundToStep(i,e)),this.change.emit(i/this.factor)},this.inputHandler=this.inputHandler.bind(this),this.getContainerClassList=this.getContainerClassList.bind(this)}connectedCallback(){this.initialize()}componentDidLoad(){this.initialize()}initialize(){const t=this.getInputElement();if(!t)return;const i=this.getValue();t.setAttribute("value",`${this.multiplyByFactor(i)}`);const e=i<=this.valuemax;if(!(i>=this.valuemin)){const e=this.multiplyByFactor(i);t.setAttribute("min",`${e}`)}if(!e){const e=this.multiplyByFactor(i);t.setAttribute("max",`${e}`)}this.isMultipleOfStep(i,this.step)||t.removeAttribute("step"),this.createMDCSlider()}componentWillLoad(){this.setPercentageClass(this.value)}disconnectedCallback(){this.destroyMDCSlider()}getContainerClassList(){return{slider:!0,"lime-slider--readonly":this.readonly,[this.percentageClass]:!0}}render(){const t={};return this.step&&(t.step=this.multiplyByFactor(this.step)),(this.disabled||this.readonly)&&(t.disabled=!0),e("div",{class:this.getContainerClassList()},e("label",{class:"slider__label mdc-floating-label mdc-floating-label--float-above"},this.label),e("div",{class:"slider__content"},e("div",{class:"slider__content-range-container"},e("span",{class:"slider__content-min-label"},this.multiplyByFactor(this.valuemin),this.unit),e("span",{class:"slider__content-max-label"},this.multiplyByFactor(this.valuemax),this.unit)),e("div",{class:{"mdc-slider":!0,"mdc-slider--discrete":!0,"mdc-slider--disabled":this.disabled||this.readonly}},e("input",Object.assign({class:"mdc-slider__input",type:"range",min:this.multiplyByFactor(this.valuemin),max:this.multiplyByFactor(this.valuemax),value:this.multiplyByFactor(this.value),name:"volume","aria-label":"Discrete slider demo"},t)),e("div",{class:"mdc-slider__track"},e("div",{class:"mdc-slider__track--inactive"}),e("div",{class:"mdc-slider__track--active"},e("div",{class:"mdc-slider__track--active_fill"}))),e("div",{class:"mdc-slider__thumb"},e("div",{class:"mdc-slider__value-indicator-container","aria-hidden":"true"},e("div",{class:"mdc-slider__value-indicator"},e("span",{class:"mdc-slider__value-indicator-text"},this.multiplyByFactor(this.value)))),e("div",{class:"mdc-slider__thumb-knob"})))),this.renderHelperLine())}renderHelperLine(){if(this.helperText)return e("div",{class:"mdc-slider-helper-line"},e("p",{class:"mdc-slider-helper-text"},this.helperText))}watchDisabled(){this.updateDisabledState()}watchReadonly(){this.updateDisabledState()}watchValue(){if(!this.mdcSlider)return;const t=this.multiplyByFactor(this.getValue());if(this.mdcSlider.setValue(t),this.isStepConfigured())return;const i=this.multiplyByFactor(this.step);this.isMultipleOfStep(t,i)&&this.reCreateSliderWithStep()}updateDisabledState(){this.mdcSlider&&this.mdcSlider.setDisabled(this.disabled||this.readonly)}multiplyByFactor(t){return Math.round(t*this.factor)}getValue(){let t=this.value;return isFinite(t)||(t=this.valuemin),t}inputHandler(t){this.setPercentageClass(t.detail.value/this.factor)}setPercentageClass(t){this.percentageClass=function(t){return 0===t?"percent-0":t<.1?"percent-0-10":t<.2?"percent-10-20":t<.3?"percent-20-30":t<.4?"percent-30-40":t<.5?"percent-40-50":t<.6?"percent-50-60":t<.7?"percent-60-70":t<.8?"percent-70-80":t<.9?"percent-80-90":"percent-90-100"}((t-this.valuemin)/(this.valuemax-this.valuemin))}isMultipleOfStep(t,i){return!i||t%i==0}roundToStep(t,i){return Math.round(t/i)*i}getRootElement(){return this.rootElement.shadowRoot.querySelector(".mdc-slider")}getInputElement(){const t=this.getRootElement();if(t)return t.querySelector("input")}isStepConfigured(){if(!this.step)return!0;const t=this.getInputElement();return!t||t.hasAttribute("step")}reCreateSliderWithStep(){const t=this.getInputElement(),i=`${this.multiplyByFactor(this.step)}`;t.setAttribute("step",i),this.destroyMDCSlider(),this.createMDCSlider()}createMDCSlider(){const t=this.getRootElement();this.mdcSlider=new y(t),this.mdcSlider.listen("MDCSlider:change",this.changeHandler),this.mdcSlider.listen("MDCSlider:input",this.inputHandler)}destroyMDCSlider(){this.mdcSlider.unlisten("MDCSlider:change",this.changeHandler),this.mdcSlider.unlisten("MDCSlider:input",this.inputHandler),this.mdcSlider.destroy(),this.mdcSlider=void 0}get rootElement(){return r(this)}static get watchers(){return{disabled:["watchDisabled"],readonly:["watchReadonly"],value:["watchValue"]}}};k.style=':host{--mdc-theme-primary:var(\n --lime-primary-color,\n rgb(var(--color-teal-default))\n );--mdc-theme-secondary:var(\n --lime-secondary-color,\n rgb(var(--contrast-1100))\n );--mdc-theme-on-primary:var(\n --lime-on-primary-color,\n rgb(var(--contrast-100))\n );--mdc-theme-on-secondary:var(\n --lime-on-secondary-color,\n rgb(var(--contrast-100))\n );--mdc-theme-text-disabled-on-background:var(\n --lime-text-disabled-on-background-color,\n rgba(var(--contrast-1700), 0.38)\n );--mdc-theme-text-primary-on-background:var(\n --lime-text-primary-on-background-color,\n rgba(var(--contrast-1700), 0.87)\n );--mdc-theme-text-secondary-on-background:var(\n --lime-text-secondary-on-background-color,\n rgba(var(--contrast-1700), 0.54)\n );--lime-error-text-color:rgb(var(--color-red-darker));--mdc-theme-surface:var(\n --lime-surface-background-color,\n rgb(var(--contrast-100))\n );--mdc-theme-on-surface:var(\n --lime-on-surface-color,\n var(--lime-text-primary-on-background-color)\n )}@keyframes mdc-ripple-fg-radius-in{from{animation-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transform:translate(var(--mdc-ripple-fg-translate-start, 0)) scale(1)}to{transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}}@keyframes mdc-ripple-fg-opacity-in{from{animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@keyframes mdc-ripple-fg-opacity-out{from{animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}.mdc-slider__thumb{--mdc-ripple-fg-size:0;--mdc-ripple-left:0;--mdc-ripple-top:0;--mdc-ripple-fg-scale:1;--mdc-ripple-fg-translate-end:0;--mdc-ripple-fg-translate-start:0;-webkit-tap-highlight-color:rgba(0, 0, 0, 0);will-change:transform, opacity}.mdc-slider__thumb::before,.mdc-slider__thumb::after{position:absolute;border-radius:50%;opacity:0;pointer-events:none;content:""}.mdc-slider__thumb::before{transition:opacity 15ms linear, background-color 15ms linear;z-index:1;z-index:var(--mdc-ripple-z-index, 1)}.mdc-slider__thumb::after{z-index:0;z-index:var(--mdc-ripple-z-index, 0)}.mdc-slider__thumb.mdc-ripple-upgraded::before{transform:scale(var(--mdc-ripple-fg-scale, 1))}.mdc-slider__thumb.mdc-ripple-upgraded::after{top:0;left:0;transform:scale(0);transform-origin:center center}.mdc-slider__thumb.mdc-ripple-upgraded--unbounded::after{top:var(--mdc-ripple-top, 0);left:var(--mdc-ripple-left, 0)}.mdc-slider__thumb.mdc-ripple-upgraded--foreground-activation::after{animation:mdc-ripple-fg-radius-in 225ms forwards, mdc-ripple-fg-opacity-in 75ms forwards}.mdc-slider__thumb.mdc-ripple-upgraded--foreground-deactivation::after{animation:mdc-ripple-fg-opacity-out 150ms;transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}.mdc-slider__thumb::before,.mdc-slider__thumb::after{top:calc(50% - 50%);left:calc(50% - 50%);width:100%;height:100%}.mdc-slider__thumb.mdc-ripple-upgraded::before,.mdc-slider__thumb.mdc-ripple-upgraded::after{top:var(--mdc-ripple-top, calc(50% - 50%));left:var(--mdc-ripple-left, calc(50% - 50%));width:var(--mdc-ripple-fg-size, 100%);height:var(--mdc-ripple-fg-size, 100%)}.mdc-slider__thumb.mdc-ripple-upgraded::after{width:var(--mdc-ripple-fg-size, 100%);height:var(--mdc-ripple-fg-size, 100%)}.mdc-slider__thumb::before,.mdc-slider__thumb::after{background-color:#26a69a;background-color:var(--mdc-ripple-color, var(--mdc-theme-primary, #26a69a))}.mdc-slider__thumb:hover::before,.mdc-slider__thumb.mdc-ripple-surface--hover::before{opacity:0.08;opacity:var(--mdc-ripple-hover-opacity, 0.08)}.mdc-slider__thumb.mdc-ripple-upgraded--background-focused::before,.mdc-slider__thumb:not(.mdc-ripple-upgraded):focus::before{transition-duration:75ms;opacity:0.24;opacity:var(--mdc-ripple-focus-opacity, 0.24)}.mdc-slider__thumb:not(.mdc-ripple-upgraded)::after{transition:opacity 150ms linear}.mdc-slider__thumb:not(.mdc-ripple-upgraded):active::after{transition-duration:75ms;opacity:0.24;opacity:var(--mdc-ripple-press-opacity, 0.24)}.mdc-slider__thumb.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.24)}.mdc-slider{cursor:pointer;height:48px;margin:0 24px;position:relative;touch-action:pan-y}.mdc-slider .mdc-slider__track{height:4px;position:absolute;top:50%;transform:translateY(-50%);width:100%}.mdc-slider .mdc-slider__track--active,.mdc-slider .mdc-slider__track--inactive{display:flex;height:100%;position:absolute;width:100%}.mdc-slider .mdc-slider__track--active{border-radius:3px;height:6px;overflow:hidden;top:-1px}.mdc-slider .mdc-slider__track--active_fill{border-top:6px solid;box-sizing:border-box;height:100%;width:100%;position:relative;-webkit-transform-origin:left;transform-origin:left}[dir=rtl] .mdc-slider .mdc-slider__track--active_fill,.mdc-slider .mdc-slider__track--active_fill[dir=rtl]{-webkit-transform-origin:right;transform-origin:right}.mdc-slider .mdc-slider__track--inactive{border-radius:2px;height:4px;left:0;top:0}.mdc-slider .mdc-slider__track--inactive::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid transparent;border-radius:inherit;content:"";pointer-events:none}.mdc-slider .mdc-slider__track--active_fill{border-color:#26a69a;border-color:var(--mdc-theme-primary, #26a69a)}.mdc-slider.mdc-slider--disabled .mdc-slider__track--active_fill{border-color:#000;border-color:var(--mdc-theme-on-surface, #000)}.mdc-slider .mdc-slider__track--inactive{background-color:#26a69a;background-color:var(--mdc-theme-primary, #26a69a);opacity:0.24}.mdc-slider.mdc-slider--disabled .mdc-slider__track--inactive{background-color:#000;background-color:var(--mdc-theme-on-surface, #000);opacity:0.24}.mdc-slider .mdc-slider__value-indicator-container{bottom:44px;left:50%;pointer-events:none;position:absolute;transform:translateX(-50%)}.mdc-slider .mdc-slider__value-indicator{transition:transform 100ms 0ms cubic-bezier(0.4, 0, 1, 1);align-items:center;border-radius:4px;display:flex;height:32px;padding:0 12px;transform:scale(0);transform-origin:bottom}.mdc-slider .mdc-slider__value-indicator::before{border-left:6px solid transparent;border-right:6px solid transparent;border-top:6px solid;bottom:-5px;content:"";height:0;left:50%;position:absolute;transform:translateX(-50%);width:0}.mdc-slider .mdc-slider__value-indicator::after{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid transparent;border-radius:inherit;content:"";pointer-events:none}.mdc-slider .mdc-slider__thumb--with-indicator .mdc-slider__value-indicator-container{pointer-events:auto}.mdc-slider .mdc-slider__thumb--with-indicator .mdc-slider__value-indicator{transition:transform 100ms 0ms cubic-bezier(0, 0, 0.2, 1);transform:scale(1)}@media (prefers-reduced-motion){.mdc-slider .mdc-slider__value-indicator,.mdc-slider .mdc-slider__thumb--with-indicator .mdc-slider__value-indicator{transition:none}}.mdc-slider .mdc-slider__value-indicator-text{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-subtitle2-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:0.8125rem;font-size:var(--mdc-typography-subtitle2-font-size, 0.8125rem);line-height:1.125rem;line-height:var(--mdc-typography-subtitle2-line-height, 1.125rem);font-weight:500;font-weight:var(--mdc-typography-subtitle2-font-weight, 500);letter-spacing:0.0071428571em;letter-spacing:var(--mdc-typography-subtitle2-letter-spacing, 0.0071428571em);text-decoration:inherit;text-decoration:var(--mdc-typography-subtitle2-text-decoration, inherit);text-transform:inherit;text-transform:var(--mdc-typography-subtitle2-text-transform, inherit)}.mdc-slider .mdc-slider__value-indicator{background-color:#000;opacity:0.6}.mdc-slider .mdc-slider__value-indicator::before{border-top-color:#000}.mdc-slider .mdc-slider__value-indicator{color:#fff;color:var(--mdc-theme-on-primary, #fff)}.mdc-slider .mdc-slider__thumb{display:flex;height:48px;left:-24px;outline:none;position:absolute;user-select:none;width:48px}.mdc-slider .mdc-slider__thumb--top{z-index:1}.mdc-slider .mdc-slider__thumb--top .mdc-slider__thumb-knob,.mdc-slider .mdc-slider__thumb--top.mdc-slider__thumb:hover .mdc-slider__thumb-knob,.mdc-slider .mdc-slider__thumb--top.mdc-slider__thumb--focused .mdc-slider__thumb-knob{border:1px solid;box-sizing:content-box;border-color:#fff}.mdc-slider .mdc-slider__thumb-knob{box-shadow:0px 2px 1px -1px rgba(0, 0, 0, 0.2), 0px 1px 1px 0px rgba(0, 0, 0, 0.14), 0px 1px 3px 0px rgba(0, 0, 0, 0.12);border:10px solid;border-radius:50%;box-sizing:border-box;height:20px;left:50%;position:absolute;top:50%;transform:translate(-50%, -50%);width:20px}.mdc-slider .mdc-slider__thumb-knob{background-color:#26a69a;background-color:var(--mdc-theme-primary, #26a69a);border-color:#26a69a;border-color:var(--mdc-theme-primary, #26a69a)}.mdc-slider.mdc-slider--disabled .mdc-slider__thumb-knob{background-color:#000;background-color:var(--mdc-theme-on-surface, #000);border-color:#000;border-color:var(--mdc-theme-on-surface, #000)}.mdc-slider .mdc-slider__thumb::before,.mdc-slider .mdc-slider__thumb::after{background-color:#26a69a;background-color:var(--mdc-ripple-color, var(--mdc-theme-primary, #26a69a))}.mdc-slider .mdc-slider__thumb:hover::before,.mdc-slider .mdc-slider__thumb.mdc-ripple-surface--hover::before{opacity:0.08;opacity:var(--mdc-ripple-hover-opacity, 0.08)}.mdc-slider .mdc-slider__thumb.mdc-ripple-upgraded--background-focused::before,.mdc-slider .mdc-slider__thumb:not(.mdc-ripple-upgraded):focus::before{transition-duration:75ms;opacity:0.24;opacity:var(--mdc-ripple-focus-opacity, 0.24)}.mdc-slider .mdc-slider__thumb:not(.mdc-ripple-upgraded)::after{transition:opacity 150ms linear}.mdc-slider .mdc-slider__thumb:not(.mdc-ripple-upgraded):active::after{transition-duration:75ms;opacity:0.24;opacity:var(--mdc-ripple-press-opacity, 0.24)}.mdc-slider .mdc-slider__thumb.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.24)}.mdc-slider .mdc-slider__tick-marks{align-items:center;box-sizing:border-box;display:flex;height:100%;justify-content:space-between;padding:0 1px;position:absolute;width:100%}.mdc-slider .mdc-slider__tick-mark--active,.mdc-slider .mdc-slider__tick-mark--inactive{border-radius:50%;height:2px;width:2px}.mdc-slider .mdc-slider__tick-mark--active{background-color:#fff;background-color:var(--mdc-theme-on-primary, #fff);opacity:0.6}.mdc-slider.mdc-slider--disabled .mdc-slider__tick-mark--active{background-color:#fff;background-color:var(--mdc-theme-on-primary, #fff);opacity:0.6}.mdc-slider .mdc-slider__tick-mark--inactive{background-color:#26a69a;background-color:var(--mdc-theme-primary, #26a69a);opacity:0.6}.mdc-slider.mdc-slider--disabled .mdc-slider__tick-mark--inactive{background-color:#000;background-color:var(--mdc-theme-on-surface, #000);opacity:0.6}.mdc-slider.mdc-slider--disabled{opacity:0.38;cursor:auto}.mdc-slider.mdc-slider--disabled .mdc-slider__thumb{pointer-events:none}.mdc-slider--discrete .mdc-slider__thumb,.mdc-slider--discrete .mdc-slider__track--active_fill{transition:transform 80ms ease}@media (prefers-reduced-motion){.mdc-slider--discrete .mdc-slider__thumb,.mdc-slider--discrete .mdc-slider__track--active_fill{transition:none}}.mdc-slider__input{cursor:pointer;left:0;margin:0;height:100%;opacity:0;pointer-events:none;position:absolute;top:0;width:100%}.mdc-floating-label{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-subtitle1-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:0.875rem;font-size:var(--mdc-typography-subtitle1-font-size, 0.875rem);font-weight:400;font-weight:var(--mdc-typography-subtitle1-font-weight, 400);letter-spacing:0.009375em;letter-spacing:var(--mdc-typography-subtitle1-letter-spacing, 0.009375em);text-decoration:inherit;text-decoration:var(--mdc-typography-subtitle1-text-decoration, inherit);text-transform:inherit;text-transform:var(--mdc-typography-subtitle1-text-transform, inherit);position:absolute;left:0;-webkit-transform-origin:left top;transform-origin:left top;line-height:1.15rem;text-align:left;text-overflow:ellipsis;white-space:nowrap;cursor:text;overflow:hidden;will-change:transform;transition:transform 150ms cubic-bezier(0.4, 0, 0.2, 1), color 150ms cubic-bezier(0.4, 0, 0.2, 1)}[dir=rtl] .mdc-floating-label,.mdc-floating-label[dir=rtl]{right:0;left:auto;-webkit-transform-origin:right top;transform-origin:right top;text-align:right}.mdc-floating-label--float-above{cursor:auto}.mdc-floating-label--required::after{margin-left:1px;margin-right:0px;content:"*"}[dir=rtl] .mdc-floating-label--required::after,.mdc-floating-label--required[dir=rtl]::after{margin-left:0;margin-right:1px}.mdc-floating-label--float-above{transform:translateY(-106%) scale(0.75)}.mdc-floating-label--shake{animation:mdc-floating-label-shake-float-above-standard 250ms 1}@keyframes mdc-floating-label-shake-float-above-standard{0%{transform:translateX(calc(0 - 0%)) translateY(-106%) scale(0.75)}33%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(calc(4% - 0%)) translateY(-106%) scale(0.75)}66%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(calc(-4% - 0%)) translateY(-106%) scale(0.75)}100%{transform:translateX(calc(0 - 0%)) translateY(-106%) scale(0.75)}}:host([disabled]:not([readonly])) .slider__label{color:rgba(var(--contrast-1200), 0.5)}.slider{position:relative}.slider__label{color:rgba(var(--contrast-1200), 1);padding-left:1.25rem;top:0.5625rem}.slider__content{display:flex;flex-direction:column;margin-top:0.25rem}.slider__content-range-container{display:flex;order:2;justify-content:space-between;width:calc(100% - 1.5rem);margin:0 auto;margin-top:-1rem}.slider__content-min-label,.slider__content-max-label{transition:opacity 0.2s ease;opacity:0.7;font-size:0.75rem;top:1.25rem}.slider:hover .slider__content-min-label,.slider:hover .slider__content-max-label{opacity:1}.mdc-slider__track:before,.mdc-slider__track:after{content:"";display:inline-block;position:absolute;top:0;bottom:0;margin:auto;width:0.375rem;height:0.375rem;border-radius:50%;background-color:rgba(var(--contrast-700), 0.6)}.mdc-slider__track:before{left:-0.75rem}.mdc-slider__track:after{right:-0.75rem}.mdc-slider__track--active_fill,.mdc-slider__track--inactive,.mdc-slider__thumb-knob{transition:background-color 0.5s ease}:host(.displays-percentage-colors) .slider.lime-slider--readonly{--mdc-theme-on-surface:var(--mdc-theme-primary)}:host(.displays-percentage-colors) .slider.percent-0{--mdc-theme-primary:var(--color-percent--0)}:host(.displays-percentage-colors) .slider.percent-0-10{--mdc-theme-primary:var(--color-percent--0to10)}:host(.displays-percentage-colors) .slider.percent-10-20{--mdc-theme-primary:var(--color-percent--10to20)}:host(.displays-percentage-colors) .slider.percent-20-30{--mdc-theme-primary:var(--color-percent--20to30)}:host(.displays-percentage-colors) .slider.percent-30-40{--mdc-theme-primary:var(--color-percent--30to40)}:host(.displays-percentage-colors) .slider.percent-40-50{--mdc-theme-primary:var(--color-percent--40to50)}:host(.displays-percentage-colors) .slider.percent-50-60{--mdc-theme-primary:var(--color-percent--50to60)}:host(.displays-percentage-colors) .slider.percent-60-70{--mdc-theme-primary:var(--color-percent--60to70)}:host(.displays-percentage-colors) .slider.percent-70-80{--mdc-theme-primary:var(--color-percent--70to80)}:host(.displays-percentage-colors) .slider.percent-80-90{--mdc-theme-primary:var(--color-percent--80to90)}:host(.displays-percentage-colors) .slider.percent-90-100{--mdc-theme-primary:var(--color-percent--90to100)}:host(.displays-percentage-colors) .slider.percent-30-40 .mdc-slider__value-indicator-text,:host(.displays-percentage-colors) .slider.percent-40-50 .mdc-slider__value-indicator-text,:host(.displays-percentage-colors) .slider.percent-70-80 .mdc-slider__value-indicator-text{color:rgb(var(--color-gray-darker))}:host(.displays-percentage-colors) .slider.percent-30-40 .mdc-slider--disabled .mdc-slider__value-indicator-text,:host(.displays-percentage-colors) .slider.percent-40-50 .mdc-slider--disabled .mdc-slider__value-indicator-text,:host(.displays-percentage-colors) .slider.percent-70-80 .mdc-slider--disabled .mdc-slider__value-indicator-text{color:rgb(var(--contrast-100))}:host(.displays-percentage-colors) .slider.percent-50-60 .mdc-slider__value-indicator-text,:host(.displays-percentage-colors) .slider.percent-60-70 .mdc-slider__value-indicator-text{color:rgb(var(--color-gray-dark))}:host(.displays-percentage-colors) .slider.percent-50-60 .mdc-slider--disabled .mdc-slider__value-indicator-text,:host(.displays-percentage-colors) .slider.percent-60-70 .mdc-slider--disabled .mdc-slider__value-indicator-text{color:rgb(var(--contrast-100))}:host{--mdc-theme-primary:var(\n --lime-primary-color,\n rgb(var(--color-teal-default))\n );--mdc-theme-secondary:var(\n --lime-secondary-color,\n rgb(var(--contrast-1100))\n );--mdc-theme-on-primary:var(\n --lime-on-primary-color,\n rgb(var(--contrast-100))\n );--mdc-theme-on-secondary:var(\n --lime-on-secondary-color,\n rgb(var(--contrast-100))\n );--mdc-theme-text-disabled-on-background:var(\n --lime-text-disabled-on-background-color,\n rgba(var(--contrast-1700), 0.38)\n );--mdc-theme-text-primary-on-background:var(\n --lime-text-primary-on-background-color,\n rgba(var(--contrast-1700), 0.87)\n );--mdc-theme-text-secondary-on-background:var(\n --lime-text-secondary-on-background-color,\n rgba(var(--contrast-1700), 0.54)\n );--lime-error-text-color:rgb(var(--color-red-darker));--mdc-theme-surface:var(\n --lime-surface-background-color,\n rgb(var(--contrast-100))\n );--mdc-theme-on-surface:var(\n --lime-on-surface-color,\n var(--lime-text-primary-on-background-color)\n )}.lime-slider--readonly .mdc-slider.mdc-slider--disabled{opacity:1}.lime-slider--readonly .mdc-slider.mdc-slider--disabled .mdc-slider__track,.lime-slider--readonly .mdc-slider.mdc-slider--disabled .mdc-slider__track--active,.lime-slider--readonly .mdc-slider.mdc-slider--disabled .mdc-slider__track--inactive,.lime-slider--readonly .mdc-slider.mdc-slider--disabled .mdc-slider__value-indicator{height:1rem;border-radius:1rem}.lime-slider--readonly .mdc-slider.mdc-slider--disabled .mdc-slider__track--active{top:0}.lime-slider--readonly .mdc-slider.mdc-slider--disabled .mdc-slider__value-indicator{transition:all 0s;transform:translateY(1.75rem)}.lime-slider--readonly .mdc-slider.mdc-slider--disabled .mdc-slider__thumb-knob{opacity:0}.lime-slider--readonly .mdc-slider.mdc-slider--disabled .mdc-slider__track--active_fill,.lime-slider--readonly .mdc-slider.mdc-slider--disabled .mdc-slider__thumb-knob{background-color:var(--mdc-theme-primary)}.lime-slider--readonly .mdc-slider.mdc-slider--disabled .mdc-slider__track--active_fill{border-color:var(--mdc-theme-primary)}.mdc-slider:not(.mdc-slider--disabled) .mdc-slider__thumb-knob:before,.mdc-slider:not(.mdc-slider--disabled) .mdc-slider__thumb-knob:after{transition:all 0.2s ease 0.2s;content:"";display:block;position:absolute;top:0;bottom:0;margin:auto;width:0.75rem;opacity:0;width:0;height:0;border:0.25rem solid transparent;border-top-color:rgba(var(--contrast-1400), 0.6)}.mdc-slider:not(.mdc-slider--disabled) .mdc-slider__thumb-knob:before{left:-1.25rem;transform:rotate(90deg)}.mdc-slider:not(.mdc-slider--disabled) .mdc-slider__thumb-knob:after{right:-1.25rem;transform:rotate(-90deg)}.mdc-slider:not(.mdc-slider--disabled) .mdc-slider__thumb-knob:hover:before{opacity:0.8;left:-1.75rem}.mdc-slider:not(.mdc-slider--disabled) .mdc-slider__thumb-knob:hover:after{opacity:0.8;right:-1.75rem}.mdc-slider .mdc-slider__value-indicator-container{z-index:1}.mdc-slider .mdc-slider__value-indicator{transition:transform 0.2s ease-out;opacity:1;transform:scale(1) translateY(2rem);border-radius:1.25rem;padding:0 0.5rem;height:1.5rem}.mdc-slider .mdc-slider__value-indicator:before{border-top-color:transparent}.mdc-slider .mdc-slider__value-indicator-text{color:var(--color-of-value-indicator)}.mdc-slider .mdc-ripple-upgraded--foreground-activation .mdc-slider__value-indicator{transform:scale(1.5) translateY(0);box-shadow:var(--shadow-depth-16)}.mdc-slider .mdc-ripple-upgraded--foreground-activation .mdc-slider__value-indicator:before{border-top-color:var(--mdc-theme-primary)}.mdc-slider:not(.mdc-slider--disabled) .mdc-slider__value-indicator{box-shadow:var(--button-shadow-normal)}.mdc-slider:not(.mdc-slider--disabled) .mdc-slider__value-indicator,.slider.lime-slider--readonly .mdc-slider__value-indicator{background-color:var(--mdc-theme-primary)}:host(:focus) .mdc-slider-helper-text,:host(:focus-visible) .mdc-slider-helper-text,:host(:focus-within) .mdc-slider-helper-text{opacity:1}.mdc-slider-helper-line{padding-right:1rem;padding-left:1rem;flex-basis:100%;width:100%}.mdc-slider-helper-text{font-family:Roboto, sans-serif;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-size:0.6875rem;font-weight:400;letter-spacing:0.0333333333em;text-decoration:inherit;text-transform:inherit;display:block;margin-top:0;line-height:normal;margin:0;transition:opacity 150ms cubic-bezier(0.4, 0, 0.2, 1);opacity:0}.mdc-slider-helper-text:before{height:0.75rem;display:inline-block;width:0;content:"";vertical-align:0}';export{k as limel_slider}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{r,h as e,g as n}from"./p-92146da6.js";import{M as i,a}from"./p-076bd4dc.js";import{
|
|
1
|
+
import{r,h as e,g as n}from"./p-92146da6.js";import{M as i,a}from"./p-076bd4dc.js";import{g as t}from"./p-9faad6eb.js";
|
|
2
2
|
/*! *****************************************************************************
|
|
3
3
|
Copyright (c) Microsoft Corporation.
|
|
4
4
|
|
|
@@ -34,4 +34,4 @@ PERFORMANCE OF THIS SOFTWARE.
|
|
|
34
34
|
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
35
35
|
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
36
36
|
* THE SOFTWARE.
|
|
37
|
-
*/(e),t=a.next();!t.done;t=a.next()){var s=t.value;s.contentRect&&r.calculateAndSetDimensions(s.contentRect.width)}}catch(r){n={error:r}}finally{try{t&&!t.done&&(i=a.return)&&i.call(a)}finally{if(n)throw n.error}}})),!this.determinate&&this.observer&&this.calculateAndSetDimensions(this.adapter.getWidth())},e.prototype.setDeterminate=function(r){if(this.determinate=r,this.determinate)return this.adapter.removeClass(l.INDETERMINATE_CLASS),this.adapter.setAttribute(m.ARIA_VALUENOW,this.progress.toString()),this.adapter.setAttribute(m.ARIA_VALUEMAX,"1"),this.adapter.setAttribute(m.ARIA_VALUEMIN,"0"),this.setPrimaryBarProgress(this.progress),void this.setBufferBarProgress(this.buffer);this.observer&&this.calculateAndSetDimensions(this.adapter.getWidth()),this.adapter.addClass(l.INDETERMINATE_CLASS),this.adapter.removeAttribute(m.ARIA_VALUENOW),this.adapter.removeAttribute(m.ARIA_VALUEMAX),this.adapter.removeAttribute(m.ARIA_VALUEMIN),this.setPrimaryBarProgress(1),this.setBufferBarProgress(1)},e.prototype.isDeterminate=function(){return this.determinate},e.prototype.setProgress=function(r){this.progress=r,this.determinate&&(this.setPrimaryBarProgress(r),this.adapter.setAttribute(m.ARIA_VALUENOW,r.toString()))},e.prototype.getProgress=function(){return this.progress},e.prototype.setBuffer=function(r){this.buffer=r,this.determinate&&this.setBufferBarProgress(r)},e.prototype.getBuffer=function(){return this.buffer},e.prototype.open=function(){this.adapter.removeClass(l.CLOSED_CLASS),this.adapter.removeClass(l.CLOSED_ANIMATION_OFF_CLASS),this.adapter.removeAttribute(m.ARIA_HIDDEN)},e.prototype.close=function(){this.adapter.addClass(l.CLOSED_CLASS),this.adapter.setAttribute(m.ARIA_HIDDEN,"true")},e.prototype.isClosed=function(){return this.adapter.hasClass(l.CLOSED_CLASS)},e.prototype.handleTransitionEnd=function(){this.adapter.hasClass(l.CLOSED_CLASS)&&this.adapter.addClass(l.CLOSED_ANIMATION_OFF_CLASS)},e.prototype.destroy=function(){r.prototype.destroy.call(this),this.observer&&this.observer.disconnect()},e.prototype.restartAnimation=function(){this.adapter.removeClass(l.ANIMATION_READY_CLASS),this.adapter.forceLayout(),this.adapter.addClass(l.ANIMATION_READY_CLASS)},e.prototype.setPrimaryBarProgress=function(r){var e="scaleX("+r+")",n="undefined"!=typeof window?t(window,"transform"):"transform";this.adapter.setPrimaryBarStyle(n,e)},e.prototype.setBufferBarProgress=function(r){this.adapter.setBufferBarStyle(m.FLEX_BASIS,100*r+"%")},e.prototype.calculateAndSetDimensions=function(r){var e=.8367142*r,n=2.00611057*r,i=.37651913*r,a=.84386165*r,t=1.60277782*r;this.adapter.setStyle("--mdc-linear-progress-primary-half",e+"px"),this.adapter.setStyle("--mdc-linear-progress-primary-half-neg",-e+"px"),this.adapter.setStyle("--mdc-linear-progress-primary-full",n+"px"),this.adapter.setStyle("--mdc-linear-progress-primary-full-neg",-n+"px"),this.adapter.setStyle("--mdc-linear-progress-secondary-quarter",i+"px"),this.adapter.setStyle("--mdc-linear-progress-secondary-quarter-neg",-i+"px"),this.adapter.setStyle("--mdc-linear-progress-secondary-half",a+"px"),this.adapter.setStyle("--mdc-linear-progress-secondary-half-neg",-a+"px"),this.adapter.setStyle("--mdc-linear-progress-secondary-full",t+"px"),this.adapter.setStyle("--mdc-linear-progress-secondary-full-neg",-t+"px"),this.restartAnimation()},e}(i),f=function(r){function e(){return null!==r&&r.apply(this,arguments)||this}return o(e,r),e.attachTo=function(r){return new e(r)},Object.defineProperty(e.prototype,"determinate",{set:function(r){this.foundation.setDeterminate(r)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"progress",{set:function(r){this.foundation.setProgress(r)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"buffer",{set:function(r){this.foundation.setBuffer(r)},enumerable:!1,configurable:!0}),e.prototype.open=function(){this.foundation.open()},e.prototype.close=function(){this.foundation.close()},e.prototype.initialSyncWithDOM=function(){var r=this;this.root.addEventListener("transitionend",(function(){r.foundation.handleTransitionEnd()}))},e.prototype.getDefaultFoundation=function(){var r=this;return new d({addClass:function(e){r.root.classList.add(e)},forceLayout:function(){r.root.getBoundingClientRect()},setBufferBarStyle:function(e,n){var i=r.root.querySelector(d.strings.BUFFER_BAR_SELECTOR);i&&i.style.setProperty(e,n)},setPrimaryBarStyle:function(e,n){var i=r.root.querySelector(d.strings.PRIMARY_BAR_SELECTOR);i&&i.style.setProperty(e,n)},hasClass:function(e){return r.root.classList.contains(e)},removeAttribute:function(e){r.root.removeAttribute(e)},removeClass:function(e){r.root.classList.remove(e)},setAttribute:function(e,n){r.root.setAttribute(e,n)},setStyle:function(e,n){r.root.style.setProperty(e,n)},attachResizeObserver:function(e){var n=window.ResizeObserver;if(n){var i=new n(e);return i.observe(r.root),i}return null},getWidth:function(){return r.root.offsetWidth}})},e}(a);let u=class{constructor(e){r(this,e),this.value=0,this.indeterminate=!1}connectedCallback(){this.initialize()}componentDidLoad(){this.initialize()}initialize(){const r=this.host.shadowRoot.querySelector(".mdc-linear-progress");r&&(this.mdcLinearProgress=new f(r),this.mdcLinearProgress.progress=this.value)}disconnectedCallback(){this.mdcLinearProgress&&this.mdcLinearProgress.destroy()}render(){return e("div",{role:"progressbar",class:{"mdc-linear-progress":!0,"mdc-linear-progress--indeterminate":this.indeterminate},"aria-label":"Progress Bar","aria-valuemin":"0","aria-valuemax":"1","aria-valuenow":this.value},e("div",{class:"mdc-linear-progress__buffer"},e("div",{class:"mdc-linear-progress__buffer-bar"})),e("div",{class:"mdc-linear-progress__bar mdc-linear-progress__primary-bar"},e("span",{class:"mdc-linear-progress__bar-inner"})),e("div",{class:"mdc-linear-progress__bar mdc-linear-progress__secondary-bar"},e("span",{class:"mdc-linear-progress__bar-inner"})))}watchValue(r){this.mdcLinearProgress&&(this.mdcLinearProgress.progress=r)}get host(){return n(this)}static get watchers(){return{value:["watchValue"]}}};u.style=":host{--mdc-theme-primary:var(\n --lime-primary-color,\n rgb(var(--color-teal-default))\n );--mdc-theme-secondary:var(\n --lime-secondary-color,\n rgb(var(--contrast-1100))\n );--mdc-theme-on-primary:var(\n --lime-on-primary-color,\n rgb(var(--contrast-100))\n );--mdc-theme-on-secondary:var(\n --lime-on-secondary-color,\n rgb(var(--contrast-100))\n );--mdc-theme-text-disabled-on-background:var(\n --lime-text-disabled-on-background-color,\n rgba(var(--contrast-1700), 0.38)\n );--mdc-theme-text-primary-on-background:var(\n --lime-text-primary-on-background-color,\n rgba(var(--contrast-1700), 0.87)\n );--mdc-theme-text-secondary-on-background:var(\n --lime-text-secondary-on-background-color,\n rgba(var(--contrast-1700), 0.54)\n );--lime-error-text-color:rgb(var(--color-red-darker));--mdc-theme-surface:var(\n --lime-surface-background-color,\n rgb(var(--contrast-100))\n );--mdc-theme-on-surface:var(\n --lime-on-surface-color,\n var(--lime-text-primary-on-background-color)\n )}@keyframes mdc-linear-progress-primary-indeterminate-translate{0%{transform:translateX(0)}20%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(0)}59.15%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(83.67142%);transform:translateX(var(--mdc-linear-progress-primary-half, 83.67142%))}100%{transform:translateX(200.611057%);transform:translateX(var(--mdc-linear-progress-primary-full, 200.611057%))}}@keyframes mdc-linear-progress-primary-indeterminate-scale{0%{transform:scaleX(0.08)}36.65%{animation-timing-function:cubic-bezier(0.334731, 0.12482, 0.785844, 1);transform:scaleX(0.08)}69.15%{animation-timing-function:cubic-bezier(0.06, 0.11, 0.6, 1);transform:scaleX(0.661479)}100%{transform:scaleX(0.08)}}@keyframes mdc-linear-progress-secondary-indeterminate-translate{0%{animation-timing-function:cubic-bezier(0.15, 0, 0.515058, 0.409685);transform:translateX(0)}25%{animation-timing-function:cubic-bezier(0.31033, 0.284058, 0.8, 0.733712);transform:translateX(37.651913%);transform:translateX(var(--mdc-linear-progress-secondary-quarter, 37.651913%))}48.35%{animation-timing-function:cubic-bezier(0.4, 0.627035, 0.6, 0.902026);transform:translateX(84.386165%);transform:translateX(var(--mdc-linear-progress-secondary-half, 84.386165%))}100%{transform:translateX(160.277782%);transform:translateX(var(--mdc-linear-progress-secondary-full, 160.277782%))}}@keyframes mdc-linear-progress-secondary-indeterminate-scale{0%{animation-timing-function:cubic-bezier(0.205028, 0.057051, 0.57661, 0.453971);transform:scaleX(0.08)}19.15%{animation-timing-function:cubic-bezier(0.152313, 0.196432, 0.648374, 1.004315);transform:scaleX(0.457104)}44.15%{animation-timing-function:cubic-bezier(0.257759, -0.003163, 0.211762, 1.38179);transform:scaleX(0.72796)}100%{transform:scaleX(0.08)}}@keyframes mdc-linear-progress-buffering{from{transform:rotate(180deg) translateX(-10px)}}@keyframes mdc-linear-progress-primary-indeterminate-translate-reverse{0%{transform:translateX(0)}20%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(0)}59.15%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(-83.67142%);transform:translateX(var(--mdc-linear-progress-primary-half-neg, -83.67142%))}100%{transform:translateX(-200.611057%);transform:translateX(var(--mdc-linear-progress-primary-full-neg, -200.611057%))}}@keyframes mdc-linear-progress-secondary-indeterminate-translate-reverse{0%{animation-timing-function:cubic-bezier(0.15, 0, 0.515058, 0.409685);transform:translateX(0)}25%{animation-timing-function:cubic-bezier(0.31033, 0.284058, 0.8, 0.733712);transform:translateX(-37.651913%);transform:translateX(var(--mdc-linear-progress-secondary-quarter-neg, -37.651913%))}48.35%{animation-timing-function:cubic-bezier(0.4, 0.627035, 0.6, 0.902026);transform:translateX(-84.386165%);transform:translateX(var(--mdc-linear-progress-secondary-half-neg, -84.386165%))}100%{transform:translateX(-160.277782%);transform:translateX(var(--mdc-linear-progress-secondary-full-neg, -160.277782%))}}@keyframes mdc-linear-progress-buffering-reverse{from{transform:translateX(-10px)}}.mdc-linear-progress{position:relative;width:100%;height:4px;transform:translateZ(0);outline:1px solid transparent;overflow:hidden;transition:opacity 250ms 0ms cubic-bezier(0.4, 0, 0.6, 1)}.mdc-linear-progress__bar{position:absolute;width:100%;height:100%;animation:none;transform-origin:top left;transition:transform 250ms 0ms cubic-bezier(0.4, 0, 0.6, 1)}.mdc-linear-progress__bar-inner{display:inline-block;position:absolute;width:100%;animation:none;border-top:4px solid}.mdc-linear-progress__buffer{display:flex;position:absolute;width:100%;height:100%}.mdc-linear-progress__buffer-dots{background-repeat:repeat-x;background-size:10px 4px;flex:auto;transform:rotate(180deg);animation:mdc-linear-progress-buffering 250ms infinite linear}.mdc-linear-progress__buffer-bar{flex:0 1 100%;transition:flex-basis 250ms 0ms cubic-bezier(0.4, 0, 0.6, 1)}.mdc-linear-progress__primary-bar{transform:scaleX(0)}.mdc-linear-progress__secondary-bar{visibility:hidden}.mdc-linear-progress--indeterminate .mdc-linear-progress__bar{transition:none}.mdc-linear-progress--indeterminate .mdc-linear-progress__primary-bar{left:-145.166611%}.mdc-linear-progress--indeterminate .mdc-linear-progress__secondary-bar{left:-54.888891%;visibility:visible}.mdc-linear-progress--indeterminate.mdc-linear-progress--animation-ready .mdc-linear-progress__primary-bar{animation:mdc-linear-progress-primary-indeterminate-translate 2s infinite linear}.mdc-linear-progress--indeterminate.mdc-linear-progress--animation-ready .mdc-linear-progress__primary-bar>.mdc-linear-progress__bar-inner{animation:mdc-linear-progress-primary-indeterminate-scale 2s infinite linear}.mdc-linear-progress--indeterminate.mdc-linear-progress--animation-ready .mdc-linear-progress__secondary-bar{animation:mdc-linear-progress-secondary-indeterminate-translate 2s infinite linear}.mdc-linear-progress--indeterminate.mdc-linear-progress--animation-ready .mdc-linear-progress__secondary-bar>.mdc-linear-progress__bar-inner{animation:mdc-linear-progress-secondary-indeterminate-scale 2s infinite linear}[dir=rtl] .mdc-linear-progress:not([dir=ltr]) .mdc-linear-progress__bar,.mdc-linear-progress[dir=rtl]:not([dir=ltr]) .mdc-linear-progress__bar{right:0;-webkit-transform-origin:center right;transform-origin:center right}[dir=rtl] .mdc-linear-progress:not([dir=ltr]).mdc-linear-progress--animation-ready .mdc-linear-progress__primary-bar,.mdc-linear-progress[dir=rtl]:not([dir=ltr]).mdc-linear-progress--animation-ready .mdc-linear-progress__primary-bar{animation-name:mdc-linear-progress-primary-indeterminate-translate-reverse}[dir=rtl] .mdc-linear-progress:not([dir=ltr]).mdc-linear-progress--animation-ready .mdc-linear-progress__secondary-bar,.mdc-linear-progress[dir=rtl]:not([dir=ltr]).mdc-linear-progress--animation-ready .mdc-linear-progress__secondary-bar{animation-name:mdc-linear-progress-secondary-indeterminate-translate-reverse}[dir=rtl] .mdc-linear-progress:not([dir=ltr]) .mdc-linear-progress__buffer-dots,.mdc-linear-progress[dir=rtl]:not([dir=ltr]) .mdc-linear-progress__buffer-dots{animation:mdc-linear-progress-buffering-reverse 250ms infinite linear;transform:rotate(0)}[dir=rtl] .mdc-linear-progress:not([dir=ltr]).mdc-linear-progress--indeterminate .mdc-linear-progress__primary-bar,.mdc-linear-progress[dir=rtl]:not([dir=ltr]).mdc-linear-progress--indeterminate .mdc-linear-progress__primary-bar{right:-145.166611%;left:auto}[dir=rtl] .mdc-linear-progress:not([dir=ltr]).mdc-linear-progress--indeterminate .mdc-linear-progress__secondary-bar,.mdc-linear-progress[dir=rtl]:not([dir=ltr]).mdc-linear-progress--indeterminate .mdc-linear-progress__secondary-bar{right:-54.888891%;left:auto}.mdc-linear-progress--closed{opacity:0}.mdc-linear-progress--closed-animation-off .mdc-linear-progress__buffer-dots{animation:none}.mdc-linear-progress--closed-animation-off.mdc-linear-progress--indeterminate .mdc-linear-progress__bar,.mdc-linear-progress--closed-animation-off.mdc-linear-progress--indeterminate .mdc-linear-progress__bar .mdc-linear-progress__bar-inner{animation:none}.mdc-linear-progress__bar-inner{border-color:#26a69a;border-color:var(--mdc-theme-primary, #26a69a)}.mdc-linear-progress__buffer-dots{background-image:url(\"data:image/svg+xml,%3Csvg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' enable-background='new 0 0 5 2' xml:space='preserve' viewBox='0 0 5 2' preserveAspectRatio='none slice'%3E%3Ccircle cx='1' cy='1' r='1' fill='%23e6e6e6'/%3E%3C/svg%3E\")}.mdc-linear-progress__buffer-bar{background-color:#e6e6e6}.mdc-linear-progress{text-align:left}.mdc-linear-progress__buffer-dots{background-image:url(\"data:image/svg+xml,%3Csvg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' enable-background='new 0 0 5 2' xml:space='preserve' viewBox='0 0 5 2' preserveAspectRatio='none slice'%3E%3Ccircle cx='1' cy='1' r='1' fill='var(--background-color, rgba(var(--contrast-800), 0.5))'/%3E%3C/svg%3E\")}.mdc-linear-progress__buffer-bar{background-color:var(--background-color, rgba(var(--contrast-800), 0.5))}";export{u as limel_linear_progress}
|
|
37
|
+
*/(e),t=a.next();!t.done;t=a.next()){var s=t.value;s.contentRect&&r.calculateAndSetDimensions(s.contentRect.width)}}catch(r){n={error:r}}finally{try{t&&!t.done&&(i=a.return)&&i.call(a)}finally{if(n)throw n.error}}})),!this.determinate&&this.observer&&this.calculateAndSetDimensions(this.adapter.getWidth())},e.prototype.setDeterminate=function(r){if(this.determinate=r,this.determinate)return this.adapter.removeClass(l.INDETERMINATE_CLASS),this.adapter.setAttribute(m.ARIA_VALUENOW,this.progress.toString()),this.adapter.setAttribute(m.ARIA_VALUEMAX,"1"),this.adapter.setAttribute(m.ARIA_VALUEMIN,"0"),this.setPrimaryBarProgress(this.progress),void this.setBufferBarProgress(this.buffer);this.observer&&this.calculateAndSetDimensions(this.adapter.getWidth()),this.adapter.addClass(l.INDETERMINATE_CLASS),this.adapter.removeAttribute(m.ARIA_VALUENOW),this.adapter.removeAttribute(m.ARIA_VALUEMAX),this.adapter.removeAttribute(m.ARIA_VALUEMIN),this.setPrimaryBarProgress(1),this.setBufferBarProgress(1)},e.prototype.isDeterminate=function(){return this.determinate},e.prototype.setProgress=function(r){this.progress=r,this.determinate&&(this.setPrimaryBarProgress(r),this.adapter.setAttribute(m.ARIA_VALUENOW,r.toString()))},e.prototype.getProgress=function(){return this.progress},e.prototype.setBuffer=function(r){this.buffer=r,this.determinate&&this.setBufferBarProgress(r)},e.prototype.getBuffer=function(){return this.buffer},e.prototype.open=function(){this.adapter.removeClass(l.CLOSED_CLASS),this.adapter.removeClass(l.CLOSED_ANIMATION_OFF_CLASS),this.adapter.removeAttribute(m.ARIA_HIDDEN)},e.prototype.close=function(){this.adapter.addClass(l.CLOSED_CLASS),this.adapter.setAttribute(m.ARIA_HIDDEN,"true")},e.prototype.isClosed=function(){return this.adapter.hasClass(l.CLOSED_CLASS)},e.prototype.handleTransitionEnd=function(){this.adapter.hasClass(l.CLOSED_CLASS)&&this.adapter.addClass(l.CLOSED_ANIMATION_OFF_CLASS)},e.prototype.destroy=function(){r.prototype.destroy.call(this),this.observer&&this.observer.disconnect()},e.prototype.restartAnimation=function(){this.adapter.removeClass(l.ANIMATION_READY_CLASS),this.adapter.forceLayout(),this.adapter.addClass(l.ANIMATION_READY_CLASS)},e.prototype.setPrimaryBarProgress=function(r){var e="scaleX("+r+")",n="undefined"!=typeof window?t(window,"transform"):"transform";this.adapter.setPrimaryBarStyle(n,e)},e.prototype.setBufferBarProgress=function(r){this.adapter.setBufferBarStyle(m.FLEX_BASIS,100*r+"%")},e.prototype.calculateAndSetDimensions=function(r){var e=.8367142*r,n=2.00611057*r,i=.37651913*r,a=.84386165*r,t=1.60277782*r;this.adapter.setStyle("--mdc-linear-progress-primary-half",e+"px"),this.adapter.setStyle("--mdc-linear-progress-primary-half-neg",-e+"px"),this.adapter.setStyle("--mdc-linear-progress-primary-full",n+"px"),this.adapter.setStyle("--mdc-linear-progress-primary-full-neg",-n+"px"),this.adapter.setStyle("--mdc-linear-progress-secondary-quarter",i+"px"),this.adapter.setStyle("--mdc-linear-progress-secondary-quarter-neg",-i+"px"),this.adapter.setStyle("--mdc-linear-progress-secondary-half",a+"px"),this.adapter.setStyle("--mdc-linear-progress-secondary-half-neg",-a+"px"),this.adapter.setStyle("--mdc-linear-progress-secondary-full",t+"px"),this.adapter.setStyle("--mdc-linear-progress-secondary-full-neg",-t+"px"),this.restartAnimation()},e}(i),f=function(r){function e(){return null!==r&&r.apply(this,arguments)||this}return o(e,r),e.attachTo=function(r){return new e(r)},Object.defineProperty(e.prototype,"determinate",{set:function(r){this.foundation.setDeterminate(r)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"progress",{set:function(r){this.foundation.setProgress(r)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"buffer",{set:function(r){this.foundation.setBuffer(r)},enumerable:!1,configurable:!0}),e.prototype.open=function(){this.foundation.open()},e.prototype.close=function(){this.foundation.close()},e.prototype.initialSyncWithDOM=function(){var r=this;this.root.addEventListener("transitionend",(function(){r.foundation.handleTransitionEnd()}))},e.prototype.getDefaultFoundation=function(){var r=this;return new d({addClass:function(e){r.root.classList.add(e)},forceLayout:function(){r.root.getBoundingClientRect()},setBufferBarStyle:function(e,n){var i=r.root.querySelector(d.strings.BUFFER_BAR_SELECTOR);i&&i.style.setProperty(e,n)},setPrimaryBarStyle:function(e,n){var i=r.root.querySelector(d.strings.PRIMARY_BAR_SELECTOR);i&&i.style.setProperty(e,n)},hasClass:function(e){return r.root.classList.contains(e)},removeAttribute:function(e){r.root.removeAttribute(e)},removeClass:function(e){r.root.classList.remove(e)},setAttribute:function(e,n){r.root.setAttribute(e,n)},setStyle:function(e,n){r.root.style.setProperty(e,n)},attachResizeObserver:function(e){var n=window.ResizeObserver;if(n){var i=new n(e);return i.observe(r.root),i}return null},getWidth:function(){return r.root.offsetWidth}})},e}(a);let g=class{constructor(e){r(this,e),this.value=0,this.indeterminate=!1}connectedCallback(){this.initialize()}componentDidLoad(){this.initialize()}initialize(){const r=this.host.shadowRoot.querySelector(".mdc-linear-progress");r&&(this.mdcLinearProgress=new f(r),this.mdcLinearProgress.progress=this.value)}disconnectedCallback(){this.mdcLinearProgress&&this.mdcLinearProgress.destroy()}render(){return e("div",{role:"progressbar",class:{"mdc-linear-progress":!0,"mdc-linear-progress--indeterminate":this.indeterminate},"aria-label":"Progress Bar","aria-valuemin":"0","aria-valuemax":"1","aria-valuenow":this.value},e("div",{class:"mdc-linear-progress__buffer"},e("div",{class:"mdc-linear-progress__buffer-bar"})),e("div",{class:"mdc-linear-progress__bar mdc-linear-progress__primary-bar"},e("span",{class:"mdc-linear-progress__bar-inner"})),e("div",{class:"mdc-linear-progress__bar mdc-linear-progress__secondary-bar"},e("span",{class:"mdc-linear-progress__bar-inner"})))}watchValue(r){this.mdcLinearProgress&&(this.mdcLinearProgress.progress=r)}get host(){return n(this)}static get watchers(){return{value:["watchValue"]}}};g.style=":host{--mdc-theme-primary:var(\n --lime-primary-color,\n rgb(var(--color-teal-default))\n );--mdc-theme-secondary:var(\n --lime-secondary-color,\n rgb(var(--contrast-1100))\n );--mdc-theme-on-primary:var(\n --lime-on-primary-color,\n rgb(var(--contrast-100))\n );--mdc-theme-on-secondary:var(\n --lime-on-secondary-color,\n rgb(var(--contrast-100))\n );--mdc-theme-text-disabled-on-background:var(\n --lime-text-disabled-on-background-color,\n rgba(var(--contrast-1700), 0.38)\n );--mdc-theme-text-primary-on-background:var(\n --lime-text-primary-on-background-color,\n rgba(var(--contrast-1700), 0.87)\n );--mdc-theme-text-secondary-on-background:var(\n --lime-text-secondary-on-background-color,\n rgba(var(--contrast-1700), 0.54)\n );--lime-error-text-color:rgb(var(--color-red-darker));--mdc-theme-surface:var(\n --lime-surface-background-color,\n rgb(var(--contrast-100))\n );--mdc-theme-on-surface:var(\n --lime-on-surface-color,\n var(--lime-text-primary-on-background-color)\n )}@keyframes mdc-linear-progress-primary-indeterminate-translate{0%{transform:translateX(0)}20%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(0)}59.15%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(83.67142%);transform:translateX(var(--mdc-linear-progress-primary-half, 83.67142%))}100%{transform:translateX(200.611057%);transform:translateX(var(--mdc-linear-progress-primary-full, 200.611057%))}}@keyframes mdc-linear-progress-primary-indeterminate-scale{0%{transform:scaleX(0.08)}36.65%{animation-timing-function:cubic-bezier(0.334731, 0.12482, 0.785844, 1);transform:scaleX(0.08)}69.15%{animation-timing-function:cubic-bezier(0.06, 0.11, 0.6, 1);transform:scaleX(0.661479)}100%{transform:scaleX(0.08)}}@keyframes mdc-linear-progress-secondary-indeterminate-translate{0%{animation-timing-function:cubic-bezier(0.15, 0, 0.515058, 0.409685);transform:translateX(0)}25%{animation-timing-function:cubic-bezier(0.31033, 0.284058, 0.8, 0.733712);transform:translateX(37.651913%);transform:translateX(var(--mdc-linear-progress-secondary-quarter, 37.651913%))}48.35%{animation-timing-function:cubic-bezier(0.4, 0.627035, 0.6, 0.902026);transform:translateX(84.386165%);transform:translateX(var(--mdc-linear-progress-secondary-half, 84.386165%))}100%{transform:translateX(160.277782%);transform:translateX(var(--mdc-linear-progress-secondary-full, 160.277782%))}}@keyframes mdc-linear-progress-secondary-indeterminate-scale{0%{animation-timing-function:cubic-bezier(0.205028, 0.057051, 0.57661, 0.453971);transform:scaleX(0.08)}19.15%{animation-timing-function:cubic-bezier(0.152313, 0.196432, 0.648374, 1.004315);transform:scaleX(0.457104)}44.15%{animation-timing-function:cubic-bezier(0.257759, -0.003163, 0.211762, 1.38179);transform:scaleX(0.72796)}100%{transform:scaleX(0.08)}}@keyframes mdc-linear-progress-buffering{from{transform:rotate(180deg) translateX(-10px)}}@keyframes mdc-linear-progress-primary-indeterminate-translate-reverse{0%{transform:translateX(0)}20%{animation-timing-function:cubic-bezier(0.5, 0, 0.701732, 0.495819);transform:translateX(0)}59.15%{animation-timing-function:cubic-bezier(0.302435, 0.381352, 0.55, 0.956352);transform:translateX(-83.67142%);transform:translateX(var(--mdc-linear-progress-primary-half-neg, -83.67142%))}100%{transform:translateX(-200.611057%);transform:translateX(var(--mdc-linear-progress-primary-full-neg, -200.611057%))}}@keyframes mdc-linear-progress-secondary-indeterminate-translate-reverse{0%{animation-timing-function:cubic-bezier(0.15, 0, 0.515058, 0.409685);transform:translateX(0)}25%{animation-timing-function:cubic-bezier(0.31033, 0.284058, 0.8, 0.733712);transform:translateX(-37.651913%);transform:translateX(var(--mdc-linear-progress-secondary-quarter-neg, -37.651913%))}48.35%{animation-timing-function:cubic-bezier(0.4, 0.627035, 0.6, 0.902026);transform:translateX(-84.386165%);transform:translateX(var(--mdc-linear-progress-secondary-half-neg, -84.386165%))}100%{transform:translateX(-160.277782%);transform:translateX(var(--mdc-linear-progress-secondary-full-neg, -160.277782%))}}@keyframes mdc-linear-progress-buffering-reverse{from{transform:translateX(-10px)}}.mdc-linear-progress{position:relative;width:100%;height:4px;transform:translateZ(0);outline:1px solid transparent;overflow:hidden;transition:opacity 250ms 0ms cubic-bezier(0.4, 0, 0.6, 1)}.mdc-linear-progress__bar{position:absolute;width:100%;height:100%;animation:none;transform-origin:top left;transition:transform 250ms 0ms cubic-bezier(0.4, 0, 0.6, 1)}.mdc-linear-progress__bar-inner{display:inline-block;position:absolute;width:100%;animation:none;border-top:4px solid}.mdc-linear-progress__buffer{display:flex;position:absolute;width:100%;height:100%}.mdc-linear-progress__buffer-dots{background-repeat:repeat-x;background-size:10px 4px;flex:auto;transform:rotate(180deg);animation:mdc-linear-progress-buffering 250ms infinite linear}.mdc-linear-progress__buffer-bar{flex:0 1 100%;transition:flex-basis 250ms 0ms cubic-bezier(0.4, 0, 0.6, 1)}.mdc-linear-progress__primary-bar{transform:scaleX(0)}.mdc-linear-progress__secondary-bar{visibility:hidden}.mdc-linear-progress--indeterminate .mdc-linear-progress__bar{transition:none}.mdc-linear-progress--indeterminate .mdc-linear-progress__primary-bar{left:-145.166611%}.mdc-linear-progress--indeterminate .mdc-linear-progress__secondary-bar{left:-54.888891%;visibility:visible}.mdc-linear-progress--indeterminate.mdc-linear-progress--animation-ready .mdc-linear-progress__primary-bar{animation:mdc-linear-progress-primary-indeterminate-translate 2s infinite linear}.mdc-linear-progress--indeterminate.mdc-linear-progress--animation-ready .mdc-linear-progress__primary-bar>.mdc-linear-progress__bar-inner{animation:mdc-linear-progress-primary-indeterminate-scale 2s infinite linear}.mdc-linear-progress--indeterminate.mdc-linear-progress--animation-ready .mdc-linear-progress__secondary-bar{animation:mdc-linear-progress-secondary-indeterminate-translate 2s infinite linear}.mdc-linear-progress--indeterminate.mdc-linear-progress--animation-ready .mdc-linear-progress__secondary-bar>.mdc-linear-progress__bar-inner{animation:mdc-linear-progress-secondary-indeterminate-scale 2s infinite linear}[dir=rtl] .mdc-linear-progress:not([dir=ltr]) .mdc-linear-progress__bar,.mdc-linear-progress[dir=rtl]:not([dir=ltr]) .mdc-linear-progress__bar{right:0;-webkit-transform-origin:center right;transform-origin:center right}[dir=rtl] .mdc-linear-progress:not([dir=ltr]).mdc-linear-progress--animation-ready .mdc-linear-progress__primary-bar,.mdc-linear-progress[dir=rtl]:not([dir=ltr]).mdc-linear-progress--animation-ready .mdc-linear-progress__primary-bar{animation-name:mdc-linear-progress-primary-indeterminate-translate-reverse}[dir=rtl] .mdc-linear-progress:not([dir=ltr]).mdc-linear-progress--animation-ready .mdc-linear-progress__secondary-bar,.mdc-linear-progress[dir=rtl]:not([dir=ltr]).mdc-linear-progress--animation-ready .mdc-linear-progress__secondary-bar{animation-name:mdc-linear-progress-secondary-indeterminate-translate-reverse}[dir=rtl] .mdc-linear-progress:not([dir=ltr]) .mdc-linear-progress__buffer-dots,.mdc-linear-progress[dir=rtl]:not([dir=ltr]) .mdc-linear-progress__buffer-dots{animation:mdc-linear-progress-buffering-reverse 250ms infinite linear;transform:rotate(0)}[dir=rtl] .mdc-linear-progress:not([dir=ltr]).mdc-linear-progress--indeterminate .mdc-linear-progress__primary-bar,.mdc-linear-progress[dir=rtl]:not([dir=ltr]).mdc-linear-progress--indeterminate .mdc-linear-progress__primary-bar{right:-145.166611%;left:auto}[dir=rtl] .mdc-linear-progress:not([dir=ltr]).mdc-linear-progress--indeterminate .mdc-linear-progress__secondary-bar,.mdc-linear-progress[dir=rtl]:not([dir=ltr]).mdc-linear-progress--indeterminate .mdc-linear-progress__secondary-bar{right:-54.888891%;left:auto}.mdc-linear-progress--closed{opacity:0}.mdc-linear-progress--closed-animation-off .mdc-linear-progress__buffer-dots{animation:none}.mdc-linear-progress--closed-animation-off.mdc-linear-progress--indeterminate .mdc-linear-progress__bar,.mdc-linear-progress--closed-animation-off.mdc-linear-progress--indeterminate .mdc-linear-progress__bar .mdc-linear-progress__bar-inner{animation:none}.mdc-linear-progress__bar-inner{border-color:#26a69a;border-color:var(--mdc-theme-primary, #26a69a)}.mdc-linear-progress__buffer-dots{background-image:url(\"data:image/svg+xml,%3Csvg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' enable-background='new 0 0 5 2' xml:space='preserve' viewBox='0 0 5 2' preserveAspectRatio='none slice'%3E%3Ccircle cx='1' cy='1' r='1' fill='%23e6e6e6'/%3E%3C/svg%3E\")}.mdc-linear-progress__buffer-bar{background-color:#e6e6e6}.mdc-linear-progress{text-align:left}.mdc-linear-progress__buffer-dots{background-image:url(\"data:image/svg+xml,%3Csvg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' enable-background='new 0 0 5 2' xml:space='preserve' viewBox='0 0 5 2' preserveAspectRatio='none slice'%3E%3Ccircle cx='1' cy='1' r='1' fill='var(--background-color, rgba(var(--contrast-800), 0.5))'/%3E%3C/svg%3E\")}.mdc-linear-progress__buffer-bar{background-color:var(--background-color, rgba(var(--contrast-800), 0.5))}";export{g as limel_linear_progress}
|
|
@@ -9,7 +9,8 @@ $input-field--mdc-text-field__input--readonly: 1 !default;
|
|
|
9
9
|
$list--has-interactive-items--mdc-list-item--hover: 1 !default;
|
|
10
10
|
$list-static-actions-list: 1 !default;
|
|
11
11
|
$tab-bar--active-tab: 2 !default;
|
|
12
|
-
$table--has-interactive-rows--selectable-row--hover:
|
|
12
|
+
$table--has-interactive-rows--selectable-row--hover: 2 !default;
|
|
13
|
+
$table--limel-table--row-selector: 1 !default;
|
|
13
14
|
$popover-before: -1 !default;
|
|
14
15
|
$button-group-radio-button-keyboard-focused: 1 !default;
|
|
15
16
|
$list-mdc-list-item: 0 !default;
|
|
@@ -45,6 +45,13 @@ export declare function formatCell(cell: Tabulator.CellComponent, column: Column
|
|
|
45
45
|
* @returns {HTMLElement} custom component that renders a value in the table
|
|
46
46
|
*/
|
|
47
47
|
export declare function createCustomComponent(cell: Tabulator.CellComponent, column: Column, value: string, pool: ElementPool): HTMLElement;
|
|
48
|
+
/**
|
|
49
|
+
* Set all properties for a custom element, including event listeners
|
|
50
|
+
*
|
|
51
|
+
* @param {HTMLElement} element the custom element
|
|
52
|
+
* @param {object} props object of properties and event listeners
|
|
53
|
+
*/
|
|
54
|
+
export declare function setElementProperties(element: HTMLElement, props: object): void;
|
|
48
55
|
interface TabulatorSorter extends Tabulator.Sorter {
|
|
49
56
|
field: string;
|
|
50
57
|
}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Contains changes made to a selection
|
|
3
|
+
*/
|
|
4
|
+
export interface SelectionChangeSet {
|
|
5
|
+
/**
|
|
6
|
+
* Tells whether the items were selected or deselected
|
|
7
|
+
*/
|
|
8
|
+
selected: boolean;
|
|
9
|
+
/**
|
|
10
|
+
* Gets the affected items
|
|
11
|
+
*/
|
|
12
|
+
items: any[];
|
|
13
|
+
/**
|
|
14
|
+
* Gets the indexes of the affected items
|
|
15
|
+
*/
|
|
16
|
+
indexes: number[];
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Contains a set of selected data objects with methods for adding and removing
|
|
20
|
+
* items to the selection by referring to them by their index/position.
|
|
21
|
+
* Maintains a memory of the last toggled item which can be used to select or
|
|
22
|
+
* deselect a range of items between the last toggled item and a given item.
|
|
23
|
+
*/
|
|
24
|
+
export declare class Selection {
|
|
25
|
+
private getDataByIndex;
|
|
26
|
+
private selectedItems;
|
|
27
|
+
private lastToggledIndex;
|
|
28
|
+
/**
|
|
29
|
+
* Creates an instance of the Selection class.
|
|
30
|
+
* The provided function `getDataByIndex` is used to provide data for the
|
|
31
|
+
* selected items when selection is toggled by using the item index,
|
|
32
|
+
* which can be the row position in a table.
|
|
33
|
+
*
|
|
34
|
+
* @param {Function} getDataByIndex A function that returns the data at the given index
|
|
35
|
+
*/
|
|
36
|
+
constructor(getDataByIndex: (number: any) => any);
|
|
37
|
+
/**
|
|
38
|
+
* @returns {number} The size of the selection
|
|
39
|
+
*/
|
|
40
|
+
get size(): number;
|
|
41
|
+
/**
|
|
42
|
+
* @returns {any[]} The selected items
|
|
43
|
+
*/
|
|
44
|
+
get items(): any[];
|
|
45
|
+
/**
|
|
46
|
+
* @param {any[]} items The selected items
|
|
47
|
+
*/
|
|
48
|
+
set items(items: any[]);
|
|
49
|
+
/**
|
|
50
|
+
* Checks whether the given item exist in the selection
|
|
51
|
+
*
|
|
52
|
+
* @param {any} data The data to look up
|
|
53
|
+
* @returns {boolean} `true` if the given data exist in the selection, otherwise `false`
|
|
54
|
+
*/
|
|
55
|
+
has(data: any): boolean;
|
|
56
|
+
/**
|
|
57
|
+
* Toggles the item at the given index in the selection
|
|
58
|
+
*
|
|
59
|
+
* @param {number} index The index of the item to toggle
|
|
60
|
+
* @returns {SelectionChangeSet} The changes made to the selection
|
|
61
|
+
*/
|
|
62
|
+
toggleSelection(index: number): SelectionChangeSet;
|
|
63
|
+
/**
|
|
64
|
+
* Toggles the items from the last toggled index to the given index in the selection.
|
|
65
|
+
* The toggled items will be toggled as the item at the given index no matter
|
|
66
|
+
* their current state in the selection.
|
|
67
|
+
* Initially, when no last toggled index exist, this function behaves like
|
|
68
|
+
* `toggleSelection`.
|
|
69
|
+
*
|
|
70
|
+
* @param {number} index The index of the item to toggle
|
|
71
|
+
* @returns {SelectionChangeSet} The changes made to the selection
|
|
72
|
+
*/
|
|
73
|
+
toggleSelectionFromLastIndex(index: number): SelectionChangeSet;
|
|
74
|
+
/**
|
|
75
|
+
* Clears the current selection and resets last toggled index
|
|
76
|
+
*/
|
|
77
|
+
clear(): void;
|
|
78
|
+
private toggleRange;
|
|
79
|
+
}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { EventEmitter } from '../../stencil-public-runtime';
|
|
2
|
+
import Tabulator from 'tabulator-tables';
|
|
3
|
+
import { ElementPool } from './element-pool';
|
|
4
|
+
/**
|
|
5
|
+
* Provides row selection to Tabulator with shift-click support for range selections
|
|
6
|
+
*/
|
|
7
|
+
export declare class TableSelection {
|
|
8
|
+
private getTable;
|
|
9
|
+
private pool;
|
|
10
|
+
private selectEvent;
|
|
11
|
+
private selection;
|
|
12
|
+
/**
|
|
13
|
+
* Creates an instance of the TableSelection class
|
|
14
|
+
*
|
|
15
|
+
* @param {Function} getTable Function that returns the Tabulator instance
|
|
16
|
+
* @param {ElementPool} pool The element pool used to cache the checkbox components
|
|
17
|
+
* @param {EventEmitter<object[]>} selectEvent The event emitter to use when checkboxes are toggled
|
|
18
|
+
*/
|
|
19
|
+
constructor(getTable: () => Tabulator, pool: ElementPool, selectEvent: EventEmitter<object[]>);
|
|
20
|
+
/**
|
|
21
|
+
* @returns {boolean} Returns `true` when the selection is non-empty, otherwise `false`
|
|
22
|
+
*/
|
|
23
|
+
get hasSelection(): boolean;
|
|
24
|
+
/**
|
|
25
|
+
* Clears the selection
|
|
26
|
+
*/
|
|
27
|
+
clear(): void;
|
|
28
|
+
/**
|
|
29
|
+
* Sets the selected items
|
|
30
|
+
*
|
|
31
|
+
* @param {any[]} data The selected items
|
|
32
|
+
*/
|
|
33
|
+
setSelection(data: any[]): void;
|
|
34
|
+
/**
|
|
35
|
+
* Prepends a checkbox column used for row selection to the given column definitions
|
|
36
|
+
*
|
|
37
|
+
* @param {Tabulator.ColumnDefinition[]} columnDefinitions The column definition for the table
|
|
38
|
+
* @returns {Tabulator.ColumnDefinition[]} The column definitions with the checkbox column prepended to it
|
|
39
|
+
*/
|
|
40
|
+
getColumnDefinitions(columnDefinitions: Tabulator.ColumnDefinition[]): Tabulator.ColumnDefinition[];
|
|
41
|
+
private getRowSelectorColumnDefinition;
|
|
42
|
+
private headerClick;
|
|
43
|
+
private getRowSelectorFormatter;
|
|
44
|
+
/**
|
|
45
|
+
* Tabulator cell click handler that updates the selection for the clicked
|
|
46
|
+
* row and toggles the selection from the last clicked row if the shift key
|
|
47
|
+
* is pressed down.
|
|
48
|
+
*
|
|
49
|
+
* @param {PointerEvent} ev The pointer event
|
|
50
|
+
* @param {Tabulator.CellComponent} cell The clicked cell component
|
|
51
|
+
*/
|
|
52
|
+
protected rowSelectorCellClick: (ev: PointerEvent, cell: Tabulator.CellComponent) => void;
|
|
53
|
+
private updateRowSelectors;
|
|
54
|
+
private updateRowSelector;
|
|
55
|
+
private getActiveRows;
|
|
56
|
+
private getRowByIndex;
|
|
57
|
+
}
|
|
@@ -8,6 +8,7 @@ import { Column, TableParams, ColumnSorter } from './table.types';
|
|
|
8
8
|
* @exampleComponent limel-example-table-local
|
|
9
9
|
* @exampleComponent limel-example-table-remote
|
|
10
10
|
* @exampleComponent limel-example-table-activate-row
|
|
11
|
+
* @exampleComponent limel-example-table-selectable-rows
|
|
11
12
|
* @exampleComponent limel-example-table-default-sorted
|
|
12
13
|
* @exampleComponent limel-example-table-low-density
|
|
13
14
|
*/
|
|
@@ -67,6 +68,14 @@ export declare class Table {
|
|
|
67
68
|
* A message to display when the table has no data
|
|
68
69
|
*/
|
|
69
70
|
emptyMessage: string;
|
|
71
|
+
/**
|
|
72
|
+
* Enables row selection
|
|
73
|
+
*/
|
|
74
|
+
selectable: boolean;
|
|
75
|
+
/**
|
|
76
|
+
* Selected data. Requires `selectable` to be true.
|
|
77
|
+
*/
|
|
78
|
+
selection: object[];
|
|
70
79
|
/**
|
|
71
80
|
* Emitted when `mode` is `remote` and the table is loading new data. The
|
|
72
81
|
* consumer is responsible for giving the table new data
|
|
@@ -80,6 +89,14 @@ export declare class Table {
|
|
|
80
89
|
* Emitted when the columns have been changed
|
|
81
90
|
*/
|
|
82
91
|
changeColumns: EventEmitter<Column[]>;
|
|
92
|
+
/**
|
|
93
|
+
* Emitted when the row selection has been changed
|
|
94
|
+
*/
|
|
95
|
+
select: EventEmitter<object[]>;
|
|
96
|
+
/**
|
|
97
|
+
* Emitted when the select all rows state is toggled
|
|
98
|
+
*/
|
|
99
|
+
selectAll: EventEmitter<boolean>;
|
|
83
100
|
private host;
|
|
84
101
|
private currentLoad;
|
|
85
102
|
private tabulator;
|
|
@@ -87,19 +104,22 @@ export declare class Table {
|
|
|
87
104
|
private columnFactory;
|
|
88
105
|
private firstRequest;
|
|
89
106
|
private currentSorting;
|
|
107
|
+
private tableSelection;
|
|
90
108
|
constructor();
|
|
91
109
|
componentWillLoad(): void;
|
|
92
110
|
componentDidLoad(): void;
|
|
93
111
|
disconnectedCallback(): void;
|
|
94
|
-
totalRowsChanged(): void;
|
|
95
|
-
pageSizeChanged(): void;
|
|
96
|
-
pageChanged(): void;
|
|
97
|
-
activeRowChanged(): void;
|
|
98
|
-
updateData(newData?: any[], oldData?: any[]): void;
|
|
99
|
-
updateColumns(newColumns: Column[], oldColumns: Column[]): void;
|
|
112
|
+
protected totalRowsChanged(): void;
|
|
113
|
+
protected pageSizeChanged(): void;
|
|
114
|
+
protected pageChanged(): void;
|
|
115
|
+
protected activeRowChanged(): void;
|
|
116
|
+
protected updateData(newData?: any[], oldData?: any[]): void;
|
|
117
|
+
protected updateColumns(newColumns: Column[], oldColumns: Column[]): void;
|
|
118
|
+
protected updateSelection(newSelection: any[]): void;
|
|
100
119
|
private areSameColumns;
|
|
101
120
|
private init;
|
|
102
121
|
private initTabulatorComponent;
|
|
122
|
+
private setSelection;
|
|
103
123
|
private updateMaxPage;
|
|
104
124
|
private getOptions;
|
|
105
125
|
private getColumnSorter;
|
|
@@ -112,6 +132,10 @@ export declare class Table {
|
|
|
112
132
|
private handleDataSorting;
|
|
113
133
|
private handlePageLoaded;
|
|
114
134
|
private onClickRow;
|
|
135
|
+
private getActiveRows;
|
|
136
|
+
private getActiveRowsData;
|
|
137
|
+
private selectAllOnChange;
|
|
138
|
+
private formatRows;
|
|
115
139
|
private formatRow;
|
|
116
140
|
private calculatePageCount;
|
|
117
141
|
private hasAggregation;
|
|
@@ -119,5 +143,6 @@ export declare class Table {
|
|
|
119
143
|
private handleMoveColumn;
|
|
120
144
|
private findColumn;
|
|
121
145
|
render(): any;
|
|
146
|
+
private renderSelectAll;
|
|
122
147
|
private renderEmptyMessage;
|
|
123
148
|
}
|
|
@@ -997,6 +997,14 @@ export namespace Components {
|
|
|
997
997
|
* Number of rows per page
|
|
998
998
|
*/
|
|
999
999
|
"pageSize": number;
|
|
1000
|
+
/**
|
|
1001
|
+
* Enables row selection
|
|
1002
|
+
*/
|
|
1003
|
+
"selectable": boolean;
|
|
1004
|
+
/**
|
|
1005
|
+
* Selected data. Requires `selectable` to be true.
|
|
1006
|
+
*/
|
|
1007
|
+
"selection": object[];
|
|
1000
1008
|
/**
|
|
1001
1009
|
* The initial sorted columns
|
|
1002
1010
|
*/
|
|
@@ -2478,6 +2486,14 @@ declare namespace LocalJSX {
|
|
|
2478
2486
|
* Emitted when `mode` is `remote` and the table is loading new data. The consumer is responsible for giving the table new data
|
|
2479
2487
|
*/
|
|
2480
2488
|
"onLoad"?: (event: CustomEvent<TableParams>) => void;
|
|
2489
|
+
/**
|
|
2490
|
+
* Emitted when the row selection has been changed
|
|
2491
|
+
*/
|
|
2492
|
+
"onSelect"?: (event: CustomEvent<object[]>) => void;
|
|
2493
|
+
/**
|
|
2494
|
+
* Emitted when the select all rows state is toggled
|
|
2495
|
+
*/
|
|
2496
|
+
"onSelectAll"?: (event: CustomEvent<boolean>) => void;
|
|
2481
2497
|
/**
|
|
2482
2498
|
* Emitted when `mode` is `local` the data is sorted
|
|
2483
2499
|
*/
|
|
@@ -2490,6 +2506,14 @@ declare namespace LocalJSX {
|
|
|
2490
2506
|
* Number of rows per page
|
|
2491
2507
|
*/
|
|
2492
2508
|
"pageSize"?: number;
|
|
2509
|
+
/**
|
|
2510
|
+
* Enables row selection
|
|
2511
|
+
*/
|
|
2512
|
+
"selectable"?: boolean;
|
|
2513
|
+
/**
|
|
2514
|
+
* Selected data. Requires `selectable` to be true.
|
|
2515
|
+
*/
|
|
2516
|
+
"selection"?: object[];
|
|
2493
2517
|
/**
|
|
2494
2518
|
* The initial sorted columns
|
|
2495
2519
|
*/
|