@alfalab/core-components-date-input 5.0.0 → 5.1.0-snapshot-92b8690

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.
@@ -0,0 +1,46 @@
1
+ import React, { ChangeEvent } from 'react';
2
+ import { InputProps } from '@alfalab/core-components-input';
3
+ export declare type DateInputProps = Omit<InputProps, 'onChange'> & {
4
+ /**
5
+ * Управление нативным режимом на мобильных устройствах
6
+ */
7
+ mobileMode?: 'input' | 'native';
8
+ /**
9
+ * Обработчик изменения значения
10
+ */
11
+ onChange?: (event: ChangeEvent<HTMLInputElement>, payload: {
12
+ date: Date;
13
+ value: string;
14
+ }) => void;
15
+ /**
16
+ * Обработчик окончания ввода
17
+ */
18
+ onComplete?: (event: ChangeEvent<HTMLInputElement>, payload: {
19
+ date: Date;
20
+ value: string;
21
+ }) => void;
22
+ };
23
+ /**
24
+ * @deprecated
25
+ * use UniversalDateInput instead
26
+ */
27
+ export declare const DateInput: React.ForwardRefExoticComponent<Omit<InputProps, "onChange"> & {
28
+ /**
29
+ * Управление нативным режимом на мобильных устройствах
30
+ */
31
+ mobileMode?: "input" | "native" | undefined;
32
+ /**
33
+ * Обработчик изменения значения
34
+ */
35
+ onChange?: ((event: ChangeEvent<HTMLInputElement>, payload: {
36
+ date: Date;
37
+ value: string;
38
+ }) => void) | undefined;
39
+ /**
40
+ * Обработчик окончания ввода
41
+ */
42
+ onComplete?: ((event: ChangeEvent<HTMLInputElement>, payload: {
43
+ date: Date;
44
+ value: string;
45
+ }) => void) | undefined;
46
+ } & React.RefAttributes<HTMLInputElement>>;
@@ -0,0 +1,106 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ var tslib = require('tslib');
6
+ var React = require('react');
7
+ var mergeRefs = require('react-merge-refs');
8
+ var dynamicMixins = require('@alfalab/core-components-input/dynamic-mixins');
9
+ var format = require('./utils/format.js');
10
+ var nativeSupports = require('./utils/native-supports.js');
11
+ var index_module = require('./index.module.css.js');
12
+
13
+ function _interopDefaultCompat (e) { return e && typeof e === 'object' && 'default' in e ? e : { default: e }; }
14
+
15
+ var React__default = /*#__PURE__*/_interopDefaultCompat(React);
16
+ var mergeRefs__default = /*#__PURE__*/_interopDefaultCompat(mergeRefs);
17
+
18
+ /**
19
+ * @deprecated
20
+ * use UniversalDateInput instead
21
+ */
22
+ var DateInput = React.forwardRef(function (_a, ref) {
23
+ var _b = _a.mobileMode, mobileMode = _b === void 0 ? 'input' : _b, _c = _a.defaultValue, defaultValue = _c === void 0 ? '' : _c, rightAddons = _a.rightAddons, error = _a.error, propValue = _a.value, onBlur = _a.onBlur, onChange = _a.onChange, onComplete = _a.onComplete, restProps = tslib.__rest(_a, ["mobileMode", "defaultValue", "rightAddons", "error", "value", "onBlur", "onChange", "onComplete"]);
24
+ var inputRef = React.useRef(null);
25
+ var _d = React.useState(false), shouldRenderNative = _d[0], setShouldRenderNative = _d[1];
26
+ var _e = React.useState(propValue || defaultValue), value = _e[0], setValue = _e[1];
27
+ var moveCaretTo = function (pos) {
28
+ requestAnimationFrame(function () {
29
+ var _a;
30
+ (_a = inputRef.current) === null || _a === void 0 ? void 0 : _a.setSelectionRange(pos, pos);
31
+ });
32
+ };
33
+ var handleChange = function (event) {
34
+ var newValue = event.target.value;
35
+ var caretPos = event.target.selectionStart || 0;
36
+ // Позволяем вводить только цифры и точки
37
+ if (/[^\d.]/.test(newValue)) {
38
+ moveCaretTo(caretPos - 1);
39
+ return;
40
+ }
41
+ // Не даем вводить больше, чем 2 точки
42
+ if (getDotsCount(newValue) > 2) {
43
+ moveCaretTo(caretPos - 1);
44
+ return;
45
+ }
46
+ // Форматируем введенное значение (добавляем точки)
47
+ var formattedValue = format.format(newValue);
48
+ var date = format.parseDateString(formattedValue);
49
+ // Управляем кареткой, если она находится не в конце инпута
50
+ if (caretPos !== newValue.length) {
51
+ if (formattedValue === value) {
52
+ moveCaretTo(caretPos);
53
+ }
54
+ else if (newValue.length - formattedValue.length === 1) {
55
+ moveCaretTo(caretPos);
56
+ }
57
+ else if (formattedValue.length - newValue.length === 1 &&
58
+ getDotsCount(formattedValue) > getDotsCount(newValue)) {
59
+ moveCaretTo(caretPos);
60
+ }
61
+ }
62
+ setValue(formattedValue);
63
+ if (onChange)
64
+ onChange(event, { date: date, value: formattedValue });
65
+ if (format.isCompleteDateInput(formattedValue)) {
66
+ var valid = formattedValue.length > 0 && format.isValid(formattedValue);
67
+ if (!valid)
68
+ return;
69
+ if (onComplete)
70
+ onComplete(event, { date: date, value: formattedValue });
71
+ }
72
+ };
73
+ var handleNativeInputChange = function (event) {
74
+ var newDate = format.parseDateString(event.target.value, format.NATIVE_DATE_FORMAT);
75
+ var newValue = event.target.value === '' ? '' : format.formatDate(newDate);
76
+ setValue(newValue);
77
+ if (onComplete)
78
+ onComplete(event, { date: newDate, value: newValue });
79
+ if (onChange)
80
+ onChange(event, { date: newDate, value: newValue });
81
+ };
82
+ var handleBlur = function (event) {
83
+ if (onBlur)
84
+ onBlur(event);
85
+ };
86
+ React.useEffect(function () {
87
+ if (mobileMode === 'native' && nativeSupports.isInputDateSupported()) {
88
+ setShouldRenderNative(true);
89
+ }
90
+ }, [mobileMode]);
91
+ React.useEffect(function () {
92
+ if (typeof propValue !== 'undefined') {
93
+ setValue(propValue);
94
+ }
95
+ // eslint-disable-next-line react-hooks/exhaustive-deps
96
+ }, [propValue]);
97
+ return (React__default.default.createElement(dynamicMixins.Input, tslib.__assign({}, restProps, { ref: mergeRefs__default.default([ref, inputRef]), value: value, inputMode: 'decimal', pattern: '[0-9\\.]*', onChange: handleChange, onBlur: handleBlur, placeholder: '\u0414\u0414.\u041C\u041C.\u0413\u0413\u0413\u0413', error: error, rightAddons: React__default.default.createElement(React__default.default.Fragment, null,
98
+ rightAddons,
99
+ shouldRenderNative && (React__default.default.createElement("input", { type: 'date', ref: ref, defaultValue: defaultValue, onChange: handleNativeInputChange, className: index_module.nativeInput }))) })));
100
+ });
101
+ function getDotsCount(value) {
102
+ return (value.match(/\./g) || []).length;
103
+ }
104
+
105
+ exports.DateInput = DateInput;
106
+ //# sourceMappingURL=Component.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Component.js","sources":["../src/Component.tsx"],"sourcesContent":["import React, { ChangeEvent, FocusEvent, forwardRef, useEffect, useRef, useState } from 'react';\nimport mergeRefs from 'react-merge-refs';\n\nimport { Input, InputProps } from '@alfalab/core-components-input';\n\nimport {\n format,\n formatDate,\n isCompleteDateInput,\n isInputDateSupported,\n isValid,\n NATIVE_DATE_FORMAT,\n parseDateString,\n} from './utils';\n\nimport styles from './index.module.css';\n\nexport type DateInputProps = Omit<InputProps, 'onChange'> & {\n /**\n * Управление нативным режимом на мобильных устройствах\n */\n mobileMode?: 'input' | 'native';\n\n /**\n * Обработчик изменения значения\n */\n onChange?: (\n event: ChangeEvent<HTMLInputElement>,\n payload: { date: Date; value: string },\n ) => void;\n\n /**\n * Обработчик окончания ввода\n */\n onComplete?: (\n event: ChangeEvent<HTMLInputElement>,\n payload: { date: Date; value: string },\n ) => void;\n};\n\n/**\n * @deprecated\n * use UniversalDateInput instead\n */\nexport const DateInput = forwardRef<HTMLInputElement, DateInputProps>(\n (\n {\n mobileMode = 'input',\n defaultValue = '',\n rightAddons,\n error,\n value: propValue,\n onBlur,\n onChange,\n onComplete,\n ...restProps\n },\n ref,\n ) => {\n const inputRef = useRef<HTMLInputElement>(null);\n\n const [shouldRenderNative, setShouldRenderNative] = useState(false);\n\n const [value, setValue] = useState(propValue || defaultValue);\n\n const moveCaretTo = (pos: number) => {\n requestAnimationFrame(() => {\n inputRef.current?.setSelectionRange(pos, pos);\n });\n };\n\n const handleChange = (event: ChangeEvent<HTMLInputElement>) => {\n const { value: newValue } = event.target;\n const caretPos = event.target.selectionStart || 0;\n\n // Позволяем вводить только цифры и точки\n if (/[^\\d.]/.test(newValue)) {\n moveCaretTo(caretPos - 1);\n\n return;\n }\n\n // Не даем вводить больше, чем 2 точки\n if (getDotsCount(newValue) > 2) {\n moveCaretTo(caretPos - 1);\n\n return;\n }\n\n // Форматируем введенное значение (добавляем точки)\n const formattedValue = format(newValue);\n const date = parseDateString(formattedValue);\n\n // Управляем кареткой, если она находится не в конце инпута\n if (caretPos !== newValue.length) {\n if (formattedValue === value) {\n moveCaretTo(caretPos);\n } else if (newValue.length - formattedValue.length === 1) {\n moveCaretTo(caretPos);\n } else if (\n formattedValue.length - newValue.length === 1 &&\n getDotsCount(formattedValue) > getDotsCount(newValue)\n ) {\n moveCaretTo(caretPos);\n }\n }\n\n setValue(formattedValue);\n\n if (onChange) onChange(event, { date, value: formattedValue });\n\n if (isCompleteDateInput(formattedValue)) {\n const valid = formattedValue.length > 0 && isValid(formattedValue);\n\n if (!valid) return;\n\n if (onComplete) onComplete(event, { date, value: formattedValue });\n }\n };\n\n const handleNativeInputChange = (event: ChangeEvent<HTMLInputElement>) => {\n const newDate = parseDateString(event.target.value, NATIVE_DATE_FORMAT);\n const newValue = event.target.value === '' ? '' : formatDate(newDate);\n\n setValue(newValue);\n\n if (onComplete) onComplete(event, { date: newDate, value: newValue });\n if (onChange) onChange(event, { date: newDate, value: newValue });\n };\n\n const handleBlur = (event: FocusEvent<HTMLInputElement>) => {\n if (onBlur) onBlur(event);\n };\n\n useEffect(() => {\n if (mobileMode === 'native' && isInputDateSupported()) {\n setShouldRenderNative(true);\n }\n }, [mobileMode]);\n\n useEffect(() => {\n if (typeof propValue !== 'undefined') {\n setValue(propValue);\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [propValue]);\n\n return (\n <Input\n {...restProps}\n ref={mergeRefs([ref, inputRef])}\n value={value}\n inputMode='decimal'\n pattern='[0-9\\.]*'\n onChange={handleChange}\n onBlur={handleBlur}\n placeholder='ДД.ММ.ГГГГ'\n error={error}\n rightAddons={\n <React.Fragment>\n {rightAddons}\n\n {shouldRenderNative && (\n <input\n type='date'\n ref={ref}\n defaultValue={defaultValue}\n onChange={handleNativeInputChange}\n className={styles.nativeInput}\n />\n )}\n </React.Fragment>\n }\n />\n );\n },\n);\n\nfunction getDotsCount(value: string) {\n return (value.match(/\\./g) || []).length;\n}\n"],"names":["forwardRef","__rest","useRef","useState","format","parseDateString","isCompleteDateInput","isValid","NATIVE_DATE_FORMAT","formatDate","useEffect","isInputDateSupported","React","Input","__assign","mergeRefs","styles"],"mappings":";;;;;;;;;;;;;;;;;AAwCA;;;AAGG;IACU,SAAS,GAAGA,gBAAU,CAC/B,UACI,EAUC,EACD,GAAG,EAAA;AAVC,IAAA,IAAA,EAAoB,GAAA,EAAA,CAAA,UAAA,EAApB,UAAU,GAAA,EAAA,KAAA,MAAA,GAAG,OAAO,GAAA,EAAA,EACpB,EAAiB,GAAA,EAAA,CAAA,YAAA,EAAjB,YAAY,GAAG,EAAA,KAAA,MAAA,GAAA,EAAE,GAAA,EAAA,EACjB,WAAW,GAAA,EAAA,CAAA,WAAA,EACX,KAAK,GAAA,EAAA,CAAA,KAAA,EACE,SAAS,GAAA,EAAA,CAAA,KAAA,EAChB,MAAM,YAAA,EACN,QAAQ,GAAA,EAAA,CAAA,QAAA,EACR,UAAU,GAAA,EAAA,CAAA,UAAA,EACP,SAAS,GAAAC,YAAA,CAAA,EAAA,EAThB,mGAUC,CADe;AAIhB,IAAA,IAAM,QAAQ,GAAGC,YAAM,CAAmB,IAAI,CAAC;IAEzC,IAAA,EAAA,GAA8CC,cAAQ,CAAC,KAAK,CAAC,EAA5D,kBAAkB,GAAA,EAAA,CAAA,CAAA,CAAA,EAAE,qBAAqB,GAAA,EAAA,CAAA,CAAA,CAAmB;AAE7D,IAAA,IAAA,EAAoB,GAAAA,cAAQ,CAAC,SAAS,IAAI,YAAY,CAAC,EAAtD,KAAK,GAAA,EAAA,CAAA,CAAA,CAAA,EAAE,QAAQ,QAAuC;IAE7D,IAAM,WAAW,GAAG,UAAC,GAAW,EAAA;AAC5B,QAAA,qBAAqB,CAAC,YAAA;;YAClB,CAAA,EAAA,GAAA,QAAQ,CAAC,OA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AK,WAAW,EAAE;YAClC,QAAQ,CAAC,SAAS,CAAC;AACtB;;AAEL,KAAC,EAAE,CAAC,SAAS,CAAC,CAAC;IAEf,QACIE,qCAACC,mBAAK,EAAAC,cAAA,CAAA,EAAA,EACE,SAAS,EACb,EAAA,GAAG,EAAEC,0BAAS,CAAC,CAAC,GAAG,EAAE,QAAQ,CAAC,CAAC,EAC/B,KAAK,EAAE,KAAK,EACZ,SAAS,EAAC,SAAS,EACnB,OAAO,EAAC,WAAU,EAClB,QAAQ,EAAE,YAAY,EACtB,MAAM,EAAE,UAAU,EAClB,WAAW,EAAC,oDAAY,EACxB,KAAK,EAAE,KAAK,EACZ,WAAW,EACPH,sBAAA,CAAA,aAAA,CAACA,sBAAK,CAAC,QAAQ,EAAA,IAAA;YACV,WAAW;AAEX,YAAA,kBAAkB,KACfA,sBACI,CAAA,aAAA,CAAA,OAAA,EAAA,EAAA,IAAI,EAAC,MAAM,EACX,GAAG,EAAE,GAAG,EACR,YAAY,EAAE,YAAY,EAC1B,QAAQ,EAAE,uBAAuB,EACjC,SAAS,EAAEI,YAAM,CAAC,WAAW,EAC/B,CAAA,CACL,CACY,EAAA,CAAA,CAEvB;AAEV,CAAC;AAGL,SAAS,YAAY,CAAC,KAAa,EAAA;AAC/B,IAAA,OAAO,CAAC,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC,IAAI,EAAE,EAAE,MAAM;AAC5C;;;;"}
@@ -0,0 +1,18 @@
1
+ :root {
2
+ --gap-0: 0px;
3
+ } .date-input__nativeInput_1n1gh {
4
+ opacity: 0;
5
+ position: absolute;
6
+ top: var(--gap-0);
7
+ left: var(--gap-0);
8
+ width: 100%;
9
+ height: 100%;
10
+ -webkit-appearance: none;
11
+ -moz-appearance: none;
12
+ appearance: none;
13
+ z-index: 1
14
+ } .date-input__nativeInput_1n1gh::-webkit-calendar-picker-indicator {
15
+ display: none;
16
+ } .date-input__nativeInput_1n1gh::-webkit-inner-spin-button {
17
+ display: none;
18
+ }
@@ -0,0 +1,2 @@
1
+ export * from './Component';
2
+ export * from './utils';
@@ -0,0 +1,21 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ var Component = require('./Component.js');
6
+ var format = require('./utils/format.js');
7
+ var nativeSupports = require('./utils/native-supports.js');
8
+
9
+
10
+
11
+ exports.DateInput = Component.DateInput;
12
+ exports.DATE_FORMAT = format.DATE_FORMAT;
13
+ exports.DATE_MASK = format.DATE_MASK;
14
+ exports.NATIVE_DATE_FORMAT = format.NATIVE_DATE_FORMAT;
15
+ exports.format = format.format;
16
+ exports.formatDate = format.formatDate;
17
+ exports.isCompleteDateInput = format.isCompleteDateInput;
18
+ exports.isValid = format.isValid;
19
+ exports.parseDateString = format.parseDateString;
20
+ exports.isInputDateSupported = nativeSupports.isInputDateSupported;
21
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;"}
@@ -0,0 +1,8 @@
1
+ 'use strict';
2
+
3
+ require('./index.css');
4
+
5
+ var styles = {"nativeInput":"date-input__nativeInput_1n1gh"};
6
+
7
+ module.exports = styles;
8
+ //# sourceMappingURL=index.module.css.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.module.css.js","sources":["src/index.module.css"],"sourcesContent":["@import '@alfalab/core-components-vars/src/no-dynamic-mixins-index.css';\n\n.nativeInput {\n opacity: 0;\n position: absolute;\n top: var(--gap-0);\n left: var(--gap-0);\n width: 100%;\n height: 100%;\n appearance: none;\n z-index: 1;\n\n &::-webkit-calendar-picker-indicator {\n display: none;\n }\n &::-webkit-inner-spin-button {\n display: none;\n }\n}\n"],"names":[],"mappings":";;;;AAEgB,aAAe,CAAC,aAAa,CAAC,+BAA+B,CAAC;;;;"}
@@ -0,0 +1,8 @@
1
+ export declare const DATE_FORMAT = "dd.MM.yyyy";
2
+ export declare const NATIVE_DATE_FORMAT = "yyyy-MM-dd";
3
+ export declare const DATE_MASK: (string | RegExp)[];
4
+ export declare const isCompleteDateInput: (input: string) => boolean;
5
+ export declare const formatDate: (date: Date | number, dateFormat?: string) => string;
6
+ export declare const parseDateString: (value: string, dateFormat?: string) => Date;
7
+ export declare const isValid: (inputValue?: string) => boolean;
8
+ export declare const format: (value: string) => string;
@@ -0,0 +1,58 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ var dateFnsFormat = require('date-fns/format');
6
+ var dateFnsIsValid = require('date-fns/isValid');
7
+ var parse = require('date-fns/parse');
8
+
9
+ function _interopDefaultCompat (e) { return e && typeof e === 'object' && 'default' in e ? e : { default: e }; }
10
+
11
+ var dateFnsFormat__default = /*#__PURE__*/_interopDefaultCompat(dateFnsFormat);
12
+ var dateFnsIsValid__default = /*#__PURE__*/_interopDefaultCompat(dateFnsIsValid);
13
+ var parse__default = /*#__PURE__*/_interopDefaultCompat(parse);
14
+
15
+ var DATE_FORMAT = 'dd.MM.yyyy';
16
+ var NATIVE_DATE_FORMAT = 'yyyy-MM-dd';
17
+ var DATE_MASK = [/\d/, /\d/, '.', /\d/, /\d/, '.', /\d/, /\d/, /\d/, /\d/];
18
+ var isCompleteDateInput = function (input) { return input.length === DATE_MASK.length; };
19
+ var formatDate = function (date, dateFormat) {
20
+ if (dateFormat === void 0) { dateFormat = DATE_FORMAT; }
21
+ return dateFnsFormat__default.default(date, dateFormat);
22
+ };
23
+ var parseDateString = function (value, dateFormat) {
24
+ if (dateFormat === void 0) { dateFormat = DATE_FORMAT; }
25
+ return parse__default.default(value, dateFormat, new Date());
26
+ };
27
+ var isValid = function (inputValue) {
28
+ return !inputValue || (isCompleteDateInput(inputValue) && dateFnsIsValid__default.default(parseDateString(inputValue)));
29
+ };
30
+ var format = function (value) {
31
+ return value
32
+ .replace(/^(\d\d)(\d)$/, '$1.$2') // 121 => 12.1
33
+ .replace(/^(\d\d)\.(\d\d)(\d)$/, '$1.$2.$3') // 12.122 => 12.12.2
34
+ .replace(/^(\d\d)\d\.(.*)/, '$1.$2') // 123.12.2005 => 12.12.2005
35
+ .replace(/^(\d\d\.\d\d)\d\.(.*)/, '$1.$2') // 12.123.2005 => 12.12.2005
36
+ .replace(/^(\d\d\.\d\d\.\d\d\d\d).*/, '$1') // 12.12.20056 => 12.12.2005
37
+ .replace(/\.$/, '') // 12. => 12
38
+ .replace(/^(\d\d\.\d\d)(\d\d\d\d)/, '$1.$2') // 12.122005 => 12.12.2005
39
+ .replace(/^(\d\d)(\d\d\.\d\d\d\d)/, '$1.$2') // 1212.2005 => 12.12.2005
40
+ .replace(/^(\d\.\d\d\.\d\d\d\d)([0-9]*)/, '$1') // 1.12.2005123123 => 01.12.2005
41
+ .replace(/^(\d\d\.\d\.\d\d\d\d)([0-9]*)/, '$1') // 01.2.20055125125 => 01.2.2005
42
+ .replace(/^(\d\.\d\.\d\d\d\d)([0-9]*)/, '$1') // 1.2.20055125125 => 1.2.2005
43
+ .replace(/^(\d)\.(\d\d)([0-9]*)\.(\d\d\d\d)/, '$1.$2.$4') // 1.123123.2005 => 1.12.2005
44
+ .replace(/^(\d\d)\.()\.(\d\d\d\d)([0-9]*)/, '$1.$2.$3') // 01..2005123123 => 01..2005
45
+ .replace(/^(\d)\.()\.(\d\d\d\d)([0-9]*)/, '$1.$2.$3') // 1..2005123123 => 1..2005
46
+ .replace(/^()\.()\.(\d\d\d\d)([0-9]*)/, '$1.$2.$3') // ..2005123123 => ..2005
47
+ .replace(/^()\.(\d)\.(\d\d\d\d)([0-9]*)/, '$1.$2.$3');
48
+ }; // .2.2005123123 => .2.2005
49
+
50
+ exports.DATE_FORMAT = DATE_FORMAT;
51
+ exports.DATE_MASK = DATE_MASK;
52
+ exports.NATIVE_DATE_FORMAT = NATIVE_DATE_FORMAT;
53
+ exports.format = format;
54
+ exports.formatDate = formatDate;
55
+ exports.isCompleteDateInput = isCompleteDateInput;
56
+ exports.isValid = isValid;
57
+ exports.parseDateString = parseDateString;
58
+ //# sourceMappingURL=format.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"format.js","sources":["../../src/utils/format.ts"],"sourcesContent":["import dateFnsFormat from 'date-fns/format';\nimport dateFnsIsValid from 'date-fns/isValid';\nimport parse from 'date-fns/parse';\n\nexport const DATE_FORMAT = 'dd.MM.yyyy';\nexport const NATIVE_DATE_FORMAT = 'yyyy-MM-dd';\nexport const DATE_MASK = [/\\d/, /\\d/, '.', /\\d/, /\\d/, '.', /\\d/, /\\d/, /\\d/, /\\d/];\n\nexport const isCompleteDateInput = (input: string) => input.length === DATE_MASK.length;\n\nexport const formatDate = (date: Date | number, dateFormat = DATE_FORMAT) =>\n dateFnsFormat(date, dateFormat);\n\nexport const parseDateString = (value: string, dateFormat = DATE_FORMAT) =>\n parse(value, dateFormat, new Date());\n\nexport const isValid = (inputValue?: string) =>\n !inputValue || (isCompleteDateInput(inputValue) && dateFnsIsValid(parseDateString(inputValue)));\n\nexport const format = (value: string): string =>\n value\n .replace(/^(\\d\\d)(\\d)$/, '$1.$2') // 121 => 12.1\n .replace(/^(\\d\\d)\\.(\\d\\d)(\\d)$/, '$1.$2.$3') // 12.122 => 12.12.2\n .replace(/^(\\d\\d)\\d\\.(.*)/, '$1.$2') // 123.12.2005 => 12.12.2005\n .replace(/^(\\d\\d\\.\\d\\d)\\d\\.(.*)/, '$1.$2') // 12.123.2005 => 12.12.2005\n .replace(/^(\\d\\d\\.\\d\\d\\.\\d\\d\\d\\d).*/, '$1') // 12.12.20056 => 12.12.2005\n .replace(/\\.$/, '') // 12. => 12\n .replace(/^(\\d\\d\\.\\d\\d)(\\d\\d\\d\\d)/, '$1.$2') // 12.122005 => 12.12.2005\n .replace(/^(\\d\\d)(\\d\\d\\.\\d\\d\\d\\d)/, '$1.$2') // 1212.2005 => 12.12.2005\n .replace(/^(\\d\\.\\d\\d\\.\\d\\d\\d\\d)([0-9]*)/, '$1') // 1.12.2005123123 => 01.12.2005\n .replace(/^(\\d\\d\\.\\d\\.\\d\\d\\d\\d)([0-9]*)/, '$1') // 01.2.20055125125 => 01.2.2005\n .replace(/^(\\d\\.\\d\\.\\d\\d\\d\\d)([0-9]*)/, '$1') // 1.2.20055125125 => 1.2.2005\n .replace(/^(\\d)\\.(\\d\\d)([0-9]*)\\.(\\d\\d\\d\\d)/, '$1.$2.$4') // 1.123123.2005 => 1.12.2005\n .replace(/^(\\d\\d)\\.()\\.(\\d\\d\\d\\d)([0-9]*)/, '$1.$2.$3') // 01..2005123123 => 01..2005\n .replace(/^(\\d)\\.()\\.(\\d\\d\\d\\d)([0-9]*)/, '$1.$2.$3') // 1..2005123123 => 1..2005\n .replace(/^()\\.()\\.(\\d\\d\\d\\d)([0-9]*)/, '$1.$2.$3') // ..2005123123 => ..2005\n .replace(/^()\\.(\\d)\\.(\\d\\d\\d\\d)([0-9]*)/, '$1.$2.$3'); // .2.2005123123 => .2.2005\n"],"names":["dateFnsFormat","parse","dateFnsIsValid"],"mappings":";;;;;;;;;;;;;;AAIO,IAAM,WAAW,GAAG;AACpB,IAAM,kBAAkB,GAAG;AACrB,IAAA,SAAS,GAAG,CAAC,IAAI,EAAE,IAAI,EAAE,GAAG,EAAE,IAAI,EAAE,IAAI,EAAE,GAAG,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI;AAErE,IAAA,mBAAmB,GAAG,UAAC,KAAa,EAAK,EAAA,OAAA,KAAK,CAAC,MAAM,KAAK,SAAS,CAAC,MAAM,CAAA;AAE1E,IAAA,UAAU,GAAG,UAAC,IAAmB,EAAE,UAAwB,EAAA;AAAxB,IAAA,IAAA,UAAA,KAAA,MAAA,EAAA,EAAA,UAAwB,GAAA,WAAA,CAAA;AACpE,IAAA,OAAAA,8BAAa,CAAC,IAAI,EAAE,UAAU,CAAC;AAA/B;AAES,IAAA,eAAe,GAAG,UAAC,KAAa,EAAE,UAAwB,EAAA;AAAxB,IAAA,IAAA,UAAA,KAAA,MAAA,EAAA,EAAA,UAAwB,GAAA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@@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ var format = require('./format.js');
6
+ var nativeSupports = require('./native-supports.js');
7
+
8
+
9
+
10
+ exports.DATE_FORMAT = format.DATE_FORMAT;
11
+ exports.DATE_MASK = format.DATE_MASK;
12
+ exports.NATIVE_DATE_FORMAT = format.NATIVE_DATE_FORMAT;
13
+ exports.format = format.format;
14
+ exports.formatDate = format.formatDate;
15
+ exports.isCompleteDateInput = format.isCompleteDateInput;
16
+ exports.isValid = format.isValid;
17
+ exports.parseDateString = format.parseDateString;
18
+ exports.isInputDateSupported = nativeSupports.isInputDateSupported;
19
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;"}
@@ -0,0 +1,4 @@
1
+ /**
2
+ * Возвращает `true`, если поддерживается `input[type="date"]`
3
+ */
4
+ export declare function isInputDateSupported(): boolean;
@@ -0,0 +1,17 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ /**
6
+ * Возвращает `true`, если поддерживается `input[type="date"]`
7
+ */
8
+ function isInputDateSupported() {
9
+ var input = document.createElement('input');
10
+ var value = 'a';
11
+ input.setAttribute('type', 'date');
12
+ input.setAttribute('value', value);
13
+ return input.value !== value;
14
+ }
15
+
16
+ exports.isInputDateSupported = isInputDateSupported;
17
+ //# sourceMappingURL=native-supports.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"native-supports.js","sources":["../../src/utils/native-supports.ts"],"sourcesContent":["/**\n * Возвращает `true`, если поддерживается `input[type=\"date\"]`\n */\nexport function isInputDateSupported() {\n const input = document.createElement('input');\n const value = 'a';\n\n input.setAttribute('type', 'date');\n input.setAttribute('value', value);\n\n return input.value !== value;\n}\n"],"names":[],"mappings":";;;;AAAA;;AAEG;SACa,oBAAoB,GAAA;IAChC,IAAM,KAAK,GAAG,QAAQ,CAAC,aAAa,CAAC,OAAO,CAAC;IAC7C,IAAM,KAAK,GAAG,GAAG;AAEjB,IAAA,KAAK,CAAC,YAAY,CAAC,MAAM,EAAE,MAAM,CAAC;AAClC,IAAA,KAAK,CAAC,YAAY,CAAC,OAAO,EAAE,KAAK,CAAC;AAElC,IAAA,OAAO,KAAK,CAAC,KAAK,KAAK,KAAK;AAChC;;;;"}
package/esm/index.css CHANGED
@@ -1,6 +1,6 @@
1
1
  :root {
2
2
  --gap-0: 0px;
3
- } .date-input__nativeInput_4b3ht {
3
+ } .date-input__nativeInput_1n1gh {
4
4
  opacity: 0;
5
5
  position: absolute;
6
6
  top: var(--gap-0);
@@ -11,8 +11,8 @@
11
11
  -moz-appearance: none;
12
12
  appearance: none;
13
13
  z-index: 1
14
- } .date-input__nativeInput_4b3ht::-webkit-calendar-picker-indicator {
14
+ } .date-input__nativeInput_1n1gh::-webkit-calendar-picker-indicator {
15
15
  display: none;
16
- } .date-input__nativeInput_4b3ht::-webkit-inner-spin-button {
16
+ } .date-input__nativeInput_1n1gh::-webkit-inner-spin-button {
17
17
  display: none;
18
18
  }
