@vchasno/ui-kit 0.2.7 → 0.2.9

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.
Files changed (40) hide show
  1. package/CHANGELOG.md +52 -27
  2. package/dist/Datepicker/index.cjs.js +10376 -0
  3. package/dist/Datepicker/index.cjs.js.map +1 -0
  4. package/dist/Datepicker/index.js.map +1 -1
  5. package/dist/Datepicker/types/components/BubbleBox/BubbleBox.d.ts +17 -0
  6. package/dist/Datepicker/types/components/BubbleBox/index.d.ts +2 -0
  7. package/dist/Datepicker/types/components/BubbleBox/useClientRect.d.ts +5 -0
  8. package/dist/Datepicker/types/components/BubbleBox/utils.d.ts +1 -0
  9. package/dist/Datepicker/types/components/Pagination/Pagination.d.ts +3 -0
  10. package/dist/Datepicker/types/components/index.d.ts +2 -0
  11. package/dist/Select/index.cjs.js +7746 -0
  12. package/dist/Select/index.cjs.js.map +1 -0
  13. package/dist/Select/index.js +12 -7
  14. package/dist/Select/index.js.map +1 -1
  15. package/dist/Select/types/components/BubbleBox/BubbleBox.d.ts +17 -0
  16. package/dist/Select/types/components/BubbleBox/index.d.ts +2 -0
  17. package/dist/Select/types/components/BubbleBox/useClientRect.d.ts +5 -0
  18. package/dist/Select/types/components/BubbleBox/utils.d.ts +1 -0
  19. package/dist/Select/types/components/Pagination/Pagination.d.ts +3 -0
  20. package/dist/Select/types/components/index.d.ts +2 -0
  21. package/dist/SelectCreatable/index.cjs.js +7835 -0
  22. package/dist/SelectCreatable/index.cjs.js.map +1 -0
  23. package/dist/SelectCreatable/index.js +12 -7
  24. package/dist/SelectCreatable/index.js.map +1 -1
  25. package/dist/SelectCreatable/types/components/BubbleBox/BubbleBox.d.ts +17 -0
  26. package/dist/SelectCreatable/types/components/BubbleBox/index.d.ts +2 -0
  27. package/dist/SelectCreatable/types/components/BubbleBox/useClientRect.d.ts +5 -0
  28. package/dist/SelectCreatable/types/components/BubbleBox/utils.d.ts +1 -0
  29. package/dist/SelectCreatable/types/components/Pagination/Pagination.d.ts +3 -0
  30. package/dist/SelectCreatable/types/components/index.d.ts +2 -0
  31. package/dist/index.d.ts +19 -1
  32. package/dist/index.js +277 -171
  33. package/dist/index.js.map +1 -1
  34. package/dist/types/components/BubbleBox/BubbleBox.d.ts +17 -0
  35. package/dist/types/components/BubbleBox/index.d.ts +2 -0
  36. package/dist/types/components/BubbleBox/useClientRect.d.ts +5 -0
  37. package/dist/types/components/BubbleBox/utils.d.ts +1 -0
  38. package/dist/types/components/Pagination/Pagination.d.ts +3 -0
  39. package/dist/types/components/index.d.ts +2 -0
  40. package/package.json +43 -34
@@ -0,0 +1,17 @@
1
+ import React, { HTMLAttributes } from 'react';
2
+ import './BubbleBox.global.css';
3
+ export interface BubbleBoxProps extends HTMLAttributes<HTMLDivElement> {
4
+ className?: string;
5
+ controlClassName?: string;
6
+ svgClassName?: string;
7
+ control?: React.ReactNode;
8
+ shadow?: boolean;
9
+ bubbleSize?: number | [number, number];
10
+ backgroundColor?: React.CSSProperties['backgroundColor'];
11
+ borderColor?: React.CSSProperties['borderColor'];
12
+ innerOffset?: number;
13
+ radiusOffset?: number;
14
+ borderWith?: 1 | 2 | 3 | 4 | 5;
15
+ }
16
+ declare const BubbleBox: React.FC<BubbleBoxProps>;
17
+ export default BubbleBox;
@@ -0,0 +1,2 @@
1
+ export { default } from './BubbleBox';
2
+ export type { BubbleBoxProps } from './BubbleBox';
@@ -0,0 +1,5 @@
1
+ import React from 'react';
2
+ export declare const useClientRect: () => {
3
+ rect: DOMRect | null;
4
+ ref: React.RefObject<HTMLDivElement>;
5
+ };
@@ -0,0 +1 @@
1
+ export declare const composeBubblePath: (width: number, height: number, bubble: number, radiusOffset: number) => string;
@@ -8,6 +8,9 @@ export interface PaginationProps {
8
8
  onChange?: (page: number) => void;
9
9
  current?: number;
10
10
  scrollOnChange?: boolean;
11
+ gapStep?: number;
12
+ hideArrows?: boolean;
13
+ simple?: boolean;
11
14
  }
