@ukic/canary-web-components 2.0.0-canary.37 → 2.0.0-canary.39
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/core.cjs.js +1 -1
- package/dist/cjs/ic-data-table.cjs.entry.js +6 -2
- package/dist/cjs/ic-data-table.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-date-picker.cjs.entry.js +110 -57
- package/dist/cjs/ic-date-picker.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-navigation-group.cjs.entry.js +9 -0
- package/dist/cjs/ic-navigation-group.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-radio-option.cjs.entry.js +1 -1
- package/dist/cjs/ic-radio-option.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-tree-item.cjs.entry.js +1 -1
- package/dist/cjs/ic-tree-item.cjs.entry.js.map +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/components/ic-card-horizontal/ic-card-horizontal.stories.js +605 -0
- package/dist/collection/components/ic-card-horizontal/ic-card-horizontal.stories.js.map +1 -0
- package/dist/collection/components/ic-data-table/ic-data-table.js +6 -2
- package/dist/collection/components/ic-data-table/ic-data-table.js.map +1 -1
- package/dist/collection/components/ic-data-table/ic-data-table.stories.js +414 -0
- package/dist/collection/components/ic-data-table/ic-data-table.stories.js.map +1 -0
- package/dist/collection/components/ic-data-table/story-data.js +155 -0
- package/dist/collection/components/ic-data-table/story-data.js.map +1 -1
- package/dist/collection/components/ic-data-table-title-bar/ic-data-table-title-bar.stories.js +98 -0
- package/dist/collection/components/ic-data-table-title-bar/ic-data-table-title-bar.stories.js.map +1 -0
- package/dist/collection/components/ic-date-input/ic-date-input.stories.js +341 -0
- package/dist/collection/components/ic-date-input/ic-date-input.stories.js.map +1 -0
- package/dist/collection/components/ic-date-picker/ic-date-picker.css +10 -3
- package/dist/collection/components/ic-date-picker/ic-date-picker.js +152 -57
- package/dist/collection/components/ic-date-picker/ic-date-picker.js.map +1 -1
- package/dist/collection/components/ic-date-picker/ic-date-picker.stories.js +167 -0
- package/dist/collection/components/ic-date-picker/ic-date-picker.stories.js.map +1 -0
- package/dist/collection/components/ic-date-picker/story-data.js +34 -3
- package/dist/collection/components/ic-date-picker/story-data.js.map +1 -1
- package/dist/collection/components/ic-pagination-bar/ic-pagination-bar.stories.js +260 -0
- package/dist/collection/components/ic-pagination-bar/ic-pagination-bar.stories.js.map +1 -0
- package/dist/collection/components/ic-select-with-multi/ic-select-multi.stories.js +144 -0
- package/dist/collection/components/ic-select-with-multi/ic-select-multi.stories.js.map +1 -0
- package/dist/collection/components/ic-tree-item/ic-tree-item.css +22 -3
- package/dist/collection/components/ic-tree-view/ic-tree-view.stories.js +456 -0
- package/dist/collection/components/ic-tree-view/ic-tree-view.stories.js.map +1 -0
- package/dist/components/ic-data-table.js +6 -2
- package/dist/components/ic-data-table.js.map +1 -1
- package/dist/components/ic-date-picker.js +112 -57
- package/dist/components/ic-date-picker.js.map +1 -1
- package/dist/components/ic-navigation-group.js +11 -2
- package/dist/components/ic-navigation-group.js.map +1 -1
- package/dist/components/ic-radio-option.js +1 -1
- package/dist/components/ic-radio-option.js.map +1 -1
- package/dist/components/ic-tree-item.js +1 -1
- package/dist/components/ic-tree-item.js.map +1 -1
- package/dist/core/core.esm.js +1 -1
- package/dist/core/core.esm.js.map +1 -1
- package/dist/core/p-04fe848d.entry.js +2 -0
- package/dist/core/p-04fe848d.entry.js.map +1 -0
- package/dist/core/{p-b4f824a6.entry.js → p-3ebd4703.entry.js} +2 -2
- package/dist/core/p-3ebd4703.entry.js.map +1 -0
- package/dist/core/p-bd0328f3.entry.js +2 -0
- package/dist/core/p-bd0328f3.entry.js.map +1 -0
- package/dist/core/p-cc0e0b46.entry.js +2 -0
- package/dist/core/p-cc0e0b46.entry.js.map +1 -0
- package/dist/core/p-fac387e8.entry.js +2 -0
- package/dist/core/p-fac387e8.entry.js.map +1 -0
- package/dist/esm/core.js +1 -1
- package/dist/esm/ic-data-table.entry.js +6 -2
- package/dist/esm/ic-data-table.entry.js.map +1 -1
- package/dist/esm/ic-date-picker.entry.js +110 -57
- package/dist/esm/ic-date-picker.entry.js.map +1 -1
- package/dist/esm/ic-navigation-group.entry.js +10 -1
- package/dist/esm/ic-navigation-group.entry.js.map +1 -1
- package/dist/esm/ic-radio-option.entry.js +1 -1
- package/dist/esm/ic-radio-option.entry.js.map +1 -1
- package/dist/esm/ic-tree-item.entry.js +1 -1
- package/dist/esm/ic-tree-item.entry.js.map +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/types/components/ic-card-horizontal/ic-card-horizontal.stories.d.ts +82 -0
- package/dist/types/components/ic-data-table/ic-data-table.stories.d.ts +239 -0
- package/dist/types/components/ic-data-table/story-data.d.ts +57 -0
- package/dist/types/components/ic-data-table-title-bar/ic-data-table-title-bar.stories.d.ts +47 -0
- package/dist/types/components/ic-date-input/ic-date-input.stories.d.ts +124 -0
- package/dist/types/components/ic-date-picker/ic-date-picker.d.ts +18 -1
- package/dist/types/components/ic-date-picker/ic-date-picker.stories.d.ts +153 -0
- package/dist/types/components/ic-date-picker/story-data.d.ts +2 -0
- package/dist/types/components/ic-pagination-bar/ic-pagination-bar.stories.d.ts +106 -0
- package/dist/types/components/ic-select-with-multi/ic-select-multi.stories.d.ts +106 -0
- package/dist/types/components/ic-tree-view/ic-tree-view.stories.d.ts +99 -0
- package/dist/types/components.d.ts +13 -0
- package/hydrate/index.js +129 -62
- package/package.json +12 -12
- package/dist/core/p-4084bce2.entry.js +0 -2
- package/dist/core/p-4084bce2.entry.js.map +0 -1
- package/dist/core/p-71bbb583.entry.js +0 -2
- package/dist/core/p-71bbb583.entry.js.map +0 -1
- package/dist/core/p-89112e37.entry.js +0 -2
- package/dist/core/p-89112e37.entry.js.map +0 -1
- package/dist/core/p-b4f824a6.entry.js.map +0 -1
- package/dist/core/p-fe105ed0.entry.js +0 -2
- package/dist/core/p-fe105ed0.entry.js.map +0 -1
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"ic-date-picker.js","sourceRoot":"","sources":["../../../src/components/ic-date-picker/ic-date-picker.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EACT,OAAO,EACP,IAAI,EACJ,CAAC,EACD,IAAI,EACJ,MAAM,EACN,KAAK,EACL,KAAK,EACL,KAAK,GAEN,MAAM,eAAe,CAAC;AACvB,OAAO,EACL,UAAU,EACV,SAAS,EACT,WAAW,EACX,WAAW,EACX,aAAa,EACb,WAAW,EACX,UAAU,EACV,YAAY,EACZ,WAAW,GACZ,MAAM,0BAA0B,CAAC;AAClC,OAAO,EACL,iBAAiB,EACjB,gCAAgC,EAChC,mBAAmB,GACpB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EACL,UAAU,EACV,eAAe,EACf,iBAAiB,GAIlB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,OAAO,MAAM,+BAA+B,CAAC;AACpD,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAC5C,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAE9C,MAAM,mBAAmB,GAAG,YAAY,CAAC;AACzC,MAAM,kCAAkC,GACtC,wEAAwE,CAAC;AAC3E,MAAM,mCAAmC,GACvC,wEAAwE,CAAC;AAC3E,MAAM,wBAAwB,GAC5B,qGAAqG,CAAC;AACxG,MAAM,WAAW,GAAG,GAAG,CAAC;AACxB,MAAM,mBAAmB,GAAG,GAAG,CAAC;AAChC,MAAM,qBAAqB,GAAG,GAAG,CAAC;AAClC,MAAM,mBAAmB,GAAG,GAAG,CAAC;AAoChC,MAAM,OAAO,UAAU;;QAEb,kBAAa,GAAwB,IAAI,CAAC;QAE1C,eAAU,GAAa,EAAE,CAAC;QAC1B,sBAAiB,GAAY,KAAK,CAAC;QACnC,yBAAoB,GAAY,KAAK,CAAC;QAGtC,sBAAiB,GAAW,EAAE,CAAC;QAC/B,a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nimport {\n createDate,\n clampDate,\n dateMatches,\n dateInRange,\n getMonthStart,\n getMonthEnd,\n getWeekEnd,\n getWeekStart,\n yearInRange,\n} from \"../../utils/date-helpers\";\nimport {\n stringEnumToArray,\n onComponentRequiredPropUndefined,\n removeDisabledFalse,\n} from \"../../utils/helpers\";\nimport {\n IcWeekDays,\n IcShortDayNames,\n IcDateInputMonths,\n IcDateFormat,\n IcSizes,\n IcInformationStatusOrEmpty,\n} from \"../../utils/types\";\nimport chevron from \"../../assets/chevron-icon.svg\";\nimport { DayButton } from \"./ic-day-button\";\nimport { MonthPicker } from \"./ic-month-picker\";\nimport { YearPicker } from \"./ic-year-picker\";\n\nconst DEFAULT_DATE_FORMAT = \"DD/MM/YYYY\";\nconst DEFAULT_DISABLE_DATES_FROM_NOW_MSG =\n \"Dates in the future are not allowed. Please select a date in the past.\";\nconst DEFAULT_DISABLE_DATES_UNTIL_NOW_MSG =\n \"Dates in the past are not allowed. Please select a date in the future.\";\nconst DEFAULT_DISABLE_DAYS_MSG =\n \"The date you have selected is on a day of the week that is not allowed. Please select another date.\";\nconst FOCUS_TIMER = 100;\nconst PICKER_HEIGHT_SMALL = 360;\nconst PICKER_HEIGHT_DEFAULT = 400;\nconst PICKER_HEIGHT_LARGE = 440;\n\ninterface IcDateInputProps {\n dateFormat?: IcDateFormat;\n disabled?: boolean;\n disableDays?: IcWeekDays[];\n disableDaysMessage?: string;\n disableFuture?: boolean;\n disableFutureMessage?: string;\n disablePast?: boolean;\n disablePastMessage?: string;\n helperText?: string;\n hideHelperText?: boolean;\n hideLabel?: boolean;\n inputId?: string;\n invalidDateMessage?: string;\n label: string;\n max?: string | Date;\n min?: string | Date;\n name?: string;\n required?: boolean;\n showClearButton?: boolean;\n showCalendarButton?: boolean;\n size?: IcSizes;\n value?: string | Date;\n validationStatus?: IcInformationStatusOrEmpty;\n validationText?: string;\n}\n\n@Component({\n tag: \"ic-date-picker\",\n styleUrl: \"ic-date-picker.css\",\n shadow: {\n delegatesFocus: true,\n },\n})\nexport class DatePicker {\n private inputEl: HTMLIcDateInputElement;\n private clearButtonEl: HTMLIcButtonElement = null;\n private dateInputProps: IcDateInputProps;\n private daysOfWeek: string[] = [];\n private dayButtonFocussed: boolean = false;\n private dayPickerKeyboardNav: boolean = false;\n private decadeStart: number;\n private decadeEnd: number;\n private dialogDescription: string = \"\";\n private focusDay: boolean = true;\n private focussedYearEl: HTMLIcButtonElement;\n private liveRegionEl: HTMLElement = null;\n private monthButtonEl: HTMLIcButtonElement;\n private monthNames: string[] = [];\n private monthInViewUpdateHandled: boolean = false;\n private myCalendarButtonClicked: boolean = false;\n private showPickerAbove: boolean = false;\n private today = new Date();\n private todayButtonEl: HTMLIcButtonElement = null;\n private yearButtonEl: HTMLIcButtonElement;\n private yearButtonFocussed: boolean = false;\n\n @Element() el: HTMLIcDatePickerElement;\n\n @State() calendarOpen: boolean = false;\n @State() currMonthView: Date[] = [];\n @State() currYearPickerView: number[] = [];\n @State() decadeView: number[] = [];\n @State() focussedDate: Date = null;\n @State() focussedDay: number;\n @State() focussedDayEl: HTMLButtonElement;\n @State() focussedMonth: number;\n @State() focussedMonthEl: HTMLIcButtonElement;\n @State() focussedYear: number;\n @State() maxDate: Date = null;\n @State() minDate: Date = null;\n @State() monthInView: number;\n @State() monthPickerVisible: boolean = false;\n @State() orderedDaysOfWeek: string[] = [];\n @State() selectedDate: Date = null;\n @State() yearInView: number;\n @State() yearPickerVisible: boolean = false;\n\n /**\n * The format in which the date will be displayed.\n */\n @Prop() dateFormat?: IcDateFormat = \"DD/MM/YYYY\";\n\n /**\n * If `true`, the disabled state will be set.\n */\n @Prop() disabled?: boolean = false;\n @Watch(\"disabled\")\n watchDisabledHandler(): void {\n removeDisabledFalse(this.disabled, this.el);\n }\n\n /**\n * The days of the week to disable.\n */\n @Prop() disableDays?: IcWeekDays[] = [];\n\n /**\n * The text to display as the validation message when `disableDays` is `true` and a disabled date is entered.\n */\n @Prop() disableDaysMessage?: string =\n \"The date you have selected is on a day of the week that is not allowed. Please select another date.\";\n\n /**\n * If `true`, dates in the future are not allowed. A validation message will appear if a date in the future is entered.\n */\n @Prop() disableFuture?: boolean = false;\n\n @Watch(\"disableFuture\")\n watchDisableFutureHandler(): void {\n this.watchMaxHandler();\n }\n\n /**\n * The text to display as the validation message when `disableFuture` is `true` and a date in the future is entered.\n */\n @Prop() disableFutureMessage?: string =\n \"Dates in the future are not allowed. Please select a date in the past.\";\n\n /**\n * If `true`, dates in the past are not allowed. A validation message will appear if a date in the past is entered.\n */\n @Prop() disablePast?: boolean = false;\n\n @Watch(\"disablePast\")\n watchDisablePastHandler(): void {\n this.watchMinHandler();\n }\n\n /**\n * The text to display as the validation message when `disablePast` is `true` and a date in the past is entered.\n */\n @Prop() disablePastMessage?: string =\n \"Dates in the past are not allowed. Please select a date in the future.\";\n\n /**\n * The helper text that will be displayed for additional field guidance. This will default to the text \"Use format\" along with the `dateFormat` value.\n */\n @Prop() helperText?: string;\n\n /**\n * If `true`, the helper text will be visually hidden, but still read out by screenreaders.\n */\n @Prop() hideHelperText: boolean = false;\n\n /**\n * If `true`, the label will be visually hidden, but the required label will still be read out by screen readers.\n */\n @Prop() hideLabel?: boolean = false;\n\n /**\n * The ID for the input field. The default will be an automatically generated value.\n */\n @Prop() inputId?: string;\n\n /**\n * The text to display as the validation message when an invalid date is entered.\n */\n @Prop() invalidDateMessage?: string = \"Please enter a valid date.\";\n\n /**\n * The label for the date input.\n */\n @Prop() label!: string;\n\n /**\n * The latest date that will be allowed. The value can be in any format supported as `dateFormat`, in ISO 8601 date string format (`yyyy-mm-dd`) or as a JavaScript `Date` object.\n * The value of this prop is ignored if `disableFuture` is set to `true`.\n */\n @Prop() max?: string | Date = \"\";\n\n @Watch(\"max\")\n watchMaxHandler(): void {\n if (this.disableFuture) {\n this.maxDate = new Date();\n } else {\n this.maxDate = createDate(this.max, this.dateFormat);\n }\n }\n\n /**\n * The earliest date that will be allowed. The value can be in any format supported as `dateFormat`, in ISO 8601 date string format (`yyyy-mm-dd`) or as a JavaScript `Date` object.\n * The value of this prop is ignored if `disablePast` is set to `true`.\n */\n @Prop() min?: string | Date = \"\";\n\n @Watch(\"min\")\n watchMinHandler(): void {\n if (this.disablePast) {\n this.minDate = new Date();\n } else {\n this.minDate = createDate(this.min, this.dateFormat);\n }\n }\n\n /**\n * The name of the control, which is submitted with the form data.\n */\n @Prop() name?: string;\n\n /**\n * The date visible when the calendar opens. Used if no date is currently selected.\n * The value can be in any format supported as `dateFormat`, in ISO 8601 date string format (`yyyy-mm-dd`) or as a JavaScript `Date` object.\n */\n @Prop() openAtDate: string | Date = \"\";\n\n /**\n * If `true`, the input will require a value.\n */\n @Prop() required?: boolean = false;\n\n /**\n * If `true`, days outside the current month will be visible in the date picker.\n */\n @Prop() showDaysOutsideMonth?: boolean = true;\n\n /**\n * If `true`, the `Clear` button on the date picker will be visible.\n */\n @Prop() showPickerClearButton?: boolean = true;\n\n /**\n * If `true`, the `Go to today` button on the date picker will be visible.\n */\n @Prop() showPickerTodayButton?: boolean = true;\n\n /**\n * The size of the date picker to be displayed.\n */\n @Prop() size?: IcSizes = \"default\";\n\n /**\n * The first day of the week. `0` for Sunday, `1` for Monday, etc.\n * Default is Monday.\n */\n @Prop() startOfWeek?: IcWeekDays = IcWeekDays.Monday;\n\n @Watch(\"startOfWeek\")\n watchStartOfWeekHandler(): void {\n this.orderedDaysOfWeek = this.daysOfWeek\n .slice(this.startOfWeek)\n .concat(this.daysOfWeek.slice(0, this.startOfWeek));\n if (this.calendarOpen) {\n this.updateMonthInView();\n }\n }\n\n /**\n * The validation status - e.g. 'error' | 'warning' | 'success'. This will override the built-in date validation.\n */\n @Prop() validationStatus?: IcInformationStatusOrEmpty = \"\";\n\n /**\n * The text to display as the validation message. This will override the built-in date validation.\n */\n @Prop() validationText?: string = \"\";\n\n /**\n * The value of the date picker. The value can be in any format supported as `dateFormat`, in ISO 8601 date string format (`yyyy-mm-dd`) or as a JavaScript `Date` object.\n */\n @Prop({ mutable: true }) value?: string | Date | null | undefined = \"\";\n\n @Watch(\"calendarOpen\")\n watchOpenHandler(): void {\n if (this.calendarOpen) {\n if (this.inputEl) {\n let pickerHeight = PICKER_HEIGHT_DEFAULT;\n if (this.size === \"small\") {\n pickerHeight = PICKER_HEIGHT_SMALL;\n } else if (this.size === \"large\") {\n pickerHeight = PICKER_HEIGHT_LARGE;\n }\n if (\n this.el.offsetTop + this.inputEl.offsetHeight + pickerHeight >\n window.innerHeight &&\n this.el.offsetTop > pickerHeight\n ) {\n this.showPickerAbove = true;\n } else {\n this.showPickerAbove = false;\n }\n }\n if (\n this.selectedDate === null ||\n !dateInRange(this.selectedDate, this.minDate, this.maxDate)\n ) {\n let openAt = new Date();\n if (this.openAtDate !== \"\") {\n openAt = createDate(this.openAtDate, this.dateFormat);\n }\n this.setFocussedDate(openAt);\n } else {\n this.setFocussedDate(this.selectedDate);\n }\n let dialogDesc = this.getMonthInViewText();\n if (this.selectedDate === null) {\n dialogDesc += \" No date selected.\";\n }\n dialogDesc +=\n \" Use arrow keys to change day. Press enter or space to select a date or press escape to close the picker\";\n this.dialogDescription = dialogDesc;\n setTimeout(() => this.focusFocussedDay(), FOCUS_TIMER);\n document.addEventListener(\"click\", this.handleDocumentClick);\n } else {\n document.removeEventListener(\"click\", this.handleDocumentClick);\n this.monthPickerVisible = false;\n this.yearPickerVisible = false;\n }\n }\n\n @Watch(\"focussedDate\")\n watchFocussedDateHandler(current: Date, previous: Date): void {\n if (\n previous === null ||\n !(\n previous.getFullYear() === current.getFullYear() &&\n previous.getMonth() === current.getMonth()\n )\n ) {\n this.updateMonthInView();\n }\n }\n\n @Watch(\"monthInView\")\n watchMonthInViewHandler(): void {\n this.focussedMonth = this.monthInView;\n }\n\n @Watch(\"yearInView\")\n watchYearInViewHandler(): void {\n this.setFocussedYear(this.yearInView, false);\n }\n\n @Watch(\"yearPickerVisible\")\n watchYearPickerVisibleHandler(): void {\n if (!this.yearPickerVisible) {\n this.setFocussedYear(this.yearInView);\n }\n }\n\n @Watch(\"monthPickerVisible\")\n watchMonthPickerVisibleHandler(): void {\n if (!this.monthPickerVisible) {\n this.focussedMonth = this.monthInView;\n }\n }\n\n @Watch(\"focussedDayEl\")\n watchFocussedDayEl(): void {\n if (this.focusDay) {\n setTimeout(() => this.focusFocussedDay(), FOCUS_TIMER);\n }\n\n this.focusDay = true;\n }\n\n /**\n * Emitted when the value has changed.\n */\n @Event() icChange: EventEmitter<{ value: Date }>;\n\n componentWillLoad(): void {\n onComponentRequiredPropUndefined(\n [{ prop: this.label, propName: \"label\" }],\n \"Date Picker\"\n );\n\n this.monthNames = stringEnumToArray(IcDateInputMonths);\n this.daysOfWeek = stringEnumToArray(IcShortDayNames);\n\n this.watchStartOfWeekHandler();\n this.watchMaxHandler();\n this.watchMinHandler();\n removeDisabledFalse(this.disabled, this.el);\n }\n\n componentWillRender(): void {\n this.dateInputProps = this.setDateInputProps();\n }\n\n componentWillUpdate(): void {\n this.dateInputProps = this.setDateInputProps();\n }\n\n @Listen(\"calendarButtonClicked\")\n localCalendarButtonClickHandler(ev: CustomEvent): void {\n this.myCalendarButtonClicked = true;\n if (!this.calendarOpen) {\n this.setSelectedDate(ev.detail.value, false);\n }\n\n this.calendarOpen = !this.calendarOpen;\n }\n\n @Listen(\"calendarButtonClicked\", { target: \"document\" })\n calendarButtonClickHandler(): void {\n //closes this picker if calendar button in another clicked\n if (!this.myCalendarButtonClicked) {\n this.calendarOpen = false;\n }\n this.myCalendarButtonClicked = false;\n }\n\n private setDecadeView = (start: number) => {\n let currYear = start - 1;\n const decadeArr = [];\n while (currYear <= start + 10) {\n decadeArr.push(currYear);\n currYear++;\n }\n this.decadeView = decadeArr;\n this.decadeStart = decadeArr[1];\n this.decadeEnd = decadeArr[10];\n };\n\n private setSelectedDate = (d: Date, emit = true): void => {\n if (d === null || !dateMatches(d, this.selectedDate)) {\n this.selectedDate = d;\n this.value = d;\n if (emit) {\n this.inputEl.triggerIcChange(d);\n }\n }\n };\n\n private handleCalendarMouseDown = (event: MouseEvent): void => {\n const target = event.target as HTMLElement;\n if (target.tagName !== \"IC-BUTTON\") {\n event.preventDefault();\n }\n };\n\n private handleCalendarClick = (event: MouseEvent): void => {\n this.clearDialogDescription();\n event.stopImmediatePropagation();\n };\n\n private handleDocumentClick = (): void => {\n this.calendarOpen = false;\n };\n\n private keyDownHandler = (event: KeyboardEvent) => {\n if (event.key === \"Escape\") {\n if (this.calendarOpen) {\n this.closeButtonClickHandler();\n this.inputEl.setCalendarFocus();\n event.stopImmediatePropagation();\n }\n } else {\n this.clearDialogDescription();\n event.stopImmediatePropagation();\n }\n };\n\n private closeButtonClickHandler = () => {\n this.calendarOpen = false;\n };\n\n private focusFirstElement = () => {\n this.monthButtonEl.setFocus();\n };\n\n private focusLastElement = () => {\n if (this.showPickerClearButton && !this.clearButtonEl.disabled) {\n this.clearButtonEl.setFocus();\n } else if (this.showPickerTodayButton && !this.todayButtonEl.disabled) {\n this.todayButtonEl.setFocus();\n } else if (this.monthPickerVisible) {\n this.focussedMonthEl.setFocus();\n } else if (this.yearPickerVisible) {\n this.focussedYearEl.setFocus();\n } else {\n this.focussedDayEl.focus();\n }\n };\n\n private focusFocussedDay = () => {\n this.focussedDayEl.focus();\n };\n\n private monthButtonClickHandler = () => {\n this.yearPickerVisible = false;\n this.focusDay = false;\n this.monthPickerVisible = !this.monthPickerVisible;\n if (this.monthPickerVisible) {\n this.setAriaLiveRegionText(\"Month picker view open\");\n } else {\n this.setMonthSelectedLiveRegionText();\n }\n };\n\n private yearButtonClickHandler = () => {\n this.monthPickerVisible = false;\n this.focusDay = false;\n this.yearPickerVisible = !this.yearPickerVisible;\n if (this.yearPickerVisible) {\n this.setAriaLiveRegionText(\n `Year picker view open. ${this.getDecadeInViewText()}`\n );\n } else {\n this.setYearSelectedLiveRegionText();\n }\n };\n\n private todayButtonClickHandler = () => {\n this.yearPickerVisible = false;\n this.monthPickerVisible = false;\n this.setFocussedDate(new Date());\n this.setAriaLiveRegionText(this.getMonthInViewText());\n\n setTimeout(() => this.focusFocussedDay(), FOCUS_TIMER);\n };\n\n private todayButtonKeyDownHandler = (ev: KeyboardEvent) => {\n if (ev.key === \"Tab\" && !ev.shiftKey && this.clearButtonEl.disabled) {\n this.focusFirstElement();\n ev.preventDefault();\n }\n };\n\n private clearButtonClickHandler = () => {\n this.setSelectedDate(null);\n let text = \"Selected date cleared.\";\n if (!this.monthPickerVisible && !this.yearPickerVisible) {\n text += ` ${this.getMonthInViewText()}`;\n }\n if (this.monthPickerVisible) {\n this.focussedMonthEl.setFocus();\n } else if (this.yearPickerVisible) {\n this.focussedYearEl.setFocus();\n } else {\n this.focusFocussedDay();\n }\n this.setAriaLiveRegionText(text);\n };\n\n private setMonthSelectedLiveRegionText = () => {\n this.setAriaLiveRegionText(\n `${\n this.monthNames[this.monthInView]\n } selected. ${this.getMonthInViewText()}`\n );\n };\n\n private setYearSelectedLiveRegionText = () => {\n this.setAriaLiveRegionText(\n `${this.yearInView} selected. ${this.getMonthInViewText()}`\n );\n };\n\n private getMonthInViewText = () => {\n return `${this.monthNames[this.monthInView]} ${\n this.yearInView\n } currently in view.`;\n };\n\n private getDecadeInViewText = () => {\n return `${this.decadeStart} to ${this.decadeEnd} currently in view.`;\n };\n\n private setAriaLiveRegionText = (text: string) => {\n this.liveRegionEl && (this.liveRegionEl.innerText = text);\n };\n\n private clearDialogDescription = () => {\n this.dialogDescription = \"\";\n };\n\n private clearButtonKeyDownHandler = (ev: KeyboardEvent) => {\n if (ev.key === \"Tab\" && !ev.shiftKey) {\n this.focusFirstElement();\n ev.preventDefault();\n }\n };\n\n private goToPreviousMonth = (focusDay = false) => {\n this.focusDay = focusDay;\n this.moveMonths(-1);\n };\n\n private goToNextMonth = (focusDay = false) => {\n this.focusDay = focusDay;\n this.moveMonths(1);\n };\n\n private goToPreviousYear = (focusDay = false) => {\n if (this.isPrevYearAllowed()) {\n this.focusDay = focusDay;\n this.moveYears(-1);\n }\n };\n\n private goToNextYear = (focusDay = false) => {\n if (this.isNextYearAllowed()) {\n this.focusDay = focusDay;\n this.moveYears(1);\n }\n };\n\n private navButtonMouseDownHandler = (ev: MouseEvent): void => {\n ev.preventDefault();\n };\n\n private renderMonthYearNavButton = (\n id: string,\n flip: boolean,\n disabled: boolean\n ): void => {\n const buttonSize = this.size;\n return (\n <div aria-hidden=\"true\">\n <ic-button\n id={id}\n disableTooltip={true}\n disabled={disabled}\n onClick={this.monthYearNavClickHandler}\n class={{ flip: flip }}\n variant=\"icon\"\n innerHTML={chevron}\n size={buttonSize}\n tabIndex={-1}\n aria-hidden=\"true\"\n onMouseDown={this.navButtonMouseDownHandler}\n />\n </div>\n );\n };\n\n private monthYearNavClickHandler = (ev: Event): void => {\n const target = ev.target as Element;\n switch (target.id) {\n case \"previous-month-button\":\n this.goToPreviousMonth(this.dayButtonFocussed);\n break;\n\n case \"next-month-button\":\n this.goToNextMonth(this.dayButtonFocussed);\n break;\n\n case \"previous-year-button\":\n this.goToPreviousYear(this.dayButtonFocussed);\n break;\n\n case \"next-year-button\":\n this.goToNextYear(this.dayButtonFocussed);\n break;\n }\n };\n\n private previousMonthButton = (): void => {\n let disabled = false;\n if (this.focussedDate !== null && this.minDate !== null) {\n const yearMatch =\n this.focussedDate.getFullYear() === this.minDate.getFullYear();\n if (yearMatch) {\n disabled = this.monthInView - 1 < this.minDate.getMonth();\n }\n }\n return this.renderMonthYearNavButton(\n \"previous-month-button\",\n true,\n disabled\n );\n };\n\n private nextMonthButton = (): void => {\n let disabled = false;\n if (this.focussedDate !== null && this.maxDate !== null) {\n const yearMatch =\n this.focussedDate.getFullYear() === this.maxDate.getFullYear();\n if (yearMatch) {\n disabled = this.monthInView + 1 > this.maxDate.getMonth();\n }\n }\n return this.renderMonthYearNavButton(\"next-month-button\", false, disabled);\n };\n\n private previousYearButton = (): void => {\n return this.renderMonthYearNavButton(\n \"previous-year-button\",\n true,\n !this.isPrevYearAllowed()\n );\n };\n\n private nextYearButton = (): void => {\n return this.renderMonthYearNavButton(\n \"next-year-button\",\n false,\n !this.isNextYearAllowed()\n );\n };\n\n private isPrevYearAllowed = (): boolean => {\n return this.isYearAllowed(this.yearInView - 1);\n };\n\n private isNextYearAllowed = (): boolean => {\n return this.isYearAllowed(this.yearInView + 1);\n };\n\n private isYearAllowed = (yr: number): boolean => {\n return yearInRange(yr, this.minDate, this.maxDate);\n };\n\n private getMonthView = (date: Date): Date[] => {\n const start = getWeekStart(getMonthStart(date), this.startOfWeek);\n const end = getWeekEnd(getMonthEnd(date), this.startOfWeek);\n\n const days: Date[] = [];\n let current = start;\n\n while (!dateMatches(current, end)) {\n days.push(current);\n current = new Date(current);\n current.setDate(current.getDate() + 1);\n }\n\n days.push(current);\n\n return days;\n };\n\n private isCurrentMonth = (): boolean => {\n const d = new Date();\n return (\n d.getFullYear() === this.yearInView && d.getMonth() === this.monthInView\n );\n };\n\n private updateMonthInView = (): void => {\n this.currMonthView = this.getMonthView(this.focussedDate);\n\n this.focussedDay = this.focussedDate.getDate();\n this.monthInView = this.focussedDate.getMonth();\n this.yearInView = this.focussedDate.getFullYear();\n\n if (this.dayPickerKeyboardNav) {\n this.monthInViewUpdateHandled = true;\n this.setAriaLiveRegionText(this.getMonthInViewText());\n this.dayPickerKeyboardNav = false;\n }\n };\n\n private handleSelectDay = (day: Date): void => {\n this.setSelectedDate(day);\n this.calendarOpen = false;\n this.inputEl.setCalendarFocus();\n };\n\n private handleSelectMonth = (month: number): void => {\n this.moveMonths(month - this.monthInView);\n setTimeout(() => {\n this.monthButtonEl.setFocus();\n this.monthPickerVisible = false;\n this.setMonthSelectedLiveRegionText();\n }, FOCUS_TIMER);\n };\n\n private handleSelectYear = (year: number): void => {\n const yrPos = this.decadeView.indexOf(year);\n if (yrPos > 0 && yrPos < this.decadeView.length - 1) {\n this.moveYears(year - this.yearInView);\n this.focusDay = false;\n const monthName = this.monthNames[this.monthInView];\n this.setAriaLiveRegionText(\n `${year} selected. ${monthName} ${year} currently in view.`\n );\n setTimeout(() => {\n this.yearButtonEl.setFocus();\n this.yearPickerVisible = false;\n }, FOCUS_TIMER);\n } else {\n const moveYears = year - this.focussedYear > 0 ? 10 : -10;\n this.updateFocussedYear(moveYears, this.yearButtonFocussed);\n this.setAriaLiveRegionText(this.getDecadeInViewText());\n }\n };\n\n private monthPickerKeyDownHandler = (ev: KeyboardEvent): void => {\n let handled = true;\n switch (ev.key) {\n case \"ArrowUp\":\n case \"ArrowLeft\":\n this.updateFocussedMonth(-1);\n break;\n\n case \"ArrowDown\":\n case \"ArrowRight\":\n this.updateFocussedMonth(1);\n break;\n\n case \"Home\":\n this.updateFocussedMonth(-this.focussedMonth);\n break;\n\n case \"End\":\n this.updateFocussedMonth(11 - this.focussedMonth);\n break;\n\n case \"Tab\":\n handled = this.calendarTabHandler(ev);\n break;\n\n case \"Escape\":\n ev.stopImmediatePropagation();\n this.monthPickerVisible = false;\n setTimeout(() => this.focusFocussedDay(), FOCUS_TIMER);\n break;\n\n default:\n handled = false;\n }\n\n if (handled) {\n ev.preventDefault();\n }\n };\n\n private yearPickerKeyDownHandler = (ev: KeyboardEvent): void => {\n let handled = true;\n switch (ev.key) {\n case \"ArrowUp\":\n case \"ArrowLeft\":\n this.updateFocussedYear(-1);\n break;\n\n case \"ArrowDown\":\n case \"ArrowRight\":\n this.updateFocussedYear(1);\n break;\n\n case \"Home\":\n if (this.focussedYear > this.decadeStart) {\n this.updateFocussedYear(this.decadeStart - this.focussedYear);\n }\n break;\n\n case \"End\":\n if (this.focussedYear < this.decadeEnd) {\n this.updateFocussedYear(this.decadeEnd - this.focussedYear);\n }\n break;\n\n case \"PageUp\":\n this.updateFocussedYear(-10);\n break;\n\n case \"PageDown\":\n this.updateFocussedYear(10);\n break;\n\n case \"Tab\":\n handled = this.calendarTabHandler(ev);\n break;\n\n case \"Escape\":\n ev.stopImmediatePropagation();\n this.yearPickerVisible = false;\n setTimeout(() => this.focusFocussedDay(), FOCUS_TIMER);\n break;\n\n default:\n handled = false;\n }\n\n if (handled) {\n ev.preventDefault();\n }\n };\n\n private onYearButtonFocusHandler = () => {\n this.yearButtonFocussed = true;\n };\n\n private onYearButtonBlurHandler = () => {\n this.yearButtonFocussed = false;\n };\n\n private monthButtonKeyDownHandler = (ev: KeyboardEvent): void => {\n let handled = false;\n switch (ev.key) {\n case \"ArrowLeft\":\n case \"ArrowUp\":\n handled = true;\n this.goToPreviousMonth();\n break;\n\n case \"ArrowRight\":\n case \"ArrowDown\":\n handled = true;\n this.goToNextMonth();\n break;\n\n case \"Home\":\n handled = true;\n this.focusDay = false;\n this.moveMonths(-this.monthInView);\n break;\n\n case \"End\":\n handled = true;\n this.focusDay = false;\n this.moveMonths(11 - this.monthInView);\n break;\n\n case \"Tab\":\n if (ev.shiftKey) {\n handled = true;\n this.focusLastElement();\n }\n break;\n\n case \"Escape\":\n if (this.monthPickerVisible) {\n this.monthPickerVisible = false;\n ev.stopImmediatePropagation();\n }\n break;\n\n default:\n break;\n }\n\n if (handled) {\n ev.preventDefault();\n }\n };\n\n private yearButtonKeyDownHandler = (ev: KeyboardEvent): void => {\n let handled = false;\n switch (ev.key) {\n case \"ArrowLeft\":\n case \"ArrowUp\":\n handled = true;\n this.goToPreviousYear();\n break;\n\n case \"ArrowRight\":\n case \"ArrowDown\":\n handled = true;\n this.goToNextYear();\n break;\n\n case \"Home\":\n if (this.yearPickerVisible && this.yearInView > this.decadeStart) {\n handled = true;\n this.moveYears(this.decadeStart - this.yearInView);\n }\n break;\n\n case \"End\":\n if (this.yearPickerVisible && this.yearInView < this.decadeEnd) {\n handled = true;\n this.moveYears(this.decadeEnd - this.focussedYear);\n }\n break;\n\n case \"PageUp\":\n handled = true;\n this.focusDay = false;\n this.moveYears(-10);\n break;\n\n case \"PageDown\":\n handled = true;\n this.focusDay = false;\n this.moveYears(10);\n break;\n\n case \"Escape\":\n if (this.yearPickerVisible) {\n this.yearPickerVisible = false;\n ev.stopImmediatePropagation();\n }\n break;\n\n default:\n break;\n }\n\n if (handled) {\n ev.preventDefault();\n }\n };\n\n private handleCalendarKeyDown = (ev: KeyboardEvent): void => {\n let handled = true;\n switch (ev.key) {\n case \"ArrowDown\":\n this.dayPickerKeyboardNav = true;\n this.moveDays(7);\n break;\n\n case \"ArrowUp\":\n this.dayPickerKeyboardNav = true;\n this.moveDays(-7);\n break;\n\n case \"ArrowLeft\":\n this.dayPickerKeyboardNav = true;\n this.moveDays(-1 * this.getNextDayToFocus(this.focussedDate, false));\n break;\n\n case \"ArrowRight\":\n this.dayPickerKeyboardNav = true;\n this.moveDays(this.getNextDayToFocus(this.focussedDate, true));\n break;\n\n case \"PageUp\":\n this.dayPickerKeyboardNav = true;\n ev.shiftKey ? this.moveYears(-1) : this.moveMonths(-1);\n break;\n\n case \"PageDown\":\n this.dayPickerKeyboardNav = true;\n ev.shiftKey ? this.moveYears(1) : this.moveMonths(1);\n break;\n\n case \"Home\":\n this.dayPickerKeyboardNav = true;\n this.setFocussedDate(\n new Date(this.focussedYear, this.focussedMonth, 1)\n );\n break;\n\n case \"End\":\n this.dayPickerKeyboardNav = true;\n this.setFocussedDate(\n new Date(this.focussedYear, this.focussedMonth + 1, 0)\n );\n break;\n\n case \"Tab\":\n handled = this.calendarTabHandler(ev);\n break;\n\n default:\n handled = false;\n break;\n }\n\n if (handled) {\n ev.preventDefault();\n }\n };\n\n private calendarTabHandler = (ev: KeyboardEvent): boolean => {\n let handled = false;\n if (\n !ev.shiftKey &&\n (!this.showPickerTodayButton || this.isCurrentMonth()) &&\n (!this.showPickerClearButton || this.clearButtonEl.disabled)\n ) {\n this.focusFirstElement();\n handled = true;\n } else if (ev.shiftKey) {\n this.yearButtonEl.setFocus();\n handled = true;\n }\n return handled;\n };\n\n private onDayButtonFocusHandler = () => {\n this.dayButtonFocussed = true;\n };\n\n private onDayButtonBlurHandler = () => {\n this.dayButtonFocussed = false;\n };\n\n private getNextDayToFocus = (\n currDay: Date,\n forward: boolean,\n level = 1\n ): number => {\n const move = forward ? 1 : -1;\n const nextDay = new Date(currDay);\n nextDay.setDate(nextDay.getDate() + move);\n const nextDayNum = Number(nextDay.getDay());\n if (this.disableDays.includes(nextDayNum)) {\n return this.getNextDayToFocus(nextDay, forward, level + 1);\n } else {\n return level;\n }\n };\n\n private moveDays = (numDays: number): void => {\n const d = new Date(this.focussedDate);\n d.setDate(d.getDate() + numDays);\n this.setFocussedDate(d);\n };\n\n private moveMonths = (numMonths: number): void => {\n const newMonth = this.focussedDate.getMonth() + numMonths;\n const min = new Date(\n new Date(getMonthStart(this.focussedDate)).setMonth(newMonth)\n );\n const max = getMonthEnd(min);\n const newDate = new Date(new Date(this.focussedDate).setMonth(newMonth));\n this.setFocussedDate(clampDate(newDate, min, max));\n\n if (\n this.monthPickerVisible === false &&\n this.yearPickerVisible === false &&\n this.monthInViewUpdateHandled === false\n ) {\n this.setAriaLiveRegionText(this.getMonthInViewText());\n }\n this.monthInViewUpdateHandled = false;\n };\n\n private moveYears = (numYears: number): void => {\n const newYear = this.focussedDate.getFullYear() + numYears;\n const min = new Date(\n new Date(getMonthStart(this.focussedDate)).setFullYear(newYear)\n );\n const max = getMonthEnd(min);\n const newDate = new Date(new Date(this.focussedDate).setFullYear(newYear));\n this.setFocussedDate(clampDate(newDate, min, max));\n\n if (\n this.monthPickerVisible === false &&\n this.yearPickerVisible === false &&\n this.monthInViewUpdateHandled === false\n ) {\n this.setAriaLiveRegionText(this.getMonthInViewText());\n }\n this.monthInViewUpdateHandled = false;\n };\n\n private updateFocussedMonth = (adjust: number): void => {\n const d = new Date(this.focussedYear, this.focussedMonth, 1);\n d.setMonth(this.focussedMonth + adjust);\n const newDate = clampDate(d, this.minDate, this.maxDate);\n this.focussedMonth = newDate.getMonth();\n setTimeout(() => this.focussedMonthEl.setFocus(), FOCUS_TIMER);\n };\n\n private updateFocussedYear = (adjust: number, focusYear = true): void => {\n const d = new Date(new Date().setFullYear(this.focussedYear + adjust));\n const newDate = clampDate(d, this.minDate, this.maxDate);\n this.setFocussedYear(newDate.getFullYear(), focusYear);\n };\n\n private setFocussedDate = (d: Date): void => {\n this.focussedDate = clampDate(d, this.minDate, this.maxDate);\n };\n\n private setFocussedDayEl = (element: HTMLButtonElement) => {\n this.focussedDayEl = element;\n };\n\n private setFocussedMonthEl = (element: HTMLIcButtonElement) => {\n this.focussedMonthEl = element;\n };\n\n private setFocussedYearEl = (element: HTMLIcButtonElement) => {\n this.focussedYearEl = element;\n };\n\n private setFocussedYear = (newYear: number, focus = true): void => {\n const prevYear = this.focussedYear;\n this.focussedYear = newYear;\n if (this.yearPickerVisible) {\n const newDecade = Math.floor(newYear / 10) * 10;\n const oldDecade = Math.floor(prevYear / 10) * 10;\n if (newDecade !== oldDecade) {\n this.setDecadeView(newDecade);\n this.setAriaLiveRegionText(this.getDecadeInViewText());\n }\n if (focus) {\n setTimeout(() => {\n if (this.focussedYearEl !== null) this.focussedYearEl.setFocus();\n }, FOCUS_TIMER);\n }\n } else {\n this.setDecadeView(Math.floor(newYear / 10) * 10);\n }\n };\n\n private setDateInputProps = (): IcDateInputProps => {\n const inputProps: IcDateInputProps = {\n hideLabel: this.hideLabel,\n invalidDateMessage: this.invalidDateMessage,\n label: this.label,\n showClearButton: true,\n showCalendarButton: true,\n value: this.value,\n };\n\n if (this.dateFormat !== DEFAULT_DATE_FORMAT) {\n inputProps.dateFormat = this.dateFormat;\n }\n if (this.disableFuture) {\n inputProps.disableFuture = this.disableFuture;\n if (this.disableFutureMessage !== DEFAULT_DISABLE_DATES_FROM_NOW_MSG) {\n inputProps.disableFutureMessage = this.disableFutureMessage;\n }\n }\n if (this.disablePast) {\n inputProps.disablePast = this.disablePast;\n if (this.disablePastMessage !== DEFAULT_DISABLE_DATES_UNTIL_NOW_MSG) {\n inputProps.disablePastMessage = this.disablePastMessage;\n }\n }\n if (this.disableDays.length > 0) {\n inputProps.disableDays = this.disableDays;\n if (this.disableDaysMessage !== DEFAULT_DISABLE_DAYS_MSG) {\n inputProps.disableDaysMessage = this.disableDaysMessage;\n }\n }\n if (this.max !== null && this.max !== \"\") {\n inputProps.max = this.maxDate;\n }\n if (this.min !== null && this.min !== \"\") {\n inputProps.min = this.minDate;\n }\n if (this.helperText !== undefined) {\n inputProps.helperText = this.helperText;\n }\n if (this.hideHelperText !== false) {\n inputProps.hideHelperText = this.hideHelperText;\n }\n if (this.inputId !== undefined) {\n inputProps.inputId = this.inputId;\n }\n if (this.name !== undefined) {\n inputProps.name = this.name;\n }\n if (this.disabled) {\n inputProps.disabled = this.disabled;\n }\n if (this.required) {\n inputProps.required = this.required;\n }\n if (this.size !== \"default\") {\n inputProps.size = this.size;\n }\n if (this.validationStatus !== \"\") {\n inputProps.validationStatus = this.validationStatus;\n }\n if (this.validationText !== \"\") {\n inputProps.validationText = this.validationText;\n }\n return inputProps;\n };\n\n render() {\n const {\n calendarOpen,\n dateInputProps,\n monthNames,\n size,\n focussedMonth,\n focussedYear,\n monthInView,\n yearInView,\n monthPickerVisible,\n yearPickerVisible,\n orderedDaysOfWeek,\n decadeView,\n minDate,\n maxDate,\n showPickerClearButton,\n showPickerTodayButton,\n dialogDescription,\n } = this;\n\n let monthButtonText = \"\";\n if (monthPickerVisible) {\n monthButtonText = `Use the arrow keys to change the selected month. To return to day picker view, press Enter or Space to select a month, or press Escape.`;\n } else {\n monthButtonText = `Press Enter or Space to open month picker view or use the arrow keys to change month.`;\n }\n\n let yearButtonText = \"\";\n if (yearPickerVisible) {\n yearButtonText = `Use the arrow keys to change the selected year. To return to day picker view, press Enter or Space to select a year, or press Escape.`;\n } else {\n yearButtonText = `Press Enter or Space to open year picker view or use the arrow keys to change the selected year.`;\n }\n\n const dialogLabel = \"choose date\";\n\n const monthLabel =\n monthNames && monthNames[monthInView]\n ? monthNames[monthInView]\n : \"Open month picker\";\n const yearLabel = this.yearInView ? this.yearInView : \"Open year picker\";\n\n let minDay = minDate;\n if (this.disablePast) {\n const yesterday = new Date(minDate);\n yesterday.setDate(minDate.getDate() - 1);\n minDay = yesterday;\n }\n\n return (\n <Host onKeyDown={this.keyDownHandler} class={size}>\n <div class=\"date-input-container\">\n <ic-date-input\n ref={(el) => (this.inputEl = el)}\n {...dateInputProps}\n ></ic-date-input>\n </div>\n {calendarOpen && (\n <div>\n <span id=\"dialog-description\" class=\"sr-only\">\n {dialogDescription}\n </span>\n <div\n role=\"dialog\"\n aria-modal=\"true\"\n aria-label={dialogLabel}\n aria-describedBy=\"dialog-description\"\n class={{\n \"calendar-container\": true,\n above: this.showPickerAbove,\n }}\n onMouseDown={this.handleCalendarMouseDown}\n onClick={this.handleCalendarClick}\n >\n <span\n ref={(el) => (this.liveRegionEl = el)}\n id=\"live-region\"\n aria-live=\"assertive\"\n class=\"sr-only\"\n ></span>\n <div\n class={{\n \"month-year-nav-container\": true,\n }}\n >\n <div class=\"month-year-nav\">\n {this.previousMonthButton()}\n <span id=\"select-month-hint\" aria-hidden=\"true\">\n {monthButtonText}\n </span>\n <ic-button\n ref={(el: HTMLIcButtonElement) => (this.monthButtonEl = el)}\n size={size}\n class=\"month-picker-button\"\n aria-haspopup=\"menu\"\n aria-expanded={monthPickerVisible ? \"true\" : \"false\"}\n full-width=\"true\"\n variant=\"tertiary\"\n aria-label={monthLabel}\n aria-describedby=\"select-month-hint\"\n onKeyDown={this.monthButtonKeyDownHandler}\n onClick={this.monthButtonClickHandler}\n >\n {monthNames[monthInView]}\n </ic-button>\n {this.nextMonthButton()}\n </div>\n <div class=\"month-year-nav\">\n {this.previousYearButton()}\n <span id=\"select-year-hint\" aria-hidden=\"true\">\n {yearButtonText}\n </span>\n <ic-button\n ref={(el: HTMLIcButtonElement) => (this.yearButtonEl = el)}\n size={size}\n class=\"year-picker-button\"\n aria-haspopup=\"menu\"\n aria-expanded={yearPickerVisible ? \"true\" : \"false\"}\n full-width=\"true\"\n variant=\"tertiary\"\n aria-label={yearLabel}\n aria-describedby=\"select-year-hint\"\n onKeyDown={this.yearButtonKeyDownHandler}\n onClick={this.yearButtonClickHandler}\n >\n {this.yearInView}\n </ic-button>\n {this.nextYearButton()}\n </div>\n </div>\n {!(monthPickerVisible || yearPickerVisible) && (\n <div\n class={{\n calendar: true,\n hidden: monthPickerVisible || yearPickerVisible,\n }}\n onKeyDown={this.handleCalendarKeyDown}\n >\n <div class=\"weekdays\" aria-hidden=\"true\">\n {orderedDaysOfWeek.map((dayName) => {\n const header =\n size === \"small\" ? dayName.charAt(0) : dayName;\n return (\n <div class=\"calendar-day-header\">\n <ic-typography variant=\"caption\">\n {header}\n </ic-typography>\n </div>\n );\n })}\n </div>\n\n <div class=\"calendar-days-container\">\n {this.currMonthView.map((day) => (\n <DayButton\n day={day}\n disableDay={this.disableDays.includes(\n Number(day.getDay())\n )}\n today={dateMatches(day, this.today)}\n selected={dateMatches(day, this.selectedDate)}\n focussed={dateMatches(day, this.focussedDate)}\n inRange={dateInRange(day, minDay, maxDate)}\n monthInView={monthInView}\n onSelectDay={this.handleSelectDay}\n focussedDayRef={this.setFocussedDayEl}\n onFocusDay={this.onDayButtonFocusHandler}\n onBlurDay={this.onDayButtonBlurHandler}\n showDaysOutsideMonth={this.showDaysOutsideMonth}\n ></DayButton>\n ))}\n </div>\n </div>\n )}\n <div\n class={{\n \"month-picker-container\": true,\n hidden: !monthPickerVisible,\n }}\n >\n {monthPickerVisible && (\n <MonthPicker\n size={size}\n onSelectMonth={this.handleSelectMonth}\n monthInView={monthInView}\n focussedMonth={focussedMonth}\n onKeyDown={this.monthPickerKeyDownHandler}\n focussedMonthRef={this.setFocussedMonthEl}\n minDate={minDate}\n maxDate={maxDate}\n yearInView={yearInView}\n ></MonthPicker>\n )}\n </div>\n <div\n class={{\n \"year-picker-container\": true,\n hidden: !yearPickerVisible,\n }}\n >\n {yearPickerVisible && (\n <YearPicker\n decadeView={decadeView}\n size={size}\n focussedYear={focussedYear}\n onSelectYear={this.handleSelectYear}\n onKeyDown={this.yearPickerKeyDownHandler}\n onFocusYear={this.onYearButtonFocusHandler}\n onBlurYear={this.onYearButtonBlurHandler}\n yearInView={yearInView}\n minDate={minDate}\n maxDate={maxDate}\n focussedYearRef={this.setFocussedYearEl}\n ></YearPicker>\n )}\n </div>\n <div\n class={{\n \"bottom-buttons\": true,\n \"no-today\": !showPickerTodayButton,\n }}\n >\n {showPickerTodayButton && (\n <ic-button\n id=\"today-button\"\n variant=\"tertiary\"\n ref={(el: HTMLIcButtonElement) => (this.todayButtonEl = el)}\n size={size}\n aria-label=\"Navigate to current date\"\n onClick={this.todayButtonClickHandler}\n onKeyDown={this.todayButtonKeyDownHandler}\n disabled={this.isCurrentMonth()}\n >\n Go to today\n </ic-button>\n )}\n {showPickerClearButton && (\n <ic-button\n id=\"clear-button\"\n aria-label=\"clear selected date\"\n ref={(el: HTMLIcButtonElement) => (this.clearButtonEl = el)}\n variant=\"tertiary\"\n size={size}\n onClick={this.clearButtonClickHandler}\n onKeyDown={this.clearButtonKeyDownHandler}\n disabled={\n this.value === \"\" ||\n this.value === null ||\n this.value === undefined\n }\n >\n Clear\n </ic-button>\n )}\n </div>\n </div>\n </div>\n )}\n </Host>\n );\n }\n}\n"]}
|
1
|
+
{"version":3,"file":"ic-date-picker.js","sourceRoot":"","sources":["../../../src/components/ic-date-picker/ic-date-picker.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EACT,OAAO,EACP,IAAI,EACJ,CAAC,EACD,IAAI,EACJ,MAAM,EACN,KAAK,EACL,KAAK,EACL,KAAK,GAEN,MAAM,eAAe,CAAC;AACvB,OAAO,EACL,UAAU,EACV,SAAS,EACT,WAAW,EACX,WAAW,EACX,aAAa,EACb,WAAW,EACX,UAAU,EACV,YAAY,EACZ,WAAW,GACZ,MAAM,0BAA0B,CAAC;AAClC,OAAO,EACL,iBAAiB,EACjB,gCAAgC,EAChC,mBAAmB,GACpB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAEL,iBAAiB,EACjB,UAAU,EAEV,eAAe,EAEf,UAAU,GACX,MAAM,mBAAmB,CAAC;AAC3B,OAAO,OAAO,MAAM,+BAA+B,CAAC;AACpD,OAAO,EAAE,SAAS,EAAE,MAAM,iBAA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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import {\n Component,\n Element,\n Host,\n h,\n Prop,\n Listen,\n Watch,\n State,\n Event,\n EventEmitter,\n} from \"@stencil/core\";\nimport {\n createDate,\n clampDate,\n dateMatches,\n dateInRange,\n getMonthStart,\n getMonthEnd,\n getWeekEnd,\n getWeekStart,\n yearInRange,\n} from \"../../utils/date-helpers\";\nimport {\n stringEnumToArray,\n onComponentRequiredPropUndefined,\n removeDisabledFalse,\n} from \"../../utils/helpers\";\nimport {\n IcDateFormat,\n IcDateInputMonths,\n IcDayNames,\n IcInformationStatusOrEmpty,\n IcShortDayNames,\n IcSizes,\n IcWeekDays,\n} from \"../../utils/types\";\nimport chevron from \"../../assets/chevron-icon.svg\";\nimport { DayButton } from \"./ic-day-button\";\nimport { MonthPicker } from \"./ic-month-picker\";\nimport { YearPicker } from \"./ic-year-picker\";\n\nconst DEFAULT_DATE_FORMAT = \"DD/MM/YYYY\";\nconst DEFAULT_DISABLE_DATES_FROM_NOW_MSG =\n \"Dates in the future are not allowed. Please select a date in the past.\";\nconst DEFAULT_DISABLE_DATES_UNTIL_NOW_MSG =\n \"Dates in the past are not allowed. Please select a date in the future.\";\nconst DEFAULT_DISABLE_DAYS_MSG =\n \"The date you have selected is on a day of the week that is not allowed. Please select another date.\";\nconst FOCUS_TIMER = 100;\nconst PICKER_HEIGHT_SMALL = 360;\nconst PICKER_HEIGHT_DEFAULT = 400;\nconst PICKER_HEIGHT_LARGE = 440;\n\ninterface IcDateInputProps {\n dateFormat?: IcDateFormat;\n disabled?: boolean;\n disableDays?: IcWeekDays[];\n disableDaysMessage?: string;\n disableFuture?: boolean;\n disableFutureMessage?: string;\n disablePast?: boolean;\n disablePastMessage?: string;\n helperText?: string;\n hideHelperText?: boolean;\n hideLabel?: boolean;\n inputId?: string;\n invalidDateMessage?: string;\n label: string;\n max?: string | Date;\n min?: string | Date;\n name?: string;\n required?: boolean;\n showClearButton?: boolean;\n showCalendarButton?: boolean;\n showDateInput?: boolean;\n size?: IcSizes;\n value?: string | Date;\n validationStatus?: IcInformationStatusOrEmpty;\n validationText?: string;\n}\n\n@Component({\n tag: \"ic-date-picker\",\n styleUrl: \"ic-date-picker.css\",\n shadow: {\n delegatesFocus: true,\n },\n})\nexport class DatePicker {\n private inputEl: HTMLIcDateInputElement;\n private clearButtonEl: HTMLIcButtonElement = null;\n private dateInputProps: IcDateInputProps;\n private daysOfWeek: string[] = [];\n private dayButtonFocussed: boolean = false;\n private dayPickerKeyboardNav: boolean = false;\n private decadeStart: number;\n private decadeEnd: number;\n private dialogDescription: string = \"\";\n private focusDay: boolean = true;\n private focussedYearEl: HTMLIcButtonElement;\n private liveRegionEl: HTMLElement = null;\n private monthButtonEl: HTMLIcButtonElement;\n private monthNames: string[] = [];\n private monthInViewUpdateHandled: boolean = false;\n private myCalendarButtonClicked: boolean = false;\n private showPickerAbove: boolean = false;\n private today = new Date();\n private todayButtonEl: HTMLIcButtonElement = null;\n private yearButtonEl: HTMLIcButtonElement;\n private yearButtonFocussed: boolean = false;\n private selectedDateInfoEl: HTMLSpanElement;\n private selectedDateInfoId: string;\n\n @Element() el: HTMLIcDatePickerElement;\n\n @State() calendarOpen: boolean = false;\n @State() currMonthView: Date[] = [];\n @State() currYearPickerView: number[] = [];\n @State() decadeView: number[] = [];\n @State() focussedDate: Date = null;\n @State() focussedDay: number;\n @State() focussedDayEl: HTMLButtonElement;\n @State() focussedMonth: number;\n @State() focussedMonthEl: HTMLIcButtonElement;\n @State() focussedYear: number;\n @State() maxDate: Date = null;\n @State() minDate: Date = null;\n @State() monthInView: number;\n @State() monthPickerVisible: boolean = false;\n @State() orderedDaysOfWeek: string[] = [];\n @State() selectedDate: Date = null;\n @State() yearInView: number;\n @State() yearPickerVisible: boolean = false;\n\n /**\n * The format in which the date will be displayed.\n */\n @Prop() dateFormat?: IcDateFormat = \"DD/MM/YYYY\";\n\n /**\n * If `true`, the disabled state will be set.\n */\n @Prop() disabled?: boolean = false;\n @Watch(\"disabled\")\n watchDisabledHandler(): void {\n removeDisabledFalse(this.disabled, this.el);\n }\n\n /**\n * The days of the week to disable.\n */\n @Prop() disableDays?: IcWeekDays[] = [];\n\n /**\n * The text to display as the validation message when `disableDays` is `true` and a disabled date is entered.\n */\n @Prop() disableDaysMessage?: string =\n \"The date you have selected is on a day of the week that is not allowed. Please select another date.\";\n\n /**\n * If `true`, dates in the future are not allowed. A validation message will appear if a date in the future is entered.\n */\n @Prop() disableFuture?: boolean = false;\n\n @Watch(\"disableFuture\")\n watchDisableFutureHandler(): void {\n this.watchMaxHandler();\n }\n\n /**\n * The text to display as the validation message when `disableFuture` is `true` and a date in the future is entered.\n */\n @Prop() disableFutureMessage?: string =\n \"Dates in the future are not allowed. Please select a date in the past.\";\n\n /**\n * If `true`, dates in the past are not allowed. A validation message will appear if a date in the past is entered.\n */\n @Prop() disablePast?: boolean = false;\n\n @Watch(\"disablePast\")\n watchDisablePastHandler(): void {\n this.watchMinHandler();\n }\n\n /**\n * The text to display as the validation message when `disablePast` is `true` and a date in the past is entered.\n */\n @Prop() disablePastMessage?: string =\n \"Dates in the past are not allowed. Please select a date in the future.\";\n\n /**\n * The helper text that will be displayed for additional field guidance. This will default to the text \"Use format\" along with the `dateFormat` value.\n */\n @Prop() helperText?: string;\n\n /**\n * If `true`, the helper text will be visually hidden, but still read out by screenreaders.\n */\n @Prop() hideHelperText: boolean = false;\n\n /**\n * If `true`, the label will be visually hidden, but the required label will still be read out by screen readers.\n */\n @Prop() hideLabel?: boolean = false;\n\n /**\n * The ID for the input field. The default will be an automatically generated value.\n */\n @Prop() inputId?: string;\n\n /**\n * The text to display as the validation message when an invalid date is entered.\n */\n @Prop() invalidDateMessage?: string = \"Please enter a valid date.\";\n\n /**\n * The label for the date input.\n */\n @Prop() label!: string;\n\n /**\n * The latest date that will be allowed. The value can be in any format supported as `dateFormat`, in ISO 8601 date string format (`yyyy-mm-dd`) or as a JavaScript `Date` object.\n * The value of this prop is ignored if `disableFuture` is set to `true`.\n */\n @Prop() max?: string | Date = \"\";\n\n @Watch(\"max\")\n watchMaxHandler(): void {\n if (this.disableFuture) {\n this.maxDate = new Date();\n } else {\n this.maxDate = createDate(this.max, this.dateFormat);\n }\n }\n\n /**\n * The earliest date that will be allowed. The value can be in any format supported as `dateFormat`, in ISO 8601 date string format (`yyyy-mm-dd`) or as a JavaScript `Date` object.\n * The value of this prop is ignored if `disablePast` is set to `true`.\n */\n @Prop() min?: string | Date = \"\";\n\n @Watch(\"min\")\n watchMinHandler(): void {\n if (this.disablePast) {\n this.minDate = new Date();\n } else {\n this.minDate = createDate(this.min, this.dateFormat);\n }\n }\n\n /**\n * The name of the control, which is submitted with the form data.\n */\n @Prop() name?: string;\n\n /**\n * The date visible when the calendar opens. Used if no date is currently selected.\n * The value can be in any format supported as `dateFormat`, in ISO 8601 date string format (`yyyy-mm-dd`) or as a JavaScript `Date` object.\n */\n @Prop() openAtDate: string | Date = \"\";\n\n /**\n * If `true`, the input will require a value.\n */\n @Prop() required?: boolean = false;\n\n /**\n * @deprecated This prop should not be used anymore. If `false` hides the date input control and just displays the calendar.\n */\n @Prop() showDateInput?: boolean = true;\n\n @Watch(\"showDateInput\")\n watchShowDateInputHandler(): void {\n if (!this.showDateInput) {\n this.calendarOpen = true;\n }\n }\n\n /**\n * If `true`, days outside the current month will be visible in the date picker.\n */\n @Prop() showDaysOutsideMonth?: boolean = true;\n\n /**\n * If `true`, the `Clear` button on the date picker will be visible.\n */\n @Prop() showPickerClearButton?: boolean = true;\n\n /**\n * If `true`, the `Go to today` button on the date picker will be visible.\n */\n @Prop() showPickerTodayButton?: boolean = true;\n\n /**\n * The size of the date picker to be displayed.\n */\n @Prop() size?: IcSizes = \"default\";\n\n /**\n * The first day of the week. `0` for Sunday, `1` for Monday, etc.\n * Default is Monday.\n */\n @Prop() startOfWeek?: IcWeekDays = IcWeekDays.Monday;\n\n @Watch(\"startOfWeek\")\n watchStartOfWeekHandler(): void {\n this.orderedDaysOfWeek = this.daysOfWeek\n .slice(this.startOfWeek)\n .concat(this.daysOfWeek.slice(0, this.startOfWeek));\n if (this.calendarOpen) {\n this.updateMonthInView();\n }\n }\n\n /**\n * The validation status - e.g. 'error' | 'warning' | 'success'. This will override the built-in date validation.\n */\n @Prop() validationStatus?: IcInformationStatusOrEmpty = \"\";\n\n /**\n * The text to display as the validation message. This will override the built-in date validation.\n */\n @Prop() validationText?: string = \"\";\n\n /**\n * The value of the date picker. The value can be in any format supported as `dateFormat`, in ISO 8601 date string format (`yyyy-mm-dd`) or as a JavaScript `Date` object.\n */\n @Prop({ mutable: true }) value?: string | Date | null | undefined = \"\";\n\n @Watch(\"calendarOpen\")\n watchOpenHandler(): void {\n if (this.calendarOpen) {\n if (this.inputEl) {\n let pickerHeight = PICKER_HEIGHT_DEFAULT;\n if (this.size === \"small\") {\n pickerHeight = PICKER_HEIGHT_SMALL;\n } else if (this.size === \"large\") {\n pickerHeight = PICKER_HEIGHT_LARGE;\n }\n if (\n this.el.offsetTop + this.inputEl.offsetHeight + pickerHeight >\n window.innerHeight &&\n this.el.offsetTop > pickerHeight\n ) {\n this.showPickerAbove = true;\n } else {\n this.showPickerAbove = false;\n }\n }\n if (\n this.selectedDate === null ||\n !dateInRange(this.selectedDate, this.minDate, this.maxDate)\n ) {\n let openAt = new Date();\n if (this.openAtDate !== \"\") {\n openAt = createDate(this.openAtDate, this.dateFormat);\n }\n this.setFocussedDate(openAt);\n } else {\n this.setFocussedDate(this.selectedDate);\n }\n let dialogDesc = this.getMonthInViewText();\n if (this.selectedDate === null) {\n dialogDesc += \" No date selected.\";\n }\n dialogDesc +=\n \" Use arrow keys to change day. Press enter or space to select a date or press escape to close the picker\";\n this.dialogDescription = dialogDesc;\n setTimeout(() => this.focusFocussedDay(), FOCUS_TIMER);\n document.addEventListener(\"click\", this.handleDocumentClick);\n } else {\n document.removeEventListener(\"click\", this.handleDocumentClick);\n this.monthPickerVisible = false;\n this.yearPickerVisible = false;\n }\n }\n\n @Watch(\"focussedDate\")\n watchFocussedDateHandler(current: Date, previous: Date): void {\n if (\n previous === null ||\n !(\n previous.getFullYear() === current.getFullYear() &&\n previous.getMonth() === current.getMonth()\n )\n ) {\n this.updateMonthInView();\n }\n }\n\n @Watch(\"monthInView\")\n watchMonthInViewHandler(): void {\n this.focussedMonth = this.monthInView;\n }\n\n @Watch(\"yearInView\")\n watchYearInViewHandler(): void {\n this.setFocussedYear(this.yearInView, false);\n }\n\n @Watch(\"yearPickerVisible\")\n watchYearPickerVisibleHandler(): void {\n if (!this.yearPickerVisible) {\n this.setFocussedYear(this.yearInView);\n }\n }\n\n @Watch(\"monthPickerVisible\")\n watchMonthPickerVisibleHandler(): void {\n if (!this.monthPickerVisible) {\n this.focussedMonth = this.monthInView;\n }\n }\n\n @Watch(\"focussedDayEl\")\n watchFocussedDayEl(): void {\n if (this.focusDay) {\n setTimeout(() => this.focusFocussedDay(), FOCUS_TIMER);\n }\n\n this.focusDay = true;\n }\n\n /**\n * Emitted when the value has changed.\n */\n @Event() icChange: EventEmitter<{ value: Date }>;\n\n /**\n * Emitted when the selected date has changed.\n */\n @Event() icSelectedDateChange: EventEmitter<{ value: Date }>;\n\n componentWillLoad(): void {\n onComponentRequiredPropUndefined(\n [{ prop: this.label, propName: \"label\" }],\n \"Date Picker\"\n );\n\n this.monthNames = stringEnumToArray(IcDateInputMonths);\n this.daysOfWeek = stringEnumToArray(IcShortDayNames);\n\n this.watchStartOfWeekHandler();\n this.watchMaxHandler();\n this.watchMinHandler();\n removeDisabledFalse(this.disabled, this.el);\n\n this.selectedDateInfoId = `${this.inputId}-selected-date-info`;\n }\n\n componentWillRender(): void {\n this.dateInputProps = this.setDateInputProps();\n\n if (!this.showDateInput) {\n this.calendarOpen = true;\n }\n }\n\n componentWillUpdate(): void {\n this.dateInputProps = this.setDateInputProps();\n }\n\n componentDidLoad(): void {\n if (!this.showDateInput && this.value) {\n this.setSelectedDate(new Date(this.value));\n this.setFocussedDate(this.selectedDate);\n }\n }\n\n @Listen(\"calendarButtonClicked\")\n localCalendarButtonClickHandler(ev: CustomEvent): void {\n this.myCalendarButtonClicked = true;\n if (!this.calendarOpen) {\n this.setSelectedDate(ev.detail.value, false);\n }\n\n this.calendarOpen = !this.calendarOpen;\n }\n\n @Listen(\"calendarButtonClicked\", { target: \"document\" })\n calendarButtonClickHandler(): void {\n //closes this picker if calendar button in another clicked\n\n if (!this.myCalendarButtonClicked && this.showDateInput) {\n this.calendarOpen = false;\n }\n this.myCalendarButtonClicked = false;\n }\n\n private setDecadeView = (start: number) => {\n let currYear = start - 1;\n const decadeArr = [];\n while (currYear <= start + 10) {\n decadeArr.push(currYear);\n currYear++;\n }\n this.decadeView = decadeArr;\n this.decadeStart = decadeArr[1];\n this.decadeEnd = decadeArr[10];\n };\n\n private notifyScreenReaderSelectedDate = () => {\n const dayNames = stringEnumToArray(IcDayNames);\n const months = stringEnumToArray(IcDateInputMonths);\n\n this.selectedDateInfoEl.textContent = this.selectedDate\n ? `Selected date: ${\n dayNames[this.selectedDate.getDay()]\n }, ${this.selectedDate.getDate()} ${\n months[this.selectedDate.getMonth()]\n } ${this.selectedDate.getFullYear()}`\n : \"Selected date cleared\";\n };\n\n private setSelectedDate = (d: Date, emit = true): void => {\n if (d === null || !dateMatches(d, this.selectedDate)) {\n this.selectedDate = d;\n this.value = d;\n\n if (emit) {\n if (this.inputEl) {\n this.inputEl.triggerIcChange(d);\n } else {\n if (this.selectedDate) {\n this.setFocussedDate(this.selectedDate);\n }\n\n this.icSelectedDateChange.emit({ value: d });\n if (!this.showDateInput && this.selectedDateInfoEl) {\n this.notifyScreenReaderSelectedDate();\n }\n }\n }\n }\n };\n\n private handleCalendarMouseDown = (event: MouseEvent): void => {\n const target = event.target as HTMLElement;\n if (target.tagName !== \"IC-BUTTON\") {\n event.preventDefault();\n }\n };\n\n private handleCalendarClick = (event: MouseEvent): void => {\n this.clearDialogDescription();\n event.stopImmediatePropagation();\n };\n\n private handleDocumentClick = (): void => {\n if (this.showDateInput) {\n this.calendarOpen = false;\n }\n };\n\n private keyDownHandler = (event: KeyboardEvent) => {\n if (event.key === \"Escape\") {\n if (this.calendarOpen) {\n this.closeButtonClickHandler();\n if (this.inputEl) {\n this.inputEl.setCalendarFocus();\n }\n event.stopImmediatePropagation();\n }\n } else {\n this.clearDialogDescription();\n event.stopImmediatePropagation();\n }\n };\n\n private closeButtonClickHandler = () => {\n if (this.showDateInput) {\n this.calendarOpen = false;\n }\n };\n\n private focusFirstElement = () => {\n this.monthButtonEl.setFocus();\n };\n\n private focusLastElement = () => {\n if (this.showPickerClearButton && !this.clearButtonEl.disabled) {\n this.clearButtonEl.setFocus();\n } else if (this.showPickerTodayButton && !this.todayButtonEl.disabled) {\n this.todayButtonEl.setFocus();\n } else if (this.monthPickerVisible) {\n this.focussedMonthEl.setFocus();\n } else if (this.yearPickerVisible) {\n this.focussedYearEl.setFocus();\n } else {\n this.focussedDayEl.focus();\n }\n };\n\n private focusFocussedDay = () => {\n this.focussedDayEl.focus();\n };\n\n private monthButtonClickHandler = () => {\n this.yearPickerVisible = false;\n this.focusDay = false;\n this.monthPickerVisible = !this.monthPickerVisible;\n if (this.monthPickerVisible) {\n this.setAriaLiveRegionText(\"Month picker view open\");\n } else {\n this.setMonthSelectedLiveRegionText();\n }\n };\n\n private yearButtonClickHandler = () => {\n this.monthPickerVisible = false;\n this.focusDay = false;\n this.yearPickerVisible = !this.yearPickerVisible;\n if (this.yearPickerVisible) {\n this.setAriaLiveRegionText(\n `Year picker view open. ${this.getDecadeInViewText()}`\n );\n } else {\n this.setYearSelectedLiveRegionText();\n }\n };\n\n private todayButtonClickHandler = () => {\n this.yearPickerVisible = false;\n this.monthPickerVisible = false;\n this.setFocussedDate(new Date());\n this.setAriaLiveRegionText(this.getMonthInViewText());\n\n setTimeout(() => this.focusFocussedDay(), FOCUS_TIMER);\n };\n\n private todayButtonKeyDownHandler = (ev: KeyboardEvent) => {\n if (ev.key === \"Tab\" && !ev.shiftKey && this.clearButtonEl.disabled) {\n this.focusFirstElement();\n ev.preventDefault();\n }\n };\n\n private clearButtonClickHandler = () => {\n this.setSelectedDate(null);\n let text = \"Selected date cleared.\";\n if (!this.monthPickerVisible && !this.yearPickerVisible) {\n text += ` ${this.getMonthInViewText()}`;\n }\n if (this.monthPickerVisible) {\n this.focussedMonthEl.setFocus();\n } else if (this.yearPickerVisible) {\n this.focussedYearEl.setFocus();\n } else {\n this.focusFocussedDay();\n }\n this.setAriaLiveRegionText(text);\n };\n\n private setMonthSelectedLiveRegionText = () => {\n this.setAriaLiveRegionText(\n `${\n this.monthNames[this.monthInView]\n } selected. ${this.getMonthInViewText()}`\n );\n };\n\n private setYearSelectedLiveRegionText = () => {\n this.setAriaLiveRegionText(\n `${this.yearInView} selected. ${this.getMonthInViewText()}`\n );\n };\n\n private getMonthInViewText = () => {\n return `${this.monthNames[this.monthInView]} ${\n this.yearInView\n } currently in view.`;\n };\n\n private getDecadeInViewText = () => {\n return `${this.decadeStart} to ${this.decadeEnd} currently in view.`;\n };\n\n private setAriaLiveRegionText = (text: string) => {\n this.liveRegionEl && (this.liveRegionEl.innerText = text);\n };\n\n private clearDialogDescription = () => {\n this.dialogDescription = \"\";\n };\n\n private clearButtonKeyDownHandler = (ev: KeyboardEvent) => {\n if (ev.key === \"Tab\" && !ev.shiftKey) {\n this.focusFirstElement();\n ev.preventDefault();\n }\n };\n\n private goToPreviousMonth = (focusDay = false) => {\n this.focusDay = focusDay;\n this.moveMonths(-1);\n };\n\n private goToNextMonth = (focusDay = false) => {\n this.focusDay = focusDay;\n this.moveMonths(1);\n };\n\n private goToPreviousYear = (focusDay = false) => {\n if (this.isPrevYearAllowed()) {\n this.focusDay = focusDay;\n this.moveYears(-1);\n }\n };\n\n private goToNextYear = (focusDay = false) => {\n if (this.isNextYearAllowed()) {\n this.focusDay = focusDay;\n this.moveYears(1);\n }\n };\n\n private navButtonMouseDownHandler = (ev: MouseEvent): void => {\n ev.preventDefault();\n };\n\n private renderMonthYearNavButton = (\n id: string,\n flip: boolean,\n disabled: boolean\n ): void => {\n const buttonSize = this.size;\n return (\n <div aria-hidden=\"true\">\n <ic-button\n id={id}\n disableTooltip={true}\n disabled={disabled}\n onClick={this.monthYearNavClickHandler}\n class={{ flip: flip }}\n variant=\"icon\"\n innerHTML={chevron}\n size={buttonSize}\n tabIndex={-1}\n aria-hidden=\"true\"\n onMouseDown={this.navButtonMouseDownHandler}\n />\n </div>\n );\n };\n\n private monthYearNavClickHandler = (ev: Event): void => {\n const target = ev.target as Element;\n switch (target.id) {\n case \"previous-month-button\":\n this.goToPreviousMonth(this.dayButtonFocussed);\n break;\n\n case \"next-month-button\":\n this.goToNextMonth(this.dayButtonFocussed);\n break;\n\n case \"previous-year-button\":\n this.goToPreviousYear(this.dayButtonFocussed);\n break;\n\n case \"next-year-button\":\n this.goToNextYear(this.dayButtonFocussed);\n break;\n }\n };\n\n private previousMonthButton = (): void => {\n let disabled = false;\n if (this.focussedDate !== null && this.minDate !== null) {\n const yearMatch =\n this.focussedDate.getFullYear() === this.minDate.getFullYear();\n if (yearMatch) {\n disabled = this.monthInView - 1 < this.minDate.getMonth();\n }\n }\n return this.renderMonthYearNavButton(\n \"previous-month-button\",\n true,\n disabled\n );\n };\n\n private nextMonthButton = (): void => {\n let disabled = false;\n if (this.focussedDate !== null && this.maxDate !== null) {\n const yearMatch =\n this.focussedDate.getFullYear() === this.maxDate.getFullYear();\n if (yearMatch) {\n disabled = this.monthInView + 1 > this.maxDate.getMonth();\n }\n }\n return this.renderMonthYearNavButton(\"next-month-button\", false, disabled);\n };\n\n private previousYearButton = (): void => {\n return this.renderMonthYearNavButton(\n \"previous-year-button\",\n true,\n !this.isPrevYearAllowed()\n );\n };\n\n private nextYearButton = (): void => {\n return this.renderMonthYearNavButton(\n \"next-year-button\",\n false,\n !this.isNextYearAllowed()\n );\n };\n\n private isPrevYearAllowed = (): boolean => {\n return this.isYearAllowed(this.yearInView - 1);\n };\n\n private isNextYearAllowed = (): boolean => {\n return this.isYearAllowed(this.yearInView + 1);\n };\n\n private isYearAllowed = (yr: number): boolean => {\n return yearInRange(yr, this.minDate, this.maxDate);\n };\n\n private getMonthView = (date: Date): Date[] => {\n const start = getWeekStart(getMonthStart(date), this.startOfWeek);\n const end = getWeekEnd(getMonthEnd(date), this.startOfWeek);\n\n const days: Date[] = [];\n let current = start;\n\n while (!dateMatches(current, end)) {\n days.push(current);\n current = new Date(current);\n current.setDate(current.getDate() + 1);\n }\n\n days.push(current);\n\n return days;\n };\n\n private isCurrentMonth = (): boolean => {\n const d = new Date();\n return (\n d.getFullYear() === this.yearInView && d.getMonth() === this.monthInView\n );\n };\n\n private updateMonthInView = (): void => {\n this.currMonthView = this.getMonthView(this.focussedDate);\n\n this.focussedDay = this.focussedDate.getDate();\n this.monthInView = this.focussedDate.getMonth();\n this.yearInView = this.focussedDate.getFullYear();\n\n if (this.dayPickerKeyboardNav) {\n this.monthInViewUpdateHandled = true;\n this.setAriaLiveRegionText(this.getMonthInViewText());\n this.dayPickerKeyboardNav = false;\n }\n };\n\n private handleSelectDay = (day: Date): void => {\n this.setSelectedDate(day);\n\n if (this.showDateInput) {\n this.calendarOpen = false;\n if (this.inputEl) {\n this.inputEl.setCalendarFocus();\n }\n }\n };\n\n private handleSelectMonth = (month: number): void => {\n this.moveMonths(month - this.monthInView);\n setTimeout(() => {\n this.monthButtonEl.setFocus();\n this.monthPickerVisible = false;\n this.setMonthSelectedLiveRegionText();\n }, FOCUS_TIMER);\n };\n\n private handleSelectYear = (year: number): void => {\n const yrPos = this.decadeView.indexOf(year);\n if (yrPos > 0 && yrPos < this.decadeView.length - 1) {\n this.moveYears(year - this.yearInView);\n this.focusDay = false;\n const monthName = this.monthNames[this.monthInView];\n this.setAriaLiveRegionText(\n `${year} selected. ${monthName} ${year} currently in view.`\n );\n setTimeout(() => {\n this.yearButtonEl.setFocus();\n this.yearPickerVisible = false;\n }, FOCUS_TIMER);\n } else {\n const moveYears = year - this.focussedYear > 0 ? 10 : -10;\n this.updateFocussedYear(moveYears, this.yearButtonFocussed);\n this.setAriaLiveRegionText(this.getDecadeInViewText());\n }\n };\n\n private monthPickerKeyDownHandler = (ev: KeyboardEvent): void => {\n let handled = true;\n switch (ev.key) {\n case \"ArrowUp\":\n case \"ArrowLeft\":\n this.updateFocussedMonth(-1);\n break;\n\n case \"ArrowDown\":\n case \"ArrowRight\":\n this.updateFocussedMonth(1);\n break;\n\n case \"Home\":\n this.updateFocussedMonth(-this.focussedMonth);\n break;\n\n case \"End\":\n this.updateFocussedMonth(11 - this.focussedMonth);\n break;\n\n case \"Tab\":\n handled = this.calendarTabHandler(ev);\n break;\n\n case \"Escape\":\n ev.stopImmediatePropagation();\n this.monthPickerVisible = false;\n setTimeout(() => this.focusFocussedDay(), FOCUS_TIMER);\n break;\n\n default:\n handled = false;\n }\n\n if (handled) {\n ev.preventDefault();\n }\n };\n\n private yearPickerKeyDownHandler = (ev: KeyboardEvent): void => {\n let handled = true;\n switch (ev.key) {\n case \"ArrowUp\":\n case \"ArrowLeft\":\n this.updateFocussedYear(-1);\n break;\n\n case \"ArrowDown\":\n case \"ArrowRight\":\n this.updateFocussedYear(1);\n break;\n\n case \"Home\":\n if (this.focussedYear > this.decadeStart) {\n this.updateFocussedYear(this.decadeStart - this.focussedYear);\n }\n break;\n\n case \"End\":\n if (this.focussedYear < this.decadeEnd) {\n this.updateFocussedYear(this.decadeEnd - this.focussedYear);\n }\n break;\n\n case \"PageUp\":\n this.updateFocussedYear(-10);\n break;\n\n case \"PageDown\":\n this.updateFocussedYear(10);\n break;\n\n case \"Tab\":\n handled = this.calendarTabHandler(ev);\n break;\n\n case \"Escape\":\n ev.stopImmediatePropagation();\n this.yearPickerVisible = false;\n setTimeout(() => this.focusFocussedDay(), FOCUS_TIMER);\n break;\n\n default:\n handled = false;\n }\n\n if (handled) {\n ev.preventDefault();\n }\n };\n\n private onYearButtonFocusHandler = () => {\n this.yearButtonFocussed = true;\n };\n\n private onYearButtonBlurHandler = () => {\n this.yearButtonFocussed = false;\n };\n\n private monthButtonKeyDownHandler = (ev: KeyboardEvent): void => {\n let handled = false;\n switch (ev.key) {\n case \"ArrowLeft\":\n case \"ArrowUp\":\n handled = true;\n this.goToPreviousMonth();\n break;\n\n case \"ArrowRight\":\n case \"ArrowDown\":\n handled = true;\n this.goToNextMonth();\n break;\n\n case \"Home\":\n handled = true;\n this.focusDay = false;\n this.moveMonths(-this.monthInView);\n break;\n\n case \"End\":\n handled = true;\n this.focusDay = false;\n this.moveMonths(11 - this.monthInView);\n break;\n\n case \"Tab\":\n if (ev.shiftKey) {\n handled = true;\n this.focusLastElement();\n }\n break;\n\n case \"Escape\":\n if (this.monthPickerVisible) {\n this.monthPickerVisible = false;\n ev.stopImmediatePropagation();\n }\n break;\n\n default:\n break;\n }\n\n if (handled) {\n ev.preventDefault();\n }\n };\n\n private yearButtonKeyDownHandler = (ev: KeyboardEvent): void => {\n let handled = false;\n switch (ev.key) {\n case \"ArrowLeft\":\n case \"ArrowUp\":\n handled = true;\n this.goToPreviousYear();\n break;\n\n case \"ArrowRight\":\n case \"ArrowDown\":\n handled = true;\n this.goToNextYear();\n break;\n\n case \"Home\":\n if (this.yearPickerVisible && this.yearInView > this.decadeStart) {\n handled = true;\n this.moveYears(this.decadeStart - this.yearInView);\n }\n break;\n\n case \"End\":\n if (this.yearPickerVisible && this.yearInView < this.decadeEnd) {\n handled = true;\n this.moveYears(this.decadeEnd - this.focussedYear);\n }\n break;\n\n case \"PageUp\":\n handled = true;\n this.focusDay = false;\n this.moveYears(-10);\n break;\n\n case \"PageDown\":\n handled = true;\n this.focusDay = false;\n this.moveYears(10);\n break;\n\n case \"Escape\":\n if (this.yearPickerVisible) {\n this.yearPickerVisible = false;\n ev.stopImmediatePropagation();\n }\n break;\n\n default:\n break;\n }\n\n if (handled) {\n ev.preventDefault();\n }\n };\n\n private handleCalendarKeyDown = (ev: KeyboardEvent): void => {\n let handled = true;\n switch (ev.key) {\n case \"ArrowDown\":\n this.dayPickerKeyboardNav = true;\n this.moveDays(7);\n break;\n\n case \"ArrowUp\":\n this.dayPickerKeyboardNav = true;\n this.moveDays(-7);\n break;\n\n case \"ArrowLeft\":\n this.dayPickerKeyboardNav = true;\n this.moveDays(-1 * this.getNextDayToFocus(this.focussedDate, false));\n break;\n\n case \"ArrowRight\":\n this.dayPickerKeyboardNav = true;\n this.moveDays(this.getNextDayToFocus(this.focussedDate, true));\n break;\n\n case \"PageUp\":\n this.dayPickerKeyboardNav = true;\n ev.shiftKey ? this.moveYears(-1) : this.moveMonths(-1);\n break;\n\n case \"PageDown\":\n this.dayPickerKeyboardNav = true;\n ev.shiftKey ? this.moveYears(1) : this.moveMonths(1);\n break;\n\n case \"Home\":\n this.dayPickerKeyboardNav = true;\n this.setFocussedDate(\n new Date(this.focussedYear, this.focussedMonth, 1)\n );\n break;\n\n case \"End\":\n this.dayPickerKeyboardNav = true;\n this.setFocussedDate(\n new Date(this.focussedYear, this.focussedMonth + 1, 0)\n );\n break;\n\n case \"Tab\":\n handled = this.calendarTabHandler(ev);\n break;\n\n default:\n handled = false;\n break;\n }\n\n if (handled) {\n ev.preventDefault();\n }\n };\n\n private calendarTabHandler = (ev: KeyboardEvent): boolean => {\n let handled = false;\n if (\n !ev.shiftKey &&\n (!this.showPickerTodayButton || this.isCurrentMonth()) &&\n (!this.showPickerClearButton || this.clearButtonEl.disabled)\n ) {\n this.focusFirstElement();\n handled = true;\n } else if (ev.shiftKey) {\n this.yearButtonEl.setFocus();\n handled = true;\n }\n return handled;\n };\n\n private onDayButtonFocusHandler = () => {\n this.dayButtonFocussed = true;\n };\n\n private onDayButtonBlurHandler = () => {\n this.dayButtonFocussed = false;\n };\n\n private getNextDayToFocus = (\n currDay: Date,\n forward: boolean,\n level = 1\n ): number => {\n const move = forward ? 1 : -1;\n const nextDay = new Date(currDay);\n nextDay.setDate(nextDay.getDate() + move);\n const nextDayNum = Number(nextDay.getDay());\n if (this.disableDays.includes(nextDayNum)) {\n return this.getNextDayToFocus(nextDay, forward, level + 1);\n } else {\n return level;\n }\n };\n\n private moveDays = (numDays: number): void => {\n const d = new Date(this.focussedDate);\n d.setDate(d.getDate() + numDays);\n this.setFocussedDate(d);\n };\n\n private moveMonths = (numMonths: number): void => {\n const newMonth = this.focussedDate.getMonth() + numMonths;\n const min = new Date(\n new Date(getMonthStart(this.focussedDate)).setMonth(newMonth)\n );\n const max = getMonthEnd(min);\n const newDate = new Date(new Date(this.focussedDate).setMonth(newMonth));\n this.setFocussedDate(clampDate(newDate, min, max));\n\n if (\n this.monthPickerVisible === false &&\n this.yearPickerVisible === false &&\n this.monthInViewUpdateHandled === false\n ) {\n this.setAriaLiveRegionText(this.getMonthInViewText());\n }\n this.monthInViewUpdateHandled = false;\n };\n\n private moveYears = (numYears: number): void => {\n const newYear = this.focussedDate.getFullYear() + numYears;\n const min = new Date(\n new Date(getMonthStart(this.focussedDate)).setFullYear(newYear)\n );\n const max = getMonthEnd(min);\n const newDate = new Date(new Date(this.focussedDate).setFullYear(newYear));\n this.setFocussedDate(clampDate(newDate, min, max));\n\n if (\n this.monthPickerVisible === false &&\n this.yearPickerVisible === false &&\n this.monthInViewUpdateHandled === false\n ) {\n this.setAriaLiveRegionText(this.getMonthInViewText());\n }\n this.monthInViewUpdateHandled = false;\n };\n\n private updateFocussedMonth = (adjust: number): void => {\n const d = new Date(this.focussedYear, this.focussedMonth, 1);\n d.setMonth(this.focussedMonth + adjust);\n const newDate = clampDate(d, this.minDate, this.maxDate);\n this.focussedMonth = newDate.getMonth();\n setTimeout(() => this.focussedMonthEl.setFocus(), FOCUS_TIMER);\n };\n\n private updateFocussedYear = (adjust: number, focusYear = true): void => {\n const d = new Date(new Date().setFullYear(this.focussedYear + adjust));\n const newDate = clampDate(d, this.minDate, this.maxDate);\n this.setFocussedYear(newDate.getFullYear(), focusYear);\n };\n\n private setFocussedDate = (d: Date): void => {\n this.focussedDate = clampDate(d, this.minDate, this.maxDate);\n };\n\n private setFocussedDayEl = (element: HTMLButtonElement) => {\n this.focussedDayEl = element;\n };\n\n private setFocussedMonthEl = (element: HTMLIcButtonElement) => {\n this.focussedMonthEl = element;\n };\n\n private setFocussedYearEl = (element: HTMLIcButtonElement) => {\n this.focussedYearEl = element;\n };\n\n private setFocussedYear = (newYear: number, focus = true): void => {\n const prevYear = this.focussedYear;\n this.focussedYear = newYear;\n if (this.yearPickerVisible) {\n const newDecade = Math.floor(newYear / 10) * 10;\n const oldDecade = Math.floor(prevYear / 10) * 10;\n if (newDecade !== oldDecade) {\n this.setDecadeView(newDecade);\n this.setAriaLiveRegionText(this.getDecadeInViewText());\n }\n if (focus) {\n setTimeout(() => {\n if (this.focussedYearEl !== null) this.focussedYearEl.setFocus();\n }, FOCUS_TIMER);\n }\n } else {\n this.setDecadeView(Math.floor(newYear / 10) * 10);\n }\n };\n\n private setDateInputProps = (): IcDateInputProps => {\n const inputProps: IcDateInputProps = {\n hideLabel: this.hideLabel,\n invalidDateMessage: this.invalidDateMessage,\n label: this.label,\n showClearButton: true,\n showCalendarButton: true,\n value: this.value,\n };\n\n if (this.dateFormat !== DEFAULT_DATE_FORMAT) {\n inputProps.dateFormat = this.dateFormat;\n }\n if (this.disableFuture) {\n inputProps.disableFuture = this.disableFuture;\n if (this.disableFutureMessage !== DEFAULT_DISABLE_DATES_FROM_NOW_MSG) {\n inputProps.disableFutureMessage = this.disableFutureMessage;\n }\n }\n if (this.disablePast) {\n inputProps.disablePast = this.disablePast;\n if (this.disablePastMessage !== DEFAULT_DISABLE_DATES_UNTIL_NOW_MSG) {\n inputProps.disablePastMessage = this.disablePastMessage;\n }\n }\n if (this.disableDays.length > 0) {\n inputProps.disableDays = this.disableDays;\n if (this.disableDaysMessage !== DEFAULT_DISABLE_DAYS_MSG) {\n inputProps.disableDaysMessage = this.disableDaysMessage;\n }\n }\n if (this.max !== null && this.max !== \"\") {\n inputProps.max = this.maxDate;\n }\n if (this.min !== null && this.min !== \"\") {\n inputProps.min = this.minDate;\n }\n if (this.helperText !== undefined) {\n inputProps.helperText = this.helperText;\n }\n if (this.hideHelperText !== false) {\n inputProps.hideHelperText = this.hideHelperText;\n }\n if (this.inputId !== undefined) {\n inputProps.inputId = this.inputId;\n }\n if (this.name !== undefined) {\n inputProps.name = this.name;\n }\n if (this.disabled) {\n inputProps.disabled = this.disabled;\n }\n if (this.required) {\n inputProps.required = this.required;\n }\n if (this.size !== \"default\") {\n inputProps.size = this.size;\n }\n if (this.validationStatus !== \"\") {\n inputProps.validationStatus = this.validationStatus;\n }\n if (this.validationText !== \"\") {\n inputProps.validationText = this.validationText;\n }\n return inputProps;\n };\n\n private renderHiddenInput = () =>\n !this.showDateInput ? (\n <span id={this.selectedDateInfoId} class=\"sr-only\" aria-live=\"polite\">\n <span ref={(el) => (this.selectedDateInfoEl = el)} role=\"status\"></span>\n </span>\n ) : (\n \"\"\n );\n\n private renderCalendar = () => {\n const {\n monthNames,\n size,\n focussedMonth,\n focussedYear,\n monthInView,\n yearInView,\n monthPickerVisible,\n yearPickerVisible,\n orderedDaysOfWeek,\n decadeView,\n minDate,\n maxDate,\n showPickerClearButton,\n showPickerTodayButton,\n dialogDescription,\n } = this;\n\n let monthButtonText = \"\";\n if (monthPickerVisible) {\n monthButtonText = `Use the arrow keys to change the selected month. To return to day picker view, press Enter or Space to select a month, or press Escape.`;\n } else {\n monthButtonText = `Press Enter or Space to open month picker view or use the arrow keys to change month.`;\n }\n\n let yearButtonText = \"\";\n if (yearPickerVisible) {\n yearButtonText = `Use the arrow keys to change the selected year. To return to day picker view, press Enter or Space to select a year, or press Escape.`;\n } else {\n yearButtonText = `Press Enter or Space to open year picker view or use the arrow keys to change the selected year.`;\n }\n\n const dialogLabel = \"choose date\";\n\n const monthLabel =\n monthNames && monthNames[monthInView]\n ? monthNames[monthInView]\n : \"Open month picker\";\n const yearLabel = this.yearInView ? this.yearInView : \"Open year picker\";\n\n let minDay = minDate;\n if (this.disablePast) {\n const yesterday = new Date(minDate);\n yesterday.setDate(minDate.getDate() - 1);\n minDay = yesterday;\n }\n\n return (\n <div>\n <span id=\"dialog-description\" class=\"sr-only\">\n {dialogDescription}\n </span>\n <div\n role=\"dialog\"\n aria-modal=\"true\"\n aria-label={dialogLabel}\n aria-describedBy=\"dialog-description\"\n class={{\n \"calendar-container\": true,\n \"show-date-input\": this.showDateInput,\n \"hide-date-input\": !this.showDateInput,\n above: this.showPickerAbove,\n }}\n onMouseDown={this.handleCalendarMouseDown}\n onClick={this.handleCalendarClick}\n >\n <span\n ref={(el) => (this.liveRegionEl = el)}\n id=\"live-region\"\n aria-live=\"assertive\"\n class=\"sr-only\"\n ></span>\n <div\n class={{\n \"month-year-nav-container\": true,\n }}\n >\n <div class=\"month-year-nav\">\n {this.previousMonthButton()}\n <span id=\"select-month-hint\" aria-hidden=\"true\">\n {monthButtonText}\n </span>\n <ic-button\n ref={(el: HTMLIcButtonElement) => (this.monthButtonEl = el)}\n size={size}\n class=\"month-picker-button\"\n aria-haspopup=\"menu\"\n aria-expanded={monthPickerVisible ? \"true\" : \"false\"}\n full-width=\"true\"\n variant=\"tertiary\"\n aria-label={monthLabel}\n aria-describedby=\"select-month-hint\"\n onKeyDown={this.monthButtonKeyDownHandler}\n onClick={this.monthButtonClickHandler}\n >\n {monthNames[monthInView]}\n </ic-button>\n {this.nextMonthButton()}\n </div>\n <div class=\"month-year-nav\">\n {this.previousYearButton()}\n <span id=\"select-year-hint\" aria-hidden=\"true\">\n {yearButtonText}\n </span>\n <ic-button\n ref={(el: HTMLIcButtonElement) => (this.yearButtonEl = el)}\n size={size}\n class=\"year-picker-button\"\n aria-haspopup=\"menu\"\n aria-expanded={yearPickerVisible ? \"true\" : \"false\"}\n full-width=\"true\"\n variant=\"tertiary\"\n aria-label={yearLabel}\n aria-describedby=\"select-year-hint\"\n onKeyDown={this.yearButtonKeyDownHandler}\n onClick={this.yearButtonClickHandler}\n >\n {this.yearInView}\n </ic-button>\n {this.nextYearButton()}\n </div>\n </div>\n {!(monthPickerVisible || yearPickerVisible) && (\n <div\n class={{\n calendar: true,\n hidden: monthPickerVisible || yearPickerVisible,\n }}\n onKeyDown={this.handleCalendarKeyDown}\n >\n <div class=\"weekdays\" aria-hidden=\"true\">\n {orderedDaysOfWeek.map((dayName) => {\n const header = size === \"small\" ? dayName.charAt(0) : dayName;\n return (\n <div class=\"calendar-day-header\">\n <ic-typography variant=\"caption\">{header}</ic-typography>\n </div>\n );\n })}\n </div>\n\n <div class=\"calendar-days-container\">\n {this.currMonthView.map((day) => (\n <DayButton\n day={day}\n disableDay={this.disableDays.includes(Number(day.getDay()))}\n today={dateMatches(day, this.today)}\n selected={dateMatches(day, this.selectedDate)}\n focussed={dateMatches(day, this.focussedDate)}\n inRange={dateInRange(day, minDay, maxDate)}\n monthInView={monthInView}\n onSelectDay={this.handleSelectDay}\n focussedDayRef={this.setFocussedDayEl}\n onFocusDay={this.onDayButtonFocusHandler}\n onBlurDay={this.onDayButtonBlurHandler}\n showDaysOutsideMonth={this.showDaysOutsideMonth}\n ></DayButton>\n ))}\n </div>\n </div>\n )}\n <div\n class={{\n \"month-picker-container\": true,\n hidden: !monthPickerVisible,\n }}\n >\n {monthPickerVisible && (\n <MonthPicker\n size={size}\n onSelectMonth={this.handleSelectMonth}\n monthInView={monthInView}\n focussedMonth={focussedMonth}\n onKeyDown={this.monthPickerKeyDownHandler}\n focussedMonthRef={this.setFocussedMonthEl}\n minDate={minDate}\n maxDate={maxDate}\n yearInView={yearInView}\n ></MonthPicker>\n )}\n </div>\n <div\n class={{\n \"year-picker-container\": true,\n hidden: !yearPickerVisible,\n }}\n >\n {yearPickerVisible && (\n <YearPicker\n decadeView={decadeView}\n size={size}\n focussedYear={focussedYear}\n onSelectYear={this.handleSelectYear}\n onKeyDown={this.yearPickerKeyDownHandler}\n onFocusYear={this.onYearButtonFocusHandler}\n onBlurYear={this.onYearButtonBlurHandler}\n yearInView={yearInView}\n minDate={minDate}\n maxDate={maxDate}\n focussedYearRef={this.setFocussedYearEl}\n ></YearPicker>\n )}\n </div>\n <div\n class={{\n \"bottom-buttons\": true,\n \"no-today\": !showPickerTodayButton,\n }}\n >\n {showPickerTodayButton && (\n <ic-button\n id=\"today-button\"\n variant=\"tertiary\"\n ref={(el: HTMLIcButtonElement) => (this.todayButtonEl = el)}\n size={size}\n aria-label=\"Navigate to current date\"\n onClick={this.todayButtonClickHandler}\n onKeyDown={this.todayButtonKeyDownHandler}\n disabled={this.isCurrentMonth()}\n >\n Go to today\n </ic-button>\n )}\n {showPickerClearButton && (\n <ic-button\n id=\"clear-button\"\n aria-label=\"clear selected date\"\n ref={(el: HTMLIcButtonElement) => (this.clearButtonEl = el)}\n variant=\"tertiary\"\n size={size}\n onClick={this.clearButtonClickHandler}\n onKeyDown={this.clearButtonKeyDownHandler}\n disabled={\n this.value === \"\" ||\n this.value === null ||\n this.value === undefined\n }\n >\n Clear\n </ic-button>\n )}\n </div>\n </div>\n\n {this.renderHiddenInput()}\n </div>\n );\n };\n\n render() {\n const {\n calendarOpen,\n dateInputProps,\n keyDownHandler,\n renderCalendar,\n showDateInput,\n size,\n } = this;\n\n return (\n <Host onKeyDown={keyDownHandler} class={size}>\n {showDateInput && (\n <div class=\"date-input-container\">\n <ic-date-input\n ref={(el) => (this.inputEl = el)}\n {...dateInputProps}\n ></ic-date-input>\n </div>\n )}\n\n {calendarOpen && renderCalendar()}\n </Host>\n );\n }\n}\n"]}
|
@@ -0,0 +1,167 @@
|
|
1
|
+
/* eslint-disable @typescript-eslint/explicit-module-boundary-types */
|
2
|
+
import readme from "./readme.md";
|
3
|
+
import { DateFormats, Default, Disabled, DisableFuture, DisablePast, HideButtons, HideOutsideMonth, IcChangeDate, IcSelectedDateChange, JSDates, MaxMin, MaxWidth, OpenAt, Sizes, Value, ValueCalendarOnlyMode, WeekStart, WorkingWeek, } from "./story-data";
|
4
|
+
export default {
|
5
|
+
title: "Web Components/Date Picker",
|
6
|
+
component: "Date Picker",
|
7
|
+
parameters: {
|
8
|
+
componentAPI: {
|
9
|
+
data: readme,
|
10
|
+
},
|
11
|
+
},
|
12
|
+
};
|
13
|
+
/**
|
14
|
+
* Use a date picker to select a single date where visualising that date could be useful.
|
15
|
+
* There is one required prop for a date picker:
|
16
|
+
* - label: `string`
|
17
|
+
*
|
18
|
+
* Click the 'Component API' tab to view all the available props and events for date pickers.
|
19
|
+
*
|
20
|
+
* To use the date picker component, import `@ukic/canary-web-components` into your application.
|
21
|
+
*/
|
22
|
+
export const DefaultExample = {
|
23
|
+
render: () => Default(),
|
24
|
+
name: "Default",
|
25
|
+
height: "540px",
|
26
|
+
};
|
27
|
+
/**
|
28
|
+
* Set the size of the date picker by using the `size` prop. This prop takes the values `small`, `default` or `large`. Depending on the chosen size, the prop will apply styling to increase or decrease the amount of spacing within the component.
|
29
|
+
*/
|
30
|
+
export const SizesExample = {
|
31
|
+
render: () => Sizes(),
|
32
|
+
name: "Sizes",
|
33
|
+
height: "790px",
|
34
|
+
};
|
35
|
+
/**
|
36
|
+
* Set the size of the input field by using the `--input-width` CSS custom property. The picker will grow, but not exceed its maximum supported width.
|
37
|
+
*/
|
38
|
+
export const MaxWidthExample = {
|
39
|
+
render: () => MaxWidth(),
|
40
|
+
name: "Max width",
|
41
|
+
height: "790px",
|
42
|
+
};
|
43
|
+
/**
|
44
|
+
* Disable the date picker and prevent user interaction by using the `disabled` prop.
|
45
|
+
*/
|
46
|
+
export const DisabledExample = {
|
47
|
+
render: () => Disabled(),
|
48
|
+
name: "Disabled",
|
49
|
+
height: "100px",
|
50
|
+
};
|
51
|
+
/**
|
52
|
+
* The `date-format` prop determines how dates are displayed. The supported formats are:
|
53
|
+
* - `DD/MM/YYYY` (Default)
|
54
|
+
* - `MM/DD/YYYY`
|
55
|
+
* - `YYYY/MM/DD`
|
56
|
+
*/
|
57
|
+
export const DateFormatsExample = {
|
58
|
+
render: () => DateFormats(),
|
59
|
+
name: "Date formats",
|
60
|
+
height: "750px",
|
61
|
+
};
|
62
|
+
/**
|
63
|
+
* The `value` prop sets the date in the input field. The value can be in any format supported by the `date-format` prop, in ISO 8601 date string format (yyyy-mm-dd) or as a JavaScript Date object.
|
64
|
+
*/
|
65
|
+
export const ValueExample = {
|
66
|
+
render: () => Value(),
|
67
|
+
name: "Value",
|
68
|
+
height: "540px",
|
69
|
+
};
|
70
|
+
/**
|
71
|
+
* The `value` prop sets the date in the input field. The value can be in any format supported by the `date-format` prop, in ISO 8601 date string format (yyyy-mm-dd) or as a JavaScript Date object.
|
72
|
+
*/
|
73
|
+
export const ValueCalendarOnlyModeExample = {
|
74
|
+
render: () => ValueCalendarOnlyMode(),
|
75
|
+
name: "Value in calendar only mode",
|
76
|
+
height: "540px",
|
77
|
+
};
|
78
|
+
/**
|
79
|
+
* If no `value` is set, the `open-at-date` prop can be used to specify the date in view when the calendar view is opened. If not set to a value, the calendar will default to showing the current date.
|
80
|
+
* The supported formats are the same as for the `value` prop.
|
81
|
+
*/
|
82
|
+
export const OpenAtDate = {
|
83
|
+
render: () => OpenAt(),
|
84
|
+
name: "Open at date",
|
85
|
+
height: "540px",
|
86
|
+
};
|
87
|
+
/**
|
88
|
+
* The first day of the week can be changed by setting the `start-of-week` prop. This is a numeric value where 0 = Sunday, 1 = Monday, etc up to 6 = Saturday.
|
89
|
+
*/
|
90
|
+
export const StartOfWeek = {
|
91
|
+
render: () => WeekStart(),
|
92
|
+
name: "Start of week",
|
93
|
+
height: "540px",
|
94
|
+
};
|
95
|
+
/**
|
96
|
+
* Specific days of the week can be disabled from selection by setting the `disableDays` prop. The value can be set as an array of numeric values where where 0 = Sunday, 1 = Monday, etc up to 6 = Saturday.
|
97
|
+
*/
|
98
|
+
export const DisableDaysOfWeek = {
|
99
|
+
render: () => WorkingWeek(),
|
100
|
+
name: "Disable days of week",
|
101
|
+
height: "540px",
|
102
|
+
};
|
103
|
+
/**
|
104
|
+
* The `max` and `min` props can be used to limit the range of dates available for selection. Values can be in any format supported by the `date-format` prop, in ISO 8601 date string format (yyyy-mm-dd) or as a JavaScript Date object.
|
105
|
+
*/
|
106
|
+
export const MaxMinExample = {
|
107
|
+
render: () => MaxMin(),
|
108
|
+
name: "Max & Min",
|
109
|
+
height: "500px",
|
110
|
+
};
|
111
|
+
/**
|
112
|
+
* Dates before today can be disabled with the `disable-past` prop.
|
113
|
+
*/
|
114
|
+
export const DisableDatesInPast = {
|
115
|
+
render: () => DisablePast(),
|
116
|
+
name: "Disable dates in past",
|
117
|
+
height: "540px",
|
118
|
+
};
|
119
|
+
/**
|
120
|
+
* Dates after today can be disabled with the `disable-future` prop.
|
121
|
+
*/
|
122
|
+
export const DisableDatesInFuture = {
|
123
|
+
render: () => DisableFuture(),
|
124
|
+
name: "Disable dates in future",
|
125
|
+
height: "540px",
|
126
|
+
};
|
127
|
+
/**
|
128
|
+
* Days outside of the current month in view can be hidden by setting the `show-days-outside-month` prop to `false`.
|
129
|
+
*/
|
130
|
+
export const DaysOutsideMonthHidden = {
|
131
|
+
render: () => HideOutsideMonth(),
|
132
|
+
name: "Days outside month hidden",
|
133
|
+
height: "540px",
|
134
|
+
};
|
135
|
+
/**
|
136
|
+
* The "Go to today" and "Clear" buttons can be hidden from the calendar view by setting the `show-picker-today-button` and `show-picker-clear-button` props to `false`.
|
137
|
+
*/
|
138
|
+
export const TodayClearButtonsHidden = {
|
139
|
+
render: () => HideButtons(),
|
140
|
+
name: "Today & clear buttons hidden",
|
141
|
+
height: "480px",
|
142
|
+
};
|
143
|
+
/**
|
144
|
+
* Any prop that accepts a date value can be set to a Javascript Date object. The following example sets the `value`, `max` and `min` props.
|
145
|
+
*/
|
146
|
+
export const JavaScriptDates = {
|
147
|
+
render: () => JSDates(),
|
148
|
+
name: "JavaScript dates",
|
149
|
+
height: "500px",
|
150
|
+
};
|
151
|
+
/**
|
152
|
+
* The `IcChange` event is emitted by the date picker when the selected date changes.
|
153
|
+
*/
|
154
|
+
export const IcChangeEvent = {
|
155
|
+
render: () => IcChangeDate(),
|
156
|
+
name: "IcChange event",
|
157
|
+
height: "540px",
|
158
|
+
};
|
159
|
+
/**
|
160
|
+
* The date input can be hidden from the component by setting the deprecated `showDateInput` prop to `false`, thereby putting the component into "calendar only" mode. The `IcSelectedDateChange` event is emitted by the date picker when the selected date changes.
|
161
|
+
*/
|
162
|
+
export const IcSelectedDateChangeEvent = {
|
163
|
+
render: () => IcSelectedDateChange(),
|
164
|
+
name: "IcSelectedDateChange event",
|
165
|
+
height: "540px",
|
166
|
+
};
|
167
|
+
//# sourceMappingURL=ic-date-picker.stories.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"ic-date-picker.stories.js","sourceRoot":"","sources":["../../../src/components/ic-date-picker/ic-date-picker.stories.js"],"names":[],"mappings":"AAAA,sEAAsE;AACtE,OAAO,MAAM,MAAM,aAAa,CAAC;AACjC,OAAO,EACL,WAAW,EACX,OAAO,EACP,QAAQ,EACR,aAAa,EACb,WAAW,EACX,WAAW,EACX,gBAAgB,EAChB,YAAY,EACZ,oBAAoB,EACpB,OAAO,EACP,MAAM,EACN,QAAQ,EACR,MAAM,EACN,KAAK,EACL,KAAK,EACL,qBAAqB,EACrB,SAAS,EACT,WAAW,GACZ,MAAM,cAAc,CAAC;AAEtB,eAAe;IACb,KAAK,EAAE,4BAA4B;IACnC,SAAS,EAAE,aAAa;IAExB,UAAU,EAAE;QACV,YAAY,EAAE;YACZ,IAAI,EAAE,MAAM;SACb;KACF;CACF,CAAC;AAEF;;;;;;;;GAQG;AACH,MAAM,CAA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AAO,EAAE;IACvB,IAAI,EAAE,kBAAkB;IACxB,MAAM,EAAE,OAAO;CAChB,CAAC;AAEF;;GAEG;AACH,MAAM,CAAC,MAAM,aAAa,GAAG;IAC3B,MAAM,EAAE,GAAG,EAAE,CAAC,YAAY,EAAE;IAC5B,IAAI,EAAE,gBAAgB;IACtB,MAAM,EAAE,OAAO;CAChB,CAAC;AAEF;;GAEG;AACH,MAAM,CAAC,MAAM,yBAAyB,GAAG;IACvC,MAAM,EAAE,GAAG,EAAE,CAAC,oBAAoB,EAAE;IACpC,IAAI,EAAE,4BAA4B;IAClC,MAAM,EAAE,OAAO;CAChB,CAAC","sourcesContent":["/* eslint-disable @typescript-eslint/explicit-module-boundary-types */\nimport readme from \"./readme.md\";\nimport {\n DateFormats,\n Default,\n Disabled,\n DisableFuture,\n DisablePast,\n HideButtons,\n HideOutsideMonth,\n IcChangeDate,\n IcSelectedDateChange,\n JSDates,\n MaxMin,\n MaxWidth,\n OpenAt,\n Sizes,\n Value,\n ValueCalendarOnlyMode,\n WeekStart,\n WorkingWeek,\n} from \"./story-data\";\n\nexport default {\n title: \"Web Components/Date Picker\",\n component: \"Date Picker\",\n\n parameters: {\n componentAPI: {\n data: readme,\n },\n },\n};\n\n/**\n * Use a date picker to select a single date where visualising that date could be useful.\n * There is one required prop for a date picker:\n * - label: `string`\n *\n * Click the 'Component API' tab to view all the available props and events for date pickers.\n *\n * To use the date picker component, import `@ukic/canary-web-components` into your application.\n */\nexport const DefaultExample = {\n render: () => Default(),\n name: \"Default\",\n height: \"540px\",\n};\n\n/**\n * Set the size of the date picker by using the `size` prop. This prop takes the values `small`, `default` or `large`. Depending on the chosen size, the prop will apply styling to increase or decrease the amount of spacing within the component.\n */\nexport const SizesExample = {\n render: () => Sizes(),\n name: \"Sizes\",\n height: \"790px\",\n};\n\n/**\n * Set the size of the input field by using the `--input-width` CSS custom property. The picker will grow, but not exceed its maximum supported width.\n */\nexport const MaxWidthExample = {\n render: () => MaxWidth(),\n name: \"Max width\",\n height: \"790px\",\n};\n\n/**\n * Disable the date picker and prevent user interaction by using the `disabled` prop.\n */\nexport const DisabledExample = {\n render: () => Disabled(),\n name: \"Disabled\",\n height: \"100px\",\n};\n\n/**\n * The `date-format` prop determines how dates are displayed. The supported formats are:\n * - `DD/MM/YYYY` (Default)\n * - `MM/DD/YYYY`\n * - `YYYY/MM/DD`\n */\nexport const DateFormatsExample = {\n render: () => DateFormats(),\n name: \"Date formats\",\n height: \"750px\",\n};\n\n/**\n * The `value` prop sets the date in the input field. The value can be in any format supported by the `date-format` prop, in ISO 8601 date string format (yyyy-mm-dd) or as a JavaScript Date object.\n */\nexport const ValueExample = {\n render: () => Value(),\n name: \"Value\",\n height: \"540px\",\n};\n\n/**\n * The `value` prop sets the date in the input field. The value can be in any format supported by the `date-format` prop, in ISO 8601 date string format (yyyy-mm-dd) or as a JavaScript Date object.\n */\nexport const ValueCalendarOnlyModeExample = {\n render: () => ValueCalendarOnlyMode(),\n name: \"Value in calendar only mode\",\n height: \"540px\",\n};\n\n/**\n * If no `value` is set, the `open-at-date` prop can be used to specify the date in view when the calendar view is opened. If not set to a value, the calendar will default to showing the current date.\n * The supported formats are the same as for the `value` prop.\n */\nexport const OpenAtDate = {\n render: () => OpenAt(),\n name: \"Open at date\",\n height: \"540px\",\n};\n\n/**\n * The first day of the week can be changed by setting the `start-of-week` prop. This is a numeric value where 0 = Sunday, 1 = Monday, etc up to 6 = Saturday.\n */\nexport const StartOfWeek = {\n render: () => WeekStart(),\n name: \"Start of week\",\n height: \"540px\",\n};\n\n/**\n * Specific days of the week can be disabled from selection by setting the `disableDays` prop. The value can be set as an array of numeric values where where 0 = Sunday, 1 = Monday, etc up to 6 = Saturday.\n */\nexport const DisableDaysOfWeek = {\n render: () => WorkingWeek(),\n name: \"Disable days of week\",\n height: \"540px\",\n};\n\n/**\n * The `max` and `min` props can be used to limit the range of dates available for selection. Values can be in any format supported by the `date-format` prop, in ISO 8601 date string format (yyyy-mm-dd) or as a JavaScript Date object.\n */\nexport const MaxMinExample = {\n render: () => MaxMin(),\n name: \"Max & Min\",\n height: \"500px\",\n};\n\n/**\n * Dates before today can be disabled with the `disable-past` prop.\n */\nexport const DisableDatesInPast = {\n render: () => DisablePast(),\n name: \"Disable dates in past\",\n height: \"540px\",\n};\n\n/**\n * Dates after today can be disabled with the `disable-future` prop.\n */\nexport const DisableDatesInFuture = {\n render: () => DisableFuture(),\n name: \"Disable dates in future\",\n height: \"540px\",\n};\n\n/**\n * Days outside of the current month in view can be hidden by setting the `show-days-outside-month` prop to `false`.\n */\nexport const DaysOutsideMonthHidden = {\n render: () => HideOutsideMonth(),\n name: \"Days outside month hidden\",\n height: \"540px\",\n};\n\n/**\n * The \"Go to today\" and \"Clear\" buttons can be hidden from the calendar view by setting the `show-picker-today-button` and `show-picker-clear-button` props to `false`.\n */\nexport const TodayClearButtonsHidden = {\n render: () => HideButtons(),\n name: \"Today & clear buttons hidden\",\n height: \"480px\",\n};\n\n/**\n * Any prop that accepts a date value can be set to a Javascript Date object. The following example sets the `value`, `max` and `min` props.\n */\nexport const JavaScriptDates = {\n render: () => JSDates(),\n name: \"JavaScript dates\",\n height: \"500px\",\n};\n\n/**\n * The `IcChange` event is emitted by the date picker when the selected date changes.\n */\nexport const IcChangeEvent = {\n render: () => IcChangeDate(),\n name: \"IcChange event\",\n height: \"540px\",\n};\n\n/**\n * The date input can be hidden from the component by setting the deprecated `showDateInput` prop to `false`, thereby putting the component into \"calendar only\" mode. The `IcSelectedDateChange` event is emitted by the date picker when the selected date changes.\n */\nexport const IcSelectedDateChangeEvent = {\n render: () => IcSelectedDateChange(),\n name: \"IcSelectedDateChange event\",\n height: \"540px\",\n};\n"]}
|