@@ -1,6 +1,6 @@
1
1
  import './index.css';
2
2
 
3
- var styles = {"nativeInput":"date-input__nativeInput_4b3ht"};
3
+ var styles = {"nativeInput":"date-input__nativeInput_1n1gh"};
4
4
 
5
5
  export { styles as default };
6
6
  //# sourceMappingURL=index.module.css.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.module.css.js","sources":["src/index.module.css"],"sourcesContent":["@import '@alfalab/core-components-vars/src/index.css';\n\n.nativeInput {\n opacity: 0;\n position: absolute;\n top: var(--gap-0);\n left: var(--gap-0);\n width: 100%;\n height: 100%;\n appearance: none;\n z-index: 1;\n\n &::-webkit-calendar-picker-indicator {\n display: none;\n }\n &::-webkit-inner-spin-button {\n display: none;\n }\n}\n"],"names":[],"mappings":";;AAEgB,aAAe,CAAC,aAAa,CAAC,+BAA+B,CAAC;;;;"}
1
+ {"version":3,"file":"index.module.css.js","sources":["src/index.module.css"],"sourcesContent":["@import '@alfalab/core-components-vars/src/no-dynamic-mixins-index.css';\n\n.nativeInput {\n opacity: 0;\n position: absolute;\n top: var(--gap-0);\n left: var(--gap-0);\n width: 100%;\n height: 100%;\n appearance: none;\n z-index: 1;\n\n &::-webkit-calendar-picker-indicator {\n display: none;\n }\n &::-webkit-inner-spin-button {\n display: none;\n }\n}\n"],"names":[],"mappings":";;AAEgB,aAAe,CAAC,aAAa,CAAC,+BAA+B,CAAC;;;;"}
package/index.css CHANGED
@@ -1,6 +1,6 @@
1
1
  :root {
2
2
  --gap-0: 0px;
3
- } .date-input__nativeInput_4b3ht {
3
+ } .date-input__nativeInput_1n1gh {
4
4
  opacity: 0;
5
5
  position: absolute;
6
6
  top: var(--gap-0);
@@ -11,8 +11,8 @@
11
11
  -moz-appearance: none;
12
12
  appearance: none;
13
13
  z-index: 1
14
- } .date-input__nativeInput_4b3ht::-webkit-calendar-picker-indicator {
14
+ } .date-input__nativeInput_1n1gh::-webkit-calendar-picker-indicator {
15
15
  display: none;
16
- } .date-input__nativeInput_4b3ht::-webkit-inner-spin-button {
16
+ } .date-input__nativeInput_1n1gh::-webkit-inner-spin-button {
17
17
  display: none;
18
18
  }
