willba-component-library 0.2.84 → 0.2.86

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.
@@ -52,5 +52,6 @@ export type Tab = {
52
52
  default?: boolean;
53
53
  order: number;
54
54
  label?: Translations;
55
+ dateOffset?: number;
55
56
  };
56
57
  export {};
package/lib/index.d.ts CHANGED
@@ -110,6 +110,7 @@ type Tab = {
110
110
  default?: boolean;
111
111
  order: number;
112
112
  label?: Translations;
113
+ dateOffset?: number;
113
114
  };
114
115
 
115
116
  declare function FilterBar({ language, ageCategories, redirectUrl, palette, onSubmit, fullWidth, disableCalendarDates, mode, tabs, outerLoading, }: FilterBarProps): React.JSX.Element;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "willba-component-library",
3
- "version": "0.2.84",
3
+ "version": "0.2.86",
4
4
  "description": "A custom UI component library",
5
5
  "main": "lib/index.js",
6
6
  "module": "lib/index.esm.js",
@@ -59,4 +59,5 @@ export type Tab = {
59
59
  default?: boolean
60
60
  order: number
61
61
  label?: Translations
62
+ dateOffset?: number
62
63
  }
@@ -14,11 +14,463 @@ type Story = StoryObj<typeof FilterCalendar>
14
14
 
