@expressms/smartapp-ui 2.5.3 → 2.5.5

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 (73) hide show
  1. package/build/main/constants/constants.d.ts +12 -6
  2. package/build/main/constants/constants.js +10 -4
  3. package/build/main/constants/constants.js.map +1 -1
  4. package/build/main/helpers/index.d.ts +4 -2
  5. package/build/main/helpers/index.js +13 -0
  6. package/build/main/helpers/index.js.map +1 -1
  7. package/build/main/styles/styles.scss +2 -2
  8. package/build/main//321/201omponents/ActionModal/ActionModal.d.ts +1 -1
  9. package/build/main//321/201omponents/ActionModal/ActionModal.js +7 -7
  10. package/build/main//321/201omponents/ActionModal/ActionModal.js.map +1 -1
  11. package/build/main//321/201omponents/Avatar/Avatar.js +1 -1
  12. package/build/main//321/201omponents/Avatar/Avatar.js.map +1 -1
  13. package/build/main//321/201omponents/Avatar/types.d.ts +2 -2
  14. package/build/main//321/201omponents/Chip/Chip.d.ts +1 -1
  15. package/build/main//321/201omponents/Chip/Chip.js +3 -3
  16. package/build/main//321/201omponents/Chip/Chip.js.map +1 -1
  17. package/build/main//321/201omponents/ConfirmationModal/ConfirmationModal.d.ts +1 -1
  18. package/build/main//321/201omponents/ConfirmationModal/ConfirmationModal.js +6 -6
  19. package/build/main//321/201omponents/ConfirmationModal/ConfirmationModal.js.map +1 -1
  20. package/build/main//321/201omponents/CustomSelect/CustomSelect.js +6 -6
  21. package/build/main//321/201omponents/CustomSelect/CustomSelect.js.map +1 -1
  22. package/build/main//321/201omponents/CustomSelect/selectStyles.d.ts +1 -1
  23. package/build/main//321/201omponents/CustomSelect/selectStyles.js +20 -26
  24. package/build/main//321/201omponents/CustomSelect/selectStyles.js.map +1 -1
  25. package/build/main//321/201omponents/CustomSelect/types.d.ts +0 -1
  26. package/build/main//321/201omponents/CustomSelectProfiles/types.d.ts +1 -2
  27. package/build/main//321/201omponents/Header/Header.js.map +1 -1
  28. package/build/main//321/201omponents/Input/Input.d.ts +1 -1
  29. package/build/main//321/201omponents/Input/Input.js +15 -17
  30. package/build/main//321/201omponents/Input/Input.js.map +1 -1
  31. package/build/main//321/201omponents/ListItem/ListItem.js +2 -2
  32. package/build/main//321/201omponents/ListItem/ListItem.js.map +1 -1
  33. package/build/main//321/201omponents/ListItem/types.d.ts +3 -3
  34. package/build/main//321/201omponents/Modal/Modal.d.ts +1 -1
  35. package/build/main//321/201omponents/Modal/Modal.js +16 -7
  36. package/build/main//321/201omponents/Modal/Modal.js.map +1 -1
  37. package/build/main//321/201omponents/Modal/types.d.ts +1 -0
  38. package/build/main//321/201omponents/ProgressBar/ProgressBar.js.map +1 -1
  39. package/build/main//321/201omponents/ScrollBar/ScrollBar.js.map +1 -1
  40. package/build/main//321/201omponents/Skeleton/Skeleton.js +2 -2
  41. package/build/main//321/201omponents/Skeleton/Skeleton.js.map +1 -1
  42. package/build/main//321/201omponents/Skeleton/types.d.ts +2 -2
  43. package/build/main//321/201omponents/Stories/Stories.js +1 -1
  44. package/build/main//321/201omponents/Stories/Stories.js.map +1 -1
  45. package/build/main//321/201omponents/Textarea/Textarea.d.ts +1 -1
  46. package/build/main//321/201omponents/Textarea/Textarea.js +10 -12
  47. package/build/main//321/201omponents/Textarea/Textarea.js.map +1 -1
  48. package/build/main//321/201omponents/UserDropdown/ContactBottomSheet/ContactBottomSheet.d.ts +1 -1
  49. package/build/main//321/201omponents/UserDropdown/ContactBottomSheet/ContactBottomSheet.js +2 -3
  50. package/build/main//321/201omponents/UserDropdown/ContactBottomSheet/ContactBottomSheet.js.map +1 -1
  51. package/build/main//321/201omponents/UserDropdown/ContactInfo/ContactInfo.d.ts +1 -1
  52. package/build/main//321/201omponents/UserDropdown/ContactInfo/ContactInfo.js +2 -3
  53. package/build/main//321/201omponents/UserDropdown/ContactInfo/ContactInfo.js.map +1 -1
  54. package/build/main//321/201omponents/UserDropdown/LoadingMessage/LoadingMessage.js +1 -2
  55. package/build/main//321/201omponents/UserDropdown/LoadingMessage/LoadingMessage.js.map +1 -1
  56. package/build/main//321/201omponents/UserDropdown/MultiValueLabel/MultiValueLabel.js +3 -3
  57. package/build/main//321/201omponents/UserDropdown/MultiValueLabel/MultiValueLabel.js.map +1 -1
  58. package/build/main//321/201omponents/UserDropdown/Option/Option.js +5 -9
  59. package/build/main//321/201omponents/UserDropdown/Option/Option.js.map +1 -1
  60. package/build/main//321/201omponents/UserDropdown/UserDropdown.js +6 -12
  61. package/build/main//321/201omponents/UserDropdown/UserDropdown.js.map +1 -1
  62. package/build/main//321/201omponents/UserDropdown/helpers.d.ts +10 -15
  63. package/build/main//321/201omponents/UserDropdown/selectStyles.d.ts +1 -1
  64. package/build/main//321/201omponents/UserDropdown/selectStyles.js +27 -33
  65. package/build/main//321/201omponents/UserDropdown/selectStyles.js.map +1 -1
  66. package/build/main//321/201omponents/UserDropdown/types.d.ts +5 -11
  67. package/package.json +18 -14
  68. package/build/main//321/201omponents/CustomSelect/colors.d.ts +0 -17
  69. package/build/main//321/201omponents/CustomSelect/colors.js +0 -18
  70. package/build/main//321/201omponents/CustomSelect/colors.js.map +0 -1
  71. package/build/main//321/201omponents/UserDropdown/colors.d.ts +0 -20
  72. package/build/main//321/201omponents/UserDropdown/colors.js +0 -21
  73. package/build/main//321/201omponents/UserDropdown/colors.js.map +0 -1
