hi-tm 0.0.2 → 0.0.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 (48) hide show
  1. package/dist/components/AutoComplete/AutoCompleteMultiSelect.d.ts +1 -1
  2. package/dist/components/AutoComplete/AutoCompleteMultiSelect.js +26 -19
  3. package/dist/components/Cards/AutoComplete&DropDown/GeographyCard.js +2 -2
  4. package/dist/components/Cards/AutoComplete&DropDown/PersonCard.js +2 -2
  5. package/dist/components/Cards/AutoComplete&DropDown/SimpleCard.js +2 -2
  6. package/dist/components/DropDowns/CreatableAutoComplete.d.ts +31 -0
  7. package/dist/components/DropDowns/CreatableAutoComplete.js +104 -0
  8. package/dist/components/DropDowns/CreatableDropDown.d.ts +2 -1
  9. package/dist/components/DropDowns/CreatableDropDown.js +89 -16
  10. package/dist/components/DropDowns/DropDown.js +5 -5
  11. package/dist/components/DropDowns/DropDownMultiSelect.js +5 -5
  12. package/dist/components/Inputs/Buttons/Button.d.ts +3 -3
  13. package/dist/components/Inputs/Buttons/Button.js +15 -15
  14. package/dist/components/Inputs/TextInput.d.ts +5 -1
  15. package/dist/components/Inputs/TextInput.js +23 -6
  16. package/dist/components/Inputs/Toggle.d.ts +2 -2
  17. package/dist/components/Inputs/Toggle.js +13 -10
  18. package/dist/components/Layout/Headers/HeaderLayout.js +20 -24
  19. package/dist/components/Layout/Sidebar.js +51 -10
  20. package/dist/components/Table/ModernTable/ModernTable.d.ts +2 -2
  21. package/dist/components/Table/ModernTable/ModernTable.js +399 -150
  22. package/dist/components/Table/ModernTable/ModernTableHeader.d.ts +4 -1
  23. package/dist/components/Table/ModernTable/ModernTableHeader.js +6 -2
  24. package/dist/components/Table/TableRowCards/TableRowCardChildren.js +19 -19
  25. package/dist/components/Table/TableRowCards/TableRowCardSimple.js +19 -19
  26. package/dist/components/Tabs/Tabs.d.ts +5 -3
  27. package/dist/components/Tabs/Tabs.js +13 -2
  28. package/dist/components/Wrapper/Modals/DeleteConfirmationModal.d.ts +18 -0
  29. package/dist/components/Wrapper/Modals/DeleteConfirmationModal.js +68 -0
  30. package/dist/components/sections/components/Tabs/BreadCrumbs.d.ts +1 -1
  31. package/dist/components/sections/components/Tabs/BreadCrumbs.js +9 -9
  32. package/dist/components/sections/components/Tabs/TabsComponent.js +19 -3
  33. package/dist/helper/formatWithCommas.d.ts +1 -0
  34. package/dist/helper/formatWithCommas.js +8 -0
  35. package/dist/index.d.ts +2 -0
  36. package/dist/index.js +5 -1
  37. package/dist/styles/globals.css +198 -180
  38. package/dist/tailwind-preset.ts +41 -41
  39. package/dist/types/AutoComplete/CreatableAutoComplete.d.ts +34 -0
  40. package/dist/types/AutoComplete/CreatableAutoComplete.js +2 -0
  41. package/dist/types/BreakCrumbTypes.d.ts +2 -0
  42. package/dist/types/Buttons/PrimaryButton.d.ts +4 -3
  43. package/dist/types/DropDown/CreatableDropDown.d.ts +10 -3
  44. package/dist/types/Inputs/TextInputType.d.ts +8 -6
  45. package/dist/types/Layout/Headers/HeaderLayout.d.ts +1 -0
  46. package/dist/types/Layout/SidebarType.d.ts +2 -1
  47. package/dist/types/ModernTable/index.d.ts +27 -7
  48. package/package.json +1 -2
