@aurodesignsystem-dev/auro-formkit 0.0.0-pr1497.5 → 0.0.0-pr1500.0
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/checkbox/demo/customize.min.js +1 -1
- package/components/checkbox/demo/getting-started.min.js +1 -1
- package/components/checkbox/demo/index.min.js +1 -1
- package/components/checkbox/dist/index.js +1 -1
- package/components/checkbox/dist/registered.js +1 -1
- package/components/combobox/demo/customize.min.js +3 -3
- package/components/combobox/demo/getting-started.min.js +3 -3
- package/components/combobox/demo/index.min.js +3 -3
- package/components/combobox/dist/index.js +3 -3
- package/components/combobox/dist/registered.js +3 -3
- package/components/counter/demo/customize.min.js +2 -2
- package/components/counter/demo/index.min.js +2 -2
- package/components/counter/dist/index.js +1 -1
- package/components/counter/dist/registered.js +1 -1
- package/components/datepicker/demo/customize.md +963 -430
- package/components/datepicker/demo/customize.min.js +3 -3
- package/components/datepicker/demo/index.md +0 -1
- package/components/datepicker/demo/index.min.js +3 -3
- package/components/datepicker/dist/index.js +3 -3
- package/components/datepicker/dist/registered.js +3 -3
- package/components/dropdown/demo/customize.min.js +1 -1
- package/components/dropdown/demo/getting-started.min.js +1 -1
- package/components/dropdown/demo/index.min.js +1 -1
- package/components/dropdown/dist/index.js +1 -1
- package/components/dropdown/dist/registered.js +1 -1
- package/components/form/demo/customize.min.js +13 -13
- package/components/form/demo/getting-started.min.js +13 -13
- package/components/form/demo/index.min.js +13 -13
- package/components/form/demo/registerDemoDeps.min.js +13 -13
- package/components/input/demo/customize.md +541 -472
- package/components/input/demo/customize.min.js +1 -1
- package/components/input/demo/getting-started.min.js +1 -1
- package/components/input/demo/index.min.js +1 -1
- package/components/input/dist/index.js +1 -1
- package/components/input/dist/registered.js +1 -1
- package/components/radio/demo/customize.min.js +1 -1
- package/components/radio/demo/getting-started.min.js +1 -1
- package/components/radio/demo/index.min.js +1 -1
- package/components/radio/dist/index.js +1 -1
- package/components/radio/dist/registered.js +1 -1
- package/components/select/demo/customize.min.js +2 -2
- package/components/select/demo/getting-started.min.js +2 -2
- package/components/select/demo/index.min.js +2 -2
- package/components/select/dist/index.js +2 -2
- package/components/select/dist/registered.js +2 -2
- package/custom-elements.json +1489 -1489
- package/package.json +1 -1
|
@@ -5,81 +5,28 @@
|
|
|
5
5
|
<span slot="mobileToggleCollapsed">View More</span>
|
|
6
6
|
<span slot="mobileToggleExpanded">View Less</span>
|
|
7
7
|
<auro-anchorlink fluid href="#appearance">Appearance</auro-anchorlink>
|
|
8
|
-
<auro-anchorlink fluid href="#layout" class="level2 body-xs">Shape, Size & Layout</auro-anchorlink>
|
|
9
|
-
<auro-anchorlink fluid href="#background" class="level2 body-xs">Light vs. Dark Background</auro-anchorlink>
|
|
10
8
|
<auro-anchorlink fluid href="#placement" class="level2 body-xs">Bib Placement</auro-anchorlink>
|
|
9
|
+
<auro-anchorlink fluid href="#cssParts" class="level2 body-xs">CSS Shadow Parts</auro-anchorlink>
|
|
11
10
|
<auro-anchorlink fluid href="#breakpoint" class="level2 body-xs">Fullscreen Breakpoint</auro-anchorlink>
|
|
11
|
+
<auro-anchorlink fluid href="#background" class="level2 body-xs">Light vs. Dark Background</auro-anchorlink>
|
|
12
|
+
<auro-anchorlink fluid href="#localization" class="level2 body-xs">Localization</auro-anchorlink>
|
|
13
|
+
<auro-anchorlink fluid href="#layout" class="level2 body-xs">Shape, Size & Layout</auro-anchorlink>
|
|
12
14
|
<auro-anchorlink fluid href="#cssTokens" class="level2 body-xs">Tokens</auro-anchorlink>
|
|
13
|
-
<auro-anchorlink fluid href="#cssParts" class="level2 body-xs">CSS Shadow Parts</auro-anchorlink>
|
|
14
15
|
<auro-anchorlink fluid href="#customBehavior">Behavior</auro-anchorlink>
|
|
15
|
-
<auro-anchorlink fluid href="#
|
|
16
|
+
<auro-anchorlink fluid href="#customValidation" class="level2 body-xs">Custom Validation</auro-anchorlink>
|
|
16
17
|
<auro-anchorlink fluid href="#disableComponent" class="level2 body-xs">Disable Component</auro-anchorlink>
|
|
17
|
-
<auro-anchorlink fluid href="#requireSelection" class="level2 body-xs">Require Selection</auro-anchorlink>
|
|
18
18
|
<auro-anchorlink fluid href="#forceError" class="level2 body-xs">Force Error State</auro-anchorlink>
|
|
19
|
-
<auro-anchorlink fluid href="#
|
|
20
|
-
<auro-anchorlink fluid href="#noValidate" class="level2 body-xs">No Validation</auro-anchorlink>
|
|
19
|
+
<auro-anchorlink fluid href="#inputMode" class="level2 body-xs">Input Mode</auro-anchorlink>
|
|
21
20
|
<auro-anchorlink fluid href="#minMaxDate" class="level2 body-xs">Min/Max Date</auro-anchorlink>
|
|
22
21
|
<auro-anchorlink fluid href="#monthNames" class="level2 body-xs">Month Names</auro-anchorlink>
|
|
23
|
-
<auro-anchorlink fluid href="#
|
|
22
|
+
<auro-anchorlink fluid href="#noValidate" class="level2 body-xs">No Validation</auro-anchorlink>
|
|
23
|
+
<auro-anchorlink fluid href="#requireSelection" class="level2 body-xs">Require Selection</auro-anchorlink>
|
|
24
24
|
</auro-nav>
|
|
25
25
|
</nav>
|
|
26
26
|
<div class="mainContent">
|
|
27
27
|
<div class="scrollWrapper">
|
|
28
28
|
<section>
|
|
29
29
|
<auro-header level="2" id="appearance">Appearance</auro-header>
|
|
30
|
-
<auro-header level="3" id="layout">Shape, Size & Layout</auro-header>
|
|
31
|
-
<p>The <code>shape</code>, <code>size</code> and <code>layout</code> attributes work in collaboration to control the overall architecture of the component.</p>
|
|
32
|
-
<p>See the <a href="./design.html">Design page</a> for a detailed breakdown.</p>
|
|
33
|
-
<auro-header level="3" id="background">Light vs. Dark Background</auro-header>
|
|
34
|
-
<p>The <code>appearance</code> attribute defines whether the component renders on lighter or darker backgrounds. Supported values are <code>default</code> and <code>inverse</code>. The default value is <code>default</code>.</p>
|
|
35
|
-
<div class="exampleWrapper">
|
|
36
|
-
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/basic.html) -->
|
|
37
|
-
<!-- The below content is automatically added from ./../apiExamples/basic.html -->
|
|
38
|
-
<auro-datepicker>
|
|
39
|
-
<span slot="ariaLabel.bib.close">Close Calendar</span>
|
|
40
|
-
<span slot="bib.fullscreen.headline">Datepicker Headline</span>
|
|
41
|
-
<span slot="fromLabel">Choose a date</span>
|
|
42
|
-
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
43
|
-
</auro-datepicker>
|
|
44
|
-
<!-- AURO-GENERATED-CONTENT:END -->
|
|
45
|
-
</div>
|
|
46
|
-
<auro-accordion alignRight>
|
|
47
|
-
<span slot="trigger">See code</span>
|
|
48
|
-
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/basic.html) -->
|
|
49
|
-
<!-- The below code snippet is automatically added from ./../apiExamples/basic.html -->
|
|
50
|
-
|
|
51
|
-
<pre class="language-html"><code class="language-html"><auro-datepicker>
|
|
52
|
-
<span slot="ariaLabel.bib.close">Close Calendar</span>
|
|
53
|
-
<span slot="bib.fullscreen.headline">Datepicker Headline</span>
|
|
54
|
-
<span slot="fromLabel">Choose a date</span>
|
|
55
|
-
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
56
|
-
</auro-datepicker></code></pre>
|
|
57
|
-
<!-- AURO-GENERATED-CONTENT:END -->
|
|
58
|
-
</auro-accordion>
|
|
59
|
-
<div class="exampleWrapper--ondark">
|
|
60
|
-
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/appearance-inverse.html) -->
|
|
61
|
-
<!-- The below content is automatically added from ./../apiExamples/appearance-inverse.html -->
|
|
62
|
-
<auro-datepicker appearance="inverse">
|
|
63
|
-
<span slot="ariaLabel.bib.close">Close Calendar</span>
|
|
64
|
-
<span slot="bib.fullscreen.headline">Datepicker Headline</span>
|
|
65
|
-
<span slot="fromLabel">Choose a date</span>
|
|
66
|
-
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
67
|
-
</auro-datepicker>
|
|
68
|
-
<!-- AURO-GENERATED-CONTENT:END -->
|
|
69
|
-
</div>
|
|
70
|
-
<auro-accordion alignRight>
|
|
71
|
-
<span slot="trigger">See code</span>
|
|
72
|
-
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/appearance-inverse.html) -->
|
|
73
|
-
<!-- The below code snippet is automatically added from ./../apiExamples/appearance-inverse.html -->
|
|
74
|
-
|
|
75
|
-
<pre class="language-html"><code class="language-html"><auro-datepicker appearance="inverse">
|
|
76
|
-
<span slot="ariaLabel.bib.close">Close Calendar</span>
|
|
77
|
-
<span slot="bib.fullscreen.headline">Datepicker Headline</span>
|
|
78
|
-
<span slot="fromLabel">Choose a date</span>
|
|
79
|
-
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
80
|
-
</auro-datepicker></code></pre>
|
|
81
|
-
<!-- AURO-GENERATED-CONTENT:END -->
|
|
82
|
-
</auro-accordion>
|
|
83
30
|
<auro-header level="3" id="placement">Bib Placement</auro-header>
|
|
84
31
|
<p>The bib position can be customized with <code>placement</code>, <code>offset</code>, <code>flip</code>, <code>autoPlacement</code>, and <code>shift</code> attributes.</p>
|
|
85
32
|
<div class="exampleWrapper">
|
|
@@ -154,6 +101,78 @@
|
|
|
154
101
|
</div></code></pre>
|
|
155
102
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
156
103
|
</auro-accordion>
|
|
104
|
+
</section>
|
|
105
|
+
<section>
|
|
106
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../docs/partials/customize/css-parts.md) -->
|
|
107
|
+
<!-- The below content is automatically added from ./../docs/partials/customize/css-parts.md -->
|
|
108
|
+
<auro-header level="3" id="cssParts">CSS Shadow Parts</auro-header>
|
|
109
|
+
<p>CSS Shadow Parts allow you to style elements inside a web component's shadow DOM using the <code>::part()</code> pseudo-element. The following parts are exposed by <code><auro-datepicker></code>.</p>
|
|
110
|
+
<table class="auro_table">
|
|
111
|
+
<thead>
|
|
112
|
+
<tr>
|
|
113
|
+
<th>Part</th>
|
|
114
|
+
<th>Description</th>
|
|
115
|
+
</tr>
|
|
116
|
+
</thead>
|
|
117
|
+
<tbody>
|
|
118
|
+
<tr><td><code>dropdown</code></td><td>The outer dropdown container.</td></tr>
|
|
119
|
+
<tr><td><code>trigger</code></td><td>The trigger content container.</td></tr>
|
|
120
|
+
<tr><td><code>input</code></td><td>The date input element(s).</td></tr>
|
|
121
|
+
<tr><td><code>calendarWrapper</code></td><td>The calendar bib sizing container.</td></tr>
|
|
122
|
+
<tr><td><code>calendar</code></td><td>The calendar element.</td></tr>
|
|
123
|
+
<tr><td><code>helpTextSpan</code></td><td>The help text container wrapper.</td></tr>
|
|
124
|
+
<tr><td><code>helpText</code></td><td>The help text element.</td></tr>
|
|
125
|
+
</tbody>
|
|
126
|
+
</table>
|
|
127
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
128
|
+
<div class="exampleWrapper">
|
|
129
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=../apiExamples/css-parts.html) -->
|
|
130
|
+
<!-- The below content is automatically added from ../apiExamples/css-parts.html -->
|
|
131
|
+
<style>
|
|
132
|
+
auro-datepicker.css-parts-demo::part(trigger) {
|
|
133
|
+
border-color: orange;
|
|
134
|
+
}
|
|
135
|
+
auro-datepicker.css-parts-demo::part(helpText) {
|
|
136
|
+
color: green;
|
|
137
|
+
}
|
|
138
|
+
auro-datepicker.css-parts-demo::part(calendarWrapper) {
|
|
139
|
+
max-height: 400px;
|
|
140
|
+
}
|
|
141
|
+
</style>
|
|
142
|
+
<auro-datepicker class="css-parts-demo">
|
|
143
|
+
<span slot="fromLabel">CSS Parts Example</span>
|
|
144
|
+
<span slot="helpText">This datepicker has custom styles applied via CSS Shadow Parts.</span>
|
|
145
|
+
<span slot="bib.fullscreen.headline">Select Date</span>
|
|
146
|
+
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
147
|
+
</auro-datepicker>
|
|
148
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
149
|
+
</div>
|
|
150
|
+
<auro-accordion alignRight>
|
|
151
|
+
<span slot="trigger">See code</span>
|
|
152
|
+
<!-- AURO-GENERATED-CONTENT:START (CODE:src=../apiExamples/css-parts.html) -->
|
|
153
|
+
<!-- The below code snippet is automatically added from ../apiExamples/css-parts.html -->
|
|
154
|
+
|
|
155
|
+
<pre class="language-html"><code class="language-html"><style>
|
|
156
|
+
auro-datepicker.css-parts-demo::part(trigger) {
|
|
157
|
+
border-color: orange;
|
|
158
|
+
}
|
|
159
|
+
auro-datepicker.css-parts-demo::part(helpText) {
|
|
160
|
+
color: green;
|
|
161
|
+
}
|
|
162
|
+
auro-datepicker.css-parts-demo::part(calendarWrapper) {
|
|
163
|
+
max-height: 400px;
|
|
164
|
+
}
|
|
165
|
+
</style>
|
|
166
|
+
<auro-datepicker class="css-parts-demo">
|
|
167
|
+
<span slot="fromLabel">CSS Parts Example</span>
|
|
168
|
+
<span slot="helpText">This datepicker has custom styles applied via CSS Shadow Parts.</span>
|
|
169
|
+
<span slot="bib.fullscreen.headline">Select Date</span>
|
|
170
|
+
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
171
|
+
</auro-datepicker></code></pre>
|
|
172
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
173
|
+
</auro-accordion>
|
|
174
|
+
</section>
|
|
175
|
+
<section>
|
|
157
176
|
<auro-header level="3" id="breakpoint">Fullscreen Breakpoint</auro-header>
|
|
158
177
|
<p>The <code>fullscreenBreakpoint</code> attribute defines the screen size breakpoint at which the dropdown switches to fullscreen mode on mobile. Supported values are <code>xs</code>, <code>sm</code>, <code>md</code>, <code>lg</code>, <code>xl</code>, and <code>disabled</code>. The default value is <code>sm</code>.</p>
|
|
159
178
|
<div class="exampleWrapper">
|
|
@@ -182,85 +201,374 @@
|
|
|
182
201
|
</auro-accordion>
|
|
183
202
|
</section>
|
|
184
203
|
<section>
|
|
185
|
-
<auro-header level="3" id="
|
|
186
|
-
<p>The
|
|
187
|
-
<
|
|
188
|
-
<!-- AURO-GENERATED-CONTENT:START (
|
|
189
|
-
<!-- The below
|
|
204
|
+
<auro-header level="3" id="background">Light vs. Dark Background</auro-header>
|
|
205
|
+
<p>The <code>appearance</code> attribute defines whether the component renders on lighter or darker backgrounds. Supported values are <code>default</code> and <code>inverse</code>. The default value is <code>default</code>.</p>
|
|
206
|
+
<div class="exampleWrapper">
|
|
207
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/basic.html) -->
|
|
208
|
+
<!-- The below content is automatically added from ./../apiExamples/basic.html -->
|
|
209
|
+
<auro-datepicker>
|
|
210
|
+
<span slot="ariaLabel.bib.close">Close Calendar</span>
|
|
211
|
+
<span slot="bib.fullscreen.headline">Datepicker Headline</span>
|
|
212
|
+
<span slot="fromLabel">Choose a date</span>
|
|
213
|
+
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
214
|
+
</auro-datepicker>
|
|
215
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
216
|
+
</div>
|
|
217
|
+
<auro-accordion alignRight>
|
|
218
|
+
<span slot="trigger">See code</span>
|
|
219
|
+
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/basic.html) -->
|
|
220
|
+
<!-- The below code snippet is automatically added from ./../apiExamples/basic.html -->
|
|
190
221
|
|
|
191
|
-
<pre class="language-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
// datepicker
|
|
198
|
-
--ds-auro-datepicker-range-input-divider-color: var(--ds-basic-color-border-bold, #{v.$ds-basic-color-border-bold});
|
|
199
|
-
--ds-auro-datepicker-error-icon-color: var(--ds-basic-color-status-error, #{v.$ds-basic-color-status-error});
|
|
200
|
-
--ds-auro-datepicker-label-text-color: var(--ds-basic-color-texticon-muted, #{v.$ds-basic-color-texticon-muted});
|
|
201
|
-
--ds-auro-datepicker-outline-color: transparent;
|
|
202
|
-
|
|
203
|
-
// calendar
|
|
204
|
-
--ds-auro-calendar-mobile-header-container-color: var(--ds-basic-color-surface-default, #{v.$ds-basic-color-surface-default});
|
|
205
|
-
--ds-auro-calendar-mobile-header-divider-color: var(--ds-basic-color-border-divider, #{v.$ds-basic-color-border-divider});
|
|
206
|
-
--ds-auro-calendar-mobile-header-text-color: var(--ds-basic-color-texticon-muted, #{v.$ds-basic-color-texticon-muted});
|
|
207
|
-
--ds-auro-calendar-nav-btn-border-color: transparent;
|
|
208
|
-
--ds-auro-calendar-nav-btn-chevron-color: var(--ds-basic-color-brand-primary, #{v.$ds-basic-color-brand-primary});
|
|
209
|
-
--ds-auro-calendar-nav-btn-container-color: transparent;
|
|
210
|
-
--ds-auro-calendar-month-container-color: var(--ds-basic-color-surface-default, #{v.$ds-basic-color-surface-default});
|
|
211
|
-
--ds-auro-calendar-month-divider-color: var(--ds-basic-color-border-divider, #{v.$ds-basic-color-border-divider});
|
|
212
|
-
--ds-auro-calendar-month-header-color: var(--ds-basic-color-texticon-default, #{v.$ds-basic-color-texticon-default});
|
|
213
|
-
--ds-auro-calendar-cell-border-color: transparent;
|
|
214
|
-
--ds-auro-calendar-cell-container-color: transparent;
|
|
215
|
-
--ds-auro-calendar-cell-in-range-color: var(--ds-advanced-color-shared-background-muted, #{v.$ds-advanced-color-shared-background-muted});
|
|
216
|
-
--ds-auro-calendar-cell-price-text-color: var(--ds-basic-color-texticon-default, #{v.$ds-basic-color-texticon-default});
|
|
217
|
-
--ds-auro-calendar-cell-text-color: var(--ds-basic-color-texticon-default, #{v.$ds-basic-color-texticon-default});
|
|
218
|
-
}
|
|
219
|
-
|
|
220
|
-
:host([ondark]),
|
|
221
|
-
:host([appearance="inverse"]) {
|
|
222
|
-
// datepicker
|
|
223
|
-
--ds-auro-datepicker-range-input-divider-color: var(--ds-basic-color-texticon-inverse-muted, #{v.$ds-basic-color-texticon-inverse-muted});
|
|
224
|
-
--ds-auro-datepicker-error-icon-color: var(--ds-advanced-color-state-error-inverse, #{v.$ds-advanced-color-state-error-inverse});
|
|
225
|
-
--ds-auro-datepicker-label-text-color: var(--ds-basic-color-texticon-inverse-muted, #{v.$ds-basic-color-texticon-inverse-muted});
|
|
226
|
-
--ds-auro-datepicker-outline-color: transparent;
|
|
227
|
-
|
|
228
|
-
// calendar
|
|
229
|
-
--ds-auro-calendar-mobile-header-container-color: var(--ds-basic-color-surface-default, #{v.$ds-basic-color-surface-default});
|
|
230
|
-
--ds-auro-calendar-mobile-header-divider-color: var(--ds-basic-color-border-divider, #{v.$ds-basic-color-border-divider});
|
|
231
|
-
--ds-auro-calendar-mobile-header-text-color: var(--ds-basic-color-texticon-muted, #{v.$ds-basic-color-texticon-muted});
|
|
232
|
-
--ds-auro-calendar-nav-btn-border-color: transparent;
|
|
233
|
-
--ds-auro-calendar-nav-btn-chevron-color: var(--ds-basic-color-brand-primary, #{v.$ds-basic-color-brand-primary});
|
|
234
|
-
--ds-auro-calendar-nav-btn-container-color: transparent;
|
|
235
|
-
--ds-auro-calendar-month-container-color: var(--ds-basic-color-surface-default, #{v.$ds-basic-color-surface-default});
|
|
236
|
-
--ds-auro-calendar-month-divider-color: var(--ds-basic-color-border-divider, #{v.$ds-basic-color-border-divider});
|
|
237
|
-
--ds-auro-calendar-month-header-color: var(--ds-basic-color-texticon-default, #{v.$ds-basic-color-texticon-default});
|
|
238
|
-
--ds-auro-calendar-cell-border-color: transparent;
|
|
239
|
-
--ds-auro-calendar-cell-container-color: transparent;
|
|
240
|
-
--ds-auro-calendar-cell-in-range-color: var(--ds-advanced-color-shared-background-muted, #{v.$ds-advanced-color-shared-background-muted});
|
|
241
|
-
--ds-auro-calendar-cell-price-text-color: var(--ds-basic-color-texticon-default, #{v.$ds-basic-color-texticon-default});
|
|
242
|
-
--ds-auro-calendar-cell-text-color: var(--ds-basic-color-texticon-default, #{v.$ds-basic-color-texticon-default});
|
|
243
|
-
}</code></pre>
|
|
222
|
+
<pre class="language-html"><code class="language-html"><auro-datepicker>
|
|
223
|
+
<span slot="ariaLabel.bib.close">Close Calendar</span>
|
|
224
|
+
<span slot="bib.fullscreen.headline">Datepicker Headline</span>
|
|
225
|
+
<span slot="fromLabel">Choose a date</span>
|
|
226
|
+
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
227
|
+
</auro-datepicker></code></pre>
|
|
244
228
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
<!--
|
|
229
|
+
</auro-accordion>
|
|
230
|
+
<div class="exampleWrapper--ondark">
|
|
231
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/appearance-inverse.html) -->
|
|
232
|
+
<!-- The below content is automatically added from ./../apiExamples/appearance-inverse.html -->
|
|
233
|
+
<auro-datepicker appearance="inverse">
|
|
234
|
+
<span slot="ariaLabel.bib.close">Close Calendar</span>
|
|
235
|
+
<span slot="bib.fullscreen.headline">Datepicker Headline</span>
|
|
236
|
+
<span slot="fromLabel">Choose a date</span>
|
|
237
|
+
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
238
|
+
</auro-datepicker>
|
|
239
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
240
|
+
</div>
|
|
241
|
+
<auro-accordion alignRight>
|
|
242
|
+
<span slot="trigger">See code</span>
|
|
243
|
+
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/appearance-inverse.html) -->
|
|
244
|
+
<!-- The below code snippet is automatically added from ./../apiExamples/appearance-inverse.html -->
|
|
248
245
|
|
|
249
|
-
<pre class="language-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
246
|
+
<pre class="language-html"><code class="language-html"><auro-datepicker appearance="inverse">
|
|
247
|
+
<span slot="ariaLabel.bib.close">Close Calendar</span>
|
|
248
|
+
<span slot="bib.fullscreen.headline">Datepicker Headline</span>
|
|
249
|
+
<span slot="fromLabel">Choose a date</span>
|
|
250
|
+
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
251
|
+
</auro-datepicker></code></pre>
|
|
252
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
253
|
+
</auro-accordion>
|
|
254
|
+
</section>
|
|
255
|
+
<section>
|
|
256
|
+
<auro-header level="3" id="localization">Localization</auro-header>
|
|
257
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../docs/partials/customize/localization.md) -->
|
|
258
|
+
<!-- The below content is automatically added from ./../docs/partials/customize/localization.md -->
|
|
259
|
+
<p>The component supports complete localization, including visible strings, screen reader announcements and locale based date formatting.</p>
|
|
260
|
+
<auro-header level="4" id="localizationTrigger">Trigger</auro-header>
|
|
261
|
+
<auro-header level="4" id="localizationTriggerVisibleStrings">Trigger Visible strings</auro-header>
|
|
262
|
+
<p>The visible strings rendered in the input, trigger, and fullscreen bib are not derived from <code>locale</code> — they are projected through named slots so each language can supply its own translation. Pass a <code><span></code> with the matching <code>slot</code> attribute for every string you need to localize.</p>
|
|
263
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/localization-visible-strings.html) -->
|
|
264
|
+
<!-- The below content is automatically added from ./../apiExamples/localization-visible-strings.html -->
|
|
265
|
+
|
|
266
|
+
<pre class="language-diff"><code class="language-diff"> <auro-datepicker>
|
|
267
|
+
+ <span slot="fromLabel">Abreisedatum</span>
|
|
268
|
+
+ <span slot="helpText">Wählen Sie ein Datum</span>
|
|
269
|
+
+ <span slot="optionalLabel">(freiwillig)</span>
|
|
270
|
+
+ <span slot="bib.fullscreen.headline">Datum auswählen</span>
|
|
271
|
+
+ <span slot="bib.fullscreen.fromLabel">Abreisedatum</span>
|
|
272
|
+
</auro-datepicker></code></pre>
|
|
273
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
274
|
+
<auro-header level="4" id="localizationCalendar">Calendar</auro-header>
|
|
275
|
+
<auro-header level="4" id="localizationCalendarVisibleStrings">Visible strings</auro-header>
|
|
276
|
+
<p>By default, the calendar weekday names rendered above the day grid and the month names rendered in the calendar header are derived from the active <code>locale</code> using the browser's <auro-hyperlink href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl" target="_blank">Intl</auro-hyperlink> API, so they update automatically when <code>locale</code> changes. Use the <code>monthNames</code> attribute to override the derived month names — for example, to supply a translation the browser does not produce or to support a locale the browser does not recognize.</p>
|
|
277
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/localization-calendar-strings.html) -->
|
|
278
|
+
<!-- The below content is automatically added from ./../apiExamples/localization-calendar-strings.html -->
|
|
279
|
+
|
|
280
|
+
<pre class="language-diff"><code class="language-diff">- <auro-datepicker>
|
|
281
|
+
+ <auro-datepicker monthNames='["Januar","Februar","März","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember"]'>
|
|
282
|
+
<span slot="fromLabel">Abreisedatum</span>
|
|
283
|
+
<span slot="helpText">Wählen Sie ein Datum</span>
|
|
284
|
+
</auro-datepicker></code></pre>
|
|
285
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
286
|
+
<auro-header level="4" id="localizationCalendarA11yStrings">Screen reader strings</auro-header>
|
|
287
|
+
<p>Assistive-technology announcements — range descriptors (<code>rangeLabelStart</code>, <code>rangeLabelEnd</code>, <code>rangeLabelBeforeRange</code>, <code>rangeLabelInRange</code>, <code>rangeLabelAfterRange</code>), month navigation labels (<code>navLabelPrevMonth</code>, <code>navLabelNextMonth</code>), and the calendar grid label (<code>calendarGridLabel</code>) — are exposed as individual attributes so they can be translated independently of the visible UI. These strings are not derived from <code>locale</code>; supply translated values for every language you support.</p>
|
|
288
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/localization-screenreader-strings.html) -->
|
|
289
|
+
<!-- The below content is automatically added from ./../apiExamples/localization-screenreader-strings.html -->
|
|
290
|
+
|
|
291
|
+
<pre class="language-diff"><code class="language-diff"> <auro-datepicker
|
|
292
|
+
locale="de-DE"
|
|
293
|
+
range
|
|
294
|
+
+ rangeLabelStart="Startdatum"
|
|
295
|
+
+ rangeLabelEnd="Enddatum"
|
|
296
|
+
+ rangeLabelBeforeRange="vor dem Zeitraum"
|
|
297
|
+
+ rangeLabelInRange="im Zeitraum"
|
|
298
|
+
+ rangeLabelAfterRange="nach dem Zeitraum"
|
|
299
|
+
+ navLabelPrevMonth="Vorheriger Monat"
|
|
300
|
+
+ navLabelNextMonth="Nächster Monat"
|
|
301
|
+
+ calendarGridLabel="Kalendertage des Monats">
|
|
302
|
+
<span slot="fromLabel">Abreise</span>
|
|
303
|
+
<span slot="toLabel">Rückkehr</span>
|
|
304
|
+
<span slot="helpText">Wählen Sie einen Zeitraum</span>
|
|
305
|
+
</auro-datepicker></code></pre>
|
|
306
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
307
|
+
<auro-header level="4" id="localizationDateFormatting">Date formatting</auro-header>
|
|
308
|
+
<p>The <code>locale</code> attribute drives the date format used by the input and the calendar. Setting <code>locale</code> automatically selects the regional format (for example <code>en-US</code> → <code>mm/dd/yyyy</code>, <code>de-DE</code> → <code>dd.mm.yyyy</code>, <code>ja-JP</code> → <code>yyyy/mm/dd</code>), derived from the browser's <code>Intl</code> API, so <code>format</code> does not need to be set manually.</p>
|
|
309
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/localization-locale.html) -->
|
|
310
|
+
<!-- The below content is automatically added from ./../apiExamples/localization-locale.html -->
|
|
311
|
+
|
|
312
|
+
<pre class="language-diff"><code class="language-diff">- <auro-datepicker>
|
|
313
|
+
+ <auro-datepicker locale="de-DE">
|
|
314
|
+
<span slot="fromLabel">Deutsches Datum</span>
|
|
315
|
+
<span slot="helpText">Hilfetext</span>
|
|
316
|
+
<span slot="optionalLabel">(freiwillig)</span>
|
|
317
|
+
</auro-datepicker></code></pre>
|
|
318
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
319
|
+
<p>If no <code>locale</code> attribute is present, the component walks up the DOM looking for the nearest ancestor with a <code>data-locale</code> attribute; if none is found, it defaults to <code>en-US</code>.</p>
|
|
320
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/localization-locale-inherited.html) -->
|
|
321
|
+
<!-- The below content is automatically added from ./../apiExamples/localization-locale-inherited.html -->
|
|
322
|
+
|
|
323
|
+
<pre class="language-diff"><code class="language-diff">+ <div data-locale="ja-JP">
|
|
324
|
+
<auro-datepicker>
|
|
325
|
+
<span slot="fromLabel">継承された ja-JP 日付形式</span>
|
|
326
|
+
<span slot="helpText">ヘルプテキスト</span>
|
|
327
|
+
<span slot="optionalLabel">(任意)</span>
|
|
328
|
+
</auro-datepicker>
|
|
329
|
+
+ </div></code></pre>
|
|
330
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
331
|
+
<p>If <code>format</code> is set alongside <code>locale</code>, <code>format</code> always wins.</p>
|
|
332
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/localization-locale-formatted.html) -->
|
|
333
|
+
<!-- The below content is automatically added from ./../apiExamples/localization-locale-formatted.html -->
|
|
334
|
+
|
|
335
|
+
<pre class="language-diff"><code class="language-diff"> <auro-datepicker
|
|
336
|
+
+ locale="de-DE"
|
|
337
|
+
+ format="mm/dd/yyyy">
|
|
338
|
+
<span slot="fromLabel">Deutsches Datum mit mm/dd/yyyy-Format</span>
|
|
339
|
+
<span slot="helpText">Hilfetext</span>
|
|
340
|
+
<span slot="optionalLabel">(freiwillig)</span>
|
|
341
|
+
</auro-datepicker></code></pre>
|
|
342
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
343
|
+
<div class="exampleWrapper">
|
|
344
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/locale.html) -->
|
|
345
|
+
<!-- The below content is automatically added from ./../apiExamples/locale.html -->
|
|
346
|
+
<div data-locale="de-DE">
|
|
347
|
+
<auro-header level="4" >de-DE Example</auro-header>
|
|
348
|
+
<auro-datepicker
|
|
349
|
+
locale="de-DE"
|
|
350
|
+
range
|
|
351
|
+
rangeLabelStart="Startdatum"
|
|
352
|
+
rangeLabelEnd="Enddatum"
|
|
353
|
+
rangeLabelBeforeRange="vor dem Zeitraum"
|
|
354
|
+
rangeLabelInRange="im Zeitraum"
|
|
355
|
+
rangeLabelAfterRange="nach dem Zeitraum"
|
|
356
|
+
navLabelPrevMonth="Vorheriger Monat"
|
|
357
|
+
navLabelNextMonth="Nächster Monat"
|
|
358
|
+
calendarGridLabel="Kalendertage des Monats">
|
|
359
|
+
<span slot="fromLabel">Deutsches Datum</span>
|
|
360
|
+
<span slot="helpText">Hilfetext</span>
|
|
361
|
+
<span slot="optionalLabel">(freiwillig)</span>
|
|
362
|
+
</auro-datepicker>
|
|
363
|
+
<auro-header level="4" >zh-CN Example</auro-header>
|
|
364
|
+
<auro-datepicker
|
|
365
|
+
locale="zh-CN"
|
|
366
|
+
range
|
|
367
|
+
rangeLabelStart="开始日期"
|
|
368
|
+
rangeLabelEnd="结束日期"
|
|
369
|
+
rangeLabelBeforeRange="在此期间之前"
|
|
370
|
+
rangeLabelInRange="在此期间内"
|
|
371
|
+
rangeLabelAfterRange="在此期间之后"
|
|
372
|
+
navLabelPrevMonth="上个月"
|
|
373
|
+
navLabelNextMonth="下个月"
|
|
374
|
+
calendarGridLabel="本月的日历天数">
|
|
375
|
+
<span slot="fromLabel">中文日期</span>
|
|
376
|
+
<span slot="helpText">帮助文本</span>
|
|
377
|
+
<span slot="optionalLabel">(可选)</span>
|
|
378
|
+
</auro-datepicker>
|
|
379
|
+
<auro-header level="4">Inherited de-DE date-locale Example</auro-header>
|
|
380
|
+
<auro-datepicker
|
|
381
|
+
range
|
|
382
|
+
rangeLabelStart="Startdatum"
|
|
383
|
+
rangeLabelEnd="Enddatum"
|
|
384
|
+
rangeLabelBeforeRange="vor dem Zeitraum"
|
|
385
|
+
rangeLabelInRange="im Zeitraum"
|
|
386
|
+
rangeLabelAfterRange="nach dem Zeitraum"
|
|
387
|
+
navLabelPrevMonth="Vorheriger Monat"
|
|
388
|
+
navLabelNextMonth="Nächster Monat"
|
|
389
|
+
calendarGridLabel="Kalendertage des Monats">
|
|
390
|
+
<span slot="fromLabel">Nächstes `data-locale`-Attributformat (`de-DE` in diesem Fall)</span>
|
|
391
|
+
<span slot="helpText">Hilfetext</span>
|
|
392
|
+
<span slot="optionalLabel">(freiwillig)</span>
|
|
393
|
+
</auro-datepicker>
|
|
394
|
+
<auro-header level="4" >ja-JP with `mm/dd/yyyy` format Example</auro-header>
|
|
395
|
+
<auro-datepicker
|
|
396
|
+
locale="ja-JP"
|
|
397
|
+
format="mm/dd/yyyy"
|
|
398
|
+
range
|
|
399
|
+
rangeLabelStart="開始日"
|
|
400
|
+
rangeLabelEnd="終了日"
|
|
401
|
+
rangeLabelBeforeRange="この期間の前"
|
|
402
|
+
rangeLabelInRange="この期間内"
|
|
403
|
+
rangeLabelAfterRange="この期間の後"
|
|
404
|
+
navLabelPrevMonth="前の月"
|
|
405
|
+
navLabelNextMonth="次の月"
|
|
406
|
+
calendarGridLabel="カレンダーの日付">
|
|
407
|
+
<span slot="fromLabel">明示的な mm/dd/yyyy 形式の ja-JP ロケール</span>
|
|
408
|
+
<span slot="helpText">ヘルプテキスト</span>
|
|
409
|
+
<span slot="optionalLabel">(任意)</span>
|
|
410
|
+
</auro-datepicker>
|
|
411
|
+
</div>
|
|
412
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
413
|
+
</div>
|
|
414
|
+
<auro-accordion alignRight>
|
|
415
|
+
<span slot="trigger">See code</span>
|
|
416
|
+
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/locale.html) -->
|
|
417
|
+
<!-- The below code snippet is automatically added from ./../apiExamples/locale.html -->
|
|
418
|
+
|
|
419
|
+
<pre class="language-html"><code class="language-html"><div data-locale="de-DE">
|
|
420
|
+
<auro-header level="4" >de-DE Example</auro-header>
|
|
421
|
+
<auro-datepicker
|
|
422
|
+
locale="de-DE"
|
|
423
|
+
range
|
|
424
|
+
rangeLabelStart="Startdatum"
|
|
425
|
+
rangeLabelEnd="Enddatum"
|
|
426
|
+
rangeLabelBeforeRange="vor dem Zeitraum"
|
|
427
|
+
rangeLabelInRange="im Zeitraum"
|
|
428
|
+
rangeLabelAfterRange="nach dem Zeitraum"
|
|
429
|
+
navLabelPrevMonth="Vorheriger Monat"
|
|
430
|
+
navLabelNextMonth="Nächster Monat"
|
|
431
|
+
calendarGridLabel="Kalendertage des Monats">
|
|
432
|
+
<span slot="fromLabel">Deutsches Datum</span>
|
|
433
|
+
<span slot="helpText">Hilfetext</span>
|
|
434
|
+
<span slot="optionalLabel">(freiwillig)</span>
|
|
435
|
+
</auro-datepicker>
|
|
436
|
+
<auro-header level="4" >zh-CN Example</auro-header>
|
|
437
|
+
<auro-datepicker
|
|
438
|
+
locale="zh-CN"
|
|
439
|
+
range
|
|
440
|
+
rangeLabelStart="开始日期"
|
|
441
|
+
rangeLabelEnd="结束日期"
|
|
442
|
+
rangeLabelBeforeRange="在此期间之前"
|
|
443
|
+
rangeLabelInRange="在此期间内"
|
|
444
|
+
rangeLabelAfterRange="在此期间之后"
|
|
445
|
+
navLabelPrevMonth="上个月"
|
|
446
|
+
navLabelNextMonth="下个月"
|
|
447
|
+
calendarGridLabel="本月的日历天数">
|
|
448
|
+
<span slot="fromLabel">中文日期</span>
|
|
449
|
+
<span slot="helpText">帮助文本</span>
|
|
450
|
+
<span slot="optionalLabel">(可选)</span>
|
|
451
|
+
</auro-datepicker>
|
|
452
|
+
<auro-header level="4">Inherited de-DE date-locale Example</auro-header>
|
|
453
|
+
<auro-datepicker
|
|
454
|
+
range
|
|
455
|
+
rangeLabelStart="Startdatum"
|
|
456
|
+
rangeLabelEnd="Enddatum"
|
|
457
|
+
rangeLabelBeforeRange="vor dem Zeitraum"
|
|
458
|
+
rangeLabelInRange="im Zeitraum"
|
|
459
|
+
rangeLabelAfterRange="nach dem Zeitraum"
|
|
460
|
+
navLabelPrevMonth="Vorheriger Monat"
|
|
461
|
+
navLabelNextMonth="Nächster Monat"
|
|
462
|
+
calendarGridLabel="Kalendertage des Monats">
|
|
463
|
+
<span slot="fromLabel">Nächstes `data-locale`-Attributformat (`de-DE` in diesem Fall)</span>
|
|
464
|
+
<span slot="helpText">Hilfetext</span>
|
|
465
|
+
<span slot="optionalLabel">(freiwillig)</span>
|
|
466
|
+
</auro-datepicker>
|
|
467
|
+
<auro-header level="4" >ja-JP with `mm/dd/yyyy` format Example</auro-header>
|
|
468
|
+
<auro-datepicker
|
|
469
|
+
locale="ja-JP"
|
|
470
|
+
format="mm/dd/yyyy"
|
|
471
|
+
range
|
|
472
|
+
rangeLabelStart="開始日"
|
|
473
|
+
rangeLabelEnd="終了日"
|
|
474
|
+
rangeLabelBeforeRange="この期間の前"
|
|
475
|
+
rangeLabelInRange="この期間内"
|
|
476
|
+
rangeLabelAfterRange="この期間の後"
|
|
477
|
+
navLabelPrevMonth="前の月"
|
|
478
|
+
navLabelNextMonth="次の月"
|
|
479
|
+
calendarGridLabel="カレンダーの日付">
|
|
480
|
+
<span slot="fromLabel">明示的な mm/dd/yyyy 形式の ja-JP ロケール</span>
|
|
481
|
+
<span slot="helpText">ヘルプテキスト</span>
|
|
482
|
+
<span slot="optionalLabel">(任意)</span>
|
|
483
|
+
</auro-datepicker>
|
|
484
|
+
</div></code></pre>
|
|
485
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
486
|
+
</auro-accordion>
|
|
487
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
488
|
+
<auro-header level="3" id="layout">Shape, Size & Layout</auro-header>
|
|
489
|
+
<p>The <code>shape</code>, <code>size</code> and <code>layout</code> attributes work in collaboration to control the overall architecture of the component.</p>
|
|
490
|
+
<p>See the <a href="./design.html">Design page</a> for a detailed breakdown.</p>
|
|
491
|
+
</section>
|
|
492
|
+
<section>
|
|
493
|
+
<auro-header level="3" id="cssTokens">Tokens</auro-header>
|
|
494
|
+
<p>The component may be restyled by changing the values of the following token(s) for the datepicker, dropdown, and input</p>
|
|
495
|
+
<auro-header level="4" id="cssTokensDatepicker">Datepicker</auro-header>
|
|
496
|
+
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../../datepicker/src/styles/tokens.scss) -->
|
|
497
|
+
<!-- The below code snippet is automatically added from ./../../datepicker/src/styles/tokens.scss -->
|
|
498
|
+
|
|
499
|
+
<pre class="language-scss"><code class="language-scss">/* stylelint-disable color-function-notation */
|
|
500
|
+
|
|
501
|
+
@use "@aurodesignsystem/design-tokens/dist/themes/alaska/SCSSVariables--alaska" as v;
|
|
502
|
+
|
|
503
|
+
:host(:not([ondark])),
|
|
504
|
+
:host(:not([appearance="inverse"])) {
|
|
505
|
+
// datepicker
|
|
506
|
+
--ds-auro-datepicker-range-input-divider-color: var(--ds-basic-color-border-bold, #{v.$ds-basic-color-border-bold});
|
|
507
|
+
--ds-auro-datepicker-error-icon-color: var(--ds-basic-color-status-error, #{v.$ds-basic-color-status-error});
|
|
508
|
+
--ds-auro-datepicker-label-text-color: var(--ds-basic-color-texticon-muted, #{v.$ds-basic-color-texticon-muted});
|
|
509
|
+
--ds-auro-datepicker-outline-color: transparent;
|
|
510
|
+
|
|
511
|
+
// calendar
|
|
512
|
+
--ds-auro-calendar-mobile-header-container-color: var(--ds-basic-color-surface-default, #{v.$ds-basic-color-surface-default});
|
|
513
|
+
--ds-auro-calendar-mobile-header-divider-color: var(--ds-basic-color-border-divider, #{v.$ds-basic-color-border-divider});
|
|
514
|
+
--ds-auro-calendar-mobile-header-text-color: var(--ds-basic-color-texticon-muted, #{v.$ds-basic-color-texticon-muted});
|
|
515
|
+
--ds-auro-calendar-nav-btn-border-color: transparent;
|
|
516
|
+
--ds-auro-calendar-nav-btn-chevron-color: var(--ds-basic-color-brand-primary, #{v.$ds-basic-color-brand-primary});
|
|
517
|
+
--ds-auro-calendar-nav-btn-container-color: transparent;
|
|
518
|
+
--ds-auro-calendar-month-container-color: var(--ds-basic-color-surface-default, #{v.$ds-basic-color-surface-default});
|
|
519
|
+
--ds-auro-calendar-month-divider-color: var(--ds-basic-color-border-divider, #{v.$ds-basic-color-border-divider});
|
|
520
|
+
--ds-auro-calendar-month-header-color: var(--ds-basic-color-texticon-default, #{v.$ds-basic-color-texticon-default});
|
|
521
|
+
--ds-auro-calendar-cell-border-color: transparent;
|
|
522
|
+
--ds-auro-calendar-cell-container-color: transparent;
|
|
523
|
+
--ds-auro-calendar-cell-in-range-color: var(--ds-advanced-color-shared-background-muted, #{v.$ds-advanced-color-shared-background-muted});
|
|
524
|
+
--ds-auro-calendar-cell-price-text-color: var(--ds-basic-color-texticon-default, #{v.$ds-basic-color-texticon-default});
|
|
525
|
+
--ds-auro-calendar-cell-text-color: var(--ds-basic-color-texticon-default, #{v.$ds-basic-color-texticon-default});
|
|
526
|
+
}
|
|
527
|
+
|
|
528
|
+
:host([ondark]),
|
|
529
|
+
:host([appearance="inverse"]) {
|
|
530
|
+
// datepicker
|
|
531
|
+
--ds-auro-datepicker-range-input-divider-color: var(--ds-basic-color-texticon-inverse-muted, #{v.$ds-basic-color-texticon-inverse-muted});
|
|
532
|
+
--ds-auro-datepicker-error-icon-color: var(--ds-advanced-color-state-error-inverse, #{v.$ds-advanced-color-state-error-inverse});
|
|
533
|
+
--ds-auro-datepicker-label-text-color: var(--ds-basic-color-texticon-inverse-muted, #{v.$ds-basic-color-texticon-inverse-muted});
|
|
534
|
+
--ds-auro-datepicker-outline-color: transparent;
|
|
535
|
+
|
|
536
|
+
// calendar
|
|
537
|
+
--ds-auro-calendar-mobile-header-container-color: var(--ds-basic-color-surface-default, #{v.$ds-basic-color-surface-default});
|
|
538
|
+
--ds-auro-calendar-mobile-header-divider-color: var(--ds-basic-color-border-divider, #{v.$ds-basic-color-border-divider});
|
|
539
|
+
--ds-auro-calendar-mobile-header-text-color: var(--ds-basic-color-texticon-muted, #{v.$ds-basic-color-texticon-muted});
|
|
540
|
+
--ds-auro-calendar-nav-btn-border-color: transparent;
|
|
541
|
+
--ds-auro-calendar-nav-btn-chevron-color: var(--ds-basic-color-brand-primary, #{v.$ds-basic-color-brand-primary});
|
|
542
|
+
--ds-auro-calendar-nav-btn-container-color: transparent;
|
|
543
|
+
--ds-auro-calendar-month-container-color: var(--ds-basic-color-surface-default, #{v.$ds-basic-color-surface-default});
|
|
544
|
+
--ds-auro-calendar-month-divider-color: var(--ds-basic-color-border-divider, #{v.$ds-basic-color-border-divider});
|
|
545
|
+
--ds-auro-calendar-month-header-color: var(--ds-basic-color-texticon-default, #{v.$ds-basic-color-texticon-default});
|
|
546
|
+
--ds-auro-calendar-cell-border-color: transparent;
|
|
547
|
+
--ds-auro-calendar-cell-container-color: transparent;
|
|
548
|
+
--ds-auro-calendar-cell-in-range-color: var(--ds-advanced-color-shared-background-muted, #{v.$ds-advanced-color-shared-background-muted});
|
|
549
|
+
--ds-auro-calendar-cell-price-text-color: var(--ds-basic-color-texticon-default, #{v.$ds-basic-color-texticon-default});
|
|
550
|
+
--ds-auro-calendar-cell-text-color: var(--ds-basic-color-texticon-default, #{v.$ds-basic-color-texticon-default});
|
|
551
|
+
}</code></pre>
|
|
552
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
553
|
+
<auro-header level="4" id="cssTokensDropdown">Dropdown</auro-header>
|
|
554
|
+
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../../dropdown/src/styles/tokens.scss) -->
|
|
555
|
+
<!-- The below code snippet is automatically added from ./../../dropdown/src/styles/tokens.scss -->
|
|
556
|
+
|
|
557
|
+
<pre class="language-scss"><code class="language-scss">@use "@aurodesignsystem/design-tokens/dist/themes/alaska/SCSSVariables--alaska" as v;
|
|
558
|
+
@use "@aurodesignsystem/design-tokens/dist/legacy/auro-classic/SCSSVariables" as vac;
|
|
559
|
+
|
|
560
|
+
:host(:not([ondark])),
|
|
561
|
+
:host(:not([appearance="inverse"])) {
|
|
562
|
+
--ds-auro-dropdown-label-text-color: var(--ds-basic-color-texticon-muted, #{v.$ds-basic-color-texticon-muted});
|
|
563
|
+
--ds-auro-dropdown-trigger-background-color: var(--ds-basic-color-surface-default, #{v.$ds-basic-color-surface-default});
|
|
564
|
+
--ds-auro-dropdown-trigger-hover-background-color: var(--ds-basic-color-surface-default, #{v.$ds-basic-color-surface-default});
|
|
565
|
+
--ds-auro-dropdown-trigger-container-color: var(--ds-basic-color-surface-default, #{v.$ds-basic-color-surface-default});
|
|
566
|
+
--ds-auro-dropdown-trigger-border-color: var(--ds-basic-color-border-bold, #{v.$ds-basic-color-border-bold});
|
|
567
|
+
--ds-auro-dropdown-trigger-outline-color: transparent;
|
|
568
|
+
--ds-auro-dropdown-trigger-text-color: var(--ds-basic-color-texticon-default, #{v.$ds-basic-color-texticon-default});
|
|
569
|
+
--ds-auro-dropdownbib-boxshadow-color: var(--ds-elevation-200, #{vac.$ds-elevation-200});
|
|
570
|
+
--ds-auro-dropdownbib-background-color: var(--ds-basic-color-surface-default, #{v.$ds-basic-color-surface-default});
|
|
571
|
+
--ds-auro-dropdownbib-container-color: var(--ds-basic-color-surface-default, #{v.$ds-basic-color-surface-default});
|
|
264
572
|
--ds-auro-dropdownbib-text-color: var(--ds-basic-color-texticon-default, #{v.$ds-basic-color-texticon-default});
|
|
265
573
|
}
|
|
266
574
|
|
|
@@ -279,40 +587,6 @@
|
|
|
279
587
|
--ds-auro-dropdownbib-text-color: var(--ds-basic-color-texticon-inverse, #{v.$ds-basic-color-texticon-inverse});
|
|
280
588
|
}</code></pre>
|
|
281
589
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
282
|
-
<auro-header level="4" id="cssTokensInput">Input</auro-header>
|
|
283
|
-
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../../input/src/styles/tokens.scss) -->
|
|
284
|
-
<!-- The below code snippet is automatically added from ./../../input/src/styles/tokens.scss -->
|
|
285
|
-
|
|
286
|
-
<pre class="language-scss"><code class="language-scss">/* stylelint-disable custom-property-empty-line-before */
|
|
287
|
-
|
|
288
|
-
@use "@aurodesignsystem/design-tokens/dist/themes/alaska/SCSSVariables--alaska" as v;
|
|
289
|
-
|
|
290
|
-
:host(:not([ondark])),
|
|
291
|
-
:host(:not([appearance="inverse"])) {
|
|
292
|
-
--ds-auro-input-border-color: var(--ds-basic-color-border-bold, #{v.$ds-basic-color-border-bold});
|
|
293
|
-
--ds-auro-input-container-color: var(--ds-basic-color-surface-default, #{v.$ds-basic-color-surface-default});
|
|
294
|
-
--ds-auro-input-caret-color: var(--ds-advanced-color-state-focused, #{v.$ds-advanced-color-state-focused});
|
|
295
|
-
--ds-auro-input-label-text-color: var(--ds-basic-color-texticon-muted, #{v.$ds-basic-color-texticon-muted});
|
|
296
|
-
--ds-auro-input-placeholder-text-color: var(--ds-basic-color-texticon-default, #{v.$ds-basic-color-texticon-default});
|
|
297
|
-
--ds-auro-input-text-color: var(--ds-basic-color-texticon-default, #{v.$ds-basic-color-texticon-default});
|
|
298
|
-
--ds-auro-input-error-icon-color: var(--ds-basic-color-status-error, #{v.$ds-basic-color-status-error});
|
|
299
|
-
|
|
300
|
-
--ds-auro-input-outline-color: transparent;
|
|
301
|
-
}
|
|
302
|
-
|
|
303
|
-
:host([ondark]),
|
|
304
|
-
:host([appearance="inverse"]) {
|
|
305
|
-
--ds-auro-input-border-color: var(--ds-basic-color-border-inverse, #{v.$ds-basic-color-border-inverse});
|
|
306
|
-
--ds-auro-input-container-color: var(--ds-advanced-color-shared-background-inverse, #{v.$ds-advanced-color-shared-background-inverse});
|
|
307
|
-
--ds-auro-input-caret-color: var(--ds-advanced-color-state-focused-inverse, #{v.$ds-advanced-color-state-focused-inverse});
|
|
308
|
-
--ds-auro-input-label-text-color: var(--ds-basic-color-texticon-inverse-muted, #{v.$ds-basic-color-texticon-inverse-muted});
|
|
309
|
-
--ds-auro-input-placeholder-text-color: var(--ds-basic-color-texticon-inverse, #{v.$ds-basic-color-texticon-inverse});
|
|
310
|
-
--ds-auro-input-text-color: var(--ds-basic-color-texticon-inverse, #{v.$ds-basic-color-texticon-inverse});
|
|
311
|
-
--ds-auro-input-error-icon-color: var(--ds-advanced-color-state-error-inverse, #{v.$ds-advanced-color-state-error-inverse});
|
|
312
|
-
|
|
313
|
-
--ds-auro-input-outline-color: transparent;
|
|
314
|
-
}</code></pre>
|
|
315
|
-
<!-- AURO-GENERATED-CONTENT:END -->
|
|
316
590
|
<auro-header level="4" id="cssTokensExample">Example</auro-header>
|
|
317
591
|
<p>The following example demonstrates overriding all available datepicker, dropdown, input, and calendar tokens.</p>
|
|
318
592
|
<div class="exampleWrapper">
|
|
@@ -411,86 +685,50 @@
|
|
|
411
685
|
</auro-datepicker></code></pre>
|
|
412
686
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
413
687
|
</auro-accordion>
|
|
414
|
-
</
|
|
415
|
-
|
|
416
|
-
<!--
|
|
417
|
-
|
|
418
|
-
<
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
auro-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
auro-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
auro-datepicker.css-parts-demo::part(calendarWrapper) {
|
|
449
|
-
max-height: 400px;
|
|
450
|
-
}
|
|
451
|
-
</style>
|
|
452
|
-
<auro-datepicker class="css-parts-demo">
|
|
453
|
-
<span slot="fromLabel">CSS Parts Example</span>
|
|
454
|
-
<span slot="helpText">This datepicker has custom styles applied via CSS Shadow Parts.</span>
|
|
455
|
-
<span slot="bib.fullscreen.headline">Select Date</span>
|
|
456
|
-
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
457
|
-
</auro-datepicker>
|
|
458
|
-
<!-- AURO-GENERATED-CONTENT:END -->
|
|
459
|
-
</div>
|
|
460
|
-
<auro-accordion alignRight>
|
|
461
|
-
<span slot="trigger">See code</span>
|
|
462
|
-
<!-- AURO-GENERATED-CONTENT:START (CODE:src=../apiExamples/css-parts.html) -->
|
|
463
|
-
<!-- The below code snippet is automatically added from ../apiExamples/css-parts.html -->
|
|
464
|
-
|
|
465
|
-
<pre class="language-html"><code class="language-html"><style>
|
|
466
|
-
auro-datepicker.css-parts-demo::part(trigger) {
|
|
467
|
-
border-color: orange;
|
|
468
|
-
}
|
|
469
|
-
auro-datepicker.css-parts-demo::part(helpText) {
|
|
470
|
-
color: green;
|
|
471
|
-
}
|
|
472
|
-
auro-datepicker.css-parts-demo::part(calendarWrapper) {
|
|
473
|
-
max-height: 400px;
|
|
474
|
-
}
|
|
475
|
-
</style>
|
|
476
|
-
<auro-datepicker class="css-parts-demo">
|
|
477
|
-
<span slot="fromLabel">CSS Parts Example</span>
|
|
478
|
-
<span slot="helpText">This datepicker has custom styles applied via CSS Shadow Parts.</span>
|
|
479
|
-
<span slot="bib.fullscreen.headline">Select Date</span>
|
|
480
|
-
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
481
|
-
</auro-datepicker></code></pre>
|
|
482
|
-
<!-- AURO-GENERATED-CONTENT:END -->
|
|
483
|
-
</auro-accordion>
|
|
688
|
+
<auro-header level="4" id="cssTokensInput">Input</auro-header>
|
|
689
|
+
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../../input/src/styles/tokens.scss) -->
|
|
690
|
+
<!-- The below code snippet is automatically added from ./../../input/src/styles/tokens.scss -->
|
|
691
|
+
|
|
692
|
+
<pre class="language-scss"><code class="language-scss">/* stylelint-disable custom-property-empty-line-before */
|
|
693
|
+
|
|
694
|
+
@use "@aurodesignsystem/design-tokens/dist/themes/alaska/SCSSVariables--alaska" as v;
|
|
695
|
+
|
|
696
|
+
:host(:not([ondark])),
|
|
697
|
+
:host(:not([appearance="inverse"])) {
|
|
698
|
+
--ds-auro-input-border-color: var(--ds-basic-color-border-bold, #{v.$ds-basic-color-border-bold});
|
|
699
|
+
--ds-auro-input-container-color: var(--ds-basic-color-surface-default, #{v.$ds-basic-color-surface-default});
|
|
700
|
+
--ds-auro-input-caret-color: var(--ds-advanced-color-state-focused, #{v.$ds-advanced-color-state-focused});
|
|
701
|
+
--ds-auro-input-label-text-color: var(--ds-basic-color-texticon-muted, #{v.$ds-basic-color-texticon-muted});
|
|
702
|
+
--ds-auro-input-placeholder-text-color: var(--ds-basic-color-texticon-default, #{v.$ds-basic-color-texticon-default});
|
|
703
|
+
--ds-auro-input-text-color: var(--ds-basic-color-texticon-default, #{v.$ds-basic-color-texticon-default});
|
|
704
|
+
--ds-auro-input-error-icon-color: var(--ds-basic-color-status-error, #{v.$ds-basic-color-status-error});
|
|
705
|
+
|
|
706
|
+
--ds-auro-input-outline-color: transparent;
|
|
707
|
+
}
|
|
708
|
+
|
|
709
|
+
:host([ondark]),
|
|
710
|
+
:host([appearance="inverse"]) {
|
|
711
|
+
--ds-auro-input-border-color: var(--ds-basic-color-border-inverse, #{v.$ds-basic-color-border-inverse});
|
|
712
|
+
--ds-auro-input-container-color: var(--ds-advanced-color-shared-background-inverse, #{v.$ds-advanced-color-shared-background-inverse});
|
|
713
|
+
--ds-auro-input-caret-color: var(--ds-advanced-color-state-focused-inverse, #{v.$ds-advanced-color-state-focused-inverse});
|
|
714
|
+
--ds-auro-input-label-text-color: var(--ds-basic-color-texticon-inverse-muted, #{v.$ds-basic-color-texticon-inverse-muted});
|
|
715
|
+
--ds-auro-input-placeholder-text-color: var(--ds-basic-color-texticon-inverse, #{v.$ds-basic-color-texticon-inverse});
|
|
716
|
+
--ds-auro-input-text-color: var(--ds-basic-color-texticon-inverse, #{v.$ds-basic-color-texticon-inverse});
|
|
717
|
+
--ds-auro-input-error-icon-color: var(--ds-advanced-color-state-error-inverse, #{v.$ds-advanced-color-state-error-inverse});
|
|
718
|
+
|
|
719
|
+
--ds-auro-input-outline-color: transparent;
|
|
720
|
+
}</code></pre>
|
|
721
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
484
722
|
</section>
|
|
485
723
|
<section>
|
|
486
724
|
<auro-header level="2" id="customBehavior">Behavior</auro-header>
|
|
487
|
-
<auro-header level="3" id="
|
|
488
|
-
<p>
|
|
725
|
+
<auro-header level="3" id="customValidation">Custom Validation</auro-header>
|
|
726
|
+
<p>Use the <code>validity</code> attribute with a custom error message to provide specific feedback.</p>
|
|
489
727
|
<div class="exampleWrapper">
|
|
490
|
-
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/
|
|
491
|
-
<!-- The below content is automatically added from ./../apiExamples/
|
|
492
|
-
<auro-datepicker
|
|
493
|
-
<span slot="bib.fullscreen.headline">
|
|
728
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/validity.html) -->
|
|
729
|
+
<!-- The below content is automatically added from ./../apiExamples/validity.html -->
|
|
730
|
+
<auro-datepicker required setCustomValidityValueMissing="Please select a departure date.">
|
|
731
|
+
<span slot="bib.fullscreen.headline">validity Example</span>
|
|
494
732
|
<span slot="fromLabel">Choose a date</span>
|
|
495
733
|
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
496
734
|
</auro-datepicker>
|
|
@@ -498,11 +736,11 @@
|
|
|
498
736
|
</div>
|
|
499
737
|
<auro-accordion alignRight>
|
|
500
738
|
<span slot="trigger">See code</span>
|
|
501
|
-
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/
|
|
502
|
-
<!-- The below code snippet is automatically added from ./../apiExamples/
|
|
739
|
+
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/validity.html) -->
|
|
740
|
+
<!-- The below code snippet is automatically added from ./../apiExamples/validity.html -->
|
|
503
741
|
|
|
504
|
-
<pre class="language-html"><code class="language-html"><auro-datepicker
|
|
505
|
-
<span slot="bib.fullscreen.headline">
|
|
742
|
+
<pre class="language-html"><code class="language-html"><auro-datepicker required setCustomValidityValueMissing="Please select a departure date.">
|
|
743
|
+
<span slot="bib.fullscreen.headline">validity Example</span>
|
|
506
744
|
<span slot="fromLabel">Choose a date</span>
|
|
507
745
|
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
508
746
|
</auro-datepicker></code></pre>
|
|
@@ -530,46 +768,6 @@
|
|
|
530
768
|
</auro-datepicker></code></pre>
|
|
531
769
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
532
770
|
</auro-accordion>
|
|
533
|
-
<auro-header level="3" id="requireSelection">Require Selection</auro-header>
|
|
534
|
-
<p>Use the <code>required</code> attribute to require a date selection before form submission.</p>
|
|
535
|
-
<div class="exampleWrapper">
|
|
536
|
-
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/required.html) -->
|
|
537
|
-
<!-- The below content is automatically added from ./../apiExamples/required.html -->
|
|
538
|
-
<auro-datepicker required>
|
|
539
|
-
<span slot="bib.fullscreen.headline">Required Example</span>
|
|
540
|
-
<span slot="fromLabel">Choose a date</span>
|
|
541
|
-
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
542
|
-
</auro-datepicker>
|
|
543
|
-
<br />
|
|
544
|
-
<auro-datepicker required range>
|
|
545
|
-
<span slot="bib.fullscreen.headline">Required Example</span>
|
|
546
|
-
<span slot="fromLabel">Departure</span>
|
|
547
|
-
<span slot="toLabel">Return</span>
|
|
548
|
-
<span slot="bib.fullscreen.fromLabel">Departure</span>
|
|
549
|
-
<span slot="bib.fullscreen.toLabel">Return</span>
|
|
550
|
-
</auro-datepicker>
|
|
551
|
-
<!-- AURO-GENERATED-CONTENT:END -->
|
|
552
|
-
</div>
|
|
553
|
-
<auro-accordion alignRight>
|
|
554
|
-
<span slot="trigger">See code</span>
|
|
555
|
-
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/required.html) -->
|
|
556
|
-
<!-- The below code snippet is automatically added from ./../apiExamples/required.html -->
|
|
557
|
-
|
|
558
|
-
<pre class="language-html"><code class="language-html"><auro-datepicker required>
|
|
559
|
-
<span slot="bib.fullscreen.headline">Required Example</span>
|
|
560
|
-
<span slot="fromLabel">Choose a date</span>
|
|
561
|
-
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
562
|
-
</auro-datepicker>
|
|
563
|
-
<br />
|
|
564
|
-
<auro-datepicker required range>
|
|
565
|
-
<span slot="bib.fullscreen.headline">Required Example</span>
|
|
566
|
-
<span slot="fromLabel">Departure</span>
|
|
567
|
-
<span slot="toLabel">Return</span>
|
|
568
|
-
<span slot="bib.fullscreen.fromLabel">Departure</span>
|
|
569
|
-
<span slot="bib.fullscreen.toLabel">Return</span>
|
|
570
|
-
</auro-datepicker></code></pre>
|
|
571
|
-
<!-- AURO-GENERATED-CONTENT:END -->
|
|
572
|
-
</auro-accordion>
|
|
573
771
|
<auro-header level="3" id="forceError">Force Error State</auro-header>
|
|
574
772
|
<p>Use the <code>error</code> attribute to force the component into an error state with a custom message.</p>
|
|
575
773
|
<div class="exampleWrapper">
|
|
@@ -600,13 +798,13 @@
|
|
|
600
798
|
</auro-datepicker></code></pre>
|
|
601
799
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
602
800
|
</auro-accordion>
|
|
603
|
-
<auro-header level="3" id="
|
|
604
|
-
<p>
|
|
801
|
+
<auro-header level="3" id="inputMode">Input Mode</auro-header>
|
|
802
|
+
<p>The <code>inputmode</code> attribute controls which virtual keyboard layout is presented on mobile devices.</p>
|
|
605
803
|
<div class="exampleWrapper">
|
|
606
|
-
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/
|
|
607
|
-
<!-- The below content is automatically added from ./../apiExamples/
|
|
608
|
-
<auro-datepicker
|
|
609
|
-
<span slot="bib.fullscreen.headline">
|
|
804
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/inputmode.html) -->
|
|
805
|
+
<!-- The below content is automatically added from ./../apiExamples/inputmode.html -->
|
|
806
|
+
<auro-datepicker inputmode="numeric">
|
|
807
|
+
<span slot="bib.fullscreen.headline">Datepicker Headline</span>
|
|
610
808
|
<span slot="fromLabel">Choose a date</span>
|
|
611
809
|
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
612
810
|
</auro-datepicker>
|
|
@@ -614,88 +812,399 @@
|
|
|
614
812
|
</div>
|
|
615
813
|
<auro-accordion alignRight>
|
|
616
814
|
<span slot="trigger">See code</span>
|
|
617
|
-
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/
|
|
618
|
-
<!-- The below code snippet is automatically added from ./../apiExamples/
|
|
815
|
+
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/inputmode.html) -->
|
|
816
|
+
<!-- The below code snippet is automatically added from ./../apiExamples/inputmode.html -->
|
|
619
817
|
|
|
620
|
-
<pre class="language-html"><code class="language-html"><auro-datepicker
|
|
621
|
-
<span slot="bib.fullscreen.headline">
|
|
818
|
+
<pre class="language-html"><code class="language-html"><auro-datepicker inputmode="numeric">
|
|
819
|
+
<span slot="bib.fullscreen.headline">Datepicker Headline</span>
|
|
622
820
|
<span slot="fromLabel">Choose a date</span>
|
|
623
821
|
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
624
822
|
</auro-datepicker></code></pre>
|
|
625
823
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
626
824
|
</auro-accordion>
|
|
627
|
-
<auro-header level="3" id="
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
<auro-
|
|
633
|
-
<
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
825
|
+
<auro-header level="3" id="localization">Localization</auro-header>
|
|
826
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../docs/partials/customize/localization.md) -->
|
|
827
|
+
<!-- The below content is automatically added from ./../docs/partials/customize/localization.md -->
|
|
828
|
+
<p>The component supports complete localization, including visible strings, screen reader announcements and locale based date formatting.</p>
|
|
829
|
+
<auro-header level="4" id="localizationTrigger">Trigger</auro-header>
|
|
830
|
+
<auro-header level="4" id="localizationTriggerVisibleStrings">Trigger Visible strings</auro-header>
|
|
831
|
+
<p>The visible strings rendered in the input, trigger, and fullscreen bib are not derived from <code>locale</code> — they are projected through named slots so each language can supply its own translation. Pass a <code><span></code> with the matching <code>slot</code> attribute for every string you need to localize.</p>
|
|
832
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/localization-visible-strings.html) -->
|
|
833
|
+
<!-- The below content is automatically added from ./../apiExamples/localization-visible-strings.html -->
|
|
834
|
+
|
|
835
|
+
<pre class="language-diff"><code class="language-diff"> <auro-datepicker>
|
|
836
|
+
+ <span slot="fromLabel">Abreisedatum</span>
|
|
837
|
+
+ <span slot="helpText">Wählen Sie ein Datum</span>
|
|
838
|
+
+ <span slot="optionalLabel">(freiwillig)</span>
|
|
839
|
+
+ <span slot="bib.fullscreen.headline">Datum auswählen</span>
|
|
840
|
+
+ <span slot="bib.fullscreen.fromLabel">Abreisedatum</span>
|
|
841
|
+
</auro-datepicker></code></pre>
|
|
637
842
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
638
|
-
</
|
|
639
|
-
<auro-
|
|
640
|
-
<
|
|
641
|
-
<!-- AURO-GENERATED-CONTENT:START (
|
|
642
|
-
<!-- The below
|
|
843
|
+
<auro-header level="4" id="localizationCalendar">Calendar</auro-header>
|
|
844
|
+
<auro-header level="4" id="localizationCalendarVisibleStrings">Visible strings</auro-header>
|
|
845
|
+
<p>By default, the calendar weekday names rendered above the day grid and the month names rendered in the calendar header are derived from the active <code>locale</code> using the browser's <auro-hyperlink href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl" target="_blank">Intl</auro-hyperlink> API, so they update automatically when <code>locale</code> changes. Use the <code>monthNames</code> attribute to override the derived month names — for example, to supply a translation the browser does not produce or to support a locale the browser does not recognize.</p>
|
|
846
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/localization-calendar-strings.html) -->
|
|
847
|
+
<!-- The below content is automatically added from ./../apiExamples/localization-calendar-strings.html -->
|
|
643
848
|
|
|
644
|
-
<pre class="language-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
</auro-datepicker></code></pre>
|
|
849
|
+
<pre class="language-diff"><code class="language-diff">- <auro-datepicker>
|
|
850
|
+
+ <auro-datepicker monthNames='["Januar","Februar","März","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember"]'>
|
|
851
|
+
<span slot="fromLabel">Abreisedatum</span>
|
|
852
|
+
<span slot="helpText">Wählen Sie ein Datum</span>
|
|
853
|
+
</auro-datepicker></code></pre>
|
|
854
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
855
|
+
<auro-header level="4" id="localizationCalendarA11yStrings">Screen reader strings</auro-header>
|
|
856
|
+
<p>Assistive-technology announcements — range descriptors (<code>rangeLabelStart</code>, <code>rangeLabelEnd</code>, <code>rangeLabelBeforeRange</code>, <code>rangeLabelInRange</code>, <code>rangeLabelAfterRange</code>), month navigation labels (<code>navLabelPrevMonth</code>, <code>navLabelNextMonth</code>), and the calendar grid label (<code>calendarGridLabel</code>) — are exposed as individual attributes so they can be translated independently of the visible UI. These strings are not derived from <code>locale</code>; supply translated values for every language you support.</p>
|
|
857
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/localization-screenreader-strings.html) -->
|
|
858
|
+
<!-- The below content is automatically added from ./../apiExamples/localization-screenreader-strings.html -->
|
|
859
|
+
|
|
860
|
+
<pre class="language-diff"><code class="language-diff"> <auro-datepicker
|
|
861
|
+
locale="de-DE"
|
|
862
|
+
range
|
|
863
|
+
+ rangeLabelStart="Startdatum"
|
|
864
|
+
+ rangeLabelEnd="Enddatum"
|
|
865
|
+
+ rangeLabelBeforeRange="vor dem Zeitraum"
|
|
866
|
+
+ rangeLabelInRange="im Zeitraum"
|
|
867
|
+
+ rangeLabelAfterRange="nach dem Zeitraum"
|
|
868
|
+
+ navLabelPrevMonth="Vorheriger Monat"
|
|
869
|
+
+ navLabelNextMonth="Nächster Monat"
|
|
870
|
+
+ calendarGridLabel="Kalendertage des Monats">
|
|
871
|
+
<span slot="fromLabel">Abreise</span>
|
|
872
|
+
<span slot="toLabel">Rückkehr</span>
|
|
873
|
+
<span slot="helpText">Wählen Sie einen Zeitraum</span>
|
|
874
|
+
</auro-datepicker></code></pre>
|
|
875
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
876
|
+
<auro-header level="4" id="localizationDateFormatting">Date formatting</auro-header>
|
|
877
|
+
<p>The <code>locale</code> attribute drives the date format used by the input and the calendar. Setting <code>locale</code> automatically selects the regional format (for example <code>en-US</code> → <code>mm/dd/yyyy</code>, <code>de-DE</code> → <code>dd.mm.yyyy</code>, <code>ja-JP</code> → <code>yyyy/mm/dd</code>), derived from the browser's <code>Intl</code> API, so <code>format</code> does not need to be set manually.</p>
|
|
878
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/localization-locale.html) -->
|
|
879
|
+
<!-- The below content is automatically added from ./../apiExamples/localization-locale.html -->
|
|
880
|
+
|
|
881
|
+
<pre class="language-diff"><code class="language-diff">- <auro-datepicker>
|
|
882
|
+
+ <auro-datepicker locale="de-DE">
|
|
883
|
+
<span slot="fromLabel">Deutsches Datum</span>
|
|
884
|
+
<span slot="helpText">Hilfetext</span>
|
|
885
|
+
<span slot="optionalLabel">(freiwillig)</span>
|
|
886
|
+
</auro-datepicker></code></pre>
|
|
887
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
888
|
+
<p>If no <code>locale</code> attribute is present, the component walks up the DOM looking for the nearest ancestor with a <code>data-locale</code> attribute; if none is found, it defaults to <code>en-US</code>.</p>
|
|
889
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/localization-locale-inherited.html) -->
|
|
890
|
+
<!-- The below content is automatically added from ./../apiExamples/localization-locale-inherited.html -->
|
|
891
|
+
|
|
892
|
+
<pre class="language-diff"><code class="language-diff">+ <div data-locale="ja-JP">
|
|
893
|
+
<auro-datepicker>
|
|
894
|
+
<span slot="fromLabel">継承された ja-JP 日付形式</span>
|
|
895
|
+
<span slot="helpText">ヘルプテキスト</span>
|
|
896
|
+
<span slot="optionalLabel">(任意)</span>
|
|
897
|
+
</auro-datepicker>
|
|
898
|
+
+ </div></code></pre>
|
|
899
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
900
|
+
<p>If <code>format</code> is set alongside <code>locale</code>, <code>format</code> always wins.</p>
|
|
901
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/localization-locale-formatted.html) -->
|
|
902
|
+
<!-- The below content is automatically added from ./../apiExamples/localization-locale-formatted.html -->
|
|
903
|
+
|
|
904
|
+
<pre class="language-diff"><code class="language-diff"> <auro-datepicker
|
|
905
|
+
+ locale="de-DE"
|
|
906
|
+
+ format="mm/dd/yyyy">
|
|
907
|
+
<span slot="fromLabel">Deutsches Datum mit mm/dd/yyyy-Format</span>
|
|
908
|
+
<span slot="helpText">Hilfetext</span>
|
|
909
|
+
<span slot="optionalLabel">(freiwillig)</span>
|
|
910
|
+
</auro-datepicker></code></pre>
|
|
649
911
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
650
|
-
</auro-accordion>
|
|
651
|
-
<auro-header level="3" id="minMaxDate">Min/Max Date</auro-header>
|
|
652
|
-
<p>Use the <code>minDate</code> and <code>maxDate</code> attributes to constrain the selectable date range.</p>
|
|
653
912
|
<div class="exampleWrapper">
|
|
654
|
-
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/
|
|
655
|
-
<!-- The below content is automatically added from ./../apiExamples/
|
|
656
|
-
<
|
|
657
|
-
<
|
|
658
|
-
<
|
|
659
|
-
|
|
913
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/locale.html) -->
|
|
914
|
+
<!-- The below content is automatically added from ./../apiExamples/locale.html -->
|
|
915
|
+
<div data-locale="de-DE">
|
|
916
|
+
<auro-header level="4" >de-DE Example</auro-header>
|
|
917
|
+
<auro-datepicker
|
|
918
|
+
locale="de-DE"
|
|
919
|
+
range
|
|
920
|
+
rangeLabelStart="Startdatum"
|
|
921
|
+
rangeLabelEnd="Enddatum"
|
|
922
|
+
rangeLabelBeforeRange="vor dem Zeitraum"
|
|
923
|
+
rangeLabelInRange="im Zeitraum"
|
|
924
|
+
rangeLabelAfterRange="nach dem Zeitraum"
|
|
925
|
+
navLabelPrevMonth="Vorheriger Monat"
|
|
926
|
+
navLabelNextMonth="Nächster Monat"
|
|
927
|
+
calendarGridLabel="Kalendertage des Monats">
|
|
928
|
+
<span slot="fromLabel">Deutsches Datum</span>
|
|
929
|
+
<span slot="helpText">Hilfetext</span>
|
|
930
|
+
<span slot="optionalLabel">(freiwillig)</span>
|
|
660
931
|
</auro-datepicker>
|
|
932
|
+
<auro-header level="4" >zh-CN Example</auro-header>
|
|
933
|
+
<auro-datepicker
|
|
934
|
+
locale="zh-CN"
|
|
935
|
+
range
|
|
936
|
+
rangeLabelStart="开始日期"
|
|
937
|
+
rangeLabelEnd="结束日期"
|
|
938
|
+
rangeLabelBeforeRange="在此期间之前"
|
|
939
|
+
rangeLabelInRange="在此期间内"
|
|
940
|
+
rangeLabelAfterRange="在此期间之后"
|
|
941
|
+
navLabelPrevMonth="上个月"
|
|
942
|
+
navLabelNextMonth="下个月"
|
|
943
|
+
calendarGridLabel="本月的日历天数">
|
|
944
|
+
<span slot="fromLabel">中文日期</span>
|
|
945
|
+
<span slot="helpText">帮助文本</span>
|
|
946
|
+
<span slot="optionalLabel">(可选)</span>
|
|
947
|
+
</auro-datepicker>
|
|
948
|
+
<auro-header level="4">Inherited de-DE date-locale Example</auro-header>
|
|
949
|
+
<auro-datepicker
|
|
950
|
+
range
|
|
951
|
+
rangeLabelStart="Startdatum"
|
|
952
|
+
rangeLabelEnd="Enddatum"
|
|
953
|
+
rangeLabelBeforeRange="vor dem Zeitraum"
|
|
954
|
+
rangeLabelInRange="im Zeitraum"
|
|
955
|
+
rangeLabelAfterRange="nach dem Zeitraum"
|
|
956
|
+
navLabelPrevMonth="Vorheriger Monat"
|
|
957
|
+
navLabelNextMonth="Nächster Monat"
|
|
958
|
+
calendarGridLabel="Kalendertage des Monats">
|
|
959
|
+
<span slot="fromLabel">Nächstes `data-locale`-Attributformat (`de-DE` in diesem Fall)</span>
|
|
960
|
+
<span slot="helpText">Hilfetext</span>
|
|
961
|
+
<span slot="optionalLabel">(freiwillig)</span>
|
|
962
|
+
</auro-datepicker>
|
|
963
|
+
<auro-header level="4" >ja-JP with `mm/dd/yyyy` format Example</auro-header>
|
|
964
|
+
<auro-datepicker
|
|
965
|
+
locale="ja-JP"
|
|
966
|
+
format="mm/dd/yyyy"
|
|
967
|
+
range
|
|
968
|
+
rangeLabelStart="開始日"
|
|
969
|
+
rangeLabelEnd="終了日"
|
|
970
|
+
rangeLabelBeforeRange="この期間の前"
|
|
971
|
+
rangeLabelInRange="この期間内"
|
|
972
|
+
rangeLabelAfterRange="この期間の後"
|
|
973
|
+
navLabelPrevMonth="前の月"
|
|
974
|
+
navLabelNextMonth="次の月"
|
|
975
|
+
calendarGridLabel="カレンダーの日付">
|
|
976
|
+
<span slot="fromLabel">明示的な mm/dd/yyyy 形式の ja-JP ロケール</span>
|
|
977
|
+
<span slot="helpText">ヘルプテキスト</span>
|
|
978
|
+
<span slot="optionalLabel">(任意)</span>
|
|
979
|
+
</auro-datepicker>
|
|
980
|
+
</div>
|
|
661
981
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
662
982
|
</div>
|
|
663
983
|
<auro-accordion alignRight>
|
|
664
984
|
<span slot="trigger">See code</span>
|
|
665
|
-
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/
|
|
666
|
-
<!-- The below code snippet is automatically added from ./../apiExamples/
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
<
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
985
|
+
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/locale.html) -->
|
|
986
|
+
<!-- The below code snippet is automatically added from ./../apiExamples/locale.html -->
|
|
987
|
+
<pre class="language-html"><code class="language-html"><div data-locale="de-DE">
|
|
988
|
+
<auro-header level="4" >de-DE Example</auro-header>
|
|
989
|
+
<auro-datepicker
|
|
990
|
+
locale="de-DE"
|
|
991
|
+
range
|
|
992
|
+
rangeLabelStart="Startdatum"
|
|
993
|
+
rangeLabelEnd="Enddatum"
|
|
994
|
+
rangeLabelBeforeRange="vor dem Zeitraum"
|
|
995
|
+
rangeLabelInRange="im Zeitraum"
|
|
996
|
+
rangeLabelAfterRange="nach dem Zeitraum"
|
|
997
|
+
navLabelPrevMonth="Vorheriger Monat"
|
|
998
|
+
navLabelNextMonth="Nächster Monat"
|
|
999
|
+
calendarGridLabel="Kalendertage des Monats">
|
|
1000
|
+
<span slot="fromLabel">Deutsches Datum</span>
|
|
1001
|
+
<span slot="helpText">Hilfetext</span>
|
|
1002
|
+
<span slot="optionalLabel">(freiwillig)</span>
|
|
1003
|
+
</auro-datepicker>
|
|
1004
|
+
<auro-header level="4" >zh-CN Example</auro-header>
|
|
1005
|
+
<auro-datepicker
|
|
1006
|
+
locale="zh-CN"
|
|
1007
|
+
range
|
|
1008
|
+
rangeLabelStart="开始日期"
|
|
1009
|
+
rangeLabelEnd="结束日期"
|
|
1010
|
+
rangeLabelBeforeRange="在此期间之前"
|
|
1011
|
+
rangeLabelInRange="在此期间内"
|
|
1012
|
+
rangeLabelAfterRange="在此期间之后"
|
|
1013
|
+
navLabelPrevMonth="上个月"
|
|
1014
|
+
navLabelNextMonth="下个月"
|
|
1015
|
+
calendarGridLabel="本月的日历天数">
|
|
1016
|
+
<span slot="fromLabel">中文日期</span>
|
|
1017
|
+
<span slot="helpText">帮助文本</span>
|
|
1018
|
+
<span slot="optionalLabel">(可选)</span>
|
|
1019
|
+
</auro-datepicker>
|
|
1020
|
+
<auro-header level="4">Inherited de-DE date-locale Example</auro-header>
|
|
1021
|
+
<auro-datepicker
|
|
1022
|
+
range
|
|
1023
|
+
rangeLabelStart="Startdatum"
|
|
1024
|
+
rangeLabelEnd="Enddatum"
|
|
1025
|
+
rangeLabelBeforeRange="vor dem Zeitraum"
|
|
1026
|
+
rangeLabelInRange="im Zeitraum"
|
|
1027
|
+
rangeLabelAfterRange="nach dem Zeitraum"
|
|
1028
|
+
navLabelPrevMonth="Vorheriger Monat"
|
|
1029
|
+
navLabelNextMonth="Nächster Monat"
|
|
1030
|
+
calendarGridLabel="Kalendertage des Monats">
|
|
1031
|
+
<span slot="fromLabel">Nächstes `data-locale`-Attributformat (`de-DE` in diesem Fall)</span>
|
|
1032
|
+
<span slot="helpText">Hilfetext</span>
|
|
1033
|
+
<span slot="optionalLabel">(freiwillig)</span>
|
|
1034
|
+
</auro-datepicker>
|
|
1035
|
+
<auro-header level="4" >ja-JP with `mm/dd/yyyy` format Example</auro-header>
|
|
1036
|
+
<auro-datepicker
|
|
1037
|
+
locale="ja-JP"
|
|
1038
|
+
format="mm/dd/yyyy"
|
|
1039
|
+
range
|
|
1040
|
+
rangeLabelStart="開始日"
|
|
1041
|
+
rangeLabelEnd="終了日"
|
|
1042
|
+
rangeLabelBeforeRange="この期間の前"
|
|
1043
|
+
rangeLabelInRange="この期間内"
|
|
1044
|
+
rangeLabelAfterRange="この期間の後"
|
|
1045
|
+
navLabelPrevMonth="前の月"
|
|
1046
|
+
navLabelNextMonth="次の月"
|
|
1047
|
+
calendarGridLabel="カレンダーの日付">
|
|
1048
|
+
<span slot="fromLabel">明示的な mm/dd/yyyy 形式の ja-JP ロケール</span>
|
|
1049
|
+
<span slot="helpText">ヘルプテキスト</span>
|
|
1050
|
+
<span slot="optionalLabel">(任意)</span>
|
|
1051
|
+
</auro-datepicker>
|
|
1052
|
+
</div></code></pre>
|
|
673
1053
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
674
1054
|
</auro-accordion>
|
|
1055
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
1056
|
+
<pre><code>// Override month names (all 12 required, starting with January)
|
|
1057
|
+
datepicker.monthNames = [
|
|
1058
|
+
'Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun',
|
|
1059
|
+
'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'
|
|
1060
|
+
];</code></pre>
|
|
675
1061
|
<div class="exampleWrapper">
|
|
676
|
-
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/
|
|
677
|
-
<!-- The below content is automatically added from ./../apiExamples/
|
|
678
|
-
<
|
|
679
|
-
<
|
|
680
|
-
<
|
|
681
|
-
|
|
1062
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/locale.html) -->
|
|
1063
|
+
<!-- The below content is automatically added from ./../apiExamples/locale.html -->
|
|
1064
|
+
<div data-locale="de-DE">
|
|
1065
|
+
<auro-header level="4" >de-DE Example</auro-header>
|
|
1066
|
+
<auro-datepicker
|
|
1067
|
+
locale="de-DE"
|
|
1068
|
+
range
|
|
1069
|
+
rangeLabelStart="Startdatum"
|
|
1070
|
+
rangeLabelEnd="Enddatum"
|
|
1071
|
+
rangeLabelBeforeRange="vor dem Zeitraum"
|
|
1072
|
+
rangeLabelInRange="im Zeitraum"
|
|
1073
|
+
rangeLabelAfterRange="nach dem Zeitraum"
|
|
1074
|
+
navLabelPrevMonth="Vorheriger Monat"
|
|
1075
|
+
navLabelNextMonth="Nächster Monat"
|
|
1076
|
+
calendarGridLabel="Kalendertage des Monats">
|
|
1077
|
+
<span slot="fromLabel">Deutsches Datum</span>
|
|
1078
|
+
<span slot="helpText">Hilfetext</span>
|
|
1079
|
+
<span slot="optionalLabel">(freiwillig)</span>
|
|
682
1080
|
</auro-datepicker>
|
|
1081
|
+
<auro-header level="4" >zh-CN Example</auro-header>
|
|
1082
|
+
<auro-datepicker
|
|
1083
|
+
locale="zh-CN"
|
|
1084
|
+
range
|
|
1085
|
+
rangeLabelStart="开始日期"
|
|
1086
|
+
rangeLabelEnd="结束日期"
|
|
1087
|
+
rangeLabelBeforeRange="在此期间之前"
|
|
1088
|
+
rangeLabelInRange="在此期间内"
|
|
1089
|
+
rangeLabelAfterRange="在此期间之后"
|
|
1090
|
+
navLabelPrevMonth="上个月"
|
|
1091
|
+
navLabelNextMonth="下个月"
|
|
1092
|
+
calendarGridLabel="本月的日历天数">
|
|
1093
|
+
<span slot="fromLabel">中文日期</span>
|
|
1094
|
+
<span slot="helpText">帮助文本</span>
|
|
1095
|
+
<span slot="optionalLabel">(可选)</span>
|
|
1096
|
+
</auro-datepicker>
|
|
1097
|
+
<auro-header level="4">Inherited de-DE date-locale Example</auro-header>
|
|
1098
|
+
<auro-datepicker
|
|
1099
|
+
range
|
|
1100
|
+
rangeLabelStart="Startdatum"
|
|
1101
|
+
rangeLabelEnd="Enddatum"
|
|
1102
|
+
rangeLabelBeforeRange="vor dem Zeitraum"
|
|
1103
|
+
rangeLabelInRange="im Zeitraum"
|
|
1104
|
+
rangeLabelAfterRange="nach dem Zeitraum"
|
|
1105
|
+
navLabelPrevMonth="Vorheriger Monat"
|
|
1106
|
+
navLabelNextMonth="Nächster Monat"
|
|
1107
|
+
calendarGridLabel="Kalendertage des Monats">
|
|
1108
|
+
<span slot="fromLabel">Nächstes `data-locale`-Attributformat (`de-DE` in diesem Fall)</span>
|
|
1109
|
+
<span slot="helpText">Hilfetext</span>
|
|
1110
|
+
<span slot="optionalLabel">(freiwillig)</span>
|
|
1111
|
+
</auro-datepicker>
|
|
1112
|
+
<auro-header level="4" >ja-JP with `mm/dd/yyyy` format Example</auro-header>
|
|
1113
|
+
<auro-datepicker
|
|
1114
|
+
locale="ja-JP"
|
|
1115
|
+
format="mm/dd/yyyy"
|
|
1116
|
+
range
|
|
1117
|
+
rangeLabelStart="開始日"
|
|
1118
|
+
rangeLabelEnd="終了日"
|
|
1119
|
+
rangeLabelBeforeRange="この期間の前"
|
|
1120
|
+
rangeLabelInRange="この期間内"
|
|
1121
|
+
rangeLabelAfterRange="この期間の後"
|
|
1122
|
+
navLabelPrevMonth="前の月"
|
|
1123
|
+
navLabelNextMonth="次の月"
|
|
1124
|
+
calendarGridLabel="カレンダーの日付">
|
|
1125
|
+
<span slot="fromLabel">明示的な mm/dd/yyyy 形式の ja-JP ロケール</span>
|
|
1126
|
+
<span slot="helpText">ヘルプテキスト</span>
|
|
1127
|
+
<span slot="optionalLabel">(任意)</span>
|
|
1128
|
+
</auro-datepicker>
|
|
1129
|
+
</div>
|
|
683
1130
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
684
1131
|
</div>
|
|
685
1132
|
<auro-accordion alignRight>
|
|
686
1133
|
<span slot="trigger">See code</span>
|
|
687
|
-
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/
|
|
688
|
-
<!-- The below code snippet is automatically added from ./../apiExamples/
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
<
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
1134
|
+
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/locale.html) -->
|
|
1135
|
+
<!-- The below code snippet is automatically added from ./../apiExamples/locale.html -->
|
|
1136
|
+
<pre class="language-html"><code class="language-html"><div data-locale="de-DE">
|
|
1137
|
+
<auro-header level="4" >de-DE Example</auro-header>
|
|
1138
|
+
<auro-datepicker
|
|
1139
|
+
locale="de-DE"
|
|
1140
|
+
range
|
|
1141
|
+
rangeLabelStart="Startdatum"
|
|
1142
|
+
rangeLabelEnd="Enddatum"
|
|
1143
|
+
rangeLabelBeforeRange="vor dem Zeitraum"
|
|
1144
|
+
rangeLabelInRange="im Zeitraum"
|
|
1145
|
+
rangeLabelAfterRange="nach dem Zeitraum"
|
|
1146
|
+
navLabelPrevMonth="Vorheriger Monat"
|
|
1147
|
+
navLabelNextMonth="Nächster Monat"
|
|
1148
|
+
calendarGridLabel="Kalendertage des Monats">
|
|
1149
|
+
<span slot="fromLabel">Deutsches Datum</span>
|
|
1150
|
+
<span slot="helpText">Hilfetext</span>
|
|
1151
|
+
<span slot="optionalLabel">(freiwillig)</span>
|
|
1152
|
+
</auro-datepicker>
|
|
1153
|
+
<auro-header level="4" >zh-CN Example</auro-header>
|
|
1154
|
+
<auro-datepicker
|
|
1155
|
+
locale="zh-CN"
|
|
1156
|
+
range
|
|
1157
|
+
rangeLabelStart="开始日期"
|
|
1158
|
+
rangeLabelEnd="结束日期"
|
|
1159
|
+
rangeLabelBeforeRange="在此期间之前"
|
|
1160
|
+
rangeLabelInRange="在此期间内"
|
|
1161
|
+
rangeLabelAfterRange="在此期间之后"
|
|
1162
|
+
navLabelPrevMonth="上个月"
|
|
1163
|
+
navLabelNextMonth="下个月"
|
|
1164
|
+
calendarGridLabel="本月的日历天数">
|
|
1165
|
+
<span slot="fromLabel">中文日期</span>
|
|
1166
|
+
<span slot="helpText">帮助文本</span>
|
|
1167
|
+
<span slot="optionalLabel">(可选)</span>
|
|
1168
|
+
</auro-datepicker>
|
|
1169
|
+
<auro-header level="4">Inherited de-DE date-locale Example</auro-header>
|
|
1170
|
+
<auro-datepicker
|
|
1171
|
+
range
|
|
1172
|
+
rangeLabelStart="Startdatum"
|
|
1173
|
+
rangeLabelEnd="Enddatum"
|
|
1174
|
+
rangeLabelBeforeRange="vor dem Zeitraum"
|
|
1175
|
+
rangeLabelInRange="im Zeitraum"
|
|
1176
|
+
rangeLabelAfterRange="nach dem Zeitraum"
|
|
1177
|
+
navLabelPrevMonth="Vorheriger Monat"
|
|
1178
|
+
navLabelNextMonth="Nächster Monat"
|
|
1179
|
+
calendarGridLabel="Kalendertage des Monats">
|
|
1180
|
+
<span slot="fromLabel">Nächstes `data-locale`-Attributformat (`de-DE` in diesem Fall)</span>
|
|
1181
|
+
<span slot="helpText">Hilfetext</span>
|
|
1182
|
+
<span slot="optionalLabel">(freiwillig)</span>
|
|
1183
|
+
</auro-datepicker>
|
|
1184
|
+
<auro-header level="4" >ja-JP with `mm/dd/yyyy` format Example</auro-header>
|
|
1185
|
+
<auro-datepicker
|
|
1186
|
+
locale="ja-JP"
|
|
1187
|
+
format="mm/dd/yyyy"
|
|
1188
|
+
range
|
|
1189
|
+
rangeLabelStart="開始日"
|
|
1190
|
+
rangeLabelEnd="終了日"
|
|
1191
|
+
rangeLabelBeforeRange="この期間の前"
|
|
1192
|
+
rangeLabelInRange="この期間内"
|
|
1193
|
+
rangeLabelAfterRange="この期間の後"
|
|
1194
|
+
navLabelPrevMonth="前の月"
|
|
1195
|
+
navLabelNextMonth="次の月"
|
|
1196
|
+
calendarGridLabel="カレンダーの日付">
|
|
1197
|
+
<span slot="fromLabel">明示的な mm/dd/yyyy 形式の ja-JP ロケール</span>
|
|
1198
|
+
<span slot="helpText">ヘルプテキスト</span>
|
|
1199
|
+
<span slot="optionalLabel">(任意)</span>
|
|
1200
|
+
</auro-datepicker>
|
|
1201
|
+
</div></code></pre>
|
|
695
1202
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
696
1203
|
</auro-accordion>
|
|
697
|
-
<auro-header level="
|
|
698
|
-
<p>
|
|
1204
|
+
<auro-header level="4" id="regionalDate">Regional Date</auro-header>
|
|
1205
|
+
<p>When the <code>locale</code> attribute is set, the component automatically derives the correct date format for that region — no need to set <code>format</code> manually. For example, <code>locale="en-US"</code> produces <code>mm/dd/yyyy</code>, <code>locale="de-DE"</code> produces <code>dd.mm.yyyy</code>, and <code>locale="ja-JP"</code> produces <code>yyyy/mm/dd</code>.</p>
|
|
1206
|
+
<p>If <code>format</code> is explicitly set alongside <code>locale</code>, <code>format</code> always wins. Use this when a specific format is required regardless of region.</p>
|
|
1207
|
+
<p>If no <code>locale</code> attribute is set on the element, the component walks up the DOM looking for the nearest ancestor with a <code>data-locale</code> attribute and uses that value. If none is found, it defaults to <code>en-US</code>.</p>
|
|
699
1208
|
<auro-header level="4" id="rangeLabels">Screen Reader Labels</auro-header>
|
|
700
1209
|
<p>The following attributes customize the labels announced by screen readers when navigating the calendar. Range labels apply when the <code>range</code> attribute is set; navigation labels apply to all configurations.</p>
|
|
701
1210
|
<auro-table>
|
|
@@ -751,90 +1260,114 @@
|
|
|
751
1260
|
</tbody>
|
|
752
1261
|
</table>
|
|
753
1262
|
</auro-table>
|
|
754
|
-
<auro-header level="
|
|
755
|
-
<p>
|
|
756
|
-
<p>If <code>format</code> is explicitly set alongside <code>locale</code>, <code>format</code> always wins. Use this when a specific format is required regardless of region.</p>
|
|
757
|
-
<p>If no <code>locale</code> attribute is set on the element, the component walks up the DOM looking for the nearest ancestor with a <code>data-locale</code> attribute and uses that value. If none is found, it defaults to <code>en-US</code>.</p>
|
|
758
|
-
<auro-header level="4" id="monthNames">Month Names</auro-header>
|
|
759
|
-
<p>The <code>monthNames</code> attribute accepts an array of 12 month name strings displayed in the calendar header. When <code>monthNames</code> is <strong>not</strong> set, the component automatically derives localized month names from the active <code>locale</code> (falling back to <code>en-US</code> if no locale is set).</p>
|
|
760
|
-
<p>Use <code>monthNames</code> only when you need to override the locale-derived names — for example, to supply translated names that differ from the browser's built-in <code>Intl</code> output, or to support a locale the browser does not recognize.</p>
|
|
761
|
-
<pre><code>// Override month names (all 12 required, starting with January)
|
|
762
|
-
datepicker.monthNames = [
|
|
763
|
-
'Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun',
|
|
764
|
-
'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'
|
|
765
|
-
];</code></pre>
|
|
1263
|
+
<auro-header level="3" id="minMaxDate">Min/Max Date</auro-header>
|
|
1264
|
+
<p>Use the <code>minDate</code> and <code>maxDate</code> attributes to constrain the selectable date range.</p>
|
|
766
1265
|
<div class="exampleWrapper">
|
|
767
|
-
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/
|
|
768
|
-
<!-- The below content is automatically added from ./../apiExamples/
|
|
769
|
-
<
|
|
770
|
-
<
|
|
771
|
-
<
|
|
772
|
-
<span slot="fromLabel">
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
<auro-
|
|
777
|
-
<span slot="
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
<
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
<
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
<
|
|
792
|
-
</
|
|
793
|
-
<
|
|
794
|
-
<
|
|
795
|
-
<span slot="fromLabel">明示的な mm/dd/yyyy 形式の ja-JP ロケール</span>
|
|
796
|
-
<span slot="helpText">ヘルプテキスト</span>
|
|
797
|
-
<span slot="optionalLabel">(任意)</span>
|
|
1266
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/min-date.html) -->
|
|
1267
|
+
<!-- The below content is automatically added from ./../apiExamples/min-date.html -->
|
|
1268
|
+
<auro-datepicker minDate="2028-03-25" setCustomValidityRangeUnderflow="Selected date is earlier than the minimum date.">
|
|
1269
|
+
<span slot="bib.fullscreen.headline">minDate Example</span>
|
|
1270
|
+
<span slot="fromLabel">Choose a date - minDate</span>
|
|
1271
|
+
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
1272
|
+
</auro-datepicker>
|
|
1273
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
1274
|
+
</div>
|
|
1275
|
+
<auro-accordion alignRight>
|
|
1276
|
+
<span slot="trigger">See code</span>
|
|
1277
|
+
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/min-date.html) -->
|
|
1278
|
+
<!-- The below code snippet is automatically added from ./../apiExamples/min-date.html -->
|
|
1279
|
+
|
|
1280
|
+
<pre class="language-html"><code class="language-html"><auro-datepicker minDate="2028-03-25" setCustomValidityRangeUnderflow="Selected date is earlier than the minimum date.">
|
|
1281
|
+
<span slot="bib.fullscreen.headline">minDate Example</span>
|
|
1282
|
+
<span slot="fromLabel">Choose a date - minDate</span>
|
|
1283
|
+
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
1284
|
+
</auro-datepicker></code></pre>
|
|
1285
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
1286
|
+
</auro-accordion>
|
|
1287
|
+
<div class="exampleWrapper">
|
|
1288
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/max-date.html) -->
|
|
1289
|
+
<!-- The below content is automatically added from ./../apiExamples/max-date.html -->
|
|
1290
|
+
<auro-datepicker maxDate="2023-03-25" setCustomValidityRangeOverflow="Selected date is later than maximum date.">
|
|
1291
|
+
<span slot="bib.fullscreen.headline">maxDate Example</span>
|
|
1292
|
+
<span slot="fromLabel">Choose a date - maxDate</span>
|
|
1293
|
+
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
798
1294
|
</auro-datepicker>
|
|
1295
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
799
1296
|
</div>
|
|
1297
|
+
<auro-accordion alignRight>
|
|
1298
|
+
<span slot="trigger">See code</span>
|
|
1299
|
+
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/max-date.html) -->
|
|
1300
|
+
<!-- The below code snippet is automatically added from ./../apiExamples/max-date.html -->
|
|
1301
|
+
|
|
1302
|
+
<pre class="language-html"><code class="language-html"><auro-datepicker maxDate="2023-03-25" setCustomValidityRangeOverflow="Selected date is later than maximum date.">
|
|
1303
|
+
<span slot="bib.fullscreen.headline">maxDate Example</span>
|
|
1304
|
+
<span slot="fromLabel">Choose a date - maxDate</span>
|
|
1305
|
+
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
1306
|
+
</auro-datepicker></code></pre>
|
|
1307
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
1308
|
+
</auro-accordion>
|
|
1309
|
+
<auro-header level="3" id="noValidate">No Validation</auro-header>
|
|
1310
|
+
<p>Use the <code>noValidate</code> attribute to disable all validation on the component.</p>
|
|
1311
|
+
<div class="exampleWrapper">
|
|
1312
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/no-validate.html) -->
|
|
1313
|
+
<!-- The below content is automatically added from ./../apiExamples/no-validate.html -->
|
|
1314
|
+
<auro-datepicker required noValidate>
|
|
1315
|
+
<span slot="bib.fullscreen.headline">noValidate Example</span>
|
|
1316
|
+
<span slot="fromLabel">Choose a date</span>
|
|
1317
|
+
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
1318
|
+
</auro-datepicker>
|
|
800
1319
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
801
1320
|
</div>
|
|
802
1321
|
<auro-accordion alignRight>
|
|
803
1322
|
<span slot="trigger">See code</span>
|
|
804
|
-
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/
|
|
805
|
-
<!-- The below code snippet is automatically added from ./../apiExamples/
|
|
1323
|
+
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/no-validate.html) -->
|
|
1324
|
+
<!-- The below code snippet is automatically added from ./../apiExamples/no-validate.html -->
|
|
806
1325
|
|
|
807
|
-
<pre class="language-html"><code class="language-html"><
|
|
808
|
-
<
|
|
809
|
-
<
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
1326
|
+
<pre class="language-html"><code class="language-html"><auro-datepicker required noValidate>
|
|
1327
|
+
<span slot="bib.fullscreen.headline">noValidate Example</span>
|
|
1328
|
+
<span slot="fromLabel">Choose a date</span>
|
|
1329
|
+
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
1330
|
+
</auro-datepicker></code></pre>
|
|
1331
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
1332
|
+
</auro-accordion>
|
|
1333
|
+
<auro-header level="3" id="requireSelection">Require Selection</auro-header>
|
|
1334
|
+
<p>Use the <code>required</code> attribute to require a date selection before form submission.</p>
|
|
1335
|
+
<div class="exampleWrapper">
|
|
1336
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/required.html) -->
|
|
1337
|
+
<!-- The below content is automatically added from ./../apiExamples/required.html -->
|
|
1338
|
+
<auro-datepicker required>
|
|
1339
|
+
<span slot="bib.fullscreen.headline">Required Example</span>
|
|
1340
|
+
<span slot="fromLabel">Choose a date</span>
|
|
1341
|
+
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
1342
|
+
</auro-datepicker>
|
|
1343
|
+
<br />
|
|
1344
|
+
<auro-datepicker required range>
|
|
1345
|
+
<span slot="bib.fullscreen.headline">Required Example</span>
|
|
1346
|
+
<span slot="fromLabel">Departure</span>
|
|
1347
|
+
<span slot="toLabel">Return</span>
|
|
1348
|
+
<span slot="bib.fullscreen.fromLabel">Departure</span>
|
|
1349
|
+
<span slot="bib.fullscreen.toLabel">Return</span>
|
|
1350
|
+
</auro-datepicker>
|
|
1351
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
1352
|
+
</div>
|
|
1353
|
+
<auro-accordion alignRight>
|
|
1354
|
+
<span slot="trigger">See code</span>
|
|
1355
|
+
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/required.html) -->
|
|
1356
|
+
<!-- The below code snippet is automatically added from ./../apiExamples/required.html -->
|
|
1357
|
+
|
|
1358
|
+
<pre class="language-html"><code class="language-html"><auro-datepicker required>
|
|
1359
|
+
<span slot="bib.fullscreen.headline">Required Example</span>
|
|
1360
|
+
<span slot="fromLabel">Choose a date</span>
|
|
1361
|
+
<span slot="bib.fullscreen.fromLabel">Choose a date</span>
|
|
1362
|
+
</auro-datepicker>
|
|
1363
|
+
<br />
|
|
1364
|
+
<auro-datepicker required range>
|
|
1365
|
+
<span slot="bib.fullscreen.headline">Required Example</span>
|
|
1366
|
+
<span slot="fromLabel">Departure</span>
|
|
1367
|
+
<span slot="toLabel">Return</span>
|
|
1368
|
+
<span slot="bib.fullscreen.fromLabel">Departure</span>
|
|
1369
|
+
<span slot="bib.fullscreen.toLabel">Return</span>
|
|
1370
|
+
</auro-datepicker></code></pre>
|
|
838
1371
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
839
1372
|
</auro-accordion>
|
|
840
1373
|
</section>
|