@@ -2,7 +2,7 @@
2
2
 
3
3
  require('./index.css');
4
4
 
5
- var styles = {"nativeInput":"date-input__nativeInput_4b3ht"};
5
+ var styles = {"nativeInput":"date-input__nativeInput_1n1gh"};
6
6
 
7
7
  module.exports = styles;
8
8
  //# sourceMappingURL=index.module.css.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.module.css.js","sources":["src/index.module.css"],"sourcesContent":["@import '@alfalab/core-components-vars/src/index.css';\n\n.nativeInput {\n opacity: 0;\n position: absolute;\n top: var(--gap-0);\n left: var(--gap-0);\n width: 100%;\n height: 100%;\n appearance: none;\n z-index: 1;\n\n &::-webkit-calendar-picker-indicator {\n display: none;\n }\n &::-webkit-inner-spin-button {\n display: none;\n }\n}\n"],"names":[],"mappings":";;;;AAEgB,aAAe,CAAC,aAAa,CAAC,+BAA+B,CAAC;;;;"}
1
+ {"version":3,"file":"index.module.css.js","sources":["src/index.module.css"],"sourcesContent":["@import '@alfalab/core-components-vars/src/no-dynamic-mixins-index.css';\n\n.nativeInput {\n opacity: 0;\n position: absolute;\n top: var(--gap-0);\n left: var(--gap-0);\n width: 100%;\n height: 100%;\n appearance: none;\n z-index: 1;\n\n &::-webkit-calendar-picker-indicator {\n display: none;\n }\n &::-webkit-inner-spin-button {\n display: none;\n }\n}\n"],"names":[],"mappings":";;;;AAEgB,aAAe,CAAC,aAAa,CAAC,+BAA+B,CAAC;;;;"}
package/modern/index.css CHANGED
@@ -1,6 +1,6 @@
1
1
  :root {
2
2
  --gap-0: 0px;
3
- } .date-input__nativeInput_4b3ht {
3
+ } .date-input__nativeInput_1n1gh {
4
4
  opacity: 0;
5
5
  position: absolute;
6
6
  top: var(--gap-0);
@@ -11,8 +11,8 @@
11
11
  -moz-appearance: none;
12
12
  appearance: none;
13
13
  z-index: 1
14
- } .date-input__nativeInput_4b3ht::-webkit-calendar-picker-indicator {
14
+ } .date-input__nativeInput_1n1gh::-webkit-calendar-picker-indicator {
15
15
  display: none;
16
- } .date-input__nativeInput_4b3ht::-webkit-inner-spin-button {
16
+ } .date-input__nativeInput_1n1gh::-webkit-inner-spin-button {
17
17
  display: none;
18
18
  }