@@ -1,180 +1,198 @@
1
- @tailwind base;
2
- @tailwind components;
3
- @tailwind utilities;
4
-
5
- * {
6
- margin: 0px;
7
- padding: 0;
8
- box-sizing: border-box;
9
- }
10
-
11
- body {
12
- font-family: var(--DanaFa);
13
- font-style: normal;
14
- font-weight: 400;
15
- font-size: 16px;
16
- }
17
-
18
- @layer components {
19
- .customTransition {
20
- transition: all ease 250ms;
21
- }
22
- .select-none-custom {
23
- -webkit-touch-callout: none;
24
- -webkit-user-select: none;
25
- -moz-user-select: none;
26
- -ms-user-select: none;
27
- user-select: none;
28
- }
29
- .customShadowBox {
30
- box-shadow: 0px 0px 10px 5px rgba(0, 0, 0, 0.08);
31
- }
32
- .BoundedShadow {
33
- box-shadow: 0px 0px 0px 1px #e9e9f0;
34
- }
35
- .trShadow {
36
- box-shadow: 0px 0px 0px 1px #ececee;
37
- }
38
- .input-style {
39
- width: 100%;
40
- height: 40px;
41
- border: 2px solid #e5e7eb;
42
- border-radius: 8px;
43
- padding: 0 12px 0px 12px;
44
- outline: none;
45
- }
46
- }
47
-
48
- li.activeSidebar {
49
- background-color: #1e88e554;
50
- font-weight: 500;
51
- }
52
-
53
- li.activeSidebar::after {
54
- content: '';
55
- position: absolute;
56
- top: 50%;
57
- left: 100%;
58
- transform: translateY(-50%);
59
- height: 70%;
60
- width: 4px;
61
- background-color: #006fee;
62
- border-radius: 4px;
63
- }
64
- li.activeSidebar-subset {
65
- position: relative;
66
- background-color: #1e88e554;
67
- font-weight: 500;
68
- }
69
-
70
- li.activeSidebar-subset::after {
71
- content: '';
72
- position: absolute;
73
- top: 50%;
74
- left: 102%;
75
- transform: translateY(-50%);
76
- height: 70%;
77
- width: 4px;
78
- background-color: #006fee;
79
- border-radius: 4px;
80
- }
81
-
82
- .noDisplay-scrollbar {
83
- scrollbar-width: none; /* For Firefox */
84
- -ms-overflow-style: none; /* For Internet Explorer and Edge */
85
- }
86
-
87
- .noDisplay-scrollbar::-webkit-scrollbar {
88
- display: none; /* For Chrome, Safari, and Opera */
89
- }
90
- .danger {
91
- background-color: #ffffff;
92
- color: #f54180;
93
- }
94
-
95
- .success {
96
- background-color: #ffffff;
97
- color: #45d483;
98
- }
99
- .warning {
100
- background-color: #f7b750;
101
- color: #3b3834;
102
- }
103
-
104
- .info {
105
- background-color: #d1ecf1;
106
- color: #0c5460;
107
- }
108
-
109
- .primary {
110
- background-color: #338cf1;
111
- color: #fff;
112
- }
113
-
114
- .secondary {
115
- background-color: #dddde0;
116
- color: #000000;
117
- }
118
-
119
- /* ============================================================================================================================== */
120
- .dangerBtn {
121
- background-color: #ff0000ab;
122
- color: #ffffff;
123
- }
124
-
125
- .successBtn {
126
- background-color: #ffffff;
127
- color: #45d483;
128
- }
129
- .warningBtn {
130
- background-color: #f7b750;
131
- color: #3b3834;
132
- }
133
-
134
- .infoBtn {
135
- background-color: #d1ecf1;
136
- color: #0c5460;
137
- }
138
-
139
- .primaryBtn {
140
- background-color: #338cf1;
141
- color: #fff;
142
- }
143
-
144
- .secondaryBtn {
145
- background-color: #dddde0;
146
- color: #000000;
147
- }
148
- /* ============================================================================================================================== */
149
- .dangerPrice {
150
- background-color: #ffffff;
151
- color: #f54180;
152
- }
153
-
154
- .successPrice {
155
- background-color: #ffffff;
156
- color: #45d483;
157
- }
158
- .warningPrice {
159
- background-color: #f7b750;
160
- color: #3b3834;
161
- }
162
-
163
- .infoPrice {
164
- background-color: #d1ecf1;
165
- color: #0c5460;
166
- }
167
-
168
- .primaryPrice {
169
- background-color: #338cf1;
170
- color: #fff;
171
- }
172
-
173
- .secondaryPrice {
174
- background-color: #dddde0;
175
- color: #000000;
176
- }
177
- .modal-content {
178
- isolation: isolate;
179
- contain: content;
180
- }
1
+ @tailwind base;
2
+ @tailwind components;
3
+ @tailwind utilities;
4
+
5
+ * {
6
+ margin: 0px;
7
+ padding: 0;
8
+ box-sizing: border-box;
9
+ }
10
+
11
+ body {
12
+ font-family: var(--DanaFa);
13
+ font-style: normal;
14
+ font-weight: 400;
15
+ font-size: 16px;
16
+ }
17
+
18
+ @layer components {
19
+ .customTransition {
20
+ transition: all ease 250ms;
21
+ }
22
+ .select-none-custom {
23
+ -webkit-touch-callout: none;
24
+ -webkit-user-select: none;
25
+ -moz-user-select: none;
26
+ -ms-user-select: none;
27
+ user-select: none;
28
+ }
29
+ .customShadowBox {
30
+ box-shadow: 0px 0px 10px 5px rgba(0, 0, 0, 0.08);
31
+ }
32
+ .BoundedShadow {
33
+ box-shadow: 0px 0px 0px 1px #e9e9f0;
34
+ }
35
+ .trShadow {
36
+ box-shadow: 0px 0px 0px 1px #ececee;
37
+ }
38
+ .input-style {
39
+ width: 100%;
40
+ height: 40px;
41
+ border: 2px solid #e5e7eb;
42
+ border-radius: 8px;
43
+ padding: 0 12px 0px 12px;
44
+ outline: none;
45
+ }
46
+ }
47
+
48
+ li.activeSidebar {
49
+ background-color: #1e88e554;
50
+ font-weight: 500;
51
+ }
52
+
53
+ li.activeSidebar::after {
54
+ content: '';
55
+ position: absolute;
56
+ top: 50%;
57
+ left: 100%;
58
+ transform: translateY(-50%);
59
+ height: 70%;
60
+ width: 4px;
61
+ background-color: #006fee;
62
+ border-radius: 4px;
63
+ }
64
+ li.activeSidebar-subset {
65
+ position: relative;
66
+ background-color: #1e88e554;
67
+ font-weight: 500;
68
+ }
69
+
70
+ li.activeSidebar-subset::after {
71
+ content: '';
72
+ position: absolute;
73
+ top: 50%;
74
+ left: 102%;
75
+ transform: translateY(-50%);
76
+ height: 70%;
77
+ width: 4px;
78
+ background-color: #006fee;
79
+ border-radius: 4px;
80
+ }
81
+
82
+ .noDisplay-scrollbar {
83
+ scrollbar-width: none; /* For Firefox */
84
+ -ms-overflow-style: none; /* For Internet Explorer and Edge */
85
+ }
86
+
87
+ .noDisplay-scrollbar::-webkit-scrollbar {
88
+ display: none; /* For Chrome, Safari, and Opera */
89
+ }
90
+ .danger {
91
+ background-color: #ffffff;
92
+ color: #f54180;
93
+ }
94
+
95
+ .success {
96
+ background-color: #ffffff;
97
+ color: #45d483;
98
+ }
99
+ .warning {
100
+ background-color: #f7b750;
101
+ color: #3b3834;
102
+ }
103
+
104
+ .info {
105
+ background-color: #d1ecf1;
106
+ color: #0c5460;
107
+ }
108
+
109
+ .primary {
110
+ background-color: #338cf1;
111
+ color: #fff;
112
+ }
113
+
114
+ .secondary {
115
+ background-color: #dddde0;
116
+ color: #000000;
117
+ }
118
+
119
+ /* ============================================================================================================================== */
120
+ .dangerBtn {
121
+ background-color: #ff0000ab;
122
+ color: #ffffff;
123
+ }
124
+
125
+ .successBtn {
126
+ background-color: #ffffff;
127
+ color: #45d483;
128
+ }
129
+ .warningBtn {
130
+ background-color: #f7b750;
131
+ color: #3b3834;
132
+ }
133
+
134
+ .infoBtn {
135
+ background-color: #d1ecf1;
136
+ color: #0c5460;
137
+ }
138
+
139
+ .primaryBtn {
140
+ background-color: #338cf1;
141
+ color: #fff;
142
+ }
143
+
144
+ .secondaryBtn {
145
+ background-color: #dddde0;
146
+ color: #000000;
147
+ }
148
+ /* ============================================================================================================================== */
149
+ .dangerPrice {
150
+ background-color: #ffffff;
151
+ color: #f54180;
152
+ }
153
+
154
+ .successPrice {
155
+ background-color: #ffffff;
156
+ color: #45d483;
157
+ }
158
+ .warningPrice {
159
+ background-color: #f7b750;
160
+ color: #3b3834;
161
+ }
162
+
163
+ .infoPrice {
164
+ background-color: #d1ecf1;
165
+ color: #0c5460;
166
+ }
167
+
168
+ .primaryPrice {
169
+ background-color: #338cf1;
170
+ color: #fff;
171
+ }
172
+
173
+ .secondaryPrice {
174
+ background-color: #dddde0;
175
+ color: #000000;
176
+ }
177
+ .modal-content {
178
+ isolation: isolate;
179
+ contain: content;
180
+ }
181
+ .no-scrollbar {
182
+ overflow-x: auto;
183
+ white-space: nowrap;
184
+ }
185
+
186
+ .no-scrollbar::-webkit-scrollbar {
187
+ display: none;
188
+ }
189
+
190
+ .no-scrollbar {
191
+ -ms-overflow-style: none; /* IE and Edge */
192
+ scrollbar-width: none; /* Firefox */
193
+ }
194
+
195
+ .placeholder-rtl::placeholder {
196
+ text-align: right;
197
+ direction: rtl;
198
+ }
@@ -1,41 +1,41 @@
1
- export default {
2
- theme: {
3
- extend: {
4
- colors: {
5
- 'white-color': '#FFFFFF',
6
- 'black-color': '#000000',
7
- 'back-ground-color': {
8
- primary: '#F5F6F9',
9
- },
10
- 'border-color': {
11
- primary: '#E9E9F0',
12
- },
13
- 'text-color': {
14
- primary: '#212121',
15
- },
16
- gray: {
17
- primary: '#E9E9F0',
18
- },
19
- blue: {
20
- primary: '#006fee',
21
- },
22
- red: {
23
- primary: '#B71C1C',
24
- },
25
- },
26
- spacing: {
27
- tiny: '10px',
28
- },
29
- borderRadius: {
30
- tiny: '10px',
31
- },
32
- fontSize: {
33
- tiny: '10px',
34
- },
35
- zIndex: {
36
- 60: '60',
37
- modal: '9000',
38
- },
39
- },
40
- },
41
- };
1
+ export default {
2
+ theme: {
3
+ extend: {
4
+ colors: {
5
+ 'white-color': '#FFFFFF',
6
+ 'black-color': '#000000',
7
+ 'back-ground-color': {
8
+ primary: '#F5F6F9',
9
+ },
10
+ 'border-color': {
11
+ primary: '#E9E9F0',
12
+ },
13
+ 'text-color': {
14
+ primary: '#212121',
15
+ },
16
+ gray: {
17
+ primary: '#E9E9F0',
18
+ },
19
+ blue: {
20
+ primary: '#006fee',
21
+ },
22
+ red: {
23
+ primary: '#B71C1C',
24
+ },
25
+ },
26
+ spacing: {
27
+ tiny: '10px',
28
+ },
29
+ borderRadius: {
30
+ tiny: '10px',
31
+ },
32
+ fontSize: {
33
+ tiny: '10px',
34
+ },
35
+ zIndex: {
36
+ 60: '60',
37
+ modal: '9000',
38
+ },
39
+ },
40
+ },
41
+ };
@@ -0,0 +1,34 @@
1
+ import type { IconType, TailwindStyleProps, SelectOption, NoResultsType } from '../DropDown/CreatableDropDown';
2
+ export type IconSourceProps = {
3
+ dropdownOpen?: IconType;
4
+ dropdownClosed?: IconType;
5
+ checkmark?: IconType;
6
+ loading?: IconType;
7
+ clear?: IconType;
8
+ create?: IconType;
9
+ xmark?: IconType;
10
+ hasAdd?: IconType;
11
+ };
12
+ export type CreatableAutoCompleteProps = {
13
+ value: SelectOption | SelectOption[] | null;
14
+ onChange: (value: string) => void;
15
+ type: "person" | "item";
16
+ onClick?: (value: SelectOption | SelectOption[] | null) => void;
17
+ onCreateOption?: (inputValue: string) => Promise<void> | void;
18
+ placeholder?: string;
19
+ isLoading?: boolean;
20
+ isDisabled?: boolean;
21
+ isClearable?: boolean;
22
+ isCreatable?: boolean;
23
+ isMultiSelect?: boolean;
24
+ noOptionsMessage?: string;
25
+ noResultsFound?: NoResultsType;
26
+ loadingMessage?: string;
27
+ createOptionMessage?: string;
28
+ className?: string;
29
+ tailwindStyle?: TailwindStyleProps;
30
+ label?: string;
31
+ iconSrc: IconSourceProps;
32
+ fetchOptions: (inputValue: string) => Promise<SelectOption[]>;
33
+ onAddClick?: (e: boolean) => void;
34
+ };
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,3 +1,4 @@
1
+ import { TabDataType } from './TabsType';
1
2
  export interface BreakCrumbType {
2
3
  sidebar: string;
3
4
  firstSubset: string;
@@ -9,4 +10,5 @@ export interface BreakCrumbPropsType {
9
10
  arrowIconSRC: string;
10
11
  activeTabName: string | null;
11
12
  breakCrumbsIconsSRC?: string;
13
+ tabsData?: TabDataType[];
12
14
  }
@@ -1,8 +1,8 @@
1
1
  export interface PrimaryButtonProps {
2
2
  disabled: boolean;
3
- text: string;
4
- type: 'submit' | 'button';
5
- classStyle: 'dangerBtn' | 'successBtn' | 'warningBtn' | 'infoBtn' | 'primaryBtn' | 'secondaryBtn';
3
+ text: string | React.JSX.Element;
4
+ type: "submit" | "button";
5
+ classStyle: "dangerBtn" | "successBtn" | "warningBtn" | "infoBtn" | "primaryBtn" | "secondaryBtn";
6
6
  svgSRC?: string;
7
7
  onClickHandler?: () => void;
8
8
  style?: {
@@ -11,4 +11,5 @@ export interface PrimaryButtonProps {
11
11
  };
12
12
  inLineCSS?: {};
13
13
  hasHover?: boolean;
14
+ tailwindStyle?: string;
14
15
  }
@@ -11,6 +11,7 @@ export type IconSourceProps = {
11
11
  clear?: IconType;
12
12
  create?: IconType;
13
13
  xmark?: IconType;
14
+ hasAdd?: IconType;
14
15
  };
15
16
  export interface TailwindStyleProps extends React.CSSProperties {
16
17
  container?: string;
@@ -27,19 +28,22 @@ export interface TailwindStyleProps extends React.CSSProperties {
27
28
  clearButton?: string;
28
29
  icon?: string;
29
30
  separator?: string;
31
+ spinAnimation?: string;
30
32
  }
31
33
  export type SelectOption = {
32
34
  label: string;
33
35
  value: string;
36
+ content: string;
34
37
  };
35
38
  export type NoResultsType = ReactNode | string | {
36
39
  icon?: IconType;
37
40
  text: string;
38
41
  };
39
42
  export type CreatableSelectProps = {
40
- options: SelectOption[] | [] | null;
41
- value: SelectOption | null;
42
- onChange: (value: SelectOption | null) => void;
43
+ options: SelectOption[] | null;
44
+ value: SelectOption | SelectOption[] | null;
45
+ onChange?: (e: React.ChangeEvent<HTMLInputElement>) => void;
46
+ onClick?: (value: SelectOption | SelectOption[] | null) => void;
43
47
  onCreateOption?: (inputValue: string) => Promise<void> | void;
44
48
  placeholder?: string;
45
49
  isLoading?: boolean;
@@ -52,6 +56,9 @@ export type CreatableSelectProps = {
52
56
  createOptionMessage?: string;
53
57
  className?: string;
54
58
  tailwindStyle?: TailwindStyleProps;
59
+ label?: string;
55
60
  iconSrc: IconSourceProps;
56
61
  fetchOptions?: (inputValue: string) => Promise<SelectOption[]>;
62
+ onAddClick: (e: boolean) => void;
63
+ isMultiSelect?: boolean;
57
64
  };
@@ -5,16 +5,18 @@ export interface TextInputPropsType {
5
5
  placeholderText: string;
6
6
  autoComplete: boolean;
7
7
  autoFocus: boolean;
8
- textError: string;
8
+ textError: string | null;
9
9
  onChangeValueHandler: (e: React.ChangeEvent<HTMLInputElement>) => void;
10
10
  onBlurHandler?: React.FocusEventHandler<HTMLInputElement>;
11
11
  onFocusHandler?: React.FocusEventHandler<HTMLInputElement>;
12
12
  onKeyUpHandler?: React.KeyboardEventHandler<HTMLInputElement>;
13
13
  onKeyDownHandler?: React.KeyboardEventHandler<HTMLInputElement>;
14
14
  disabled?: boolean;
15
- type?: 'text' | 'number';
16
- style?: {
17
- width?: string;
18
- margin?: string;
19
- };
15
+ type?: 'text' | 'number' | 'password' | 'captcha';
16
+ style?: React.CSSProperties;
17
+ startContent?: React.ReactNode;
18
+ startContentStyle?: React.CSSProperties;
19
+ placeHolderDirection?: 'rtl' | 'ltr';
20
+ applyConditionalStyles?: boolean;
21
+ maxLength?: number;
20
22
  }
@@ -21,6 +21,7 @@ export interface HeaderLayoutProps {
21
21
  refreshPageHandler: () => void;
22
22
  languages: LanguageDataType[];
23
23
  changeLanguageHandler: (language: LanguageDataType) => void;
24
+ onLogoClickHandler: () => void;
24
25
  }
25
26
  export interface iconsSRC {
26
27
  logoSRC: string;
@@ -1,4 +1,4 @@
1
- import { TabDataType } from '../TabsType';
1
+ import { TabDataType } from "../TabsType";
2
2
  export interface SidebarProps {
3
3
  isOpenSidebar: boolean;
4
4
  logoSRC: string;
@@ -24,6 +24,7 @@ export interface SecondarySubset {
24
24
  routeURL: string;
25
25
  iconSRC: string;
26
26
  keyNameLang: string;
27
+ disabled?: boolean;
27
28
  }
28
29
  export interface FirstSubset {
29
30
  id: number;