You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

1 lines
136 KiB

{"version":3,"file":"slider.mjs","sources":["../../../../../darwin_arm64-fastbuild-ST-fdfa778d11ba/bin/src/material/slider/slider-interface.ts","../../../../../darwin_arm64-fastbuild-ST-fdfa778d11ba/bin/src/material/slider/slider-thumb.ts","../../../../../darwin_arm64-fastbuild-ST-fdfa778d11ba/bin/src/material/slider/slider-thumb.html","../../../../../darwin_arm64-fastbuild-ST-fdfa778d11ba/bin/src/material/slider/slider.ts","../../../../../darwin_arm64-fastbuild-ST-fdfa778d11ba/bin/src/material/slider/slider.html","../../../../../darwin_arm64-fastbuild-ST-fdfa778d11ba/bin/src/material/slider/slider-input.ts","../../../../../darwin_arm64-fastbuild-ST-fdfa778d11ba/bin/src/material/slider/slider-module.ts"],"sourcesContent":["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {InjectionToken, ChangeDetectorRef, WritableSignal} from '@angular/core';\nimport {MatRipple, RippleGlobalOptions} from '../core';\n\n/**\n * Thumb types: range slider has two thumbs (START, END) whereas single point\n * slider only has one thumb (END).\n */\nexport enum _MatThumb {\n START = 1,\n END = 2,\n}\n\n/** Tick mark enum, for discrete sliders. */\nexport enum _MatTickMark {\n ACTIVE = 0,\n INACTIVE = 1,\n}\n\n/**\n * Injection token that can be used for a `MatSlider` to provide itself as a\n * parent to the `MatSliderThumb` and `MatSliderRangeThumb`.\n * Used primarily to avoid circular imports.\n * @docs-private\n */\nexport const MAT_SLIDER = new InjectionToken<{}>('_MatSlider');\n\n/**\n * Injection token that can be used to query for a `MatSliderThumb`.\n * Used primarily to avoid circular imports.\n * @docs-private\n */\nexport const MAT_SLIDER_THUMB = new InjectionToken<{}>('_MatSliderThumb');\n\n/**\n * Injection token that can be used to query for a `MatSliderRangeThumb`.\n * Used primarily to avoid circular imports.\n * @docs-private\n */\nexport const MAT_SLIDER_RANGE_THUMB = new InjectionToken<{}>('_MatSliderRangeThumb');\n\n/**\n * Injection token that can be used to query for a `MatSliderVisualThumb`.\n * Used primarily to avoid circular imports.\n * @docs-private\n */\nexport const MAT_SLIDER_VISUAL_THUMB = new InjectionToken<{}>('_MatSliderVisualThumb');\n\n/** Represents a drag event emitted by the MatSlider component. */\nexport interface MatSliderDragEvent {\n /** The MatSliderThumb that was interacted with. */\n source: _MatSliderThumb;\n\n /** The MatSlider that was interacted with. */\n parent: _MatSlider;\n\n /** The current value of the slider. */\n value: number;\n}\n\n/**\n * A simple change event emitted by the MatSlider component.\n * @deprecated Use event bindings directly on the MatSliderThumbs for `change` and `input` events. See https://v17.material.angular.dev/guide/mdc-migration for information about migrating.\n * @breaking-change 17.0.0\n */\nexport class MatSliderChange {\n /** The MatSliderThumb that was interacted with. */\n source!: _MatSliderThumb;\n\n /** The MatSlider that was interacted with. */\n parent!: _MatSlider;\n\n /** The new value of the source slider. */\n value!: number;\n}\n\nexport interface _MatSlider {\n /** Whether the given pointer event occurred within the bounds of the slider pointer's DOM Rect. */\n _isCursorOnSliderThumb(event: PointerEvent, rect: DOMRect): boolean;\n\n /** Gets the slider thumb input of the given thumb position. */\n _getInput(thumbPosition: _MatThumb): _MatSliderThumb | _MatSliderRangeThumb | undefined;\n\n /** Gets the slider thumb HTML input element of the given thumb position. */\n _getThumb(thumbPosition: _MatThumb): _MatSliderVisualThumb;\n\n /** The minimum value that the slider can have. */\n min: number;\n\n /** The maximum value that the slider can have. */\n max: number;\n\n /** The amount that slider values can increment or decrement by. */\n step: number;\n\n /** Whether the slider is disabled. */\n disabled: boolean;\n\n /** Whether the slider is a range slider. */\n _isRange: boolean;\n\n /** Whether the slider is rtl. */\n _isRtl: boolean;\n\n /** The stored width of the host element's bounding client rect. */\n _cachedWidth: number;\n\n /** The stored width of the host element's bounding client rect. */\n _cachedLeft: number;\n\n /**\n * The padding of the native slider input. This is added in order to make the region where the\n * thumb ripple extends past the end of the slider track clickable.\n */\n _inputPadding: number;\n\n /** The radius of the visual slider's ripple. */\n _rippleRadius: number;\n\n /** The global configuration for `matRipple` instances. */\n readonly _globalRippleOptions: RippleGlobalOptions | null;\n\n /** Whether animations have been disabled. */\n _noopAnimations: boolean;\n\n /** Whether or not the slider should use animations. */\n _hasAnimation: boolean;\n\n /** Triggers UI updates that are needed after a slider input value has changed. */\n _onValueChange: (source: _MatSliderThumb) => void;\n\n /** Triggers UI updates that are needed after the slider thumb position has changed. */\n _onTranslateXChange: (source: _MatSliderThumb) => void;\n\n /** Updates the stored slider dimensions using the current bounding client rect. */\n _updateDimensions: () => void;\n\n /** Updates the scale on the active portion of the track. */\n _updateTrackUI: (source: _MatSliderThumb) => void;\n\n /** Used to set the transition duration for thumb and track animations. */\n _setTransition: (withAnimation: boolean) => void;\n\n _cdr: ChangeDetectorRef;\n}\n\nexport interface _MatSliderThumb {\n /** The minimum value that the slider can have. */\n min: number;\n\n /** The maximum value that the slider can have. */\n max: number;\n\n /** The amount that slider values can increment or decrement by. */\n step: number;\n\n /** The current value of this slider input. */\n value: number;\n\n /** The current translateX in px of the slider visual thumb. */\n translateX: number;\n\n /** Indicates whether this thumb is the start or end thumb. */\n thumbPosition: _MatThumb;\n\n /** Similar to percentage but calcualted using translateX relative to the total track width. */\n fillPercentage: number;\n\n /** Whether the slider is disabled. */\n disabled: boolean;\n\n /** The host native HTML input element. */\n _hostElement: HTMLInputElement;\n\n /** Whether the input is currently focused (either by tab or after clicking). */\n _isFocused: boolean;\n\n /** The aria-valuetext string representation of the input's value. */\n _valuetext: WritableSignal<string>;\n\n /**\n * Indicates whether UI updates should be skipped.\n *\n * This flag is used to avoid flickering\n * when correcting values on pointer up/down.\n */\n _skipUIUpdate: boolean;\n\n /** Handles the initialization of properties for the slider input. */\n initProps: () => void;\n\n /** Handles UI initialization controlled by this slider input. */\n initUI: () => void;\n\n /** Calculates the visual thumb's translateX based on the slider input's current value. */\n _calcTranslateXByValue: () => number;\n\n /** Updates the visual thumb based on the slider input's current value. */\n _updateThumbUIByValue: () => void;\n\n /**\n * Sets the slider input to disproportionate dimensions to allow for touch\n * events to be captured on touch devices.\n */\n _updateWidthInactive: () => void;\n\n /**\n * Used to set the slider width to the correct\n * dimensions while the user is dragging.\n */\n _updateWidthActive: () => void;\n}\n\nexport interface _MatSliderRangeThumb extends _MatSliderThumb {\n /** Whether this slider corresponds to the input on the left hand side. */\n _isLeftThumb: boolean;\n\n /**\n * Gets the sibling MatSliderRangeThumb.\n * Returns undefined if it is too early in Angular's life cycle.\n */\n getSibling: () => _MatSliderRangeThumb | undefined;\n\n /** Used to cache whether this slider input corresponds to the visual left thumb. */\n _setIsLeftThumb: () => void;\n\n /** Updates the input styles to control whether it is pinned to the start or end of the mat-slider. */\n _updateStaticStyles: () => void;\n\n /** Updates the min and max properties of this slider input according to it's sibling. */\n _updateMinMax: () => void;\n}\n\nexport interface _MatSliderVisualThumb {\n /** The MatRipple for this slider thumb. */\n _ripple: MatRipple;\n\n /** Whether the slider thumb is currently being pressed. */\n _isActive: boolean;\n\n /** The host native HTML input element. */\n _hostElement: HTMLElement;\n\n /** Shows the value indicator ui. */\n _showValueIndicator: () => void;\n\n /** Hides the value indicator ui. */\n _hideValueIndicator: () => void;\n\n /** Whether the slider visual thumb is currently showing any ripple. */\n _isShowingAnyRipple: () => boolean;\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {\n AfterViewInit,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ElementRef,\n Input,\n NgZone,\n OnDestroy,\n Renderer2,\n ViewChild,\n ViewEncapsulation,\n inject,\n} from '@angular/core';\nimport {MatRipple, RippleAnimationConfig, RippleRef, RippleState} from '../core';\nimport {\n _MatThumb,\n _MatSlider,\n _MatSliderThumb,\n _MatSliderVisualThumb,\n MAT_SLIDER,\n MAT_SLIDER_VISUAL_THUMB,\n} from './slider-interface';\nimport {Platform} from '@angular/cdk/platform';\n\n/**\n * The visual slider thumb.\n *\n * Handles the slider thumb ripple states (hover, focus, and active),\n * and displaying the value tooltip on discrete sliders.\n * @docs-private\n */\n@Component({\n selector: 'mat-slider-visual-thumb',\n templateUrl: './slider-thumb.html',\n styleUrl: 'slider-thumb.css',\n host: {\n 'class': 'mdc-slider__thumb mat-mdc-slider-visual-thumb',\n },\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n providers: [{provide: MAT_SLIDER_VISUAL_THUMB, useExisting: MatSliderVisualThumb}],\n imports: [MatRipple],\n})\nexport class MatSliderVisualThumb implements _MatSliderVisualThumb, AfterViewInit, OnDestroy {\n readonly _cdr = inject(ChangeDetectorRef);\n private readonly _ngZone = inject(NgZone);\n private _slider = inject<_MatSlider>(MAT_SLIDER);\n private _renderer = inject(Renderer2);\n private _listenerCleanups: (() => void)[] | undefined;\n\n /** Whether the slider displays a numeric value label upon pressing the thumb. */\n @Input() discrete: boolean = false;\n\n /** Indicates which slider thumb this input corresponds to. */\n @Input() thumbPosition!: _MatThumb;\n\n /** The display value of the slider thumb. */\n @Input() valueIndicatorText!: string;\n\n /** The MatRipple for this slider thumb. */\n @ViewChild(MatRipple) readonly _ripple!: MatRipple;\n\n /** The slider thumb knob. */\n @ViewChild('knob') _knob!: ElementRef<HTMLElement>;\n\n /** The slider thumb value indicator container. */\n @ViewChild('valueIndicatorContainer')\n _valueIndicatorContainer!: ElementRef<HTMLElement>;\n\n /** The slider input corresponding to this slider thumb. */\n private _sliderInput!: _MatSliderThumb;\n\n /** The native html element of the slider input corresponding to this thumb. */\n private _sliderInputEl: HTMLInputElement | undefined;\n\n /** The RippleRef for the slider thumbs hover state. */\n private _hoverRippleRef: RippleRef | undefined;\n\n /** The RippleRef for the slider thumbs focus state. */\n private _focusRippleRef: RippleRef | undefined;\n\n /** The RippleRef for the slider thumbs active state. */\n private _activeRippleRef: RippleRef | undefined;\n\n /** Whether the slider thumb is currently being hovered. */\n private _isHovered: boolean = false;\n\n /** Whether the slider thumb is currently being pressed. */\n _isActive = false;\n\n /** Whether the value indicator tooltip is visible. */\n _isValueIndicatorVisible: boolean = false;\n\n /** The host native HTML input element. */\n _hostElement = inject<ElementRef<HTMLElement>>(ElementRef).nativeElement;\n\n private _platform = inject(Platform);\n\n constructor(...args: unknown[]);\n constructor() {}\n\n ngAfterViewInit() {\n const sliderInput = this._slider._getInput(this.thumbPosition);\n\n // No-op if the slider isn't configured properly. `MatSlider` will\n // throw an error instructing the user how to set up the slider.\n if (!sliderInput) {\n return;\n }\n\n this._ripple.radius = 24;\n this._sliderInput = sliderInput;\n this._sliderInputEl = this._sliderInput._hostElement;\n\n // These listeners don't update any data bindings so we bind them outside\n // of the NgZone to prevent Angular from needlessly running change detection.\n this._ngZone.runOutsideAngular(() => {\n const input = this._sliderInputEl!;\n const renderer = this._renderer;\n this._listenerCleanups = [\n renderer.listen(input, 'pointermove', this._onPointerMove),\n renderer.listen(input, 'pointerdown', this._onDragStart),\n renderer.listen(input, 'pointerup', this._onDragEnd),\n renderer.listen(input, 'pointerleave', this._onMouseLeave),\n renderer.listen(input, 'focus', this._onFocus),\n renderer.listen(input, 'blur', this._onBlur),\n ];\n });\n }\n\n ngOnDestroy() {\n this._listenerCleanups?.forEach(cleanup => cleanup());\n }\n\n private _onPointerMove = (event: PointerEvent): void => {\n if (this._sliderInput._isFocused) {\n return;\n }\n\n const rect = this._hostElement.getBoundingClientRect();\n const isHovered = this._slider._isCursorOnSliderThumb(event, rect);\n this._isHovered = isHovered;\n\n if (isHovered) {\n this._showHoverRipple();\n } else {\n this._hideRipple(this._hoverRippleRef);\n }\n };\n\n private _onMouseLeave = (): void => {\n this._isHovered = false;\n this._hideRipple(this._hoverRippleRef);\n };\n\n private _onFocus = (): void => {\n // We don't want to show the hover ripple on top of the focus ripple.\n // Happen when the users cursor is over a thumb and then the user tabs to it.\n this._hideRipple(this._hoverRippleRef);\n this._showFocusRipple();\n this._hostElement.classList.add('mdc-slider__thumb--focused');\n };\n\n private _onBlur = (): void => {\n // Happens when the user tabs away while still dragging a thumb.\n if (!this._isActive) {\n this._hideRipple(this._focusRippleRef);\n }\n // Happens when the user tabs away from a thumb but their cursor is still over it.\n if (this._isHovered) {\n this._showHoverRipple();\n }\n this._hostElement.classList.remove('mdc-slider__thumb--focused');\n };\n\n private _onDragStart = (event: PointerEvent): void => {\n if (event.button !== 0) {\n return;\n }\n this._isActive = true;\n this._showActiveRipple();\n };\n\n private _onDragEnd = (): void => {\n this._isActive = false;\n this._hideRipple(this._activeRippleRef);\n // Happens when the user starts dragging a thumb, tabs away, and then stops dragging.\n if (!this._sliderInput._isFocused) {\n this._hideRipple(this._focusRippleRef);\n }\n\n // On Safari we need to immediately re-show the hover ripple because\n // sliders do not retain focus from pointer events on that platform.\n if (this._platform.SAFARI) {\n this._showHoverRipple();\n }\n };\n\n /** Handles displaying the hover ripple. */\n private _showHoverRipple(): void {\n if (!this._isShowingRipple(this._hoverRippleRef)) {\n this._hoverRippleRef = this._showRipple({enterDuration: 0, exitDuration: 0});\n this._hoverRippleRef?.element.classList.add('mat-mdc-slider-hover-ripple');\n }\n }\n\n /** Handles displaying the focus ripple. */\n private _showFocusRipple(): void {\n // Show the focus ripple event if noop animations are enabled.\n if (!this._isShowingRipple(this._focusRippleRef)) {\n this._focusRippleRef = this._showRipple({enterDuration: 0, exitDuration: 0}, true);\n this._focusRippleRef?.element.classList.add('mat-mdc-slider-focus-ripple');\n }\n }\n\n /** Handles displaying the active ripple. */\n private _showActiveRipple(): void {\n if (!this._isShowingRipple(this._activeRippleRef)) {\n this._activeRippleRef = this._showRipple({enterDuration: 225, exitDuration: 400});\n this._activeRippleRef?.element.classList.add('mat-mdc-slider-active-ripple');\n }\n }\n\n /** Whether the given rippleRef is currently fading in or visible. */\n private _isShowingRipple(rippleRef?: RippleRef): boolean {\n return rippleRef?.state === RippleState.FADING_IN || rippleRef?.state === RippleState.VISIBLE;\n }\n\n /** Manually launches the slider thumb ripple using the specified ripple animation config. */\n private _showRipple(\n animation: RippleAnimationConfig,\n ignoreGlobalRippleConfig?: boolean,\n ): RippleRef | undefined {\n if (this._slider.disabled) {\n return;\n }\n this._showValueIndicator();\n if (this._slider._isRange) {\n const sibling = this._slider._getThumb(\n this.thumbPosition === _MatThumb.START ? _MatThumb.END : _MatThumb.START,\n );\n sibling._showValueIndicator();\n }\n if (this._slider._globalRippleOptions?.disabled && !ignoreGlobalRippleConfig) {\n return;\n }\n return this._ripple.launch({\n animation: this._slider._noopAnimations ? {enterDuration: 0, exitDuration: 0} : animation,\n centered: true,\n persistent: true,\n });\n }\n\n /**\n * Fades out the given ripple.\n * Also hides the value indicator if no ripple is showing.\n */\n private _hideRipple(rippleRef?: RippleRef): void {\n rippleRef?.fadeOut();\n\n if (this._isShowingAnyRipple()) {\n return;\n }\n\n if (!this._slider._isRange) {\n this._hideValueIndicator();\n }\n\n const sibling = this._getSibling();\n if (!sibling._isShowingAnyRipple()) {\n this._hideValueIndicator();\n sibling._hideValueIndicator();\n }\n }\n\n /** Shows the value indicator ui. */\n _showValueIndicator(): void {\n this._hostElement.classList.add('mdc-slider__thumb--with-indicator');\n }\n\n /** Hides the value indicator ui. */\n _hideValueIndicator(): void {\n this._hostElement.classList.remove('mdc-slider__thumb--with-indicator');\n }\n\n _getSibling(): _MatSliderVisualThumb {\n return this._slider._getThumb(\n this.thumbPosition === _MatThumb.START ? _MatThumb.END : _MatThumb.START,\n );\n }\n\n /** Gets the value indicator container's native HTML element. */\n _getValueIndicatorContainer(): HTMLElement | undefined {\n return this._valueIndicatorContainer?.nativeElement;\n }\n\n /** Gets the native HTML element of the slider thumb knob. */\n _getKnob(): HTMLElement {\n return this._knob.nativeElement;\n }\n\n _isShowingAnyRipple(): boolean {\n return (\n this._isShowingRipple(this._hoverRippleRef) ||\n this._isShowingRipple(this._focusRippleRef) ||\n this._isShowingRipple(this._activeRippleRef)\n );\n }\n}\n","@if (discrete) {\n <div class=\"mdc-slider__value-indicator-container\" #valueIndicatorContainer>\n <div class=\"mdc-slider__value-indicator\">\n <span class=\"mdc-slider__value-indicator-text\">{{valueIndicatorText}}</span>\n </div>\n </div>\n}\n<div class=\"mdc-slider__thumb-knob\" #knob></div>\n<div matRipple class=\"mat-focus-indicator\" [matRippleDisabled]=\"true\"></div>\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {Directionality} from '@angular/cdk/bidi';\nimport {Platform} from '@angular/cdk/platform';\nimport {\n AfterViewInit,\n booleanAttribute,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ContentChild,\n ContentChildren,\n ElementRef,\n inject,\n Input,\n NgZone,\n numberAttribute,\n OnDestroy,\n QueryList,\n ViewChild,\n ViewChildren,\n ViewEncapsulation,\n} from '@angular/core';\nimport {\n _animationsDisabled,\n _StructuralStylesLoader,\n MAT_RIPPLE_GLOBAL_OPTIONS,\n RippleGlobalOptions,\n ThemePalette,\n} from '../core';\nimport {Subscription} from 'rxjs';\nimport {\n _MatThumb,\n _MatTickMark,\n _MatSlider,\n _MatSliderRangeThumb,\n _MatSliderThumb,\n _MatSliderVisualThumb,\n MAT_SLIDER_RANGE_THUMB,\n MAT_SLIDER_THUMB,\n MAT_SLIDER,\n MAT_SLIDER_VISUAL_THUMB,\n} from './slider-interface';\nimport {MatSliderVisualThumb} from './slider-thumb';\nimport {_CdkPrivateStyleLoader} from '@angular/cdk/private';\n\n// TODO(wagnermaciel): maybe handle the following edge case:\n// 1. start dragging discrete slider\n// 2. tab to disable checkbox\n// 3. without ending drag, disable the slider\n\n/**\n * Allows users to select from a range of values by moving the slider thumb. It is similar in\n * behavior to the native `<input type=\"range\">` element.\n */\n@Component({\n selector: 'mat-slider',\n templateUrl: 'slider.html',\n styleUrl: 'slider.css',\n host: {\n 'class': 'mat-mdc-slider mdc-slider',\n '[class]': '\"mat-\" + (color || \"primary\")',\n '[class.mdc-slider--range]': '_isRange',\n '[class.mdc-slider--disabled]': 'disabled',\n '[class.mdc-slider--discrete]': 'discrete',\n '[class.mdc-slider--tick-marks]': 'showTickMarks',\n '[class._mat-animation-noopable]': '_noopAnimations',\n },\n exportAs: 'matSlider',\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n providers: [{provide: MAT_SLIDER, useExisting: MatSlider}],\n imports: [MatSliderVisualThumb],\n})\nexport class MatSlider implements AfterViewInit, OnDestroy, _MatSlider {\n readonly _ngZone = inject(NgZone);\n readonly _cdr = inject(ChangeDetectorRef);\n readonly _elementRef = inject<ElementRef<HTMLElement>>(ElementRef);\n readonly _dir = inject(Directionality, {optional: true});\n readonly _globalRippleOptions = inject<RippleGlobalOptions>(MAT_RIPPLE_GLOBAL_OPTIONS, {\n optional: true,\n });\n\n /** The active portion of the slider track. */\n @ViewChild('trackActive') _trackActive!: ElementRef<HTMLElement>;\n\n /** The slider thumb(s). */\n @ViewChildren(MAT_SLIDER_VISUAL_THUMB) _thumbs!: QueryList<_MatSliderVisualThumb>;\n\n /** The sliders hidden range input(s). */\n @ContentChild(MAT_SLIDER_THUMB) _input!: _MatSliderThumb;\n\n /** The sliders hidden range input(s). */\n @ContentChildren(MAT_SLIDER_RANGE_THUMB, {descendants: false})\n _inputs!: QueryList<_MatSliderRangeThumb>;\n\n /** Whether the slider is disabled. */\n @Input({transform: booleanAttribute})\n get disabled(): boolean {\n return this._disabled;\n }\n set disabled(v: boolean) {\n this._disabled = v;\n const endInput = this._getInput(_MatThumb.END);\n const startInput = this._getInput(_MatThumb.START);\n\n if (endInput) {\n endInput.disabled = this._disabled;\n }\n if (startInput) {\n startInput.disabled = this._disabled;\n }\n }\n private _disabled: boolean = false;\n\n /** Whether the slider displays a numeric value label upon pressing the thumb. */\n @Input({transform: booleanAttribute})\n get discrete(): boolean {\n return this._discrete;\n }\n set discrete(v: boolean) {\n this._discrete = v;\n this._updateValueIndicatorUIs();\n }\n private _discrete: boolean = false;\n\n /** Whether the slider displays tick marks along the slider track. */\n @Input({transform: booleanAttribute})\n get showTickMarks(): boolean {\n return this._showTickMarks;\n }\n set showTickMarks(value: boolean) {\n this._showTickMarks = value;\n\n if (this._hasViewInitialized) {\n this._updateTickMarkUI();\n this._updateTickMarkTrackUI();\n }\n }\n private _showTickMarks: boolean = false;\n\n /** The minimum value that the slider can have. */\n @Input({transform: numberAttribute})\n get min(): number {\n return this._min;\n }\n set min(v: number) {\n const min = v === undefined || v === null || isNaN(v) ? this._min : v;\n if (this._min !== min) {\n this._updateMin(min);\n }\n }\n private _min: number = 0;\n\n /**\n * Theme color of the slider. This API is supported in M2 themes only, it\n * has no effect in M3 themes. For color customization in M3, see https://material.angular.dev/components/slider/styling.\n *\n * For information on applying color variants in M3, see\n * https://material.angular.dev/guide/material-2-theming#optional-add-backwards-compatibility-styles-for-color-variants\n */\n @Input()\n color: ThemePalette;\n\n /** Whether ripples are disabled in the slider. */\n @Input({transform: booleanAttribute})\n disableRipple: boolean = false;\n\n private _updateMin(min: number): void {\n const prevMin = this._min;\n this._min = min;\n this._isRange ? this._updateMinRange({old: prevMin, new: min}) : this._updateMinNonRange(min);\n this._onMinMaxOrStepChange();\n }\n\n private _updateMinRange(min: {old: number; new: number}): void {\n const endInput = this._getInput(_MatThumb.END) as _MatSliderRangeThumb;\n const startInput = this._getInput(_MatThumb.START) as _MatSliderRangeThumb;\n\n const oldEndValue = endInput.value;\n const oldStartValue = startInput.value;\n\n startInput.min = min.new;\n endInput.min = Math.max(min.new, startInput.value);\n startInput.max = Math.min(endInput.max, endInput.value);\n\n startInput._updateWidthInactive();\n endInput._updateWidthInactive();\n\n min.new < min.old\n ? this._onTranslateXChangeBySideEffect(endInput, startInput)\n : this._onTranslateXChangeBySideEffect(startInput, endInput);\n\n if (oldEndValue !== endInput.value) {\n this._onValueChange(endInput);\n }\n\n if (oldStartValue !== startInput.value) {\n this._onValueChange(startInput);\n }\n }\n\n private _updateMinNonRange(min: number): void {\n const input = this._getInput(_MatThumb.END);\n if (input) {\n const oldValue = input.value;\n\n input.min = min;\n input._updateThumbUIByValue();\n this._updateTrackUI(input);\n\n if (oldValue !== input.value) {\n this._onValueChange(input);\n }\n }\n }\n\n /** The maximum value that the slider can have. */\n @Input({transform: numberAttribute})\n get max(): number {\n return this._max;\n }\n set max(v: number) {\n const max = v === undefined || v === null || isNaN(v) ? this._max : v;\n if (this._max !== max) {\n this._updateMax(max);\n }\n }\n private _max: number = 100;\n\n private _updateMax(max: number): void {\n const prevMax = this._max;\n this._max = max;\n this._isRange ? this._updateMaxRange({old: prevMax, new: max}) : this._updateMaxNonRange(max);\n this._onMinMaxOrStepChange();\n }\n\n private _updateMaxRange(max: {old: number; new: number}): void {\n const endInput = this._getInput(_MatThumb.END) as _MatSliderRangeThumb;\n const startInput = this._getInput(_MatThumb.START) as _MatSliderRangeThumb;\n\n const oldEndValue = endInput.value;\n const oldStartValue = startInput.value;\n\n endInput.max = max.new;\n startInput.max = Math.min(max.new, endInput.value);\n endInput.min = startInput.value;\n\n endInput._updateWidthInactive();\n startInput._updateWidthInactive();\n\n max.new > max.old\n ? this._onTranslateXChangeBySideEffect(startInput, endInput)\n : this._onTranslateXChangeBySideEffect(endInput, startInput);\n\n if (oldEndValue !== endInput.value) {\n this._onValueChange(endInput);\n }\n\n if (oldStartValue !== startInput.value) {\n this._onValueChange(startInput);\n }\n }\n\n private _updateMaxNonRange(max: number): void {\n const input = this._getInput(_MatThumb.END);\n if (input) {\n const oldValue = input.value;\n\n input.max = max;\n input._updateThumbUIByValue();\n this._updateTrackUI(input);\n\n if (oldValue !== input.value) {\n this._onValueChange(input);\n }\n }\n }\n\n /** The values at which the thumb will snap. */\n @Input({transform: numberAttribute})\n get step(): number {\n return this._step;\n }\n set step(v: number) {\n const step = isNaN(v) ? this._step : v;\n if (this._step !== step) {\n this._updateStep(step);\n }\n }\n private _step: number = 1;\n\n private _updateStep(step: number): void {\n this._step = step;\n this._isRange ? this._updateStepRange() : this._updateStepNonRange();\n this._onMinMaxOrStepChange();\n }\n\n private _updateStepRange(): void {\n const endInput = this._getInput(_MatThumb.END) as _MatSliderRangeThumb;\n const startInput = this._getInput(_MatThumb.START) as _MatSliderRangeThumb;\n\n const oldEndValue = endInput.value;\n const oldStartValue = startInput.value;\n\n const prevStartValue = startInput.value;\n\n endInput.min = this._min;\n startInput.max = this._max;\n\n endInput.step = this._step;\n startInput.step = this._step;\n\n if (this._platform.SAFARI) {\n endInput.value = endInput.value;\n startInput.value = startInput.value;\n }\n\n endInput.min = Math.max(this._min, startInput.value);\n startInput.max = Math.min(this._max, endInput.value);\n\n startInput._updateWidthInactive();\n endInput._updateWidthInactive();\n\n endInput.value < prevStartValue\n ? this._onTranslateXChangeBySideEffect(startInput, endInput)\n : this._onTranslateXChangeBySideEffect(endInput, startInput);\n\n if (oldEndValue !== endInput.value) {\n this._onValueChange(endInput);\n }\n\n if (oldStartValue !== startInput.value) {\n this._onValueChange(startInput);\n }\n }\n\n private _updateStepNonRange(): void {\n const input = this._getInput(_MatThumb.END);\n if (input) {\n const oldValue = input.value;\n\n input.step = this._step;\n if (this._platform.SAFARI) {\n input.value = input.value;\n }\n\n input._updateThumbUIByValue();\n\n if (oldValue !== input.value) {\n this._onValueChange(input);\n }\n }\n }\n\n /**\n * Function that will be used to format the value before it is displayed\n * in the thumb label. Can be used to format very large number in order\n * for them to fit into the slider thumb.\n */\n @Input() displayWith: (value: number) => string = (value: number) => `${value}`;\n\n /** Used to keep track of & render the active & inactive tick marks on the slider track. */\n _tickMarks!: _MatTickMark[];\n\n /** Whether animations have been disabled. */\n _noopAnimations = _animationsDisabled();\n\n /** Subscription to changes to the directionality (LTR / RTL) context for the application. */\n private _dirChangeSubscription: Subscription | undefined;\n\n /** Observer used to monitor size changes in the slider. */\n private _resizeObserver: ResizeObserver | null = null;\n\n // Stored dimensions to avoid calling getBoundingClientRect redundantly.\n\n _cachedWidth!: number;\n _cachedLeft!: number;\n\n _rippleRadius: number = 24;\n\n // The value indicator tooltip text for the visual slider thumb(s).\n\n /** @docs-private */\n protected startValueIndicatorText: string = '';\n\n /** @docs-private */\n protected endValueIndicatorText: string = '';\n\n // Used to control the translateX of the visual slider thumb(s).\n\n _endThumbTransform!: string;\n _startThumbTransform!: string;\n\n _isRange: boolean = false;\n\n /** Whether the slider is rtl. */\n _isRtl: boolean = false;\n\n private _hasViewInitialized: boolean = false;\n\n /**\n * The width of the tick mark track.\n * The tick mark track width is different from full track width\n */\n _tickMarkTrackWidth: number = 0;\n\n _hasAnimation: boolean = false;\n\n private _resizeTimer: null | ReturnType<typeof setTimeout> = null;\n\n private _platform = inject(Platform);\n\n constructor(...args: unknown[]);\n\n constructor() {\n inject(_CdkPrivateStyleLoader).load(_StructuralStylesLoader);\n\n if (this._dir) {\n this._dirChangeSubscription = this._dir.change.subscribe(() => this._onDirChange());\n this._isRtl = this._dir.value === 'rtl';\n }\n }\n\n /** The radius of the native slider's knob. AFAIK there is no way to avoid hardcoding this. */\n _knobRadius: number = 8;\n\n _inputPadding!: number;\n\n ngAfterViewInit(): void {\n if (this._platform.isBrowser) {\n this._updateDimensions();\n }\n\n const eInput = this._getInput(_MatThumb.END);\n const sInput = this._getInput(_MatThumb.START);\n this._isRange = !!eInput && !!sInput;\n this._cdr.detectChanges();\n\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n _validateInputs(\n this._isRange,\n this._getInput(_MatThumb.END),\n this._getInput(_MatThumb.START),\n );\n }\n\n const thumb = this._getThumb(_MatThumb.END);\n this._rippleRadius = thumb._ripple.radius;\n this._inputPadding = this._rippleRadius - this._knobRadius;\n\n this._isRange\n ? this._initUIRange(eInput as _MatSliderRangeThumb, sInput as _MatSliderRangeThumb)\n : this._initUINonRange(eInput!);\n\n this._updateTrackUI(eInput!);\n this._updateTickMarkUI();\n this._updateTickMarkTrackUI();\n\n this._observeHostResize();\n this._cdr.detectChanges();\n }\n\n private _initUINonRange(eInput: _MatSliderThumb): void {\n eInput.initProps();\n eInput.initUI();\n\n this._updateValueIndicatorUI(eInput);\n\n this._hasViewInitialized = true;\n eInput._updateThumbUIByValue();\n }\n\n private _initUIRange(eInput: _MatSliderRangeThumb, sInput: _MatSliderRangeThumb): void {\n eInput.initProps();\n eInput.initUI();\n\n sInput.initProps();\n sInput.initUI();\n\n eInput._updateMinMax();\n sInput._updateMinMax();\n\n eInput._updateStaticStyles();\n sInput._updateStaticStyles();\n\n this._updateValueIndicatorUIs();\n\n this._hasViewInitialized = true;\n\n eInput._updateThumbUIByValue();\n sInput._updateThumbUIByValue();\n }\n\n ngOnDestroy(): void {\n this._dirChangeSubscription?.unsubscribe();\n this._resizeObserver?.disconnect();\n this._resizeObserver = null;\n }\n\n /** Handles updating the slider ui after a dir change. */\n private _onDirChange(): void {\n this._isRtl = this._dir?.value === 'rtl';\n this._isRange ? this._onDirChangeRange() : this._onDirChangeNonRange();\n this._updateTickMarkUI();\n }\n\n private _onDirChangeRange(): void {\n const endInput = this._getInput(_MatThumb.END) as _MatSliderRangeThumb;\n const startInput = this._getInput(_MatThumb.START) as _MatSliderRangeThumb;\n\n endInput._setIsLeftThumb();\n startInput._setIsLeftThumb();\n\n endInput.translateX = endInput._calcTranslateXByValue();\n startInput.translateX = startInput._calcTranslateXByValue();\n\n endInput._updateStaticStyles();\n startInput._updateStaticStyles();\n\n endInput._updateWidthInactive();\n startInput._updateWidthInactive();\n\n endInput._updateThumbUIByValue();\n startInput._updateThumbUIByValue();\n }\n\n private _onDirChangeNonRange(): void {\n const input = this._getInput(_MatThumb.END)!;\n input._updateThumbUIByValue();\n }\n\n /** Starts observing and updating the slider if the host changes its size. */\n private _observeHostResize() {\n if (typeof ResizeObserver === 'undefined' || !ResizeObserver) {\n return;\n }\n\n this._ngZone.runOutsideAngular(() => {\n this._resizeObserver = new ResizeObserver(() => {\n if (this._isActive()) {\n return;\n }\n if (this._resizeTimer) {\n clearTimeout(this._resizeTimer);\n }\n this._onResize();\n });\n this._resizeObserver.observe(this._elementRef.nativeElement);\n });\n }\n\n /** Whether any of the thumbs are currently active. */\n private _isActive(): boolean {\n return this._getThumb(_MatThumb.START)._isActive || this._getThumb(_MatThumb.END)._isActive;\n }\n\n private _getValue(thumbPosition: _MatThumb = _MatThumb.END): number {\n const input = this._getInput(thumbPosition);\n if (!input) {\n return this.min;\n }\n return input.value;\n }\n\n private _skipUpdate(): boolean {\n return !!(\n this._getInput(_MatThumb.START)?._skipUIUpdate || this._getInput(_MatThumb.END)?._skipUIUpdate\n );\n }\n\n /** Stores the slider dimensions. */\n _updateDimensions(): void {\n this._cachedWidth = this._elementRef.nativeElement.offsetWidth;\n this._cachedLeft = this._elementRef.nativeElement.getBoundingClientRect().left;\n }\n\n /** Sets the styles for the active portion of the track. */\n _setTrackActiveStyles(styles: {\n left: string;\n right: string;\n transform: string;\n transformOrigin: string;\n }): void {\n const trackStyle = this._trackActive.nativeElement.style;\n\n trackStyle.left = styles.left;\n trackStyle.right = styles.right;\n trackStyle.transformOrigin = styles.transformOrigin;\n trackStyle.transform = styles.transform;\n }\n\n /** Returns the translateX positioning for a tick mark based on it's index. */\n _calcTickMarkTransform(index: number): string {\n // TODO(wagnermaciel): See if we can avoid doing this and just using flex to position these.\n const offset = index * (this._tickMarkTrackWidth / (this._tickMarks.length - 1));\n const translateX = this._isRtl ? this._cachedWidth - 6 - offset : offset;\n return `translateX(${translateX}px)`;\n }\n\n // Handlers for updating the slider ui.\n\n _onTranslateXChange(source: _MatSliderThumb): void {\n if (!this._hasViewInitialized) {\n return;\n }\n\n this._updateThumbUI(source);\n this._updateTrackUI(source);\n this._updateOverlappingThumbUI(source as _MatSliderRangeThumb);\n }\n\n _onTranslateXChangeBySideEffect(\n input1: _MatSliderRangeThumb,\n input2: _MatSliderRangeThumb,\n ): void {\n if (!this._hasViewInitialized) {\n return;\n }\n\n input1._updateThumbUIByValue();\n input2._updateThumbUIByValue();\n }\n\n _onValueChange(source: _MatSliderThumb): void {\n if (!this._hasViewInitialized) {\n return;\n }\n\n this._updateValueIndicatorUI(source);\n this._updateTickMarkUI();\n this._cdr.detectChanges();\n }\n\n _onMinMaxOrStepChange(): void {\n if (!this._hasViewInitialized) {\n return;\n }\n\n this._updateTickMarkUI();\n this._updateTickMarkTrackUI();\n this._cdr.markForCheck();\n }\n\n _onResize(): void {\n if (!this._hasViewInitialized) {\n return;\n }\n\n this._updateDimensions();\n if (this._isRange) {\n const eInput = this._getInput(_MatThumb.END) as _MatSliderRangeThumb;\n const sInput = this._getInput(_MatThumb.START) as _MatSliderRangeThumb;\n\n eInput._updateThumbUIByValue();\n sInput._updateThumbUIByValue();\n\n eInput._updateStaticStyles();\n sInput._updateStaticStyles();\n\n eInput._updateMinMax();\n sInput._updateMinMax();\n\n eInput._updateWidthInactive();\n sInput._updateWidthInactive();\n } else {\n const eInput = this._getInput(_MatThumb.END);\n if (eInput) {\n eInput._updateThumbUIByValue();\n }\n }\n\n this._updateTickMarkUI();\n this._updateTickMarkTrackUI();\n this._cdr.detectChanges();\n }\n\n /** Whether or not the slider thumbs overlap. */\n private _thumbsOverlap: boolean = false;\n\n /** Returns true if the slider knobs are overlapping one another. */\n private _areThumbsOverlapping(): boolean {\n const startInput = this._getInput(_MatThumb.START);\n const endInput = this._getInput(_MatThumb.END);\n if (!startInput || !endInput) {\n return false;\n }\n return endInput.translateX - startInput.translateX < 20;\n }\n\n /**\n * Updates the class names of overlapping slider thumbs so\n * that the current active thumb is styled to be on \"top\".\n */\n private _updateOverlappingThumbClassNames(source: _MatSliderRangeThumb): void {\n const sibling = source.getSibling()!;\n const sourceThumb = this._getThumb(source.thumbPosition);\n const siblingThumb = this._getThumb(sibling.thumbPosition);\n siblingThumb._hostElement.classList.remove('mdc-slider__thumb--top');\n sourceThumb._hostElement.classList.toggle('mdc-slider__thumb--top', this._thumbsOverlap);\n }\n\n /** Updates the UI of slider thumbs when they begin or stop overlapping. */\n private _updateOverlappingThumbUI(source: _MatSliderRangeThumb): void {\n if (!this._isRange || this._skipUpdate()) {\n return;\n }\n if (this._thumbsOverlap !== this._areThumbsOverlapping()) {\n this._thumbsOverlap = !this._thumbsOverlap;\n this._updateOverlappingThumbClassNames(source);\n }\n }\n\n // _MatThumb styles update conditions\n //\n // 1. TranslateX, resize, or dir change\n // - Reason: The thumb styles need to be updated according to the new translateX.\n // 2. Min, max, or step\n // - Reason: The value may have silently changed.\n\n /** Updates the translateX of the given thumb. */\n _updateThumbUI(source: _MatSliderThumb) {\n if (this._skipUpdate()) {\n return;\n }\n const thumb = this._getThumb(\n source.thumbPosition === _MatThumb.END ? _MatThumb.END : _MatThumb.START,\n )!;\n thumb._hostElement.style.transform = `translateX(${source.translateX}px)`;\n }\n\n // Value indicator text update conditions\n //\n // 1. Value\n // - Reason: The value displayed needs to be updated.\n // 2. Min, max, or step\n // - Reason: The value may have silently changed.\n\n /** Updates the value indicator tooltip ui for the given thumb. */\n _updateValueIndicatorUI(source: _MatSliderThumb): void {\n if (this._skipUpdate()) {\n return;\n }\n\n const valuetext = this.displayWith(source.value);\n\n this._hasViewInitialized\n ? source._valuetext.set(valuetext)\n : source._hostElement.setAttribute('aria-valuetext', valuetext);\n\n if (this.discrete) {\n source.thumbPosition === _MatThumb.START\n ? (this.startValueIndicatorText = valuetext)\n : (this.endValueIndicatorText = valuetext);\n\n const visualThumb = this._getThumb(source.thumbPosition);\n valuetext.length < 3\n ? visualThumb._hostElement.classList.add('mdc-slider__thumb--short-value')\n : visualThumb._hostElement.classList.remove('mdc-slider__thumb--short-value');\n }\n }\n\n /** Updates all value indicator UIs in the slider. */\n private _updateValueIndicatorUIs(): void {\n const eInput = this._getInput(_MatThumb.END);\n const sInput = this._getInput(_MatThumb.START);\n\n if (eInput) {\n this._updateValueIndicatorUI(eInput);\n }\n if (sInput) {\n this._updateValueIndicatorUI(sInput);\n }\n }\n\n // Update Tick Mark Track Width\n //\n // 1. Min, max, or step\n // - Reason: The maximum reachable value may have changed.\n // - Side note: The maximum reachable value is different from the maximum value set by the\n // user. For example, a slider with [min: 5, max: 100, step: 10] would have a maximum\n // reachable value of 95.\n // 2. Resize\n // - Reason: The position for the maximum reachable value needs to be recalculated.\n\n /** Updates the width of the tick mark track. */\n private _updateTickMarkTrackUI(): void {\n if (!this.showTickMarks || this._skipUpdate()) {\n return;\n }\n\n const step = this._step && this._step > 0 ? this._step : 1;\n const maxValue = Math.floor(this.max / step) * step;\n const percentage = (maxValue - this.min) / (this.max - this.min);\n this._tickMarkTrackWidth = (this._cachedWidth - 6) * percentage;\n }\n\n // Track active update conditions\n //\n // 1. TranslateX\n // - Reason: The track active should line up with the new thumb position.\n // 2. Min or max\n // - Reason #1: The 'active' percentage needs to be recalculated.\n // - Reason #2: The value may have silently changed.\n // 3. Step\n // - Reason: The value may have silently changed causing the thumb(s) to shift.\n // 4. Dir change\n // - Reason: The track active will need to be updated according to the new thumb position(s).\n // 5. Resize\n // - Reason: The total width the 'active' tracks translateX is based on has changed.\n\n /** Updates the scale on the active portion of the track. */\n _updateTrackUI(source: _MatSliderThumb): void {\n if (this._skipUpdate()) {\n return;\n }\n\n this._isRange\n ? this._updateTrackUIRange(source as _MatSliderRangeThumb)\n : this._updateTrackUINonRange(source as _MatSliderThumb);\n }\n\n private _updateTrackUIRange(source: _MatSliderRangeThumb): void {\n const sibling = source.getSibling();\n if (!sibling || !this._cachedWidth) {\n return;\n }\n\n const activePercentage = Math.abs(sibling.translateX - source.translateX) / this._cachedWidth;\n\n if (source._isLeftThumb && this._cachedWidth) {\n this._setTrackActiveStyles({\n left: 'auto',\n right: `${this._cachedWidth - sibling.translateX}px`,\n transformOrigin: 'right',\n transform: `scaleX(${activePercentage})`,\n });\n } else {\n this._setTrackActiveStyles({\n left: `${sibling.translateX}px`,\n right: 'auto',\n transformOrigin: 'left',\n transform: `scaleX(${activePercentage})`,\n });\n }\n }\n\n private _updateTrackUINonRange(source: _MatSliderThumb): void {\n this._isRtl\n ? this._setTrackActiveStyles({\n left: 'auto',\n right: '0px',\n transformOrigin: 'right',\n transform: `scaleX(${1 - source.fillPercentage})`,\n })\n : this._setTrackActiveStyles({\n left: '0px',\n right: 'auto',\n transformOrigin: 'left',\n transform: `scaleX(${source.fillPercentage})`,\n });\n }\n\n // Tick mark update conditions\n //\n // 1. Value\n // - Reason: a tick mark which was once active might now be inactive or vice versa.\n // 2. Min, max, or step\n // - Reason #1: the number of tick marks may have changed.\n // - Reason #2: The value may have silently changed.\n\n /** Updates the dots along the slider track. */\n _updateTickMarkUI(): void {\n if (\n !this.showTickMarks ||\n this.step === undefined ||\n this.min === undefined ||\n this.max === undefined\n ) {\n return;\n }\n const step = this.step > 0 ? this.step : 1;\n this._isRange ? this._updateTickMarkUIRange(step) : this._updateTickMarkUINonRange(step);\n }\n\n private _updateTickMarkUINonRange(step: number): void {\n const value = this._getValue();\n let numActive = Math.max(Math.round((value - this.min) / step), 0) + 1;\n let numInactive = Math.max(Math.round((this.max - value) / step), 0) - 1;\n this._isRtl ? numActive++ : numInactive++;\n\n this._tickMarks = Array(numActive)\n .fill(_MatTickMark.ACTIVE)\n .concat(Array(numInactive).fill(_MatTickMark.INACTIVE));\n }\n\n private _updateTickMarkUIRange(step: number): void {\n const endValue = this._getValue();\n const startValue = this._getValue(_MatThumb.START);\n\n const numInactiveBeforeStartThumb = Math.max(Math.round((startValue - this.min) / step), 0);\n const numActive = Math.max(Math.round((endValue - startValue) / step) + 1, 0);\n const numInactiveAfterEndThumb = Math.max(Math.round((this.max - endValue) / step), 0);\n this._tickMarks = Array(numInactiveBeforeStartThumb)\n .fill(_MatTickMark.INACTIVE)\n .concat(\n Array(numActive).fill(_MatTickMark.ACTIVE),\n Array(numInactiveAfterEndThumb).fill(_MatTickMark.INACTIVE),\n );\n }\n\n /** Gets the slider thumb input of the given thumb position. */\n _getInput(thumbPosition: _MatThumb): _MatSliderThumb | _MatSliderRangeThumb | undefined {\n if (thumbPosition === _MatThumb.END && this._input) {\n return this._input;\n }\n if (this._inputs?.length) {\n return thumbPosition === _MatThumb.START ? this._inputs.first : this._inputs.last;\n }\n return;\n }\n\n /** Gets the slider thumb HTML input element of the given thumb position. */\n _getThumb(thumbPosition: _MatThumb): _MatSliderVisualThumb {\n return thumbPosition === _MatThumb.END ? this._thumbs?.last! : this._thumbs?.first!;\n }\n\n _setTransition(withAnimation: boolean): void {\n this._hasAnimation = !this._platform.IOS && withAnimation && !this._noopAnimations;\n this._elementRef.nativeElement.classList.toggle(\n 'mat-mdc-slider-with-animation',\n this._hasAnimation,\n );\n }\n\n /** Whether the given pointer event occurred within the bounds of the slider pointer's DOM Rect. */\n _isCursorOnSliderThumb(event: PointerEvent, rect: DOMRect) {\n const radius = rect.width / 2;\n const centerX = rect.x + radius;\n const centerY = rect.y + radius;\n const dx = event.clientX - centerX;\n const dy = event.clientY - centerY;\n return Math.pow(dx, 2) + Math.pow(dy, 2) < Math.pow(radius, 2);\n }\n}\n\n/** Ensures that there is not an invalid configuration for the slider thumb inputs. */\nfunction _validateInputs(\n isRange: boolean,\n endInputElement: _MatSliderThumb | _MatSliderRangeThumb | undefined,\n startInputElement: _MatSliderThumb | undefined,\n): void {\n const startValid =\n !isRange || startInputElement?._hostElement.hasAttribute('matSliderStartThumb');\n const endValid = endInputElement?._hostElement.hasAttribute(\n isRange ? 'matSliderEndThumb' : 'matSliderThumb',\n );\n\n if (!startValid || !endValid) {\n _throwInvalidInputConfigurationError();\n }\n}\n\nfunction _throwInvalidInputConfigurationError(): void {\n throw Error(`Invalid slider thumb input configuration!\n\n Valid configurations are as follows:\n\n <mat-slider>\n <input matSliderThumb>\n </mat-slider>\n\n or\n\n <mat-slider>\n <input matSliderStartThumb>\n <input matSliderEndThumb>\n </mat-slider>\n `);\n}\n","<!-- Inputs -->\n<ng-content></ng-content>\n\n<!-- Track -->\n<div class=\"mdc-slider__track\">\n <div class=\"mdc-slider__track--inactive\"></div>\n <div class=\"mdc-slider__track--active\">\n <div #trackActive class=\"mdc-slider__track--active_fill\"></div>\n </div>\n @if (showTickMarks) {\n <div class=\"mdc-slider__tick-marks\" #tickMarkContainer>\n @if (_cachedWidth) {\n @for (tickMark of _tickMarks; track i; let i = $index) {\n <div\n [class]=\"tickMark === 0 ? 'mdc-slider__tick-mark--active' : 'mdc-slider__tick-mark--inactive'\"\n [style.transform]=\"_calcTickMarkTransform(i)\"></div>\n }\n }\n </div>\n }\n</div>\n\n<!-- Thumbs -->\n@if (_isRange) {\n <mat-slider-visual-thumb\n [discrete]=\"discrete\"\n [thumbPosition]=\"1\"\n [valueIndicatorText]=\"startValueIndicatorText\">\n </mat-slider-visual-thumb>\n}\n\n<mat-slider-visual-thumb\n [discrete]=\"discrete\"\n [thumbPosition]=\"2\"\n [valueIndicatorText]=\"endValueIndicatorText\">\n</mat-slider-visual-thumb>\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {\n booleanAttribute,\n ChangeDetectorRef,\n Directive,\n ElementRef,\n EventEmitter,\n forwardRef,\n inject,\n Input,\n NgZone,\n numberAttribute,\n OnDestroy,\n Output,\n Renderer2,\n signal,\n} from '@angular/core';\nimport {ControlValueAccessor, FormControl, NG_VALUE_ACCESSOR} from '@angular/forms';\nimport {Subject} from 'rxjs';\nimport {\n _MatThumb,\n MatSliderDragEvent,\n _MatSlider,\n _MatSliderRangeThumb,\n _MatSliderThumb,\n MAT_SLIDER_RANGE_THUMB,\n MAT_SLIDER_THUMB,\n MAT_SLIDER,\n} from './slider-interface';\nimport {Platform} from '@angular/cdk/platform';\n\n/**\n * Provider that allows the slider thumb to register as a ControlValueAccessor.\n * @docs-private\n */\nexport const MAT_SLIDER_THUMB_VALUE_ACCESSOR: any = {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => MatSliderThumb),\n multi: true,\n};\n\n/**\n * Provider that allows the range slider thumb to register as a ControlValueAccessor.\n * @docs-private\n */\nexport const MAT_SLIDER_RANGE_THUMB_VALUE_ACCESSOR: any = {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => MatSliderRangeThumb),\n multi: true,\n};\n\n/**\n * Directive that adds slider-specific behaviors to an input element inside `<mat-slider>`.\n * Up to two may be placed inside of a `<mat-slider>`.\n *\n * If one is used, the selector `matSliderThumb` must be used, and the outcome will be a normal\n * slider. If two are used, the selectors `matSliderStartThumb` and `matSliderEndThumb` must be\n * used, and the outcome will be a range slider with two slider thumbs.\n */\n@Directive({\n selector: 'input[matSliderThumb]',\n exportAs: 'matSliderThumb',\n host: {\n 'class': 'mdc-slider__input',\n 'type': 'range',\n '[attr.aria-valuetext]': '_valuetext()',\n '(change)': '_onChange()',\n '(input)': '_onInput()',\n // TODO(wagnermaciel): Consider using a global event listener instead.\n // Reason: I have found a semi-consistent way to mouse up without triggering this event.\n '(blur)': '_onBlur()',\n '(focus)': '_onFocus()',\n },\n providers: [\n MAT_SLIDER_THUMB_VALUE_ACCESSOR,\n {provide: MAT_SLIDER_THUMB, useExisting: MatSliderThumb},\n ],\n})\nexport class MatSliderThumb implements _MatSliderThumb, OnDestroy, ControlValueAccessor {\n readonly _ngZone = inject(NgZone);\n readonly _elementRef = inject<ElementRef<HTMLInputElement>>(ElementRef);\n readonly _cdr = inject(ChangeDetectorRef);\n protected _slider = inject<_MatSlider>(MAT_SLIDER);\n private _platform = inject(Platform);\n private _listenerCleanups!: (() => void)[];\n\n @Input({transform: numberAttribute})\n get value(): number {\n return numberAttribute(this._hostElement.value, 0);\n }\n set value(value: number) {\n if (value === null) {\n value = this._getDefaultValue();\n }\n value = isNaN(value) ? 0 : value;\n const stringValue = value + '';\n if (!this._hasSetInitialValue) {\n this._initialValue = stringValue;\n return;\n }\n if (this._isActive) {\n return;\n }\n this._setValue(stringValue);\n }\n\n /**\n * Handles programmatic value setting. This has been split out to\n * allow the range thumb to override it and add additional necessary logic.\n */\n protected _setValue(value: string) {\n this._hostElement.value = value;\n this._updateThumbUIByValue();\n this._slider._onValueChange(this);\n this._cdr.detectChanges();\n this._slider._cdr.markForCheck();\n }\n\n /** Event emitted when the `value` is changed. */\n @Output() readonly valueChange: EventEmitter<number> = new EventEmitter<number>();\n\n /** Event emitted when the slider thumb starts being dragged. */\n @Output() readonly dragStart: EventEmitter<MatSliderDragEvent> =\n new EventEmitter<MatSliderDragEvent>();\n\n /** Event emitted when the slider thumb stops being dragged. */\n @Output() readonly dragEnd: EventEmitter<MatSliderDragEvent> =\n new EventEmitter<MatSliderDragEvent>();\n\n /**\n * The current translateX in px of the slider visual thumb.\n * @docs-private\n */\n get translateX(): number {\n if (this._slider.min >= this._slider.max) {\n this._translateX = this._tickMarkOffset;\n return this._translateX;\n }\n if (this._translateX === undefined) {\n this._translateX = this._calcTranslateXByValue();\n }\n return this._translateX;\n }\n set translateX(v: number) {\n this._translateX = v;\n }\n private _translateX: number | undefined;\n\n /**\n * Indicates whether this thumb is the start or end thumb.\n * @docs-private\n */\n thumbPosition: _MatThumb = _MatThumb.END;\n\n /** @docs-private */\n get min(): number {\n return numberAttribute(this._hostElement.min, 0);\n }\n set min(v: number) {\n this._hostElement.min = v + '';\n this._cdr.detectChanges();\n }\n\n /** @docs-private */\n get max(): number {\n return numberAttribute(this._hostElement.max, 0);\n }\n set max(v: number) {\n this._hostElement.max = v + '';\n this._cdr.detectChanges();\n }\n\n get step(): number {\n return numberAttribute(this._hostElement.step, 0);\n }\n set step(v: number) {\n this._hostElement.step = v + '';\n this._cdr.detectChanges();\n }\n\n /** @docs-private */\n get disabled(): boolean {\n return booleanAttribute(this._hostElement.disabled);\n }\n set disabled(v: boolean) {\n this._hostElement.disabled = v;\n this._cdr.detectChanges();\n\n if (this._slider.disabled !== this.disabled) {\n this._slider.disabled = this.disabled;\n }\n }\n\n /** The percentage of the slider that coincides with the value. */\n get percentage(): number {\n if (this._slider.min >= this._slider.max) {\n return this._slider._isRtl ? 1 : 0;\n }\n return (this.value - this._slider.min) / (this._slider.max - this._slider.min);\n }\n\n /** @docs-private */\n get fillPercentage(): number {\n if (!this._slider._cachedWidth) {\n return this._slider._isRtl ? 1 : 0;\n }\n if (this._translateX === 0) {\n return 0;\n }\n return this.translateX / this._slider._cachedWidth;\n }\n\n /** The host native HTML input element. */\n _hostElement = this._elementRef.nativeElement;\n\n /** The aria-valuetext string representation of the input's value. */\n _valuetext = signal('');\n\n /** The radius of a native html slider's knob. */\n _knobRadius: number = 8;\n\n /** The distance in px from the start of the slider track to the first tick mark. */\n _tickMarkOffset = 3;\n\n /** Whether user's cursor is currently in a mouse down state on the input. */\n _isActive: boolean = false;\n\n /** Whether the input is currently focused (either by tab or after clicking). */\n _isFocused: boolean = false;\n\n /** Used to relay updates to _isFocused to the slider visual thumbs. */\n private _setIsFocused(v: boolean): void {\n this._isFocused = v;\n }\n\n /**\n * Whether the initial value has been set.\n * This exists because the initial value cannot be immediately set because the min and max\n * must first be relayed from the parent MatSlider component, which can only happen later\n * in the component lifecycle.\n */\n private _hasSetInitialValue: boolean = false;\n\n /** The stored initial value. */\n _initialValue: string | undefined;\n\n /** Defined when a user is using a form control to manage slider value & validation. */\n private _formControl: FormControl | undefined;\n\n /** Emits when the component is destroyed. */\n protected readonly _destroyed = new Subject<void>();\n\n /**\n * Indicates whether UI updates should be skipped.\n *\n * This flag is used to avoid flickering\n * when correcting values on pointer up/down.\n */\n _skipUIUpdate: boolean = false;\n\n /** Callback called when the slider input value changes. */\n protected _onChangeFn: ((value: any) => void) | undefined;\n\n /** Callback called when the slider input has been touched. */\n private _onTouchedFn: () => void = () => {};\n\n /**\n * Whether the NgModel has been initialized.\n *\n * This flag is used to ignore ghost null calls to\n * writeValue which can break slider initialization.\n *\n * See https://github.com/angular/angular/issues/14988.\n */\n protected _isControlInitialized = false;\n\n constructor(...args: unknown[]);\n\n constructor() {\n const renderer = inject(Renderer2);\n\n this._ngZone.runOutsideAngular(() => {\n this._listenerCleanups = [\n renderer.listen(this._hostElement, 'pointerdown', this._onPointerDown.bind(this)),\n renderer.listen(this._hostElement, 'pointermove', this._onPointerMove.bind(this)),\n renderer.listen(this._hostElement, 'pointerup', this._onPointerUp.bind(this)),\n ];\n });\n }\n\n ngOnDestroy(): void {\n this._listenerCleanups.forEach(cleanup => cleanup());\n this._destroyed.next();\n this._destroyed.complete();\n this.dragStart.complete();\n this.dragEnd.complete();\n }\n\n /** @docs-private */\n initProps(): void {\n this._updateWidthInactive();\n\n // If this or the parent slider is disabled, just make everything disabled.\n if (this.disabled !== this._slider.disabled) {\n // The MatSlider setter for disabled will relay this and disable both inputs.\n this._slider.disabled = true;\n }\n\n this.step = this._slider.step;\n this.min = this._slider.min;\n this.max = this._slider.max;\n this._initValue();\n }\n\n /** @docs-private */\n initUI(): void {\n this._updateThumbUIByValue();\n }\n\n _initValue(): void {\n this._hasSetInitialValue = true;\n if (this._initialValue === undefined) {\n this.value = this._getDefaultValue();\n } else {\n this._hostElement.value = this._initialValue;\n this._updateThumbUIByValue();\n this._slider._onValueChange(this);\n this._cdr.detectChanges();\n }\n }\n\n _getDefaultValue(): number {\n return this.min;\n }\n\n _onBlur(): void {\n this._setIsFocused(false);\n this._onTouchedFn();\n }\n\n _onFocus(): void {\n this._slider._setTransition(false);\n this._slider._updateTrackUI(this);\n this._setIsFocused(true);\n }\n\n _onChange(): void {\n this.valueChange.emit(this.value);\n // only used to handle the edge case where user\n // mousedown on the slider then uses arrow keys.\n if (this._isActive) {\n this._updateThumbUIByValue({withAnimation: true});\n }\n }\n\n _onInput(): void {\n this._onChangeFn?.(this.value);\n // handles arrowing and updating the value when\n // a step is defined.\n if (this._slider.step || !this._isActive) {\n this._updateThumbUIByValue({withAnimation: true});\n }\n this._slider._onValueChange(this);\n }\n\n _onNgControlValueChange(): void {\n // only used to handle when the value change\n // originates outside of the slider.\n if (!this._isActive || !this._isFocused) {\n this._slider._onValueChange(this);\n this._updateThumbUIByValue();\n }\n this._slider.disabled = this._formControl!.disabled;\n }\n\n _onPointerDown(event: PointerEvent): void {\n if (this.disabled || event.button !== 0) {\n return;\n }\n\n // On IOS, dragging only works if the pointer down happens on the\n // slider thumb and the slider does not receive focus from pointer events.\n if (this._platform.IOS) {\n const isCursorOnSliderThumb = this._slider._isCursorOnSliderThumb(\n event,\n this._slider._getThumb(this.thumbPosition)._hostElement.getBoundingClientRect(),\n );\n\n this._isActive = isCursorOnSliderThumb;\n this._updateWidthActive();\n this._slider._updateDimensions();\n return;\n }\n\n this._isActive = true;\n this._setIsFocused(true);\n this._updateWidthActive();\n this._slider._updateDimensions();\n\n // Does nothing if a step is defined because we\n // want the value to snap to the values on input.\n if (!this._slider.step) {\n this._updateThumbUIByPointerEvent(event, {withAnimation: true});\n }\n\n if (!this.disabled) {\n this._handleValueCorrection(event);\n this.dragStart.emit({source: this, parent: this._slider, value: this.value});\n }\n }\n\n /**\n * Corrects the value of the slider on pointer up/down.\n *\n * Called on pointer down and up because the value is set based\n * on the inactive width instead of the active width.\n */\n private _handleValueCorrection(event: PointerEvent): void {\n // Don't update the UI with the current value! The value on pointerdown\n // and pointerup is calculated in the split second before the input(s)\n // resize. See _updateWidthInactive() and _updateWidthActive() for more\n // details.\n this._skipUIUpdate = true;\n\n // Note that this function gets triggered before the actual value of the\n // slider is updated. This means if we were to set the value here, it\n // would immediately be overwritten. Using setTimeout ensures the setting\n // of the value happens after the value has been updated by the\n // pointerdown event.\n setTimeout(() => {\n this._skipUIUpdate = false;\n this._fixValue(event);\n }, 0);\n }\n\n /** Corrects the value of the slider based on the pointer event's position. */\n _fixValue(event: PointerEvent): void {\n const xPos = event.clientX - this._slider._cachedLeft;\n const width = this._slider._cachedWidth;\n const step = this._slider.step === 0 ? 1 : this._slider.step;\n const numSteps = Math.floor((this._slider.max - this._slider.min) / step);\n const percentage = this._slider._isRtl ? 1 - xPos / width : xPos / width;\n\n // To ensure the percentage is rounded to the necessary number of decimals.\n const fixedPercentage = Math.round(percentage * numSteps) / numSteps;\n\n const impreciseValue =\n fixedPercentage * (this._slider.max - this._slider.min) + this._slider.min;\n const value = Math.round(impreciseValue / step) * step;\n const prevValue = this.value;\n\n if (value === prevValue) {\n // Because we prevented UI updates, if it turns out that the race\n // condition didn't happen and the value is already correct, we\n // have to apply the ui updates now.\n this._slider._onValueChange(this);\n this._slider.step > 0\n ? this._updateThumbUIByValue()\n : this._updateThumbUIByPointerEvent(event, {withAnimation: this._slider._hasAnimation});\n return;\n }\n\n this.value = value;\n this.valueChange.emit(this.value);\n this._onChangeFn?.(this.value);\n this._slider._onValueChange(this);\n this._slider.step > 0\n ? this._updateThumbUIByValue()\n : this._updateThumbUIByPointerEvent(event, {withAnimation: this._slider._hasAnimation});\n }\n\n _onPointerMove(event: PointerEvent): void {\n // Again, does nothing if a step is defined because\n // we want the value to snap to the values on input.\n if (!this._slider.step && this._isActive) {\n this._updateThumbUIByPointerEvent(event);\n }\n }\n\n _onPointerUp(): void {\n if (this._isActive) {\n this._isActive = false;\n if (this._platform.SAFARI) {\n this._setIsFocused(false);\n }\n this.dragEnd.emit({source: this, parent: this._slider, value: this.value});\n\n // This setTimeout is to prevent the pointerup from triggering a value\n // change on the input based on the inactive width. It's not clear why\n // but for some reason on IOS this race condition is even more common so\n // the timeout needs to be increased.\n setTimeout(() => this._updateWidthInactive(), this._platform.IOS ? 10 : 0);\n }\n }\n\n _clamp(v: number): number {\n const min = this._tickMarkOffset;\n const max = this._slider._cachedWidth - this._tickMarkOffset;\n return Math.max(Math.min(v, max), min);\n }\n\n _calcTranslateXByValue(): number {\n if (this._slider._isRtl) {\n return (\n (1 - this.percentage) * (this._slider._cachedWidth - this._tickMarkOffset * 2) +\n this._tickMarkOffset\n );\n }\n return (\n this.percentage * (this._slider._cachedWidth - this._tickMarkOffset * 2) +\n this._tickMarkOffset\n );\n }\n\n _calcTranslateXByPointerEvent(event: PointerEvent): number {\n return event.clientX - this._slider._cachedLeft;\n }\n\n /**\n * Used to set the slider width to the correct\n * dimensions while the user is dragging.\n */\n _updateWidthActive(): void {}\n\n /**\n * Sets the slider input to disproportionate dimensions to allow for touch\n * events to be captured on touch devices.\n */\n _updateWidthInactive(): void {\n this._hostElement.style.padding = `0 ${this._slider._inputPadding}px`;\n this._hostElement.style.width = `calc(100% + ${\n this._slider._inputPadding - this._tickMarkOffset * 2\n }px)`;\n this._hostElement.style.left = `-${this._slider._rippleRadius - this._tickMarkOffset}px`;\n }\n\n _updateThumbUIByValue(options?: {withAnimation: boolean}): void {\n this.translateX = this._clamp(this._calcTranslateXByValue());\n this._updateThumbUI(options);\n }\n\n _updateThumbUIByPointerEvent(event: PointerEvent, options?: {withAnimation: boolean}): void {\n this.translateX = this._clamp(this._calcTranslateXByPointerEvent(event));\n this._updateThumbUI(options);\n }\n\n _updateThumbUI(options?: {withAnimation: boolean}) {\n this._slider._setTransition(!!options?.withAnimation);\n this._slider._onTranslateXChange(this);\n }\n\n /**\n * Sets the input's value.\n * @param value The new value of the input\n * @docs-private\n */\n writeValue(value: any): void {\n if (this._isControlInitialized || value !== null) {\n this.value = value;\n }\n }\n\n /**\n * Registers a callback to be invoked when the input's value changes from user input.\n * @param fn The callback to register\n * @docs-private\n */\n registerOnChange(fn: any): void {\n this._onChangeFn = fn;\n this._isControlInitialized = true;\n }\n\n /**\n * Registers a callback to be invoked when the input is blurred by the user.\n * @param fn The callback to register\n * @docs-private\n */\n registerOnTouched(fn: any): void {\n this._onTouchedFn = fn;\n }\n\n /**\n * Sets the disabled state of the slider.\n * @param isDisabled The new disabled state\n * @docs-private\n */\n setDisabledState(isDisabled: boolean): void {\n this.disabled = isDisabled;\n }\n\n focus(): void {\n this._hostElement.focus();\n }\n\n blur(): void {\n this._hostElement.blur();\n }\n}\n\n@Directive({\n selector: 'input[matSliderStartThumb], input[matSliderEndThumb]',\n exportAs: 'matSliderRangeThumb',\n providers: [\n MAT_SLIDER_RANGE_THUMB_VALUE_ACCESSOR,\n {provide: MAT_SLIDER_RANGE_THUMB, useExisting: MatSliderRangeThumb},\n ],\n})\nexport class MatSliderRangeThumb extends MatSliderThumb implements _MatSliderRangeThumb {\n override readonly _cdr = inject(ChangeDetectorRef);\n\n /** @docs-private */\n getSibling(): _MatSliderRangeThumb | undefined {\n if (!this._sibling) {\n this._sibling = this._slider._getInput(this._isEndThumb ? _MatThumb.START : _MatThumb.END) as\n | MatSliderRangeThumb\n | undefined;\n }\n return this._sibling;\n }\n private _sibling: MatSliderRangeThumb | undefined;\n\n /**\n * Returns the minimum translateX position allowed for this slider input's visual thumb.\n * @docs-private\n */\n getMinPos(): number {\n const sibling = this.getSibling();\n if (!this._isLeftThumb && sibling) {\n return sibling.translateX;\n }\n return this._tickMarkOffset;\n }\n\n /**\n * Returns the maximum translateX position allowed for this slider input's visual thumb.\n * @docs-private\n */\n getMaxPos(): number {\n const sibling = this.getSibling();\n if (this._isLeftThumb && sibling) {\n return sibling.translateX;\n }\n return this._slider._cachedWidth - this._tickMarkOffset;\n }\n\n _setIsLeftThumb(): void {\n this._isLeftThumb =\n (this._isEndThumb && this._slider._isRtl) || (!this._isEndThumb && !this._slider._isRtl);\n }\n\n /** Whether this slider corresponds to the input on the left hand side. */\n _isLeftThumb = false;\n\n /** Whether this slider corresponds to the input with greater value. */\n _isEndThumb = false;\n\n constructor(...args: unknown[]);\n\n constructor() {\n super();\n\n this._isEndThumb = this._hostElement.hasAttribute('matSliderEndThumb');\n this._setIsLeftThumb();\n this.thumbPosition = this._isEndThumb ? _MatThumb.END : _MatThumb.START;\n }\n\n override _getDefaultValue(): number {\n return this._isEndThumb && this._slider._isRange ? this.max : this.min;\n }\n\n override _onInput(): void {\n super._onInput();\n this._updateSibling();\n if (!this._isActive) {\n this._updateWidthInactive();\n }\n }\n\n override _onNgControlValueChange(): void {\n super._onNgControlValueChange();\n this.getSibling()?._updateMinMax();\n }\n\n override _onPointerDown(event: PointerEvent): void {\n if (this.disabled || event.button !== 0) {\n return;\n }\n if (this._sibling) {\n this._sibling._updateWidthActive();\n this._sibling._hostElement.classList.add('mat-mdc-slider-input-no-pointer-events');\n }\n super._onPointerDown(event);\n }\n\n override _onPointerUp(): void {\n super._onPointerUp();\n if (this._sibling) {\n setTimeout(() => {\n this._sibling!._updateWidthInactive();\n this._sibling!._hostElement.classList.remove('mat-mdc-slider-input-no-pointer-events');\n });\n }\n }\n\n override _onPointerMove(event: PointerEvent): void {\n super._onPointerMove(event);\n if (!this._slider.step && this._isActive) {\n this._updateSibling();\n }\n }\n\n override _fixValue(event: PointerEvent): void {\n super._fixValue(event);\n this._sibling?._updateMinMax();\n }\n\n override _clamp(v: number): number {\n return Math.max(Math.min(v, this.getMaxPos()), this.getMinPos());\n }\n\n _updateMinMax(): void {\n const sibling = this.getSibling();\n if (!sibling) {\n return;\n }\n if (this._isEndThumb) {\n this.min = Math.max(this._slider.min, sibling.value);\n this.max = this._slider.max;\n } else {\n this.min = this._slider.min;\n this.max = Math.min(this._slider.max, sibling.value);\n }\n }\n\n override _updateWidthActive(): void {\n const minWidth = this._slider._rippleRadius * 2 - this._slider._inputPadding * 2;\n const maxWidth =\n this._slider._cachedWidth + this._slider._inputPadding - minWidth - this._tickMarkOffset * 2;\n const percentage =\n this._slider.min < this._slider.max\n ? (this.max - this.min) / (this._slider.max - this._slider.min)\n : 1;\n const width = maxWidth * percentage + minWidth;\n this._hostElement.style.width = `${width}px`;\n this._hostElement.style.padding = `0 ${this._slider._inputPadding}px`;\n }\n\n override _updateWidthInactive(): void {\n const sibling = this.getSibling();\n if (!sibling) {\n return;\n }\n const maxWidth = this._slider._cachedWidth - this._tickMarkOffset * 2;\n const midValue = this._isEndThumb\n ? this.value - (this.value - sibling.value) / 2\n : this.value + (sibling.value - this.value) / 2;\n\n const _percentage = this._isEndThumb\n ? (this.max - midValue) / (this._slider.max - this._slider.min)\n : (midValue - this.min) / (this._slider.max - this._slider.min);\n\n const percentage = this._slider.min < this._slider.max ? _percentage : 1;\n\n // Extend the native input width by the radius of the ripple\n let ripplePadding = this._slider._rippleRadius;\n\n // If one of the inputs is maximally sized (the value of both thumbs is\n // equal to the min or max), make that input take up all of the width and\n // make the other unselectable.\n if (percentage === 1) {\n ripplePadding = 48;\n } else if (percentage === 0) {\n ripplePadding = 0;\n }\n\n const width = maxWidth * percentage + ripplePadding;\n this._hostElement.style.width = `${width}px`;\n this._hostElement.style.padding = '0px';\n\n if (this._isLeftThumb) {\n this._hostElement.style.left = `-${this._slider._rippleRadius - this._tickMarkOffset}px`;\n this._hostElement.style.right = 'auto';\n } else {\n this._hostElement.style.left = 'auto';\n this._hostElement.style.right = `-${this._slider._rippleRadius - this._tickMarkOffset}px`;\n }\n }\n\n _updateStaticStyles(): void {\n this._hostElement.classList.toggle('mat-slider__right-input', !this._isLeftThumb);\n }\n\n private _updateSibling(): void {\n const sibling = this.getSibling();\n if (!sibling) {\n return;\n }\n sibling._updateMinMax();\n if (this._isActive) {\n sibling._updateWidthActive();\n } else {\n sibling._updateWidthInactive();\n }\n }\n\n /**\n * Sets the input's value.\n * @param value The new value of the input\n * @docs-private\n */\n override writeValue(value: any): void {\n if (this._isControlInitialized || value !== null) {\n this.value = value;\n this._updateWidthInactive();\n this._updateSibling();\n }\n }\n\n override _setValue(value: string) {\n super._setValue(value);\n this._updateWidthInactive();\n this._updateSibling();\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {BidiModule} from '@angular/cdk/bidi';\nimport {NgModule} from '@angular/core';\nimport {MatRippleModule} from '../core';\nimport {MatSlider} from './slider';\nimport {MatSliderVisualThumb} from './slider-thumb';\nimport {MatSliderThumb, MatSliderRangeThumb} from './slider-input';\n\n@NgModule({\n imports: [MatRippleModule, MatSlider, MatSliderThumb, MatSliderRangeThumb, MatSliderVisualThumb],\n exports: [MatSlider, MatSliderThumb, MatSliderRangeThumb, BidiModule],\n})\nexport class MatSliderModule {}\n"],"names":["_MatThumb","_MatTickMark","MAT_SLIDER","InjectionToken","MAT_SLIDER_THUMB","MAT_SLIDER_RANGE_THUMB","MAT_SLIDER_VISUAL_THUMB","MatSliderChange","source","parent","value","MatSliderVisualThumb","_cdr","inject","ChangeDetectorRef","_ngZone","NgZone","_slider","_renderer","Renderer2","_listenerCleanups","discrete","thumbPosition","valueIndicatorText","_ripple","_knob","_valueIndicatorContainer","_sliderInput","_sliderInputEl","_hoverRippleRef","_focusRippleRef","_activeRippleRef","_isHovered","_isActive","_isValueIndicatorVisible","_hostElement","ElementRef","nativeElement","_platform","Platform","constructor","ngAfterViewInit","sliderInput","_getInput","radius","runOutsideAngular","input","renderer","listen","_onPointerMove","_onDragStart","_onDragEnd","_onMouseLeave","_onFocus","_onBlur","ngOnDestroy","forEach","cleanup","event","_isFocused","rect","getBoundingClientRect","isHovered","_isCursorOnSliderThumb","_showHoverRipple","_hideRipple","_showFocusRipple","classList","add","remove","button","_showActiveRipple","SAFARI","_isShowingRipple","_showRipple","enterDuration","exitDuration","element","rippleRef","state","RippleState","FADING_IN","VISIBLE","animation","ignoreGlobalRippleConfig","disabled","_showValueIndicator","_isRange","sibling","_getThumb","START","END","_globalRippleOptions","launch","_noopAnimations","centered","persistent","fadeOut","_isShowingAnyRipple","_hideValueIndicator","_getSibling","_getValueIndicatorContainer","_getKnob","deps","target","i0","ɵɵFactoryTarget","Component","ɵcmp","ɵɵngDeclareComponent","minVersion","version","type","provide","useExisting","viewQueries","propertyName","first","predicate","MatRipple","descendants","ngImport","template","selector","inputs","exportAs","changeDetection","ChangeDetectionStrategy","OnPush","encapsulation","ViewEncapsulation","None","decorators","args","host","imports","styles","Input","ViewChild","MatSlider","_elementRef","_dir","Directionality","optional","MAT_RIPPLE_GLOBAL_OPTIONS","_trackActive","_thumbs","_input","_inputs","_disabled","v","endInput","startInput","_discrete","_updateValueIndicatorUIs","showTickMarks","_showTickMarks","_hasViewInitialized","_updateTickMarkUI","_updateTickMarkTrackUI","min","_min","undefined","isNaN","_updateMin","color","disableRipple","prevMin","_updateMinRange","old","new","_updateMinNonRange","_onMinMaxOrStepChange","oldEndValue","oldStartValue","Math","max","_updateWidthInactive","_onTranslateXChangeBySideEffect","_onValueChange","oldValue","_updateThumbUIByValue","_updateTrackUI","_max","_updateMax","prevMax","_updateMaxRange","_updateMaxNonRange","step","_step","_updateStep","_updateStepRange","_updateStepNonRange","prevStartValue","displayWith","_tickMarks","_animationsDisabled","_dirChangeSubscription","_resizeObserver","_cachedWidth","_cachedLeft","_rippleRadius","startValueIndicatorText","endValueIndicatorText","_endThumbTransform","_startThumbTransform","_isRtl","_tickMarkTrackWidth","_hasAnimation","_resizeTimer","_CdkPrivateStyleLoader","load","_StructuralStylesLoader","change","subscribe","_onDirChange","_knobRadius","_inputPadding","isBrowser","_updateDimensions","eInput","sInput","detectChanges","ngDevMode","_validateInputs","thumb","_initUIRange","_initUINonRange","_observeHostResize","initProps","initUI","_updateValueIndicatorUI","_updateMinMax","_updateStaticStyles","unsubscribe","disconnect","_onDirChangeRange","_onDirChangeNonRange","_setIsLeftThumb","translateX","_calcTranslateXByValue","ResizeObserver","clearTimeout","_onResize","observe","_getValue","_skipUpdate","_skipUIUpdate","offsetWidth","left","_setTrackActiveStyles","trackStyle","style","right","transformOrigin","transform","_calcTickMarkTransform","index","offset","length","_onTranslateXChange","_updateThumbUI","_updateOverlappingThumbUI","input1","input2","markForCheck","_thumbsOverlap","_areThumbsOverlapping","_updateOverlappingThumbClassNames","getSibling","sourceThumb","siblingThumb","toggle","valuetext","_valuetext","set","setAttribute","visualThumb","maxValue","floor","percentage","_updateTrackUIRange","_updateTrackUINonRange","activePercentage","abs","_isLeftThumb","fillPercentage","_updateTickMarkUIRange","_updateTickMarkUINonRange","numActive","round","numInactive","Array","fill","ACTIVE","concat","INACTIVE","endValue","startValue","numInactiveBeforeStartThumb","numInactiveAfterEndThumb","last","_setTransition","withAnimation","IOS","width","centerX","x","centerY","y","dx","clientX","dy","clientY","pow","isStandalone","booleanAttribute","numberAttribute","queries","providers","ViewChildren","ContentChild","ContentChildren","isRange","endInputElement","startInputElement","startValid","hasAttribute","endValid","_throwInvalidInputConfigurationError","Error","MAT_SLIDER_THUMB_VALUE_ACCESSOR","NG_VALUE_ACCESSOR","forwardRef","MatSliderThumb","multi","MAT_SLIDER_RANGE_THUMB_VALUE_ACCESSOR","MatSliderRangeThumb","_getDefaultValue","stringValue","_hasSetInitialValue","_initialValue","_setValue","valueChange","EventEmitter","dragStart","dragEnd","_translateX","_tickMarkOffset","signal","_setIsFocused","_formControl","_destroyed","Subject","_onChangeFn","_onTouchedFn","_isControlInitialized","_onPointerDown","bind","_onPointerUp","next","complete","_initValue","_onChange","emit","_onInput","_onNgControlValueChange","isCursorOnSliderThumb","_updateWidthActive","_updateThumbUIByPointerEvent","_handleValueCorrection","setTimeout","_fixValue","xPos","numSteps","fixedPercentage","impreciseValue","prevValue","_clamp","_calcTranslateXByPointerEvent","padding","options","writeValue","registerOnChange","fn","registerOnTouched","setDisabledState","isDisabled","focus","blur","Directive","outputs","attributes","listeners","properties","classAttribute","Output","_sibling","_isEndThumb","getMinPos","getMaxPos","_updateSibling","minWidth","maxWidth","midValue","_percentage","ripplePadding","ɵdir","ɵɵngDeclareDirective","usesInheritance","MatSliderModule","NgModule","ɵmod","ɵɵngDeclareNgModule","MatRippleModule","BidiModule","exports"],"mappings":";;;;;;;;;;;;;;;AAeA,IAAYA,SAGX;AAHD,CAAA,UAAYA,SAAS,EAAA;EACnBA,SAAA,CAAAA,SAAA,CAAA,OAAA,CAAA,GAAA,CAAA,CAAA,GAAA,OAAS;EACTA,SAAA,CAAAA,SAAA,CAAA,KAAA,CAAA,GAAA,CAAA,CAAA,GAAA,KAAO;AACT,CAAC,EAHWA,SAAS,KAATA,SAAS,GAGpB,EAAA,CAAA,CAAA;AAGD,IAAYC,YAGX;AAHD,CAAA,UAAYA,YAAY,EAAA;EACtBA,YAAA,CAAAA,YAAA,CAAA,QAAA,CAAA,GAAA,CAAA,CAAA,GAAA,QAAU;EACVA,YAAA,CAAAA,YAAA,CAAA,UAAA,CAAA,GAAA,CAAA,CAAA,GAAA,UAAY;AACd,CAAC,EAHWA,YAAY,KAAZA,YAAY,GAGvB,EAAA,CAAA,CAAA;AAQM,MAAMC,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