asma-ui-datetime 0.0.76 → 0.0.78

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.
@@ -1,9 +1,10 @@
1
1
  import type { StyledTimePickerProps } from './types';
2
2
  import { type PopupState } from 'material-ui-popup-state/hooks';
3
- import type { ChangeEvent } from 'react';
3
+ import { type ChangeEvent } from 'react';
4
4
  export declare const TimePickerInput: React.FC<StyledTimePickerProps & {
5
5
  popupState: PopupState;
6
6
  handleChange: (e: ChangeEvent<HTMLTextAreaElement | HTMLInputElement>) => void;
7
7
  isValidTime: boolean;
8
+ isValidEndTime: boolean;
8
9
  localValue: string;
9
10
  }>;
@@ -1,6 +1,7 @@
1
1
  import type { ReactNode } from 'react';
2
2
  export declare const HelperText: React.FC<{
3
3
  isValidTime: boolean;
4
+ isValidEndTime: boolean;
4
5
  error?: boolean;
5
6
  localization: 'en' | 'no';
6
7
  helperText?: ReactNode;
@@ -1,12 +1,15 @@
1
1
  import type PopupState from 'material-ui-popup-state';
2
2
  import type { ReactNode } from 'react';
3
+ /**
4
+ * @param notBeforeTime - Start time of the range. Selected time must be after this value.
5
+ */
3
6
  export type StyledTimePickerProps = {
7
+ value?: Date;
8
+ onSelect: (date: Date | undefined) => void;
4
9
  placeholder?: string;
5
10
  disabled?: boolean;
6
11
  readOnly?: boolean;
7
12
  inputClassName?: string;
8
- value?: Date;
9
- onSelect: (date: Date | undefined) => void;
10
13
  dataTest: string;
11
14
  width?: number;
12
15
  error?: boolean;
@@ -14,5 +17,6 @@ export type StyledTimePickerProps = {
14
17
  label?: string;
15
18
  locale?: 'no' | 'en';
16
19
  title?: string;
20
+ notBeforeTime?: Date;
17
21
  };
18
22
  export type IPopupStateType = ReturnType<typeof PopupState>;
package/package.json CHANGED
@@ -1,114 +1,114 @@
1
1
  {
2
- "name": "asma-ui-datetime",
3
- "publishConfig": {
4
- "access": "public"
5
- },
6
- "version": "0.0.76",
7
- "type": "module",
8
- "files": [
9
- "dist/**/*"
10
- ],
11
- "keywords": [],
12
- "author": "asma-team",
13
- "types": "./dist/index.d.ts",
14
- "main": "./dist/asma-ui-datetime.es.js",
15
- "module": "./dist/asma-ui-datetime.es.js",
16
- "exports": {
17
- ".": {
18
- "import": {
19
- "types": "./dist/index.d.ts",
20
- "default": "./dist/asma-ui-datetime.es.js"
21
- }
2
+ "name": "asma-ui-datetime",
3
+ "publishConfig": {
4
+ "access": "public"
22
5
  },
23
- "./dist/style.css": "./dist/style.css"
24
- },
25
- "license": "UNLICENSED",
26
- "dependencies": {
27
- "@emotion/react": "^11.11.1",
28
- "@emotion/styled": "^11.11.0",
29
- "@fontsource/roboto": "^5.0.4",
30
- "@mui/material": "^5.13.7",
31
- "@react-input/mask": "^1.2.5",
32
- "clsx": "^1.2.1",
33
- "date-fns": "^3.6.0",
34
- "lodash-es": "^4.17.21",
35
- "material-ui-popup-state": "^5.1.2",
36
- "node": "18.17.0",
37
- "react": "^18.2.0",
38
- "react-day-picker": "^8.10.1",
39
- "react-dom": "^18.2.0"
40
- },
41
- "devDependencies": {
42
- "@changesets/cli": "^2.26.2",
43
- "@rollup/plugin-terser": "^0.4.3",
44
- "@storybook/addon-a11y": "^7.6.9",
45
- "@storybook/addon-essentials": "^7.6.9",
46
- "@storybook/addon-interactions": "^7.6.9",
47
- "@storybook/addon-links": "^7.6.9",
48
- "@storybook/addon-mdx-gfm": "^7.6.9",
49
- "@storybook/addon-styling": "^1.3.7",
50
- "@storybook/addons": "^7.6.9",
51
- "@storybook/blocks": "^7.6.9",
52
- "@storybook/manager-api": "^7.6.9",
53
- "@storybook/preset-create-react-app": "^7.6.9",
54
- "@storybook/react": "^7.6.9",
55
- "@storybook/react-vite": "^7.6.9",
56
- "@storybook/test-runner": "^0.16.0",
57
- "@storybook/testing-library": "^0.2.2",
58
- "@storybook/theming": "^7.6.9",
59
- "@types/lodash-es": "^4.17.7",
60
- "@types/node": "^18.0.3",
61
- "@types/react": "^18.0.37",
62
- "@types/react-dom": "^18.0.11",
63
- "@typescript-eslint/eslint-plugin": "^5.59.0",
64
- "@typescript-eslint/parser": "^5.59.0",
65
- "@vitejs/plugin-react": "^4.0.0",
66
- "autoprefixer": "^10.4.14",
67
- "axe-playwright": "^1.2.3",
68
- "eslint": "^8.38.0",
69
- "eslint-plugin-react-hooks": "^4.6.0",
70
- "eslint-plugin-react-refresh": "^0.3.4",
71
- "eslint-plugin-storybook": "^0.6.15",
72
- "postcss": "^8.4.24",
73
- "prop-types": "^15.8.1",
74
- "rollup-plugin-typescript2": "^0.35.0",
75
- "sass": "^1.77.5",
76
- "storybook": "^7.6.9",
77
- "storybook-addon-themes": "^6.1.0",
78
- "tailwind-merge": "^2.4.0",
79
- "tailwind-scrollbar": "^3.1.0",
80
- "tailwindcss": "^3.3.2",
81
- "typescript": "^5.0.2",
82
- "typescript-plugin-css-modules": "^5.0.1",
83
- "vite": "^4.3.9",
84
- "vite-plugin-dts": "^3.1.1",
85
- "vite-tsconfig-paths": "^4.2.0"
86
- },
87
- "peerDependencies": {
88
- "@emotion/react": "^11.*",
89
- "@emotion/styled": "^11.*",
90
- "@mui/material": "^5.*",
91
- "immer": "^9.*",
92
- "react": "^18.*",
93
- "react-dom": "^18.*"
94
- },
95
- "resolutions": {
96
- "@types/node": "18.0.3",
97
- "node": "18.17.0"
98
- },
99
- "scripts": {
100
- "dev": "vite",
101
- "build": "npx tsc && rm -rf ./dist && vite build",
102
- "preview": "vite preview",
103
- "version": "echo $npm_package_version",
104
- "lint:fix": "eslint ./src --ext .jsx,.js,.ts,.tsx --quiet --fix --ignore-path ./.gitignore",
105
- "lint:format": "prettier --loglevel warn --write \"./**/*.{js,jsx,ts,tsx,css,md,json}\" ",
106
- "lint": "pnpm lint:format && pnpm lint:fix ",
107
- "prettier": "prettier --write src//**/*.{ts,tsx,scss} --config ./.prettierrc",
108
- "storybook": "storybook dev -p 6006",
109
- "storybook:no-browser": "storybook dev -p 6006 --no-open",
110
- "storybook:node18": "export NODE_OPTIONS=--openssl-legacy-provider && storybook dev -p 6006",
111
- "storybook:node18:win": "set NODE_OPTIONS=--openssl-legacy-provider && storybook dev -p 6006",
112
- "build-storybook": "export NODE_OPTIONS=--max_old_space_size=6240 && storybook build"
113
- }
114
- }
6
+ "version": "0.0.78",
7
+ "type": "module",
8
+ "files": [
9
+ "dist/**/*"
10
+ ],
11
+ "keywords": [],
12
+ "author": "asma-team",
13
+ "types": "./dist/index.d.ts",
14
+ "main": "./dist/asma-ui-datetime.es.js",
15
+ "module": "./dist/asma-ui-datetime.es.js",
16
+ "exports": {
17
+ ".": {
18
+ "import": {
19
+ "types": "./dist/index.d.ts",
20
+ "default": "./dist/asma-ui-datetime.es.js"
21
+ }
22
+ },
23
+ "./dist/style.css": "./dist/style.css"
24
+ },
25
+ "scripts": {
26
+ "dev": "vite",
27
+ "build": "npx tsc && rm -rf ./dist && vite build",
28
+ "preview": "vite preview",
29
+ "version": "echo $npm_package_version",
30
+ "lint:fix": "eslint ./src --ext .jsx,.js,.ts,.tsx --quiet --fix --ignore-path ./.gitignore",
31
+ "lint:format": "prettier --loglevel warn --write \"./**/*.{js,jsx,ts,tsx,css,md,json}\" ",
32
+ "lint": "pnpm lint:format && pnpm lint:fix ",
33
+ "prettier": "prettier --write src//**/*.{ts,tsx,scss} --config ./.prettierrc",
34
+ "storybook": "storybook dev -p 6006",
35
+ "storybook:no-browser": "storybook dev -p 6006 --no-open",
36
+ "storybook:node18": "export NODE_OPTIONS=--openssl-legacy-provider && storybook dev -p 6006",
37
+ "storybook:node18:win": "set NODE_OPTIONS=--openssl-legacy-provider && storybook dev -p 6006",
38
+ "build-storybook": "export NODE_OPTIONS=--max_old_space_size=6240 && storybook build"
39
+ },
40
+ "license": "UNLICENSED",
41
+ "dependencies": {
42
+ "@emotion/react": "^11.11.1",
43
+ "@emotion/styled": "^11.11.0",
44
+ "@fontsource/roboto": "^5.0.4",
45
+ "@mui/material": "^5.13.7",
46
+ "@react-input/mask": "^1.2.5",
47
+ "clsx": "^1.2.1",
48
+ "date-fns": "^3.6.0",
49
+ "lodash-es": "^4.17.21",
50
+ "material-ui-popup-state": "^5.1.2",
51
+ "node": "18.17.0",
52
+ "react": "^18.2.0",
53
+ "react-day-picker": "^8.10.1",
54
+ "react-dom": "^18.2.0"
55
+ },
56
+ "devDependencies": {
57
+ "@changesets/cli": "^2.26.2",
58
+ "@rollup/plugin-terser": "^0.4.3",
59
+ "@storybook/addon-a11y": "^7.6.9",
60
+ "@storybook/addon-essentials": "^7.6.9",
61
+ "@storybook/addon-interactions": "^7.6.9",
62
+ "@storybook/addon-links": "^7.6.9",
63
+ "@storybook/addon-mdx-gfm": "^7.6.9",
64
+ "@storybook/addon-styling": "^1.3.7",
65
+ "@storybook/addons": "^7.6.9",
66
+ "@storybook/blocks": "^7.6.9",
67
+ "@storybook/manager-api": "^7.6.9",
68
+ "@storybook/preset-create-react-app": "^7.6.9",
69
+ "@storybook/react": "^7.6.9",
70
+ "@storybook/react-vite": "^7.6.9",
71
+ "@storybook/test-runner": "^0.16.0",
72
+ "@storybook/testing-library": "^0.2.2",
73
+ "@storybook/theming": "^7.6.9",
74
+ "@types/lodash-es": "^4.17.7",
75
+ "@types/node": "^18.0.3",
76
+ "@types/react": "^18.0.37",
77
+ "@types/react-dom": "^18.0.11",
78
+ "@typescript-eslint/eslint-plugin": "^5.59.0",
79
+ "@typescript-eslint/parser": "^5.59.0",
80
+ "@vitejs/plugin-react": "^4.0.0",
81
+ "autoprefixer": "^10.4.14",
82
+ "axe-playwright": "^1.2.3",
83
+ "eslint": "^8.38.0",
84
+ "eslint-plugin-react-hooks": "^4.6.0",
85
+ "eslint-plugin-react-refresh": "^0.3.4",
86
+ "eslint-plugin-storybook": "^0.6.15",
87
+ "postcss": "^8.4.24",
88
+ "prop-types": "^15.8.1",
89
+ "rollup-plugin-typescript2": "^0.35.0",
90
+ "sass": "^1.77.5",
91
+ "storybook": "^7.6.9",
92
+ "storybook-addon-themes": "^6.1.0",
93
+ "tailwind-merge": "^2.4.0",
94
+ "tailwind-scrollbar": "^3.1.0",
95
+ "tailwindcss": "^3.3.2",
96
+ "typescript": "^5.0.2",
97
+ "typescript-plugin-css-modules": "^5.0.1",
98
+ "vite": "^4.3.9",
99
+ "vite-plugin-dts": "^3.1.1",
100
+ "vite-tsconfig-paths": "^4.2.0"
101
+ },
102
+ "peerDependencies": {
103
+ "@emotion/react": "^11.*",
104
+ "@emotion/styled": "^11.*",
105
+ "@mui/material": "^5.*",
106
+ "immer": "^9.*",
107
+ "react": "^18.*",
108
+ "react-dom": "^18.*"
109
+ },
110
+ "resolutions": {
111
+ "@types/node": "18.0.3",
112
+ "node": "18.17.0"
113
+ }
114
+ }