kamotive_ui 1.2.7 → 1.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.
- package/dist/Icons/ChevronLeft/ChevronLeft.d.ts +6 -0
- package/dist/Icons/ChevronLeft/ChevronLeft.js +5 -0
- package/dist/Icons/ChevronRight/ChevronRight.d.ts +6 -0
- package/dist/Icons/ChevronRight/ChevronRight.js +5 -0
- package/dist/Icons/index.d.ts +2 -0
- package/dist/Icons/index.js +2 -0
- package/dist/Intro/Welcome.module.css +4 -5
- package/dist/colors.css +1 -0
- package/dist/components/Breadcrumb/Breadcrumb.d.ts +3 -0
- package/dist/components/Breadcrumb/Breadcrumb.js +17 -0
- package/dist/components/Breadcrumb/Breadcrumb.module.css +30 -0
- package/dist/components/Breadcrumbs/Breadcrumbs.d.ts +3 -0
- package/dist/components/Breadcrumbs/Breadcrumbs.js +10 -0
- package/dist/components/Breadcrumbs/Breadcrumbs.module.css +13 -0
- package/dist/components/Button/Button.js +3 -3
- package/dist/components/ColorPicker/ColorPicker.module.css +33 -39
- package/dist/components/DateInput/DateInput.d.ts +12 -0
- package/dist/components/DateInput/DateInput.js +336 -0
- package/dist/components/DateInput/DateInput.module.css +425 -0
- package/dist/components/Dropdown/Dropdown.module.css +17 -10
- package/dist/components/FileAttach/FileAttach.js +3 -3
- package/dist/components/Input/Input.module.css +8 -8
- package/dist/components/Loader/Loader.js +3 -3
- package/dist/components/ProgressBar/ProgressBar.js +1 -2
- package/dist/components/ProgressBar/ProgressBar.module.css +1 -2
- package/dist/components/Snackbar/Snackbar.js +2 -3
- package/dist/components/Tab/Tab.js +1 -2
- package/dist/components/Tab/Tab.module.css +2 -1
- package/dist/components/Tabs/Tabs.module.css +3 -3
- package/dist/components/Tag/Tag.js +1 -1
- package/dist/components/Tag/Tag.module.css +2 -2
- package/dist/components/ToggleButton/ToggleButton.module.css +46 -47
- package/dist/components/Typography/Typography.module.css +74 -67
- package/dist/fonts.css +9 -8
- package/dist/index.d.ts +2 -1
- package/dist/index.js +1 -0
- package/dist/types/index.d.ts +53 -0
- package/package.json +2 -1
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export const ChevronLeft = ({ color = 'inherit', htmlColor, strokeWidth, }) => {
|
|
3
|
+
return (React.createElement("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: color },
|
|
4
|
+
React.createElement("path", { fill: htmlColor || 'currentColor', stroke: htmlColor || 'currentColor', strokeWidth: strokeWidth || '0', d: "M11.354 1.646a.5.5 0 0 1 0 .708L5.707 8l5.647 5.646a.5.5 0 0 1-.708.708l-6-6a.5.5 0 0 1 0-.708l6-6a.5.5 0 0 1 .708 0z" })));
|
|
5
|
+
};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export const ChevronRight = ({ color = 'inherit', htmlColor, strokeWidth, }) => {
|
|
3
|
+
return (React.createElement("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: color },
|
|
4
|
+
React.createElement("path", { fill: htmlColor || 'currentColor', stroke: htmlColor || 'currentColor', strokeWidth: strokeWidth || '0', d: "M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708z" })));
|
|
5
|
+
};
|
package/dist/Icons/index.d.ts
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
export { ChevronDown10 } from './ChevronDown/ChevronDown10';
|
|
2
|
+
export { ChevronRight } from './ChevronRight/ChevronRight';
|
|
3
|
+
export { ChevronLeft } from './ChevronLeft/ChevronLeft';
|
|
2
4
|
export { ChevronUp10 } from './ChevronUp/ChevronUp10';
|
|
3
5
|
export { IconAlarm10 } from './IconAlarm/IconAlarm10';
|
|
4
6
|
export { IconAccount10 } from './IconAccount/IconAccount10';
|
package/dist/Icons/index.js
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
export { ChevronDown10 } from './ChevronDown/ChevronDown10';
|
|
2
|
+
export { ChevronRight } from './ChevronRight/ChevronRight';
|
|
3
|
+
export { ChevronLeft } from './ChevronLeft/ChevronLeft';
|
|
2
4
|
export { ChevronUp10 } from './ChevronUp/ChevronUp10';
|
|
3
5
|
export { IconAlarm10 } from './IconAlarm/IconAlarm10';
|
|
4
6
|
export { IconAccount10 } from './IconAccount/IconAccount10';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
.h1{
|
|
2
|
-
font-family: var(--font-family);
|
|
1
|
+
.h1 {
|
|
2
|
+
font-family: var(--font-family-headers);
|
|
3
3
|
font-style: normal;
|
|
4
4
|
font-weight: 600;
|
|
5
5
|
line-height: 16.5px;
|
|
@@ -8,12 +8,11 @@
|
|
|
8
8
|
margin: 20px;
|
|
9
9
|
}
|
|
10
10
|
.body {
|
|
11
|
-
font-family: var(--font-family);
|
|
11
|
+
font-family: var(--font-family-content);
|
|
12
12
|
font-style: normal;
|
|
13
13
|
font-weight: 400;
|
|
14
14
|
line-height: 16.5px;
|
|
15
15
|
font-size: 16px;
|
|
16
16
|
color: var(--text-dark);
|
|
17
17
|
margin: 20px;
|
|
18
|
-
|
|
19
|
-
}
|
|
18
|
+
}
|
package/dist/colors.css
CHANGED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import styles from './Breadcrumb.module.css';
|
|
3
|
+
import classNames from 'classnames';
|
|
4
|
+
;
|
|
5
|
+
import { Typography } from '../Typography/Typography';
|
|
6
|
+
export const Breadcrumb = ({ onClick, active, label, icon, children }) => {
|
|
7
|
+
const handleClick = (e) => {
|
|
8
|
+
if (!active && onClick) {
|
|
9
|
+
onClick();
|
|
10
|
+
}
|
|
11
|
+
};
|
|
12
|
+
const childrenClassNames = classNames(active ? styles['children--active'] : styles['children--inactive'], styles.children);
|
|
13
|
+
const iconClassNames = classNames(childrenClassNames, styles.icon);
|
|
14
|
+
return (React.createElement("button", { className: classNames(styles.breadcrumb), onClick: handleClick },
|
|
15
|
+
icon && React.createElement("span", { className: iconClassNames }, icon),
|
|
16
|
+
React.createElement(Typography, { variant: "Body2-Medium", style: { fontWeight: '500' }, className: childrenClassNames }, label || children)));
|
|
17
|
+
};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
.breadcrumb {
|
|
2
|
+
display: flex;
|
|
3
|
+
align-items: center;
|
|
4
|
+
background: none;
|
|
5
|
+
border: none;
|
|
6
|
+
padding: 0;
|
|
7
|
+
cursor: pointer;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
.icon {
|
|
11
|
+
gap: none;
|
|
12
|
+
margin-right: 6px;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.children {
|
|
16
|
+
display: inline-flex;
|
|
17
|
+
gap: 6px;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
.children:hover {
|
|
21
|
+
text-decoration: underline;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
.children--active {
|
|
25
|
+
color: var(--text-dark);
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.children--inactive {
|
|
29
|
+
color: var(--icons-grey);
|
|
30
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import classNames from 'classnames';
|
|
3
|
+
import styles from './Breadcrumbs.module.css';
|
|
4
|
+
export const Breadcrumbs = ({ className, separator = '/', children }) => {
|
|
5
|
+
return (React.createElement("nav", { className: classNames(styles.breadcrumbs, className) }, React.Children.map(children, (child, index) => {
|
|
6
|
+
return (React.createElement(React.Fragment, { key: index },
|
|
7
|
+
child,
|
|
8
|
+
index < children.length - 1 && (React.createElement("span", { className: styles.separator }, separator))));
|
|
9
|
+
})));
|
|
10
|
+
};
|
|
@@ -82,8 +82,8 @@ export const Button = ({ label, variant = 'fill', size = 'md', style, condition,
|
|
|
82
82
|
}, [condition, error]);
|
|
83
83
|
const iconColorStyle = iconColorFn();
|
|
84
84
|
if (!buttonStyle) {
|
|
85
|
-
return React.createElement("button", { className: buttonClasses },
|
|
86
|
-
React.createElement(Typography, { variant:
|
|
85
|
+
return (React.createElement("button", { className: buttonClasses },
|
|
86
|
+
React.createElement(Typography, { variant: "Body1" }, "\u041A\u043D\u043E\u043F\u043A\u0430")));
|
|
87
87
|
}
|
|
88
88
|
return (React.createElement("button", { className: buttonClasses, style: color && !error ? {
|
|
89
89
|
'--button-color': color,
|
|
@@ -97,5 +97,5 @@ export const Button = ({ label, variant = 'fill', size = 'md', style, condition,
|
|
|
97
97
|
htmlColor: iconColorStyle,
|
|
98
98
|
strokeWidth: size === 'lg' ? '0.5' : size === 'md' ? '0.3' : '0.0',
|
|
99
99
|
}),
|
|
100
|
-
(buttonStyle === 'text' || buttonStyle === 'default') && React.createElement(Typography, { variant:
|
|
100
|
+
(buttonStyle === 'text' || buttonStyle === 'default') && (React.createElement(Typography, { variant: "Body1" }, label ? label : typeof children === 'string' && children))));
|
|
101
101
|
};
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
|
|
2
1
|
.colorPicker {
|
|
3
2
|
-webkit-appearance: none;
|
|
4
3
|
appearance: none;
|
|
@@ -9,14 +8,14 @@
|
|
|
9
8
|
padding: 0;
|
|
10
9
|
}
|
|
11
10
|
|
|
12
|
-
.colorPicker:hover{
|
|
11
|
+
.colorPicker:hover {
|
|
13
12
|
box-shadow: 0px 0px 2.9px rgba(0, 0, 0, 0.1);
|
|
14
13
|
background-color: var(--white);
|
|
15
14
|
border-radius: 50%;
|
|
16
15
|
padding: 0;
|
|
17
16
|
}
|
|
18
17
|
|
|
19
|
-
.colorPicker--defaultColor{
|
|
18
|
+
.colorPicker--defaultColor {
|
|
20
19
|
background: conic-gradient(
|
|
21
20
|
rgba(255, 59, 48) 0deg,
|
|
22
21
|
rgb(255, 59, 48) 35deg,
|
|
@@ -55,8 +54,6 @@
|
|
|
55
54
|
);
|
|
56
55
|
} */
|
|
57
56
|
|
|
58
|
-
|
|
59
|
-
|
|
60
57
|
/* Обертка для всех цветов */
|
|
61
58
|
.colorPickerWrapper {
|
|
62
59
|
display: flex;
|
|
@@ -70,7 +67,6 @@
|
|
|
70
67
|
padding: 5px;
|
|
71
68
|
}
|
|
72
69
|
|
|
73
|
-
|
|
74
70
|
/* Обертка для каждого цвета */
|
|
75
71
|
.circle {
|
|
76
72
|
border-radius: 50%;
|
|
@@ -80,7 +76,6 @@
|
|
|
80
76
|
/* margin: 3px; */
|
|
81
77
|
}
|
|
82
78
|
|
|
83
|
-
|
|
84
79
|
/* Заданный основной цвет */
|
|
85
80
|
.mainColor {
|
|
86
81
|
position: relative;
|
|
@@ -93,13 +88,13 @@
|
|
|
93
88
|
top: 50%;
|
|
94
89
|
right: -6px;
|
|
95
90
|
transform: translateY(-50%);
|
|
96
|
-
width: 1px;
|
|
91
|
+
width: 1px;
|
|
97
92
|
height: 20px;
|
|
98
|
-
background-color: var(--grey-light);
|
|
93
|
+
background-color: var(--grey-light);
|
|
99
94
|
}
|
|
100
95
|
|
|
101
96
|
/* Обертка для выбора цветов */
|
|
102
|
-
.colorPicker{
|
|
97
|
+
.colorPicker {
|
|
103
98
|
position: relative;
|
|
104
99
|
display: inline-block;
|
|
105
100
|
}
|
|
@@ -127,7 +122,7 @@
|
|
|
127
122
|
z-index: 100;
|
|
128
123
|
}
|
|
129
124
|
|
|
130
|
-
:global(.w-color-swatch){
|
|
125
|
+
:global(.w-color-swatch) {
|
|
131
126
|
padding: 10px !important;
|
|
132
127
|
border-radius: 10px !important;
|
|
133
128
|
width: fit-content !important;
|
|
@@ -139,8 +134,8 @@
|
|
|
139
134
|
}
|
|
140
135
|
|
|
141
136
|
:global(.w-color-swatch) > div:nth-child(1),
|
|
142
|
-
:global(.w-color-swatch) > div:nth-child(2){
|
|
143
|
-
|
|
137
|
+
:global(.w-color-swatch) > div:nth-child(2) {
|
|
138
|
+
display: none !important;
|
|
144
139
|
}
|
|
145
140
|
:global(.w-color-swatch) > div:nth-child(3) {
|
|
146
141
|
width: 195px !important;
|
|
@@ -148,76 +143,75 @@
|
|
|
148
143
|
border-radius: 10px !important;
|
|
149
144
|
}
|
|
150
145
|
|
|
151
|
-
:global(.w-color-swatch) > div:nth-child(4){
|
|
146
|
+
:global(.w-color-swatch) > div:nth-child(4) {
|
|
152
147
|
gap: 15px !important;
|
|
153
148
|
padding: 10px 0 !important;
|
|
154
149
|
/* width: 80%; */
|
|
155
150
|
}
|
|
156
|
-
:global(.w-color-swatch) > div:nth-child(5){
|
|
151
|
+
:global(.w-color-swatch) > div:nth-child(5) {
|
|
157
152
|
padding: 0 !important;
|
|
158
|
-
|
|
159
153
|
}
|
|
160
|
-
:global(.w-color-swatch) > div:nth-child(5) > div:nth-child(2){
|
|
154
|
+
:global(.w-color-swatch) > div:nth-child(5) > div:nth-child(2) {
|
|
161
155
|
display: none !important;
|
|
162
156
|
/* width: 80%; */
|
|
163
157
|
}
|
|
164
158
|
/* Для всех инпутов в пикере */
|
|
165
159
|
:global(.w-color-chrome) :global(.w-color-editable-input) input {
|
|
166
|
-
font-family: var(--font-family) !important;
|
|
160
|
+
font-family: var(--font-family-content) !important;
|
|
167
161
|
font-style: normal !important;
|
|
168
162
|
font-weight: 400 !important;
|
|
169
163
|
line-height: 14px !important;
|
|
170
164
|
font-size: 12px !important;
|
|
171
165
|
margin: 0 !important;
|
|
172
|
-
}
|
|
173
|
-
:global(.w-color-editable-input){
|
|
166
|
+
}
|
|
167
|
+
:global(.w-color-editable-input) {
|
|
174
168
|
margin: 0 !important;
|
|
175
169
|
max-width: 30px !important;
|
|
176
170
|
flex-direction: column-reverse !important;
|
|
177
|
-
--editable-input-box-shadow
|
|
171
|
+
--editable-input-box-shadow: none !important;
|
|
178
172
|
}
|
|
179
|
-
:global(.w-color-editable-input-rgba){
|
|
173
|
+
:global(.w-color-editable-input-rgba) {
|
|
180
174
|
justify-content: end !important;
|
|
181
175
|
}
|
|
182
176
|
|
|
183
177
|
:global(.w-color-editable-input) > span {
|
|
184
178
|
padding-top: 0 !important;
|
|
185
179
|
}
|
|
186
|
-
:global(.w-color-editable-input:nth-child(1))> input{
|
|
180
|
+
:global(.w-color-editable-input:nth-child(1)) > input {
|
|
187
181
|
border-radius: 10px 0 0 10px !important;
|
|
188
182
|
border: 1px solid var(--grey-light) !important;
|
|
189
183
|
}
|
|
190
|
-
:global(.w-color-editable-input:nth-child(2))> input{
|
|
184
|
+
:global(.w-color-editable-input:nth-child(2)) > input {
|
|
191
185
|
border-radius: 0 0 0 0px !important;
|
|
192
|
-
border: 1px solid var(--grey-light) !important;
|
|
193
|
-
border-left: none !important;
|
|
186
|
+
border: 1px solid var(--grey-light) !important;
|
|
187
|
+
border-left: none !important;
|
|
194
188
|
}
|
|
195
|
-
:global(.w-color-editable-input:nth-child(3))> input{
|
|
189
|
+
:global(.w-color-editable-input:nth-child(3)) > input {
|
|
196
190
|
border-radius: 0 0 0 0px !important;
|
|
197
191
|
border: 1px solid var(--grey-light) !important;
|
|
198
|
-
border-left: none !important;
|
|
192
|
+
border-left: none !important;
|
|
199
193
|
}
|
|
200
|
-
:global(.w-color-editable-input:nth-child(4))> input{
|
|
194
|
+
:global(.w-color-editable-input:nth-child(4)) > input {
|
|
201
195
|
border-radius: 0px 10px 10px 0px !important;
|
|
202
196
|
border: 1px solid var(--grey-light) !important;
|
|
203
|
-
border-left: none !important;
|
|
197
|
+
border-left: none !important;
|
|
204
198
|
}
|
|
205
199
|
/* Для лейблов */
|
|
206
200
|
:global(.w-color-chrome-fields) :global(.w-color-editable-input) label {
|
|
207
|
-
font-family: var(--font-family) !important;
|
|
201
|
+
font-family: var(--font-family-content) !important;
|
|
208
202
|
font-style: normal !important;
|
|
209
203
|
font-weight: 400 !important;
|
|
210
204
|
line-height: 16.5px !important;
|
|
211
205
|
font-size: 16px !important;
|
|
212
206
|
}
|
|
213
207
|
|
|
214
|
-
:global(.w-color-alpha-horizontal > div.w-color-interactive){
|
|
208
|
+
:global(.w-color-alpha-horizontal > div.w-color-interactive) {
|
|
215
209
|
border-radius: 8px !important;
|
|
216
210
|
}
|
|
217
|
-
:global(.w-color-alpha-horizontal:first-of-type > div:first-child){
|
|
211
|
+
:global(.w-color-alpha-horizontal:first-of-type > div:first-child) {
|
|
218
212
|
border-radius: 50px !important;
|
|
219
213
|
}
|
|
220
|
-
:global(.w-color-alpha-horizontal:nth-of-type(2) > div:first-child){
|
|
214
|
+
:global(.w-color-alpha-horizontal:nth-of-type(2) > div:first-child) {
|
|
221
215
|
border-radius: 50px !important;
|
|
222
216
|
}
|
|
223
217
|
|
|
@@ -229,21 +223,21 @@ border-left: none !important;
|
|
|
229
223
|
padding: 10px;
|
|
230
224
|
}
|
|
231
225
|
|
|
232
|
-
.hex{
|
|
226
|
+
.hex {
|
|
233
227
|
position: absolute;
|
|
234
228
|
bottom: 20px;
|
|
235
229
|
left: -10px;
|
|
236
230
|
}
|
|
237
|
-
.hex :global(.w-color-editable-input){
|
|
238
|
-
|
|
231
|
+
.hex :global(.w-color-editable-input) {
|
|
232
|
+
border-radius: 10px !important;
|
|
239
233
|
}
|
|
240
234
|
.hex > :global(.w-color-editable-input) > input {
|
|
241
235
|
/* padding: 0 !important; */
|
|
242
236
|
font-size: 12px !important;
|
|
243
|
-
font-family: var(--font-family) !important;
|
|
237
|
+
font-family: var(--font-family-content) !important;
|
|
244
238
|
padding: 5px !important;
|
|
245
239
|
width: 70px !important;
|
|
246
240
|
height: 45px !important;
|
|
247
|
-
border-radius: 10px !important;
|
|
241
|
+
border-radius: 10px !important;
|
|
248
242
|
text-align: center !important;
|
|
249
243
|
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { FC } from 'react';
|
|
2
|
+
import { DateInputProps } from '../../types';
|
|
3
|
+
import 'react-datepicker/dist/react-datepicker.css';
|
|
4
|
+
interface CustomDatePickerProps {
|
|
5
|
+
minDate?: Date;
|
|
6
|
+
maxDate?: Date;
|
|
7
|
+
inputClassName?: string;
|
|
8
|
+
calendarClassName?: string;
|
|
9
|
+
dateFormat?: string;
|
|
10
|
+
}
|
|
11
|
+
export declare const DateInput: FC<DateInputProps & CustomDatePickerProps>;
|
|
12
|
+
export {};
|