12
15
  declare const Pagination: React.FC<PaginationProps>;
13
16
  export default Pagination;
@@ -32,3 +32,5 @@ export { default as Checkbox } from './Checkbox';
32
32
  export type { CheckboxProps } from './Checkbox';
33
33
  export { default as PulseDot } from './PulseDot';
34
34
  export type { PulseDotProps } from './PulseDot';
35
+ export { default as BubbleBox } from './BubbleBox';
36
+ export type { BubbleBoxProps } from './BubbleBox';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vchasno/ui-kit",
3
- "version": "0.2.7",
3
+ "version": "0.2.9",
4
4
  "description": "React UI components for Vchasno applications",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.js",
@@ -12,19 +12,27 @@
12
12
  "exports": {
13
13
  ".": {
14
14
  "types": "./dist/index.d.ts",
15
- "import": "./dist/index.js"
15
+ "require": "./dist/index.cjs.js",
16
+ "import": "./dist/index.js",
17
+ "default": "./dist/index.js"
16
18
  },
17
19
  "./Datepicker": {
18
20
  "types": "./dist/Datepicker/index.d.ts",
19
- "import": "./dist/Datepicker/index.js"
21
+ "require": "./dist/Datepicker/index.cjs.js",
22
+ "import": "./dist/Datepicker/index.js",
23
+ "default": "./dist/Datepicker/index.js"
20
24
  },
21
25
  "./Select": {
22
26
  "types": "./dist/Select/index.d.ts",
23
- "import": "./dist/Select/index.js"
27
+ "require": "./dist/Select/index.cjs.js",
28
+ "import": "./dist/Select/index.js",
29
+ "default": "./dist/Select/index.js"
24
30
  },
25
31
  "./SelectCreatable": {
26
32
  "types": "./dist/SelectCreatable/index.d.ts",
27
- "import": "./dist/SelectCreatable/index.js"
33
+ "require": "./dist/SelectCreatable/index.cjs.js",
34
+ "import": "./dist/SelectCreatable/index.js",
35
+ "default": "./dist/SelectCreatable/index.js"
28
36
  },
29
37
  "./dist/css/*.css": "./dist/css/*.css"
30
38
  },
@@ -34,6 +42,7 @@
34
42
  "lint": "npm run lint:js && npm run lint:css",
35
43
  "lint:js": "eslint 'src/**/*.{js,jsx,ts,tsx,json}'",
36
44
  "lint:css": "stylelint \"src/**/*.css\"",
45
+ "lint:css:fix": "stylelint \"src/**/*.css\" --fix",
37
46
  "build": "rollup -c",
38
47
  "pub": "npm run build && npm publish --access public --scope=@vchasno",
39
48
  "storybook": "storybook dev -p 6006",
@@ -57,24 +66,24 @@
57
66
  "@vchasno:registry": "https://registry.npmjs.org/"
58
67
  },
