@cloudscape-design/components 3.0.28 → 3.0.31
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/app-layout/visual-refresh/styles.css.js +59 -59
- package/app-layout/visual-refresh/styles.scoped.css +146 -146
- package/app-layout/visual-refresh/styles.selectors.js +59 -59
- package/autosuggest/autosuggest-option.d.ts +1 -0
- package/autosuggest/autosuggest-option.d.ts.map +1 -1
- package/autosuggest/autosuggest-option.js +2 -2
- package/autosuggest/autosuggest-option.js.map +1 -1
- package/autosuggest/controller.d.ts +2 -5
- package/autosuggest/controller.d.ts.map +1 -1
- package/autosuggest/controller.js +5 -49
- package/autosuggest/controller.js.map +1 -1
- package/autosuggest/internal.d.ts.map +1 -1
- package/autosuggest/internal.js +19 -25
- package/autosuggest/internal.js.map +1 -1
- package/autosuggest/options-controller.d.ts +25 -0
- package/autosuggest/options-controller.d.ts.map +1 -0
- package/autosuggest/options-controller.js +64 -0
- package/autosuggest/options-controller.js.map +1 -0
- package/autosuggest/options-list.d.ts +3 -2
- package/autosuggest/options-list.d.ts.map +1 -1
- package/autosuggest/options-list.js +8 -7
- package/autosuggest/options-list.js.map +1 -1
- package/autosuggest/plain-list.d.ts +2 -2
- package/autosuggest/plain-list.d.ts.map +1 -1
- package/autosuggest/plain-list.js +4 -4
- package/autosuggest/plain-list.js.map +1 -1
- package/autosuggest/virtual-list.d.ts +1 -1
- package/autosuggest/virtual-list.d.ts.map +1 -1
- package/autosuggest/virtual-list.js +4 -4
- package/autosuggest/virtual-list.js.map +1 -1
- package/breadcrumb-group/internal.d.ts.map +1 -1
- package/breadcrumb-group/internal.js +4 -4
- package/breadcrumb-group/internal.js.map +1 -1
- package/button-dropdown/category-elements/category-element.d.ts +1 -1
- package/button-dropdown/category-elements/category-element.d.ts.map +1 -1
- package/button-dropdown/category-elements/category-element.js +2 -2
- package/button-dropdown/category-elements/category-element.js.map +1 -1
- package/button-dropdown/category-elements/expandable-category-element.d.ts +1 -1
- package/button-dropdown/category-elements/expandable-category-element.d.ts.map +1 -1
- package/button-dropdown/category-elements/expandable-category-element.js +4 -2
- package/button-dropdown/category-elements/expandable-category-element.js.map +1 -1
- package/button-dropdown/category-elements/mobile-expandable-category-element.d.ts +1 -1
- package/button-dropdown/category-elements/mobile-expandable-category-element.d.ts.map +1 -1
- package/button-dropdown/category-elements/mobile-expandable-category-element.js +4 -2
- package/button-dropdown/category-elements/mobile-expandable-category-element.js.map +1 -1
- package/button-dropdown/category-elements/styles.css.js +13 -12
- package/button-dropdown/category-elements/styles.scoped.css +26 -22
- package/button-dropdown/category-elements/styles.selectors.js +13 -12
- package/button-dropdown/interfaces.d.ts +3 -1
- package/button-dropdown/interfaces.d.ts.map +1 -1
- package/button-dropdown/interfaces.js.map +1 -1
- package/button-dropdown/internal.d.ts.map +1 -1
- package/button-dropdown/internal.js +6 -11
- package/button-dropdown/internal.js.map +1 -1
- package/button-dropdown/item-element/index.d.ts +1 -1
- package/button-dropdown/item-element/index.d.ts.map +1 -1
- package/button-dropdown/item-element/index.js +2 -1
- package/button-dropdown/item-element/index.js.map +1 -1
- package/button-dropdown/item-element/styles.css.js +14 -13
- package/button-dropdown/item-element/styles.scoped.css +21 -17
- package/button-dropdown/item-element/styles.selectors.js +14 -13
- package/button-dropdown/items-list.d.ts +1 -1
- package/button-dropdown/items-list.d.ts.map +1 -1
- package/button-dropdown/items-list.js +4 -4
- package/button-dropdown/items-list.js.map +1 -1
- package/button-dropdown/utils/use-button-dropdown.d.ts +2 -2
- package/button-dropdown/utils/use-button-dropdown.d.ts.map +1 -1
- package/button-dropdown/utils/use-button-dropdown.js +7 -5
- package/button-dropdown/utils/use-button-dropdown.js.map +1 -1
- package/button-dropdown/utils/use-highlighted-menu.d.ts +1 -0
- package/button-dropdown/utils/use-highlighted-menu.d.ts.map +1 -1
- package/button-dropdown/utils/use-highlighted-menu.js +11 -3
- package/button-dropdown/utils/use-highlighted-menu.js.map +1 -1
- package/checkbox/styles.css.js +3 -3
- package/checkbox/styles.scoped.css +6 -6
- package/checkbox/styles.selectors.js +3 -3
- package/date-picker/calendar/index.d.ts.map +1 -1
- package/date-picker/calendar/index.js +2 -1
- package/date-picker/calendar/index.js.map +1 -1
- package/date-picker/calendar/utils/memoized-date.d.ts +2 -0
- package/date-picker/calendar/utils/memoized-date.d.ts.map +1 -0
- package/date-picker/calendar/utils/memoized-date.js +13 -0
- package/date-picker/calendar/utils/memoized-date.js.map +1 -0
- package/date-picker/embedded.js +1 -1
- package/date-picker/embedded.js.map +1 -1
- package/date-picker/index.js +1 -1
- package/date-picker/index.js.map +1 -1
- package/date-picker/use-date-picker.d.ts.map +1 -1
- package/date-picker/use-date-picker.js +1 -1
- package/date-picker/use-date-picker.js.map +1 -1
- package/date-range-picker/calendar/grids/day/index.js +1 -1
- package/date-range-picker/calendar/grids/day/index.js.map +1 -1
- package/date-range-picker/calendar/index.d.ts.map +1 -1
- package/date-range-picker/calendar/index.js +3 -3
- package/date-range-picker/calendar/index.js.map +1 -1
- package/date-range-picker/dropdown.d.ts +1 -0
- package/date-range-picker/dropdown.d.ts.map +1 -1
- package/date-range-picker/dropdown.js +18 -30
- package/date-range-picker/dropdown.js.map +1 -1
- package/date-range-picker/embedded.d.ts +7 -0
- package/date-range-picker/embedded.d.ts.map +1 -0
- package/date-range-picker/embedded.js +46 -0
- package/date-range-picker/embedded.js.map +1 -0
- package/date-range-picker/index.d.ts.map +1 -1
- package/date-range-picker/index.js +5 -18
- package/date-range-picker/index.js.map +1 -1
- package/date-range-picker/interfaces.d.ts +46 -44
- package/date-range-picker/interfaces.d.ts.map +1 -1
- package/date-range-picker/interfaces.js.map +1 -1
- package/date-range-picker/time-offset.d.ts +0 -7
- package/date-range-picker/time-offset.d.ts.map +1 -1
- package/date-range-picker/time-offset.js +4 -60
- package/date-range-picker/time-offset.js.map +1 -1
- package/date-range-picker/use-date-range-picker.d.ts +29 -0
- package/date-range-picker/use-date-range-picker.d.ts.map +1 -0
- package/date-range-picker/use-date-range-picker.js +58 -0
- package/date-range-picker/use-date-range-picker.js.map +1 -0
- package/icon/icons.js +1 -1
- package/icon/interfaces.d.ts +1 -1
- package/icon/interfaces.d.ts.map +1 -1
- package/icon/interfaces.js.map +1 -1
- package/input/styles.css.js +13 -13
- package/input/styles.scoped.css +35 -37
- package/input/styles.selectors.js +13 -13
- package/internal/components/abstract-switch/index.d.ts.map +1 -1
- package/internal/components/abstract-switch/index.js +5 -5
- package/internal/components/abstract-switch/index.js.map +1 -1
- package/internal/components/abstract-switch/styles.css.js +11 -11
- package/internal/components/abstract-switch/styles.scoped.css +20 -13
- package/internal/components/abstract-switch/styles.selectors.js +11 -11
- package/internal/components/date-input/index.d.ts.map +1 -1
- package/internal/components/date-input/index.js +3 -2
- package/internal/components/date-input/index.js.map +1 -1
- package/internal/components/masked-input/utils/mask-format.d.ts.map +1 -1
- package/internal/components/masked-input/utils/mask-format.js +2 -1
- package/internal/components/masked-input/utils/mask-format.js.map +1 -1
- package/internal/components/masked-input/utils/strings.d.ts +0 -1
- package/internal/components/masked-input/utils/strings.d.ts.map +1 -1
- package/internal/components/masked-input/utils/strings.js +0 -6
- package/internal/components/masked-input/utils/strings.js.map +1 -1
- package/internal/components/options-list/utils/use-highlight-option.d.ts +7 -2
- package/internal/components/options-list/utils/use-highlight-option.d.ts.map +1 -1
- package/internal/components/options-list/utils/use-highlight-option.js +10 -3
- package/internal/components/options-list/utils/use-highlight-option.js.map +1 -1
- package/internal/components/selectable-item/index.d.ts +1 -1
- package/internal/components/selectable-item/index.d.ts.map +1 -1
- package/internal/components/selectable-item/index.js +2 -2
- package/internal/components/selectable-item/index.js.map +1 -1
- package/internal/components/selectable-item/styles.css.js +16 -16
- package/internal/components/selectable-item/styles.scoped.css +29 -30
- package/internal/components/selectable-item/styles.selectors.js +16 -16
- package/internal/environment.js +1 -1
- package/internal/utils/date-time/display-format.d.ts +9 -0
- package/internal/utils/date-time/display-format.d.ts.map +1 -0
- package/internal/utils/date-time/display-format.js +15 -0
- package/internal/utils/date-time/display-format.js.map +1 -0
- package/internal/utils/date-time/format-date.d.ts +7 -0
- package/internal/utils/date-time/format-date.d.ts.map +1 -0
- package/internal/utils/date-time/format-date.js +15 -0
- package/internal/utils/date-time/format-date.js.map +1 -0
- package/internal/utils/date-time/format-time.d.ts +5 -0
- package/internal/utils/date-time/format-time.d.ts.map +1 -0
- package/internal/utils/date-time/format-time.js +13 -0
- package/internal/utils/date-time/format-time.js.map +1 -0
- package/internal/utils/date-time/format-timezone-offset.d.ts +2 -0
- package/internal/utils/date-time/format-timezone-offset.d.ts.map +1 -0
- package/internal/utils/date-time/format-timezone-offset.js +11 -0
- package/internal/utils/date-time/format-timezone-offset.js.map +1 -0
- package/internal/utils/date-time/get-browser-timezone-offset.d.ts +7 -0
- package/internal/utils/date-time/get-browser-timezone-offset.d.ts.map +1 -0
- package/internal/utils/date-time/get-browser-timezone-offset.js +11 -0
- package/internal/utils/date-time/get-browser-timezone-offset.js.map +1 -0
- package/internal/utils/date-time/index.d.ts +11 -0
- package/internal/utils/date-time/index.d.ts.map +1 -0
- package/internal/utils/date-time/index.js +13 -0
- package/internal/utils/date-time/index.js.map +1 -0
- package/internal/utils/date-time/is-iso-date-only.d.ts +5 -0
- package/internal/utils/date-time/is-iso-date-only.d.ts.map +1 -0
- package/internal/utils/date-time/is-iso-date-only.js +10 -0
- package/internal/utils/date-time/is-iso-date-only.js.map +1 -0
- package/internal/utils/date-time/join-date-time.d.ts +2 -0
- package/internal/utils/date-time/join-date-time.d.ts.map +1 -0
- package/internal/utils/date-time/join-date-time.js +6 -0
- package/internal/utils/date-time/join-date-time.js.map +1 -0
- package/internal/utils/date-time/parse-date.d.ts +8 -0
- package/internal/utils/date-time/parse-date.d.ts.map +1 -0
- package/internal/utils/date-time/parse-date.js +16 -0
- package/internal/utils/date-time/parse-date.js.map +1 -0
- package/internal/utils/date-time/parse-timezone-offset.d.ts +5 -0
- package/internal/utils/date-time/parse-timezone-offset.d.ts.map +1 -0
- package/internal/utils/date-time/parse-timezone-offset.js +20 -0
- package/internal/utils/date-time/parse-timezone-offset.js.map +1 -0
- package/internal/utils/date-time/shift-timezone-offset.d.ts +12 -0
- package/internal/utils/date-time/shift-timezone-offset.d.ts.map +1 -0
- package/internal/utils/date-time/shift-timezone-offset.js +27 -0
- package/internal/utils/date-time/shift-timezone-offset.js.map +1 -0
- package/internal/utils/strings/index.d.ts +3 -0
- package/internal/utils/strings/index.d.ts.map +1 -0
- package/internal/utils/strings/index.js +5 -0
- package/internal/utils/strings/index.js.map +1 -0
- package/internal/utils/strings/join-strings.d.ts +5 -0
- package/internal/utils/strings/join-strings.d.ts.map +1 -0
- package/internal/utils/{strings.js → strings/join-strings.js} +7 -6
- package/internal/utils/strings/join-strings.js.map +1 -0
- package/internal/utils/strings/pad-left-zeros.d.ts +5 -0
- package/internal/utils/strings/pad-left-zeros.d.ts.map +1 -0
- package/internal/utils/strings/pad-left-zeros.js +12 -0
- package/internal/utils/strings/pad-left-zeros.js.map +1 -0
- package/multiselect/internal.d.ts.map +1 -1
- package/multiselect/internal.js +2 -2
- package/multiselect/internal.js.map +1 -1
- package/package.json +1 -1
- package/popover/styles.css.js +48 -48
- package/popover/styles.scoped.css +65 -60
- package/popover/styles.selectors.js +48 -48
- package/radio-group/styles.css.js +9 -9
- package/radio-group/styles.scoped.css +16 -16
- package/radio-group/styles.selectors.js +9 -9
- package/select/internal.d.ts.map +1 -1
- package/select/internal.js +2 -2
- package/select/internal.js.map +1 -1
- package/select/parts/item.d.ts +1 -1
- package/select/parts/item.d.ts.map +1 -1
- package/select/parts/item.js +6 -3
- package/select/parts/item.js.map +1 -1
- package/select/parts/multiselect-item.d.ts +1 -1
- package/select/parts/multiselect-item.d.ts.map +1 -1
- package/select/parts/multiselect-item.js +2 -2
- package/select/parts/multiselect-item.js.map +1 -1
- package/select/parts/plain-list.d.ts +1 -1
- package/select/parts/plain-list.d.ts.map +1 -1
- package/select/parts/plain-list.js +4 -4
- package/select/parts/plain-list.js.map +1 -1
- package/select/parts/styles.css.js +8 -7
- package/select/parts/styles.scoped.css +12 -7
- package/select/parts/styles.selectors.js +8 -7
- package/select/parts/virtual-list.js +4 -4
- package/select/parts/virtual-list.js.map +1 -1
- package/select/utils/get-item-props.d.ts +1 -2
- package/select/utils/get-item-props.d.ts.map +1 -1
- package/select/utils/get-item-props.js +3 -3
- package/select/utils/get-item-props.js.map +1 -1
- package/select/utils/render-options.d.ts +2 -2
- package/select/utils/render-options.d.ts.map +1 -1
- package/select/utils/render-options.js +2 -3
- package/select/utils/render-options.js.map +1 -1
- package/select/utils/use-select.d.ts +1 -0
- package/select/utils/use-select.d.ts.map +1 -1
- package/select/utils/use-select.js +2 -1
- package/select/utils/use-select.js.map +1 -1
- package/split-panel/index.d.ts.map +1 -1
- package/split-panel/index.js +2 -2
- package/split-panel/index.js.map +1 -1
- package/table/styles.css.js +32 -32
- package/table/styles.scoped.css +40 -43
- package/table/styles.selectors.js +32 -32
- package/tabs/styles.css.js +21 -21
- package/tabs/styles.scoped.css +40 -43
- package/tabs/styles.selectors.js +21 -21
- package/textarea/styles.css.js +4 -4
- package/textarea/styles.scoped.css +13 -14
- package/textarea/styles.selectors.js +4 -4
- package/toggle/internal.d.ts.map +1 -1
- package/toggle/internal.js +3 -1
- package/toggle/internal.js.map +1 -1
- package/toggle/styles.css.js +8 -8
- package/toggle/styles.scoped.css +15 -14
- package/toggle/styles.selectors.js +8 -8
- package/date-picker/calendar/utils/date.d.ts +0 -10
- package/date-picker/calendar/utils/date.d.ts.map +0 -1
- package/date-picker/calendar/utils/date.js +0 -50
- package/date-picker/calendar/utils/date.js.map +0 -1
- package/internal/components/date-input/utils/date.d.ts +0 -5
- package/internal/components/date-input/utils/date.d.ts.map +0 -1
- package/internal/components/date-input/utils/date.js +0 -11
- package/internal/components/date-input/utils/date.js.map +0 -1
- package/internal/utils/strings.d.ts +0 -2
- package/internal/utils/strings.d.ts.map +0 -1
- package/internal/utils/strings.js.map +0 -1
|
@@ -90,7 +90,7 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
|
|
|
90
90
|
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
91
91
|
SPDX-License-Identifier: Apache-2.0
|
|
92
92
|
*/
|
|
93
|
-
.awsui_selectable-
|
|
93
|
+
.awsui_selectable-item_15o6u_1g6vu_93:not(#\9) {
|
|
94
94
|
font-size: var(--font-body-m-size-sregvd, 14px);
|
|
95
95
|
line-height: var(--font-body-m-line-height-i7xxvv, 22px);
|
|
96
96
|
color: var(--color-text-body-default-ajf1h5, #000716);
|
|
@@ -110,96 +110,95 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
|
|
|
110
110
|
var(--space-xxs-ynfts5, 4px) + (var(--border-item-width-qbbbsa, 2px) - var(--border-divider-list-width-hacikr, 1px))
|
|
111
111
|
) calc(var(--space-field-horizontal-89h2yr, 12px) + var(--border-item-width-qbbbsa, 2px));
|
|
112
112
|
}
|
|
113
|
-
.awsui_selectable-
|
|
113
|
+
.awsui_selectable-item_15o6u_1g6vu_93.awsui_pad-bottom_15o6u_1g6vu_113:not(#\9) {
|
|
114
114
|
padding-bottom: calc(calc(
|
|
115
115
|
var(--space-xxs-ynfts5, 4px) + (var(--border-item-width-qbbbsa, 2px) - var(--border-divider-list-width-hacikr, 1px))
|
|
116
116
|
) + var(--space-xxxs-k2w98v, 2px));
|
|
117
117
|
border-bottom-color: transparent;
|
|
118
118
|
}
|
|
119
|
-
.awsui_selectable-
|
|
119
|
+
.awsui_selectable-item_15o6u_1g6vu_93:not(#\9):not(:first-child) {
|
|
120
120
|
margin-top: calc(-1 * var(--border-item-width-qbbbsa, 2px));
|
|
121
121
|
}
|
|
122
|
-
.awsui_selectable-
|
|
122
|
+
.awsui_selectable-item_15o6u_1g6vu_93.awsui_has-background_15o6u_1g6vu_122:not(#\9) {
|
|
123
123
|
background-color: var(--color-background-dropdown-item-hover-mqsxkv, #f4f4f4);
|
|
124
124
|
}
|
|
125
|
-
.awsui_selectable-
|
|
125
|
+
.awsui_selectable-item_15o6u_1g6vu_93.awsui_highlighted_15o6u_1g6vu_125:not(#\9), .awsui_selectable-item_15o6u_1g6vu_93.awsui_selected_15o6u_1g6vu_125:not(#\9) {
|
|
126
126
|
color: var(--color-text-dropdown-item-highlighted-oaabyk, #000716);
|
|
127
127
|
border-width: var(--border-item-width-qbbbsa, 2px);
|
|
128
128
|
border-radius: var(--border-radius-item-u2ibpi, 8px);
|
|
129
129
|
padding: var(--space-xxs-ynfts5, 4px) var(--space-field-horizontal-89h2yr, 12px);
|
|
130
130
|
}
|
|
131
|
-
.awsui_selectable-
|
|
131
|
+
.awsui_selectable-item_15o6u_1g6vu_93.awsui_highlighted_15o6u_1g6vu_125.awsui_pad-bottom_15o6u_1g6vu_113:not(#\9), .awsui_selectable-item_15o6u_1g6vu_93.awsui_selected_15o6u_1g6vu_125.awsui_pad-bottom_15o6u_1g6vu_113:not(#\9) {
|
|
132
132
|
padding-bottom: calc(var(--space-xxs-ynfts5, 4px) + var(--space-xxxs-k2w98v, 2px));
|
|
133
133
|
}
|
|
134
|
-
.awsui_selectable-
|
|
134
|
+
.awsui_selectable-item_15o6u_1g6vu_93.awsui_highlighted_15o6u_1g6vu_125:not(#\9) {
|
|
135
135
|
z-index: 2;
|
|
136
136
|
background-color: var(--color-background-dropdown-item-hover-mqsxkv, #f4f4f4);
|
|
137
137
|
border-color: var(--color-border-dropdown-item-hover-tyzq9m, #7d8998);
|
|
138
138
|
}
|
|
139
|
-
.awsui_selectable-
|
|
139
|
+
.awsui_selectable-item_15o6u_1g6vu_93.awsui_highlighted_15o6u_1g6vu_125.awsui_disabled_15o6u_1g6vu_139:not(#\9) {
|
|
140
140
|
color: var(--color-text-dropdown-item-dimmed-jyqdrs, #9ba7b6);
|
|
141
141
|
border-color: var(--color-border-dropdown-item-dimmed-hover-6dhy15, #7d8998);
|
|
142
142
|
background-color: var(--color-background-dropdown-item-dimmed-qw48ma, transparent);
|
|
143
143
|
}
|
|
144
|
-
.awsui_selectable-
|
|
145
|
-
z-index: 3;
|
|
144
|
+
.awsui_selectable-item_15o6u_1g6vu_93.awsui_selected_15o6u_1g6vu_125:not(#\9) {
|
|
146
145
|
background-color: var(--color-background-dropdown-item-selected-8l4mpk, #f2f8fd);
|
|
147
|
-
border-color: var(--color-border-dropdown-item-selected-eahq2j, #0972d3);
|
|
148
146
|
}
|
|
149
|
-
.awsui_selectable-
|
|
147
|
+
.awsui_selectable-item_15o6u_1g6vu_93.awsui_selected_15o6u_1g6vu_125.awsui_next-item-selected_15o6u_1g6vu_147:not(#\9) {
|
|
150
148
|
border-bottom-left-radius: 0;
|
|
151
149
|
border-bottom-right-radius: 0;
|
|
152
150
|
}
|
|
153
|
-
.awsui_selectable-
|
|
151
|
+
.awsui_selectable-item_15o6u_1g6vu_93.awsui_selected_15o6u_1g6vu_125 + .awsui_selectable-item_15o6u_1g6vu_93.awsui_selected_15o6u_1g6vu_125:not(#\9) {
|
|
154
152
|
border-top-left-radius: 0;
|
|
155
153
|
border-top-right-radius: 0;
|
|
156
154
|
}
|
|
157
|
-
.awsui_selectable-
|
|
158
|
-
|
|
155
|
+
.awsui_selectable-item_15o6u_1g6vu_93.awsui_highlighted_15o6u_1g6vu_125.awsui_is-keyboard_15o6u_1g6vu_155:not(#\9) {
|
|
156
|
+
border-color: var(--color-border-item-focused-ap3b6s, #0972d3);
|
|
157
|
+
box-shadow: inset 0 0 0 var(--border-control-focus-ring-shadow-spread-srzyiu, 0px) var(--color-border-item-focused-ap3b6s, #0972d3);
|
|
159
158
|
}
|
|
160
|
-
.awsui_selectable-
|
|
159
|
+
.awsui_selectable-item_15o6u_1g6vu_93.awsui_parent_15o6u_1g6vu_159:not(#\9) {
|
|
161
160
|
font-weight: bold;
|
|
162
161
|
color: var(--color-text-dropdown-group-label-eaqlcl, #414d5c);
|
|
163
162
|
}
|
|
164
|
-
.awsui_selectable-
|
|
163
|
+
.awsui_selectable-item_15o6u_1g6vu_93.awsui_parent_15o6u_1g6vu_159:not(#\9):not(.awsui_interactiveGroups_15o6u_1g6vu_163) {
|
|
165
164
|
border-top-color: var(--color-border-dropdown-group-0utpsr, #e9ebed);
|
|
166
165
|
padding: var(--space-xs-rsr2qu, 8px);
|
|
167
166
|
}
|
|
168
|
-
.awsui_selectable-
|
|
167
|
+
.awsui_selectable-item_15o6u_1g6vu_93.awsui_parent_15o6u_1g6vu_159.awsui_interactiveGroups_15o6u_1g6vu_163:not(#\9) {
|
|
169
168
|
padding: calc(
|
|
170
169
|
var(--space-xs-rsr2qu, 8px) + (var(--border-item-width-qbbbsa, 2px) - var(--border-divider-list-width-hacikr, 1px))
|
|
171
170
|
) calc(var(--space-field-horizontal-89h2yr, 12px) + var(--border-item-width-qbbbsa, 2px));
|
|
172
171
|
}
|
|
173
|
-
.awsui_selectable-
|
|
172
|
+
.awsui_selectable-item_15o6u_1g6vu_93.awsui_parent_15o6u_1g6vu_159.awsui_interactiveGroups_15o6u_1g6vu_163.awsui_highlighted_15o6u_1g6vu_125:not(#\9), .awsui_selectable-item_15o6u_1g6vu_93.awsui_parent_15o6u_1g6vu_159.awsui_interactiveGroups_15o6u_1g6vu_163.awsui_selected_15o6u_1g6vu_125:not(#\9) {
|
|
174
173
|
padding: var(--space-xs-rsr2qu, 8px) var(--space-field-horizontal-89h2yr, 12px);
|
|
175
174
|
}
|
|
176
|
-
.awsui_selectable-
|
|
175
|
+
.awsui_selectable-item_15o6u_1g6vu_93.awsui_child_15o6u_1g6vu_175:not(#\9) {
|
|
177
176
|
padding-left: calc(var(--space-xxl-2nvmf1, 32px) + var(--border-item-width-qbbbsa, 2px));
|
|
178
177
|
}
|
|
179
|
-
.awsui_selectable-
|
|
178
|
+
.awsui_selectable-item_15o6u_1g6vu_93.awsui_child_15o6u_1g6vu_175.awsui_highlighted_15o6u_1g6vu_125:not(#\9), .awsui_selectable-item_15o6u_1g6vu_93.awsui_child_15o6u_1g6vu_175.awsui_selected_15o6u_1g6vu_125:not(#\9) {
|
|
180
179
|
padding-left: var(--space-xxl-2nvmf1, 32px);
|
|
181
180
|
}
|
|
182
|
-
.awsui_selectable-
|
|
181
|
+
.awsui_selectable-item_15o6u_1g6vu_93.awsui_disabled_15o6u_1g6vu_139:not(#\9) {
|
|
183
182
|
color: var(--color-text-dropdown-item-disabled-varol7, #9ba7b6);
|
|
184
183
|
}
|
|
185
|
-
.awsui_selectable-
|
|
184
|
+
.awsui_selectable-item_15o6u_1g6vu_93:not(#\9):not(.awsui_disabled_15o6u_1g6vu_139):not(.awsui_parent_15o6u_1g6vu_159) {
|
|
186
185
|
cursor: pointer;
|
|
187
186
|
}
|
|
188
|
-
.awsui_selectable-
|
|
187
|
+
.awsui_selectable-item_15o6u_1g6vu_93.awsui_interactiveGroups_15o6u_1g6vu_163:not(#\9):not(.awsui_disabled_15o6u_1g6vu_139) {
|
|
189
188
|
cursor: pointer;
|
|
190
189
|
}
|
|
191
|
-
.awsui_selectable-
|
|
190
|
+
.awsui_selectable-item_15o6u_1g6vu_93.awsui_virtual_15o6u_1g6vu_190:not(#\9) {
|
|
192
191
|
position: absolute;
|
|
193
192
|
top: var(--border-dropdown-virtual-offset-width-fzhepk, 2px);
|
|
194
193
|
left: 0;
|
|
195
194
|
width: 100%;
|
|
196
195
|
box-sizing: border-box;
|
|
197
196
|
}
|
|
198
|
-
.awsui_selectable-
|
|
197
|
+
.awsui_selectable-item_15o6u_1g6vu_93.awsui_virtual_15o6u_1g6vu_190:not(#\9):first-of-type:not(.awsui_selected_15o6u_1g6vu_125, .awsui_highlighted_15o6u_1g6vu_125) {
|
|
199
198
|
border-top-color: var(--color-border-dropdown-item-top-xnzq48, transparent);
|
|
200
199
|
}
|
|
201
200
|
|
|
202
|
-
.awsui_measure-
|
|
201
|
+
.awsui_measure-strut_15o6u_1g6vu_201:not(#\9) {
|
|
203
202
|
position: absolute;
|
|
204
203
|
pointer-events: none;
|
|
205
204
|
height: 100%;
|
|
@@ -208,16 +207,16 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
|
|
|
208
207
|
left: 0;
|
|
209
208
|
padding-top: var(--border-divider-list-width-hacikr, 1px);
|
|
210
209
|
}
|
|
211
|
-
.awsui_measure-strut-
|
|
210
|
+
.awsui_measure-strut-first_15o6u_1g6vu_210:not(#\9) {
|
|
212
211
|
padding-bottom: var(--border-divider-list-width-hacikr, 1px);
|
|
213
212
|
}
|
|
214
213
|
|
|
215
|
-
.awsui_screenreader-
|
|
214
|
+
.awsui_screenreader-content_15o6u_1g6vu_214:not(#\9) {
|
|
216
215
|
position: absolute !important;
|
|
217
216
|
top: -9999px !important;
|
|
218
217
|
left: -9999px !important;
|
|
219
218
|
}
|
|
220
219
|
|
|
221
|
-
.awsui_option-
|
|
220
|
+
.awsui_option-content_15o6u_1g6vu_220:not(#\9) {
|
|
222
221
|
/* used in test-utils */
|
|
223
222
|
}
|
|
@@ -2,21 +2,21 @@
|
|
|
2
2
|
// es-module interop with Babel and Typescript
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
4
|
module.exports.default = {
|
|
5
|
-
"selectable-item": "awsui_selectable-
|
|
6
|
-
"pad-bottom": "awsui_pad-
|
|
7
|
-
"has-background": "awsui_has-
|
|
8
|
-
"highlighted": "
|
|
9
|
-
"selected": "
|
|
10
|
-
"disabled": "
|
|
11
|
-
"next-item-selected": "awsui_next-item-
|
|
12
|
-
"is-keyboard": "awsui_is-
|
|
13
|
-
"parent": "
|
|
14
|
-
"interactiveGroups": "
|
|
15
|
-
"child": "
|
|
16
|
-
"virtual": "
|
|
17
|
-
"measure-strut": "awsui_measure-
|
|
18
|
-
"measure-strut-first": "awsui_measure-strut-
|
|
19
|
-
"screenreader-content": "awsui_screenreader-
|
|
20
|
-
"option-content": "awsui_option-
|
|
5
|
+
"selectable-item": "awsui_selectable-item_15o6u_1g6vu_93",
|
|
6
|
+
"pad-bottom": "awsui_pad-bottom_15o6u_1g6vu_113",
|
|
7
|
+
"has-background": "awsui_has-background_15o6u_1g6vu_122",
|
|
8
|
+
"highlighted": "awsui_highlighted_15o6u_1g6vu_125",
|
|
9
|
+
"selected": "awsui_selected_15o6u_1g6vu_125",
|
|
10
|
+
"disabled": "awsui_disabled_15o6u_1g6vu_139",
|
|
11
|
+
"next-item-selected": "awsui_next-item-selected_15o6u_1g6vu_147",
|
|
12
|
+
"is-keyboard": "awsui_is-keyboard_15o6u_1g6vu_155",
|
|
13
|
+
"parent": "awsui_parent_15o6u_1g6vu_159",
|
|
14
|
+
"interactiveGroups": "awsui_interactiveGroups_15o6u_1g6vu_163",
|
|
15
|
+
"child": "awsui_child_15o6u_1g6vu_175",
|
|
16
|
+
"virtual": "awsui_virtual_15o6u_1g6vu_190",
|
|
17
|
+
"measure-strut": "awsui_measure-strut_15o6u_1g6vu_201",
|
|
18
|
+
"measure-strut-first": "awsui_measure-strut-first_15o6u_1g6vu_210",
|
|
19
|
+
"screenreader-content": "awsui_screenreader-content_15o6u_1g6vu_214",
|
|
20
|
+
"option-content": "awsui_option-content_15o6u_1g6vu_220"
|
|
21
21
|
};
|
|
22
22
|
|
package/internal/environment.js
CHANGED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Converts ISO date to display format, e.g. 2020-01-01 -> 2020/01/01.
|
|
3
|
+
*/
|
|
4
|
+
export declare function isoToDisplay(value: string): string;
|
|
5
|
+
/**
|
|
6
|
+
* Converts display date to ISO format, e.g. 2020/01/01 -> 2020-01-01.
|
|
7
|
+
*/
|
|
8
|
+
export declare function displayToIso(value: string): string;
|
|
9
|
+
//# sourceMappingURL=display-format.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"display-format.d.ts","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/display-format.ts"],"names":[],"mappings":"AAGA;;GAEG;AACH,wBAAgB,YAAY,CAAC,KAAK,EAAE,MAAM,UAEzC;AAED;;GAEG;AACH,wBAAgB,YAAY,CAAC,KAAK,EAAE,MAAM,UAEzC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
/**
|
|
4
|
+
* Converts ISO date to display format, e.g. 2020-01-01 -> 2020/01/01.
|
|
5
|
+
*/
|
|
6
|
+
export function isoToDisplay(value) {
|
|
7
|
+
return value.replace(/-/g, '/');
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Converts display date to ISO format, e.g. 2020/01/01 -> 2020-01-01.
|
|
11
|
+
*/
|
|
12
|
+
export function displayToIso(value) {
|
|
13
|
+
return value.replace(/\//g, '-');
|
|
14
|
+
}
|
|
15
|
+
//# sourceMappingURL=display-format.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"display-format.js","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/display-format.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AAEtC;;GAEG;AACH,MAAM,UAAU,YAAY,CAAC,KAAa;IACxC,OAAO,KAAK,CAAC,OAAO,CAAC,IAAI,EAAE,GAAG,CAAC,CAAC;AAClC,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,YAAY,CAAC,KAAa;IACxC,OAAO,KAAK,CAAC,OAAO,CAAC,KAAK,EAAE,GAAG,CAAC,CAAC;AACnC,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\n\n/**\n * Converts ISO date to display format, e.g. 2020-01-01 -> 2020/01/01.\n */\nexport function isoToDisplay(value: string) {\n return value.replace(/-/g, '/');\n}\n\n/**\n * Converts display date to ISO format, e.g. 2020/01/01 -> 2020-01-01.\n */\nexport function displayToIso(value: string) {\n return value.replace(/\\//g, '-');\n}\n"]}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Transforms Date's object date part to a string.
|
|
3
|
+
*
|
|
4
|
+
* We cannot use Date.toISOString because it produces GMT time where the date can be different than local.
|
|
5
|
+
*/
|
|
6
|
+
export declare function formatDate(value: Date): string;
|
|
7
|
+
//# sourceMappingURL=format-date.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"format-date.d.ts","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/format-date.ts"],"names":[],"mappings":"AAKA;;;;GAIG;AACH,wBAAgB,UAAU,CAAC,KAAK,EAAE,IAAI,GAAG,MAAM,CAK9C"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
import { padLeftZeros } from '../strings';
|
|
4
|
+
/**
|
|
5
|
+
* Transforms Date's object date part to a string.
|
|
6
|
+
*
|
|
7
|
+
* We cannot use Date.toISOString because it produces GMT time where the date can be different than local.
|
|
8
|
+
*/
|
|
9
|
+
export function formatDate(value) {
|
|
10
|
+
var year = value.getFullYear();
|
|
11
|
+
var month = padLeftZeros("".concat(value.getMonth() + 1), 2);
|
|
12
|
+
var date = padLeftZeros("".concat(value.getDate()), 2);
|
|
13
|
+
return "".concat(year, "-").concat(month, "-").concat(date);
|
|
14
|
+
}
|
|
15
|
+
//# sourceMappingURL=format-date.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"format-date.js","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/format-date.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AAEtC,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAE1C;;;;GAIG;AACH,MAAM,UAAU,UAAU,CAAC,KAAW;IACpC,IAAM,IAAI,GAAG,KAAK,CAAC,WAAW,EAAE,CAAC;IACjC,IAAM,KAAK,GAAG,YAAY,CAAC,UAAG,KAAK,CAAC,QAAQ,EAAE,GAAG,CAAC,CAAE,EAAE,CAAC,CAAC,CAAC;IACzD,IAAM,IAAI,GAAG,YAAY,CAAC,UAAG,KAAK,CAAC,OAAO,EAAE,CAAE,EAAE,CAAC,CAAC,CAAC;IACnD,OAAO,UAAG,IAAI,cAAI,KAAK,cAAI,IAAI,CAAE,CAAC;AACpC,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport { padLeftZeros } from '../strings';\n\n/**\n * Transforms Date's object date part to a string.\n *\n * We cannot use Date.toISOString because it produces GMT time where the date can be different than local.\n */\nexport function formatDate(value: Date): string {\n const year = value.getFullYear();\n const month = padLeftZeros(`${value.getMonth() + 1}`, 2);\n const date = padLeftZeros(`${value.getDate()}`, 2);\n return `${year}-${month}-${date}`;\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"format-time.d.ts","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/format-time.ts"],"names":[],"mappings":"AAKA;;GAEG;AACH,eAAO,MAAM,UAAU,UAAW,IAAI,KAAG,MAKxC,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
import { padLeftZeros } from '../strings';
|
|
4
|
+
/**
|
|
5
|
+
* Transforms Date's object time part to a string.
|
|
6
|
+
*/
|
|
7
|
+
export var formatTime = function (value) {
|
|
8
|
+
var hours = padLeftZeros("".concat(value.getHours()), 2);
|
|
9
|
+
var minutes = padLeftZeros("".concat(value.getMinutes()), 2);
|
|
10
|
+
var seconds = padLeftZeros("".concat(value.getSeconds()), 2);
|
|
11
|
+
return "".concat(hours, ":").concat(minutes, ":").concat(seconds);
|
|
12
|
+
};
|
|
13
|
+
//# sourceMappingURL=format-time.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"format-time.js","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/format-time.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AAEtC,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAE1C;;GAEG;AACH,MAAM,CAAC,IAAM,UAAU,GAAG,UAAC,KAAW;IACpC,IAAM,KAAK,GAAG,YAAY,CAAC,UAAG,KAAK,CAAC,QAAQ,EAAE,CAAE,EAAE,CAAC,CAAC,CAAC;IACrD,IAAM,OAAO,GAAG,YAAY,CAAC,UAAG,KAAK,CAAC,UAAU,EAAE,CAAE,EAAE,CAAC,CAAC,CAAC;IACzD,IAAM,OAAO,GAAG,YAAY,CAAC,UAAG,KAAK,CAAC,UAAU,EAAE,CAAE,EAAE,CAAC,CAAC,CAAC;IACzD,OAAO,UAAG,KAAK,cAAI,OAAO,cAAI,OAAO,CAAE,CAAC;AAC1C,CAAC,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport { padLeftZeros } from '../strings';\n\n/**\n * Transforms Date's object time part to a string.\n */\nexport const formatTime = (value: Date): string => {\n const hours = padLeftZeros(`${value.getHours()}`, 2);\n const minutes = padLeftZeros(`${value.getMinutes()}`, 2);\n const seconds = padLeftZeros(`${value.getSeconds()}`, 2);\n return `${hours}:${minutes}:${seconds}`;\n};\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"format-timezone-offset.d.ts","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/format-timezone-offset.ts"],"names":[],"mappings":"AAKA,wBAAgB,oBAAoB,CAAC,eAAe,EAAE,MAAM,UAQ3D"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
import { padLeftZeros } from '../strings';
|
|
4
|
+
export function formatTimezoneOffset(offsetInMinutes) {
|
|
5
|
+
var hoursOffset = padLeftZeros(Math.floor(Math.abs(offsetInMinutes) / 60).toFixed(0), 2);
|
|
6
|
+
var minuteOffset = padLeftZeros(Math.abs(offsetInMinutes % 60).toFixed(0), 2);
|
|
7
|
+
var sign = offsetInMinutes < 0 ? '-' : '+';
|
|
8
|
+
var formattedOffset = "".concat(sign).concat(hoursOffset, ":").concat(minuteOffset);
|
|
9
|
+
return formattedOffset;
|
|
10
|
+
}
|
|
11
|
+
//# sourceMappingURL=format-timezone-offset.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"format-timezone-offset.js","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/format-timezone-offset.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AAEtC,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAE1C,MAAM,UAAU,oBAAoB,CAAC,eAAuB;IAC1D,IAAM,WAAW,GAAG,YAAY,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,eAAe,CAAC,GAAG,EAAE,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;IAC3F,IAAM,YAAY,GAAG,YAAY,CAAC,IAAI,CAAC,GAAG,CAAC,eAAe,GAAG,EAAE,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;IAEhF,IAAM,IAAI,GAAG,eAAe,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC;IAC7C,IAAM,eAAe,GAAG,UAAG,IAAI,SAAG,WAAW,cAAI,YAAY,CAAE,CAAC;IAEhE,OAAO,eAAe,CAAC;AACzB,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport { padLeftZeros } from '../strings';\n\nexport function formatTimezoneOffset(offsetInMinutes: number) {\n const hoursOffset = padLeftZeros(Math.floor(Math.abs(offsetInMinutes) / 60).toFixed(0), 2);\n const minuteOffset = padLeftZeros(Math.abs(offsetInMinutes % 60).toFixed(0), 2);\n\n const sign = offsetInMinutes < 0 ? '-' : '+';\n const formattedOffset = `${sign}${hoursOffset}:${minuteOffset}`;\n\n return formattedOffset;\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-browser-timezone-offset.d.ts","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/get-browser-timezone-offset.ts"],"names":[],"mappings":"AAGA;;;;GAIG;AACH,wBAAgB,wBAAwB,WAEvC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
/**
|
|
4
|
+
* Returns the time offset of the browser.
|
|
5
|
+
*
|
|
6
|
+
* I.e. determines the `x` in `current offset = UTC + x`
|
|
7
|
+
*/
|
|
8
|
+
export function getBrowserTimezoneOffset() {
|
|
9
|
+
return 0 - new Date().getTimezoneOffset();
|
|
10
|
+
}
|
|
11
|
+
//# sourceMappingURL=get-browser-timezone-offset.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-browser-timezone-offset.js","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/get-browser-timezone-offset.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AAEtC;;;;GAIG;AACH,MAAM,UAAU,wBAAwB;IACtC,OAAO,CAAC,GAAG,IAAI,IAAI,EAAE,CAAC,iBAAiB,EAAE,CAAC;AAC5C,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\n\n/**\n * Returns the time offset of the browser.\n *\n * I.e. determines the `x` in `current offset = UTC + x`\n */\nexport function getBrowserTimezoneOffset() {\n return 0 - new Date().getTimezoneOffset();\n}\n"]}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export { isoToDisplay, displayToIso } from './display-format';
|
|
2
|
+
export { formatDate } from './format-date';
|
|
3
|
+
export { formatTime } from './format-time';
|
|
4
|
+
export { formatTimezoneOffset } from './format-timezone-offset';
|
|
5
|
+
export { getBrowserTimezoneOffset } from './get-browser-timezone-offset';
|
|
6
|
+
export { isIsoDateOnly } from './is-iso-date-only';
|
|
7
|
+
export { joinDateTime } from './join-date-time';
|
|
8
|
+
export { parseDate } from './parse-date';
|
|
9
|
+
export { parseTimezoneOffset } from './parse-timezone-offset';
|
|
10
|
+
export { shiftTimezoneOffset } from './shift-timezone-offset';
|
|
11
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/index.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAC9D,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EAAE,oBAAoB,EAAE,MAAM,0BAA0B,CAAC;AAChE,OAAO,EAAE,wBAAwB,EAAE,MAAM,+BAA+B,CAAC;AACzE,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AACnD,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAChD,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC;AAC9D,OAAO,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
export { isoToDisplay, displayToIso } from './display-format';
|
|
4
|
+
export { formatDate } from './format-date';
|
|
5
|
+
export { formatTime } from './format-time';
|
|
6
|
+
export { formatTimezoneOffset } from './format-timezone-offset';
|
|
7
|
+
export { getBrowserTimezoneOffset } from './get-browser-timezone-offset';
|
|
8
|
+
export { isIsoDateOnly } from './is-iso-date-only';
|
|
9
|
+
export { joinDateTime } from './join-date-time';
|
|
10
|
+
export { parseDate } from './parse-date';
|
|
11
|
+
export { parseTimezoneOffset } from './parse-timezone-offset';
|
|
12
|
+
export { shiftTimezoneOffset } from './shift-timezone-offset';
|
|
13
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/index.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AAEtC,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAC9D,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EAAE,oBAAoB,EAAE,MAAM,0BAA0B,CAAC;AAChE,OAAO,EAAE,wBAAwB,EAAE,MAAM,+BAA+B,CAAC;AACzE,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AACnD,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAChD,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC;AAC9D,OAAO,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nexport { isoToDisplay, displayToIso } from './display-format';\nexport { formatDate } from './format-date';\nexport { formatTime } from './format-time';\nexport { formatTimezoneOffset } from './format-timezone-offset';\nexport { getBrowserTimezoneOffset } from './get-browser-timezone-offset';\nexport { isIsoDateOnly } from './is-iso-date-only';\nexport { joinDateTime } from './join-date-time';\nexport { parseDate } from './parse-date';\nexport { parseTimezoneOffset } from './parse-timezone-offset';\nexport { shiftTimezoneOffset } from './shift-timezone-offset';\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"is-iso-date-only.d.ts","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/is-iso-date-only.ts"],"names":[],"mappings":"AAKA;;GAEG;AACH,wBAAgB,aAAa,CAAC,UAAU,EAAE,MAAM,WAE/C"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
var dateRegex = /^\d{4}-\d{2}-\d{2}$/;
|
|
4
|
+
/**
|
|
5
|
+
* Checks if ISO date-string is date-only.
|
|
6
|
+
*/
|
|
7
|
+
export function isIsoDateOnly(dateString) {
|
|
8
|
+
return dateRegex.test(dateString);
|
|
9
|
+
}
|
|
10
|
+
//# sourceMappingURL=is-iso-date-only.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"is-iso-date-only.js","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/is-iso-date-only.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AAEtC,IAAM,SAAS,GAAG,qBAAqB,CAAC;AAExC;;GAEG;AACH,MAAM,UAAU,aAAa,CAAC,UAAkB;IAC9C,OAAO,SAAS,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;AACpC,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nconst dateRegex = /^\\d{4}-\\d{2}-\\d{2}$/;\n\n/**\n * Checks if ISO date-string is date-only.\n */\nexport function isIsoDateOnly(dateString: string) {\n return dateRegex.test(dateString);\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"join-date-time.d.ts","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/join-date-time.ts"],"names":[],"mappings":"AAGA,wBAAgB,YAAY,CAAC,UAAU,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,UAElE"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
export function joinDateTime(dateString, timeString) {
|
|
4
|
+
return "".concat(dateString, "T").concat(timeString);
|
|
5
|
+
}
|
|
6
|
+
//# sourceMappingURL=join-date-time.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"join-date-time.js","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/join-date-time.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AAEtC,MAAM,UAAU,YAAY,CAAC,UAAkB,EAAE,UAAkB;IACjE,OAAO,UAAG,UAAU,cAAI,UAAU,CAAE,CAAC;AACvC,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nexport function joinDateTime(dateString: string, timeString: string) {\n return `${dateString}T${timeString}`;\n}\n"]}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Parses date string and returns Date object or null.
|
|
3
|
+
*
|
|
4
|
+
* We cannot use new Date(string) constructor, because it produces GMT time that may have different date than the local.
|
|
5
|
+
*/
|
|
6
|
+
export declare function parseDate(value: string): Date;
|
|
7
|
+
export declare function parseDate(value: string, strict: boolean): Date | null;
|
|
8
|
+
//# sourceMappingURL=parse-date.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"parse-date.d.ts","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/parse-date.ts"],"names":[],"mappings":"AAGA;;;;GAIG;AACH,wBAAgB,SAAS,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;AAC/C,wBAAgB,SAAS,CAAC,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,OAAO,GAAG,IAAI,GAAG,IAAI,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
export function parseDate(value, strict) {
|
|
4
|
+
if (strict === void 0) { strict = false; }
|
|
5
|
+
var _a = value.split('-'), yearString = _a[0], monthString = _a[1], dayString = _a[2];
|
|
6
|
+
var year = Number(yearString);
|
|
7
|
+
var month = Number(monthString);
|
|
8
|
+
var day = Number(dayString);
|
|
9
|
+
if (strict) {
|
|
10
|
+
if (isNaN(year) || isNaN(month) || isNaN(day)) {
|
|
11
|
+
return null;
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
return new Date(year, (month || 1) - 1, day || 1);
|
|
15
|
+
}
|
|
16
|
+
//# sourceMappingURL=parse-date.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"parse-date.js","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/parse-date.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AAStC,MAAM,UAAU,SAAS,CAAC,KAAa,EAAE,MAAc;IAAd,uBAAA,EAAA,cAAc;IAC/C,IAAA,KAAuC,KAAK,CAAC,KAAK,CAAC,GAAG,CAAC,EAAtD,UAAU,QAAA,EAAE,WAAW,QAAA,EAAE,SAAS,QAAoB,CAAC;IAE9D,IAAM,IAAI,GAAG,MAAM,CAAC,UAAU,CAAC,CAAC;IAChC,IAAM,KAAK,GAAG,MAAM,CAAC,WAAW,CAAC,CAAC;IAClC,IAAM,GAAG,GAAG,MAAM,CAAC,SAAS,CAAC,CAAC;IAE9B,IAAI,MAAM,EAAE;QACV,IAAI,KAAK,CAAC,IAAI,CAAC,IAAI,KAAK,CAAC,KAAK,CAAC,IAAI,KAAK,CAAC,GAAG,CAAC,EAAE;YAC7C,OAAO,IAAI,CAAC;SACb;KACF;IAED,OAAO,IAAI,IAAI,CAAC,IAAI,EAAE,CAAC,KAAK,IAAI,CAAC,CAAC,GAAG,CAAC,EAAE,GAAG,IAAI,CAAC,CAAC,CAAC;AACpD,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\n\n/**\n * Parses date string and returns Date object or null.\n *\n * We cannot use new Date(string) constructor, because it produces GMT time that may have different date than the local.\n */\nexport function parseDate(value: string): Date;\nexport function parseDate(value: string, strict: boolean): Date | null;\nexport function parseDate(value: string, strict = false): Date | null {\n const [yearString, monthString, dayString] = value.split('-');\n\n const year = Number(yearString);\n const month = Number(monthString);\n const day = Number(dayString);\n\n if (strict) {\n if (isNaN(year) || isNaN(month) || isNaN(day)) {\n return null;\n }\n }\n\n return new Date(year, (month || 1) - 1, day || 1);\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"parse-timezone-offset.d.ts","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/parse-timezone-offset.ts"],"names":[],"mappings":"AAKA;;GAEG;AACH,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAexD"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
import { getBrowserTimezoneOffset } from './get-browser-timezone-offset';
|
|
4
|
+
/**
|
|
5
|
+
* Extracts timezone offset from ISO8601 date string.
|
|
6
|
+
*/
|
|
7
|
+
export function parseTimezoneOffset(date) {
|
|
8
|
+
var _a = date.split('T'), time = _a[1];
|
|
9
|
+
var _b = time.split(/(-|\+)/), signCharacter = _b[1], offsetPart = _b[2];
|
|
10
|
+
if (signCharacter && offsetPart) {
|
|
11
|
+
var _c = offsetPart.split(':'), offsetHours = _c[0], offsetMinutes = _c[1];
|
|
12
|
+
return Number(signCharacter + '1') * (Number(offsetHours) * 60 + Number(offsetMinutes));
|
|
13
|
+
}
|
|
14
|
+
var utcTimezoneIndicator = date.indexOf('Z');
|
|
15
|
+
if (utcTimezoneIndicator !== -1) {
|
|
16
|
+
return 0;
|
|
17
|
+
}
|
|
18
|
+
return getBrowserTimezoneOffset();
|
|
19
|
+
}
|
|
20
|
+
//# sourceMappingURL=parse-timezone-offset.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"parse-timezone-offset.js","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/parse-timezone-offset.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AAEtC,OAAO,EAAE,wBAAwB,EAAE,MAAM,+BAA+B,CAAC;AAEzE;;GAEG;AACH,MAAM,UAAU,mBAAmB,CAAC,IAAY;IACxC,IAAA,KAAW,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,EAAvB,IAAI,QAAmB,CAAC;IAC3B,IAAA,KAAgC,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,EAAjD,aAAa,QAAA,EAAE,UAAU,QAAwB,CAAC;IAE3D,IAAI,aAAa,IAAI,UAAU,EAAE;QACzB,IAAA,KAA+B,UAAU,CAAC,KAAK,CAAC,GAAG,CAAC,EAAnD,WAAW,QAAA,EAAE,aAAa,QAAyB,CAAC;QAC3D,OAAO,MAAM,CAAC,aAAa,GAAG,GAAG,CAAC,GAAG,CAAC,MAAM,CAAC,WAAW,CAAC,GAAG,EAAE,GAAG,MAAM,CAAC,aAAa,CAAC,CAAC,CAAC;KACzF;IAED,IAAM,oBAAoB,GAAG,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;IAC/C,IAAI,oBAAoB,KAAK,CAAC,CAAC,EAAE;QAC/B,OAAO,CAAC,CAAC;KACV;IAED,OAAO,wBAAwB,EAAE,CAAC;AACpC,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport { getBrowserTimezoneOffset } from './get-browser-timezone-offset';\n\n/**\n * Extracts timezone offset from ISO8601 date string.\n */\nexport function parseTimezoneOffset(date: string): number {\n const [, time] = date.split('T');\n const [, signCharacter, offsetPart] = time.split(/(-|\\+)/);\n\n if (signCharacter && offsetPart) {\n const [offsetHours, offsetMinutes] = offsetPart.split(':');\n return Number(signCharacter + '1') * (Number(offsetHours) * 60 + Number(offsetMinutes));\n }\n\n const utcTimezoneIndicator = date.indexOf('Z');\n if (utcTimezoneIndicator !== -1) {\n return 0;\n }\n\n return getBrowserTimezoneOffset();\n}\n"]}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Re-formats an ISO8601 date string so that it is expressed using the
|
|
3
|
+
* target timezone offset. The returned date string still represents the
|
|
4
|
+
* same instant in time, but contains no visible offset.
|
|
5
|
+
*
|
|
6
|
+
* Example:
|
|
7
|
+
* ```
|
|
8
|
+
* shiftTimezoneOffset("2020-01-01T09:00:00+03:00", 2 * 60) === "2020-01-01T08:00:00"
|
|
9
|
+
* ```
|
|
10
|
+
*/
|
|
11
|
+
export declare function shiftTimezoneOffset(dateString: string, targetTimezoneOffset: number): string;
|
|
12
|
+
//# sourceMappingURL=shift-timezone-offset.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"shift-timezone-offset.d.ts","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/shift-timezone-offset.ts"],"names":[],"mappings":"AASA;;;;;;;;;GASG;AACH,wBAAgB,mBAAmB,CAAC,UAAU,EAAE,MAAM,EAAE,oBAAoB,EAAE,MAAM,UAUnF"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
import { addMinutes } from 'date-fns';
|
|
4
|
+
import { joinDateTime } from '.';
|
|
5
|
+
import { formatDate } from './format-date';
|
|
6
|
+
import { formatTime } from './format-time';
|
|
7
|
+
import { parseTimezoneOffset } from './parse-timezone-offset';
|
|
8
|
+
/**
|
|
9
|
+
* Re-formats an ISO8601 date string so that it is expressed using the
|
|
10
|
+
* target timezone offset. The returned date string still represents the
|
|
11
|
+
* same instant in time, but contains no visible offset.
|
|
12
|
+
*
|
|
13
|
+
* Example:
|
|
14
|
+
* ```
|
|
15
|
+
* shiftTimezoneOffset("2020-01-01T09:00:00+03:00", 2 * 60) === "2020-01-01T08:00:00"
|
|
16
|
+
* ```
|
|
17
|
+
*/
|
|
18
|
+
export function shiftTimezoneOffset(dateString, targetTimezoneOffset) {
|
|
19
|
+
var _a = dateString.split('T'), datePart = _a[0], timeAndOffsetPart = _a[1];
|
|
20
|
+
var timePart = timeAndOffsetPart.split(/-|\+|Z/)[0];
|
|
21
|
+
var valueWithoutOffset = joinDateTime(datePart, timePart);
|
|
22
|
+
var originalTimezoneOffset = parseTimezoneOffset(dateString);
|
|
23
|
+
var date = new Date(valueWithoutOffset);
|
|
24
|
+
var adjustedDate = addMinutes(date, targetTimezoneOffset - originalTimezoneOffset);
|
|
25
|
+
return joinDateTime(formatDate(adjustedDate), formatTime(adjustedDate));
|
|
26
|
+
}
|
|
27
|
+
//# sourceMappingURL=shift-timezone-offset.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"shift-timezone-offset.js","sourceRoot":"","sources":["../../../../../src/internal/utils/date-time/shift-timezone-offset.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AAEtC,OAAO,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AACtC,OAAO,EAAE,YAAY,EAAE,MAAM,GAAG,CAAC;AACjC,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC;AAE9D;;;;;;;;;GASG;AACH,MAAM,UAAU,mBAAmB,CAAC,UAAkB,EAAE,oBAA4B;IAC5E,IAAA,KAAgC,UAAU,CAAC,KAAK,CAAC,GAAG,CAAC,EAApD,QAAQ,QAAA,EAAE,iBAAiB,QAAyB,CAAC;IACrD,IAAA,QAAQ,GAAI,iBAAiB,CAAC,KAAK,CAAC,QAAQ,CAAC,GAArC,CAAsC;IACrD,IAAM,kBAAkB,GAAG,YAAY,CAAC,QAAQ,EAAE,QAAQ,CAAC,CAAC;IAC5D,IAAM,sBAAsB,GAAG,mBAAmB,CAAC,UAAU,CAAC,CAAC;IAE/D,IAAM,IAAI,GAAG,IAAI,IAAI,CAAC,kBAAkB,CAAC,CAAC;IAC1C,IAAM,YAAY,GAAG,UAAU,CAAC,IAAI,EAAE,oBAAoB,GAAG,sBAAsB,CAAC,CAAC;IAErF,OAAO,YAAY,CAAC,UAAU,CAAC,YAAY,CAAC,EAAE,UAAU,CAAC,YAAY,CAAC,CAAC,CAAC;AAC1E,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport { addMinutes } from 'date-fns';\nimport { joinDateTime } from '.';\nimport { formatDate } from './format-date';\nimport { formatTime } from './format-time';\nimport { parseTimezoneOffset } from './parse-timezone-offset';\n\n/**\n * Re-formats an ISO8601 date string so that it is expressed using the\n * target timezone offset. The returned date string still represents the\n * same instant in time, but contains no visible offset.\n *\n * Example:\n * ```\n * shiftTimezoneOffset(\"2020-01-01T09:00:00+03:00\", 2 * 60) === \"2020-01-01T08:00:00\"\n * ```\n */\nexport function shiftTimezoneOffset(dateString: string, targetTimezoneOffset: number) {\n const [datePart, timeAndOffsetPart] = dateString.split('T');\n const [timePart] = timeAndOffsetPart.split(/-|\\+|Z/);\n const valueWithoutOffset = joinDateTime(datePart, timePart);\n const originalTimezoneOffset = parseTimezoneOffset(dateString);\n\n const date = new Date(valueWithoutOffset);\n const adjustedDate = addMinutes(date, targetTimezoneOffset - originalTimezoneOffset);\n\n return joinDateTime(formatDate(adjustedDate), formatTime(adjustedDate));\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/internal/utils/strings/index.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/internal/utils/strings/index.ts"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AAEtC,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nexport { joinStrings } from './join-strings';\nexport { padLeftZeros } from './pad-left-zeros';\n"]}
|