ngxsmk-datepicker 2.3.1 → 2.4.0-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +75 -3
- package/MIGRATION.md +1818 -1794
- package/README.md +967 -922
- package/docs/API.md +2423 -2413
- package/docs/COMPATIBILITY.md +471 -471
- package/docs/INTEGRATION.md +703 -703
- package/docs/IONIC_INTEGRATION.md +228 -228
- package/docs/LOCALE-GUIDE.md +300 -300
- package/docs/PLUGIN-ARCHITECTURE.md +930 -930
- package/docs/SSR-EXAMPLE.md +427 -427
- package/docs/THEME-TOKENS.md +324 -324
- package/docs/TIMEZONE.md +307 -307
- package/docs/extension-points.md +419 -419
- package/docs/signal-forms.md +600 -600
- package/docs/signals.md +266 -266
- package/docs/ssr.md +305 -305
- package/fesm2022/ngxsmk-datepicker.mjs +762 -289
- package/package.json +10 -1
- package/schematics/collection.json +10 -0
- package/schematics/ng-add/index.js +67 -0
- package/schematics/ng-add/schema.json +14 -0
- package/types/ngxsmk-datepicker.d.ts +263 -108
- package/docs/FEATURE_SCOPING.md +0 -60
- package/docs/IONIC_TESTING.md +0 -148
- package/docs/REFACTOR_PLAN.md +0 -38
- package/docs/SEO.md +0 -214
package/CHANGELOG.md
CHANGED
|
@@ -2,13 +2,85 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
|
|
5
|
-
**Last updated:**
|
|
5
|
+
**Last updated:** July 11, 2026 - **Current stable:** v2.4.0
|
|
6
6
|
|
|
7
7
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
8
8
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
9
9
|
|
|
10
10
|
## [Unreleased]
|
|
11
11
|
|
|
12
|
+
### Added
|
|
13
|
+
|
|
14
|
+
- **`ng add ngxsmk-datepicker` schematic**: installs the package, adds the missing `luxon` peer
|
|
15
|
+
dependency, and prints a getting-started snippet. Shipped in the npm package under `schematics/`
|
|
16
|
+
and self-verified on every publish.
|
|
17
|
+
- **ISO week numbers**: `[showWeekNumbers]` renders an ISO 8601 week-number column; header label is
|
|
18
|
+
customizable via `[weekNumberLabel]` (e.g. `"KW"`). New exported util `getISOWeekNumber`.
|
|
19
|
+
- **Guided input masking**: `[inputMask]` (requires `allowTyping`) slots typed digits into
|
|
20
|
+
`DD`/`MM`/`YY`/`YYYY`/`HH`/`mm`/`ss` tokens and auto-inserts separators. `true` uses
|
|
21
|
+
`displayFormat` (falling back to `MM/DD/YYYY`); a string sets an explicit pattern.
|
|
22
|
+
- **Server-driven disabled dates**: `[asyncDateFilter]` is called with the visible month range on
|
|
23
|
+
every navigation and disables the resolved dates. Stale responses are discarded; new
|
|
24
|
+
`(asyncDateFilterLoading)` and `(asyncDateFilterError)` outputs report request state.
|
|
25
|
+
- **Secondary calendar systems**: `[secondaryCalendar]` annotates each day cell with its date in a
|
|
26
|
+
second calendar (`islamic`, `persian`, `hebrew`, `buddhist`, `japanese`) rendered via `Intl`;
|
|
27
|
+
the grid itself remains Gregorian. New exported utils `getSecondaryDayLabel` and
|
|
28
|
+
`formatDateInCalendarSystem`.
|
|
29
|
+
- **Per-day metadata decorations**: `[dayMetadata]` provider adds a label under the day number
|
|
30
|
+
(e.g. a price), an indicator dot, extra CSS classes, and a tooltip per day — booking-style
|
|
31
|
+
calendars without custom templates. Also available as `meta` in day-template contexts.
|
|
32
|
+
New exported types `DayMetadata` / `DayMetadataProvider`.
|
|
33
|
+
- **Header/footer action slots**: `[calendarHeaderTemplate]` renders custom content at the top of
|
|
34
|
+
the popover; `[calendarFooterTemplate]` replaces the default Clear/Close footer (and, unlike the
|
|
35
|
+
default, also renders in inline mode). Both receive `{ clear(), close() }` actions in context.
|
|
36
|
+
|
|
37
|
+
### Fixed
|
|
38
|
+
|
|
39
|
+
- **Memory leak — multi-calendar lazy-loading observer**: the `IntersectionObserver` was stored in
|
|
40
|
+
the timeout set and "cleaned up" with `clearTimeout`, so it was never disconnected and retained
|
|
41
|
+
the whole component. It is now tracked separately and disconnected on destroy.
|
|
42
|
+
- **Memory leak — destroy with open popover**: destroying the component while the calendar was open
|
|
43
|
+
(e.g. route navigation) leaked the window `scroll`/`resize` listeners and left the body-appended
|
|
44
|
+
portal view attached to `ApplicationRef`. `ngOnDestroy` now tears both down.
|
|
45
|
+
- **Input mask zero-padding**: with `displayFormat` set, typing a partial token was zero-padded
|
|
46
|
+
(typing `1` became `10`), corrupting subsequent input. Partial tokens are now left as typed, and
|
|
47
|
+
the caret stays at the end when the mask inserts separators.
|
|
48
|
+
- `ngOnDestroy` "state clearing" used no-op `??=` assignments; date references are now actually
|
|
49
|
+
released.
|
|
50
|
+
- The workspace root `package.json` is now `private`, preventing an accidental `npm publish` of the
|
|
51
|
+
workspace itself (releases publish from `dist/ngxsmk-datepicker` as before).
|
|
52
|
+
|
|
53
|
+
## [2.4.0] - 2026-07-02
|
|
54
|
+
|
|
55
|
+
### Added
|
|
56
|
+
|
|
57
|
+
- **Dual-Range Comparison**: New `[comparisonRange]="[start, end]"` input highlights a secondary,
|
|
58
|
+
purely-presentational range alongside the primary selection (analytics "this period vs previous"
|
|
59
|
+
use case). Themeable via the `--datepicker-comparison-range-color` CSS variable; does not affect
|
|
60
|
+
selection or emitted values.
|
|
61
|
+
|
|
62
|
+
### Changed
|
|
63
|
+
|
|
64
|
+
- **Modern reactivity (non-breaking)**: Migrated all `@Output()`s to the `output()` function and an
|
|
65
|
+
initial batch of read-only `@Input()`s to signal `input()`. Public template bindings
|
|
66
|
+
(`[x]="…"` / `(event)="…"`) are unchanged.
|
|
67
|
+
- **Signal-backed internal state**: Converted transient state (`isOpeningCalendar`,
|
|
68
|
+
`naturalLanguagePreview`, `showNaturalLanguagePreview`, `validationErrorMessage`, `typedInputValue`)
|
|
69
|
+
to signals and made the `displayValue` getter side-effect free, reducing manual `markForCheck()`.
|
|
70
|
+
|
|
71
|
+
### Fixed
|
|
72
|
+
|
|
73
|
+
- **TypeScript 6.0 build compatibility**: Removed the now-invalid `baseUrl` and `importsNotUsedAsValues`
|
|
74
|
+
compiler options that broke the production build and test suite on the TS 6 toolchain.
|
|
75
|
+
- Corrected three internal guards (`autoApplyClose`, `timeRangeMode`, `allowSameDay`) surfaced during
|
|
76
|
+
the signal migration.
|
|
77
|
+
|
|
78
|
+
### Removed
|
|
79
|
+
|
|
80
|
+
- **Dead SCSS architecture** (~7k lines): the unreferenced, stale `datepicker.scss` +
|
|
81
|
+
`styles/{components,core,abstracts}/` partials, `_legacy-datepicker.scss`, and an orphaned
|
|
82
|
+
`datepicker.css.map`. The maintained flat `styles/datepicker.css` is unaffected.
|
|
83
|
+
|
|
12
84
|
## [2.3.1] - 2026-06-03
|
|
13
85
|
|
|
14
86
|
### Added
|
|
@@ -57,7 +129,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
57
129
|
|
|
58
130
|
### Fixed
|
|
59
131
|
|
|
60
|
-
- **npm package**: The `2.2.12` tarball on the registry omitted `fesm2022/` and `types/` (only docs, styles, and package metadata). **Use `ngxsmk-datepicker@2.2.11` until `2.
|
|
132
|
+
- **npm package**: The `2.2.12` tarball on the registry omitted `fesm2022/` and `types/` (only docs, styles, and package metadata). **Use `ngxsmk-datepicker@2.2.11` until `2.4.0` or later** with a full ng-packagr build ([#230](https://github.com/NGXSMK/ngxsmk-datepicker/issues/230)).
|
|
61
133
|
|
|
62
134
|
## [2.2.11] - 2026-03-24
|
|
63
135
|
|
|
@@ -939,7 +1011,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
939
1011
|
- No breaking changes from v1.9.11
|
|
940
1012
|
- SEO improvements are automatic and require no code changes
|
|
941
1013
|
- See [MIGRATION.md](MIGRATION.md) for detailed migration guide
|
|
942
|
-
- See
|
|
1014
|
+
- See docs/SEO.md for SEO best practices *(document removed in July 2026 cleanup)*
|
|
943
1015
|
|
|
944
1016
|
## [1.9.11] - 2025-11-17
|
|
945
1017
|
|