59
68
  "devDependencies": {
60
- "@babel/preset-env": "~7.22.20",
61
- "@babel/preset-react": "7.22.15",
62
- "@babel/preset-typescript": "~7.22.15",
63
- "@jest/globals": "~29.7.0",
64
- "@rollup/plugin-commonjs": "25.0.4",
65
- "@rollup/plugin-node-resolve": "15.2.1",
66
- "@rollup/plugin-terser": "~0.4.3",
67
- "@rollup/plugin-typescript": "11.1.3",
68
- "@storybook/addon-essentials": "~7.4.5",
69
- "@storybook/addon-interactions": "~7.4.5",
70
- "@storybook/addon-links": "~7.4.5",
71
- "@storybook/addon-onboarding": "~1.0.8",
72
- "@storybook/blocks": "~7.4.5",
73
- "@storybook/react": "~7.4.5",
74
- "@storybook/react-webpack5": "~7.4.5",
75
- "@storybook/testing-library": "~0.2.1",
76
- "@trivago/prettier-plugin-sort-imports": "~4.2.0",
77
- "@types/jest": "~29.5.5",
69
+ "@babel/preset-env": "7.24.0",
70
+ "@babel/preset-react": "7.23.3",
71
+ "@babel/preset-typescript": "7.23.3",
72
+ "@jest/globals": "29.7.0",
73
+ "@rollup/plugin-commonjs": "25.0.7",
74
+ "@rollup/plugin-node-resolve": "15.2.3",
75
+ "@rollup/plugin-terser": "0.4.4",
76
+ "@rollup/plugin-typescript": "11.1.6",
77
+ "@storybook/addon-essentials": "7.6.17",
78
+ "@storybook/addon-interactions": "7.6.17",
79
+ "@storybook/addon-links": "7.6.17",
80
+ "@storybook/addon-onboarding": "1.0.11",
81
+ "@storybook/blocks": "7.6.17",
82
+ "@storybook/react": "7.6.17",
83
+ "@storybook/react-webpack5": "7.6.17",
84
+ "@storybook/testing-library": "0.2.2",
85
+ "@trivago/prettier-plugin-sort-imports": "4.3.0",
86
+ "@types/jest": "29.5.12",
78
87
  "@types/react": "~17.0.75",
79
88
  "@types/react-dom": "~17.0.25",
80
89
  "@typescript-eslint/eslint-plugin": "~6.7.3",
@@ -85,29 +94,29 @@
85
94
  "eslint-plugin-prettier": "~5.0.0",
86
95
  "eslint-plugin-react": "~7.33.2",
87
96
  "eslint-plugin-react-hooks": "~4.6.0",
88
- "jest": "~29.7.0",
89
- "jest-environment-jsdom": "~29.7.0",
97
+ "jest": "29.7.0",
98
+ "jest-environment-jsdom": "29.7.0",
90
99
  "postcss": "8.4.31",
91
100
  "prettier": "~3.0.3",
92
101
  "react": "~17.0.2",
93
102
  "react-dom": "~17.0.2",
94
- "rimraf": "5.0.1",
95
- "rollup": "~3.29.4",
96
- "rollup-plugin-copy": "^3.5.0",
97
- "rollup-plugin-dts": "6.0.2",
103
+ "rimraf": "5.0.5",
104
+ "rollup": "3.29.4",
105
+ "rollup-plugin-copy": "3.5.0",
106
+ "rollup-plugin-dts": "6.1.0",
98
107
  "rollup-plugin-multi-input": "~1.4.1",
99
108
  "rollup-plugin-peer-deps-external": "2.2.4",
100
109
  "rollup-plugin-postcss": "4.0.2",
101
110
  "rollup-plugin-sourcemaps": "^0.6.3",
102
- "storybook": "~7.4.5",
111
+ "storybook": "7.6.17",
103
112
  "stylelint": "~15.10.3",
104
113
  "stylelint-config-idiomatic-order": "~9.0.0",
105
114
  "stylelint-config-standard": "~34.0.0",
106
- "ts-jest": "~29.1.1",
107
- "ts-node": "~10.9.1",
115
+ "ts-jest": "29.1.2",
116
+ "ts-node": "10.9.2",
108
117
  "tslib": "2.6.2",
109
- "typescript": "5.2.2",
110
- "webpack": "^5.88.2"
118
+ "typescript": "5.3.3",
119
+ "webpack": "5.90.3"
111
120
  },
112
121
  "peerDependencies": {
113
122
  "react": "^16.8.0 || ^17 || ^18",