react-day-picker 9.6.0 → 9.6.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/cjs/UI.d.ts CHANGED
@@ -13,7 +13,7 @@ export declare enum UI {
13
13
  Chevron = "chevron",
14
14
  /**
15
15
  * The grid cell with the day's date. Extended by {@link DayFlag} and
16
- * {@link SelectionFlag}.
16
+ * {@link SelectionState}.
17
17
  */
18
18
  Day = "day",
19
19
  /** The button containing the formatted day's date, inside the grid cell. */
package/dist/cjs/UI.js CHANGED
@@ -16,7 +16,7 @@ var UI;
16
16
  UI["Chevron"] = "chevron";
17
17
  /**
18
18
  * The grid cell with the day's date. Extended by {@link DayFlag} and
19
- * {@link SelectionFlag}.
19
+ * {@link SelectionState}.
20
20
  */
21
21
  UI["Day"] = "day";
22
22
  /** The button containing the formatted day's date, inside the grid cell. */
@@ -6,7 +6,7 @@ import type { Modifiers } from "../types/index.js";
6
6
  * the focus with they day.
7
7
  *
8
8
  * If you need to just change the content of the day cell, consider swapping the
9
- * `DayDate` component instead.
9
+ * `DayButton` component instead.
10
10
  *
11
11
  * @group Components
12
12
  * @see https://daypicker.dev/guides/custom-components
@@ -10,7 +10,7 @@ const react_1 = __importDefault(require("react"));
10
10
  * the focus with they day.
11
11
  *
12
12
  * If you need to just change the content of the day cell, consider swapping the
13
- * `DayDate` component instead.
13
+ * `DayButton` component instead.
14
14
  *
15
15
  * @group Components
16
16
  * @see https://daypicker.dev/guides/custom-components
@@ -204,7 +204,7 @@ export interface PropsBase {
204
204
  /**
205
205
  * Show the outside days (days falling in the next or the previous month).
206
206
  *
207
- * **Note:** when a broadcast {@link calendar} is set, this prop defaults to
207
+ * **Note:** when a {@link broadcastCalendar} is set, this prop defaults to
208
208
  * true.
209
209
  *
210
210
  * @see https://daypicker.dev/docs/customization#outside-days
package/dist/esm/UI.d.ts CHANGED
@@ -13,7 +13,7 @@ export declare enum UI {
13
13
  Chevron = "chevron",
14
14
  /**
15
15
  * The grid cell with the day's date. Extended by {@link DayFlag} and
16
- * {@link SelectionFlag}.
16
+ * {@link SelectionState}.
17
17
  */
18
18
  Day = "day",
19
19
  /** The button containing the formatted day's date, inside the grid cell. */
package/dist/esm/UI.js CHANGED
@@ -13,7 +13,7 @@ export var UI;
13
13
  UI["Chevron"] = "chevron";
14
14
  /**
15
15
  * The grid cell with the day's date. Extended by {@link DayFlag} and
16
- * {@link SelectionFlag}.
16
+ * {@link SelectionState}.
17
17
  */
18
18
  UI["Day"] = "day";
19
19
  /** The button containing the formatted day's date, inside the grid cell. */
@@ -6,7 +6,7 @@ import type { Modifiers } from "../types/index.js";
6
6
  * the focus with they day.
7
7
  *
8
8
  * If you need to just change the content of the day cell, consider swapping the
9
- * `DayDate` component instead.
9
+ * `DayButton` component instead.
10
10
  *
11
11
  * @group Components
12
12
  * @see https://daypicker.dev/guides/custom-components
@@ -4,7 +4,7 @@ import React from "react";
4
4
  * the focus with they day.
5
5
  *
6
6
  * If you need to just change the content of the day cell, consider swapping the
7
- * `DayDate` component instead.
7
+ * `DayButton` component instead.
8
8
  *
9
9
  * @group Components
10
10
  * @see https://daypicker.dev/guides/custom-components
@@ -204,7 +204,7 @@ export interface PropsBase {
204
204
  /**
205
205
  * Show the outside days (days falling in the next or the previous month).
206
206
  *
207
- * **Note:** when a broadcast {@link calendar} is set, this prop defaults to
207
+ * **Note:** when a {@link broadcastCalendar} is set, this prop defaults to
208
208
  * true.
209
209
  *
210
210
  * @see https://daypicker.dev/docs/customization#outside-days
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-day-picker",
3
- "version": "9.6.0",
3
+ "version": "9.6.2",
4
4
  "description": "Customizable Date Picker for React",
5
5
  "author": "Giampaolo Bellavite <io@gpbl.dev>",
6
6
  "homepage": "https://daypicker.dev",
@@ -174,10 +174,13 @@
174
174
  },
175
175
  "files": [
176
176
  "dist",
177
- "style.css",
178
- "style.module.css",
177
+ "src/style.css",
178
+ "src/style.module.css",
179
+ "src/style.module.css.d.ts",
179
180
  "jalali.js",
180
181
  "jalali.d.ts",
182
+ "persian.js",
183
+ "persian.d.ts",
181
184
  "locale.js",
182
185
  "locale.d.ts"
183
186
  ],
@@ -188,42 +191,42 @@
188
191
  },
189
192
  "devDependencies": {
190
193
  "@jest/types": "^29.6.3",
191
- "@radix-ui/react-select": "^2.1.5",
192
- "@swc/core": "^1.10.8",
194
+ "@radix-ui/react-select": "^2.1.6",
195
+ "@swc/core": "^1.11.8",
193
196
  "@swc/jest": "^0.2.37",
194
197
  "@testing-library/dom": "^10.4.0",
195
198
  "@testing-library/jest-dom": "^6.6.3",
196
199
  "@testing-library/react": "^16.2.0",
197
- "@testing-library/user-event": "^14.6.0",
198
- "@trivago/prettier-plugin-sort-imports": "^5.2.1",
200
+ "@testing-library/user-event": "^14.6.1",
201
+ "@trivago/prettier-plugin-sort-imports": "^5.2.2",
199
202
  "@types/jest": "^29.5.14",
200
- "@types/node": "^22.10.7",
201
- "@types/react": "^19.0.7",
202
- "@types/react-dom": "^19.0.3",
203
- "@typescript-eslint/eslint-plugin": "^8.21.0",
204
- "@typescript-eslint/parser": "^8.21.0",
203
+ "@types/node": "^22.13.10",
204
+ "@types/react": "^19.0.10",
205
+ "@types/react-dom": "^19.0.4",
206
+ "@typescript-eslint/eslint-plugin": "^8.26.0",
207
+ "@typescript-eslint/parser": "^8.26.0",
205
208
  "eslint": "^8.57.1",
206
- "eslint-config-prettier": "^9.1.0",
207
- "eslint-import-resolver-typescript": "^3.7.0",
209
+ "eslint-config-prettier": "^10.1.1",
210
+ "eslint-import-resolver-typescript": "^3.8.3",
208
211
  "eslint-plugin-import": "^2.31.0",
209
212
  "eslint-plugin-jest": "^28.11.0",
210
213
  "eslint-plugin-prettier": "^5.2.3",
211
214
  "eslint-plugin-react": "^7.37.4",
212
- "eslint-plugin-react-hooks": "^5.1.0",
215
+ "eslint-plugin-react-hooks": "^5.2.0",
213
216
  "eslint-plugin-require-extensions": "^0.1.3",
214
- "eslint-plugin-testing-library": "^6.5.0",
215
- "html-validate": "^9.1.3",
217
+ "eslint-plugin-testing-library": "^7.1.1",
218
+ "html-validate": "^9.4.2",
216
219
  "jest": "^29.7.0",
217
220
  "jest-environment-jsdom": "^29.7.0",
218
221
  "jest-transform-css": "^6.0.2",
219
222
  "mockdate": "^3.0.5",
220
- "prettier": "^3.4.2",
223
+ "prettier": "^3.5.3",
221
224
  "prettier-plugin-jsdoc": "^1.3.2",
222
225
  "react": "^19.0.0",
223
226
  "react-dom": "^19.0.0",
224
227
  "ts-node": "^10.9.2",
225
228
  "tslib": "^2.8.1",
226
- "typescript": "~5.7.3",
229
+ "typescript": "~5.8.2",
227
230
  "typescript-css-modules": "^1.0.4"
228
231
  },
229
232
  "peerDependencies": {
package/persian.d.ts ADDED
@@ -0,0 +1 @@
1
+ export * from "./dist/cjs/persian.d.ts";
package/persian.js ADDED
@@ -0,0 +1,4 @@
1
+ /* eslint-disable @typescript-eslint/no-require-imports */
2
+ /* eslint-disable no-undef */
3
+ const persian = require("./dist/cjs/persian.js");
4
+ module.exports = persian;
package/src/style.css ADDED
@@ -0,0 +1,421 @@
1
+ /* Variables declaration */
2
+ /* prettier-ignore */
3
+ .rdp-root {
4
+ --rdp-accent-color: blue; /* The accent color used for selected days and UI elements. */
5
+ --rdp-accent-background-color: #f0f0ff; /* The accent background color used for selected days and UI elements. */
6
+
7
+ --rdp-day-height: 44px; /* The height of the day cells. */
8
+ --rdp-day-width: 44px; /* The width of the day cells. */
9
+
10
+ --rdp-day_button-border-radius: 100%; /* The border radius of the day cells. */
11
+ --rdp-day_button-border: 2px solid transparent; /* The border of the day cells. */
12
+ --rdp-day_button-height: 42px; /* The height of the day cells. */
13
+ --rdp-day_button-width: 42px; /* The width of the day cells. */
14
+
15
+ --rdp-selected-border: 2px solid var(--rdp-accent-color); /* The border of the selected days. */
16
+ --rdp-disabled-opacity: 0.5; /* The opacity of the disabled days. */
17
+ --rdp-outside-opacity: 0.75; /* The opacity of the days outside the current month. */
18
+ --rdp-today-color: var(--rdp-accent-color); /* The color of the today's date. */
19
+
20
+ --rdp-dropdown-gap: 0.5rem;/* The gap between the dropdowns used in the month captons. */
21
+
22
+ --rdp-months-gap: 2rem; /* The gap between the months in the multi-month view. */
23
+
24
+ --rdp-nav_button-disabled-opacity: 0.5; /* The opacity of the disabled navigation buttons. */
25
+ --rdp-nav_button-height: 2.25rem; /* The height of the navigation buttons. */
26
+ --rdp-nav_button-width: 2.25rem; /* The width of the navigation buttons. */
27
+ --rdp-nav-height: 2.75rem; /* The height of the navigation bar. */
28
+
29
+ --rdp-range_middle-background-color: var(--rdp-accent-background-color); /* The color of the background for days in the middle of a range. */
30
+ --rdp-range_middle-color: inherit;/* The color of the range text. */
31
+
32
+ --rdp-range_start-color: white; /* The color of the range text. */
33
+ --rdp-range_start-background: linear-gradient(var(--rdp-gradient-direction), transparent 50%, var(--rdp-range_middle-background-color) 50%); /* Used for the background of the start of the selected range. */
34
+ --rdp-range_start-date-background-color: var(--rdp-accent-color); /* The background color of the date when at the start of the selected range. */
35
+
36
+ --rdp-range_end-background: linear-gradient(var(--rdp-gradient-direction), var(--rdp-range_middle-background-color) 50%, transparent 50%); /* Used for the background of the end of the selected range. */
37
+ --rdp-range_end-color: white;/* The color of the range text. */
38
+ --rdp-range_end-date-background-color: var(--rdp-accent-color); /* The background color of the date when at the end of the selected range. */
39
+
40
+ --rdp-week_number-border-radius: 100%; /* The border radius of the week number. */
41
+ --rdp-week_number-border: 2px solid transparent; /* The border of the week number. */
42
+
43
+ --rdp-week_number-height: var(--rdp-day-height); /* The height of the week number cells. */
44
+ --rdp-week_number-opacity: 0.75; /* The opacity of the week number. */
45
+ --rdp-week_number-width: var(--rdp-day-width); /* The width of the week number cells. */
46
+ --rdp-weeknumber-text-align: center; /* The text alignment of the weekday cells. */
47
+
48
+ --rdp-weekday-opacity: 0.75; /* The opacity of the weekday. */
49
+ --rdp-weekday-padding: 0.5rem 0rem; /* The padding of the weekday. */
50
+ --rdp-weekday-text-align: center; /* The text alignment of the weekday cells. */
51
+
52
+ --rdp-gradient-direction: 90deg;
53
+
54
+ --rdp-animation_duration: 0.3s;
55
+ --rdp-animation_timing: cubic-bezier(0.4, 0, 0.2, 1);
56
+ }
57
+
58
+ .rdp-root[dir="rtl"] {
59
+ --rdp-gradient-direction: -90deg;
60
+ }
61
+
62
+ .rdp-root[data-broadcast-calendar="true"] {
63
+ --rdp-outside-opacity: unset;
64
+ }
65
+
66
+ /* Root of the component. */
67
+ .rdp-root {
68
+ position: relative; /* Required to position the navigation toolbar. */
69
+ box-sizing: border-box;
70
+ }
71
+
72
+ .rdp-root * {
73
+ box-sizing: border-box;
74
+ }
75
+
76
+ .rdp-day {
77
+ width: var(--rdp-day-width);
78
+ height: var(--rdp-day-height);
79
+ text-align: center;
80
+ }
81
+
82
+ .rdp-day_button {
83
+ background: none;
84
+ padding: 0;
85
+ margin: 0;
86
+ cursor: pointer;
87
+ font: inherit;
88
+ color: inherit;
89
+ justify-content: center;
90
+ align-items: center;
91
+ display: flex;
92
+
93
+ width: var(--rdp-day_button-width);
94
+ height: var(--rdp-day_button-height);
95
+ border: var(--rdp-day_button-border);
96
+ border-radius: var(--rdp-day_button-border-radius);
97
+ }
98
+
99
+ .rdp-day_button:disabled {
100
+ cursor: revert;
101
+ }
102
+
103
+ .rdp-caption_label {
104
+ z-index: 1;
105
+
106
+ position: relative;
107
+ display: inline-flex;
108
+ align-items: center;
109
+
110
+ white-space: nowrap;
111
+ border: 0;
112
+ }
113
+
114
+ .rdp-dropdown:focus-visible ~ .rdp-caption_label {
115
+ outline: 5px auto Highlight;
116
+ outline: 5px auto -webkit-focus-ring-color;
117
+ }
118
+
119
+ .rdp-button_next,
120
+ .rdp-button_previous {
121
+ border: none;
122
+ background: none;
123
+ padding: 0;
124
+ margin: 0;
125
+ cursor: pointer;
126
+ font: inherit;
127
+ color: inherit;
128
+ -moz-appearance: none;
129
+ -webkit-appearance: none;
130
+ display: inline-flex;
131
+ align-items: center;
132
+ justify-content: center;
133
+ position: relative;
134
+ appearance: none;
135
+
136
+ width: var(--rdp-nav_button-width);
137
+ height: var(--rdp-nav_button-height);
138
+ }
139
+
140
+ .rdp-button_next:disabled,
141
+ .rdp-button_next[aria-disabled="true"],
142
+ .rdp-button_previous:disabled,
143
+ .rdp-button_previous[aria-disabled="true"] {
144
+ cursor: revert;
145
+
146
+ opacity: var(--rdp-nav_button-disabled-opacity);
147
+ }
148
+
149
+ .rdp-chevron {
150
+ display: inline-block;
151
+ fill: var(--rdp-accent-color);
152
+ }
153
+
154
+ .rdp-root[dir="rtl"] .rdp-nav .rdp-chevron {
155
+ transform: rotate(180deg);
156
+ transform-origin: 50%;
157
+ }
158
+
159
+ .rdp-dropdowns {
160
+ position: relative;
161
+ display: inline-flex;
162
+ align-items: center;
163
+ gap: var(--rdp-dropdown-gap);
164
+ }
165
+ .rdp-dropdown {
166
+ z-index: 2;
167
+
168
+ /* Reset */
169
+ opacity: 0;
170
+ appearance: none;
171
+ position: absolute;
172
+ inset-block-start: 0;
173
+ inset-block-end: 0;
174
+ inset-inline-start: 0;
175
+ width: 100%;
176
+ margin: 0;
177
+ padding: 0;
178
+ cursor: inherit;
179
+ border: none;
180
+ line-height: inherit;
181
+ }
182
+
183
+ .rdp-dropdown_root {
184
+ position: relative;
185
+ display: inline-flex;
186
+ align-items: center;
187
+ }
188
+
189
+ .rdp-dropdown_root[data-disabled="true"] .rdp-chevron {
190
+ opacity: var(--rdp-disabled-opacity);
191
+ }
192
+
193
+ .rdp-month_caption {
194
+ display: flex;
195
+ align-content: center;
196
+ height: var(--rdp-nav-height);
197
+ font-weight: bold;
198
+ font-size: large;
199
+ }
200
+
201
+ .rdp-months {
202
+ position: relative;
203
+ display: flex;
204
+ flex-wrap: wrap;
205
+ gap: var(--rdp-months-gap);
206
+ max-width: fit-content;
207
+ }
208
+
209
+ .rdp-month_grid {
210
+ border-collapse: collapse;
211
+ }
212
+
213
+ .rdp-nav {
214
+ position: absolute;
215
+ inset-block-start: 0;
216
+ inset-inline-end: 0;
217
+
218
+ display: flex;
219
+ align-items: center;
220
+
221
+ height: var(--rdp-nav-height);
222
+ }
223
+
224
+ .rdp-weekday {
225
+ opacity: var(--rdp-weekday-opacity);
226
+ padding: var(--rdp-weekday-padding);
227
+ font-weight: 500;
228
+ font-size: smaller;
229
+ text-align: var(--rdp-weekday-text-align);
230
+ text-transform: var(--rdp-weekday-text-transform);
231
+ }
232
+
233
+ .rdp-week_number {
234
+ opacity: var(--rdp-week_number-opacity);
235
+ font-weight: 400;
236
+ font-size: small;
237
+ height: var(--rdp-week_number-height);
238
+ width: var(--rdp-week_number-width);
239
+ border: var(--rdp-week_number-border);
240
+ border-radius: var(--rdp-week_number-border-radius);
241
+ text-align: var(--rdp-weeknumber-text-align);
242
+ }
243
+
244
+ /* DAY MODIFIERS */
245
+ .rdp-today:not(.rdp-outside) {
246
+ color: var(--rdp-today-color);
247
+ }
248
+
249
+ .rdp-selected {
250
+ font-weight: bold;
251
+ font-size: large;
252
+ }
253
+
254
+ .rdp-selected .rdp-day_button {
255
+ border: var(--rdp-selected-border);
256
+ }
257
+
258
+ .rdp-outside {
259
+ opacity: var(--rdp-outside-opacity);
260
+ }
261
+
262
+ .rdp-disabled {
263
+ opacity: var(--rdp-disabled-opacity);
264
+ }
265
+
266
+ .rdp-hidden {
267
+ visibility: hidden;
268
+ color: var(--rdp-range_start-color);
269
+ }
270
+
271
+ .rdp-range_start {
272
+ background: var(--rdp-range_start-background);
273
+ }
274
+
275
+ .rdp-range_start .rdp-day_button {
276
+ background-color: var(--rdp-range_start-date-background-color);
277
+ color: var(--rdp-range_start-color);
278
+ }
279
+
280
+ .rdp-range_middle {
281
+ background-color: var(--rdp-range_middle-background-color);
282
+ }
283
+
284
+ .rdp-range_middle .rdp-day_button {
285
+ border-color: transparent;
286
+ border: unset;
287
+ border-radius: unset;
288
+ color: var(--rdp-range_middle-color);
289
+ }
290
+
291
+ .rdp-range_end {
292
+ background: var(--rdp-range_end-background);
293
+ color: var(--rdp-range_end-color);
294
+ }
295
+
296
+ .rdp-range_end .rdp-day_button {
297
+ color: var(--rdp-range_start-color);
298
+ background-color: var(--rdp-range_end-date-background-color);
299
+ }
300
+
301
+ .rdp-range_start.rdp-range_end {
302
+ background: revert;
303
+ }
304
+
305
+ .rdp-focusable {
306
+ cursor: pointer;
307
+ }
308
+
309
+ @keyframes rdp-slide_in_left {
310
+ 0% {
311
+ transform: translateX(-100%);
312
+ }
313
+ 100% {
314
+ transform: translateX(0);
315
+ }
316
+ }
317
+
318
+ @keyframes rdp-slide_in_right {
319
+ 0% {
320
+ transform: translateX(100%);
321
+ }
322
+ 100% {
323
+ transform: translateX(0);
324
+ }
325
+ }
326
+
327
+ @keyframes rdp-slide_out_left {
328
+ 0% {
329
+ transform: translateX(0);
330
+ }
331
+ 100% {
332
+ transform: translateX(-100%);
333
+ }
334
+ }
335
+
336
+ @keyframes rdp-slide_out_right {
337
+ 0% {
338
+ transform: translateX(0);
339
+ }
340
+ 100% {
341
+ transform: translateX(100%);
342
+ }
343
+ }
344
+
345
+ .rdp-weeks_before_enter {
346
+ animation: rdp-slide_in_left var(--rdp-animation_duration)
347
+ var(--rdp-animation_timing) forwards;
348
+ }
349
+
350
+ .rdp-weeks_before_exit {
351
+ animation: rdp-slide_out_left var(--rdp-animation_duration)
352
+ var(--rdp-animation_timing) forwards;
353
+ }
354
+
355
+ .rdp-weeks_after_enter {
356
+ animation: rdp-slide_in_right var(--rdp-animation_duration)
357
+ var(--rdp-animation_timing) forwards;
358
+ }
359
+
360
+ .rdp-weeks_after_exit {
361
+ animation: rdp-slide_out_right var(--rdp-animation_duration)
362
+ var(--rdp-animation_timing) forwards;
363
+ }
364
+
365
+ .rdp-root[dir="rtl"] .rdp-weeks_after_enter {
366
+ animation: rdp-slide_in_left var(--rdp-animation_duration)
367
+ var(--rdp-animation_timing) forwards;
368
+ }
369
+
370
+ .rdp-root[dir="rtl"] .rdp-weeks_before_exit {
371
+ animation: rdp-slide_out_right var(--rdp-animation_duration)
372
+ var(--rdp-animation_timing) forwards;
373
+ }
374
+
375
+ .rdp-root[dir="rtl"] .rdp-weeks_before_enter {
376
+ animation: rdp-slide_in_right var(--rdp-animation_duration)
377
+ var(--rdp-animation_timing) forwards;
378
+ }
379
+
380
+ .rdp-root[dir="rtl"] .rdp-weeks_after_exit {
381
+ animation: rdp-slide_out_left var(--rdp-animation_duration)
382
+ var(--rdp-animation_timing) forwards;
383
+ }
384
+
385
+ @keyframes rdp-fade_in {
386
+ from {
387
+ opacity: 0;
388
+ }
389
+ to {
390
+ opacity: 1;
391
+ }
392
+ }
393
+
394
+ @keyframes rdp-fade_out {
395
+ from {
396
+ opacity: 1;
397
+ }
398
+ to {
399
+ opacity: 0;
400
+ }
401
+ }
402
+
403
+ .rdp-caption_after_enter {
404
+ animation: rdp-fade_in var(--rdp-animation_duration)
405
+ var(--rdp-animation_timing) forwards;
406
+ }
407
+
408
+ .rdp-caption_after_exit {
409
+ animation: rdp-fade_out var(--rdp-animation_duration)
410
+ var(--rdp-animation_timing) forwards;
411
+ }
412
+
413
+ .rdp-caption_before_enter {
414
+ animation: rdp-fade_in var(--rdp-animation_duration)
415
+ var(--rdp-animation_timing) forwards;
416
+ }
417
+
418
+ .rdp-caption_before_exit {
419
+ animation: rdp-fade_out var(--rdp-animation_duration)
420
+ var(--rdp-animation_timing) forwards;
421
+ }
@@ -0,0 +1,421 @@
1
+ /* Variables declaration */
2
+ /* prettier-ignore */
3
+ .root {
4
+ --rdp-accent-color: blue; /* The accent color used for selected days and UI elements. */
5
+ --rdp-accent-background-color: #f0f0ff; /* The accent background color used for selected days and UI elements. */
6
+
7
+ --rdp-day-height: 44px; /* The height of the day cells. */
8
+ --rdp-day-width: 44px; /* The width of the day cells. */
9
+
10
+ --rdp-day_button-border-radius: 100%; /* The border radius of the day cells. */
11
+ --rdp-day_button-border: 2px solid transparent; /* The border of the day cells. */
12
+ --rdp-day_button-height: 42px; /* The height of the day cells. */
13
+ --rdp-day_button-width: 42px; /* The width of the day cells. */
14
+
15
+ --rdp-selected-border: 2px solid var(--rdp-accent-color); /* The border of the selected days. */
16
+ --rdp-disabled-opacity: 0.5; /* The opacity of the disabled days. */
17
+ --rdp-outside-opacity: 0.75; /* The opacity of the days outside the current month. */
18
+ --rdp-today-color: var(--rdp-accent-color); /* The color of the today's date. */
19
+
20
+ --rdp-dropdown-gap: 0.5rem;/* The gap between the dropdowns used in the month captons. */
21
+
22
+ --rdp-months-gap: 2rem; /* The gap between the months in the multi-month view. */
23
+
24
+ --rdp-nav_button-disabled-opacity: 0.5; /* The opacity of the disabled navigation buttons. */
25
+ --rdp-nav_button-height: 2.25rem; /* The height of the navigation buttons. */
26
+ --rdp-nav_button-width: 2.25rem; /* The width of the navigation buttons. */
27
+ --rdp-nav-height: 2.75rem; /* The height of the navigation bar. */
28
+
29
+ --rdp-range_middle-background-color: var(--rdp-accent-background-color); /* The color of the background for days in the middle of a range. */
30
+ --rdp-range_middle-color: inherit;/* The color of the range text. */
31
+
32
+ --rdp-range_start-color: white; /* The color of the range text. */
33
+ --rdp-range_start-background: linear-gradient(var(--rdp-gradient-direction), transparent 50%, var(--rdp-range_middle-background-color) 50%); /* Used for the background of the start of the selected range. */
34
+ --rdp-range_start-date-background-color: var(--rdp-accent-color); /* The background color of the date when at the start of the selected range. */
35
+
36
+ --rdp-range_end-background: linear-gradient(var(--rdp-gradient-direction), var(--rdp-range_middle-background-color) 50%, transparent 50%); /* Used for the background of the end of the selected range. */
37
+ --rdp-range_end-color: white;/* The color of the range text. */
38
+ --rdp-range_end-date-background-color: var(--rdp-accent-color); /* The background color of the date when at the end of the selected range. */
39
+
40
+ --rdp-week_number-border-radius: 100%; /* The border radius of the week number. */
41
+ --rdp-week_number-border: 2px solid transparent; /* The border of the week number. */
42
+
43
+ --rdp-week_number-height: var(--rdp-day-height); /* The height of the week number cells. */
44
+ --rdp-week_number-opacity: 0.75; /* The opacity of the week number. */
45
+ --rdp-week_number-width: var(--rdp-day-width); /* The width of the week number cells. */
46
+ --rdp-weeknumber-text-align: center; /* The text alignment of the weekday cells. */
47
+
48
+ --rdp-weekday-opacity: 0.75; /* The opacity of the weekday. */
49
+ --rdp-weekday-padding: 0.5rem 0rem; /* The padding of the weekday. */
50
+ --rdp-weekday-text-align: center; /* The text alignment of the weekday cells. */
51
+
52
+ --rdp-gradient-direction: 90deg;
53
+
54
+ --rdp-animation_duration: 0.3s;
55
+ --rdp-animation_timing: cubic-bezier(0.4, 0, 0.2, 1);
56
+ }
57
+
58
+ .root[dir="rtl"] {
59
+ --rdp-gradient-direction: -90deg;
60
+ }
61
+
62
+ .root[data-broadcast-calendar="true"] {
63
+ --rdp-outside-opacity: unset;
64
+ }
65
+
66
+ /* Root of the component. */
67
+ .root {
68
+ position: relative; /* Required to position the navigation toolbar. */
69
+ box-sizing: border-box;
70
+ }
71
+
72
+ .root * {
73
+ box-sizing: border-box;
74
+ }
75
+
76
+ .day {
77
+ width: var(--rdp-day-width);
78
+ height: var(--rdp-day-height);
79
+ text-align: center;
80
+ }
81
+
82
+ .day_button {
83
+ background: none;
84
+ padding: 0;
85
+ margin: 0;
86
+ cursor: pointer;
87
+ font: inherit;
88
+ color: inherit;
89
+ justify-content: center;
90
+ align-items: center;
91
+ display: flex;
92
+
93
+ width: var(--rdp-day_button-width);
94
+ height: var(--rdp-day_button-height);
95
+ border: var(--rdp-day_button-border);
96
+ border-radius: var(--rdp-day_button-border-radius);
97
+ }
98
+
99
+ .day_button:disabled {
100
+ cursor: revert;
101
+ }
102
+
103
+ .caption_label {
104
+ z-index: 1;
105
+
106
+ position: relative;
107
+ display: inline-flex;
108
+ align-items: center;
109
+
110
+ white-space: nowrap;
111
+ border: 0;
112
+ }
113
+
114
+ .dropdown:focus-visible ~ .caption_label {
115
+ outline: 5px auto Highlight;
116
+ outline: 5px auto -webkit-focus-ring-color;
117
+ }
118
+
119
+ .button_next,
120
+ .button_previous {
121
+ border: none;
122
+ background: none;
123
+ padding: 0;
124
+ margin: 0;
125
+ cursor: pointer;
126
+ font: inherit;
127
+ color: inherit;
128
+ -moz-appearance: none;
129
+ -webkit-appearance: none;
130
+ display: inline-flex;
131
+ align-items: center;
132
+ justify-content: center;
133
+ position: relative;
134
+ appearance: none;
135
+
136
+ width: var(--rdp-nav_button-width);
137
+ height: var(--rdp-nav_button-height);
138
+ }
139
+
140
+ .button_next:disabled,
141
+ .button_next[aria-disabled="true"],
142
+ .button_previous:disabled,
143
+ .button_previous[aria-disabled="true"] {
144
+ cursor: revert;
145
+
146
+ opacity: var(--rdp-nav_button-disabled-opacity);
147
+ }
148
+
149
+ .chevron {
150
+ display: inline-block;
151
+ fill: var(--rdp-accent-color);
152
+ }
153
+
154
+ .root[dir="rtl"] .nav .chevron {
155
+ transform: rotate(180deg);
156
+ transform-origin: 50%;
157
+ }
158
+
159
+ .dropdowns {
160
+ position: relative;
161
+ display: inline-flex;
162
+ align-items: center;
163
+ gap: var(--rdp-dropdown-gap);
164
+ }
165
+ .dropdown {
166
+ z-index: 2;
167
+
168
+ /* Reset */
169
+ opacity: 0;
170
+ appearance: none;
171
+ position: absolute;
172
+ inset-block-start: 0;
173
+ inset-block-end: 0;
174
+ inset-inline-start: 0;
175
+ width: 100%;
176
+ margin: 0;
177
+ padding: 0;
178
+ cursor: inherit;
179
+ border: none;
180
+ line-height: inherit;
181
+ }
182
+
183
+ .dropdown_root {
184
+ position: relative;
185
+ display: inline-flex;
186
+ align-items: center;
187
+ }
188
+
189
+ .dropdown_root[data-disabled="true"] .chevron {
190
+ opacity: var(--rdp-disabled-opacity);
191
+ }
192
+
193
+ .month_caption {
194
+ display: flex;
195
+ align-content: center;
196
+ height: var(--rdp-nav-height);
197
+ font-weight: bold;
198
+ font-size: large;
199
+ }
200
+
201
+ .months {
202
+ position: relative;
203
+ display: flex;
204
+ flex-wrap: wrap;
205
+ gap: var(--rdp-months-gap);
206
+ max-width: fit-content;
207
+ }
208
+
209
+ .month_grid {
210
+ border-collapse: collapse;
211
+ }
212
+
213
+ .nav {
214
+ position: absolute;
215
+ inset-block-start: 0;
216
+ inset-inline-end: 0;
217
+
218
+ display: flex;
219
+ align-items: center;
220
+
221
+ height: var(--rdp-nav-height);
222
+ }
223
+
224
+ .weekday {
225
+ opacity: var(--rdp-weekday-opacity);
226
+ padding: var(--rdp-weekday-padding);
227
+ font-weight: 500;
228
+ font-size: smaller;
229
+ text-align: var(--rdp-weekday-text-align);
230
+ text-transform: var(--rdp-weekday-text-transform);
231
+ }
232
+
233
+ .week_number {
234
+ opacity: var(--rdp-week_number-opacity);
235
+ font-weight: 400;
236
+ font-size: small;
237
+ height: var(--rdp-week_number-height);
238
+ width: var(--rdp-week_number-width);
239
+ border: var(--rdp-week_number-border);
240
+ border-radius: var(--rdp-week_number-border-radius);
241
+ text-align: var(--rdp-weeknumber-text-align);
242
+ }
243
+
244
+ /* DAY MODIFIERS */
245
+ .today:not(.outside) {
246
+ color: var(--rdp-today-color);
247
+ }
248
+
249
+ .selected {
250
+ font-weight: bold;
251
+ font-size: large;
252
+ }
253
+
254
+ .selected .day_button {
255
+ border: var(--rdp-selected-border);
256
+ }
257
+
258
+ .outside {
259
+ opacity: var(--rdp-outside-opacity);
260
+ }
261
+
262
+ .disabled {
263
+ opacity: var(--rdp-disabled-opacity);
264
+ }
265
+
266
+ .hidden {
267
+ visibility: hidden;
268
+ color: var(--rdp-range_start-color);
269
+ }
270
+
271
+ .range_start {
272
+ background: var(--rdp-range_start-background);
273
+ }
274
+
275
+ .range_start .day_button {
276
+ background-color: var(--rdp-range_start-date-background-color);
277
+ color: var(--rdp-range_start-color);
278
+ }
279
+
280
+ .range_middle {
281
+ background-color: var(--rdp-range_middle-background-color);
282
+ }
283
+
284
+ .range_middle .day_button {
285
+ border-color: transparent;
286
+ border: unset;
287
+ border-radius: unset;
288
+ color: var(--rdp-range_middle-color);
289
+ }
290
+
291
+ .range_end {
292
+ background: var(--rdp-range_end-background);
293
+ color: var(--rdp-range_end-color);
294
+ }
295
+
296
+ .range_end .day_button {
297
+ color: var(--rdp-range_start-color);
298
+ background-color: var(--rdp-range_end-date-background-color);
299
+ }
300
+
301
+ .range_start.range_end {
302
+ background: revert;
303
+ }
304
+
305
+ .focusable {
306
+ cursor: pointer;
307
+ }
308
+
309
+ @keyframes rdp-slide_in_left {
310
+ 0% {
311
+ transform: translateX(-100%);
312
+ }
313
+ 100% {
314
+ transform: translateX(0);
315
+ }
316
+ }
317
+
318
+ @keyframes rdp-slide_in_right {
319
+ 0% {
320
+ transform: translateX(100%);
321
+ }
322
+ 100% {
323
+ transform: translateX(0);
324
+ }
325
+ }
326
+
327
+ @keyframes rdp-slide_out_left {
328
+ 0% {
329
+ transform: translateX(0);
330
+ }
331
+ 100% {
332
+ transform: translateX(-100%);
333
+ }
334
+ }
335
+
336
+ @keyframes rdp-slide_out_right {
337
+ 0% {
338
+ transform: translateX(0);
339
+ }
340
+ 100% {
341
+ transform: translateX(100%);
342
+ }
343
+ }
344
+
345
+ .weeks_before_enter {
346
+ animation: rdp-slide_in_left var(--rdp-animation_duration)
347
+ var(--rdp-animation_timing) forwards;
348
+ }
349
+
350
+ .weeks_before_exit {
351
+ animation: rdp-slide_out_left var(--rdp-animation_duration)
352
+ var(--rdp-animation_timing) forwards;
353
+ }
354
+
355
+ .weeks_after_enter {
356
+ animation: rdp-slide_in_right var(--rdp-animation_duration)
357
+ var(--rdp-animation_timing) forwards;
358
+ }
359
+
360
+ .weeks_after_exit {
361
+ animation: rdp-slide_out_right var(--rdp-animation_duration)
362
+ var(--rdp-animation_timing) forwards;
363
+ }
364
+
365
+ .root[dir="rtl"] .weeks_after_enter {
366
+ animation: rdp-slide_in_left var(--rdp-animation_duration)
367
+ var(--rdp-animation_timing) forwards;
368
+ }
369
+
370
+ .root[dir="rtl"] .weeks_before_exit {
371
+ animation: rdp-slide_out_right var(--rdp-animation_duration)
372
+ var(--rdp-animation_timing) forwards;
373
+ }
374
+
375
+ .root[dir="rtl"] .weeks_before_enter {
376
+ animation: rdp-slide_in_right var(--rdp-animation_duration)
377
+ var(--rdp-animation_timing) forwards;
378
+ }
379
+
380
+ .root[dir="rtl"] .weeks_after_exit {
381
+ animation: rdp-slide_out_left var(--rdp-animation_duration)
382
+ var(--rdp-animation_timing) forwards;
383
+ }
384
+
385
+ @keyframes rdp-fade_in {
386
+ from {
387
+ opacity: 0;
388
+ }
389
+ to {
390
+ opacity: 1;
391
+ }
392
+ }
393
+
394
+ @keyframes rdp-fade_out {
395
+ from {
396
+ opacity: 1;
397
+ }
398
+ to {
399
+ opacity: 0;
400
+ }
401
+ }
402
+
403
+ .caption_after_enter {
404
+ animation: rdp-fade_in var(--rdp-animation_duration)
405
+ var(--rdp-animation_timing) forwards;
406
+ }
407
+
408
+ .caption_after_exit {
409
+ animation: rdp-fade_out var(--rdp-animation_duration)
410
+ var(--rdp-animation_timing) forwards;
411
+ }
412
+
413
+ .caption_before_enter {
414
+ animation: rdp-fade_in var(--rdp-animation_duration)
415
+ var(--rdp-animation_timing) forwards;
416
+ }
417
+
418
+ .caption_before_exit {
419
+ animation: rdp-fade_out var(--rdp-animation_duration)
420
+ var(--rdp-animation_timing) forwards;
421
+ }
@@ -0,0 +1,29 @@
1
+ declare const styles: {
2
+ root: string;
3
+ day: string;
4
+ day_button: string;
5
+ caption_label: string;
6
+ button_next: string;
7
+ button_previous: string;
8
+ chevron: string;
9
+ dropdowns: string;
10
+ dropdown: string;
11
+ dropdown_root: string;
12
+ month_caption: string;
13
+ months: string;
14
+ month_grid: string;
15
+ nav: string;
16
+ weekday: string;
17
+ week_number: string;
18
+ today: string;
19
+ selected: string;
20
+ outside: string;
21
+ disabled: string;
22
+ hidden: string;
23
+ range_start: string;
24
+ range_middle: string;
25
+ range_end: string;
26
+ focusable: string;
27
+ };
28
+
29
+ export default styles;