@esri/calcite-components
Version:
Web Components for Esri's Calcite Design System.
6 lines • 43 kB
JavaScript
/*!
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
* See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.
* v1.5.0-next.4
*/
import{r as t,c as e,h as a,H as i,a as r,F as n}from"./p-8789682d.js";import{h as o,b as s,c,g as l,f as h,e as d,s as u,j as g,i as p,k as f,n as m,p as v,l as y,m as w}from"./p-074f85c7.js";import{c as x,s as b,a as k}from"./p-deebcc06.js";import{c as D,d as _,n as z,b as C}from"./p-743ed09c.js";import{c as A,d as I,s as S,u as j}from"./p-9dd9a26d.js";import{c as M,b as P,t as H}from"./p-68f223ec.js";import{c as O,u as R,d as L}from"./p-0d8324b6.js";import{i as W}from"./p-4929e834.js";import{C as Y}from"./p-9280476e.js";import{H as E}from"./p-36712ef1.js";import"./p-c8e46b02.js";import"./p-d2aa9245.js";import"./p-7fb6664e.js";const N={dateStyle:"full"},F=class{constructor(a){t(this,a),this.calciteDatePickerChange=e(this,"calciteDatePickerChange",6),this.calciteDatePickerRangeChange=e(this,"calciteDatePickerRangeChange",6),this.keyDownHandler=t=>{"Escape"===t.key&&this.reset()},this.monthHeaderSelectChange=t=>{const e=new Date(t.detail);this.range?("end"===this.activeRange?this.activeEndDate=e:this.activeStartDate=e,this.mostRecentRangeValue=e):this.activeDate=e},this.monthActiveDateChange=t=>{const e=new Date(t.detail);this.range?("end"===this.activeRange?this.activeEndDate=e:this.activeStartDate=e,this.mostRecentRangeValue=e):this.activeDate=e},this.monthHoverChange=t=>{if(!this.range)return void(this.hoverRange=void 0);const{valueAsDate:e}=this,a=Array.isArray(e)&&e[0],i=Array.isArray(e)&&e[1],r=new Date(t.detail);if(this.hoverRange={focused:this.activeRange||"start",start:a,end:i},this.proximitySelectionDisabled)i?this.hoverRange=void 0:r<a?this.hoverRange={focused:"start",start:r,end:a}:(this.hoverRange.end=r,this.hoverRange.focused="end");else if(i){const t=o(r,a),e=o(r,i);e>0?(this.hoverRange.end=r,this.hoverRange.focused="end"):t<0||t>e?(this.hoverRange.start=r,this.hoverRange.focused="start"):(this.hoverRange.end=r,this.hoverRange.focused="end")}else a&&(r<a?this.hoverRange={focused:"start",start:r,end:a}:(this.hoverRange.end=r,this.hoverRange.focused="end"));t.stopPropagation()},this.monthMouseOutChange=()=>{this.hoverRange&&(this.hoverRange=void 0)},this.reset=()=>{const{valueAsDate:t}=this;!Array.isArray(t)&&t&&t?.getTime()!==this.activeDate?.getTime()&&(this.activeDate=new Date(t)),Array.isArray(t)&&(t[0]&&t[0]?.getTime()!==(this.activeStartDate instanceof Date&&this.activeStartDate?.getTime())&&(this.activeStartDate=new Date(t[0])),t[1]&&t[1]?.getTime()!==(this.activeStartDate instanceof Date&&this.activeEndDate?.getTime())&&(this.activeEndDate=new Date(t[1])))},this.monthDateChange=t=>{const e=new Date(t.detail),a=s(e);if(!this.range&&a===s(this.valueAsDate))return;if(!this.range)return this.value=a||"",this.valueAsDate=e||null,this.activeDate=e||null,void this.calciteDatePickerChange.emit();const i=this.getStartDate(),r=this.getEndDate();if(!i||!r&&e<i)i&&this.setEndDate(new Date(i)),"end"==this.activeRange?this.setEndDate(e):this.setStartDate(e);else if(r)if(this.proximitySelectionDisabled)this.setStartDate(e);else if(this.activeRange)"end"==this.activeRange?this.setEndDate(e):this.setStartDate(e);else{const t=o(e,i),a=o(e,r);0===a||t<0?this.setStartDate(e):0===t||a<0?this.setEndDate(e):t<a?this.setStartDate(e):this.setEndDate(e)}else this.setEndDate(e);this.calciteDatePickerChange.emit()},this.activeDate=void 0,this.activeRange=void 0,this.value=void 0,this.headingLevel=void 0,this.valueAsDate=void 0,this.minAsDate=void 0,this.maxAsDate=void 0,this.min=void 0,this.max=void 0,this.numberingSystem=void 0,this.scale="m",this.range=!1,this.proximitySelectionDisabled=!1,this.messageOverrides=void 0,this.messages=void 0,this.activeEndDate=void 0,this.activeStartDate=void 0,this.dateTimeFormat=void 0,this.defaultMessages=void 0,this.effectiveLocale="",this.endAsDate=void 0,this.hoverRange=void 0,this.localeData=void 0,this.startAsDate=void 0}activeDateWatcher(t){"end"===this.activeRange&&(this.activeEndDate=t)}valueAsDateWatcher(t){if(this.range&&Array.isArray(t)){const{activeStartDate:e,activeEndDate:a}=this,i=t[0],r=t[1];this.activeStartDate=e!==i&&i,this.activeEndDate=a!==r&&r}else t&&t!==this.activeDate&&(this.activeDate=t)}onMinChanged(t){t&&(this.minAsDate=c(t))}onMaxChanged(t){t&&(this.maxAsDate=c(t))}onMessagesChange(){}async setFocus(){await x(this),this.el.focus()}connectedCallback(){D(this),A(this),Array.isArray(this.value)?this.valueAsDate=l(this.value):this.value&&(this.valueAsDate=c(this.value)),this.min&&(this.minAsDate=c(this.min)),this.max&&(this.maxAsDate=c(this.max))}disconnectedCallback(){_(this),I(this)}async componentWillLoad(){b(this),await this.loadLocaleData(),this.onMinChanged(this.min),this.onMaxChanged(this.max),await S(this)}componentDidLoad(){k(this)}render(){const t=h(this.range&&Array.isArray(this.valueAsDate)?this.valueAsDate[0]:this.valueAsDate,this.minAsDate,this.maxAsDate);let e=this.getActiveDate(t,this.minAsDate,this.maxAsDate);const r=this.range&&Array.isArray(this.valueAsDate)?h(this.valueAsDate[1],this.minAsDate,this.maxAsDate):null,n=this.getActiveEndDate(r,this.minAsDate,this.maxAsDate);return"end"!==this.activeRange&&("end"!==this.hoverRange?.focused||this.proximitySelectionDisabled&&!r)||!n||(e=n),this.range&&this.mostRecentRangeValue&&(e=this.mostRecentRangeValue),a(i,{onBlur:this.reset,onKeyDown:this.keyDownHandler},this.renderCalendar(e,this.range&&this.activeRange&&"start"===this.activeRange&&r||this.maxAsDate,this.range&&this.activeRange?"start"===this.activeRange?this.minAsDate:t||this.minAsDate:this.minAsDate,t,r))}effectiveLocaleChange(){j(this,this.effectiveLocale)}valueHandler(t){Array.isArray(t)?this.valueAsDate=l(t):t&&(this.valueAsDate=c(t))}async loadLocaleData(){z.numberFormatOptions={numberingSystem:this.numberingSystem,locale:this.effectiveLocale,useGrouping:!1},this.localeData=await d(this.effectiveLocale),this.dateTimeFormat=C(this.effectiveLocale,N)}renderCalendar(t,e,i,r,n){return this.localeData&&[a("calcite-date-picker-month-header",{activeDate:t,headingLevel:this.headingLevel||2,localeData:this.localeData,max:e,messages:this.messages,min:i,onCalciteInternalDatePickerSelect:this.monthHeaderSelectChange,scale:this.scale,selectedDate:"end"===this.activeRange?n:r||new Date}),a("calcite-date-picker-month",{activeDate:t,dateTimeFormat:this.dateTimeFormat,endDate:this.range?n:void 0,hoverRange:this.hoverRange,localeData:this.localeData,max:e,min:i,onCalciteInternalDatePickerActiveDateChange:this.monthActiveDateChange,onCalciteInternalDatePickerHover:this.monthHoverChange,onCalciteInternalDatePickerMouseOut:this.monthMouseOutChange,onCalciteInternalDatePickerSelect:this.monthDateChange,scale:this.scale,selectedDate:"end"===this.activeRange?n:r,startDate:this.range?r:void 0})]}getEndDate(){return Array.isArray(this.valueAsDate)&&this.valueAsDate[1]||void 0}setEndDate(t){const e=this.getStartDate(),a=t?u(t):t;this.value=[s(e),s(t)],this.valueAsDate=[e,t],this.mostRecentRangeValue=a,this.calciteDatePickerRangeChange.emit(),this.activeEndDate=t||null}getStartDate(){return Array.isArray(this.valueAsDate)&&this.valueAsDate[0]}setStartDate(t){const e=this.getEndDate();this.value=[s(t),s(e)],this.valueAsDate=[t,e],this.mostRecentRangeValue=t,this.calciteDatePickerRangeChange.emit(),this.activeStartDate=t||null}getActiveDate(t,e,a){return h(this.activeDate,e,a)||t||h(new Date,e,a)}getActiveEndDate(t,e,a){return h(this.activeEndDate,e,a)||t||h(new Date,e,a)}static get delegatesFocus(){return!0}static get assetsDirs(){return["assets"]}get el(){return r(this)}static get watchers(){return{activeDate:["activeDateWatcher"],valueAsDate:["valueAsDateWatcher"],min:["onMinChanged"],max:["onMaxChanged"],messageOverrides:["onMessagesChange"],effectiveLocale:["effectiveLocaleChange","loadLocaleData"],value:["valueHandler"]}}};F.style="@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-right{0%{opacity:0;transform:translate3D(-5px, 0, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-left{0%{opacity:0;transform:translate3D(5px, 0, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-right{animation-name:in-right}.calcite-animate__in-left{animation-name:in-left}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:var(--calcite-app-z-index-dropdown)}:host([hidden]){display:none}:host{position:relative;display:inline-block;inline-size:100%;overflow:visible;border-radius:0px;border-width:1px;border-style:solid;border-color:var(--calcite-ui-border-1);background-color:var(--calcite-ui-foreground-1);vertical-align:top}:host([scale=s]){max-inline-size:216px}:host([scale=m]){max-inline-size:286px}:host([scale=l]){max-inline-size:398px}";const K=class{constructor(a){t(this,a),this.calciteDaySelect=e(this,"calciteDaySelect",6),this.calciteInternalDayHover=e(this,"calciteInternalDayHover",6),this.onClick=()=>{this.disabled||this.calciteDaySelect.emit()},this.keyDownHandler=t=>{W(t.key)&&(!this.disabled&&this.calciteDaySelect.emit(),t.preventDefault())},this.day=void 0,this.dateTimeFormat=void 0,this.disabled=!1,this.currentMonth=!1,this.selected=!1,this.highlighted=!1,this.range=!1,this.rangeEdge=void 0,this.startOfRange=!1,this.endOfRange=!1,this.rangeHover=!1,this.active=!1,this.scale=void 0,this.value=void 0}pointerOverHandler(){this.disabled||this.calciteInternalDayHover.emit()}componentWillLoad(){this.parentDatePickerEl=M(this.el,"calcite-date-picker")}render(){const t=s(this.value).replaceAll("-","");if(this.parentDatePickerEl){const{numberingSystem:t,lang:e}=this.parentDatePickerEl;z.numberFormatOptions={useGrouping:!1,...t&&{numberingSystem:t},...e&&{locale:e}}}const e=z.localize(String(this.day)),r=P(this.el),n=this.dateTimeFormat.format(this.value);return a(i,{"aria-disabled":H(this.disabled),"aria-label":n,"aria-selected":H(this.active),id:t,onClick:this.onClick,onKeyDown:this.keyDownHandler,role:"button"},a("div",{"aria-hidden":"true",class:{"day-v-wrapper":!0,[Y.rtl]:"rtl"===r}},a("div",{class:"day-wrapper"},a("span",{class:"day"},a("span",{class:"text"},e)))))}connectedCallback(){O(this)}componentDidRender(){R(this,this.isTabbable)}disconnectedCallback(){L(this)}isTabbable(){return this.active}get el(){return r(this)}};K.style="@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-right{0%{opacity:0;transform:translate3D(-5px, 0, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-left{0%{opacity:0;transform:translate3D(5px, 0, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-right{animation-name:in-right}.calcite-animate__in-left{animation-name:in-left}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:var(--calcite-app-z-index-dropdown)}:host([hidden]){display:none}:host([disabled]){cursor:default;-webkit-user-select:none;user-select:none;opacity:var(--calcite-ui-opacity-disabled)}:host([disabled]) *,:host([disabled]) ::slotted(*){pointer-events:none}:host{display:flex;cursor:pointer;color:var(--calcite-ui-text-3)}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}.day-v-wrapper{flex:1 1 auto}.day-wrapper{display:flex;flex-direction:column;align-items:center}.day{display:flex;align-items:center;justify-content:center;border-radius:9999px;font-size:var(--calcite-font-size--2);line-height:1rem;line-height:1;color:var(--calcite-ui-text-3);opacity:var(--calcite-ui-opacity-disabled);outline-color:transparent;transition:all var(--calcite-animation-timing) ease-in-out 0s, outline 0s, outline-offset 0s;background:none;box-shadow:0 0 0 2px transparent}.text{margin-block:1px 0px;margin-inline-start:0px}:host([scale=s]) .day-v-wrapper{padding-block:0.125rem}:host([scale=s]) .day-wrapper{padding:0px}:host([scale=s]) .day{block-size:27px;inline-size:27px;font-size:var(--calcite-font-size--2)}:host([scale=m]) .day-v-wrapper{padding-block:0.25rem}:host([scale=m]) .day-wrapper{padding-inline:0.25rem}:host([scale=m]) .day{block-size:33px;inline-size:33px;font-size:var(--calcite-font-size--1)}:host([scale=l]) .day-v-wrapper{padding-block:0.25rem}:host([scale=l]) .day-wrapper{padding-inline:0.25rem}:host([scale=l]) .day{block-size:43px;inline-size:43px;font-size:var(--calcite-font-size-0)}:host([current-month]) .day{opacity:1}:host(:hover:not([disabled])) .day,:host([active]:not([range])) .day{background-color:var(--calcite-ui-foreground-2);color:var(--calcite-ui-text-1)}:host(:focus),:host([active]){outline:2px solid transparent;outline-offset:2px}:host(:focus:not([disabled])) .day{outline:2px solid var(--calcite-ui-focus-color, var(--calcite-ui-brand));outline-offset:calc(\n 2px *\n calc(\n 1 -\n 2 * clamp(\n 0,\n var(--calcite-ui-focus-offset-invert),\n 1\n )\n )\n );box-shadow:0 0 0 2px var(--calcite-ui-foreground-1)}:host([selected]) .day{font-weight:var(--calcite-font-weight-medium);background-color:var(--calcite-ui-brand) !important;color:var(--calcite-ui-foreground-1) !important}:host([range][selected]) .day-wrapper{background-color:var(--calcite-ui-foreground-current)}:host([start-of-range]) .day-wrapper{border-start-start-radius:40%;border-end-start-radius:40%}:host([end-of-range]) .day-wrapper{border-start-end-radius:40%;border-end-end-radius:40%}:host([start-of-range]) :not(.calcite--rtl) .day-wrapper{box-shadow:inset 4px 0 var(--calcite-ui-foreground-1)}:host([start-of-range]) .calcite--rtl .day-wrapper{box-shadow:inset -4px 0 var(--calcite-ui-foreground-1)}:host([start-of-range]) .day{opacity:1}:host([end-of-range]) :not(.calcite--rtl) .day-wrapper{box-shadow:inset -4px 0 var(--calcite-ui-foreground-1)}:host([end-of-range]) .calcite--rtl .day-wrapper{box-shadow:inset 4px 0 var(--calcite-ui-foreground-1)}:host([end-of-range]) .day{opacity:1}:host([start-of-range]:not(:focus)) :not(.calcite--rtl) .day,:host([end-of-range]:not(:focus)) :not(.calcite--rtl) .day{box-shadow:0 0 0 2px var(--calcite-ui-foreground-1)}:host([start-of-range]:not(:focus)) .calcite--rtl .day,:host([end-of-range]:not(:focus)) .calcite--rtl .day{box-shadow:0 0 0 2px var(--calcite-ui-foreground-1)}:host([start-of-range][scale=l]) :not(.calcite--rtl) .day-wrapper{box-shadow:inset 8px 0 var(--calcite-ui-foreground-1)}:host([start-of-range][scale=l]) .calcite--rtl .day-wrapper{box-shadow:inset -8px 0 var(--calcite-ui-foreground-1)}:host([end-of-range][scale=l]) :not(.calcite--rtl) .day-wrapper{box-shadow:inset -8px 0 var(--calcite-ui-foreground-1)}:host([end-of-range][scale=l]) .calcite--rtl .day-wrapper{box-shadow:inset 8px 0 var(--calcite-ui-foreground-1)}:host([highlighted]) .day-wrapper{background-color:var(--calcite-ui-foreground-current)}:host([highlighted]) .day-wrapper .day{color:var(--calcite-ui-text-1)}:host([highlighted]:not([active]:focus)) .day{color:var(--calcite-ui-text-1)}:host([range-hover]:not([selected])) .day-wrapper{background-color:var(--calcite-ui-foreground-2)}:host([range-hover]:not([selected])) .day{border-radius:0px}:host([start-of-range][range-hover]) :not(.calcite--rtl) .day-wrapper{background-image:linear-gradient(to left, var(--calcite-ui-foreground-current), var(--calcite-ui-foreground-current), var(--calcite-ui-foreground-2), var(--calcite-ui-foreground-2));border-radius:0px;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}:host([start-of-range][range-hover]) .calcite--rtl .day-wrapper{background-image:linear-gradient(to right, var(--calcite-ui-foreground-current), var(--calcite-ui-foreground-current), var(--calcite-ui-foreground-2), var(--calcite-ui-foreground-2));border-radius:0px;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}:host([end-of-range][range-hover]) :not(.calcite--rtl) .day-wrapper{background-image:linear-gradient(to right, var(--calcite-ui-foreground-current), var(--calcite-ui-foreground-current), var(--calcite-ui-foreground-2), var(--calcite-ui-foreground-2));border-radius:0px;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}:host([end-of-range][range-hover]) .calcite--rtl .day-wrapper{background-image:linear-gradient(to left, var(--calcite-ui-foreground-current), var(--calcite-ui-foreground-current), var(--calcite-ui-foreground-2), var(--calcite-ui-foreground-2));border-radius:0px;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}:host(:hover[end-of-range][range-hover]) :not(.calcite--rtl) .day-wrapper,:host(:hover[start-of-range][range-hover]) .calcite--rtl .day-wrapper{background-image:linear-gradient(to right, var(--calcite-ui-foreground-current), var(--calcite-ui-foreground-current), var(--calcite-ui-foreground-1), var(--calcite-ui-foreground-1));border-radius:0px;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}:host(:hover[start-of-range][range-hover]) :not(.calcite--rtl) .day-wrapper,:host(:hover[end-of-range][range-hover]) .calcite--rtl .day-wrapper{background-image:linear-gradient(to left, var(--calcite-ui-foreground-current), var(--calcite-ui-foreground-current), var(--calcite-ui-foreground-1), var(--calcite-ui-foreground-1));border-radius:0px;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}:host(:hover[range-hover]:not([selected]).focused--start) :not(.calcite--rtl) .day-wrapper{background-image:linear-gradient(to right, var(--calcite-ui-foreground-current), var(--calcite-ui-foreground-current), var(--calcite-ui-foreground-2), var(--calcite-ui-foreground-2))}:host(:hover[range-hover]:not([selected]).focused--start) .calcite--rtl .day-wrapper{background-image:linear-gradient(to right, var(--calcite-ui-foreground-2), var(--calcite-ui-foreground-2), var(--calcite-ui-foreground-current), var(--calcite-ui-foreground-current))}:host(:hover[range-hover]:not([selected]).focused--start) .day{border-radius:9999px;opacity:1;box-shadow:0 0 0 2px var(--calcite-ui-foreground-1)}:host(:hover[range-hover]:not([selected]).focused--end) :not(.calcite--rtl) .day-wrapper{background-image:linear-gradient(to right, var(--calcite-ui-foreground-2), var(--calcite-ui-foreground-2), var(--calcite-ui-foreground-current), var(--calcite-ui-foreground-current))}:host(:hover[range-hover]:not([selected]).focused--end) .calcite--rtl .day-wrapper{background-image:linear-gradient(to right, var(--calcite-ui-foreground-current), var(--calcite-ui-foreground-current), var(--calcite-ui-foreground-2), var(--calcite-ui-foreground-2))}:host(:hover[range-hover]:not([selected]).focused--end) .day{border-radius:9999px;opacity:1;box-shadow:0 0 0 2px var(--calcite-ui-foreground-1)}:host(:hover[range-hover]:not([selected]).focused--start.hover--outside-range) :not(.calcite--rtl) .day-wrapper,:host(:hover[range-hover]:not([selected]).focused--end.hover--outside-range) .calcite--rtl .day-wrapper{background-image:linear-gradient(to right, var(--calcite-ui-foreground-1), var(--calcite-ui-foreground-1), var(--calcite-ui-foreground-2), var(--calcite-ui-foreground-2))}:host(:hover[range-hover]:not([selected]).focused--start.hover--outside-range) :not(.calcite--rtl) .day,:host(:hover[range-hover]:not([selected]).focused--end.hover--outside-range) .calcite--rtl .day{border-radius:9999px;opacity:1;box-shadow:0 0 0 2px var(--calcite-ui-foreground-1)}:host(:hover[range-hover]:not([selected]).focused--end.hover--outside-range) :not(.calcite--rtl) .day-wrapper,:host(:hover[range-hover]:not([selected]).focused--start.hover--outside-range) .calcite--rtl .day-wrapper{background-image:linear-gradient(to right, var(--calcite-ui-foreground-2), var(--calcite-ui-foreground-2), var(--calcite-ui-foreground-1), var(--calcite-ui-foreground-1))}:host(:hover[range-hover]:not([selected]).focused--end.hover--outside-range) :not(.calcite--rtl) .day,:host(:hover[range-hover]:not([selected]).focused--start.hover--outside-range) .calcite--rtl .day{border-radius:9999px;opacity:1;box-shadow:0 0 0 2px var(--calcite-ui-foreground-1)}:host(:hover[start-of-range].hover--inside-range.focused--end) .day-wrapper,:host(:hover[end-of-range].hover--inside-range.focused--start) .day-wrapper{background-image:none}:host([start-of-range].hover--inside-range.focused--end) .day-wrapper,:host([end-of-range].hover--inside-range.focused--start) .day-wrapper{background-color:var(--calcite-ui-foreground-2)}:host([highlighted][range-edge=end]) :not(.calcite--rtl) .day-wrapper,:host([range-hover][range-edge=end]) :not(.calcite--rtl) .day-wrapper,:host([highlighted][range-edge=start]) .calcite--rtl .day-wrapper,:host([range-hover][range-edge=start]) .calcite--rtl .day-wrapper{box-shadow:inset -4px 0px 0px 0px var(--calcite-ui-foreground-1)}:host([highlighted][range-edge=start]) :not(.calcite--rtl) .day-wrapper,:host([range-hover][range-edge=start]) :not(.calcite--rtl) .day-wrapper,:host([highlighted][range-edge=end]) .calcite--rtl .day-wrapper,:host([range-hover][range-edge=end]) .calcite--rtl .day-wrapper{box-shadow:inset 4px 0px 0px 0px var(--calcite-ui-foreground-1)}:host([scale=s][highlighted][range-edge=end]) :not(.calcite--rtl) .day-wrapper,:host([scale=s][range-hover][range-edge=end]) :not(.calcite--rtl) .day-wrapper,:host([scale=s][highlighted][range-edge=start]) .calcite--rtl .day-wrapper,:host([scale=s][range-hover][range-edge=start]) .calcite--rtl .day-wrapper{box-shadow:inset -1px 0px 0px 0px var(--calcite-ui-foreground-1)}:host([scale=s][highlighted][range-edge=start]) :not(.calcite--rtl) .day-wrapper,:host([scale=s][range-hover][range-edge=start]) :not(.calcite--rtl) .day-wrapper,:host([scale=s][highlighted][range-edge=end]) .calcite--rtl .day-wrapper,:host([scale=s][range-hover][range-edge=end]) .calcite--rtl .day-wrapper{box-shadow:inset 1px 0px 0px 0px var(--calcite-ui-foreground-1)}:host([scale=l][highlighted][range-edge=start]) :not(.calcite--rtl) .day-wrapper,:host([scale=l][range-hover][range-edge=start]) :not(.calcite--rtl) .day-wrapper,:host([scale=l][highlighted][range-edge=end]) .calcite--rtl .day-wrapper,:host([scale=l][range-hover][range-edge=end]) .calcite--rtl .day-wrapper{box-shadow:inset 6px 0px 0px 0px var(--calcite-ui-foreground-1)}:host([highlighted][range-edge=start]) .day-wrapper,:host([range-hover][range-edge=start]) .day-wrapper{border-start-start-radius:45%;border-end-start-radius:45%}:host([highlighted][range-edge=end]) .day-wrapper,:host([range-hover][range-edge=end]) .day-wrapper{border-start-end-radius:45%;border-end-end-radius:45%}:host([scale=l][highlighted][range-edge=end]) :not(.calcite--rtl) .day-wrapper,:host([scale=l][range-hover][range-edge=end]) :not(.calcite--rtl) .day-wrapper,:host([scale=l][highlighted][range-edge=start]) .calcite--rtl .day-wrapper,:host([scale=l][range-hover][range-edge=start]) .calcite--rtl .day-wrapper{box-shadow:inset -6px 0px 0px 0px var(--calcite-ui-foreground-1)}@media (forced-colors: active){:host(:hover:not([disabled])) .day,:host([active]:not([range])) .day{border-radius:0px}:host([selected]){outline:2px solid canvasText}:host([selected]) .day{border-radius:0px;background-color:highlight}:host([range][selected]) .day-wrapper,:host([highlighted]) .day-wrapper,:host([range-hover]:not([selected])) .day-wrapper{background-color:highlight}:host([range][selected][start-of-range]) .day-wrapper,:host([range][selected][end-of-range]) .day-wrapper{background-color:canvas}}";const T=class{constructor(a){t(this,a),this.calciteInternalDatePickerSelect=e(this,"calciteInternalDatePickerSelect",6),this.calciteInternalDatePickerHover=e(this,"calciteInternalDatePickerHover",6),this.calciteInternalDatePickerActiveDateChange=e(this,"calciteInternalDatePickerActiveDateChange",6),this.calciteInternalDatePickerMouseOut=e(this,"calciteInternalDatePickerMouseOut",6),this.keyDownHandler=t=>{if(t.defaultPrevented)return;const e="rtl"===this.el.dir;switch(t.key){case"ArrowUp":t.preventDefault(),this.addDays(-7);break;case"ArrowRight":t.preventDefault(),this.addDays(e?-1:1);break;case"ArrowDown":t.preventDefault(),this.addDays(7);break;case"ArrowLeft":t.preventDefault(),this.addDays(e?1:-1);break;case"PageUp":t.preventDefault(),this.addMonths(-1);break;case"PageDown":t.preventDefault(),this.addMonths(1);break;case"Home":t.preventDefault(),this.activeDate.setDate(1),this.addDays();break;case"End":t.preventDefault(),this.activeDate.setDate(new Date(this.activeDate.getFullYear(),this.activeDate.getMonth()+1,0).getDate()),this.addDays();break;case"Enter":case" ":t.preventDefault();break;case"Tab":this.activeFocus=!1}},this.disableActiveFocus=()=>{this.activeFocus=!1},this.dayHover=t=>{const e=t.target;e.disabled?this.calciteInternalDatePickerMouseOut.emit():this.calciteInternalDatePickerHover.emit(e.value),t.stopPropagation()},this.daySelect=t=>{this.calciteInternalDatePickerSelect.emit(t.target.value)},this.dateTimeFormat=void 0,this.selectedDate=void 0,this.activeDate=new Date,this.startDate=void 0,this.endDate=void 0,this.min=void 0,this.max=void 0,this.scale=void 0,this.localeData=void 0,this.hoverRange=void 0}pointerOutHandler(){this.calciteInternalDatePickerMouseOut.emit()}render(){const t=this.activeDate.getMonth(),e=this.activeDate.getFullYear(),r=this.localeData.weekStart%7,{abbreviated:n,short:o,narrow:s}=this.localeData.days,c="s"===this.scale?s||o||n:o||n||s,l=[...c.slice(r,7),...c.slice(0,r)],h=this.getCurrentMonthDays(t,e),d=this.getPreviousMonthDays(t,e,r),u=this.getNextMonthDays(t,e,r);let p=0;const f=()=>p++%7,m=[...d.map((a=>({active:!1,day:a,dayInWeek:f(),date:new Date(e,t-1,a)}))),...h.map((a=>{const i=new Date(e,t,a);return{active:g(i,this.activeDate),currentMonth:!0,day:a,dayInWeek:f(),date:i,ref:!0}})),...u.map((a=>({active:!1,day:a,dayInWeek:f(),date:new Date(e,t+1,a)})))],v=[];for(let t=0;t<m.length;t+=7)v.push(m.slice(t,t+7));return a(i,{onFocusOut:this.disableActiveFocus,onKeyDown:this.keyDownHandler},a("div",{class:"calendar",role:"grid"},a("div",{class:"week-headers",role:"row"},l.map((t=>a("span",{class:"week-header",role:"columnheader"},t)))),v.map((t=>a("div",{class:"week-days",role:"row"},t.map((t=>this.renderDateDay(t))))))))}addMonths(t){const e=new Date(this.activeDate);e.setMonth(this.activeDate.getMonth()+t),this.calciteInternalDatePickerActiveDateChange.emit(h(e,this.min,this.max)),this.activeFocus=!0}addDays(t=0){const e=new Date(this.activeDate);e.setDate(this.activeDate.getDate()+t),this.calciteInternalDatePickerActiveDateChange.emit(h(e,this.min,this.max)),this.activeFocus=!0}getPreviousMonthDays(t,e,a){const i=new Date(e,t,0),r=i.getDate(),n=i.getDay(),o=[];if(n===(a+6)%7)return o;if(n===a)return[r];for(let t=(7+n-a)%7;t>=0;t--)o.push(r-t);return o}getCurrentMonthDays(t,e){const a=new Date(e,t+1,0).getDate(),i=[];for(let t=0;t<a;t++)i.push(t+1);return i}getNextMonthDays(t,e,a){const i=new Date(e,t+1,0).getDay(),r=[];if(i===(a+6)%7)return r;for(let t=0;t<(6-(i-a))%7;t++)r.push(t+1);return r}betweenSelectedRange(t){return!(!(this.startDate&&this.endDate&&t>this.startDate&&t<this.endDate)||this.isRangeHover(t))}isSelected(t){return!!(g(t,this.selectedDate)||this.startDate&&g(t,this.startDate)||this.endDate&&g(t,this.endDate))}isStartOfRange(t){return!(!this.startDate||g(this.startDate,this.endDate)||!g(this.startDate,t)||this.isEndOfRange(t))}isEndOfRange(t){return!!(this.endDate&&!g(this.startDate,this.endDate)&&g(this.endDate,t)||!this.endDate&&this.hoverRange&&g(this.startDate,this.hoverRange.end)&&g(t,this.hoverRange.end))}renderDateDay({active:t,currentMonth:e,date:i,day:r,dayInWeek:n,ref:o}){const s=this.isFocusedOnStart(),c=this.isHoverInRange()||!this.endDate&&this.hoverRange&&g(this.hoverRange?.end,this.startDate);return a("div",{class:"day",key:i.toDateString(),role:"gridcell"},a("calcite-date-picker-day",{active:t,class:{"hover--inside-range":this.startDate&&c,"hover--outside-range":this.startDate&&!c,"focused--start":s,"focused--end":!s},currentMonth:e,dateTimeFormat:this.dateTimeFormat,day:r,disabled:!p(i,this.min,this.max),endOfRange:this.isEndOfRange(i),highlighted:this.betweenSelectedRange(i),onCalciteDaySelect:this.daySelect,onCalciteInternalDayHover:this.dayHover,range:!!this.startDate&&!!this.endDate&&!g(this.startDate,this.endDate),rangeEdge:0===n?"start":6===n?"end":void 0,rangeHover:this.isRangeHover(i),scale:this.scale,selected:this.isSelected(i),startOfRange:this.isStartOfRange(i),value:i,ref:e=>{o&&t&&this.activeFocus&&e?.focus()}}))}isFocusedOnStart(){return"start"===this.hoverRange?.focused}isHoverInRange(){if(!this.hoverRange)return!1;const{start:t,end:e}=this.hoverRange;return!!(!this.isFocusedOnStart()&&this.startDate&&(!this.endDate||e<this.endDate)||this.isFocusedOnStart()&&this.startDate&&t>this.startDate)}isRangeHover(t){if(!this.hoverRange)return!1;const{start:e,end:a}=this.hoverRange,i=this.isFocusedOnStart(),r=this.isHoverInRange(),n=r&&(!i&&t>this.startDate&&(t<a||g(t,a))||i&&t<this.endDate&&(t>e||g(t,e))),o=!r&&(!i&&t>=this.endDate&&(t<a||g(t,a))||i&&(this.startDate&&t<this.startDate||this.endDate&&g(t,this.startDate))&&(e&&t>e||g(t,e)));return n||o}get el(){return r(this)}};T.style="@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-right{0%{opacity:0;transform:translate3D(-5px, 0, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-left{0%{opacity:0;transform:translate3D(5px, 0, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-right{animation-name:in-right}.calcite-animate__in-left{animation-name:in-left}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:var(--calcite-app-z-index-dropdown)}:host([hidden]){display:none}.calendar{margin-block-end:0.25rem}.week-headers{display:flex;border-width:0px;border-block-start-width:1px;border-style:solid;border-color:var(--calcite-ui-border-3);padding-block:0px;padding-inline:0.25rem}.week-header{text-align:center;font-weight:var(--calcite-font-weight-bold);color:var(--calcite-ui-text-3);inline-size:14.2857142857%}.day{display:flex;min-inline-size:0px;justify-content:center;inline-size:14.2857142857%}:host([scale=s]) .week-header{padding-inline:0px;padding-block:0.5rem 0.75rem;font-size:var(--calcite-font-size--2);line-height:1rem}:host([scale=m]) .week-header{padding-inline:0px;padding-block:0.75rem 1rem;font-size:var(--calcite-font-size--2);line-height:1rem}:host([scale=l]) .week-header{padding-inline:0px;padding-block:1rem 1.25rem;font-size:var(--calcite-font-size--1);line-height:1rem}.week-days{display:flex;flex-direction:row;padding-block:0px;padding-inline:6px}.week-days:focus{outline:2px solid transparent;outline-offset:2px}";const $="chevron",G=class{constructor(a){t(this,a),this.calciteInternalDatePickerSelect=e(this,"calciteInternalDatePickerSelect",6),this.onYearKey=t=>{const e=this.parseCalendarYear(t.target.value);switch(t.key){case"ArrowDown":t.preventDefault(),this.setYear({localizedYear:e,offset:-1});break;case"ArrowUp":t.preventDefault(),this.setYear({localizedYear:e,offset:1})}},this.onYearChange=t=>{this.setYear({localizedYear:this.parseCalendarYear(t.target.value)})},this.onYearInput=t=>{this.setYear({localizedYear:this.parseCalendarYear(t.target.value),commit:!1})},this.prevMonthClick=t=>{this.handleArrowClick(t,this.prevMonthDate)},this.prevMonthKeydown=t=>{W(t.key)&&this.prevMonthClick(t)},this.nextMonthClick=t=>{this.handleArrowClick(t,this.nextMonthDate)},this.nextMonthKeydown=t=>{W(t.key)&&this.nextMonthClick(t)},this.handleArrowClick=(t,e)=>{t.preventDefault(),this.calciteInternalDatePickerSelect.emit(e)},this.selectedDate=void 0,this.activeDate=void 0,this.headingLevel=void 0,this.min=void 0,this.max=void 0,this.scale=void 0,this.localeData=void 0,this.messages=void 0,this.nextMonthDate=void 0,this.prevMonthDate=void 0}componentWillLoad(){this.parentDatePickerEl=M(this.el,"calcite-date-picker")}connectedCallback(){this.setNextPrevMonthDates()}render(){return a("div",{class:"header"},this.renderContent())}renderContent(){const{messages:t,localeData:e,activeDate:i}=this;if(!i||!e)return null;if(this.parentDatePickerEl){const{numberingSystem:t,lang:e}=this.parentDatePickerEl;z.numberFormatOptions={useGrouping:!1,...t&&{numberingSystem:t},...e&&{locale:e}}}const r=i.getMonth(),{months:o,unitOrder:s}=e,c=(o.wide||o.narrow||o.abbreviated)[r],l=this.formatCalendarYear(i.getFullYear()),h="l"===this.scale?"m":"s",d=f(s),u=d.indexOf("y")<d.indexOf("m"),g=e.year?.suffix;return a(n,null,a("a",{"aria-disabled":`${this.prevMonthDate.getMonth()===r}`,"aria-label":t.prevMonth,class:$,href:"#",onClick:this.prevMonthClick,onKeyDown:this.prevMonthKeydown,role:"button",tabindex:this.prevMonthDate.getMonth()===r?-1:0},a("calcite-icon",{"flip-rtl":!0,icon:"chevron-left",scale:h})),a("div",{class:{text:!0,"text--reverse":u}},a(E,{class:"month",level:this.headingLevel},c),a("span",{class:"year-wrap"},a("input",{"aria-label":t.year,class:{year:!0,"year--suffix":!!g},inputmode:"numeric",maxlength:"4",minlength:"1",onChange:this.onYearChange,onInput:this.onYearInput,onKeyDown:this.onYearKey,pattern:"\\d*",type:"text",value:l,ref:t=>this.yearInput=t}),g&&a("span",{class:"suffix"},g))),a("a",{"aria-disabled":`${this.nextMonthDate.getMonth()===r}`,"aria-label":t.nextMonth,class:$,href:"#",onClick:this.nextMonthClick,onKeyDown:this.nextMonthKeydown,role:"button",tabindex:this.nextMonthDate.getMonth()===r?-1:0},a("calcite-icon",{"flip-rtl":!0,icon:"chevron-right",scale:h})))}setNextPrevMonthDates(){this.activeDate&&(this.nextMonthDate=h(m(this.activeDate),this.min,this.max),this.prevMonthDate=h(v(this.activeDate),this.min,this.max))}formatCalendarYear(t){return z.localize(`${y(t,this.localeData)}`)}parseCalendarYear(t){return z.localize(`${w(Number(z.delocalize(t)),this.localeData)}`)}getInRangeDate({localizedYear:t,offset:e=0}){const{min:a,max:i,activeDate:r}=this,n=Number(z.delocalize(t)),o=n.toString().length,s=!isNaN(n)&&n+e,c=s&&(!a||a.getFullYear()<=s)&&(!i||i.getFullYear()>=s);if(s&&c&&o===t.length){const t=new Date(r);return t.setFullYear(s),h(t,a,i)}}setYear({localizedYear:t,commit:e=!0,offset:a=0}){const{yearInput:i,activeDate:r}=this,n=this.getInRangeDate({localizedYear:t,offset:a});n&&this.calciteInternalDatePickerSelect.emit(n),e&&(i.value=this.formatCalendarYear((n||r).getFullYear()))}get el(){return r(this)}static get watchers(){return{min:["setNextPrevMonthDates"],max:["setNextPrevMonthDates"],activeDate:["setNextPrevMonthDates"]}}};G.style="@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-right{0%{opacity:0;transform:translate3D(-5px, 0, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-left{0%{opacity:0;transform:translate3D(5px, 0, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-right{animation-name:in-right}.calcite-animate__in-left{animation-name:in-left}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:var(--calcite-app-z-index-dropdown)}:host([hidden]){display:none}:host{display:block}.header{display:flex;justify-content:space-between;padding-block:0px;padding-inline:0.25rem}:host([scale=s]) .text{margin-block:0.5rem;font-size:var(--calcite-font-size--1);line-height:1rem}:host([scale=s]) .chevron{block-size:2.25rem}:host([scale=m]) .text{margin-block:0.75rem;font-size:var(--calcite-font-size-0);line-height:1.25rem}:host([scale=m]) .chevron{block-size:3rem}:host([scale=l]) .text{margin-block:1rem;font-size:var(--calcite-font-size-1);line-height:1.5rem}:host([scale=l]) .chevron{block-size:3.5rem}.chevron{margin-inline:-0.25rem;box-sizing:content-box;display:flex;flex-grow:0;cursor:pointer;align-items:center;justify-content:center;border-style:none;background-color:var(--calcite-ui-foreground-1);padding-inline:0.25rem;color:var(--calcite-ui-text-3);outline:2px solid transparent;outline-offset:2px;outline-color:transparent;transition:all var(--calcite-animation-timing) ease-in-out 0s, outline 0s, outline-offset 0s;inline-size:14.2857142857%}.chevron:focus{outline:2px solid var(--calcite-ui-focus-color, var(--calcite-ui-brand));outline-offset:calc(\n -2px *\n calc(\n 1 -\n 2 * clamp(\n 0,\n var(--calcite-ui-focus-offset-invert),\n 1\n )\n )\n )}.chevron:hover,.chevron:focus{background-color:var(--calcite-ui-foreground-2);fill:var(--calcite-ui-text-1);color:var(--calcite-ui-text-1)}.chevron:active{background-color:var(--calcite-ui-foreground-3)}.chevron[aria-disabled=true]{pointer-events:none;opacity:0}.text{margin-block:auto;display:flex;inline-size:100%;flex:1 1 auto;align-items:center;justify-content:center;text-align:center;line-height:1}.text--reverse{flex-direction:row-reverse}.month,.year,.suffix{margin-inline:0.25rem;margin-block:auto;display:inline-block;background-color:var(--calcite-ui-foreground-1);font-weight:var(--calcite-font-weight-medium);line-height:1.25;color:var(--calcite-ui-text-1);font-size:inherit}.year{position:relative;inline-size:2.5rem;border-style:none;background-color:transparent;text-align:center;font-family:inherit;outline-color:transparent}.year:hover{transition-duration:100ms;transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-property:outline-color;outline:2px solid var(--calcite-ui-border-2);outline-offset:2px}.year:focus{outline:2px solid var(--calcite-ui-focus-color, var(--calcite-ui-brand));outline-offset:calc(\n 2px *\n calc(\n 1 -\n 2 * clamp(\n 0,\n var(--calcite-ui-focus-offset-invert),\n 1\n )\n )\n )}.year--suffix{text-align:start}.year-wrap{position:relative}.suffix{inset-block-start:0px;white-space:nowrap;text-align:start;inset-inline-start:0}";export{F as calcite_date_picker,K as calcite_date_picker_day,T as calcite_date_picker_month,G as calcite_date_picker_month_header}