15
15
  const baseData = {
16
16
  disableCalendarDates: {
17
- availableDates: [],
17
+ availableDates: [
18
+ {
19
+ checkIn: new Date('2025-01-01'),
20
+ firstCheckOut: new Date('2025-01-02'),
21
+ lastCheckOut: new Date('2025-01-04'),
22
+ },
23
+ {
24
+ checkIn: new Date('2025-01-02'),
25
+ firstCheckOut: new Date('2025-01-03'),
26
+ lastCheckOut: new Date('2025-01-04'),
27
+ },
28
+ {
29
+ checkIn: new Date('2025-01-03'),
30
+ firstCheckOut: new Date('2025-01-04'),
31
+ lastCheckOut: new Date('2025-01-04'),
32
+ },
33
+ {
34
+ checkIn: new Date('2025-01-08'),
35
+ firstCheckOut: new Date('2025-01-09'),
36
+ lastCheckOut: new Date('2025-01-14'),
37
+ },
38
+ {
39
+ checkIn: new Date('2025-01-09'),
40
+ firstCheckOut: new Date('2025-01-10'),
41
+ lastCheckOut: new Date('2025-01-14'),
42
+ },
43
+ {
44
+ checkIn: new Date('2025-01-10'),
45
+ firstCheckOut: new Date('2025-01-11'),
46
+ lastCheckOut: new Date('2025-01-14'),
47
+ },
48
+ {
49
+ checkIn: new Date('2025-01-11'),
50
+ firstCheckOut: new Date('2025-01-12'),
51
+ lastCheckOut: new Date('2025-01-14'),
52
+ },
53
+ {
54
+ checkIn: new Date('2025-01-12'),
55
+ firstCheckOut: new Date('2025-01-13'),
56
+ lastCheckOut: new Date('2025-01-14'),
57
+ },
58
+ {
59
+ checkIn: new Date('2025-01-13'),
60
+ firstCheckOut: new Date('2025-01-14'),
61
+ lastCheckOut: new Date('2025-01-14'),
62
+ },
63
+ {
64
+ checkIn: new Date('2025-01-17'),
65
+ firstCheckOut: new Date('2025-01-18'),
66
+ lastCheckOut: new Date('2025-02-05'),
67
+ },
68
+ {
69
+ checkIn: new Date('2025-01-18'),
70
+ firstCheckOut: new Date('2025-01-19'),
71
+ lastCheckOut: new Date('2025-02-05'),
72
+ },
73
+ {
74
+ checkIn: new Date('2025-01-19'),
75
+ firstCheckOut: new Date('2025-01-20'),
76
+ lastCheckOut: new Date('2025-02-05'),
77
+ },
78
+ {
79
+ checkIn: new Date('2025-01-20'),
80
+ firstCheckOut: new Date('2025-01-21'),
81
+ lastCheckOut: new Date('2025-02-05'),
82
+ },
83
+ {
84
+ checkIn: new Date('2025-01-21'),
85
+ firstCheckOut: new Date('2025-01-22'),
86
+ lastCheckOut: new Date('2025-02-05'),
87
+ },
88
+ {
89
+ checkIn: new Date('2025-01-22'),
90
+ firstCheckOut: new Date('2025-01-23'),
91
+ lastCheckOut: new Date('2025-02-05'),
92
+ },
93
+ {
94
+ checkIn: new Date('2025-01-23'),
95
+ firstCheckOut: new Date('2025-01-24'),
96
+ lastCheckOut: new Date('2025-02-05'),
97
+ },
98
+ {
99
+ checkIn: new Date('2025-01-24'),
100
+ firstCheckOut: new Date('2025-01-25'),
101
+ lastCheckOut: new Date('2025-02-11'),
102
+ },
103
+ {
104
+ checkIn: new Date('2025-01-25'),
105
+ firstCheckOut: new Date('2025-01-26'),
106
+ lastCheckOut: new Date('2025-02-11'),
107
+ },
108
+ {
109
+ checkIn: new Date('2025-01-26'),
110
+ firstCheckOut: new Date('2025-01-27'),
111
+ lastCheckOut: new Date('2025-02-11'),
112
+ },
113
+ {
114
+ checkIn: new Date('2025-01-27'),
115
+ firstCheckOut: new Date('2025-01-28'),
116
+ lastCheckOut: new Date('2025-02-11'),
117
+ },
118
+ {
119
+ checkIn: new Date('2025-01-28'),
120
+ firstCheckOut: new Date('2025-01-29'),
121
+ lastCheckOut: new Date('2025-02-11'),
122
+ },
123
+ {
124
+ checkIn: new Date('2025-01-29'),
125
+ firstCheckOut: new Date('2025-01-30'),
126
+ lastCheckOut: new Date('2025-02-11'),
127
+ },
128
+ {
129
+ checkIn: new Date('2025-01-30'),
130
+ firstCheckOut: new Date('2025-01-31'),
131
+ lastCheckOut: new Date('2025-02-11'),
132
+ },
133
+ {
134
+ checkIn: new Date('2025-01-31'),
135
+ firstCheckOut: new Date('2025-02-01'),
136
+ lastCheckOut: new Date('2025-02-11'),
137
+ },
138
+ {
139
+ checkIn: new Date('2025-02-01'),
140
+ firstCheckOut: new Date('2025-02-02'),
141
+ lastCheckOut: new Date('2025-02-11'),
142
+ },
143
+ {
144
+ checkIn: new Date('2025-02-02'),
145
+ firstCheckOut: new Date('2025-02-03'),
146
+ lastCheckOut: new Date('2025-02-11'),
147
+ },
148
+ {
149
+ checkIn: new Date('2025-02-03'),
150
+ firstCheckOut: new Date('2025-02-04'),
151
+ lastCheckOut: new Date('2025-02-11'),
152
+ },
153
+ {
154
+ checkIn: new Date('2025-02-04'),
155
+ firstCheckOut: new Date('2025-02-05'),
156
+ lastCheckOut: new Date('2025-02-11'),
157
+ },
158
+ {
159
+ checkIn: new Date('2025-02-05'),
160
+ firstCheckOut: new Date('2025-02-06'),
161
+ lastCheckOut: new Date('2025-02-11'),
162
+ },
163
+ {
164
+ checkIn: new Date('2025-02-06'),
165
+ firstCheckOut: new Date('2025-02-07'),
166
+ lastCheckOut: new Date('2025-02-11'),
167
+ },
168
+ {
169
+ checkIn: new Date('2025-02-07'),
170
+ firstCheckOut: new Date('2025-02-08'),
171
+ lastCheckOut: new Date('2025-02-11'),
172
+ },
173
+ {
174
+ checkIn: new Date('2025-02-08'),
175
+ firstCheckOut: new Date('2025-02-09'),
176
+ lastCheckOut: new Date('2025-02-11'),
177
+ },
178
+ {
179
+ checkIn: new Date('2025-02-09'),
180
+ firstCheckOut: new Date('2025-02-10'),
181
+ lastCheckOut: new Date('2025-02-11'),
182
+ },
183
+ {
184
+ checkIn: new Date('2025-02-10'),
185
+ firstCheckOut: new Date('2025-02-11'),
186
+ lastCheckOut: new Date('2025-02-11'),
187
+ },
188
+ {
189
+ checkIn: new Date('2025-02-11'),
190
+ firstCheckOut: new Date('2025-02-12'),
191
+ lastCheckOut: new Date('2025-03-01'),
192
+ },
193
+ {
194
+ checkIn: new Date('2025-02-12'),
195
+ firstCheckOut: new Date('2025-02-13'),
196
+ lastCheckOut: new Date('2025-03-01'),
197
+ },
198
+ {
199
+ checkIn: new Date('2025-02-13'),
200
+ firstCheckOut: new Date('2025-02-14'),
201
+ lastCheckOut: new Date('2025-03-01'),
202
+ },
203
+ {
204
+ checkIn: new Date('2025-02-14'),
205
+ firstCheckOut: new Date('2025-02-15'),
206
+ lastCheckOut: new Date('2025-03-01'),
207
+ },
208
+ {
209
+ checkIn: new Date('2025-02-15'),
210
+ firstCheckOut: new Date('2025-02-16'),
211
+ lastCheckOut: new Date('2025-03-01'),
212
+ },
213
+ {
214
+ checkIn: new Date('2025-02-16'),
215
+ firstCheckOut: new Date('2025-02-17'),
216
+ lastCheckOut: new Date('2025-03-01'),
217
+ },
218
+ {
219
+ checkIn: new Date('2025-02-17'),
220
+ firstCheckOut: new Date('2025-02-18'),
221
+ lastCheckOut: new Date('2025-03-01'),
222
+ },
223
+ {
224
+ checkIn: new Date('2025-02-18'),
225
+ firstCheckOut: new Date('2025-02-19'),
226
+ lastCheckOut: new Date('2025-03-01'),
227
+ },
228
+ {
229
+ checkIn: new Date('2025-02-19'),
230
+ firstCheckOut: new Date('2025-02-20'),
231
+ lastCheckOut: new Date('2025-03-01'),
232
+ },
233
+ {
234
+ checkIn: new Date('2025-02-20'),
235
+ firstCheckOut: new Date('2025-02-21'),
236
+ lastCheckOut: new Date('2025-03-01'),
237
+ },
238
+ {
239
+ checkIn: new Date('2025-02-21'),
240
+ firstCheckOut: new Date('2025-02-22'),
241
+ lastCheckOut: new Date('2025-03-12'),
242
+ },
243
+ {
244
+ checkIn: new Date('2025-02-22'),
245
+ firstCheckOut: new Date('2025-02-23'),
246
+ lastCheckOut: new Date('2025-03-12'),
247
+ },
248
+ {
249
+ checkIn: new Date('2025-02-23'),
250
+ firstCheckOut: new Date('2025-02-24'),
251
+ lastCheckOut: new Date('2025-03-12'),
252
+ },
253
+ {
254
+ checkIn: new Date('2025-02-24'),
255
+ firstCheckOut: new Date('2025-02-25'),
256
+ lastCheckOut: new Date('2025-03-12'),
257
+ },
258
+ {
259
+ checkIn: new Date('2025-02-25'),
260
+ firstCheckOut: new Date('2025-02-26'),
261
+ lastCheckOut: new Date('2025-03-12'),
262
+ },
263
+ {
264
+ checkIn: new Date('2025-02-26'),
265
+ firstCheckOut: new Date('2025-02-27'),
266
+ lastCheckOut: new Date('2025-03-12'),
267
+ },
268
+ {
269
+ checkIn: new Date('2025-02-27'),
270
+ firstCheckOut: new Date('2025-02-28'),
271
+ lastCheckOut: new Date('2025-03-12'),
272
+ },
273
+ {
274
+ checkIn: new Date('2025-02-28'),
275
+ firstCheckOut: new Date('2025-03-01'),
276
+ lastCheckOut: new Date('2025-03-12'),
277
+ },
278
+ {
279
+ checkIn: new Date('2024-12-01'),
280
+ firstCheckOut: new Date('2024-12-02'),
281
+ lastCheckOut: new Date('2024-12-03'),
282
+ },
283
+ {
284
+ checkIn: new Date('2024-12-02'),
285
+ firstCheckOut: new Date('2024-12-03'),
286
+ lastCheckOut: new Date('2024-12-03'),
287
+ },
288
+ {
289
+ checkIn: new Date('2024-12-07'),
290
+ firstCheckOut: new Date('2024-12-08'),
291
+ lastCheckOut: new Date('2024-12-11'),
292
+ },
293
+ {
294
+ checkIn: new Date('2024-12-08'),
295
+ firstCheckOut: new Date('2024-12-09'),
296
+ lastCheckOut: new Date('2024-12-11'),
297
+ },
298
+ {
299
+ checkIn: new Date('2024-12-09'),
300
+ firstCheckOut: new Date('2024-12-10'),
301
+ lastCheckOut: new Date('2024-12-11'),
302
+ },
303
+ {
304
+ checkIn: new Date('2024-12-10'),
305
+ firstCheckOut: new Date('2024-12-11'),
306
+ lastCheckOut: new Date('2024-12-11'),
307
+ },
308
+ {
309
+ checkIn: new Date('2024-12-14'),
310
+ firstCheckOut: new Date('2024-12-15'),
311
+ lastCheckOut: new Date('2025-01-04'),
312
+ },
313
+ {
314
+ checkIn: new Date('2024-12-15'),
315
+ firstCheckOut: new Date('2024-12-16'),
316
+ lastCheckOut: new Date('2025-01-04'),
317
+ },
318
+ {
319
+ checkIn: new Date('2024-12-16'),
320
+ firstCheckOut: new Date('2024-12-17'),
321
+ lastCheckOut: new Date('2025-01-04'),
322
+ },
323
+ {
324
+ checkIn: new Date('2024-12-17'),
325
+ firstCheckOut: new Date('2024-12-18'),
326
+ lastCheckOut: new Date('2025-01-04'),
327
+ },
328
+ {
329
+ checkIn: new Date('2024-12-18'),
330
+ firstCheckOut: new Date('2024-12-19'),
331
+ lastCheckOut: new Date('2025-01-04'),
332
+ },
333
+ {
334
+ checkIn: new Date('2024-12-19'),
335
+ firstCheckOut: new Date('2024-12-20'),
336
+ lastCheckOut: new Date('2025-01-04'),
337
+ },
338
+ {
339
+ checkIn: new Date('2024-12-20'),
340
+ firstCheckOut: new Date('2024-12-21'),
341
+ lastCheckOut: new Date('2025-01-04'),
342
+ },
343
+ {
344
+ checkIn: new Date('2024-12-21'),
345
+ firstCheckOut: new Date('2024-12-22'),
346
+ lastCheckOut: new Date('2025-01-04'),
347
+ },
348
+ {
349
+ checkIn: new Date('2024-12-22'),
350
+ firstCheckOut: new Date('2024-12-23'),
351
+ lastCheckOut: new Date('2025-01-04'),
352
+ },
353
+ {
354
+ checkIn: new Date('2024-12-23'),
355
+ firstCheckOut: new Date('2024-12-24'),
356
+ lastCheckOut: new Date('2025-01-04'),
357
+ },
358
+ {
359
+ checkIn: new Date('2024-12-24'),
360
+ firstCheckOut: new Date('2024-12-25'),
361
+ lastCheckOut: new Date('2025-01-04'),
362
+ },
363
+ {
364
+ checkIn: new Date('2024-12-25'),
365
+ firstCheckOut: new Date('2024-12-26'),
366
+ lastCheckOut: new Date('2025-01-04'),
367
+ },
368
+ {
369
+ checkIn: new Date('2024-12-26'),
370
+ firstCheckOut: new Date('2024-12-27'),
371
+ lastCheckOut: new Date('2025-01-04'),
372
+ },
373
+ {
374
+ checkIn: new Date('2024-12-27'),
375
+ firstCheckOut: new Date('2024-12-28'),
376
+ lastCheckOut: new Date('2025-01-04'),
377
+ },
378
+ {
379
+ checkIn: new Date('2024-12-28'),
380
+ firstCheckOut: new Date('2024-12-29'),
381
+ lastCheckOut: new Date('2025-01-04'),
382
+ },
383
+ {
384
+ checkIn: new Date('2024-12-29'),
385
+ firstCheckOut: new Date('2024-12-30'),
386
+ lastCheckOut: new Date('2025-01-04'),
387
+ },
388
+ {
389
+ checkIn: new Date('2024-12-30'),
390
+ firstCheckOut: new Date('2024-12-31'),
391
+ lastCheckOut: new Date('2025-01-04'),
392
+ },
393
+ {
394
+ checkIn: new Date('2024-12-31'),
395
+ firstCheckOut: new Date('2025-01-01'),
396
+ lastCheckOut: new Date('2025-01-04'),
397
+ },
398
+ {
399
+ checkIn: new Date('2025-03-01'),
400
+ firstCheckOut: new Date('2025-03-02'),
401
+ lastCheckOut: new Date('2025-03-12'),
402
+ },
403
+ {
404
+ checkIn: new Date('2025-03-02'),
405
+ firstCheckOut: new Date('2025-03-03'),
406
+ lastCheckOut: new Date('2025-03-12'),
407
+ },
408
+ {
409
+ checkIn: new Date('2025-03-03'),
410
+ firstCheckOut: new Date('2025-03-04'),
411
+ lastCheckOut: new Date('2025-03-12'),
412
+ },
413
+ {
414
+ checkIn: new Date('2025-03-04'),
415
+ firstCheckOut: new Date('2025-03-05'),
416
+ lastCheckOut: new Date('2025-03-12'),
417
+ },
418
+ {
419
+ checkIn: new Date('2025-03-05'),
420
+ firstCheckOut: new Date('2025-03-06'),
421
+ lastCheckOut: new Date('2025-03-12'),
422
+ },
423
+ {
424
+ checkIn: new Date('2025-03-06'),
425
+ firstCheckOut: new Date('2025-03-07'),
426
+ lastCheckOut: new Date('2025-03-12'),
427
+ },
428
+ {
429
+ checkIn: new Date('2025-03-07'),
430
+ firstCheckOut: new Date('2025-03-08'),
431
+ lastCheckOut: new Date('2025-03-12'),
432
+ },
433
+ {
434
+ checkIn: new Date('2025-03-08'),
435
+ firstCheckOut: new Date('2025-03-09'),
436
+ lastCheckOut: new Date('2025-03-12'),
437
+ },
438
+ {
439
+ checkIn: new Date('2025-03-09'),
440
+ firstCheckOut: new Date('2025-03-10'),
441
+ lastCheckOut: new Date('2025-03-12'),
442
+ },
443
+ {
444
+ checkIn: new Date('2025-03-10'),
445
+ firstCheckOut: new Date('2025-03-11'),
446
+ lastCheckOut: new Date('2025-03-12'),
447
+ },
448
+ {
449
+ checkIn: new Date('2025-03-11'),
450
+ firstCheckOut: new Date('2025-03-12'),
451
+ lastCheckOut: new Date('2025-03-12'),
452
+ },
453
+ ],
18
454
  disabledDates: [
19
455
  {
20
- to: new Date('2025-04-30'),
21
- from: new Date('2025-03-01'),
456
+ to: new Date('2025-01-07'),
457
+ from: new Date('2025-01-04'),
458
+ },
459
+ {
460
+ to: new Date('2025-01-16'),
461
+ from: new Date('2025-01-14'),
462
+ },
463
+ {
464
+ to: new Date('2024-12-06'),
465
+ from: new Date('2024-12-03'),
466
+ },
467
+ {
468
+ to: new Date('2024-12-13'),
469
+ from: new Date('2024-12-11'),
470
+ },
471
+ {
472
+ to: new Date('2025-03-31'),
473
+ from: new Date('2025-03-12'),
22
474
  },
23
475
  ],
24
476
  },