ngxsmk-datepicker 2.2.0 → 2.2.3

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/MIGRATION.md DELETED
@@ -1,1702 +0,0 @@
1
- # Migration Guide
2
-
3
- This document provides migration instructions for upgrading between major versions of ngxsmk-datepicker.
4
-
5
- **Last updated:** February 25, 2026 · **Current stable:** v2.2.0
6
-
7
- ## Table of Contents
8
-
9
- - [v2.1.8 → v2.2.0](#v218---v219)
10
- - [v2.1.7 → v2.1.8](#v217---v218)
11
- - [v2.1.6 → v2.1.7](#v216---v217)
12
- - [v2.1.5 → v2.1.6](#v215---v216)
13
- - [v2.1.4 → v2.1.5](#v214---v215)
14
- - [v2.1.3 → v2.1.4](#v213---v214)
15
- - [v2.1.2 → v2.1.3](#v212---v213)
16
- - [v2.1.1 → v2.1.2](#v211---v212)
17
- - [v2.0.11 → v2.1.1](#v2011---v211)
18
- - [v2.0.6 → v2.0.7](#v206---v207)
19
- - [v2.0.5 → v2.0.6](#v205---v206)
20
- - [v2.0.4 → v2.0.5](#v204---v205)
21
- - [v2.0.3 → v2.0.4](#v203---v204)
22
- - [v2.0.2 → v2.0.3](#v202---v203)
23
- - [v2.0.1 → v2.0.2](#v201---v202)
24
- - [v2.0.0 → v2.0.1](#v200---v201)
25
- - [v1.9.30 → v2.0.0](#v1930---v200)
26
- - [v1.9.29 → v1.9.30](#v1929---v1930)
27
- - [v1.9.27 → v1.9.28](#v1927---v1928)
28
- - [v1.9.26 → v1.9.27](#v1926---v1927)
29
- - [v1.9.25 → v1.9.26](#v1925---v1926)
30
- - [v1.9.23 → v1.9.25](#v1923---v1925)
31
- - [v1.9.22 → v1.9.23](#v1922---v1923)
32
- - [v1.9.21 → v1.9.22](#v1921---v1922)
33
- - [v1.9.20 → v1.9.21](#v1920---v1921)
34
- - [v1.9.19 → v1.9.20](#v1919---v1920)
35
- - [v1.9.18 → v1.9.19](#v1918---v1919)
36
- - [v1.9.17 → v1.9.18](#v1917---v1918)
37
- - [v1.9.16 → v1.9.17](#v1916---v1917)
38
- - [v1.9.15 → v1.9.16](#v1915---v1916)
39
- - [v1.9.14 → v1.9.15](#v1914---v1915)
40
- - [v1.9.13 → v1.9.14](#v1913---v1914)
41
- - [v1.9.12 → v1.9.13](#v1912---v1913)
42
- - [v1.9.11 → v1.9.12](#v1911---v1912)
43
- - [v1.9.10 → v1.9.11](#v1910---v1911)
44
- - [v1.9.9 → v1.9.10](#v199---v1910)
45
- - [v1.9.8 → v1.9.9](#v198---v199)
46
- - [v1.9.7 → v1.9.8](#v197---v198)
47
- - [v1.9.6 → v1.9.7](#v196---v197)
48
- - [v1.9.5 → v1.9.6](#v195---v196)
49
- - [v1.9.4 → v1.9.5](#v194---v195)
50
- - [v1.9.3 → v1.9.4](#v193---v194)
51
- - [v1.9.2 → v1.9.3](#v192---v193)
52
- - [v1.9.1 → v1.9.2](#v191---v192)
53
- - [v1.9.0 → v1.9.1](#v190---v191)
54
- - [v1.8.0 → v1.9.0](#v180---v190)
55
- - [v1.9.0 → v2.0.0](#v190---v200) (Future)
56
- - [v1.7.0 → v1.8.0](#v170---v180)
57
-
58
- ## v2.1.8 → v2.2.0
59
-
60
- ### Changes
61
-
62
- - **Header Select Synchronization**: Migrated header components to `ViewEncapsulation.None` and consolidated styles into `_header.scss`.
63
- - **Improved Dropdown Layout**: Professional `space-between` layout for Month/Year selectors.
64
- - **Enhanced Visibility**: High-contrast text for non-selected dropdown options.
65
- - **Web Component Support**: New capability to compile/export as a Universal Custom Web Component for React, Vue, & Vanilla JS.
66
- - **Performance**: Reduced calendar opening timers for faster feedback (150ms mobile / 60ms desktop).
67
-
68
- ### Migration Steps
69
-
70
- No migration steps required.
71
-
72
- ```bash
73
- npm install ngxsmk-datepicker@2.2.0
74
- ```
75
-
76
- ## v2.1.7 → v2.1.8
77
-
78
- ### Changes
79
-
80
- - **Fixed**: **appendToBody** popover positioning (Issue #206).
81
- - **Fixed**: Datepicker in modal positioning fixes.
82
- - **Changed**: Reduced loading/opening delays and CSS cleanup.
83
-
84
- ### Migration Steps
85
-
86
- No migration steps required.
87
-
88
- ```bash
89
- npm install ngxsmk-datepicker@2.1.8
90
- ```
91
-
92
- ## v2.1.6 → v2.1.7
93
-
94
- ### Changes
95
-
96
- - **Version Update**: Updated to version 2.1.7.
97
- - **Fixed**: Resolved `No provider for DatePipe` runtime error. The library is now fully self-contained regarding `DatePipe` usage.
98
- - No breaking changes.
99
-
100
- ### Migration Steps
101
-
102
- No migration steps required. If you previously added `DatePipe` to your `app.config.ts` or `AppModule` providers solely for this library, you can now safely remove it.
103
-
104
- ```bash
105
- npm install ngxsmk-datepicker@2.1.7
106
- ```
107
-
108
- ## v2.1.5 → v2.1.6
109
-
110
- ### Changes
111
-
112
- - **Version Update**: Updated to version 2.1.6.
113
- - No breaking changes.
114
-
115
- ### Migration Steps
116
-
117
- No migration steps required.
118
-
119
- ```bash
120
- npm install ngxsmk-datepicker@2.1.6
121
- ```
122
-
123
- ## v2.1.4 → v2.1.5
124
-
125
- ### Changes
126
-
127
- - **Version Update**: Updated to version 2.1.5.
128
- - **New**: User-facing validation messages (i18n) for invalid date, date before min, date after max; calendar loading state (visual + a11y); installation options doc and demo page updates; demo light/dark theme fix; optional issue-reproduction app. Service refactors (calendar generation, parsing) are internal.
129
- - No breaking changes.
130
-
131
- ### Migration Steps
132
-
133
- No migration steps required.
134
-
135
- ```bash
136
- npm install ngxsmk-datepicker@2.1.5
137
- ```
138
-
139
- ## v2.1.3 → v2.1.4
140
-
141
- ### Changes
142
-
143
- - **Version Update**: Updated to version 2.1.4.
144
- - **Improved Calendar Grid**: Calendar now always generates exactly 42 days (6 full weeks), providing layout stability during month navigation.
145
- - **Enhanced Playground**: New options for `minDate`, `maxDate`, and `weekStart` constraints.
146
- - No breaking changes.
147
-
148
- ### Migration Steps
149
-
150
- No migration steps required.
151
-
152
- ```bash
153
- npm install ngxsmk-datepicker@2.1.4
154
- ```
155
-
156
- ## v2.1.2 → v2.1.3
157
-
158
- ### Changes
159
-
160
- - **Version Update**: Updated to version 2.1.3.
161
- - **Bug Fix**: Fixed inline datepicker width issue where it was constrained by container styles in some contexts. The inline mode now correctly fit its content.
162
- - No breaking changes.
163
-
164
- ### Migration Steps
165
-
166
- No migration steps required.
167
-
168
- ```bash
169
- npm install ngxsmk-datepicker@2.1.3
170
- ```
171
-
172
-
173
- ## v2.1.1 → v2.1.2
174
-
175
- ### Changes
176
-
177
- - **Version Update**: Updated to version 2.1.2.
178
- - **Circular Dependency Fix**: Resolved `RuntimeError: NG0200` when using forms by removing `NG_VALUE_ACCESSOR` from providers. This might require verifying your form integration if you were relying on side-effects of the previous implementation.
179
- - **UI Refresh**: Implemented a "border detox" and refined aesthetics.
180
- - **Removed Feature**: The range duration header (which displayed "X Days" during range selection) has been removed.
181
- - **Mobile Stabilization**: Critical fixes for mobile browsers.
182
-
183
- No migration steps required.
184
-
185
- ```bash
186
- npm install ngxsmk-datepicker@latest
187
- ```
188
-
189
-
190
- ## v2.0.11 → v2.1.1
191
-
192
- ### ⚠️ CRITICAL NOTICE
193
-
194
- **Versions 2.0.10 and 2.0.11 are broken and should NOT be used.**
195
-
196
- These versions have critical package configuration issues that prevent proper TypeScript module resolution. If you have installed either of these versions, please upgrade to v2.1.1 immediately.
197
-
198
- ### Changes
199
-
200
- - **Package Fixes**: Corrected TypeScript declaration paths and package configuration
201
- - Fixed `types` and `typings` fields to point to the correct location: `types/ngxsmk-datepicker.d.ts`
202
- - Simplified exports configuration to match stable v2.0.9 format
203
- - Removed disallowed `esm2022` property from package.json
204
- - **No Breaking Changes**: This is a minor version update with package configuration improvements
205
- - **Recommended Update**: All v2.0.x users should update to v2.1.1 for proper TypeScript support
206
- - **Skip 2.0.10 & 2.0.11**: These versions have been unpublished from npm due to broken package configuration
207
-
208
- ### Migration Steps
209
-
210
- Update your package.json to use the new version:
211
-
212
- ```bash
213
- npm install ngxsmk-datepicker@2.1.1
214
- ```
215
-
216
- **No code changes required.** This update only fixes package configuration issues that were preventing proper TypeScript declaration file resolution.
217
-
218
- ### What's Fixed
219
-
220
- If you were experiencing the following error:
221
-
222
- ```
223
- Could not find a declaration file for module 'ngxsmk-datepicker'
224
- ```
225
-
226
- This is now resolved in v2.1.1. The package now correctly points to its TypeScript declaration files.
227
-
228
- ## v2.0.7 → v2.0.8
229
-
230
- ### Changes
231
-
232
- - **Version Update**: Updated to version 2.0.8
233
- - **Ionic Integration**: Added automatic CSS variable support for seamless theming in Ionic apps
234
- - **Optimized Change Detection**: Switched to Signal-based updates for better performance
235
- - **Mobile UX Fixes**: Fixed page jumping on date selection and improved dropdown scrolling
236
- - No breaking changes.
237
-
238
- ### Migration Steps
239
-
240
- No migration steps required. This is a patch version update:
241
-
242
- ```bash
243
- npm install ngxsmk-datepicker@2.0.8
244
- ```
245
-
246
- ## v2.0.6 → v2.0.7
247
-
248
- ### Changes
249
-
250
- - **Version Update**: Updated to version 2.0.7
251
- - **Stable Release**: Version 2.2.0 is the current stable version
252
- - No breaking changes.
253
-
254
- ### Migration Steps
255
-
256
- No migration steps required. This is a patch version update:
257
-
258
- ```bash
259
- npm install ngxsmk-datepicker@2.0.7
260
- ```
261
-
262
- ## v2.0.5 → v2.0.6
263
-
264
- ### Changes
265
-
266
- - **Enhanced Range Picker Reselection**: Improved comprehensive range reselection behavior
267
- - Clicking the start date when a complete range is selected now clears only the end date
268
- - Clicking the end date when a complete range is selected now clears the start date and sets the end date as the new start date
269
- - **NEW**: Clicking any date within the selected range now clears the end date and sets the clicked date as the new start date
270
- - Allows users to easily redefine date ranges from any point (start, end, or within the range)
271
- - **Code Cleanup**: Removed unnecessary inline comments from range selection logic for cleaner, more maintainable code
272
- - No breaking changes.
273
-
274
- ### Migration Steps
275
-
276
- No migration steps required. This is a patch version update:
277
-
278
- ```bash
279
- npm install ngxsmk-datepicker@2.0.6
280
- ```
281
-
282
- ## v2.0.4 -> v2.0.5
283
-
284
- ### Changes
285
-
286
- - **Documentation**: Added "Form Validation" section to clarify `readonly` input behavior and `allowTyping` workaround.
287
- - General updates and improvements.
288
- - No breaking changes.
289
-
290
- ## v2.0.3 → v2.0.4
291
-
292
- ### Changes
293
-
294
- - Bug fix: Fixed `touched` state sync for Signal Forms validation.
295
- - No breaking changes.
296
-
297
- ## v2.0.2 → v2.0.3
298
-
299
- ### Changes
300
-
301
- - Bug fixes: #136, #112, #84, #71 verified.
302
- - Code cleanup in `field-sync.service.ts`.
303
- - No breaking changes.
304
-
305
- ## v2.0.1 → v2.0.2
306
-
307
- ### Changes
308
-
309
- - Documentation updates to reflect new version
310
-
311
- ## v2.0.0 → v2.0.1
312
-
313
- ### Changes
314
-
315
- - Bug fixes and improvements
316
-
317
- ## v1.9.30 → v2.0.0
318
-
319
- ### Overview
320
-
321
- v2.0.0 is a major version update representing significant architectural improvements, enhanced features, and modernization of the codebase. While maintaining backward compatibility for most features, some breaking changes are necessary for improved performance, type safety, and Angular alignment.
322
-
323
- ### Breaking Changes
324
-
325
- #### 1. Angular Version Requirement
326
-
327
- **Change**: Minimum Angular version updated to 17.0.0+
328
-
329
- **Reason**: To leverage modern Angular features (signals, standalone components, built-in control flow)
330
-
331
- **Migration**:
332
-
333
- ```bash
334
- # Update Angular to v17+
335
- ng update @angular/core@17 @angular/cli@17
336
-
337
- # Then update ngxsmk-datepicker
338
- npm install ngxsmk-datepicker@2.0.0
339
- ```
340
-
341
- #### 2. Signal Forms Integration
342
-
343
- **Change**: Enhanced Signal Forms API with stricter typing
344
-
345
- **Before** (v1.x):
346
-
347
- ```typescript
348
- // Signal form field with loose typing
349
- [field] = "mySignalFormField";
350
- ```
351
-
352
- **After** (v2.0):
353
-
354
- ```typescript
355
- // Import SignalFormFieldConfig for type safety
356
- import { SignalFormFieldConfig } from "ngxsmk-datepicker";
357
-
358
- // Signal form field with strict typing
359
- [field] = "mySignalFormField"; // Now with proper type inference
360
- ```
361
-
362
- **Migration**: No code changes required, but TypeScript will now catch type errors earlier.
363
-
364
- #### 3. Timezone Utilities API
365
-
366
- **Change**: Improved timezone utility function signatures for type safety
367
-
368
- **Before** (v1.x):
369
-
370
- ```typescript
371
- // Loose parameter types
372
- formatDateWithTimezone(date, locale, options, timezone);
373
- ```
374
-
375
- **After** (v2.0):
376
-
377
- ```typescript
378
- // Strict parameter types with proper interfaces
379
- formatDateWithTimezone(
380
- date: Date,
381
- locale: string,
382
- options: Intl.DateTimeFormatOptions,
383
- timezone?: string
384
- ): string;
385
- ```
386
-
387
- **Migration**: Ensure you're passing correctly typed parameters to timezone utilities.
388
-
389
- #### 4. Deprecated Properties Removed
390
-
391
- **Change**: Removed properties deprecated in v1.9.x
392
-
393
- **Removed**:
394
-
395
- - `numberOfMonths` (use `calendarCount` instead - deprecated since v1.9.12)
396
-
397
- **Migration**:
398
-
399
- ```typescript
400
- // Before (v1.x)
401
- <ngxsmk-datepicker [numberOfMonths]="2"></ngxsmk-datepicker>
402
-
403
- // After (v2.0)
404
- <ngxsmk-datepicker [calendarCount]="2"></ngxsmk-datepicker>
405
- ```
406
-
407
- #### 5. Service Extraction
408
-
409
- **Change**: Internal architecture refactored - services extracted from main component
410
-
411
- **Impact**: If you were extending or monkey-patching internal component methods, this may break.
412
-
413
- **Affected Internal Services**:
414
-
415
- - `CalendarGenerationService` - Calendar generation logic
416
- - `DatepickerParsingService` - Date parsing and formatting
417
- - `TouchGestureHandlerService` - Touch gesture handling
418
- - `PopoverPositioningService` - Popover positioning
419
-
420
- **Migration**: Use public APIs instead of internal methods. If you need access to these services, inject them:
421
-
422
- ```typescript
423
- import { CalendarGenerationService } from 'ngxsmk-datepicker';
424
-
425
- constructor(private calendarService: CalendarGenerationService) {}
426
- ```
427
-
428
- ### New Features
429
-
430
- #### 1. Enhanced Time Selection
431
-
432
- ```typescript
433
- // Time range mode
434
- <ngxsmk-datepicker
435
- [timeRangeMode]="true"
436
- [showTime]="true"
437
- ></ngxsmk-datepicker>
438
-
439
- // Seconds support (already available, now documented)
440
- <ngxsmk-datepicker
441
- [showSeconds]="true"
442
- [secondInterval]="5"
443
- ></ngxsmk-datepicker>
444
-
445
- // Step configuration
446
- <ngxsmk-datepicker
447
- [minuteInterval]="15"
448
- [secondInterval]="30"
449
- ></ngxsmk-datepicker>
450
- ```
451
-
452
- #### 2. Internationalization Improvements
453
-
454
- ```typescript
455
- // Custom date format patterns
456
- import { CustomDateFormatService } from "ngxsmk-datepicker";
457
-
458
- customFormat.format(date, "YYYY-MM-DD HH:mm:ss", "en-US");
459
-
460
- // Locale-aware number formatting
461
- import { formatLocaleNumber } from "ngxsmk-datepicker/utils";
462
-
463
- formatLocaleNumber(42, "de-DE"); // "42"
464
- ```
465
-
466
- #### 3. Animation API
467
-
468
- ```typescript
469
- // Configure animations
470
- <ngxsmk-datepicker
471
- [animationConfig]="{
472
- duration: 200,
473
- easing: 'ease-in-out',
474
- enabled: true
475
- }"
476
- ></ngxsmk-datepicker>
477
-
478
- // Respects prefers-reduced-motion automatically
479
- ```
480
-
481
- #### 4. Multi-Calendar Sync Scrolling
482
-
483
- ```typescript
484
- // Synchronized scrolling for multi-calendar layouts
485
- <ngxsmk-datepicker
486
- [calendarCount]="2"
487
- [syncScroll]="true"
488
- [monthGap]="1"
489
- ></ngxsmk-datepicker>
490
- ```
491
-
492
- ### Performance Improvements
493
-
494
- #### 1. Virtual Scrolling
495
-
496
- Year and decade views now use virtual scrolling for better performance with large date ranges:
497
-
498
- ```typescript
499
- // Automatically enabled for year/decade views
500
- // Handles 100+ years efficiently
501
- <ngxsmk-datepicker [currentView]="'year'"></ngxsmk-datepicker>
502
- ```
503
-
504
- #### 2. Signal-Based Reactivity
505
-
506
- Change detection is now automatic and more efficient:
507
-
508
- ```typescript
509
- // Automatically optimized - no manual change detection needed
510
- component.selectedDate.set(new Date());
511
- ```
512
-
513
- #### 3. Lazy Loading
514
-
515
- Multi-month calendars are now lazily rendered:
516
-
517
- ```typescript
518
- // Only visible calendars + buffer are rendered
519
- <ngxsmk-datepicker [calendarCount]="12"></ngxsmk-datepicker>
520
- ```
521
-
522
- ### Testing Infrastructure
523
-
524
- New testing utilities are available:
525
-
526
- ```typescript
527
- // Accessibility testing
528
- import { runAccessibilityScan } from "ngxsmk-datepicker/testing";
529
-
530
- // Performance benchmarking
531
- import { measureSync, benchmark } from "ngxsmk-datepicker/testing";
532
-
533
- // Visual regression testing
534
- import { captureElementScreenshot, compareImageData } from "ngxsmk-datepicker/testing";
535
- ```
536
-
537
- ### Documentation Updates
538
-
539
- - ✅ Complete API reference with JSDoc
540
- - ✅ Enhanced accessibility guide
541
- - ✅ Performance testing guide
542
- - ✅ Visual regression testing guide
543
- - ✅ Improvement report
544
-
545
- ### Migration Steps
546
-
547
- 1. **Update Angular** (if needed):
548
-
549
- ```bash
550
- ng update @angular/core@17 @angular/cli@17
551
- ```
552
-
553
- 2. **Update ngxsmk-datepicker**:
554
-
555
- ```bash
556
- npm install ngxsmk-datepicker@2.0.0
557
- ```
558
-
559
- 3. **Replace deprecated properties**:
560
-
561
- ```typescript
562
- // Replace numberOfMonths with calendarCount
563
- [numberOfMonths]="2" → [calendarCount]="2"
564
- ```
565
-
566
- 4. **Update imports** (if using internal services):
567
-
568
- ```typescript
569
- // Use public APIs instead of internal methods
570
- import { CalendarGenerationService } from "ngxsmk-datepicker";
571
- ```
572
-
573
- 5. **Test thoroughly**:
574
- - Test all date selection modes
575
- - Test time selection
576
- - Test keyboard navigation
577
- - Test mobile interactions
578
- - Run accessibility tests
579
-
580
- 6. **Verify bundle size**:
581
- ```bash
582
- ng build --prod
583
- # Check bundle analyzer if needed
584
- ```
585
-
586
- ### Rollback Instructions
587
-
588
- If you encounter issues, you can rollback to v1.9.30:
589
-
590
- ```bash
591
- npm install ngxsmk-datepicker@1.9.30
592
- ```
593
-
594
- ### Support
595
-
596
- For migration issues or questions:
597
-
598
- - Check the [README](README.md) for updated examples
599
- - Review [IMPROVEMENT_REPORT.md](IMPROVEMENT_REPORT.md) for architectural changes
600
- - Open an issue on GitHub with migration questions
601
-
602
- ---
603
-
604
- ## v1.9.29 → v1.9.30
605
-
606
- ### Installation
607
-
608
- Update to the latest version:
609
-
610
- ```bash
611
- npm install ngxsmk-datepicker@2.0.0
612
- ```
613
-
614
- ### Changes
615
-
616
- - **Signal Form Resolution**: Improved the way signal-based form fields are resolved. The datepicker now correctly handles signals that have field properties attached directly to the signal function.
617
- - **Improved Validation**: Enhanced detection of `required` state from Signal Forms schema.
618
- - **Public API**: Exported `SignalFormFieldConfig` for better type safety.
619
-
620
- ### Breaking Changes
621
-
622
- None in v2.0.0.
623
-
624
- ### v1.9.30
625
-
626
- None in v1.9.30.
627
-
628
- ### Migration Steps
629
-
630
- If you are using custom types for Signal Form fields, you can now use the officially exported `SignalFormFieldConfig` interface.
631
-
632
- ## v1.9.27 → v1.9.28
633
-
634
- ### Installation
635
-
636
- Update to the latest version:
637
-
638
- ```bash
639
- npm install ngxsmk-datepicker@1.9.28
640
- ```
641
-
642
- ### Changes
643
-
644
- - **Input Attributes**: New `inputId`, `name`, and `autocomplete` inputs are available.
645
- - **Improved Validation**: The `required` attribute is now correctly reflected on the internal input element when set via form schema.
646
-
647
- ### Breaking Changes
648
-
649
- None in v1.9.28.
650
-
651
- ### Migration Steps
652
-
653
- No code changes required. The new features are additive.
654
-
655
- ## v1.9.26 → v1.9.27
656
-
657
- ### Installation
658
-
659
- Update to the latest version:
660
-
661
- ```bash
662
- npm install ngxsmk-datepicker@1.9.27
663
- ```
664
-
665
- ### Changes
666
-
667
- - **Modern Control Flow**: Components migrated to Angular's built-in `@if` and `@for` blocks.
668
- - **Improved Resolution**: Resolved static analysis and module resolution issues in monorepos.
669
-
670
- ### Breaking Changes
671
-
672
- None in v1.9.27.
673
-
674
- ### Migration Steps
675
-
676
- No code changes required. The changes are focused on internal library architecture and build compatibility.
677
-
678
- ## v1.9.25 → v1.9.26
679
-
680
- > ⚠️ **Warning**: Version `1.9.26` has broken styles. It is highly recommended to skip this version and upgrade directly to `1.9.27`.
681
-
682
- ### Installation
683
-
684
- Update to the latest version:
685
-
686
- ```bash
687
- npm install ngxsmk-datepicker@1.9.26
688
- ```
689
-
690
- ### Changes
691
-
692
- - **Core Architecture**: Major internal refactoring to improve maintainability and performance.
693
- - **Ionic Integration**: Fixed localized style exporting issues.
694
-
695
- ### Breaking Changes
696
-
697
- None in v1.9.26.
698
-
699
- ### Migration Steps
700
-
701
- No code changes required. The refactoring is internal and maintains full backward compatibility.
702
-
703
- ## v1.9.23 → v1.9.25
704
-
705
- ### Installation
706
-
707
- ```bash
708
- npm install ngxsmk-datepicker@1.9.25
709
- ```
710
-
711
- ### Changes
712
-
713
- - **Strict Mode**: Improved support for strict template type checking in IDEs.
714
- - **NPM Package**: Fixed missing README in package distribution.
715
-
716
- ### Breaking Changes
717
-
718
- None in v1.9.25.
719
-
720
- ## v1.9.22 → v1.9.23
721
-
722
- ### Installation
723
-
724
- ```bash
725
- npm install ngxsmk-datepicker@1.9.23
726
- ```
727
-
728
- ### Changes
729
-
730
- - **Signal Forms**: Fixed dirty state tracking for `[field]` binding.
731
- - **CSS Variables**: Improved theming specificity for global variables.
732
-
733
- ### Breaking Changes
734
-
735
- None in v1.9.23.
736
-
737
- ## v1.9.21 → v1.9.22
738
-
739
- ### Installation
740
-
741
- Update to the latest version:
742
-
743
- ```bash
744
- npm install ngxsmk-datepicker@1.9.22
745
- ```
746
-
747
- ### Changes
748
-
749
- - **Version Update**: Updated to version 1.9.22
750
- - **Stable Release**: Version 1.9.22 is the current stable version
751
-
752
- ### Bug Fixes
753
-
754
- - **Form Control Value Initialization**: Fixed issue where datepicker was not properly updating the displayed month when initialized with form control values
755
- - The datepicker now correctly displays the month from form control values instead of defaulting to the current month
756
- - Added proper signal updates and change detection in `writeValue()` method
757
- - This fix ensures that when using Reactive Forms with initial date values, the calendar opens to the correct month
758
- - Example: If a form control has a value of January 2026, the calendar will now open showing January instead of the current month
759
-
760
- - **Locale Week Start Detection**: Fixed `getFirstDayOfWeek()` function to properly return 1 for en-GB locale and other European locales
761
- - Added fallback logic for locales where `Intl.Locale.weekInfo` is not available (older browsers/environments)
762
- - Now correctly returns Monday (1) for en-GB, en-AU, en-NZ, and most European locales
763
- - Maintains backward compatibility with en-US and other locales that use Sunday (0) as first day
764
- - All calendar utils tests now passing
765
-
766
- ### Breaking Changes
767
-
768
- None in v1.9.22.
769
-
770
- ### Deprecations
771
-
772
- None in v1.9.22.
773
-
774
- ## v1.9.20 → v1.9.21
775
-
776
- ### Installation
777
-
778
- Update to the latest version:
779
-
780
- ```bash
781
- npm install ngxsmk-datepicker@latest
782
- ```
783
-
784
- ### New Features
785
-
786
- #### Mobile-Specific Features
787
-
788
- Version 1.9.21 introduces comprehensive mobile optimization:
789
-
790
- ```typescript
791
- // Enable native picker on mobile devices (automatic detection)
792
- <ngxsmk-datepicker
793
- [useNativePicker]="true"
794
- [autoDetectMobile]="true"
795
- [mobileModalStyle]="'bottom-sheet'"
796
- [enableHapticFeedback]="true">
797
- </ngxsmk-datepicker>
798
- ```
799
-
800
- **New Inputs:**
801
-
802
- - `useNativePicker`: Enable native date picker on mobile devices
803
- - `autoDetectMobile`: Automatically detect mobile devices (default: `true`)
804
- - `mobileModalStyle`: Choose modal style (`'bottom-sheet'`, `'center'`, `'fullscreen'`)
805
- - `enableHapticFeedback`: Enable haptic feedback for interactions
806
-
807
- #### Advanced Selection Modes
808
-
809
- New selection modes extend the existing `mode` input:
810
-
811
- ```typescript
812
- // Week selection
813
- <ngxsmk-datepicker mode="week"></ngxsmk-datepicker>
814
-
815
- // Month selection
816
- <ngxsmk-datepicker mode="month"></ngxsmk-datepicker>
817
-
818
- // Quarter selection
819
- <ngxsmk-datepicker mode="quarter"></ngxsmk-datepicker>
820
-
821
- // Year selection
822
- <ngxsmk-datepicker mode="year"></ngxsmk-datepicker>
823
- ```
824
-
825
- #### Enhanced Time Selection
826
-
827
- Seconds selection is now available:
828
-
829
- ```typescript
830
- <ngxsmk-datepicker
831
- [showTime]="true"
832
- [showSeconds]="true"
833
- [secondInterval]="1">
834
- </ngxsmk-datepicker>
835
- ```
836
-
837
- **New Inputs:**
838
-
839
- - `showSeconds`: Show seconds selector in time picker
840
- - `secondInterval`: Interval for seconds selection (default: `1`)
841
-
842
- ### Migration Steps
843
-
844
- No migration steps required. This is a patch version with new features that are opt-in:
845
-
846
- 1. **Existing code continues to work**: All existing implementations remain unchanged
847
- 2. **New features are opt-in**: Mobile features and new selection modes require explicit configuration
848
- 3. **Backward compatible**: All changes maintain full backward compatibility
849
-
850
- ### Breaking Changes
851
-
852
- None. This version is fully backward compatible.
853
-
854
- ### Compatibility
855
-
856
- - Angular 17-22
857
- - All existing features continue to work
858
- - New features are additive only
859
-
860
- ## v1.9.15 → v1.9.16
861
-
862
- ### Fixed
863
-
864
- - **Range Mode Previous Month Selection**: Fixed issue where users could not select dates from previous months in range mode when starting with `{ start: null, end: null }`
865
- - Added memo cache invalidation before calendar generation when clicking dates from previous/next months in range mode
866
- - Fixed issue where clicking dates from previous months would navigate but memoized functions would use stale month/year values
867
- - Now properly invalidates memo cache in single, range, and multiple modes when navigating to different months via date clicks
868
- - Users can now select dates from previous months in range mode without issues, allowing proper range selection across month boundaries
869
-
870
- ### Changed
871
-
872
- - **Version Update**: Updated to version 1.9.16
873
- - **Stable Release**: Version 1.9.16 is the current stable version
874
-
875
- ### Migration Steps
876
-
877
- No migration steps required. This is a patch version with bug fixes only. Simply update your package version:
878
-
879
- ```bash
880
- npm install ngxsmk-datepicker@1.9.16
881
- ```
882
-
883
- ### Breaking Changes
884
-
885
- None in v1.9.16.
886
-
887
- ### Deprecations
888
-
889
- None in v1.9.16.
890
-
891
- ### Notes
892
-
893
- - This version maintains full backward compatibility with v1.9.15. All existing code will continue to work without modifications.
894
- - The fix ensures that range mode date pickers work correctly when users click on dates from previous months, especially when starting with null initial values.
895
-
896
- ## v1.9.20 → v1.9.21
897
-
898
- ### Changed
899
-
900
- - **Version Update**: Updated to version 1.9.21
901
- - **Stable Release**: Version 1.9.21 is the current stable version
902
-
903
- ### Installation
904
-
905
- ```bash
906
- npm install ngxsmk-datepicker@1.9.21
907
- ```
908
-
909
- ### Breaking Changes
910
-
911
- None in v1.9.21.
912
-
913
- ### Deprecations
914
-
915
- None in v1.9.21.
916
-
917
- ### Migration Steps
918
-
919
- - This version maintains full backward compatibility with v1.9.20. All existing code will continue to work without modifications.
920
- - No code changes required.
921
-
922
- ## v1.9.19 → v1.9.20
923
-
924
- ### Fixed
925
-
926
- - **Test Environment Compatibility (Issue #71)**: Fixed `TypeError: window.matchMedia is not a function` error in test environments (jsdom/Vitest)
927
- - Added error handling for `window.matchMedia` in `applyAnimationConfig()` method
928
- - Component now gracefully handles missing `matchMedia` API in test environments
929
- - Prevents test failures when running with Vitest and jsdom
930
- - Added comprehensive test coverage for `matchMedia` compatibility scenarios
931
-
932
- ### Changed
933
-
934
- - **Version Update**: Updated to version 1.9.20
935
- - **Stable Release**: Version 1.9.20 is the current stable version
936
-
937
- ### Installation
938
-
939
- ```bash
940
- npm install ngxsmk-datepicker@1.9.20
941
- ```
942
-
943
- ### Breaking Changes
944
-
945
- None in v1.9.20.
946
-
947
- ### Deprecations
948
-
949
- None in v1.9.20.
950
-
951
- ### Migration Steps
952
-
953
- - This version maintains full backward compatibility with v1.9.19. All existing code will continue to work without modifications.
954
- - No code changes required.
955
- - Fixes test compatibility issues with Vitest and jsdom environments.
956
-
957
- ## v1.9.18 → v1.9.19
958
-
959
- ### Added
960
-
961
- - **Comprehensive Responsive Layout Redesign**: Complete redesign of demo project layout for all screen sizes
962
- - Redesigned navbar for all breakpoints (320px-374px, 375px-479px, 480px-599px, 600px-767px, 768px-1023px, 1024px+)
963
- - Enhanced sidebar navigation with mobile drawer, tablet collapsible, and desktop fixed layouts
964
- - Responsive hero section with adaptive typography and button layouts
965
- - Feature grid responsive design (1 column → 2 columns → 3 columns → 4 columns)
966
- - Optimized content sections with responsive padding, typography, and spacing
967
-
968
- ### Changed
969
-
970
- - **Version Update**: Updated to version 1.9.19
971
- - **Stable Release**: Version 1.9.19 is the current stable version
972
- - **Meta Tag Update**: Replaced deprecated `apple-mobile-web-app-capable` with `mobile-web-app-capable`
973
- - **Code Cleanup**: Removed unnecessary comments from SCSS files for cleaner codebase
974
-
975
- ### Installation
976
-
977
- ```bash
978
- npm install ngxsmk-datepicker@1.9.19
979
- ```
980
-
981
- ### Breaking Changes
982
-
983
- None in v1.9.19.
984
-
985
- ### Deprecations
986
-
987
- None in v1.9.19.
988
-
989
- ### Migration Steps
990
-
991
- - This version maintains full backward compatibility with v1.9.18. All existing code will continue to work without modifications.
992
- - No code changes required.
993
- - Demo project layout improvements are automatic and require no code changes.
994
-
995
- ## v1.9.17 → v1.9.18
996
-
997
- ### Fixed
998
-
999
- - **Mobile Touch Event Handling**: Improved touch listener attachment when calendar opens on mobile devices
1000
- - Touch listeners now properly attach when calendar first opens, eliminating the need to navigate months first
1001
- - Added retry mechanism with multiple attempts to ensure listeners are attached even on slower mobile devices
1002
- - Improved timing with double `requestAnimationFrame` calls and multiple retry strategies
1003
-
1004
- ### Changed
1005
-
1006
- - **Version Update**: Updated to version 1.9.18
1007
- - **Stable Release**: Version 1.9.18 is the current stable version
1008
-
1009
- ### Installation
1010
-
1011
- ```bash
1012
- npm install ngxsmk-datepicker@1.9.18
1013
- ```
1014
-
1015
- ### Breaking Changes
1016
-
1017
- None in v1.9.18.
1018
-
1019
- ### Deprecations
1020
-
1021
- None in v1.9.18.
1022
-
1023
- ### Migration Steps
1024
-
1025
- - This version maintains full backward compatibility with v1.9.17. All existing code will continue to work without modifications.
1026
- - No code changes required.
1027
-
1028
- ## v1.9.16 → v1.9.17
1029
-
1030
- ### Changed
1031
-
1032
- - **Version Update**: Updated to version 1.9.17
1033
- - **Stable Release**: Version 1.9.17 is the current stable version
1034
-
1035
- ### Migration Steps
1036
-
1037
- No migration steps required. This is a patch version update. Simply update your package version:
1038
-
1039
- ```bash
1040
- npm install ngxsmk-datepicker@1.9.17
1041
- ```
1042
-
1043
- ### Breaking Changes
1044
-
1045
- None in v1.9.17.
1046
-
1047
- ### Deprecations
1048
-
1049
- None in v1.9.17.
1050
-
1051
- ### Notes
1052
-
1053
- - This version maintains full backward compatibility with v1.9.16. All existing code will continue to work without modifications.
1054
- - This is a patch version update with no code changes required.
1055
-
1056
- ## v1.9.14 → v1.9.15
1057
-
1058
- ### Fixed
1059
-
1060
- - **Moment Object Binding with ngModel**: Fixed issue where Moment.js objects passed via `[(ngModel)]` were not binding correctly with the datepicker
1061
- - Updated `writeValue()` method to normalize Moment.js objects before passing to `initializeValue()`
1062
- - Ensures Moment.js objects (including those with `utcOffset()` applied) are properly converted to Date objects when binding with template-driven forms
1063
- - Now correctly handles `moment(response.Date).utcOffset(timezone)` when setting via ngModel
1064
- - **Date Clicks After Month Navigation**: Fixed issue where dates became unclickable after navigating backward or forward months
1065
- - Updated `isDateDisabledMemo` getter to properly invalidate cached memoized function when month/year changes
1066
- - Added month/year change detection to ensure disabled date cache is refreshed after navigation
1067
- - Dates in previous/next months are now properly clickable without needing to close and reopen the datepicker
1068
-
1069
- ### Changed
1070
-
1071
- - **Version Update**: Updated to version 1.9.15
1072
- - **Stable Release**: Version 1.9.15 is the current stable version
1073
-
1074
- ### Migration Steps
1075
-
1076
- No migration steps required. This is a patch version with bug fixes only. Simply update your package version:
1077
-
1078
- ```bash
1079
- npm install ngxsmk-datepicker@1.9.15
1080
- ```
1081
-
1082
- All fixes are backward compatible and require no code changes. This version is compatible with Angular 17 and up versions.
1083
-
1084
- ## v1.9.13 → v1.9.14
1085
-
1086
- ### Fixed
1087
-
1088
- - **Date Picker Selection Issue**: Fixed issue where date picker was not working properly when selecting dates, especially in range mode
1089
- - Added proper change detection scheduling when setting start date in range mode
1090
- - Added memo cache invalidation to ensure UI updates correctly reflect selected dates
1091
- - Fixed UI not updating when only start date is selected in range mode
1092
- - **Moment.js Timezone Offset Preservation**: Fixed issue where Moment.js objects with timezone offsets (e.g., `moment().utcOffset('-0600')`) were not preserving the timezone offset when converted to Date objects
1093
- - Added `momentToDate()` method that detects and preserves timezone offsets from Moment.js objects
1094
- - Now correctly handles `moment().utcOffset('-0600')` without requiring `toDate()` which loses timezone information
1095
-
1096
- ### Changed
1097
-
1098
- - **Version Update**: Updated to version 1.9.14
1099
- - **Stable Release**: Version 1.9.14 is the current stable version
1100
-
1101
- ### Migration Steps
1102
-
1103
- No migration steps required. This is a patch version with bug fixes only. Simply update your package version:
1104
-
1105
- ```bash
1106
- npm install ngxsmk-datepicker@1.9.14
1107
- ```
1108
-
1109
- All fixes are backward compatible and require no code changes.
1110
-
1111
- ## v1.9.12 → v1.9.13
1112
-
1113
- ### Fixed
1114
-
1115
- - **valueChange Event Bug**: Fixed issue where `(valueChange)` event was emitting `null` instead of the date value for range mode when using template-driven forms with `[(ngModel)]`
1116
- - **Range Mode Date Selection**: Fixed issue where dates became disabled/unclickable after navigating to previous or next months in range mode
1117
- - **Moment.js Object Handling**: Fixed issue where Moment.js objects in range values and arrays were not being properly normalized and converted to Date objects
1118
-
1119
- ### Changed
1120
-
1121
- - **Version Update**: Updated to version 1.9.13
1122
- - **Stable Release**: Version 1.9.13 is the current stable version
1123
-
1124
- ### Migration Steps
1125
-
1126
- No migration steps required. This is a patch version with bug fixes only. Simply update your package version:
1127
-
1128
- ```bash
1129
- npm install ngxsmk-datepicker@1.9.13
1130
- ```
1131
-
1132
- All fixes are backward compatible and require no code changes.
1133
-
1134
- ## v1.9.11 → v1.9.12
1135
-
1136
- ### Changed
1137
-
1138
- - **Version Update**: Updated to version 1.9.12
1139
- - **Stable Release**: Version 1.9.12 is the current stable version
1140
-
1141
- ### Migration Steps
1142
-
1143
- No code changes required. This is a minor version update with backward compatibility:
1144
-
1145
- 1. Update package version:
1146
-
1147
- ```bash
1148
- npm install ngxsmk-datepicker@^1.9.12
1149
- ```
1150
-
1151
- 2. Rebuild your application:
1152
-
1153
- ```bash
1154
- npm run build
1155
- ```
1156
-
1157
- 3. Run tests to ensure everything works:
1158
- ```bash
1159
- npm test
1160
- ```
1161
-
1162
- **Note**: This version maintains full backward compatibility with v1.9.11. All existing code will continue to work without modifications.
1163
-
1164
- ## v1.9.10 → v1.9.11
1165
-
1166
- ### Fixed
1167
-
1168
- - **Moment.js Integration**: Fixed critical issue where Moment.js objects with custom date formats would not populate correctly
1169
- - Added support for Moment.js objects via `.toDate()` method
1170
- - Enhanced format token parsing (YYYY, YY, MM, M, DD, D, hh, h, HH, H, mm, m, ss, s, a, A)
1171
- - Improved TypeScript compatibility with dynamic object properties
1172
-
1173
- ### Migration Steps
1174
-
1175
- No code changes required. This is a bug fix release:
1176
-
1177
- 1. Update package version:
1178
-
1179
- ```bash
1180
- npm install ngxsmk-datepicker@^1.9.11
1181
- ```
1182
-
1183
- 2. If you're using Moment.js with custom formats, the datepicker will now properly handle Moment.js objects.
1184
-
1185
- ## v1.9.9 → v1.9.10
1186
-
1187
- ### Fixed
1188
-
1189
- - **Async Database Value Loading**: Enhanced datepicker to properly handle database values that load asynchronously
1190
- - Added fallback sync mechanisms for async database loads
1191
- - Extended sync duration to 30 seconds with 100ms check intervals
1192
- - **TypeScript Compilation Error**: Fixed `EffectRef` type error when using Angular 17+ `effect()` API
1193
- - **Test Configuration**: Fixed test configuration for Angular 17+ compatibility
1194
-
1195
- ### Migration Steps
1196
-
1197
- No code changes required. This is a bug fix release:
1198
-
1199
- 1. Update package version:
1200
-
1201
- ```bash
1202
- npm install ngxsmk-datepicker@^1.9.10
1203
- ```
1204
-
1205
- 2. If you're experiencing issues with database values not populating, this version should resolve them.
1206
-
1207
- ## v1.9.8 → v1.9.9
1208
-
1209
- ### Fixed
1210
-
1211
- - **Database Value Population**: Fixed critical issue where datepicker would not populate with values from database when using `[field]` input binding
1212
- - Now properly handles Date objects, string dates, range objects, and arrays of dates
1213
-
1214
- ### Migration Steps
1215
-
1216
- No code changes required. This is a bug fix release:
1217
-
1218
- 1. Update package version:
1219
- ```bash
1220
- npm install ngxsmk-datepicker@^1.9.9
1221
- ```
1222
-
1223
- ## v1.9.7 → v1.9.8
1224
-
1225
- ### Fixed
1226
-
1227
- - **Date Selection Reset Issue**: Fixed critical bug where selected dates would reset to today's date when using `[field]` input binding
1228
- - Fixed date mutation issues
1229
- - Added internal update flag to prevent value resets
1230
-
1231
- ### Migration Steps
1232
-
1233
- No code changes required. This is a bug fix release:
1234
-
1235
- 1. Update package version:
1236
- ```bash
1237
- npm install ngxsmk-datepicker@^1.9.8
1238
- ```
1239
-
1240
- ## v1.9.6 → v1.9.7
1241
-
1242
- ### Fixed
1243
-
1244
- - **Calendar Population**: Fixed critical issue where datepicker calendar would not populate with dates when opened
1245
- - Fixed issue when multiple datepickers were present in the same form
1246
-
1247
- ### Migration Steps
1248
-
1249
- No code changes required. This is a bug fix release:
1250
-
1251
- 1. Update package version:
1252
- ```bash
1253
- npm install ngxsmk-datepicker@^1.9.7
1254
- ```
1255
-
1256
- ## v1.9.5 → v1.9.6
1257
-
1258
- ### Fixed
1259
-
1260
- - **Multiple Datepicker Management**: Fixed issue where multiple datepickers in the same form would open in the same centered location
1261
- - **Outside Click Detection**: Improved click detection to properly close datepicker
1262
- - **Auto-close Other Datepickers**: When opening a datepicker, all other open datepickers are now automatically closed
1263
- - **Mobile Datepicker**: Fixed issues with mobile datepicker opening and closing
1264
- - **Select Box Cursor**: Added pointer cursor to all select boxes
1265
-
1266
- ### Migration Steps
1267
-
1268
- No code changes required. This is a bug fix release:
1269
-
1270
- 1. Update package version:
1271
- ```bash
1272
- npm install ngxsmk-datepicker@^1.9.6
1273
- ```
1274
-
1275
- ## v1.9.4 → v1.9.5
1276
-
1277
- ### Fixed
1278
-
1279
- - **Angular 21+ Signal Forms Type Compatibility**: Fixed TypeScript compilation error with Angular 21+ Signal Forms
1280
- - Fixed `Type '() => string' is not assignable to type 'never'` error when using `[field]` input
1281
- - Updated `SignalFormField` type definition to be compatible with Angular 21's `FieldTree<Date, string>` types
1282
- - Maintains backward compatibility with Angular 17-20
1283
-
1284
- ### Migration Steps
1285
-
1286
- No code changes required. This is a bug fix release:
1287
-
1288
- 1. Update package version:
1289
-
1290
- ```bash
1291
- npm install ngxsmk-datepicker@^1.9.5
1292
- ```
1293
-
1294
- 2. If you were experiencing TypeScript errors with Signal Forms in Angular 21+, they should now be resolved.
1295
-
1296
- ## v1.9.3 → v1.9.4
1297
-
1298
- ### Added
1299
-
1300
- - **Custom Date Format**: New `[displayFormat]` input property to display dates in custom formats
1301
- - Supports format strings like "MM/DD/YYYY hh:mm A"
1302
- - Works with date adapters (date-fns, dayjs, luxon) or built-in simple formatter
1303
- - Supports common format tokens: YYYY, MM, DD, hh, mm, A, etc.
1304
-
1305
- ### Fixed
1306
-
1307
- - **Time Selection Dropdowns**: Fixed visibility issues with time selection dropdowns
1308
- - Dropdowns now properly display and are not clipped by parent containers
1309
- - Improved z-index handling for time selection dropdowns
1310
-
1311
- ### Migration Steps
1312
-
1313
- 1. Update package version:
1314
-
1315
- ```bash
1316
- npm install ngxsmk-datepicker@^1.9.4
1317
- ```
1318
-
1319
- 2. **Optional**: Use the new `[displayFormat]` input for custom date formatting:
1320
- ```html
1321
- <ngxsmk-datepicker [displayFormat]="'MM/DD/YYYY hh:mm A'" mode="single"> </ngxsmk-datepicker>
1322
- ```
1323
-
1324
- ## v1.9.2 → v1.9.3
1325
-
1326
- ### Added
1327
-
1328
- - **Time-Only Picker**: New `[timeOnly]` input property to display only time selection without calendar
1329
- - Hides calendar grid and shows only time controls (hour, minute, AM/PM)
1330
- - Automatically enables `showTime` when `timeOnly` is true
1331
- - Perfect for time selection scenarios where date is not needed
1332
-
1333
- ### Fixed
1334
-
1335
- - **Test Suite**: Fixed 25+ failing tests across multiple test files
1336
- - All 353 tests now pass successfully
1337
-
1338
- ### Migration Steps
1339
-
1340
- 1. Update package version:
1341
-
1342
- ```bash
1343
- npm install ngxsmk-datepicker@^1.9.3
1344
- ```
1345
-
1346
- 2. **Optional**: Use the new `[timeOnly]` input for time-only selection:
1347
- ```html
1348
- <ngxsmk-datepicker [timeOnly]="true" placeholder="Select Time"> </ngxsmk-datepicker>
1349
- ```
1350
-
1351
- ## v1.9.1 → v1.9.2
1352
-
1353
- ### Changed
1354
-
1355
- - **Bundle Optimization**: Optimized bundle size with improved TypeScript compiler settings
1356
- - Main bundle: ~127KB (source maps excluded from published package)
1357
- - Enhanced tree-shaking with optimized imports and compiler options
1358
- - Source maps automatically removed from production builds
1359
-
1360
- ### Fixed
1361
-
1362
- - Test suite configuration improvements
1363
- - Bundle analysis now correctly excludes source maps
1364
- - Build warnings from conflicting export conditions resolved
1365
-
1366
- ### Migration Steps
1367
-
1368
- No code changes required. This is a transparent update with optimizations:
1369
-
1370
- 1. Update package version:
1371
-
1372
- ```bash
1373
- npm install ngxsmk-datepicker@^1.9.2
1374
- ```
1375
-
1376
- 2. Rebuild your application to benefit from bundle optimizations:
1377
- ```bash
1378
- npm run build
1379
- ```
1380
-
1381
- ## v1.9.0 → v1.9.1
1382
-
1383
- ### New Features
1384
-
1385
- _No new features in v1.9.1._
1386
-
1387
- ### Changes
1388
-
1389
- #### Bundle Optimization
1390
-
1391
- The library bundle has been further optimized for production:
1392
-
1393
- - **Bundle Size**: Main bundle is now ~127KB (source maps excluded from published package)
1394
- - **TypeScript Compiler**: Enhanced settings for better tree-shaking
1395
- - Added `importsNotUsedAsValues: "remove"` for smaller output
1396
- - Disabled `preserveConstEnums` for better inlining
1397
- - **Source Maps**: Automatically removed from production builds (saves ~127KB)
1398
- - **Package Configuration**: Fixed exports to eliminate build warnings
1399
-
1400
- **For Developers:**
1401
-
1402
- - Use `npm run build:optimized` for production builds
1403
- - Use `npm run build:analyze` to check bundle size
1404
- - Source maps are automatically excluded from the published package
1405
-
1406
- #### Build Process Improvements
1407
-
1408
- - Source maps are now automatically removed from production builds
1409
- - Improved build scripts with better error handling
1410
- - Enhanced bundle analysis that correctly excludes source maps
1411
-
1412
- #### Package Configuration
1413
-
1414
- - Fixed `package.json` exports to eliminate build warnings
1415
- - Optimized `files` array to exclude unnecessary files
1416
- - Updated exports field for better module resolution
1417
-
1418
- #### Test Configuration
1419
-
1420
- - Added Zone.js polyfills to library test configuration
1421
- - Updated test commands to explicitly target library project
1422
- - Improved test reliability across Angular versions
1423
-
1424
- ### Breaking Changes
1425
-
1426
- None in v1.9.1.
1427
-
1428
- ### Deprecations
1429
-
1430
- None in v1.9.1.
1431
-
1432
- ### Migration Steps
1433
-
1434
- No code changes required. This is a transparent update with optimizations and bug fixes:
1435
-
1436
- 1. Update package version:
1437
-
1438
- ```bash
1439
- npm install ngxsmk-datepicker@^1.9.1
1440
- ```
1441
-
1442
- 2. Rebuild your application:
1443
-
1444
- ```bash
1445
- npm run build
1446
- ```
1447
-
1448
- 3. Verify bundle size improvements (optional):
1449
- - Check your application's bundle size
1450
- - You should see improved tree-shaking benefits
1451
-
1452
- 4. Run tests to ensure everything works:
1453
- ```bash
1454
- npm test
1455
- ```
1456
-
1457
- **Note**: If you're a library developer using ngxsmk-datepicker as a dependency, you may notice:
1458
-
1459
- - Smaller bundle sizes in your application
1460
- - Fewer build warnings related to package exports
1461
- - Improved test reliability if you're running tests with Zone.js
1462
-
1463
- ## v1.8.0 → v1.9.0
1464
-
1465
- ### New Features
1466
-
1467
- #### Extension Points & Hooks
1468
-
1469
- Added comprehensive hook system for customization.
1470
-
1471
- **New Input:**
1472
-
1473
- ```typescript
1474
- hooks: DatepickerHooks | null = null;
1475
- ```
1476
-
1477
- **Usage:**
1478
-
1479
- ```typescript
1480
- const myHooks: DatepickerHooks = {
1481
- getDayCellClasses: (date, isSelected, isDisabled, isToday, isHoliday) => {
1482
- return isHoliday ? ["custom-holiday"] : [];
1483
- },
1484
- validateDate: (date, currentValue, mode) => {
1485
- return date.getDay() !== 0; // Disable Sundays
1486
- },
1487
- };
1488
- ```
1489
-
1490
- ```html
1491
- <ngxsmk-datepicker [hooks]="myHooks"></ngxsmk-datepicker>
1492
- ```
1493
-
1494
- #### Enhanced Keyboard Shortcuts
1495
-
1496
- New keyboard shortcuts:
1497
-
1498
- - `Y`: Select yesterday
1499
- - `N`: Select tomorrow
1500
- - `W`: Select next week
1501
-
1502
- #### Animation Optimizations
1503
-
1504
- All animations now use GPU acceleration for better performance. No code changes required.
1505
-
1506
- #### Bundle Optimization
1507
-
1508
- The library bundle has been optimized for production:
1509
-
1510
- - **Bundle Size**: Main bundle is now ~127KB (source maps excluded from published package)
1511
- - **Tree-Shaking**: Enhanced with optimized TypeScript compiler settings
1512
- - **Source Maps**: Automatically removed from production builds (saves ~127KB)
1513
- - **No Breaking Changes**: All optimizations are transparent to end users
1514
-
1515
- **For Developers:**
1516
-
1517
- - Use `npm run build:optimized` for production builds
1518
- - Use `npm run build:analyze` to check bundle size
1519
- - Source maps are automatically excluded from the published package
1520
-
1521
- ### Breaking Changes
1522
-
1523
- None in v1.9.0.
1524
-
1525
- ### Deprecations
1526
-
1527
- None in v1.9.0.
1528
-
1529
- ## v1.7.0 → v1.8.0
1530
-
1531
- ### New Features
1532
-
1533
- #### Signal Forms Support
1534
-
1535
- Added `[field]` input for Angular 21+ Signal Forms integration.
1536
-
1537
- **Before:**
1538
-
1539
- ```typescript
1540
- // Using Reactive Forms
1541
- dateControl = new FormControl<DatepickerValue>(null);
1542
- ```
1543
-
1544
- ```html
1545
- <ngxsmk-datepicker formControlName="date"></ngxsmk-datepicker>
1546
- ```
1547
-
1548
- **After (Optional - Reactive Forms still work):**
1549
-
1550
- ```typescript
1551
- // Using Signal Forms
1552
- localObject = signal({ date: null as DatepickerValue });
1553
- myForm = form(
1554
- this.localObject,
1555
- objectSchema({
1556
- date: objectSchema<DatepickerValue>(),
1557
- }),
1558
- );
1559
- ```
1560
-
1561
- ```html
1562
- <ngxsmk-datepicker [field]="myForm.date"></ngxsmk-datepicker>
1563
- ```
1564
-
1565
- #### SSR Optimizations
1566
-
1567
- The datepicker is now fully SSR-compatible. No code changes required, but ensure you're using the latest version for SSR applications.
1568
-
1569
- #### Improved Value Input
1570
-
1571
- The `[value]` input now initializes immediately when set programmatically.
1572
-
1573
- **Before:**
1574
-
1575
- ```typescript
1576
- // Value might not initialize immediately
1577
- component.value = new Date();
1578
- ```
1579
-
1580
- **After:**
1581
-
1582
- ```typescript
1583
- // Value initializes immediately
1584
- component.value = new Date();
1585
- ```
1586
-
1587
- ### Breaking Changes
1588
-
1589
- None in v1.8.0.
1590
-
1591
- ### Deprecations
1592
-
1593
- None in v1.8.0.
1594
-
1595
- ## v1.9.0 → v2.0.0
1596
-
1597
- ### Planned Breaking Changes
1598
-
1599
- _This section will be updated when v2.0.0 is released._
1600
-
1601
- ### Migration Steps
1602
-
1603
- 1. Update package version:
1604
-
1605
- ```bash
1606
- npm install ngxsmk-datepicker@^2.0.0
1607
- ```
1608
-
1609
- 2. Review breaking changes below
1610
- 3. Update your code according to migration steps
1611
- 4. Run tests
1612
- 5. Update any custom styles if CSS classes changed
1613
-
1614
- ## General Migration Tips
1615
-
1616
- ### 1. Read the Changelog
1617
-
1618
- Always check `CHANGELOG.md` for detailed changes in each version.
1619
-
1620
- ### 2. Test Thoroughly
1621
-
1622
- After upgrading:
1623
-
1624
- - Test all datepicker instances in your app
1625
- - Verify form integration still works
1626
- - Check SSR compatibility if applicable
1627
- - Test keyboard navigation
1628
- - Verify accessibility features
1629
-
1630
- ### 3. Update Dependencies
1631
-
1632
- Ensure your Angular version is compatible:
1633
-
1634
- - Check the compatibility table in README.md
1635
- - Update Angular if needed
1636
-
1637
- ### 4. Check TypeScript Errors
1638
-
1639
- New versions may have stricter types:
1640
-
1641
- ```bash
1642
- npm run build
1643
- # Fix any TypeScript errors
1644
- ```
1645
-
1646
- ### 5. Review CSS Changes
1647
-
1648
- If you've customized styles:
1649
-
1650
- - Check if CSS class names changed
1651
- - Review CSS custom properties
1652
- - Update selectors if needed
1653
-
1654
- ## Getting Help
1655
-
1656
- If you encounter issues during migration:
1657
-
1658
- 1. Check existing GitHub issues
1659
- 2. Review the documentation
1660
- 3. Open a new issue with:
1661
- - Your current version
1662
- - Target version
1663
- - Error messages
1664
- - Code examples
1665
-
1666
- ## Version Compatibility
1667
-
1668
- | ngxsmk-datepicker | Angular | Node.js |
1669
- | ----------------- | ------- | ------- |
1670
- | 1.9.17+ | 17-22 | 18+ |
1671
- | 1.9.16 | 17-22 | 18+ |
1672
- | 1.9.15 | 17-22 | 18+ |
1673
- | 1.9.14 | 17-22 | 18+ |
1674
- | 1.9.11 | 17-22 | 18+ |
1675
- | 1.9.10 | 17-22 | 18+ |
1676
- | 1.9.9 | 17-22 | 18+ |
1677
- | 1.9.8 | 17-22 | 18+ |
1678
- | 1.9.7 | 17-22 | 18+ |
1679
- | 1.9.6 | 17-22 | 18+ |
1680
- | 1.9.5 | 17-22 | 18+ |
1681
- | 1.9.4 | 17-22 | 18+ |
1682
- | 1.9.3 | 17-22 | 18+ |
1683
- | 1.9.2 | 17-22 | 18+ |
1684
- | 1.9.1 | 17-22 | 18+ |
1685
- | 1.9.0 | 17-22 | 18+ |
1686
- | 1.8.0 | 17-22 | 18+ |
1687
- | 1.7.0 | 17-20 | 18+ |
1688
-
1689
- ## Deprecation Timeline
1690
-
1691
- When APIs are deprecated:
1692
-
1693
- 1. **Deprecation Notice**: API marked with `@deprecated` JSDoc
1694
- 2. **Warning Period**: Deprecated API remains functional for at least one major version
1695
- 3. **Removal**: Deprecated API removed in next major version
1696
-
1697
- Example:
1698
-
1699
- - v1.8.0: API deprecated
1700
- - v1.9.0: Still works with deprecation warning
1701
- - v1.9.1: Still works with deprecation warning
1702
- - v2.0.0: Removed