@ng-matero/extensions 14.6.1 → 14.6.3
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/colorpicker/colorpicker-toggle.d.ts +7 -5
- package/datetimepicker/datetimepicker-toggle.d.ts +3 -3
- package/datetimepicker/time.scss +9 -0
- package/esm2020/colorpicker/colorpicker-toggle.mjs +29 -18
- package/esm2020/datetimepicker/datetimepicker-toggle.mjs +23 -16
- package/esm2020/datetimepicker/time.mjs +5 -4
- package/esm2020/select/select.component.mjs +2 -2
- package/fesm2015/mtxColorpicker.mjs +27 -14
- package/fesm2015/mtxColorpicker.mjs.map +1 -1
- package/fesm2015/mtxDatetimepicker.mjs +28 -18
- package/fesm2015/mtxDatetimepicker.mjs.map +1 -1
- package/fesm2015/mtxSelect.mjs +2 -2
- package/fesm2015/mtxSelect.mjs.map +1 -1
- package/fesm2020/mtxColorpicker.mjs +25 -14
- package/fesm2020/mtxColorpicker.mjs.map +1 -1
- package/fesm2020/mtxDatetimepicker.mjs +26 -18
- package/fesm2020/mtxDatetimepicker.mjs.map +1 -1
- package/fesm2020/mtxSelect.mjs +2 -2
- package/fesm2020/mtxSelect.mjs.map +1 -1
- package/package.json +1 -1
- package/select/select.component.scss +10 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mtxColorpicker.mjs","sources":["../../../projects/extensions/colorpicker/colorpicker-input.ts","../../../projects/extensions/colorpicker/colorpicker-toggle.ts","../../../projects/extensions/colorpicker/colorpicker-toggle.html","../../../projects/extensions/colorpicker/colorpicker-animations.ts","../../../projects/extensions/colorpicker/colorpicker.ts","../../../projects/extensions/colorpicker/colorpicker-content.html","../../../projects/extensions/colorpicker/colorpicker-module.ts","../../../projects/extensions/colorpicker/mtxColorpicker.ts"],"sourcesContent":["import { BooleanInput, coerceBooleanProperty } from '@angular/cdk/coercion';\nimport { DOWN_ARROW } from '@angular/cdk/keycodes';\nimport {\n AfterViewInit,\n Directive,\n ElementRef,\n EventEmitter,\n forwardRef,\n Input,\n OnDestroy,\n Optional,\n Output,\n} from '@angular/core';\nimport {\n AbstractControl,\n ControlValueAccessor,\n NG_VALIDATORS,\n NG_VALUE_ACCESSOR,\n ValidationErrors,\n ValidatorFn,\n Validators,\n} from '@angular/forms';\nimport { ThemePalette } from '@angular/material/core';\nimport { MatFormField } from '@angular/material/form-field';\nimport { MAT_INPUT_VALUE_ACCESSOR } from '@angular/material/input';\nimport { Subscription } from 'rxjs';\nimport { MtxColorpicker } from './colorpicker';\n\nexport class MtxColorPickerInputEvent {\n /** The new value for the target colorpicker input. */\n value: string | null;\n\n constructor(\n /** Reference to the colorpicker input component that emitted the event. */\n public target: MtxColorpickerInput,\n /** Reference to the native input element associated with the colorpicker input. */\n public targetElement: HTMLElement\n ) {\n this.value = this.target.value;\n }\n}\n\nexport const MTX_COLORPICKER_VALUE_ACCESSOR: any = {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => MtxColorpickerInput),\n multi: true,\n};\n\nexport const MTX_COLORPICKER_VALIDATORS: any = {\n provide: NG_VALIDATORS,\n useExisting: forwardRef(() => MtxColorpickerInput),\n multi: true,\n};\n\nexport type ColorFormat = 'hex' | 'rgb' | 'hsl' | 'hsv';\n\n@Directive({\n selector: 'input[mtxColorpicker]',\n providers: [\n MTX_COLORPICKER_VALUE_ACCESSOR,\n MTX_COLORPICKER_VALIDATORS,\n { provide: MAT_INPUT_VALUE_ACCESSOR, useExisting: MtxColorpickerInput },\n ],\n host: {\n 'class': 'mtx-colorpicker-input',\n '[attr.aria-haspopup]': '_picker ? \"dialog\" : null',\n '[attr.aria-owns]': '(_picker?.opened && _picker.id) || null',\n '[disabled]': 'disabled',\n '(input)': '_onInput($event.target.value)',\n '(change)': '_onChange()',\n '(blur)': '_onBlur()',\n '(keydown)': '_onKeydown($event)',\n },\n exportAs: 'mtxColorpickerInput',\n})\nexport class MtxColorpickerInput implements ControlValueAccessor, AfterViewInit, OnDestroy {\n /** Whether the component has been initialized. */\n private _isInitialized!: boolean;\n\n @Input()\n set mtxColorpicker(value: MtxColorpicker) {\n if (!value) {\n return;\n }\n\n this._picker = value;\n this._picker.registerInput(this);\n this._pickerSubscription.unsubscribe();\n\n this._pickerSubscription = this._picker._selectedChanged.subscribe((selected: string) => {\n this.value = selected;\n this._cvaOnChange(selected);\n this._onTouched();\n this.colorInput.emit(new MtxColorPickerInputEvent(this, this._elementRef.nativeElement));\n this.colorChange.emit(new MtxColorPickerInputEvent(this, this._elementRef.nativeElement));\n });\n }\n _picker!: MtxColorpicker;\n\n /** Whether the colorpicker-input is disabled. */\n @Input()\n get disabled(): boolean {\n return !!this._disabled;\n }\n set disabled(value: boolean) {\n const newValue = coerceBooleanProperty(value);\n const element = this._elementRef.nativeElement;\n\n if (this._disabled !== newValue) {\n this._disabled = newValue;\n this._disabledChange.emit(newValue);\n }\n\n // We need to null check the `blur` method, because it's undefined during SSR.\n // In Ivy static bindings are invoked earlier, before the element is attached to the DOM.\n // This can cause an error to be thrown in some browsers (IE/Edge) which assert that the\n // element has been inserted.\n if (newValue && this._isInitialized && element.blur) {\n // Normally, native input elements automatically blur if they turn disabled. This behavior\n // is problematic, because it would mean that it triggers another change detection cycle,\n // which then causes a changed after checked error if the input element was focused before.\n element.blur();\n }\n }\n private _disabled!: boolean;\n\n /** The value of the input. */\n @Input()\n get value(): string | null {\n return this._value;\n }\n set value(value: string | null) {\n const oldValue = this.value;\n this._value = value;\n this._formatValue(value);\n\n this._valueChange.emit(value);\n }\n private _value!: string | null;\n\n /** The input and output color format. */\n @Input() format: ColorFormat = 'hex';\n\n /** Emits when a `change` event is fired on this `<input>`. */\n @Output() readonly colorChange: EventEmitter<MtxColorPickerInputEvent> =\n new EventEmitter<MtxColorPickerInputEvent>();\n\n /** Emits when an `input` event is fired on this `<input>`. */\n @Output() readonly colorInput: EventEmitter<MtxColorPickerInputEvent> =\n new EventEmitter<MtxColorPickerInputEvent>();\n\n /** Emits when the disabled state has changed */\n _disabledChange = new EventEmitter<boolean>();\n\n /** Emits when the value changes (either due to user input or programmatic change). */\n _valueChange = new EventEmitter<string | null>();\n\n _onTouched = () => {};\n\n _validatorOnChange = () => {};\n\n private _cvaOnChange: (value: any) => void = () => {};\n\n private _pickerSubscription = Subscription.EMPTY;\n\n /** The combined form control validator for this input. */\n private _validator: ValidatorFn | null = Validators.compose([]);\n\n /** Whether the last value set on the input was valid. */\n private _lastValueValid = false;\n\n constructor(\n private _elementRef: ElementRef<HTMLInputElement>,\n @Optional() private _formField: MatFormField\n ) {}\n\n ngAfterViewInit() {\n this._isInitialized = true;\n }\n\n ngOnDestroy() {\n this._pickerSubscription.unsubscribe();\n this._valueChange.complete();\n this._disabledChange.complete();\n }\n\n registerOnValidatorChange(fn: () => void): void {\n this._validatorOnChange = fn;\n }\n\n /** @docs-private */\n validate(c: AbstractControl): ValidationErrors | null {\n return this._validator ? this._validator(c) : null;\n }\n\n /**\n * @deprecated\n * @breaking-change 8.0.0 Use `getConnectedOverlayOrigin` instead\n */\n getPopupConnectionElementRef(): ElementRef {\n return this.getConnectedOverlayOrigin();\n }\n\n /**\n * Gets the element that the colorpicker popup should be connected to.\n * @return The element to connect the popup to.\n */\n getConnectedOverlayOrigin(): ElementRef {\n return this._formField ? this._formField.getConnectedOverlayOrigin() : this._elementRef;\n }\n\n /** Gets the ID of an element that should be used a description for the overlay. */\n getOverlayLabelId(): string | null {\n if (this._formField) {\n return this._formField.getLabelId();\n }\n\n return this._elementRef.nativeElement.getAttribute('aria-labelledby');\n }\n\n // Implemented as part of ControlValueAccessor.\n writeValue(value: string): void {\n this.value = value;\n }\n\n // Implemented as part of ControlValueAccessor.\n registerOnChange(fn: (value: any) => void): void {\n this._cvaOnChange = fn;\n }\n\n // Implemented as part of ControlValueAccessor.\n registerOnTouched(fn: () => void): void {\n this._onTouched = fn;\n }\n\n // Implemented as part of ControlValueAccessor.\n setDisabledState(isDisabled: boolean): void {\n this.disabled = isDisabled;\n }\n\n _onKeydown(event: KeyboardEvent) {\n const isAltDownArrow = event.altKey && event.keyCode === DOWN_ARROW;\n\n if (this._picker && isAltDownArrow && !this._elementRef.nativeElement.readOnly) {\n this._picker.open();\n event.preventDefault();\n }\n }\n\n /** Handles blur events on the input. */\n _onBlur() {\n // Reformat the input only if we have a valid value.\n if (this.value) {\n this._formatValue(this.value);\n }\n\n this._onTouched();\n }\n\n _onInput(value: string) {\n const nextValue = value;\n\n this._value = nextValue;\n this._cvaOnChange(nextValue);\n this._valueChange.emit(nextValue);\n this.colorInput.emit(new MtxColorPickerInputEvent(this, this._elementRef.nativeElement));\n }\n\n _onChange() {\n this.colorChange.emit(new MtxColorPickerInputEvent(this, this._elementRef.nativeElement));\n }\n\n /** Returns the palette used by the input's form field, if any. */\n getThemePalette(): ThemePalette {\n return this._formField ? this._formField.color : undefined;\n }\n\n /** TODO: Formats a value and sets it on the input element. */\n private _formatValue(value: string | null) {\n this._elementRef.nativeElement.value = value ? value : '';\n }\n\n // Accept `any` to avoid conflicts with other directives on `<input>` that\n // may accept different types.\n static ngAcceptInputType_value: any;\n static ngAcceptInputType_disabled: BooleanInput;\n}\n","import { BooleanInput, coerceBooleanProperty } from '@angular/cdk/coercion';\nimport {\n AfterContentInit,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ContentChild,\n Directive,\n Input,\n OnChanges,\n OnDestroy,\n OnInit,\n SimpleChanges,\n ViewChild,\n ViewEncapsulation,\n} from '@angular/core';\nimport { MatButton } from '@angular/material/button';\nimport { Subscription, of, merge } from 'rxjs';\nimport { MtxColorpicker } from './colorpicker';\n\n/** Can be used to override the icon of a `mtxColorpickerToggle`. */\n@Directive({\n selector: '[mtxColorpickerToggleIcon]',\n})\nexport class MtxColorpickerToggleIcon {}\n\n@Component({\n selector: 'mtx-colorpicker-toggle',\n templateUrl: './colorpicker-toggle.html',\n styleUrls: ['./colorpicker-toggle.scss'],\n host: {\n 'class': 'mtx-colorpicker-toggle',\n // Always set the tabindex to -1 so that it doesn't overlap with any custom tabindex the\n // consumer may have provided, while still being able to receive focus.\n '[attr.tabindex]': 'disabled ? null : -1',\n '[class.mtx-colorpicker-toggle-active]': 'picker && picker.opened',\n '[class.mat-accent]': 'picker && picker.color === \"accent\"',\n '[class.mat-warn]': 'picker && picker.color === \"warn\"',\n '(focus)': '_button.focus()',\n },\n exportAs: 'mtxColorpickerToggle',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class MtxColorpickerToggle implements AfterContentInit, OnChanges, OnDestroy {\n private _stateChanges = Subscription.EMPTY;\n\n /** Colorpicker instance that the button will toggle. */\n @Input('for') picker!: MtxColorpicker;\n\n /** Tabindex for the toggle. */\n @Input() tabIndex!: number;\n\n /** Whether the toggle button is disabled. */\n @Input()\n get disabled(): boolean {\n if (this._disabled == null && this.picker) {\n return this.picker.disabled;\n }\n\n return !!this._disabled;\n }\n set disabled(value: boolean) {\n this._disabled = coerceBooleanProperty(value);\n }\n private _disabled!: boolean;\n\n /** Whether ripples on the toggle should be disabled. */\n @Input() disableRipple!: boolean;\n\n /** Custom icon set by the consumer. */\n @ContentChild(MtxColorpickerToggleIcon) _customIcon!: MtxColorpickerToggleIcon;\n\n /** Underlying button element. */\n @ViewChild('button') _button!: MatButton;\n\n constructor(private _changeDetectorRef: ChangeDetectorRef) {}\n\n ngOnChanges(changes: SimpleChanges): void {\n if (changes.picker) {\n this._watchStateChanges();\n }\n }\n\n ngOnDestroy() {\n this._stateChanges.unsubscribe();\n }\n\n ngAfterContentInit() {\n this._watchStateChanges();\n }\n\n open(event: Event): void {\n if (this.picker && !this.disabled) {\n this.picker.open();\n event.stopPropagation();\n }\n }\n\n private _watchStateChanges() {\n const pickerDisabled = this.picker ? this.picker._disabledChange : of();\n const inputDisabled =\n this.picker && this.picker.pickerInput ? this.picker.pickerInput._disabledChange : of();\n const datepickerToggled = this.picker\n ? merge(this.picker.openedStream, this.picker.closedStream)\n : of();\n\n this._stateChanges.unsubscribe();\n this._stateChanges = merge([pickerDisabled, inputDisabled, datepickerToggled]).subscribe(() =>\n this._changeDetectorRef.markForCheck()\n );\n }\n\n static ngAcceptInputType_disabled: BooleanInput;\n static ngAcceptInputType_disableRipple: BooleanInput;\n}\n","<button #button\n mat-icon-button\n type=\"button\"\n [attr.aria-haspopup]=\"picker ? 'dialog' : null\"\n [attr.tabindex]=\"disabled ? -1 : tabIndex\"\n [disabled]=\"disabled\"\n [disableRipple]=\"disableRipple\"\n (click)=\"open($event)\">\n\n <svg *ngIf=\"!_customIcon\"\n class=\"mtx-colorpicker-toggle-default-icon\"\n viewBox=\"0 0 24 24\"\n width=\"24px\"\n height=\"24px\"\n fill=\"currentColor\"\n focusable=\"false\">\n <path\n d=\"M17.5,12A1.5,1.5 0 0,1 16,10.5A1.5,1.5 0 0,1 17.5,9A1.5,1.5 0 0,1 19,10.5A1.5,1.5 0 0,1 17.5,12M14.5,8A1.5,1.5 0 0,1 13,6.5A1.5,1.5 0 0,1 14.5,5A1.5,1.5 0 0,1 16,6.5A1.5,1.5 0 0,1 14.5,8M9.5,8A1.5,1.5 0 0,1 8,6.5A1.5,1.5 0 0,1 9.5,5A1.5,1.5 0 0,1 11,6.5A1.5,1.5 0 0,1 9.5,8M6.5,12A1.5,1.5 0 0,1 5,10.5A1.5,1.5 0 0,1 6.5,9A1.5,1.5 0 0,1 8,10.5A1.5,1.5 0 0,1 6.5,12M12,3A9,9 0 0,0 3,12A9,9 0 0,0 12,21A1.5,1.5 0 0,0 13.5,19.5C13.5,19.11 13.35,18.76 13.11,18.5C12.88,18.23 12.73,17.88 12.73,17.5A1.5,1.5 0 0,1 14.23,16H16A5,5 0 0,0 21,11C21,6.58 16.97,3 12,3Z\" />\n </svg>\n\n <ng-content select=\"[mtxColorpickerToggleIcon]\"></ng-content>\n</button>\n","import {\n animate,\n style,\n transition,\n trigger,\n keyframes,\n AnimationTriggerMetadata,\n} from '@angular/animations';\n\n/**\n * Animations used by the colorpicker.\n * @docs-private\n */\nexport const mtxColorpickerAnimations: {\n readonly transformPanel: AnimationTriggerMetadata;\n} = {\n /** Transforms the height of the colorpicker's panel. */\n transformPanel: trigger('transformPanel', [\n transition(\n 'void => enter-dropdown',\n animate(\n '120ms cubic-bezier(0, 0, 0.2, 1)',\n keyframes([\n style({ opacity: 0, transform: 'scale(1, 0.8)' }),\n style({ opacity: 1, transform: 'scale(1, 1)' }),\n ])\n )\n ),\n transition('* => void', animate('100ms linear', style({ opacity: 0 }))),\n ]),\n};\n","import { Directionality } from '@angular/cdk/bidi';\nimport { BooleanInput, coerceBooleanProperty } from '@angular/cdk/coercion';\nimport { ESCAPE, hasModifierKey, UP_ARROW } from '@angular/cdk/keycodes';\nimport {\n ScrollStrategy,\n OverlayConfig,\n Overlay,\n OverlayRef,\n FlexibleConnectedPositionStrategy,\n} from '@angular/cdk/overlay';\nimport { ComponentPortal } from '@angular/cdk/portal';\nimport { DOCUMENT } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ComponentRef,\n ElementRef,\n EventEmitter,\n Inject,\n InjectionToken,\n Input,\n NgZone,\n OnChanges,\n OnDestroy,\n Optional,\n Output,\n TemplateRef,\n ViewContainerRef,\n ViewEncapsulation,\n} from '@angular/core';\nimport { CanColor, mixinColor, ThemePalette } from '@angular/material/core';\nimport { Subject, Subscription, merge } from 'rxjs';\nimport { filter, take } from 'rxjs/operators';\nimport { mtxColorpickerAnimations } from './colorpicker-animations';\nimport { ColorFormat, MtxColorpickerInput } from './colorpicker-input';\n\nimport { ColorEvent } from 'ngx-color';\n\nimport { TinyColor } from '@ctrl/tinycolor';\n\n/** Used to generate a unique ID for each colorpicker instance. */\nlet colorpickerUid = 0;\n\n/** Injection token that determines the scroll handling while the panel is open. */\nexport const MTX_COLORPICKER_SCROLL_STRATEGY = new InjectionToken<() => ScrollStrategy>(\n 'mtx-colorpicker-scroll-strategy'\n);\n\nexport function MTX_COLORPICKER_SCROLL_STRATEGY_FACTORY(overlay: Overlay): () => ScrollStrategy {\n return () => overlay.scrollStrategies.reposition();\n}\n\n/** Possible positions for the colorpicker dropdown along the X axis. */\nexport type ColorpickerDropdownPositionX = 'start' | 'end';\n\n/** Possible positions for the colorpicker dropdown along the Y axis. */\nexport type ColorpickerDropdownPositionY = 'above' | 'below';\n\nexport const MTX_COLORPICKER_SCROLL_STRATEGY_FACTORY_PROVIDER = {\n provide: MTX_COLORPICKER_SCROLL_STRATEGY,\n deps: [Overlay],\n useFactory: MTX_COLORPICKER_SCROLL_STRATEGY_FACTORY,\n};\n\n// Boilerplate for applying mixins to MtxColorpickerContent.\n/** @docs-private */\nconst _MtxColorpickerContentBase = mixinColor(\n class {\n constructor(public _elementRef: ElementRef) {}\n }\n);\n\n@Component({\n selector: 'mtx-colorpicker-content',\n templateUrl: './colorpicker-content.html',\n styleUrls: ['colorpicker-content.scss'],\n host: {\n 'class': 'mtx-colorpicker-content',\n '[@transformPanel]': '_animationState',\n '(@transformPanel.done)': '_animationDone.next()',\n },\n animations: [mtxColorpickerAnimations.transformPanel],\n exportAs: 'mtxColorpickerContent',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n inputs: ['color'],\n})\nexport class MtxColorpickerContent\n extends _MtxColorpickerContentBase\n implements OnDestroy, CanColor\n{\n picker!: MtxColorpicker;\n\n /** Current state of the animation. */\n _animationState: 'enter-dropdown' | 'void' = 'enter-dropdown';\n\n /** Emits when an animation has finished. */\n readonly _animationDone = new Subject<void>();\n\n constructor(elementRef: ElementRef, private _changeDetectorRef: ChangeDetectorRef) {\n super(elementRef);\n }\n\n _startExitAnimation() {\n this._animationState = 'void';\n this._changeDetectorRef.markForCheck();\n }\n\n ngOnDestroy() {\n this._animationDone.complete();\n }\n\n getColorString(e: ColorEvent): string {\n return {\n hex: e.color.rgb.a === 1 ? e.color.hex : new TinyColor(e.color.rgb).toHex8String(),\n rgb: new TinyColor(e.color.rgb).toRgbString(),\n hsl: new TinyColor(e.color.hsl).toHslString(),\n hsv: new TinyColor(e.color.hsv).toHsvString(),\n }[this.picker.format];\n }\n}\n\n@Component({\n selector: 'mtx-colorpicker',\n template: '',\n exportAs: 'mtxColorpicker',\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n})\nexport class MtxColorpicker implements OnChanges, OnDestroy {\n private _scrollStrategy: () => ScrollStrategy;\n private _inputStateChanges = Subscription.EMPTY;\n\n /** Custom colorpicker content set by the consumer. */\n @Input() content!: TemplateRef<any>;\n\n /** Emits when the colorpicker has been opened. */\n @Output('opened') openedStream: EventEmitter<void> = new EventEmitter<void>();\n\n /** Emits when the colorpicker has been closed. */\n @Output('closed') closedStream: EventEmitter<void> = new EventEmitter<void>();\n\n @Input() get disabled() {\n return this._disabled === undefined && this.pickerInput\n ? this.pickerInput.disabled\n : !!this._disabled;\n }\n set disabled(value: boolean) {\n const newValue = coerceBooleanProperty(value);\n\n if (newValue !== this._disabled) {\n this._disabled = newValue;\n this._disabledChange.next(newValue);\n }\n }\n private _disabled!: boolean;\n\n /** Preferred position of the colorpicker in the X axis. */\n @Input()\n xPosition: ColorpickerDropdownPositionX = 'start';\n\n /** Preferred position of the colorpicker in the Y axis. */\n @Input()\n yPosition: ColorpickerDropdownPositionY = 'below';\n\n /**\n * Whether to restore focus to the previously-focused element when the panel is closed.\n * Note that automatic focus restoration is an accessibility feature and it is recommended that\n * you provide your own equivalent, if you decide to turn it off.\n */\n @Input()\n get restoreFocus(): boolean {\n return this._restoreFocus;\n }\n set restoreFocus(value: boolean) {\n this._restoreFocus = coerceBooleanProperty(value);\n }\n private _restoreFocus = true;\n\n /** Whether the panel is open. */\n @Input()\n get opened(): boolean {\n return this._opened;\n }\n set opened(value: boolean) {\n coerceBooleanProperty(value) ? this.open() : this.close();\n }\n private _opened = false;\n\n /** The id for the colorpicker panel. */\n id = `mtx-colorpicker-${colorpickerUid++}`;\n\n /** Color palette to use on the colorpicker's panel. */\n @Input()\n get color(): ThemePalette {\n return this._color || (this.pickerInput ? this.pickerInput.getThemePalette() : undefined);\n }\n set color(value: ThemePalette) {\n this._color = value;\n }\n private _color: ThemePalette;\n\n /** The input and output color format. */\n @Input()\n get format(): ColorFormat {\n return this._format || this.pickerInput.format;\n }\n set format(value: ColorFormat) {\n this._format = value;\n }\n _format!: ColorFormat;\n\n /** The currently selected color. */\n get selected(): string {\n return this._validSelected;\n }\n set selected(value: string) {\n this._validSelected = value;\n }\n private _validSelected: string = '';\n\n /** A reference to the overlay when the picker is opened as a popup. */\n private _overlayRef!: OverlayRef | null;\n\n /** Reference to the component instance rendered in the overlay. */\n private _componentRef!: ComponentRef<MtxColorpickerContent> | null;\n\n /** The element that was focused before the colorpicker was opened. */\n private _focusedElementBeforeOpen: HTMLElement | null = null;\n\n /** Unique class that will be added to the backdrop so that the test harnesses can look it up. */\n private _backdropHarnessClass = `${this.id}-backdrop`;\n\n /** The input element this colorpicker is associated with. */\n pickerInput!: MtxColorpickerInput;\n\n /** Emits when the datepicker is disabled. */\n readonly _disabledChange = new Subject<boolean>();\n\n /** Emits new selected color when selected color changes. */\n readonly _selectedChanged = new Subject<string>();\n\n constructor(\n private _overlay: Overlay,\n private _ngZone: NgZone,\n private _viewContainerRef: ViewContainerRef,\n @Inject(MTX_COLORPICKER_SCROLL_STRATEGY) scrollStrategy: any,\n @Optional() private _dir: Directionality,\n @Optional() @Inject(DOCUMENT) private _document: any\n ) {\n this._scrollStrategy = scrollStrategy;\n }\n\n ngOnChanges() {}\n\n ngOnDestroy() {\n this._destroyOverlay();\n this.close();\n this._inputStateChanges.unsubscribe();\n this._disabledChange.complete();\n }\n\n /** Selects the given color. */\n select(nextVal: string): void {\n const oldValue = this.selected;\n this.selected = nextVal;\n\n // TODO: `nextVal` should compare with `oldValue`\n this._selectedChanged.next(nextVal);\n }\n\n /**\n * Register an input with this colorpicker.\n * @param input The colorpicker input to register with this colorpicker.\n */\n registerInput(input: MtxColorpickerInput): void {\n if (this.pickerInput) {\n throw Error('A Colorpicker can only be associated with a single input.');\n }\n this.pickerInput = input;\n this._inputStateChanges = input._valueChange.subscribe(\n (value: string) => (this.selected = value)\n );\n }\n\n /** Open the panel. */\n open(): void {\n if (this._opened || this.disabled) {\n return;\n }\n if (!this.pickerInput) {\n throw Error('Attempted to open an Colorpicker with no associated input.');\n }\n\n if (this._document) {\n this._focusedElementBeforeOpen = this._document.activeElement;\n }\n\n this._openOverlay();\n this._opened = true;\n this.openedStream.emit();\n }\n\n /** Close the panel. */\n close(): void {\n if (!this._opened) {\n return;\n }\n\n if (this._componentRef) {\n const instance = this._componentRef.instance;\n instance._startExitAnimation();\n instance._animationDone.pipe(take(1)).subscribe(() => this._destroyOverlay());\n }\n\n const completeClose = () => {\n // The `_opened` could've been reset already if\n // we got two events in quick succession.\n if (this._opened) {\n this._opened = false;\n this.closedStream.emit();\n this._focusedElementBeforeOpen = null;\n }\n };\n\n if (\n this._restoreFocus &&\n this._focusedElementBeforeOpen &&\n typeof this._focusedElementBeforeOpen.focus === 'function'\n ) {\n // Because IE moves focus asynchronously, we can't count on it being restored before we've\n // marked the colorpicker as closed. If the event fires out of sequence and the element that\n // we're refocusing opens the colorpicker on focus, the user could be stuck with not being\n // able to close the panel at all. We work around it by making the logic, that marks\n // the colorpicker as closed, async as well.\n this._focusedElementBeforeOpen.focus();\n setTimeout(completeClose);\n } else {\n completeClose();\n }\n }\n\n /** Forwards relevant values from the colorpicker to the colorpicker content inside the overlay. */\n protected _forwardContentValues(instance: MtxColorpickerContent) {\n instance.picker = this;\n instance.color = this.color;\n }\n\n /** Open the colopicker as a popup. */\n private _openOverlay(): void {\n this._destroyOverlay();\n\n const labelId = this.pickerInput.getOverlayLabelId();\n const portal = new ComponentPortal<MtxColorpickerContent>(\n MtxColorpickerContent,\n this._viewContainerRef\n );\n const overlayRef = (this._overlayRef = this._overlay.create(\n new OverlayConfig({\n positionStrategy: this._getDropdownStrategy(),\n hasBackdrop: true,\n backdropClass: ['mat-overlay-transparent-backdrop', this._backdropHarnessClass],\n direction: this._dir,\n scrollStrategy: this._scrollStrategy(),\n panelClass: `mtx-colorpicker-popup`,\n })\n ));\n const overlayElement = overlayRef.overlayElement;\n overlayElement.setAttribute('role', 'dialog');\n\n if (labelId) {\n overlayElement.setAttribute('aria-labelledby', labelId);\n }\n\n this._getCloseStream(overlayRef).subscribe(event => {\n if (event) {\n event.preventDefault();\n }\n this.close();\n });\n\n this._componentRef = overlayRef.attach(portal);\n this._forwardContentValues(this._componentRef.instance);\n\n // Update the position once the panel has rendered. Only relevant in dropdown mode.\n this._ngZone.onStable.pipe(take(1)).subscribe(() => overlayRef.updatePosition());\n }\n\n /** Destroys the current overlay. */\n private _destroyOverlay() {\n if (this._overlayRef) {\n this._overlayRef.dispose();\n this._overlayRef = this._componentRef = null;\n }\n }\n\n /** Gets a position strategy that will open the panel as a dropdown. */\n private _getDropdownStrategy() {\n const strategy = this._overlay\n .position()\n .flexibleConnectedTo(this.pickerInput.getConnectedOverlayOrigin())\n .withTransformOriginOn('.mtx-colorpicker-content')\n .withFlexibleDimensions(false)\n .withViewportMargin(8)\n .withLockedPosition();\n\n return this._setConnectedPositions(strategy);\n }\n\n /** Sets the positions of the colorpicker in dropdown mode based on the current configuration. */\n private _setConnectedPositions(strategy: FlexibleConnectedPositionStrategy) {\n const primaryX = this.xPosition === 'end' ? 'end' : 'start';\n const secondaryX = primaryX === 'start' ? 'end' : 'start';\n const primaryY = this.yPosition === 'above' ? 'bottom' : 'top';\n const secondaryY = primaryY === 'top' ? 'bottom' : 'top';\n\n return strategy.withPositions([\n {\n originX: primaryX,\n originY: secondaryY,\n overlayX: primaryX,\n overlayY: primaryY,\n },\n {\n originX: primaryX,\n originY: primaryY,\n overlayX: primaryX,\n overlayY: secondaryY,\n },\n {\n originX: secondaryX,\n originY: secondaryY,\n overlayX: secondaryX,\n overlayY: primaryY,\n },\n {\n originX: secondaryX,\n originY: primaryY,\n overlayX: secondaryX,\n overlayY: secondaryY,\n },\n ]);\n }\n\n /** Gets an observable that will emit when the overlay is supposed to be closed. */\n private _getCloseStream(overlayRef: OverlayRef) {\n return merge(\n overlayRef.backdropClick(),\n overlayRef.detachments(),\n overlayRef.keydownEvents().pipe(\n filter(event => {\n // Closing on alt + up is only valid when there's an input associated with the colorpicker.\n return (\n (event.keyCode === ESCAPE && !hasModifierKey(event)) ||\n (this.pickerInput && hasModifierKey(event, 'altKey') && event.keyCode === UP_ARROW)\n );\n })\n )\n );\n }\n\n static ngAcceptInputType_disabled: BooleanInput;\n}\n","<ng-template [ngIf]=\"picker.content\" [ngIfElse]=\"default\"\n [ngTemplateOutlet]=\"picker.content\">\n</ng-template>\n<ng-template #default>\n <color-chrome [color]=\"picker.selected\"\n (onChangeComplete)=\"picker.select(getColorString($event))\">\n </color-chrome>\n</ng-template>\n","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { OverlayModule } from '@angular/cdk/overlay';\nimport { A11yModule } from '@angular/cdk/a11y';\nimport { PortalModule } from '@angular/cdk/portal';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MtxColorpickerInput } from './colorpicker-input';\nimport { MtxColorpickerToggle, MtxColorpickerToggleIcon } from './colorpicker-toggle';\nimport {\n MtxColorpicker,\n MtxColorpickerContent,\n MTX_COLORPICKER_SCROLL_STRATEGY_FACTORY_PROVIDER,\n} from './colorpicker';\n\nimport { ColorChromeModule } from 'ngx-color/chrome';\n\n@NgModule({\n imports: [\n CommonModule,\n OverlayModule,\n A11yModule,\n PortalModule,\n MatButtonModule,\n ColorChromeModule,\n ],\n exports: [\n MtxColorpicker,\n MtxColorpickerContent,\n MtxColorpickerInput,\n MtxColorpickerToggle,\n MtxColorpickerToggleIcon,\n ],\n declarations: [\n MtxColorpicker,\n MtxColorpickerContent,\n MtxColorpickerInput,\n MtxColorpickerToggle,\n MtxColorpickerToggleIcon,\n ],\n providers: [MTX_COLORPICKER_SCROLL_STRATEGY_FACTORY_PROVIDER],\n})\nexport class MtxColorpickerModule {}\n","/**\n * Generated bundle index. Do not ed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CD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"mtxColorpicker.mjs","sources":["../../../projects/extensions/colorpicker/colorpicker-input.ts","../../../projects/extensions/colorpicker/colorpicker-toggle.ts","../../../projects/extensions/colorpicker/colorpicker-toggle.html","../../../projects/extensions/colorpicker/colorpicker-animations.ts","../../../projects/extensions/colorpicker/colorpicker.ts","../../../projects/extensions/colorpicker/colorpicker-content.html","../../../projects/extensions/colorpicker/colorpicker-module.ts","../../../projects/extensions/colorpicker/mtxColorpicker.ts"],"sourcesContent":["import { BooleanInput, coerceBooleanProperty } from '@angular/cdk/coercion';\nimport { DOWN_ARROW } from '@angular/cdk/keycodes';\nimport {\n AfterViewInit,\n Directive,\n ElementRef,\n EventEmitter,\n forwardRef,\n Input,\n OnDestroy,\n Optional,\n Output,\n} from '@angular/core';\nimport {\n AbstractControl,\n ControlValueAccessor,\n NG_VALIDATORS,\n NG_VALUE_ACCESSOR,\n ValidationErrors,\n ValidatorFn,\n Validators,\n} from '@angular/forms';\nimport { ThemePalette } from '@angular/material/core';\nimport { MatFormField } from '@angular/material/form-field';\nimport { MAT_INPUT_VALUE_ACCESSOR } from '@angular/material/input';\nimport { Subscription } from 'rxjs';\nimport { MtxColorpicker } from './colorpicker';\n\nexport class MtxColorPickerInputEvent {\n /** The new value for the target colorpicker input. */\n value: string | null;\n\n constructor(\n /** Reference to the colorpicker input component that emitted the event. */\n public target: MtxColorpickerInput,\n /** Reference to the native input element associated with the colorpicker input. */\n public targetElement: HTMLElement\n ) {\n this.value = this.target.value;\n }\n}\n\nexport const MTX_COLORPICKER_VALUE_ACCESSOR: any = {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => MtxColorpickerInput),\n multi: true,\n};\n\nexport const MTX_COLORPICKER_VALIDATORS: any = {\n provide: NG_VALIDATORS,\n useExisting: forwardRef(() => MtxColorpickerInput),\n multi: true,\n};\n\nexport type ColorFormat = 'hex' | 'rgb' | 'hsl' | 'hsv';\n\n@Directive({\n selector: 'input[mtxColorpicker]',\n providers: [\n MTX_COLORPICKER_VALUE_ACCESSOR,\n MTX_COLORPICKER_VALIDATORS,\n { provide: MAT_INPUT_VALUE_ACCESSOR, useExisting: MtxColorpickerInput },\n ],\n host: {\n 'class': 'mtx-colorpicker-input',\n '[attr.aria-haspopup]': '_picker ? \"dialog\" : null',\n '[attr.aria-owns]': '(_picker?.opened && _picker.id) || null',\n '[disabled]': 'disabled',\n '(input)': '_onInput($event.target.value)',\n '(change)': '_onChange()',\n '(blur)': '_onBlur()',\n '(keydown)': '_onKeydown($event)',\n },\n exportAs: 'mtxColorpickerInput',\n})\nexport class MtxColorpickerInput implements ControlValueAccessor, AfterViewInit, OnDestroy {\n /** Whether the component has been initialized. */\n private _isInitialized!: boolean;\n\n @Input()\n set mtxColorpicker(value: MtxColorpicker) {\n if (!value) {\n return;\n }\n\n this._picker = value;\n this._picker.registerInput(this);\n this._pickerSubscription.unsubscribe();\n\n this._pickerSubscription = this._picker._selectedChanged.subscribe((selected: string) => {\n this.value = selected;\n this._cvaOnChange(selected);\n this._onTouched();\n this.colorInput.emit(new MtxColorPickerInputEvent(this, this._elementRef.nativeElement));\n this.colorChange.emit(new MtxColorPickerInputEvent(this, this._elementRef.nativeElement));\n });\n }\n _picker!: MtxColorpicker;\n\n /** Whether the colorpicker-input is disabled. */\n @Input()\n get disabled(): boolean {\n return !!this._disabled;\n }\n set disabled(value: boolean) {\n const newValue = coerceBooleanProperty(value);\n const element = this._elementRef.nativeElement;\n\n if (this._disabled !== newValue) {\n this._disabled = newValue;\n this._disabledChange.emit(newValue);\n }\n\n // We need to null check the `blur` method, because it's undefined during SSR.\n // In Ivy static bindings are invoked earlier, before the element is attached to the DOM.\n // This can cause an error to be thrown in some browsers (IE/Edge) which assert that the\n // element has been inserted.\n if (newValue && this._isInitialized && element.blur) {\n // Normally, native input elements automatically blur if they turn disabled. This behavior\n // is problematic, because it would mean that it triggers another change detection cycle,\n // which then causes a changed after checked error if the input element was focused before.\n element.blur();\n }\n }\n private _disabled!: boolean;\n\n /** The value of the input. */\n @Input()\n get value(): string | null {\n return this._value;\n }\n set value(value: string | null) {\n const oldValue = this.value;\n this._value = value;\n this._formatValue(value);\n\n this._valueChange.emit(value);\n }\n private _value!: string | null;\n\n /** The input and output color format. */\n @Input() format: ColorFormat = 'hex';\n\n /** Emits when a `change` event is fired on this `<input>`. */\n @Output() readonly colorChange: EventEmitter<MtxColorPickerInputEvent> =\n new EventEmitter<MtxColorPickerInputEvent>();\n\n /** Emits when an `input` event is fired on this `<input>`. */\n @Output() readonly colorInput: EventEmitter<MtxColorPickerInputEvent> =\n new EventEmitter<MtxColorPickerInputEvent>();\n\n /** Emits when the disabled state has changed */\n _disabledChange = new EventEmitter<boolean>();\n\n /** Emits when the value changes (either due to user input or programmatic change). */\n _valueChange = new EventEmitter<string | null>();\n\n _onTouched = () => {};\n\n _validatorOnChange = () => {};\n\n private _cvaOnChange: (value: any) => void = () => {};\n\n private _pickerSubscription = Subscription.EMPTY;\n\n /** The combined form control validator for this input. */\n private _validator: ValidatorFn | null = Validators.compose([]);\n\n /** Whether the last value set on the input was valid. */\n private _lastValueValid = false;\n\n constructor(\n private _elementRef: ElementRef<HTMLInputElement>,\n @Optional() private _formField: MatFormField\n ) {}\n\n ngAfterViewInit() {\n this._isInitialized = true;\n }\n\n ngOnDestroy() {\n this._pickerSubscription.unsubscribe();\n this._valueChange.complete();\n this._disabledChange.complete();\n }\n\n registerOnValidatorChange(fn: () => void): void {\n this._validatorOnChange = fn;\n }\n\n /** @docs-private */\n validate(c: AbstractControl): ValidationErrors | null {\n return this._validator ? this._validator(c) : null;\n }\n\n /**\n * @deprecated\n * @breaking-change 8.0.0 Use `getConnectedOverlayOrigin` instead\n */\n getPopupConnectionElementRef(): ElementRef {\n return this.getConnectedOverlayOrigin();\n }\n\n /**\n * Gets the element that the colorpicker popup should be connected to.\n * @return The element to connect the popup to.\n */\n getConnectedOverlayOrigin(): ElementRef {\n return this._formField ? this._formField.getConnectedOverlayOrigin() : this._elementRef;\n }\n\n /** Gets the ID of an element that should be used a description for the overlay. */\n getOverlayLabelId(): string | null {\n if (this._formField) {\n return this._formField.getLabelId();\n }\n\n return this._elementRef.nativeElement.getAttribute('aria-labelledby');\n }\n\n // Implemented as part of ControlValueAccessor.\n writeValue(value: string): void {\n this.value = value;\n }\n\n // Implemented as part of ControlValueAccessor.\n registerOnChange(fn: (value: any) => void): void {\n this._cvaOnChange = fn;\n }\n\n // Implemented as part of ControlValueAccessor.\n registerOnTouched(fn: () => void): void {\n this._onTouched = fn;\n }\n\n // Implemented as part of ControlValueAccessor.\n setDisabledState(isDisabled: boolean): void {\n this.disabled = isDisabled;\n }\n\n _onKeydown(event: KeyboardEvent) {\n const isAltDownArrow = event.altKey && event.keyCode === DOWN_ARROW;\n\n if (this._picker && isAltDownArrow && !this._elementRef.nativeElement.readOnly) {\n this._picker.open();\n event.preventDefault();\n }\n }\n\n /** Handles blur events on the input. */\n _onBlur() {\n // Reformat the input only if we have a valid value.\n if (this.value) {\n this._formatValue(this.value);\n }\n\n this._onTouched();\n }\n\n _onInput(value: string) {\n const nextValue = value;\n\n this._value = nextValue;\n this._cvaOnChange(nextValue);\n this._valueChange.emit(nextValue);\n this.colorInput.emit(new MtxColorPickerInputEvent(this, this._elementRef.nativeElement));\n }\n\n _onChange() {\n this.colorChange.emit(new MtxColorPickerInputEvent(this, this._elementRef.nativeElement));\n }\n\n /** Returns the palette used by the input's form field, if any. */\n getThemePalette(): ThemePalette {\n return this._formField ? this._formField.color : undefined;\n }\n\n /** TODO: Formats a value and sets it on the input element. */\n private _formatValue(value: string | null) {\n this._elementRef.nativeElement.value = value ? value : '';\n }\n\n // Accept `any` to avoid conflicts with other directives on `<input>` that\n // may accept different types.\n static ngAcceptInputType_value: any;\n static ngAcceptInputType_disabled: BooleanInput;\n}\n","import { BooleanInput, coerceBooleanProperty } from '@angular/cdk/coercion';\nimport {\n AfterContentInit,\n Attribute,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ContentChild,\n Directive,\n Input,\n OnChanges,\n OnDestroy,\n SimpleChanges,\n ViewChild,\n ViewEncapsulation,\n} from '@angular/core';\nimport { MatButton } from '@angular/material/button';\nimport { Subscription, of as observableOf, merge, Observable } from 'rxjs';\nimport { MtxColorpicker } from './colorpicker';\n\n/** Can be used to override the icon of a `mtxColorpickerToggle`. */\n@Directive({\n selector: '[mtxColorpickerToggleIcon]',\n})\nexport class MtxColorpickerToggleIcon {}\n\n@Component({\n selector: 'mtx-colorpicker-toggle',\n templateUrl: './colorpicker-toggle.html',\n styleUrls: ['./colorpicker-toggle.scss'],\n host: {\n 'class': 'mtx-colorpicker-toggle',\n '[attr.tabindex]': 'null',\n '[class.mtx-colorpicker-toggle-active]': 'picker && picker.opened',\n '[class.mat-accent]': 'picker && picker.color === \"accent\"',\n '[class.mat-warn]': 'picker && picker.color === \"warn\"',\n // Bind the `click` on the host, rather than the inner `button`, so that we can call\n // `stopPropagation` on it without affecting the user's `click` handlers. We need to stop\n // it so that the input doesn't get focused automatically by the form field (See #21836).\n '(click)': '_open($event)',\n },\n exportAs: 'mtxColorpickerToggle',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class MtxColorpickerToggle implements AfterContentInit, OnChanges, OnDestroy {\n private _stateChanges = Subscription.EMPTY;\n\n /** Colorpicker instance that the button will toggle. */\n @Input('for') picker!: MtxColorpicker;\n\n /** Tabindex for the toggle. */\n @Input() tabIndex: number | null;\n\n /** Screen-reader label for the button. */\n @Input('aria-label') ariaLabel!: string;\n\n /** Whether the toggle button is disabled. */\n @Input()\n get disabled(): boolean {\n if (this._disabled == null && this.picker) {\n return this.picker.disabled;\n }\n\n return !!this._disabled;\n }\n set disabled(value: boolean) {\n this._disabled = coerceBooleanProperty(value);\n }\n private _disabled!: boolean;\n\n /** Whether ripples on the toggle should be disabled. */\n @Input() disableRipple!: boolean;\n\n /** Custom icon set by the consumer. */\n @ContentChild(MtxColorpickerToggleIcon) _customIcon!: MtxColorpickerToggleIcon;\n\n /** Underlying button element. */\n @ViewChild('button') _button!: MatButton;\n\n constructor(\n private _changeDetectorRef: ChangeDetectorRef,\n @Attribute('tabindex') defaultTabIndex: string\n ) {\n const parsedTabIndex = Number(defaultTabIndex);\n this.tabIndex = parsedTabIndex || parsedTabIndex === 0 ? parsedTabIndex : null;\n }\n\n ngOnChanges(changes: SimpleChanges): void {\n if (changes.picker) {\n this._watchStateChanges();\n }\n }\n\n ngOnDestroy() {\n this._stateChanges.unsubscribe();\n }\n\n ngAfterContentInit() {\n this._watchStateChanges();\n }\n\n _open(event: Event): void {\n if (this.picker && !this.disabled) {\n this.picker.open();\n event.stopPropagation();\n }\n }\n\n private _watchStateChanges() {\n const pickerDisabled = this.picker ? this.picker._disabledChange : observableOf();\n const inputDisabled =\n this.picker && this.picker.pickerInput\n ? this.picker.pickerInput._disabledChange\n : observableOf();\n const pickerToggled = this.picker\n ? merge(this.picker.openedStream, this.picker.closedStream)\n : observableOf();\n\n this._stateChanges.unsubscribe();\n this._stateChanges = merge(\n pickerDisabled as Observable<void>,\n inputDisabled as Observable<void>,\n pickerToggled\n ).subscribe(() => this._changeDetectorRef.markForCheck());\n }\n\n static ngAcceptInputType_disabled: BooleanInput;\n static ngAcceptInputType_disableRipple: BooleanInput;\n}\n","<button #button\n mat-icon-button\n type=\"button\"\n [attr.aria-haspopup]=\"picker ? 'dialog' : null\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.tabindex]=\"disabled ? -1 : tabIndex\"\n [disabled]=\"disabled\"\n [disableRipple]=\"disableRipple\">\n\n <svg *ngIf=\"!_customIcon\"\n class=\"mtx-colorpicker-toggle-default-icon\"\n viewBox=\"0 0 24 24\"\n width=\"24px\"\n height=\"24px\"\n fill=\"currentColor\"\n focusable=\"false\">\n <path\n d=\"M17.5,12A1.5,1.5 0 0,1 16,10.5A1.5,1.5 0 0,1 17.5,9A1.5,1.5 0 0,1 19,10.5A1.5,1.5 0 0,1 17.5,12M14.5,8A1.5,1.5 0 0,1 13,6.5A1.5,1.5 0 0,1 14.5,5A1.5,1.5 0 0,1 16,6.5A1.5,1.5 0 0,1 14.5,8M9.5,8A1.5,1.5 0 0,1 8,6.5A1.5,1.5 0 0,1 9.5,5A1.5,1.5 0 0,1 11,6.5A1.5,1.5 0 0,1 9.5,8M6.5,12A1.5,1.5 0 0,1 5,10.5A1.5,1.5 0 0,1 6.5,9A1.5,1.5 0 0,1 8,10.5A1.5,1.5 0 0,1 6.5,12M12,3A9,9 0 0,0 3,12A9,9 0 0,0 12,21A1.5,1.5 0 0,0 13.5,19.5C13.5,19.11 13.35,18.76 13.11,18.5C12.88,18.23 12.73,17.88 12.73,17.5A1.5,1.5 0 0,1 14.23,16H16A5,5 0 0,0 21,11C21,6.58 16.97,3 12,3Z\" />\n </svg>\n\n <ng-content select=\"[mtxColorpickerToggleIcon]\"></ng-content>\n</button>\n","import {\n animate,\n style,\n transition,\n trigger,\n keyframes,\n AnimationTriggerMetadata,\n} from '@angular/animations';\n\n/**\n * Animations used by the colorpicker.\n * @docs-private\n */\nexport const mtxColorpickerAnimations: {\n readonly transformPanel: AnimationTriggerMetadata;\n} = {\n /** Transforms the height of the colorpicker's panel. */\n transformPanel: trigger('transformPanel', [\n transition(\n 'void => enter-dropdown',\n animate(\n '120ms cubic-bezier(0, 0, 0.2, 1)',\n keyframes([\n style({ opacity: 0, transform: 'scale(1, 0.8)' }),\n style({ opacity: 1, transform: 'scale(1, 1)' }),\n ])\n )\n ),\n transition('* => void', animate('100ms linear', style({ opacity: 0 }))),\n ]),\n};\n","import { Directionality } from '@angular/cdk/bidi';\nimport { BooleanInput, coerceBooleanProperty } from '@angular/cdk/coercion';\nimport { ESCAPE, hasModifierKey, UP_ARROW } from '@angular/cdk/keycodes';\nimport {\n ScrollStrategy,\n OverlayConfig,\n Overlay,\n OverlayRef,\n FlexibleConnectedPositionStrategy,\n} from '@angular/cdk/overlay';\nimport { ComponentPortal } from '@angular/cdk/portal';\nimport { DOCUMENT } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ComponentRef,\n ElementRef,\n EventEmitter,\n Inject,\n InjectionToken,\n Input,\n NgZone,\n OnChanges,\n OnDestroy,\n Optional,\n Output,\n TemplateRef,\n ViewContainerRef,\n ViewEncapsulation,\n} from '@angular/core';\nimport { CanColor, mixinColor, ThemePalette } from '@angular/material/core';\nimport { Subject, Subscription, merge } from 'rxjs';\nimport { filter, take } from 'rxjs/operators';\nimport { mtxColorpickerAnimations } from './colorpicker-animations';\nimport { ColorFormat, MtxColorpickerInput } from './colorpicker-input';\n\nimport { ColorEvent } from 'ngx-color';\n\nimport { TinyColor } from '@ctrl/tinycolor';\n\n/** Used to generate a unique ID for each colorpicker instance. */\nlet colorpickerUid = 0;\n\n/** Injection token that determines the scroll handling while the panel is open. */\nexport const MTX_COLORPICKER_SCROLL_STRATEGY = new InjectionToken<() => ScrollStrategy>(\n 'mtx-colorpicker-scroll-strategy'\n);\n\nexport function MTX_COLORPICKER_SCROLL_STRATEGY_FACTORY(overlay: Overlay): () => ScrollStrategy {\n return () => overlay.scrollStrategies.reposition();\n}\n\n/** Possible positions for the colorpicker dropdown along the X axis. */\nexport type ColorpickerDropdownPositionX = 'start' | 'end';\n\n/** Possible positions for the colorpicker dropdown along the Y axis. */\nexport type ColorpickerDropdownPositionY = 'above' | 'below';\n\nexport const MTX_COLORPICKER_SCROLL_STRATEGY_FACTORY_PROVIDER = {\n provide: MTX_COLORPICKER_SCROLL_STRATEGY,\n deps: [Overlay],\n useFactory: MTX_COLORPICKER_SCROLL_STRATEGY_FACTORY,\n};\n\n// Boilerplate for applying mixins to MtxColorpickerContent.\n/** @docs-private */\nconst _MtxColorpickerContentBase = mixinColor(\n class {\n constructor(public _elementRef: ElementRef) {}\n }\n);\n\n@Component({\n selector: 'mtx-colorpicker-content',\n templateUrl: './colorpicker-content.html',\n styleUrls: ['colorpicker-content.scss'],\n host: {\n 'class': 'mtx-colorpicker-content',\n '[@transformPanel]': '_animationState',\n '(@transformPanel.done)': '_animationDone.next()',\n },\n animations: [mtxColorpickerAnimations.transformPanel],\n exportAs: 'mtxColorpickerContent',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n inputs: ['color'],\n})\nexport class MtxColorpickerContent\n extends _MtxColorpickerContentBase\n implements OnDestroy, CanColor\n{\n picker!: MtxColorpicker;\n\n /** Current state of the animation. */\n _animationState: 'enter-dropdown' | 'void' = 'enter-dropdown';\n\n /** Emits when an animation has finished. */\n readonly _animationDone = new Subject<void>();\n\n constructor(elementRef: ElementRef, private _changeDetectorRef: ChangeDetectorRef) {\n super(elementRef);\n }\n\n _startExitAnimation() {\n this._animationState = 'void';\n this._changeDetectorRef.markForCheck();\n }\n\n ngOnDestroy() {\n this._animationDone.complete();\n }\n\n getColorString(e: ColorEvent): string {\n return {\n hex: e.color.rgb.a === 1 ? e.color.hex : new TinyColor(e.color.rgb).toHex8String(),\n rgb: new TinyColor(e.color.rgb).toRgbString(),\n hsl: new TinyColor(e.color.hsl).toHslString(),\n hsv: new TinyColor(e.color.hsv).toHsvString(),\n }[this.picker.format];\n }\n}\n\n@Component({\n selector: 'mtx-colorpicker',\n template: '',\n exportAs: 'mtxColorpicker',\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n})\nexport class MtxColorpicker implements OnChanges, OnDestroy {\n private _scrollStrategy: () => ScrollStrategy;\n private _inputStateChanges = Subscription.EMPTY;\n\n /** Custom colorpicker content set by the consumer. */\n @Input() content!: TemplateRef<any>;\n\n /** Emits when the colorpicker has been opened. */\n @Output('opened') openedStream: EventEmitter<void> = new EventEmitter<void>();\n\n /** Emits when the colorpicker has been closed. */\n @Output('closed') closedStream: EventEmitter<void> = new EventEmitter<void>();\n\n @Input() get disabled() {\n return this._disabled === undefined && this.pickerInput\n ? this.pickerInput.disabled\n : !!this._disabled;\n }\n set disabled(value: boolean) {\n const newValue = coerceBooleanProperty(value);\n\n if (newValue !== this._disabled) {\n this._disabled = newValue;\n this._disabledChange.next(newValue);\n }\n }\n private _disabled!: boolean;\n\n /** Preferred position of the colorpicker in the X axis. */\n @Input()\n xPosition: ColorpickerDropdownPositionX = 'start';\n\n /** Preferred position of the colorpicker in the Y axis. */\n @Input()\n yPosition: ColorpickerDropdownPositionY = 'below';\n\n /**\n * Whether to restore focus to the previously-focused element when the panel is closed.\n * Note that automatic focus restoration is an accessibility feature and it is recommended that\n * you provide your own equivalent, if you decide to turn it off.\n */\n @Input()\n get restoreFocus(): boolean {\n return this._restoreFocus;\n }\n set restoreFocus(value: boolean) {\n this._restoreFocus = coerceBooleanProperty(value);\n }\n private _restoreFocus = true;\n\n /** Whether the panel is open. */\n @Input()\n get opened(): boolean {\n return this._opened;\n }\n set opened(value: boolean) {\n coerceBooleanProperty(value) ? this.open() : this.close();\n }\n private _opened = false;\n\n /** The id for the colorpicker panel. */\n id = `mtx-colorpicker-${colorpickerUid++}`;\n\n /** Color palette to use on the colorpicker's panel. */\n @Input()\n get color(): ThemePalette {\n return this._color || (this.pickerInput ? this.pickerInput.getThemePalette() : undefined);\n }\n set color(value: ThemePalette) {\n this._color = value;\n }\n private _color: ThemePalette;\n\n /** The input and output color format. */\n @Input()\n get format(): ColorFormat {\n return this._format || this.pickerInput.format;\n }\n set format(value: ColorFormat) {\n this._format = value;\n }\n _format!: ColorFormat;\n\n /** The currently selected color. */\n get selected(): string {\n return this._validSelected;\n }\n set selected(value: string) {\n this._validSelected = value;\n }\n private _validSelected: string = '';\n\n /** A reference to the overlay when the picker is opened as a popup. */\n private _overlayRef!: OverlayRef | null;\n\n /** Reference to the component instance rendered in the overlay. */\n private _componentRef!: ComponentRef<MtxColorpickerContent> | null;\n\n /** The element that was focused before the colorpicker was opened. */\n private _focusedElementBeforeOpen: HTMLElement | null = null;\n\n /** Unique class that will be added to the backdrop so that the test harnesses can look it up. */\n private _backdropHarnessClass = `${this.id}-backdrop`;\n\n /** The input element this colorpicker is associated with. */\n pickerInput!: MtxColorpickerInput;\n\n /** Emits when the datepicker is disabled. */\n readonly _disabledChange = new Subject<boolean>();\n\n /** Emits new selected color when selected color changes. */\n readonly _selectedChanged = new Subject<string>();\n\n constructor(\n private _overlay: Overlay,\n private _ngZone: NgZone,\n private _viewContainerRef: ViewContainerRef,\n @Inject(MTX_COLORPICKER_SCROLL_STRATEGY) scrollStrategy: any,\n @Optional() private _dir: Directionality,\n @Optional() @Inject(DOCUMENT) private _document: any\n ) {\n this._scrollStrategy = scrollStrategy;\n }\n\n ngOnChanges() {}\n\n ngOnDestroy() {\n this._destroyOverlay();\n this.close();\n this._inputStateChanges.unsubscribe();\n this._disabledChange.complete();\n }\n\n /** Selects the given color. */\n select(nextVal: string): void {\n const oldValue = this.selected;\n this.selected = nextVal;\n\n // TODO: `nextVal` should compare with `oldValue`\n this._selectedChanged.next(nextVal);\n }\n\n /**\n * Register an input with this colorpicker.\n * @param input The colorpicker input to register with this colorpicker.\n */\n registerInput(input: MtxColorpickerInput): void {\n if (this.pickerInput) {\n throw Error('A Colorpicker can only be associated with a single input.');\n }\n this.pickerInput = input;\n this._inputStateChanges = input._valueChange.subscribe(\n (value: string) => (this.selected = value)\n );\n }\n\n /** Open the panel. */\n open(): void {\n if (this._opened || this.disabled) {\n return;\n }\n if (!this.pickerInput) {\n throw Error('Attempted to open an Colorpicker with no associated input.');\n }\n\n if (this._document) {\n this._focusedElementBeforeOpen = this._document.activeElement;\n }\n\n this._openOverlay();\n this._opened = true;\n this.openedStream.emit();\n }\n\n /** Close the panel. */\n close(): void {\n if (!this._opened) {\n return;\n }\n\n if (this._componentRef) {\n const instance = this._componentRef.instance;\n instance._startExitAnimation();\n instance._animationDone.pipe(take(1)).subscribe(() => this._destroyOverlay());\n }\n\n const completeClose = () => {\n // The `_opened` could've been reset already if\n // we got two events in quick succession.\n if (this._opened) {\n this._opened = false;\n this.closedStream.emit();\n this._focusedElementBeforeOpen = null;\n }\n };\n\n if (\n this._restoreFocus &&\n this._focusedElementBeforeOpen &&\n typeof this._focusedElementBeforeOpen.focus === 'function'\n ) {\n // Because IE moves focus asynchronously, we can't count on it being restored before we've\n // marked the colorpicker as closed. If the event fires out of sequence and the element that\n // we're refocusing opens the colorpicker on focus, the user could be stuck with not being\n // able to close the panel at all. We work around it by making the logic, that marks\n // the colorpicker as closed, async as well.\n this._focusedElementBeforeOpen.focus();\n setTimeout(completeClose);\n } else {\n completeClose();\n }\n }\n\n /** Forwards relevant values from the colorpicker to the colorpicker content inside the overlay. */\n protected _forwardContentValues(instance: MtxColorpickerContent) {\n instance.picker = this;\n instance.color = this.color;\n }\n\n /** Open the colopicker as a popup. */\n private _openOverlay(): void {\n this._destroyOverlay();\n\n const labelId = this.pickerInput.getOverlayLabelId();\n const portal = new ComponentPortal<MtxColorpickerContent>(\n MtxColorpickerContent,\n this._viewContainerRef\n );\n const overlayRef = (this._overlayRef = this._overlay.create(\n new OverlayConfig({\n positionStrategy: this._getDropdownStrategy(),\n hasBackdrop: true,\n backdropClass: ['mat-overlay-transparent-backdrop', this._backdropHarnessClass],\n direction: this._dir,\n scrollStrategy: this._scrollStrategy(),\n panelClass: `mtx-colorpicker-popup`,\n })\n ));\n const overlayElement = overlayRef.overlayElement;\n overlayElement.setAttribute('role', 'dialog');\n\n if (labelId) {\n overlayElement.setAttribute('aria-labelledby', labelId);\n }\n\n this._getCloseStream(overlayRef).subscribe(event => {\n if (event) {\n event.preventDefault();\n }\n this.close();\n });\n\n this._componentRef = overlayRef.attach(portal);\n this._forwardContentValues(this._componentRef.instance);\n\n // Update the position once the panel has rendered. Only relevant in dropdown mode.\n this._ngZone.onStable.pipe(take(1)).subscribe(() => overlayRef.updatePosition());\n }\n\n /** Destroys the current overlay. */\n private _destroyOverlay() {\n if (this._overlayRef) {\n this._overlayRef.dispose();\n this._overlayRef = this._componentRef = null;\n }\n }\n\n /** Gets a position strategy that will open the panel as a dropdown. */\n private _getDropdownStrategy() {\n const strategy = this._overlay\n .position()\n .flexibleConnectedTo(this.pickerInput.getConnectedOverlayOrigin())\n .withTransformOriginOn('.mtx-colorpicker-content')\n .withFlexibleDimensions(false)\n .withViewportMargin(8)\n .withLockedPosition();\n\n return this._setConnectedPositions(strategy);\n }\n\n /** Sets the positions of the colorpicker in dropdown mode based on the current configuration. */\n private _setConnectedPositions(strategy: FlexibleConnectedPositionStrategy) {\n const primaryX = this.xPosition === 'end' ? 'end' : 'start';\n const secondaryX = primaryX === 'start' ? 'end' : 'start';\n const primaryY = this.yPosition === 'above' ? 'bottom' : 'top';\n const secondaryY = primaryY === 'top' ? 'bottom' : 'top';\n\n return strategy.withPositions([\n {\n originX: primaryX,\n originY: secondaryY,\n overlayX: primaryX,\n overlayY: primaryY,\n },\n {\n originX: primaryX,\n originY: primaryY,\n overlayX: primaryX,\n overlayY: secondaryY,\n },\n {\n originX: secondaryX,\n originY: secondaryY,\n overlayX: secondaryX,\n overlayY: primaryY,\n },\n {\n originX: secondaryX,\n originY: primaryY,\n overlayX: secondaryX,\n overlayY: secondaryY,\n },\n ]);\n }\n\n /** Gets an observable that will emit when the overlay is supposed to be closed. */\n private _getCloseStream(overlayRef: OverlayRef) {\n return merge(\n overlayRef.backdropClick(),\n overlayRef.detachments(),\n overlayRef.keydownEvents().pipe(\n filter(event => {\n // Closing on alt + up is only valid when there's an input associated with the colorpicker.\n return (\n (event.keyCode === ESCAPE && !hasModifierKey(event)) ||\n (this.pickerInput && hasModifierKey(event, 'altKey') && event.keyCode === UP_ARROW)\n );\n })\n )\n );\n }\n\n static ngAcceptInputType_disabled: BooleanInput;\n}\n","<ng-template [ngIf]=\"picker.content\" [ngIfElse]=\"default\"\n [ngTemplateOutlet]=\"picker.content\">\n</ng-template>\n<ng-template #default>\n <color-chrome [color]=\"picker.selected\"\n (onChangeComplete)=\"picker.select(getColorString($event))\">\n </color-chrome>\n</ng-template>\n","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { OverlayModule } from '@angular/cdk/overlay';\nimport { A11yModule } from '@angular/cdk/a11y';\nimport { PortalModule } from '@angular/cdk/portal';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MtxColorpickerInput } from './colorpicker-input';\nimport { MtxColorpickerToggle, MtxColorpickerToggleIcon } from './colorpicker-toggle';\nimport {\n MtxColorpicker,\n MtxColorpickerContent,\n MTX_COLORPICKER_SCROLL_STRATEGY_FACTORY_PROVIDER,\n} from './colorpicker';\n\nimport { ColorChromeModule } from 'ngx-color/chrome';\n\n@NgModule({\n imports: [\n CommonModule,\n OverlayModule,\n A11yModule,\n PortalModule,\n MatButtonModule,\n ColorChromeModule,\n ],\n exports: [\n MtxColorpicker,\n MtxColorpickerContent,\n MtxColorpickerInput,\n MtxColorpickerToggle,\n MtxColorpickerToggleIcon,\n ],\n declarations: [\n MtxColorpicker,\n MtxColorpickerContent,\n MtxColorpickerInput,\n MtxColorpickerToggle,\n MtxColorpickerToggleIcon,\n ],\n providers: [MTX_COLORPICKER_SCROLL_STRATEGY_FACTORY_PROVIDER],\n})\nexport class MtxColorpickerModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["observableOf","i1","i2"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;MA4Ba,wBAAwB,CAAA;AAInC,IAAA,WAAA;;IAES,MAA2B;;IAE3B,aAA0B,EAAA;QAF1B,IAAM,CAAA,MAAA,GAAN,MAAM,CAAqB;QAE3B,IAAa,CAAA,aAAA,GAAb,aAAa,CAAa;QAEjC,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC;KAChC;AACF,CAAA;AAEY,MAAA,8BAA8B,GAAQ;AACjD,IAAA,OAAO,EAAE,iBAAiB;AAC1B,IAAA,WAAW,EAAE,UAAU,CAAC,MAAM,mBAAmB,CAAC;AAClD,IAAA,KAAK,EAAE,IAAI;EACX;AAEW,MAAA,0BAA0B,GAAQ;AAC7C,IAAA,OAAO,EAAE,aAAa;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|
|
7
7
|
import { DOCUMENT, CommonModule } from '@angular/common';
|
|
8
8
|
import * as i0 from '@angular/core';
|
|
9
|
-
import { EventEmitter, Component, ViewEncapsulation, ChangeDetectionStrategy, Input, Output, Optional, Inject, Injectable, Directive, ElementRef, ViewChild, InjectionToken, inject, forwardRef, ContentChild, NgModule } from '@angular/core';
|
|
9
|
+
import { EventEmitter, Component, ViewEncapsulation, ChangeDetectionStrategy, Input, Output, Optional, Inject, Injectable, Directive, ElementRef, ViewChild, InjectionToken, inject, forwardRef, Attribute, ContentChild, NgModule } from '@angular/core';
|
|
10
10
|
import * as i4 from '@angular/material/button';
|
|
11
11
|
import { MatButtonModule } from '@angular/material/button';
|
|
12
12
|
import { UP_ARROW, DOWN_ARROW, ENTER, PAGE_DOWN, PAGE_UP, END, HOME, RIGHT_ARROW, LEFT_ARROW, ESCAPE, hasModifierKey } from '@angular/cdk/keycodes';
|
|
@@ -883,7 +883,8 @@ class MtxTimeInput {
|
|
|
883
883
|
return;
|
|
884
884
|
}
|
|
885
885
|
const value = coerceNumberProperty(this.inputElement?.value ?? null);
|
|
886
|
-
if
|
|
886
|
+
// if this._min === 0, we should allow 0
|
|
887
|
+
if (value || (this._min === 0 && value === 0)) {
|
|
887
888
|
const clampedValue = Math.min(Math.max(value, this._min), this._max);
|
|
888
889
|
if (clampedValue !== value) {
|
|
889
890
|
this.writeValue(clampedValue);
|
|
@@ -1140,12 +1141,12 @@ class MtxTime {
|
|
|
1140
1141
|
}
|
|
1141
1142
|
}
|
|
1142
1143
|
/** @nocollapse */ MtxTime.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: MtxTime, deps: [{ token: i1.DatetimeAdapter }, { token: i0.ChangeDetectorRef }, { token: MtxDatetimepickerIntl }], target: i0.ɵɵFactoryTarget.Component });
|
|
1143
|
-
/** @nocollapse */ MtxTime.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: MtxTime, selector: "mtx-time", inputs: { dateFilter: "dateFilter", interval: "interval", twelvehour: "twelvehour", AMPM: "AMPM", activeDate: "activeDate", selected: "selected", minDate: "minDate", maxDate: "maxDate", clockView: "clockView" }, outputs: { selectedChange: "selectedChange", activeDateChange: "activeDateChange", _userSelection: "_userSelection", ampmChange: "ampmChange", clockViewChange: "clockViewChange" }, host: { classAttribute: "mtx-time" }, viewQueries: [{ propertyName: "hourInputElement", first: true, predicate: ["hourInput"], descendants: true, read: (ElementRef) }, { propertyName: "hourInputDirective", first: true, predicate: ["hourInput"], descendants: true, read: MtxTimeInput }, { propertyName: "minuteInputElement", first: true, predicate: ["minuteInput"], descendants: true, read: (ElementRef) }, { propertyName: "minuteInputDirective", first: true, predicate: ["minuteInput"], descendants: true, read: MtxTimeInput }], exportAs: ["mtxTime"], usesOnChanges: true, ngImport: i0, template: "<div class=\"mtx-time-input-wrapper\">\n <div class=\"mtx-time-input-inner\">\n <input class=\"mtx-time-input\"\n [class.mtx-time-input-active]=\"clockView === 'hour'\"\n [class.mtx-time-input-warning]=\"!hourInput.valid\"\n #hourInput=\"mtxTimeInput\"\n type=\"text\"\n inputmode=\"numeric\"\n maxlength=\"2\"\n [timeMin]=\"twelvehour ? 1 : 0\"\n [timeMax]=\"twelvehour ? 12 : 23\"\n [timeValue]=\"hour\"\n (timeValueChanged)=\"handleHourInputChange($event)\"\n (focus)=\"handleFocus('hour')\" />\n\n <div class=\"mtx-time-seperator\">:</div>\n\n <input class=\"mtx-time-input\"\n [class.mtx-time-input-active]=\"clockView === 'minute'\"\n [class.mtx-time-input-warning]=\"!minuteInput.valid\"\n #minuteInput=\"mtxTimeInput\"\n type=\"text\"\n inputmode=\"numeric\"\n maxlength=\"2\"\n [timeMin]=\"0\"\n [timeMax]=\"59\"\n [timeValue]=\"minute\"\n (timeValueChanged)=\"handleMinuteInputChange($event)\"\n [timeInterval]=\"interval\"\n (focus)=\"handleFocus('minute')\" />\n\n <div *ngIf=\"twelvehour\" class=\"mtx-time-ampm\">\n <button mat-button type=\"button\" class=\"mtx-time-am\"\n [class.mtx-time-ampm-active]=\"AMPM === 'AM'\" aria-label=\"AM\"\n (keydown)=\"$event.stopPropagation()\"\n (click)=\"ampmChange.emit('AM')\">AM</button>\n <button mat-button type=\"button\" class=\"mtx-time-pm\"\n [class.mtx-time-ampm-active]=\"AMPM === 'PM'\" aria-label=\"PM\"\n (keydown)=\"$event.stopPropagation()\"\n (click)=\"ampmChange.emit('PM')\">PM</button>\n </div>\n </div>\n</div>\n\n<mtx-clock (selectedChange)=\"_timeSelected($event)\"\n (activeDateChange)=\"_onActiveDateChange($event)\"\n [dateFilter]=\"dateFilter\"\n [interval]=\"interval\"\n [maxDate]=\"maxDate\"\n [minDate]=\"minDate\"\n [selected]=\"selected\"\n [startView]=\"clockView\"\n [twelvehour]=\"twelvehour\">\n</mtx-clock>\n\n<div class=\"mtx-time-button-wrapper\">\n <button class=\"mtx-time-cancel-button\" mat-button type=\"button\" (click)=\"handleCancel()\">\n {{ _datetimepickerIntl.cancelLabel }}\n </button>\n <button class=\"mtx-time-ok-button\" mat-button type=\"button\" (click)=\"handleOk()\"\n [disabled]=\"minuteInputDirective?.invalid || hourInputDirective?.invalid\">\n {{ _datetimepickerIntl.okLabel }}\n </button>\n</div>\n", styles: [".mtx-time{display:block;outline:none;-webkit-user-select:none;user-select:none}.mtx-time-input-wrapper{padding:8px 0;text-align:center}.mtx-time-input-inner{display:inline-flex;height:56px}.mtx-time-input{box-sizing:border-box;width:72px;height:100%;padding:0;font-size:36px;text-align:center;border-radius:8px;border:2px solid transparent;-webkit-appearance:none;appearance:none;outline:none}.mtx-time-seperator{display:inline-flex;justify-content:center;align-items:center;width:24px;font-size:36px}.mtx-time-ampm{display:inline-flex;flex-direction:column;margin-left:12px}[dir=rtl] .mtx-time-ampm{margin-left:auto;margin-right:12px}.mtx-time-ampm .mtx-time-am,.mtx-time-ampm .mtx-time-pm{flex:1;width:40px;min-width:auto;padding:0;line-height:normal;border-width:1px;border-style:solid}.mtx-time-ampm .mtx-time-am{border-radius:8px 8px 0 0}.mtx-time-ampm .mtx-time-pm{border-radius:0 0 8px 8px;border-top:none}.mtx-time-button-wrapper{display:flex;justify-content:flex-end;padding-top:8px}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i4.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: MtxClock, selector: "mtx-clock", inputs: ["dateFilter", "interval", "twelvehour", "activeDate", "selected", "minDate", "maxDate", "startView"], outputs: ["selectedChange", "activeDateChange", "_userSelection"], exportAs: ["mtxClock"] }, { kind: "directive", type: MtxTimeInput, selector: "input.mtx-time-input", inputs: ["timeInterval", "timeMin", "timeMax", "timeValue"], outputs: ["timeValueChanged"], exportAs: ["mtxTimeInput"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1144
|
+
/** @nocollapse */ MtxTime.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: MtxTime, selector: "mtx-time", inputs: { dateFilter: "dateFilter", interval: "interval", twelvehour: "twelvehour", AMPM: "AMPM", activeDate: "activeDate", selected: "selected", minDate: "minDate", maxDate: "maxDate", clockView: "clockView" }, outputs: { selectedChange: "selectedChange", activeDateChange: "activeDateChange", _userSelection: "_userSelection", ampmChange: "ampmChange", clockViewChange: "clockViewChange" }, host: { classAttribute: "mtx-time" }, viewQueries: [{ propertyName: "hourInputElement", first: true, predicate: ["hourInput"], descendants: true, read: (ElementRef) }, { propertyName: "hourInputDirective", first: true, predicate: ["hourInput"], descendants: true, read: MtxTimeInput }, { propertyName: "minuteInputElement", first: true, predicate: ["minuteInput"], descendants: true, read: (ElementRef) }, { propertyName: "minuteInputDirective", first: true, predicate: ["minuteInput"], descendants: true, read: MtxTimeInput }], exportAs: ["mtxTime"], usesOnChanges: true, ngImport: i0, template: "<div class=\"mtx-time-input-wrapper\">\n <div class=\"mtx-time-input-inner\">\n <input class=\"mtx-time-input\"\n [class.mtx-time-input-active]=\"clockView === 'hour'\"\n [class.mtx-time-input-warning]=\"!hourInput.valid\"\n #hourInput=\"mtxTimeInput\"\n type=\"text\"\n inputmode=\"numeric\"\n maxlength=\"2\"\n [timeMin]=\"twelvehour ? 1 : 0\"\n [timeMax]=\"twelvehour ? 12 : 23\"\n [timeValue]=\"hour\"\n (timeValueChanged)=\"handleHourInputChange($event)\"\n (focus)=\"handleFocus('hour')\" />\n\n <div class=\"mtx-time-seperator\">:</div>\n\n <input class=\"mtx-time-input\"\n [class.mtx-time-input-active]=\"clockView === 'minute'\"\n [class.mtx-time-input-warning]=\"!minuteInput.valid\"\n #minuteInput=\"mtxTimeInput\"\n type=\"text\"\n inputmode=\"numeric\"\n maxlength=\"2\"\n [timeMin]=\"0\"\n [timeMax]=\"59\"\n [timeValue]=\"minute\"\n (timeValueChanged)=\"handleMinuteInputChange($event)\"\n [timeInterval]=\"interval\"\n (focus)=\"handleFocus('minute')\" />\n\n <div *ngIf=\"twelvehour\" class=\"mtx-time-ampm\">\n <button mat-button type=\"button\" class=\"mtx-time-am\"\n [class.mtx-time-ampm-active]=\"AMPM === 'AM'\" aria-label=\"AM\"\n (keydown)=\"$event.stopPropagation()\"\n (click)=\"ampmChange.emit('AM')\">AM</button>\n <button mat-button type=\"button\" class=\"mtx-time-pm\"\n [class.mtx-time-ampm-active]=\"AMPM === 'PM'\" aria-label=\"PM\"\n (keydown)=\"$event.stopPropagation()\"\n (click)=\"ampmChange.emit('PM')\">PM</button>\n </div>\n </div>\n</div>\n\n<mtx-clock (selectedChange)=\"_timeSelected($event)\"\n (activeDateChange)=\"_onActiveDateChange($event)\"\n [dateFilter]=\"dateFilter\"\n [interval]=\"interval\"\n [maxDate]=\"maxDate\"\n [minDate]=\"minDate\"\n [selected]=\"selected\"\n [startView]=\"clockView\"\n [twelvehour]=\"twelvehour\">\n</mtx-clock>\n\n<div class=\"mtx-time-button-wrapper\">\n <button class=\"mtx-time-cancel-button\" mat-button type=\"button\" (click)=\"handleCancel()\">\n {{ _datetimepickerIntl.cancelLabel }}\n </button>\n <button class=\"mtx-time-ok-button\" mat-button type=\"button\" (click)=\"handleOk()\"\n [disabled]=\"minuteInputDirective?.invalid || hourInputDirective?.invalid\">\n {{ _datetimepickerIntl.okLabel }}\n </button>\n</div>\n", styles: [".mtx-time{display:block;outline:none;-webkit-user-select:none;user-select:none}.mtx-time-input-wrapper{padding:8px 0;text-align:center}.mtx-time-input-inner{display:inline-flex;height:56px}.mtx-time-input{box-sizing:border-box;width:72px;height:100%;padding:0;font-size:36px;text-align:center;border-radius:8px;border:2px solid transparent;-webkit-appearance:none;appearance:none;outline:none}.mtx-time-seperator{display:inline-flex;justify-content:center;align-items:center;width:24px;font-size:36px}.mtx-time-ampm{display:inline-flex;flex-direction:column;margin-left:12px}[dir=rtl] .mtx-time-ampm{margin-left:auto;margin-right:12px}.mtx-time-ampm .mtx-time-am,.mtx-time-ampm .mtx-time-pm{flex:1;width:40px;min-width:auto;padding:0;line-height:normal;border-width:1px;border-style:solid}.mtx-time-ampm .mtx-time-am{border-radius:8px 8px 0 0}.mtx-time-ampm .mtx-time-pm{border-radius:0 0 8px 8px;border-top:none}.mtx-time-button-wrapper{display:flex;justify-content:flex-end;padding-top:8px}.mtx-time-button-wrapper .mat-button-base+.mat-button-base{margin-left:8px}[dir=rtl] .mtx-time-button-wrapper .mat-button-base+.mat-button-base{margin-left:0;margin-right:8px}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i4.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: MtxClock, selector: "mtx-clock", inputs: ["dateFilter", "interval", "twelvehour", "activeDate", "selected", "minDate", "maxDate", "startView"], outputs: ["selectedChange", "activeDateChange", "_userSelection"], exportAs: ["mtxClock"] }, { kind: "directive", type: MtxTimeInput, selector: "input.mtx-time-input", inputs: ["timeInterval", "timeMin", "timeMax", "timeValue"], outputs: ["timeValueChanged"], exportAs: ["mtxTimeInput"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1144
1145
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: MtxTime, decorators: [{
|
|
1145
1146
|
type: Component,
|
|
1146
1147
|
args: [{ selector: 'mtx-time', exportAs: 'mtxTime', host: {
|
|
1147
1148
|
class: 'mtx-time',
|
|
1148
|
-
}, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"mtx-time-input-wrapper\">\n <div class=\"mtx-time-input-inner\">\n <input class=\"mtx-time-input\"\n [class.mtx-time-input-active]=\"clockView === 'hour'\"\n [class.mtx-time-input-warning]=\"!hourInput.valid\"\n #hourInput=\"mtxTimeInput\"\n type=\"text\"\n inputmode=\"numeric\"\n maxlength=\"2\"\n [timeMin]=\"twelvehour ? 1 : 0\"\n [timeMax]=\"twelvehour ? 12 : 23\"\n [timeValue]=\"hour\"\n (timeValueChanged)=\"handleHourInputChange($event)\"\n (focus)=\"handleFocus('hour')\" />\n\n <div class=\"mtx-time-seperator\">:</div>\n\n <input class=\"mtx-time-input\"\n [class.mtx-time-input-active]=\"clockView === 'minute'\"\n [class.mtx-time-input-warning]=\"!minuteInput.valid\"\n #minuteInput=\"mtxTimeInput\"\n type=\"text\"\n inputmode=\"numeric\"\n maxlength=\"2\"\n [timeMin]=\"0\"\n [timeMax]=\"59\"\n [timeValue]=\"minute\"\n (timeValueChanged)=\"handleMinuteInputChange($event)\"\n [timeInterval]=\"interval\"\n (focus)=\"handleFocus('minute')\" />\n\n <div *ngIf=\"twelvehour\" class=\"mtx-time-ampm\">\n <button mat-button type=\"button\" class=\"mtx-time-am\"\n [class.mtx-time-ampm-active]=\"AMPM === 'AM'\" aria-label=\"AM\"\n (keydown)=\"$event.stopPropagation()\"\n (click)=\"ampmChange.emit('AM')\">AM</button>\n <button mat-button type=\"button\" class=\"mtx-time-pm\"\n [class.mtx-time-ampm-active]=\"AMPM === 'PM'\" aria-label=\"PM\"\n (keydown)=\"$event.stopPropagation()\"\n (click)=\"ampmChange.emit('PM')\">PM</button>\n </div>\n </div>\n</div>\n\n<mtx-clock (selectedChange)=\"_timeSelected($event)\"\n (activeDateChange)=\"_onActiveDateChange($event)\"\n [dateFilter]=\"dateFilter\"\n [interval]=\"interval\"\n [maxDate]=\"maxDate\"\n [minDate]=\"minDate\"\n [selected]=\"selected\"\n [startView]=\"clockView\"\n [twelvehour]=\"twelvehour\">\n</mtx-clock>\n\n<div class=\"mtx-time-button-wrapper\">\n <button class=\"mtx-time-cancel-button\" mat-button type=\"button\" (click)=\"handleCancel()\">\n {{ _datetimepickerIntl.cancelLabel }}\n </button>\n <button class=\"mtx-time-ok-button\" mat-button type=\"button\" (click)=\"handleOk()\"\n [disabled]=\"minuteInputDirective?.invalid || hourInputDirective?.invalid\">\n {{ _datetimepickerIntl.okLabel }}\n </button>\n</div>\n", styles: [".mtx-time{display:block;outline:none;-webkit-user-select:none;user-select:none}.mtx-time-input-wrapper{padding:8px 0;text-align:center}.mtx-time-input-inner{display:inline-flex;height:56px}.mtx-time-input{box-sizing:border-box;width:72px;height:100%;padding:0;font-size:36px;text-align:center;border-radius:8px;border:2px solid transparent;-webkit-appearance:none;appearance:none;outline:none}.mtx-time-seperator{display:inline-flex;justify-content:center;align-items:center;width:24px;font-size:36px}.mtx-time-ampm{display:inline-flex;flex-direction:column;margin-left:12px}[dir=rtl] .mtx-time-ampm{margin-left:auto;margin-right:12px}.mtx-time-ampm .mtx-time-am,.mtx-time-ampm .mtx-time-pm{flex:1;width:40px;min-width:auto;padding:0;line-height:normal;border-width:1px;border-style:solid}.mtx-time-ampm .mtx-time-am{border-radius:8px 8px 0 0}.mtx-time-ampm .mtx-time-pm{border-radius:0 0 8px 8px;border-top:none}.mtx-time-button-wrapper{display:flex;justify-content:flex-end;padding-top:8px}\n"] }]
|
|
1149
|
+
}, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"mtx-time-input-wrapper\">\n <div class=\"mtx-time-input-inner\">\n <input class=\"mtx-time-input\"\n [class.mtx-time-input-active]=\"clockView === 'hour'\"\n [class.mtx-time-input-warning]=\"!hourInput.valid\"\n #hourInput=\"mtxTimeInput\"\n type=\"text\"\n inputmode=\"numeric\"\n maxlength=\"2\"\n [timeMin]=\"twelvehour ? 1 : 0\"\n [timeMax]=\"twelvehour ? 12 : 23\"\n [timeValue]=\"hour\"\n (timeValueChanged)=\"handleHourInputChange($event)\"\n (focus)=\"handleFocus('hour')\" />\n\n <div class=\"mtx-time-seperator\">:</div>\n\n <input class=\"mtx-time-input\"\n [class.mtx-time-input-active]=\"clockView === 'minute'\"\n [class.mtx-time-input-warning]=\"!minuteInput.valid\"\n #minuteInput=\"mtxTimeInput\"\n type=\"text\"\n inputmode=\"numeric\"\n maxlength=\"2\"\n [timeMin]=\"0\"\n [timeMax]=\"59\"\n [timeValue]=\"minute\"\n (timeValueChanged)=\"handleMinuteInputChange($event)\"\n [timeInterval]=\"interval\"\n (focus)=\"handleFocus('minute')\" />\n\n <div *ngIf=\"twelvehour\" class=\"mtx-time-ampm\">\n <button mat-button type=\"button\" class=\"mtx-time-am\"\n [class.mtx-time-ampm-active]=\"AMPM === 'AM'\" aria-label=\"AM\"\n (keydown)=\"$event.stopPropagation()\"\n (click)=\"ampmChange.emit('AM')\">AM</button>\n <button mat-button type=\"button\" class=\"mtx-time-pm\"\n [class.mtx-time-ampm-active]=\"AMPM === 'PM'\" aria-label=\"PM\"\n (keydown)=\"$event.stopPropagation()\"\n (click)=\"ampmChange.emit('PM')\">PM</button>\n </div>\n </div>\n</div>\n\n<mtx-clock (selectedChange)=\"_timeSelected($event)\"\n (activeDateChange)=\"_onActiveDateChange($event)\"\n [dateFilter]=\"dateFilter\"\n [interval]=\"interval\"\n [maxDate]=\"maxDate\"\n [minDate]=\"minDate\"\n [selected]=\"selected\"\n [startView]=\"clockView\"\n [twelvehour]=\"twelvehour\">\n</mtx-clock>\n\n<div class=\"mtx-time-button-wrapper\">\n <button class=\"mtx-time-cancel-button\" mat-button type=\"button\" (click)=\"handleCancel()\">\n {{ _datetimepickerIntl.cancelLabel }}\n </button>\n <button class=\"mtx-time-ok-button\" mat-button type=\"button\" (click)=\"handleOk()\"\n [disabled]=\"minuteInputDirective?.invalid || hourInputDirective?.invalid\">\n {{ _datetimepickerIntl.okLabel }}\n </button>\n</div>\n", styles: [".mtx-time{display:block;outline:none;-webkit-user-select:none;user-select:none}.mtx-time-input-wrapper{padding:8px 0;text-align:center}.mtx-time-input-inner{display:inline-flex;height:56px}.mtx-time-input{box-sizing:border-box;width:72px;height:100%;padding:0;font-size:36px;text-align:center;border-radius:8px;border:2px solid transparent;-webkit-appearance:none;appearance:none;outline:none}.mtx-time-seperator{display:inline-flex;justify-content:center;align-items:center;width:24px;font-size:36px}.mtx-time-ampm{display:inline-flex;flex-direction:column;margin-left:12px}[dir=rtl] .mtx-time-ampm{margin-left:auto;margin-right:12px}.mtx-time-ampm .mtx-time-am,.mtx-time-ampm .mtx-time-pm{flex:1;width:40px;min-width:auto;padding:0;line-height:normal;border-width:1px;border-style:solid}.mtx-time-ampm .mtx-time-am{border-radius:8px 8px 0 0}.mtx-time-ampm .mtx-time-pm{border-radius:0 0 8px 8px;border-top:none}.mtx-time-button-wrapper{display:flex;justify-content:flex-end;padding-top:8px}.mtx-time-button-wrapper .mat-button-base+.mat-button-base{margin-left:8px}[dir=rtl] .mtx-time-button-wrapper .mat-button-base+.mat-button-base{margin-left:0;margin-right:8px}\n"] }]
|
|
1149
1150
|
}], ctorParameters: function () { return [{ type: i1.DatetimeAdapter }, { type: i0.ChangeDetectorRef }, { type: MtxDatetimepickerIntl }]; }, propDecorators: { selectedChange: [{
|
|
1150
1151
|
type: Output
|
|
1151
1152
|
}], activeDateChange: [{
|
|
@@ -2962,10 +2963,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImpor
|
|
|
2962
2963
|
}]
|
|
2963
2964
|
}] });
|
|
2964
2965
|
class MtxDatetimepickerToggle {
|
|
2965
|
-
constructor(_intl, _changeDetectorRef) {
|
|
2966
|
+
constructor(_intl, _changeDetectorRef, defaultTabIndex) {
|
|
2966
2967
|
this._intl = _intl;
|
|
2967
2968
|
this._changeDetectorRef = _changeDetectorRef;
|
|
2968
2969
|
this._stateChanges = Subscription.EMPTY;
|
|
2970
|
+
const parsedTabIndex = Number(defaultTabIndex);
|
|
2971
|
+
this.tabIndex = parsedTabIndex || parsedTabIndex === 0 ? parsedTabIndex : null;
|
|
2969
2972
|
}
|
|
2970
2973
|
/** Whether the toggle button is disabled. */
|
|
2971
2974
|
get disabled() {
|
|
@@ -2998,29 +3001,34 @@ class MtxDatetimepickerToggle {
|
|
|
2998
3001
|
const inputDisabled = this.datetimepicker && this.datetimepicker.datetimepickerInput
|
|
2999
3002
|
? this.datetimepicker.datetimepickerInput._disabledChange
|
|
3000
3003
|
: of();
|
|
3004
|
+
const datetimepickerToggled = this.datetimepicker
|
|
3005
|
+
? merge(this.datetimepicker.openedStream, this.datetimepicker.closedStream)
|
|
3006
|
+
: of();
|
|
3001
3007
|
this._stateChanges.unsubscribe();
|
|
3002
|
-
this._stateChanges = merge(
|
|
3003
|
-
this._intl.changes,
|
|
3004
|
-
datetimepickerDisabled,
|
|
3005
|
-
inputDisabled,
|
|
3006
|
-
]).subscribe(() => this._changeDetectorRef.markForCheck());
|
|
3008
|
+
this._stateChanges = merge(this._intl.changes, datetimepickerDisabled, inputDisabled, datetimepickerToggled).subscribe(() => this._changeDetectorRef.markForCheck());
|
|
3007
3009
|
}
|
|
3008
3010
|
}
|
|
3009
|
-
/** @nocollapse */ MtxDatetimepickerToggle.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: MtxDatetimepickerToggle, deps: [{ token: MtxDatetimepickerIntl }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
3010
|
-
/** @nocollapse */ MtxDatetimepickerToggle.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: MtxDatetimepickerToggle, selector: "mtx-datetimepicker-toggle", inputs: { datetimepicker: ["for", "datetimepicker"], tabIndex: "tabIndex", ariaLabel: ["aria-label", "ariaLabel"], disabled: "disabled", disableRipple: "disableRipple" }, host: { listeners: { "
|
|
3011
|
+
/** @nocollapse */ MtxDatetimepickerToggle.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: MtxDatetimepickerToggle, deps: [{ token: MtxDatetimepickerIntl }, { token: i0.ChangeDetectorRef }, { token: 'tabindex', attribute: true }], target: i0.ɵɵFactoryTarget.Component });
|
|
3012
|
+
/** @nocollapse */ MtxDatetimepickerToggle.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: MtxDatetimepickerToggle, selector: "mtx-datetimepicker-toggle", inputs: { datetimepicker: ["for", "datetimepicker"], tabIndex: "tabIndex", ariaLabel: ["aria-label", "ariaLabel"], disabled: "disabled", disableRipple: "disableRipple" }, host: { listeners: { "click": "_open($event)" }, properties: { "attr.tabindex": "null", "class.mtx-datetimepicker-toggle-active": "datetimepicker && datetimepicker.opened", "class.mat-accent": "datetimepicker && datetimepicker.color === \"accent\"", "class.mat-warn": "datetimepicker && datetimepicker.color === \"warn\"", "attr.data-mtx-calendar": "datetimepicker ? datetimepicker.id : null" }, classAttribute: "mtx-datetimepicker-toggle" }, queries: [{ propertyName: "_customIcon", first: true, predicate: MtxDatetimepickerToggleIcon, descendants: true }], viewQueries: [{ propertyName: "_button", first: true, predicate: ["button"], descendants: true }], exportAs: ["mtxDatetimepickerToggle"], usesOnChanges: true, ngImport: i0, template: "<button #button\n mat-icon-button\n type=\"button\"\n [attr.aria-haspopup]=\"datetimepicker ? 'dialog' : null\"\n [attr.aria-label]=\"ariaLabel || _intl.openCalendarLabel\"\n [attr.tabindex]=\"disabled ? -1 : tabIndex\"\n [disabled]=\"disabled\"\n [disableRipple]=\"disableRipple\">\n\n <ng-container *ngIf=\"!_customIcon\" [ngSwitch]=\"datetimepicker.type\">\n <svg *ngSwitchCase=\"'time'\"\n class=\"mtx-datetimepicker-toggle-default-icon\"\n viewBox=\"0 0 24 24\"\n width=\"24px\"\n height=\"24px\"\n fill=\"currentColor\"\n focusable=\"false\">\n <path\n d=\"M12,20A8,8 0 0,0 20,12A8,8 0 0,0 12,4A8,8 0 0,0 4,12A8,8 0 0,0 12,20M12,2A10,10 0 0,1 22,12A10,10 0 0,1 12,22C6.47,22 2,17.5 2,12A10,10 0 0,1 12,2M12.5,7V12.25L17,14.92L16.25,16.15L11,13V7H12.5Z\">\n </path>\n </svg>\n <svg *ngSwitchCase=\"'datetime'\"\n class=\"mtx-datetimepicker-toggle-default-icon\"\n viewBox=\"0 0 24 24\"\n width=\"24px\"\n height=\"24px\"\n fill=\"currentColor\"\n focusable=\"false\">\n <path\n d=\"M15,13H16.5V15.82L18.94,17.23L18.19,18.53L15,16.69V13M19,8H5V19H9.67C9.24,18.09 9,17.07 9,16A7,7 0 0,1 16,9C17.07,9 18.09,9.24 19,9.67V8M5,21C3.89,21 3,20.1 3,19V5C3,3.89 3.89,3 5,3H6V1H8V3H16V1H18V3H19A2,2 0 0,1 21,5V11.1C22.24,12.36 23,14.09 23,16A7,7 0 0,1 16,23C14.09,23 12.36,22.24 11.1,21H5M16,11.15A4.85,4.85 0 0,0 11.15,16C11.15,18.68 13.32,20.85 16,20.85A4.85,4.85 0 0,0 20.85,16C20.85,13.32 18.68,11.15 16,11.15Z\">\n </path>\n </svg>\n <svg *ngSwitchDefault\n class=\"mtx-datetimepicker-toggle-default-icon\"\n viewBox=\"0 0 24 24\"\n width=\"24px\"\n height=\"24px\"\n fill=\"currentColor\"\n focusable=\"false\">\n <path d=\"M0 0h24v24H0z\" fill=\"none\" />\n <path\n d=\"M19 3h-1V1h-2v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V8h14v11zM7 10h5v5H7z\" />\n </svg>\n </ng-container>\n\n <ng-content select=\"[mtxDatetimepickerToggleIcon]\"></ng-content>\n</button>\n", styles: [".mat-form-field-appearance-legacy .mat-form-field-prefix .mtx-datetimepicker-toggle-default-icon,.mat-form-field-appearance-legacy .mat-form-field-suffix .mtx-datetimepicker-toggle-default-icon{width:1em}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mtx-datetimepicker-toggle-default-icon,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mtx-datetimepicker-toggle-default-icon{display:block;width:1.5em;height:1.5em}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon-button .mtx-datetimepicker-toggle-default-icon,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon-button .mtx-datetimepicker-toggle-default-icon{margin:auto}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i2.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i2.NgSwitchDefault, selector: "[ngSwitchDefault]" }, { kind: "component", type: i4.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
3011
3013
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: MtxDatetimepickerToggle, decorators: [{
|
|
3012
3014
|
type: Component,
|
|
3013
3015
|
args: [{ selector: 'mtx-datetimepicker-toggle', host: {
|
|
3014
3016
|
'class': 'mtx-datetimepicker-toggle',
|
|
3015
|
-
|
|
3016
|
-
// consumer may have provided, while still being able to receive focus.
|
|
3017
|
-
'[attr.tabindex]': 'disabled ? null : -1',
|
|
3017
|
+
'[attr.tabindex]': 'null',
|
|
3018
3018
|
'[class.mtx-datetimepicker-toggle-active]': 'datetimepicker && datetimepicker.opened',
|
|
3019
3019
|
'[class.mat-accent]': 'datetimepicker && datetimepicker.color === "accent"',
|
|
3020
3020
|
'[class.mat-warn]': 'datetimepicker && datetimepicker.color === "warn"',
|
|
3021
|
-
|
|
3022
|
-
|
|
3023
|
-
|
|
3021
|
+
// Used by the test harness to tie this toggle to its datetimepicker.
|
|
3022
|
+
'[attr.data-mtx-calendar]': 'datetimepicker ? datetimepicker.id : null',
|
|
3023
|
+
// Bind the `click` on the host, rather than the inner `button`, so that we can call
|
|
3024
|
+
// `stopPropagation` on it without affecting the user's `click` handlers. We need to stop
|
|
3025
|
+
// it so that the input doesn't get focused automatically by the form field (See #21836).
|
|
3026
|
+
'(click)': '_open($event)',
|
|
3027
|
+
}, exportAs: 'mtxDatetimepickerToggle', encapsulation: ViewEncapsulation.None, preserveWhitespaces: false, changeDetection: ChangeDetectionStrategy.OnPush, template: "<button #button\n mat-icon-button\n type=\"button\"\n [attr.aria-haspopup]=\"datetimepicker ? 'dialog' : null\"\n [attr.aria-label]=\"ariaLabel || _intl.openCalendarLabel\"\n [attr.tabindex]=\"disabled ? -1 : tabIndex\"\n [disabled]=\"disabled\"\n [disableRipple]=\"disableRipple\">\n\n <ng-container *ngIf=\"!_customIcon\" [ngSwitch]=\"datetimepicker.type\">\n <svg *ngSwitchCase=\"'time'\"\n class=\"mtx-datetimepicker-toggle-default-icon\"\n viewBox=\"0 0 24 24\"\n width=\"24px\"\n height=\"24px\"\n fill=\"currentColor\"\n focusable=\"false\">\n <path\n d=\"M12,20A8,8 0 0,0 20,12A8,8 0 0,0 12,4A8,8 0 0,0 4,12A8,8 0 0,0 12,20M12,2A10,10 0 0,1 22,12A10,10 0 0,1 12,22C6.47,22 2,17.5 2,12A10,10 0 0,1 12,2M12.5,7V12.25L17,14.92L16.25,16.15L11,13V7H12.5Z\">\n </path>\n </svg>\n <svg *ngSwitchCase=\"'datetime'\"\n class=\"mtx-datetimepicker-toggle-default-icon\"\n viewBox=\"0 0 24 24\"\n width=\"24px\"\n height=\"24px\"\n fill=\"currentColor\"\n focusable=\"false\">\n <path\n d=\"M15,13H16.5V15.82L18.94,17.23L18.19,18.53L15,16.69V13M19,8H5V19H9.67C9.24,18.09 9,17.07 9,16A7,7 0 0,1 16,9C17.07,9 18.09,9.24 19,9.67V8M5,21C3.89,21 3,20.1 3,19V5C3,3.89 3.89,3 5,3H6V1H8V3H16V1H18V3H19A2,2 0 0,1 21,5V11.1C22.24,12.36 23,14.09 23,16A7,7 0 0,1 16,23C14.09,23 12.36,22.24 11.1,21H5M16,11.15A4.85,4.85 0 0,0 11.15,16C11.15,18.68 13.32,20.85 16,20.85A4.85,4.85 0 0,0 20.85,16C20.85,13.32 18.68,11.15 16,11.15Z\">\n </path>\n </svg>\n <svg *ngSwitchDefault\n class=\"mtx-datetimepicker-toggle-default-icon\"\n viewBox=\"0 0 24 24\"\n width=\"24px\"\n height=\"24px\"\n fill=\"currentColor\"\n focusable=\"false\">\n <path d=\"M0 0h24v24H0z\" fill=\"none\" />\n <path\n d=\"M19 3h-1V1h-2v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V8h14v11zM7 10h5v5H7z\" />\n </svg>\n </ng-container>\n\n <ng-content select=\"[mtxDatetimepickerToggleIcon]\"></ng-content>\n</button>\n", styles: [".mat-form-field-appearance-legacy .mat-form-field-prefix .mtx-datetimepicker-toggle-default-icon,.mat-form-field-appearance-legacy .mat-form-field-suffix .mtx-datetimepicker-toggle-default-icon{width:1em}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mtx-datetimepicker-toggle-default-icon,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mtx-datetimepicker-toggle-default-icon{display:block;width:1.5em;height:1.5em}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon-button .mtx-datetimepicker-toggle-default-icon,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon-button .mtx-datetimepicker-toggle-default-icon{margin:auto}\n"] }]
|
|
3028
|
+
}], ctorParameters: function () { return [{ type: MtxDatetimepickerIntl }, { type: i0.ChangeDetectorRef }, { type: undefined, decorators: [{
|
|
3029
|
+
type: Attribute,
|
|
3030
|
+
args: ['tabindex']
|
|
3031
|
+
}] }]; }, propDecorators: { datetimepicker: [{
|
|
3024
3032
|
type: Input,
|
|
3025
3033
|
args: ['for']
|
|
3026
3034
|
}], tabIndex: [{
|