@aurodesignsystem-dev/auro-formkit 0.0.0-pr624.75 → 0.0.0-pr624.77
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/components/bibtemplate/dist/index.js +1 -1
- package/components/bibtemplate/dist/registered.js +1 -1
- package/components/combobox/demo/api.min.js +1 -1
- package/components/combobox/demo/index.min.js +1 -1
- package/components/combobox/dist/index.js +1 -1
- package/components/combobox/dist/registered.js +1 -1
- package/components/counter/demo/api.min.js +1 -1
- package/components/counter/demo/index.min.js +1 -1
- package/components/counter/dist/index.js +1 -1
- package/components/counter/dist/registered.js +1 -1
- package/components/datepicker/README.md +1 -1
- package/components/datepicker/demo/api.md +39 -19
- package/components/datepicker/demo/api.min.js +155 -76
- package/components/datepicker/demo/index.md +4 -4
- package/components/datepicker/demo/index.min.js +155 -76
- package/components/datepicker/demo/readme.md +1 -1
- package/components/datepicker/dist/auro-datepicker.d.ts +50 -12
- package/components/datepicker/dist/index.js +155 -76
- package/components/datepicker/dist/registered.js +155 -76
- package/components/datepicker/dist/styles/classic/style-css.d.ts +2 -0
- package/components/radio/demo/api.md +32 -1
- package/components/radio/demo/api.min.js +2 -2
- package/components/radio/demo/index.min.js +2 -2
- package/components/radio/dist/index.js +2 -2
- package/components/radio/dist/registered.js +2 -2
- package/components/select/demo/api.min.js +1 -1
- package/components/select/demo/index.min.js +1 -1
- package/components/select/dist/index.js +1 -1
- package/components/select/dist/registered.js +1 -1
- package/package.json +1 -1
- /package/components/datepicker/dist/styles/{default → classic}/color-css.d.ts +0 -0
|
@@ -1258,19 +1258,21 @@ class UtilitiesCalendarRender {
|
|
|
1258
1258
|
}
|
|
1259
1259
|
}
|
|
1260
1260
|
|
|
1261
|
-
var styleCss$e = css`.util_displayInline{display:inline}.util_displayInlineBlock{display:inline-block}.util_displayBlock{display:block}.util_displayFlex{display:flex}.util_displayHidden{display:none}.util_displayHiddenVisually{position:absolute;overflow:hidden;clip:rect(1px, 1px, 1px, 1px);width:1px;height:1px;padding:0;border:0}:
|
|
1261
|
+
var styleCss$e = css`.util_displayInline{display:inline}.util_displayInlineBlock{display:inline-block}.util_displayBlock{display:block}.util_displayFlex{display:flex}.util_displayHidden{display:none}.util_displayHiddenVisually{position:absolute;overflow:hidden;clip:rect(1px, 1px, 1px, 1px);width:1px;height:1px;padding:0;border:0}.accents{flex-grow:0;flex-shrink:0;display:flex;align-items:center;justify-content:center}.accents.left{padding-right:var(--ds-size-100, 0.5rem)}.accents.right{width:var(--ds-size-400, 2rem)}.mainContent{height:100%;max-height:100%;flex-grow:1;display:flex;flex-direction:column;justify-content:center;align-items:center;overflow:hidden}.inputSection{display:flex;flex-direction:row;align-items:center;width:100%;margin:0 auto}.inputContainer{display:flex;flex-direction:row;align-items:center;width:100%}.inputContainer:first-of-type{justify-content:flex-end}.inputContainer:last-of-type{justify-content:flex-start}.dpTriggerContent{width:100%}@media screen and (max-width: 576px){::part(popover){position:fixed !important;top:0 !important;left:0 !important;width:100vw !important;height:100vh !important;margin-bottom:var(--ds-size-200, 1rem);transform:unset !important}.calendarWrapper{display:flex;height:100dvh;flex-direction:row;justify-content:center}}`;
|
|
1262
1262
|
|
|
1263
|
-
var colorCss$d = css`.util_displayInline{display:inline}.util_displayInlineBlock{display:inline-block}.util_displayBlock{display:block}.util_displayFlex{display:flex}.util_displayHidden{display:none}.util_displayHiddenVisually{position:absolute;overflow:hidden;clip:rect(1px, 1px, 1px, 1px);width:1px;height:1px;padding:0;border:0}[auro-input]::part(wrapper){--ds-auro-input-border-color: transparent;--ds-auro-input-container-color: transparent}.dpTriggerContent [auro-input]:nth-child(2):before{background-color:var(--ds-auro-datepicker-range-input-divider-color)}:host([
|
|
1263
|
+
var colorCss$d = css`.util_displayInline{display:inline}.util_displayInlineBlock{display:inline-block}.util_displayBlock{display:block}.util_displayFlex{display:flex}.util_displayHidden{display:none}.util_displayHiddenVisually{position:absolute;overflow:hidden;clip:rect(1px, 1px, 1px, 1px);width:1px;height:1px;padding:0;border:0}:host label{color:var(--ds-auro-datepicker-label-text-color)}:host .inputDivider{background-color:var(--ds-auro-datepicker-range-input-divider-color)}:host .error{color:var(--ds-auro-datepicker-error-icon-color)}[auro-input]::part(wrapper){--ds-auro-input-border-color: transparent;--ds-auro-input-container-color: transparent}.dpTriggerContent [auro-input]:nth-child(2):before{background-color:var(--ds-auro-datepicker-range-input-divider-color)}:host(:not([ondark])[disabled]){--ds-auro-datepicker-border-color: var(--ds-basic-color-border-subtle, #dddddd);--ds-auro-datepicker-label-text-color: var(--ds-basic-color-texticon-disabled, #d0d0d0);--ds-auro-datepicker-placeholder-text-color: var(--ds-basic-color-texticon-disabled, #d0d0d0)}:host([ondark][disabled]){--ds-auro-datepicker-border-color: var(--ds-advanced-color-button-primary-border-inverse-disabled, rgba(255, 255, 255, 0.75));--ds-auro-datepicker-label-text-color: var(--ds-basic-color-texticon-inverse-disabled, #7e8894);--ds-auro-datepicker-placeholder-text-color: var(--ds-basic-color-texticon-inverse-disabled, #7e8894)}`;
|
|
1264
1264
|
|
|
1265
|
-
var tokensCss$b = css`:host{--ds-auro-datepicker-
|
|
1265
|
+
var tokensCss$b = css`:host(:not([ondark])){--ds-auro-datepicker-range-input-divider-color: var(--ds-basic-color-border-bold, #585e67);--ds-auro-datepicker-error-icon-color: var(--ds-basic-color-status-error, #e31f26);--ds-auro-datepicker-label-text-color: var(--ds-basic-color-texticon-muted, #676767);--ds-auro-calendar-mobile-header-container-color: var(--ds-basic-color-surface-default, #ffffff);--ds-auro-calendar-mobile-header-divider-color: var(--ds-basic-color-border-divider, rgba(0, 0, 0, 0.15));--ds-auro-calendar-mobile-header-text-color: var(--ds-basic-color-texticon-muted, #676767);--ds-auro-calendar-nav-btn-border-color: transparent;--ds-auro-calendar-nav-btn-chevron-color: var(--ds-basic-color-brand-primary, #01426a);--ds-auro-calendar-nav-btn-container-color: transparent;--ds-auro-calendar-month-container-color: var(--ds-basic-color-surface-default, #ffffff);--ds-auro-calendar-month-divider-color: var(--ds-basic-color-border-divider, rgba(0, 0, 0, 0.15));--ds-auro-calendar-month-header-color: var(--ds-basic-color-texticon-default, #2a2a2a);--ds-auro-calendar-cell-border-color: transparent;--ds-auro-calendar-cell-container-color: transparent;--ds-auro-calendar-cell-in-range-color: var(--ds-advanced-color-shared-background-muted, #f7f7f7);--ds-auro-calendar-cell-price-text-color: var(--ds-basic-color-texticon-default, #2a2a2a);--ds-auro-calendar-cell-text-color: var(--ds-basic-color-texticon-default, #2a2a2a)}:host([ondark]){--ds-auro-datepicker-range-input-divider-color: var(--ds-basic-color-texticon-inverse-muted, v.$ds-basic-color-texticon-inverse-muted);--ds-auro-datepicker-error-icon-color: var(--ds-basic-color-status-error-subtle, v.$ds-basic-color-status-error-subtle);--ds-auro-datepicker-label-text-color: var(--ds-basic-color-texticon-inverse-muted, v.$ds-basic-color-texticon-inverse-muted);--ds-auro-calendar-mobile-header-container-color: var(--ds-basic-color-surface-default, #ffffff);--ds-auro-calendar-mobile-header-divider-color: var(--ds-basic-color-border-divider, rgba(0, 0, 0, 0.15));--ds-auro-calendar-mobile-header-text-color: var(--ds-basic-color-texticon-muted, #676767);--ds-auro-calendar-nav-btn-border-color: transparent;--ds-auro-calendar-nav-btn-chevron-color: var(--ds-basic-color-brand-primary, #01426a);--ds-auro-calendar-nav-btn-container-color: transparent;--ds-auro-calendar-month-container-color: var(--ds-basic-color-surface-default, #ffffff);--ds-auro-calendar-month-divider-color: var(--ds-basic-color-border-divider, rgba(0, 0, 0, 0.15));--ds-auro-calendar-month-header-color: var(--ds-basic-color-texticon-default, #2a2a2a);--ds-auro-calendar-cell-border-color: transparent;--ds-auro-calendar-cell-container-color: transparent;--ds-auro-calendar-cell-in-range-color: var(--ds-advanced-color-shared-background-muted, #f7f7f7);--ds-auro-calendar-cell-price-text-color: var(--ds-basic-color-texticon-default, #2a2a2a);--ds-auro-calendar-cell-text-color: var(--ds-basic-color-texticon-default, #2a2a2a)}`;
|
|
1266
1266
|
|
|
1267
1267
|
var shapeSizeCss$2 = css`.wrapper{overflow:hidden}.shape-classic-xl,.shape-classic-lg,.shape-classic-md,.shape-classic-sm,.shape-classic-xs{min-height:58px;max-height:58px;border-style:solid;border-width:1px;border-radius:var(--ds-border-radius, 0.375rem)}.shape-classic-xl.simple,.shape-classic-lg.simple,.shape-classic-md.simple,.shape-classic-sm.simple,.shape-classic-xs.simple{border-width:0px;min-height:60px;max-height:60px;background-color:unset;box-shadow:none}.shape-classic-xl.thin,.shape-classic-lg.thin,.shape-classic-md.thin,.shape-classic-sm.thin,.shape-classic-xs.thin{border-width:1px;min-height:58px;max-height:58px;background-color:unset}.shape-classic-xl.parentBorder,.shape-classic-lg.parentBorder,.shape-classic-md.parentBorder,.shape-classic-sm.parentBorder,.shape-classic-xs.parentBorder{border:0;box-shadow:unset;min-height:56px;max-height:56px}.shape-snowflake-xl,.shape-snowflake-lg,.shape-snowflake-md,.shape-snowflake-sm,.shape-snowflake-xs{min-height:56px;max-height:56px;border-style:solid;border-width:2px;border-color:transparent;border-radius:30px}.shape-snowflake-xl.simple,.shape-snowflake-lg.simple,.shape-snowflake-md.simple,.shape-snowflake-sm.simple,.shape-snowflake-xs.simple{border-width:0px;min-height:60px;max-height:60px;background-color:unset;box-shadow:none}.shape-snowflake-xl.thin,.shape-snowflake-lg.thin,.shape-snowflake-md.thin,.shape-snowflake-sm.thin,.shape-snowflake-xs.thin{border-width:1px;min-height:58px;max-height:58px;background-color:unset}.shape-snowflake-xl.parentBorder,.shape-snowflake-lg.parentBorder,.shape-snowflake-md.parentBorder,.shape-snowflake-sm.parentBorder,.shape-snowflake-xs.parentBorder{border:0;box-shadow:unset;min-height:56px;max-height:56px}.shape-box-xl{min-height:68px;max-height:68px;border-style:solid;border-width:2px;border-color:transparent}.shape-box-xl.simple{border-width:0px;min-height:72px;max-height:72px;background-color:unset;box-shadow:none}.shape-box-xl.thin{border-width:1px;min-height:70px;max-height:70px;background-color:unset}.shape-box-xl.parentBorder{border:0;box-shadow:unset;min-height:68px;max-height:68px}.shape-rounded-lg{min-height:56px;max-height:56px;border-style:solid;border-width:2px;border-color:transparent;border-radius:6px}.shape-rounded-lg.simple{border-width:0px;min-height:56px;max-height:56px;background-color:unset;box-shadow:none}.shape-rounded-lg.thin{border-width:1px;min-height:54px;max-height:54px;background-color:unset}.shape-rounded-lg.parentBorder{border:0;box-shadow:unset;min-height:52px;max-height:52px}.shape-pill-xl{min-height:68px;max-height:68px;border-style:solid;border-width:2px;border-color:transparent;border-radius:36px}.shape-pill-xl.simple{border-width:0px;min-height:72px;max-height:72px;background-color:unset;box-shadow:none}.shape-pill-xl.thin{border-width:1px;min-height:70px;max-height:70px;background-color:unset}.shape-pill-xl.parentBorder{border:0;box-shadow:unset;min-height:68px;max-height:68px}.shape-pill-left-xl{min-height:68px;max-height:68px;border-style:solid;border-width:2px;border-color:transparent;border-radius:36px 0 0 36px}.shape-pill-left-xl.simple{border-width:0px;min-height:72px;max-height:72px;background-color:unset;box-shadow:none}.shape-pill-left-xl.thin{border-width:1px;min-height:70px;max-height:70px;background-color:unset}.shape-pill-left-xl.parentBorder{border:0;box-shadow:unset;min-height:68px;max-height:68px}.shape-pill-right-xl{min-height:68px;max-height:68px;border-style:solid;border-width:2px;border-color:transparent;border-radius:0 36px 36px 0}.shape-pill-right-xl.simple{border-width:0px;min-height:72px;max-height:72px;background-color:unset;box-shadow:none}.shape-pill-right-xl.thin{border-width:1px;min-height:70px;max-height:70px;background-color:unset}.shape-pill-right-xl.parentBorder{border:0;box-shadow:unset;min-height:68px;max-height:68px}.shape-pill-md{min-height:44px;max-height:44px;border-style:solid;border-width:2px;border-color:transparent;border-radius:36px}.shape-pill-md.simple{border-width:0px;min-height:48px;max-height:48px;background-color:unset;box-shadow:none}.shape-pill-md.thin{border-width:1px;min-height:46px;max-height:46px;background-color:unset}.shape-pill-md.parentBorder{border:0;box-shadow:unset;min-height:44px;max-height:44px}.shape-pill-left-md{min-height:44px;max-height:44px;border-style:solid;border-width:2px;border-color:transparent;border-radius:36px 0 0 36px}.shape-pill-left-md.simple{border-width:0px;min-height:48px;max-height:48px;background-color:unset;box-shadow:none}.shape-pill-left-md.thin{border-width:1px;min-height:46px;max-height:46px;background-color:unset}.shape-pill-left-md.parentBorder{border:0;box-shadow:unset;min-height:44px;max-height:44px}.shape-pill-right-md{min-height:44px;max-height:44px;border-style:solid;border-width:2px;border-color:transparent;border-radius:0 36px 36px 0}.shape-pill-right-md.simple{border-width:0px;min-height:48px;max-height:48px;background-color:unset;box-shadow:none}.shape-pill-right-md.thin{border-width:1px;min-height:46px;max-height:46px;background-color:unset}.shape-pill-right-md.parentBorder{border:0;box-shadow:unset;min-height:44px;max-height:44px}`;
|
|
1268
1268
|
|
|
1269
|
+
var classicLayoutStyle = css`.util_displayInline{display:inline}.util_displayInlineBlock{display:inline-block}.util_displayBlock{display:block}.util_displayFlex{display:flex}.util_displayHidden{display:none}.util_displayHiddenVisually{position:absolute;overflow:hidden;clip:rect(1px, 1px, 1px, 1px);width:1px;height:1px;padding:0;border:0}:host([layout*=classic]) .accents{display:none}:host([layout*=classic]) [auro-input]{width:100%}:host([layout*=classic]) [auro-input]::part(helpText){display:none}:host([layout*=classic]) [auro-input]::part(wrapper){border-width:0;box-shadow:none}:host([layout*=classic]) [auro-input].dateTo{margin-left:var(--ds-size-150, 0.75rem)}:host([layout*=classic]) [auro-input].dateTo::part(accent-left){display:none}:host([layout*=classic]) .inputDivider{width:1px;height:2rem}`;
|
|
1270
|
+
|
|
1269
1271
|
var classicLayoutColor = css``;
|
|
1270
1272
|
|
|
1271
|
-
var snowflakeStyle = css
|
|
1273
|
+
var snowflakeStyle = css`:host([layout*=snowflake]) [auro-input]{flex:1;text-align:center}:host([layout*=snowflake]) [auro-input]::part(label),:host([layout*=snowflake]) [auro-input]::part(accent-left),:host([layout*=snowflake]) [auro-input]::part(accent-right){display:none}:host([layout*=snowflake]) [auro-input]::part(input){padding-bottom:unset;text-align:center;font-size:var(--ds-text-body-size-lg, 1.125rem);line-height:var(--ds-text-body-height-lg, 1.625rem);transition:unset}:host([layout*=snowflake]) [auro-input]::part(wrapper){min-height:unset;max-height:unset;box-shadow:unset}:host([layout*=snowflake]) [auro-input]::part(wrapper) .mainContent{padding-bottom:unset}:host([layout*=snowflake]) [auro-input]::part(inputHelpText){display:none}:host([layout*=snowflake]) [auro-input]::part(displayValue){justify-content:center;font-size:var(--ds-text-body-size-lg, 1.125rem);line-height:var(--ds-text-body-height-lg, 1.625rem)}:host([layout*=snowflake]) [auro-dropdown]::part(trigger){width:100%}:host([layout*=snowflake]) .dpTriggerContent{width:100%}:host([layout*=snowflake]) .wrapper{height:60px;width:calc(100% - 48px);display:flex;flex-direction:row;justify-content:space-between;padding-left:24px;padding-right:24px}:host([layout*=snowflake]) label{font-size:var(--ds-text-body-size-lg, 1.125rem);line-height:var(--ds-text-body-height-lg, 1.625rem);font-weight:450;letter-spacing:0;white-space:nowrap;text-overflow:ellipsis;overflow:hidden}:host([layout*=snowflake]) label.hasFocus,:host([layout*=snowflake]) label.hasValue{font-size:var(--ds-text-body-size-xs, 0.75rem);line-height:var(--ds-text-body-height-xs, 1rem)}:host([layout*=snowflake]) .inputDivider{height:18px;margin:4px 12px;width:2px}:host([layout*=snowflake]) .inputSection:not(:is(.disabled,.hasFocus,.hasValue)) .inputDivider{display:none}:host([layout*=snowflake][disabled]){pointer-events:none}`;
|
|
1272
1274
|
|
|
1273
|
-
var snowflakeColors = css`:host([layout=snowflake])
|
|
1275
|
+
var snowflakeColors = css`:host([layout=snowflake]) [auro-dropdown]:not(:is([error],.hasFocus)){--ds-auro-dropdown-trigger-border-color: transparent}`;
|
|
1274
1276
|
|
|
1275
1277
|
var styleCss$d = css`:host{--calendar-width: 336px;--mobile-footer-height: 150px;--mobile-header-height: 68px;height:100vh;height:100dvh}.calendars{display:flex;flex-direction:row}.calendarNavButtons{position:absolute;top:var(--ds-size-200, 1rem);right:var(--ds-size-50, 0.25rem);left:var(--ds-size-50, 0.25rem)}.calendarNavBtn{display:flex;width:var(--ds-size-500, 2.5rem);height:var(--ds-size-500, 2.5rem);align-items:center;justify-content:center;border-width:1px;border-style:solid;border-radius:50%;cursor:pointer}.prevMonth,.nextMonth{position:absolute;top:0}.prevMonth{left:0}.nextMonth{right:0}.headerActions{padding:0 var(--ds-size-200, 1rem)}.mobileHeader{width:100%;height:var(--mobile-header-height);z-index:1;align-items:center;flex-direction:row}.headerDateFrom{display:flex;height:var(--mobile-header-height);flex:1;flex-direction:column;justify-content:center;padding:0 var(--ds-size-150, 0.75rem) 0 var(--ds-size-200, 1rem)}.mobileDateLabel{font-size:12px;font-weight:450;letter-spacing:0;line-height:16px}.headerDateTo{height:calc(var(--mobile-header-height) - var(--ds-size-300, 1.5rem));padding:var(--ds-size-300, 1.5rem) var(--ds-size-100, 0.5rem) 0 var(--ds-size-200, 1rem)}:host(:not([noRange])) .headerDateTo{position:relative;display:flex;flex:1;flex-direction:column;justify-content:center}:host(:not([noRange])) .headerDateTo:after{position:absolute;top:calc(50% + 10px);left:0;display:block;width:1px;height:var(--ds-size-300, 1.5rem);content:"";transform:translateY(-50%)}.mobileFooter{display:none;width:100%;align-items:flex-end;flex-direction:column;justify-content:flex-end}.mobileFooterActions{position:relative;bottom:0;left:50%;display:none;width:calc(100% - var(--ds-size-200, 1rem)*2);align-items:flex-end;flex-direction:column;justify-content:flex-end;padding:var(--ds-size-150) calc(var(--ds-size-200, 1rem));transform:translateX(-50%)}.mobileFooterActions auro-button{width:100%}:host([isfullscreen]){width:100%;max-height:100dvh;overflow:hidden}:host([isfullscreen]) .prevMonth,:host([isfullscreen]) .nextMonth{display:none}:host([isfullscreen]) .mobileHeader,:host([isfullscreen]) .mobileFooter,:host([isfullscreen]) .mobileFooterActions{display:flex}:host([isfullscreen]) .calendarWrapper{display:flex;flex-direction:column}:host([isfullscreen]) .calendars{display:flex;flex-direction:column;flex:1;align-items:center;width:100%;overscroll-behavior:contain}:host([isfullscreen]) .calendars:after{display:block;width:100%;height:var(--mobile-footer-height);content:""}`;
|
|
1276
1278
|
|
|
@@ -12698,7 +12700,7 @@ class AuroBibtemplate extends LitElement {
|
|
|
12698
12700
|
/**
|
|
12699
12701
|
* @private
|
|
12700
12702
|
*/
|
|
12701
|
-
this.buttonTag = versioning.generateTag('auro-formkit-
|
|
12703
|
+
this.buttonTag = versioning.generateTag('auro-formkit-bibtemplate-button', buttonVersion$2, AuroButton$2);
|
|
12702
12704
|
}
|
|
12703
12705
|
|
|
12704
12706
|
static get styles() {
|
|
@@ -28215,6 +28217,7 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
28215
28217
|
shapeSizeCss$2,
|
|
28216
28218
|
|
|
28217
28219
|
// layouts
|
|
28220
|
+
classicLayoutStyle,
|
|
28218
28221
|
classicLayoutColor,
|
|
28219
28222
|
snowflakeStyle,
|
|
28220
28223
|
snowflakeColors
|
|
@@ -28282,11 +28285,7 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
28282
28285
|
* @param {String} focusInput - Pass in `endDate` to focus on the return input. No parameter is needed to focus on the depart input.
|
|
28283
28286
|
* @returns {void}
|
|
28284
28287
|
*/
|
|
28285
|
-
focus(focusInput) {
|
|
28286
|
-
if (this.disabled) {
|
|
28287
|
-
return;
|
|
28288
|
-
}
|
|
28289
|
-
|
|
28288
|
+
focus(focusInput = '') {
|
|
28290
28289
|
this.range && focusInput === 'endDate' ? this.inputList[1].focus() : this.inputList[0].focus();
|
|
28291
28290
|
}
|
|
28292
28291
|
|
|
@@ -28489,9 +28488,11 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
28489
28488
|
configureDatepicker() {
|
|
28490
28489
|
this.addEventListener('focusin', () => {
|
|
28491
28490
|
this.touched = true;
|
|
28491
|
+
this.hasFocus = true;
|
|
28492
28492
|
});
|
|
28493
28493
|
|
|
28494
28494
|
this.addEventListener('focusout', (evt) => {
|
|
28495
|
+
this.hasFocus = false;
|
|
28495
28496
|
if (!this.noValidate && !evt.detail.expanded && this.touched) {
|
|
28496
28497
|
if (!this.contains(document.activeElement)) {
|
|
28497
28498
|
this.validation.validate(this.inputList[0]);
|
|
@@ -28577,9 +28578,6 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
28577
28578
|
const convertedDate = this.convertWcTimeToDate(time);
|
|
28578
28579
|
const newDate = this.util.toCustomFormat(convertedDate, this.format);
|
|
28579
28580
|
|
|
28580
|
-
console.log(newDate);
|
|
28581
|
-
console.log(this.util.validDateStr(newDate, this.format));
|
|
28582
|
-
|
|
28583
28581
|
if (this.util.validDateStr(newDate, this.format)) {
|
|
28584
28582
|
if (this.inputList.length > 1) {
|
|
28585
28583
|
if (!this.value || !this.util.validDateStr(this.value, this.format)) {
|
|
@@ -28618,7 +28616,7 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
28618
28616
|
handleKeydownReset(event) {
|
|
28619
28617
|
if (event.key === 'Enter' || event.key === ' ') {
|
|
28620
28618
|
this.resetValues();
|
|
28621
|
-
this.
|
|
28619
|
+
this.focus();
|
|
28622
28620
|
}
|
|
28623
28621
|
}
|
|
28624
28622
|
|
|
@@ -28656,22 +28654,10 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
28656
28654
|
this.validation.validate(this, force);
|
|
28657
28655
|
}
|
|
28658
28656
|
|
|
28659
|
-
|
|
28660
|
-
|
|
28661
|
-
|
|
28662
|
-
|
|
28663
|
-
|
|
28664
|
-
this.hasFocus = true;
|
|
28665
|
-
this.dropdown.show();
|
|
28666
|
-
|
|
28667
|
-
// shadowroot active element is null if we focus the datepicker itself
|
|
28668
|
-
if (this.shadowRoot.activeElement === null) {
|
|
28669
|
-
// If the shadowRoot.activeElement is null, we can assume that the datepicker itself has focus
|
|
28670
|
-
// and we should focus the first input in the inputList
|
|
28671
|
-
this.inputList[0].focus();
|
|
28672
|
-
}
|
|
28673
|
-
}
|
|
28674
|
-
|
|
28657
|
+
/**
|
|
28658
|
+
* Private method for interacting with the `hasValue` property.
|
|
28659
|
+
* @private
|
|
28660
|
+
*/
|
|
28675
28661
|
setHasValue() {
|
|
28676
28662
|
if (!this.range) {
|
|
28677
28663
|
this.hasValue = this.value && this.value.length > 0;
|
|
@@ -28691,6 +28677,17 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
28691
28677
|
this.monthFirst = this.format.indexOf('mm') < this.format.indexOf('yyyy');
|
|
28692
28678
|
}
|
|
28693
28679
|
|
|
28680
|
+
if (changedProperties.has('disabled')) {
|
|
28681
|
+
if (this.disabled) {
|
|
28682
|
+
this.previousTabIndex = this.getAttribute('tabindex');
|
|
28683
|
+
this.setAttribute('tabindex', '-1');
|
|
28684
|
+
} else if (!this.disabled && this.previousTabIndex > -1) {
|
|
28685
|
+
this.tabIndex = this.previousTabIndex;
|
|
28686
|
+
} else {
|
|
28687
|
+
this.removeAttribute('tabindex');
|
|
28688
|
+
}
|
|
28689
|
+
}
|
|
28690
|
+
|
|
28694
28691
|
if (changedProperties.has('calendarFocusDate')) {
|
|
28695
28692
|
this.formattedFocusDate = this.util.toNorthAmericanFormat(this.calendarFocusDate, this.format);
|
|
28696
28693
|
|
|
@@ -28856,6 +28853,8 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
28856
28853
|
this.calendarFocusDate = this.minDate;
|
|
28857
28854
|
}
|
|
28858
28855
|
}
|
|
28856
|
+
|
|
28857
|
+
this.calendar.requestUpdate();
|
|
28859
28858
|
}
|
|
28860
28859
|
|
|
28861
28860
|
// This resets the datepicker when the maxDate is set to a new value that is
|
|
@@ -28887,6 +28886,8 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
28887
28886
|
}
|
|
28888
28887
|
}
|
|
28889
28888
|
}
|
|
28889
|
+
|
|
28890
|
+
this.calendar.requestUpdate();
|
|
28890
28891
|
}
|
|
28891
28892
|
|
|
28892
28893
|
if (changedProperties.has('centralDate')) {
|
|
@@ -28928,11 +28929,7 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
28928
28929
|
|
|
28929
28930
|
// setup focus/blur event listeners
|
|
28930
28931
|
this.addEventListener('focus', () => {
|
|
28931
|
-
this.
|
|
28932
|
-
}, true);
|
|
28933
|
-
|
|
28934
|
-
this.addEventListener('blur', () => {
|
|
28935
|
-
this.hasFocus = false;
|
|
28932
|
+
this.focus();
|
|
28936
28933
|
}, true);
|
|
28937
28934
|
}
|
|
28938
28935
|
|
|
@@ -28987,17 +28984,63 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
28987
28984
|
}
|
|
28988
28985
|
|
|
28989
28986
|
/**
|
|
28987
|
+
* Renders the snowflake layout for the datepicker.
|
|
28990
28988
|
* @private
|
|
28989
|
+
* @returns {import("lit").TemplateResult}
|
|
28990
|
+
*/
|
|
28991
|
+
renderClassicLayout() {
|
|
28992
|
+
const accentsClassMap = {
|
|
28993
|
+
error: this.hasError
|
|
28994
|
+
};
|
|
28995
|
+
|
|
28996
|
+
const inputSectionClassMap = {
|
|
28997
|
+
inputSection: true,
|
|
28998
|
+
|
|
28999
|
+
hasValue: this.hasValue,
|
|
29000
|
+
hasFocus: this.hasFocus,
|
|
29001
|
+
};
|
|
29002
|
+
|
|
29003
|
+
const labelClassMap = {
|
|
29004
|
+
hasValue: this.hasValue,
|
|
29005
|
+
hasFocus: this.hasFocus,
|
|
29006
|
+
};
|
|
29007
|
+
|
|
29008
|
+
return html$1`
|
|
29009
|
+
<div
|
|
29010
|
+
class="wrapper trigger"
|
|
29011
|
+
part="wrapper">
|
|
29012
|
+
<div class="accents left">
|
|
29013
|
+
${this.renderHtmlIconCalendar()}
|
|
29014
|
+
</div>
|
|
29015
|
+
<div class="mainContent">
|
|
29016
|
+
<label class="${classMap(labelClassMap)}" part="mainLabel">
|
|
29017
|
+
<slot name="label"></slot>
|
|
29018
|
+
</label>
|
|
29019
|
+
<div class="${classMap(inputSectionClassMap)}" part="inputSection">
|
|
29020
|
+
${this.renderHtmlInputs()}
|
|
29021
|
+
</div>
|
|
29022
|
+
</div>
|
|
29023
|
+
<div class="accents right ${classMap(accentsClassMap)}">
|
|
29024
|
+
${this.hasError
|
|
29025
|
+
? this.renderHtmlIconError()
|
|
29026
|
+
: this.renderHtmlActionClear()
|
|
29027
|
+
}
|
|
29028
|
+
</div>
|
|
29029
|
+
</div>
|
|
29030
|
+
`;
|
|
29031
|
+
}
|
|
29032
|
+
|
|
29033
|
+
/**
|
|
29034
|
+
* Renders the layout based on the `layout` attribute.
|
|
29035
|
+
* @private
|
|
29036
|
+
* @returns {import('lit').TemplateResult}
|
|
28991
29037
|
*/
|
|
28992
29038
|
renderLayoutFromAttributes() {
|
|
28993
29039
|
switch (this.layout) {
|
|
28994
29040
|
case 'snowflake':
|
|
28995
29041
|
return this.renderSnowflakeLayout();
|
|
28996
29042
|
default:
|
|
28997
|
-
|
|
28998
|
-
return html$1`
|
|
28999
|
-
<p>Please implement layout "${this.layout}" for datepicker</p>
|
|
29000
|
-
`;
|
|
29043
|
+
return this.renderClassicLayout();
|
|
29001
29044
|
}
|
|
29002
29045
|
}
|
|
29003
29046
|
|
|
@@ -29008,7 +29051,7 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
29008
29051
|
* Returns formatted date like Apr 21 or Dec 25.
|
|
29009
29052
|
* @private
|
|
29010
29053
|
* @param {string} date - Date format should be in a format Date constructor accepts, like '2023-04-21' or '2023/04/21'.
|
|
29011
|
-
* @
|
|
29054
|
+
* @returns {string}
|
|
29012
29055
|
*/
|
|
29013
29056
|
formatShortDate(date) {
|
|
29014
29057
|
// should render like Apr 21
|
|
@@ -29023,8 +29066,8 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
29023
29066
|
/**
|
|
29024
29067
|
* Format and render the provided date value.
|
|
29025
29068
|
* @private
|
|
29026
|
-
* @param dateValue
|
|
29027
|
-
* @
|
|
29069
|
+
* @param {string} dateValue - The date value to format and render.
|
|
29070
|
+
* @returns {import('lit').TemplateResult}
|
|
29028
29071
|
*/
|
|
29029
29072
|
renderDisplayTextDate(dateValue) {
|
|
29030
29073
|
return html$1`
|
|
@@ -29039,9 +29082,15 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
29039
29082
|
`;
|
|
29040
29083
|
}
|
|
29041
29084
|
|
|
29085
|
+
/**
|
|
29086
|
+
* Renders the HTML inputs for the datepicker.
|
|
29087
|
+
* @private
|
|
29088
|
+
* @returns {import('lit').TemplateResult}
|
|
29089
|
+
*/
|
|
29042
29090
|
renderHtmlInputs() {
|
|
29043
29091
|
const inputClasses = {
|
|
29044
|
-
"util_displayHiddenVisually": !this.hasValue && !this.hasFocus
|
|
29092
|
+
"util_displayHiddenVisually": !this.hasValue && !this.hasFocus && this.layout !== "classic",
|
|
29093
|
+
"parentBorder": this.layout === "classic"
|
|
29045
29094
|
};
|
|
29046
29095
|
|
|
29047
29096
|
return html$1`
|
|
@@ -29055,14 +29104,12 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
29055
29104
|
.min="${this.minDate}"
|
|
29056
29105
|
id="${this.generateRandomString(12)}"
|
|
29057
29106
|
.placeholder="${this.placeholder}"
|
|
29058
|
-
|
|
29059
|
-
|
|
29107
|
+
.size="${this.size}"
|
|
29108
|
+
.shape="${this.shape}"
|
|
29060
29109
|
noValidate
|
|
29061
29110
|
class="dateFrom ${classMap(inputClasses)}"
|
|
29062
29111
|
type="date"
|
|
29063
29112
|
part="input"
|
|
29064
|
-
shape="box"
|
|
29065
|
-
size="xl"
|
|
29066
29113
|
setCustomValidity="${this.setCustomValidity}"
|
|
29067
29114
|
setCustomValidityCustomError="${this.setCustomValidityCustomError}"
|
|
29068
29115
|
setCustomValidityValueMissing="${this.setCustomValidityValueMissing}"
|
|
@@ -29070,9 +29117,14 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
29070
29117
|
setCustomValidityRangeUnderflow="${this.setCustomValidityRangeUnderflow}"
|
|
29071
29118
|
inputmode="${ifDefined(this.inputmode)}"
|
|
29072
29119
|
>
|
|
29073
|
-
|
|
29074
|
-
$
|
|
29075
|
-
|
|
29120
|
+
${this.layout !== "classic"
|
|
29121
|
+
? html$1`
|
|
29122
|
+
<span slot="displayValue">
|
|
29123
|
+
${this.renderDisplayTextDate(this.value)}
|
|
29124
|
+
</span>
|
|
29125
|
+
`
|
|
29126
|
+
: undefined
|
|
29127
|
+
}
|
|
29076
29128
|
<span slot="label"><slot name="fromLabel"></slot></span>
|
|
29077
29129
|
</${this.inputTag}>
|
|
29078
29130
|
</div>
|
|
@@ -29092,7 +29144,6 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
29092
29144
|
.min="${this.minDate}"
|
|
29093
29145
|
.placeholder="${this.placeholderEndDate || this.placeholder}"
|
|
29094
29146
|
id="${this.generateRandomString(12)}"
|
|
29095
|
-
bordered
|
|
29096
29147
|
class="dateTo ${classMap(inputClasses)}"
|
|
29097
29148
|
noValidate
|
|
29098
29149
|
type="date"
|
|
@@ -29103,9 +29154,14 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
29103
29154
|
setCustomValidityRangeUnderflow="${this.setCustomValidityRangeUnderflow}"
|
|
29104
29155
|
?disabled="${this.disabled}"
|
|
29105
29156
|
part="input">
|
|
29106
|
-
|
|
29107
|
-
$
|
|
29108
|
-
|
|
29157
|
+
${this.layout !== "classic"
|
|
29158
|
+
? html$1`
|
|
29159
|
+
<span slot="displayValue">
|
|
29160
|
+
${this.renderDisplayTextDate(this.valueEnd)}
|
|
29161
|
+
</span>
|
|
29162
|
+
`
|
|
29163
|
+
: undefined
|
|
29164
|
+
}
|
|
29109
29165
|
<span slot="label"><slot name="toLabel"></slot></span>
|
|
29110
29166
|
</${this.inputTag}>
|
|
29111
29167
|
</div>
|
|
@@ -29119,6 +29175,11 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
29119
29175
|
// icons/actions
|
|
29120
29176
|
// ------------------------------------
|
|
29121
29177
|
|
|
29178
|
+
/**
|
|
29179
|
+
* Renders the clear action button.
|
|
29180
|
+
* @private
|
|
29181
|
+
* @returns {import('lit').TemplateResult}
|
|
29182
|
+
*/
|
|
29122
29183
|
renderHtmlActionClear() {
|
|
29123
29184
|
const clearActionClassMap = {
|
|
29124
29185
|
'notification': true,
|
|
@@ -29148,6 +29209,11 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
29148
29209
|
`;
|
|
29149
29210
|
}
|
|
29150
29211
|
|
|
29212
|
+
/**
|
|
29213
|
+
* Renders the error icon.
|
|
29214
|
+
* @private
|
|
29215
|
+
* @returns {import('lit').TemplateResult}
|
|
29216
|
+
*/
|
|
29151
29217
|
renderHtmlIconError() {
|
|
29152
29218
|
const clearActionClassMap = {
|
|
29153
29219
|
'notification': true,
|
|
@@ -29167,6 +29233,11 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
29167
29233
|
`;
|
|
29168
29234
|
}
|
|
29169
29235
|
|
|
29236
|
+
/**
|
|
29237
|
+
* Renders the calendar icon.
|
|
29238
|
+
* @private
|
|
29239
|
+
* @returns {import('lit').TemplateResult}
|
|
29240
|
+
*/
|
|
29170
29241
|
renderHtmlIconCalendar() {
|
|
29171
29242
|
return html$1`
|
|
29172
29243
|
<${this.iconTag}
|
|
@@ -29182,7 +29253,7 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
29182
29253
|
/**
|
|
29183
29254
|
* Returns HTML for the help text and error message.
|
|
29184
29255
|
* @private
|
|
29185
|
-
* @returns {
|
|
29256
|
+
* @returns {import('lit').TemplateResult} - Returns HTML for the help text and error message.
|
|
29186
29257
|
*/
|
|
29187
29258
|
renderHtmlHelpText() {
|
|
29188
29259
|
return html$1`
|
|
@@ -29205,6 +29276,33 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
29205
29276
|
`;
|
|
29206
29277
|
}
|
|
29207
29278
|
|
|
29279
|
+
/**
|
|
29280
|
+
* Separate method for rendering the calendar.
|
|
29281
|
+
* @private
|
|
29282
|
+
* @returns {import('lit').TemplateResult}
|
|
29283
|
+
*/
|
|
29284
|
+
renderCalendar() {
|
|
29285
|
+
return html$1`
|
|
29286
|
+
<auro-formkit-calendar
|
|
29287
|
+
?largeFullscreenHeadline="${this.largeFullscreenHeadline}"
|
|
29288
|
+
?noRange="${!this.range}"
|
|
29289
|
+
.format="${this.format}"
|
|
29290
|
+
.monthFirst="${this.monthFirst}"
|
|
29291
|
+
.min="${this.convertToWcValidTime(new Date(this.formattedMinDate))}"
|
|
29292
|
+
.max="${this.convertToWcValidTime(new Date(this.formattedMaxDate))}"
|
|
29293
|
+
.maxDate="${this.maxDate}"
|
|
29294
|
+
.minDate="${this.minDate}"
|
|
29295
|
+
.monthNames="${this.monthNames}"
|
|
29296
|
+
part="calendar"
|
|
29297
|
+
>
|
|
29298
|
+
<slot slot="bib.fullscreen.headline" name="bib.fullscreen.headline" @slotchange="${this.handleSlotToSlot}"></slot>
|
|
29299
|
+
<slot slot="bib.fullscreen.dateLabel" name="bib.fullscreen.dateLabel" @slotchange="${this.handleSlotToSlot}"></slot>
|
|
29300
|
+
<span slot="bib.fullscreen.fromStr">${this.value || html$1`<span class="placeholderDate">${this.format.toUpperCase()}</span>`}</span>
|
|
29301
|
+
${this.range ? html$1`<span slot="mobileDateToStr">${this.valueEnd || html$1`<span class="placeholderDate">${this.format.toUpperCase()}</span>`}</span>` : undefined}
|
|
29302
|
+
</auro-formkit-calendar>
|
|
29303
|
+
`;
|
|
29304
|
+
}
|
|
29305
|
+
|
|
29208
29306
|
// function that renders the HTML and CSS into the scope of the component
|
|
29209
29307
|
render() {
|
|
29210
29308
|
const dropdownElementClassMap = {
|
|
@@ -29226,37 +29324,18 @@ class AuroDatePicker extends AuroElement$1 {
|
|
|
29226
29324
|
.placement="${this.placement}"
|
|
29227
29325
|
.shape="${this.shape}"
|
|
29228
29326
|
.size="${this.size}"
|
|
29229
|
-
bordered
|
|
29230
29327
|
class="${classMap(dropdownElementClassMap)}"
|
|
29231
29328
|
disableEventShow
|
|
29232
29329
|
disableFocusTrap
|
|
29233
|
-
fluid
|
|
29234
29330
|
for="dropdownMenu"
|
|
29235
29331
|
part="dropdown"
|
|
29236
|
-
rounded
|
|
29237
29332
|
>
|
|
29238
29333
|
<div slot="trigger" class="dpTriggerContent" part="trigger">
|
|
29239
29334
|
${this.renderLayoutFromAttributes()}
|
|
29240
29335
|
</div>
|
|
29241
29336
|
|
|
29242
29337
|
<div class="calendarWrapper" part="calendarWrapper">
|
|
29243
|
-
|
|
29244
|
-
?largeFullscreenHeadline="${this.largeFullscreenHeadline}"
|
|
29245
|
-
?noRange="${!this.range}"
|
|
29246
|
-
.format="${this.format}"
|
|
29247
|
-
.monthFirst="${this.monthFirst}"
|
|
29248
|
-
.min="${this.convertToWcValidTime(new Date(this.formattedMinDate))}"
|
|
29249
|
-
.max="${this.convertToWcValidTime(new Date(this.formattedMaxDate))}"
|
|
29250
|
-
.maxDate="${this.maxDate}"
|
|
29251
|
-
.minDate="${this.minDate}"
|
|
29252
|
-
.monthNames="${this.monthNames}"
|
|
29253
|
-
part="calendar"
|
|
29254
|
-
>
|
|
29255
|
-
<slot slot="bib.fullscreen.headline" name="bib.fullscreen.headline" @slotchange="${this.handleSlotToSlot}"></slot>
|
|
29256
|
-
<slot slot="bib.fullscreen.dateLabel" name="bib.fullscreen.dateLabel" @slotchange="${this.handleSlotToSlot}"></slot>
|
|
29257
|
-
<span slot="bib.fullscreen.fromStr">${this.value || html$1`<span class="placeholderDate">${this.format.toUpperCase()}</span>`}</span>
|
|
29258
|
-
${this.range ? html$1`<span slot="mobileDateToStr">${this.valueEnd || html$1`<span class="placeholderDate">${this.format.toUpperCase()}</span>`}</span>` : undefined}
|
|
29259
|
-
</auro-formkit-calendar>
|
|
29338
|
+
${this.renderCalendar()}
|
|
29260
29339
|
</div>
|
|
29261
29340
|
<div slot="helpText" part="helpTextSpan">
|
|
29262
29341
|
${this.renderHtmlHelpText()}
|