@@ -1,8 +1,7 @@
1
- import { MutableRefObject } from 'react';
1
+ import { RefObject } from 'react';
2
2
  import { MenuListProps, OptionProps } from 'react-select';
3
3
  import { ICommonProps, ILayoutTypeProps } from '../../constants';
4
4
  export interface IContactBottomSheet {
5
- theme: string;
6
5
  language: string;
7
6
  avatar: string | null;
8
7
  name: string;
@@ -13,7 +12,6 @@ export interface IContactBottomSheet {
13
12
  companyPosition: string | null;
14
13
  }
15
14
  export interface IContactInfo {
16
- theme: string;
17
15
  language: string;
18
16
  serverName: string | null;
19
17
  company: string | null;
@@ -30,8 +28,8 @@ export interface ILoadingMessage {
30
28
  }
31
29
  export interface IMenuListProps extends MenuListProps {
32
30
  appTheme: 'default' | 'dark';
33
- selectRef: MutableRefObject<any>;
34
- scrollFromTop: MutableRefObject<number | undefined>;
31
+ selectRef: RefObject<any>;
32
+ scrollFromTop: RefObject<number>;
35
33
  hasNextPage: boolean;
36
34
  isLoading: boolean;
37
35
  isUserTyping: boolean;
@@ -47,7 +45,6 @@ type TData = {
47
45
  department: string | null;
48
46
  companyPosition: string | null;
49
47
  isMyContacts: boolean;
50
- theme: 'default' | 'dark';
51
48
  platform: 'web' | 'ios' | 'android';
52
49
  language: 'ru' | 'en' | 'de' | 'es' | 'fr' | 'ar' | 'mal';
53
50
  setIsSearchable: (isSearchable: boolean) => void;
@@ -66,12 +63,11 @@ export type TModalData = {
66
63
  companyPosition: string | null;
67
64
  };
68
65
  type TGenerateCommonOption = {
69
- theme: string;
70
66
  platform: string;
71
67
  layoutType: string;
72
68
  isChipsCollapsable: boolean;
73
- isInputFocused: MutableRefObject<boolean>;
74
- selectRef: MutableRefObject<any>;
69
+ isInputFocused: RefObject<boolean>;
70
+ selectRef: RefObject<any>;
75
71
  };
76
72
  export type TGenerateCorporateOption = TGenerateCommonOption & {
77
73
  option: TCorporateEntity;
@@ -101,7 +97,6 @@ export type TSelectStyles = {
101
97
  paddingLeft: string;
102
98
  fillType: string;
103
99
  platform: string;
104
- theme: string;
105
100
  layoutType: string;
106
101
  };
107
102
  export type TGenerateNoOptionsMessage = {
@@ -121,7 +116,6 @@ export interface MultiOptionType {
121
116
  label: string;
122
117
  avatar?: string | null;
123
118
  email: string;
124
- theme: string;
125
119
  layoutType: string;
126
120
  isChipsCollapsable: boolean;
127
121
  platform?: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@expressms/smartapp-ui",
3
- "version": "2.5.3",
3
+ "version": "2.5.5",
4
4
  "description": "SmartApp UI library",
5
5
  "license": "MIT",
6
6
  "main": "build/main/index.js",
@@ -11,7 +11,8 @@
11
11
  "registry": "https://registry.npmjs.org/"
12
12
  },
13
13
  "dependencies": {
14
- "@svgr/webpack": "5.5",
14
+ "@storybook/core-events": "^8.5.1",
15
+ "@svgr/webpack": "^8.1.0",
15
16
  "@testing-library/jest-dom": "^6.4.2",
16
17
  "@types/color": "^3.0.6",
17
18
  "@types/dompurify": "^3.0.5",
@@ -84,12 +85,13 @@
84
85
  "uuid": "^9.0.1"
85
86
  },
86
87
  "resolutions": {
88
+ "@typescript-eslint/utils": "6.21.0",
87
89
  "juice/cheerio": "1.0.0-rc.12"
88
90
  },
89
91
  "scripts": {
90
92
  "start": "node scripts/start.js",
91
- "storybook": "rm -rf node_modules/.cache/storybook && start-storybook -p 6006",
92
- "build-storybook": "build-storybook -o storybook-build",
93
+ "storybook": "rm -rf node_modules/.cache/storybook && storybook dev -p 6006",
94
+ "build-storybook": "storybook build -o storybook-build",
93
95
  "case-sensitive-paths-webpack-plugin": "^2.4.0",
94
96
  "copy-svg-files": "copyfiles -u 1 src/assets/icons/*.svg build/main",
95
97
  "build": "rm -rf build && tsc -p tsconfig.json && webpack && npm run copy-svg-files",
@@ -107,7 +109,8 @@
107
109
  "eslintConfig": {
108
110
  "extends": [
109
111
  "react-app",
110
- "react-app/jest"
112
+ "react-app/jest",
113
+ "plugin:storybook/recommended"
111
114
  ],
112
115
  "overrides": [
113
116
  {
@@ -136,28 +139,29 @@
136
139
  "@expressms/eslint-config": "^1.0.3",
137
140
  "@expressms/prettier-config": "^1.0.0",
138
141
  "@pmmmwh/react-refresh-webpack-plugin": "^0.5.3",
139
- "@storybook/addon-actions": "^6.5.15",
140
- "@storybook/addon-essentials": "^6.5.15",
141
- "@storybook/addon-links": "^6.5.15",
142
- "@storybook/addon-viewport": "^6.5.15",
143
- "@storybook/addons": "^6.5.15",
144
- "@storybook/core-events": "^6.5.15",
145
- "@storybook/react": "^6.5.15",
142
+ "@storybook/addon-essentials": "^8.5.1",
143
+ "@storybook/blocks": "^8.5.1",
144
+ "@storybook/preset-create-react-app": "^8.5.1",
145
+ "@storybook/react": "^8.5.1",
146
+ "@storybook/react-webpack5": "^8.5.1",
147
+ "@storybook/test": "^8.5.1",
146
148
  "@types/convert-layout": "^0.5.3",
149
+ "@types/lodash": "^4.17.13",
147
150
  "@types/react-virtualized": "^9.21.30",
148
151
  "@types/react-window": "^1.8.8",
149
152
  "css-loader": "^6.7.3",
150
153
  "css-minimizer-webpack-plugin": "^3.2.0",
151
154
  "eslint-config-react-app": "^6.0.0",
155
+ "eslint-plugin-storybook": "^0.11.0",
152
156
  "postcss": "^8.4.4",
153
157
  "postcss-flexbugs-fixes": "^5.0.2",
154
158
  "postcss-loader": "^6.2.1",
155
159
  "postcss-normalize": "^10.0.1",
156
160
  "postcss-preset-env": "^7.0.1",
161
+ "prop-types": "^15.8.1",
157
162
  "react-scripts": "^5.0.1",
158
163
  "resolve-url-loader": "2.3.1",
159
- "storybook-addon-react-router-v6": "^0.2.1",
160
- "storybook-addon-sass-postcss": "0.1.3",
164
+ "storybook": "^8.5.1",
161
165
  "terser-webpack-plugin": "^5.2.5",
162
166
  "tsconfig-paths-webpack-plugin": "^4.0.0",
163
167
  "webpack": "^5.75.0",
@@ -1,17 +0,0 @@
1
- export declare const lightBlueColor = "rgba(71, 153, 227, 0.5)";
2
- export declare const blueColor = "rgba(71, 153, 227, 1)";
3
- export declare const lightGrayColor = "rgba(249, 249, 249, 1)";
4
- export declare const grayColor = "rgba(183, 183, 183, 1)";
5
- export declare const darkGrayColor = "rgba(128, 128, 128, 1)";
6
- export declare const lightBlackColor = "rgba(86, 86, 86, 1)";
7
- export declare const blackColor = "rgba(26, 26, 26, 1)";
8
- export declare const whiteBackgroundColor = "rgba(255, 255, 255, 1)";
9
- export declare const grayBackgroundColor = "rgba(241, 241, 242, 1)";
10
- export declare const lighterBlackBackgroundColor = "rgba(43, 43, 43, 1)";
11
- export declare const lightBlackBackgroundColor = "rgba(61, 61, 61, 1)";
12
- export declare const blackBackgroundColor = "rgba(36, 36, 36, 1)";
13
- export declare const redBorderColor = "rgba(237, 71, 71, 1)";
14
- export declare const lightGrayBorderColor = "rgba(0, 0, 0, 0.05)";
15
- export declare const grayBorderColor = "rgba(232, 233, 238, 1)";
16
- export declare const boxShadowColor = "rgba(0, 0, 0, 0.1)";
17
- export declare const transparentColor = "transparent";
@@ -1,18 +0,0 @@
1
- export var lightBlueColor = 'rgba(71, 153, 227, 0.5)';
2
- export var blueColor = 'rgba(71, 153, 227, 1)';
3
- export var lightGrayColor = 'rgba(249, 249, 249, 1)';
4
- export var grayColor = 'rgba(183, 183, 183, 1)';
5
- export var darkGrayColor = 'rgba(128, 128, 128, 1)';
6
- export var lightBlackColor = 'rgba(86, 86, 86, 1)';
7
- export var blackColor = 'rgba(26, 26, 26, 1)';
8
- export var whiteBackgroundColor = 'rgba(255, 255, 255, 1)';
9
- export var grayBackgroundColor = 'rgba(241, 241, 242, 1)';
10
- export var lighterBlackBackgroundColor = 'rgba(43, 43, 43, 1)';
11
- export var lightBlackBackgroundColor = 'rgba(61, 61, 61, 1)';
12
- export var blackBackgroundColor = 'rgba(36, 36, 36, 1)';
13
- export var redBorderColor = 'rgba(237, 71, 71, 1)';
14
- export var lightGrayBorderColor = 'rgba(0, 0, 0, 0.05)';
15
- export var grayBorderColor = 'rgba(232, 233, 238, 1)';
16
- export var boxShadowColor = 'rgba(0, 0, 0, 0.1)';
17
- export var transparentColor = 'transparent';
18
- //# sourceMappingURL=colors.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"colors.js","sourceRoot":"","sources":["../../../../src/сomponents/CustomSelect/colors.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,IAAM,cAAc,GAAG,yBAAyB,CAAA;AACvD,MAAM,CAAC,IAAM,SAAS,GAAG,uBAAuB,CAAA;AAChD,MAAM,CAAC,IAAM,cAAc,GAAG,wBAAwB,CAAA;AACtD,MAAM,CAAC,IAAM,SAAS,GAAG,wBAAwB,CAAA;AACjD,MAAM,CAAC,IAAM,aAAa,GAAG,wBAAwB,CAAA;AACrD,MAAM,CAAC,IAAM,eAAe,GAAG,qBAAqB,CAAA;AACpD,MAAM,CAAC,IAAM,UAAU,GAAG,qBAAqB,CAAA;AAE/C,MAAM,CAAC,IAAM,oBAAoB,GAAG,wBAAwB,CAAA;AAC5D,MAAM,CAAC,IAAM,mBAAmB,GAAG,wBAAwB,CAAA;AAC3D,MAAM,CAAC,IAAM,2BAA2B,GAAG,qBAAqB,CAAA;AAChE,MAAM,CAAC,IAAM,yBAAyB,GAAG,qBAAqB,CAAA;AAC9D,MAAM,CAAC,IAAM,oBAAoB,GAAG,qBAAqB,CAAA;AAEzD,MAAM,CAAC,IAAM,cAAc,GAAG,sBAAsB,CAAA;AACpD,MAAM,CAAC,IAAM,oBAAoB,GAAG,qBAAqB,CAAA;AACzD,MAAM,CAAC,IAAM,eAAe,GAAG,wBAAwB,CAAA;AAEvD,MAAM,CAAC,IAAM,cAAc,GAAG,oBAAoB,CAAA;AAElD,MAAM,CAAC,IAAM,gBAAgB,GAAG,aAAa,CAAA"}
@@ -1,20 +0,0 @@
1
- export declare const blueColor = "rgba(71, 153, 227, 1)";
2
- export declare const lightBlueColor = "rgba(71, 153, 227, 0.5)";
3
- export declare const lighterGrayColor = "rgba(241, 241, 242, 1)";
4
- export declare const lightGrayColor = "rgba(17, 17, 17, 0.3)";
5
- export declare const grayColor = "rgba(183, 183, 183, 1)";
6
- export declare const lighterBlackColor = "rgba(86, 86, 86, 1)";
7
- export declare const lightBlackColor = "rgba(49, 49, 49, 1)";
8
- export declare const blackColor = "rgba(26, 26, 26, 1)";
9
- export declare const whiteBackgroundColor = "rgba(255, 255, 255, 1)";
10
- export declare const grayBackgroundColor = "rgba(249, 249, 249, 1)";
11
- export declare const darkGrayBackgroundColor = "rgba(0, 0, 0, 0.04)";
12
- export declare const darkerGrayBackgroundColor = "rgba(0, 0, 0, 0.3)";
13
- export declare const lighterBlackBackgroundColor = "rgba(43, 43, 43, 1)";
14
- export declare const lightBlackBackgroundColor = "rgba(61, 61, 61, 1)";
15
- export declare const blackBackgroundColor = "rgba(36, 36, 36, 1)";
16
- export declare const grayBorderColor = "rgba(232, 233, 238, 1)";
17
- export declare const darkGrayBorderColor = "rgba(128, 128, 128, 1)";
18
- export declare const redBorderColor = "rgba(237, 71, 71, 1)";
19
- export declare const boxShadowColor = "rgba(0, 0, 0, 0.25)";
20
- export declare const transparentColor = "transparent";
@@ -1,21 +0,0 @@
1
- export var blueColor = 'rgba(71, 153, 227, 1)';
2
- export var lightBlueColor = 'rgba(71, 153, 227, 0.5)';
3
- export var lighterGrayColor = 'rgba(241, 241, 242, 1)';
4
- export var lightGrayColor = 'rgba(17, 17, 17, 0.3)';
5
- export var grayColor = 'rgba(183, 183, 183, 1)';
6
- export var lighterBlackColor = 'rgba(86, 86, 86, 1)';
7
- export var lightBlackColor = 'rgba(49, 49, 49, 1)';
8
- export var blackColor = 'rgba(26, 26, 26, 1)';
9
- export var whiteBackgroundColor = 'rgba(255, 255, 255, 1)';
10
- export var grayBackgroundColor = 'rgba(249, 249, 249, 1)';
11
- export var darkGrayBackgroundColor = 'rgba(0, 0, 0, 0.04)';
12
- export var darkerGrayBackgroundColor = 'rgba(0, 0, 0, 0.3)';
13
- export var lighterBlackBackgroundColor = 'rgba(43, 43, 43, 1)';
14
- export var lightBlackBackgroundColor = 'rgba(61, 61, 61, 1)';
15
- export var blackBackgroundColor = 'rgba(36, 36, 36, 1)';
16
- export var grayBorderColor = 'rgba(232, 233, 238, 1)';
17
- export var darkGrayBorderColor = 'rgba(128, 128, 128, 1)';
18
- export var redBorderColor = 'rgba(237, 71, 71, 1)';
19
- export var boxShadowColor = 'rgba(0, 0, 0, 0.25)';
20
- export var transparentColor = 'transparent';
21
- //# sourceMappingURL=colors.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"colors.js","sourceRoot":"","sources":["../../../../src/сomponents/UserDropdown/colors.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,IAAM,SAAS,GAAG,uBAAuB,CAAA;AAChD,MAAM,CAAC,IAAM,cAAc,GAAG,yBAAyB,CAAA;AACvD,MAAM,CAAC,IAAM,gBAAgB,GAAG,wBAAwB,CAAA;AACxD,MAAM,CAAC,IAAM,cAAc,GAAG,uBAAuB,CAAA;AACrD,MAAM,CAAC,IAAM,SAAS,GAAG,wBAAwB,CAAA;AACjD,MAAM,CAAC,IAAM,iBAAiB,GAAG,qBAAqB,CAAA;AACtD,MAAM,CAAC,IAAM,eAAe,GAAG,qBAAqB,CAAA;AACpD,MAAM,CAAC,IAAM,UAAU,GAAG,qBAAqB,CAAA;AAE/C,MAAM,CAAC,IAAM,oBAAoB,GAAG,wBAAwB,CAAA;AAC5D,MAAM,CAAC,IAAM,mBAAmB,GAAG,wBAAwB,CAAA;AAC3D,MAAM,CAAC,IAAM,uBAAuB,GAAG,qBAAqB,CAAA;AAC5D,MAAM,CAAC,IAAM,yBAAyB,GAAG,oBAAoB,CAAA;AAC7D,MAAM,CAAC,IAAM,2BAA2B,GAAG,qBAAqB,CAAA;AAChE,MAAM,CAAC,IAAM,yBAAyB,GAAG,qBAAqB,CAAA;AAC9D,MAAM,CAAC,IAAM,oBAAoB,GAAG,qBAAqB,CAAA;AAEzD,MAAM,CAAC,IAAM,eAAe,GAAG,wBAAwB,CAAA;AACvD,MAAM,CAAC,IAAM,mBAAmB,GAAG,wBAAwB,CAAA;AAC3D,MAAM,CAAC,IAAM,cAAc,GAAG,sBAAsB,CAAA;AAEpD,MAAM,CAAC,IAAM,cAAc,GAAG,qBAAqB,CAAA;AAEnD,MAAM,CAAC,IAAM,gBAAgB,GAAG,aAAa,CAAA"}