@etsoo/shared 1.1.7 → 1.1.8

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.
@@ -48,7 +48,7 @@ export declare namespace DateUtils {
48
48
  * Format to 'yyyy-MM-dd', especially used for date input min/max property
49
49
  * @param date Input date
50
50
  */
51
- function formatForInput(date?: Date | string): string;
51
+ function formatForInput(date?: Date | string | null): string;
52
52
  /**
53
53
  * Get month's days
54
54
  * @param year Year
@@ -48,7 +48,7 @@ export declare namespace DateUtils {
48
48
  * Format to 'yyyy-MM-dd', especially used for date input min/max property
49
49
  * @param date Input date
50
50
  */
51
- function formatForInput(date?: Date | string): string;
51
+ function formatForInput(date?: Date | string | null): string;
52
52
  /**
53
53
  * Get month's days
54
54
  * @param year Year
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@etsoo/shared",
3
- "version": "1.1.7",
3
+ "version": "1.1.8",
4
4
  "description": "TypeScript shared utilities and functions",
5
5
  "main": "lib/cjs/index.js",
6
6
  "module": "lib/mjs/index.js",
package/src/DateUtils.ts CHANGED
@@ -148,7 +148,7 @@ export namespace DateUtils {
148
148
  * Format to 'yyyy-MM-dd', especially used for date input min/max property
149
149
  * @param date Input date
150
150
  */
151
- export function formatForInput(date?: Date | string) {
151
+ export function formatForInput(date?: Date | string | null) {
152
152
  // Parse string as date
153
153
  if (typeof date === 'string') date = new Date(date);
154
154