@@ -1,6 +1,6 @@
1
1
  import './index.css';
2
2
 
3
- const styles = {"nativeInput":"date-input__nativeInput_4b3ht"};
3
+ const styles = {"nativeInput":"date-input__nativeInput_1n1gh"};
4
4
 
5
5
  export { styles as default };
6
6
  //# sourceMappingURL=index.module.css.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.module.css.js","sources":["src/index.module.css"],"sourcesContent":["@import '@alfalab/core-components-vars/src/index.css';\n\n.nativeInput {\n opacity: 0;\n position: absolute;\n top: var(--gap-0);\n left: var(--gap-0);\n width: 100%;\n height: 100%;\n appearance: none;\n z-index: 1;\n\n &::-webkit-calendar-picker-indicator {\n display: none;\n }\n &::-webkit-inner-spin-button {\n display: none;\n }\n}\n"],"names":[],"mappings":";;AAEgB,eAAe,CAAC,aAAa,CAAC,+BAA+B,CAAC;;;;"}
1
+ {"version":3,"file":"index.module.css.js","sources":["src/index.module.css"],"sourcesContent":["@import '@alfalab/core-components-vars/src/no-dynamic-mixins-index.css';\n\n.nativeInput {\n opacity: 0;\n position: absolute;\n top: var(--gap-0);\n left: var(--gap-0);\n width: 100%;\n height: 100%;\n appearance: none;\n z-index: 1;\n\n &::-webkit-calendar-picker-indicator {\n display: none;\n }\n &::-webkit-inner-spin-button {\n display: none;\n }\n}\n"],"names":[],"mappings":";;AAEgB,eAAe,CAAC,aAAa,CAAC,+BAA+B,CAAC;;;;"}
@@ -1,3 +1,5 @@
1
+
2
+
1
3
  .nativeInput {
2
4
  opacity: 0;
3
5
  position: absolute;
@@ -10,11 +12,9 @@
10
12
  appearance: none;
11
13
  z-index: 1
12
14
  }
13
-
14
15
  .nativeInput::-webkit-calendar-picker-indicator {
15
16
  display: none;
16
17
  }
17
-
18
18
  .nativeInput::-webkit-inner-spin-button {
19
19
  display: none;
20
20
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alfalab/core-components-date-input",
3
- "version": "5.0.0",
3
+ "version": "5.1.0-snapshot-92b8690",
4
4
  "description": "",
5
5
  "keywords": [],
6
6
  "license": "MIT",
@@ -10,7 +10,7 @@
10
10
  "main": "index.js",
11
11
  "module": "./esm/index.js",
12
12
  "dependencies": {
13
- "@alfalab/core-components-input": "^16.0.0",
13
+ "@alfalab/core-components-input": "16.1.0-snapshot-92b8690",
14
14
  "date-fns": "^2.16.1",
15
15
  "react-merge-refs": "^1.1.0",
16
16
  "tslib": "^2.4.0"
@@ -23,6 +23,6 @@
23
23
  "access": "public",
24
24
  "directory": "dist"
25
25
  },
26
- "themesVersion": "14.0.0",
27
- "varsVersion": "10.0.0"
26
+ "themesVersion": "14.1.0-snapshot-92b8690",
27
+ "varsVersion": "10.1.0-snapshot-92b8690"
28
28
  }
@@ -1,4 +1,4 @@
1
- @import '@alfalab/core-components-vars/src/index.css';
1
+ @import '@alfalab/core-components-vars/src/no-dynamic-mixins-index.css';
2
2
 
3
3
  .nativeInput {
4
4
  opacity: 0;