@vchasno/ui-kit 0.3.27 → 0.3.29
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/CHANGELOG.md +12 -0
- package/dist/Datepicker/index.cjs.js +11 -5
- package/dist/Datepicker/index.cjs.js.map +1 -1
- package/dist/Datepicker/index.js +11 -5
- package/dist/Datepicker/index.js.map +1 -1
- package/dist/Datepicker/types/components/Select/customComponents.d.ts +2 -1
- package/dist/Datepicker/types/components/TextAreaInput/TextAreaInput.d.ts +4 -4
- package/dist/Datepicker/types/components/Title/Title.d.ts +1 -0
- package/dist/Menu/types/components/Select/customComponents.d.ts +2 -1
- package/dist/Menu/types/components/TextAreaInput/TextAreaInput.d.ts +4 -4
- package/dist/Menu/types/components/Title/Title.d.ts +1 -0
- package/dist/ProjectsPopover/types/components/Select/customComponents.d.ts +2 -1
- package/dist/ProjectsPopover/types/components/TextAreaInput/TextAreaInput.d.ts +4 -4
- package/dist/ProjectsPopover/types/components/Title/Title.d.ts +1 -0
- package/dist/Select/index.cjs.js +16 -7
- package/dist/Select/index.cjs.js.map +1 -1
- package/dist/Select/index.js +16 -7
- package/dist/Select/index.js.map +1 -1
- package/dist/Select/types/components/Select/customComponents.d.ts +2 -1
- package/dist/Select/types/components/TextAreaInput/TextAreaInput.d.ts +4 -4
- package/dist/Select/types/components/Title/Title.d.ts +1 -0
- package/dist/SelectCreatable/index.cjs.js +16 -7
- package/dist/SelectCreatable/index.cjs.js.map +1 -1
- package/dist/SelectCreatable/index.js +16 -7
- package/dist/SelectCreatable/index.js.map +1 -1
- package/dist/SelectCreatable/types/components/Select/customComponents.d.ts +2 -1
- package/dist/SelectCreatable/types/components/TextAreaInput/TextAreaInput.d.ts +4 -4
- package/dist/SelectCreatable/types/components/Title/Title.d.ts +1 -0
- package/dist/Snackbar/index.cjs.js +6 -6
- package/dist/Snackbar/index.cjs.js.map +1 -1
- package/dist/Snackbar/index.js +6 -6
- package/dist/Snackbar/index.js.map +1 -1
- package/dist/Snackbar/types/components/Select/customComponents.d.ts +2 -1
- package/dist/Snackbar/types/components/TextAreaInput/TextAreaInput.d.ts +4 -4
- package/dist/Snackbar/types/components/Title/Title.d.ts +1 -0
- package/dist/css/DatePicker.global.css +54 -29
- package/dist/css/Input.global.css +1 -0
- package/dist/css/Select.global.css +11 -19
- package/dist/css/Title.global.css +4 -0
- package/dist/index.d.ts +5 -4
- package/dist/index.js +6 -6
- package/dist/index.js.map +1 -1
- package/dist/types/components/Select/customComponents.d.ts +2 -1
- package/dist/types/components/TextAreaInput/TextAreaInput.d.ts +4 -4
- package/dist/types/components/Title/Title.d.ts +1 -0
- package/package.json +1 -1
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { ClearIndicatorProps, DropdownIndicatorProps } from 'react-select';
|
|
2
|
+
import { ClearIndicatorProps, DropdownIndicatorProps, MultiValueRemoveProps } from 'react-select';
|
|
3
3
|
declare const _default: {
|
|
4
|
+
MultiValueRemove: (props: MultiValueRemoveProps<unknown, boolean, import("react-select").GroupBase<unknown>>) => React.JSX.Element;
|
|
4
5
|
DropdownIndicator: (props: DropdownIndicatorProps<unknown, boolean, import("react-select").GroupBase<unknown>>) => React.JSX.Element;
|
|
5
6
|
LoadingIndicator: () => React.JSX.Element;
|
|
6
7
|
IndicatorSeparator: () => null;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import React, { InputHTMLAttributes } from 'react';
|
|
2
2
|
import { InputProps } from '../Input';
|
|
3
|
-
import { TextareaAutosizeProps } from '@mui/base/TextareaAutosize';
|
|
4
3
|
import './TextAreaInput.global.css';
|
|
5
|
-
export interface TextAreaInputProps extends
|
|
4
|
+
export interface TextAreaInputProps extends Omit<React.TextareaHTMLAttributes<HTMLTextAreaElement>, 'children' | 'rows'>, Omit<InputProps, 'children'> {
|
|
6
5
|
textareaClassName?: string;
|
|
7
6
|
labelProps?: InputHTMLAttributes<HTMLLabelElement>;
|
|
8
|
-
|
|
7
|
+
minRows?: number;
|
|
8
|
+
maxRows?: number;
|
|
9
9
|
}
|
|
10
|
-
declare const TextAreaInput: React.ForwardRefExoticComponent<
|
|
10
|
+
declare const TextAreaInput: React.ForwardRefExoticComponent<TextAreaInputProps & React.RefAttributes<HTMLTextAreaElement>>;
|
|
11
11
|
export default TextAreaInput;
|
|
@@ -5,6 +5,7 @@ import './Title.global.css';
|
|
|
5
5
|
export interface TitleProps extends EllipsisText, TextAlign, HTMLAttributes<HTMLHeadingElement> {
|
|
6
6
|
level?: 1 | 2 | 3 | 4 | 5;
|
|
7
7
|
className?: string;
|
|
8
|
+
pretty?: boolean;
|
|
8
9
|
}
|
|
9
10
|
export declare const Title: React.ForwardRefExoticComponent<TitleProps & React.RefAttributes<HTMLHeadingElement>>;
|
|
10
11
|
export default Title;
|
|
@@ -3,6 +3,22 @@
|
|
|
3
3
|
left: 50px;
|
|
4
4
|
}
|
|
5
5
|
|
|
6
|
+
.react-datepicker-popper[data-placement^='bottom'] {
|
|
7
|
+
margin-top: -6px;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
.react-datepicker-popper[data-placement^='top'] {
|
|
11
|
+
margin-top: 6px;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
.react-datepicker-popper[data-placement^='right'] {
|
|
15
|
+
margin-left: -6px;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.react-datepicker-popper[data-placement^='left'] {
|
|
19
|
+
margin-left: 6px;
|
|
20
|
+
}
|
|
21
|
+
|
|
6
22
|
.react-datepicker-popper[data-placement^='bottom'] .react-datepicker__triangle,
|
|
7
23
|
.react-datepicker-popper[data-placement^='top'] .react-datepicker__triangle,
|
|
8
24
|
.react-datepicker__year-read-view--down-arrow,
|
|
@@ -45,7 +61,7 @@
|
|
|
45
61
|
.react-datepicker-popper[data-placement^='bottom'] .react-datepicker__triangle,
|
|
46
62
|
.react-datepicker-popper[data-placement^='bottom'] .react-datepicker__triangle::before {
|
|
47
63
|
border-top: none;
|
|
48
|
-
border-bottom-color:
|
|
64
|
+
border-bottom-color: var(--vchasno-ui-input-bg-color);
|
|
49
65
|
}
|
|
50
66
|
|
|
51
67
|
.react-datepicker-popper[data-placement^='bottom'] .react-datepicker__triangle::before {
|
|
@@ -60,7 +76,7 @@
|
|
|
60
76
|
display: block;
|
|
61
77
|
width: 7px;
|
|
62
78
|
height: 7px;
|
|
63
|
-
background-color:
|
|
79
|
+
background-color: var(--vchasno-ui-input-bg-color);
|
|
64
80
|
content: '';
|
|
65
81
|
transform: rotate(45deg);
|
|
66
82
|
}
|
|
@@ -78,7 +94,7 @@
|
|
|
78
94
|
.react-datepicker-popper[data-placement^='top'] .react-datepicker__triangle::before,
|
|
79
95
|
.react-datepicker__year-read-view--down-arrow::before,
|
|
80
96
|
.react-datepicker__month-read-view--down-arrow::before {
|
|
81
|
-
border-top-color:
|
|
97
|
+
border-top-color: var(--vchasno-ui-input-bg-color);
|
|
82
98
|
border-bottom: none;
|
|
83
99
|
}
|
|
84
100
|
|
|
@@ -96,7 +112,7 @@
|
|
|
96
112
|
display: block;
|
|
97
113
|
width: 7px;
|
|
98
114
|
height: 7px;
|
|
99
|
-
background-color:
|
|
115
|
+
background-color: var(--vchasno-ui-input-bg-color);
|
|
100
116
|
content: '';
|
|
101
117
|
transform: rotate(45deg);
|
|
102
118
|
}
|
|
@@ -107,7 +123,7 @@
|
|
|
107
123
|
padding: 10px;
|
|
108
124
|
border: 1px solid var(--vchasno-ui-calendar-color);
|
|
109
125
|
border-radius: 8px;
|
|
110
|
-
background-color:
|
|
126
|
+
background-color: var(--vchasno-ui-input-bg-color);
|
|
111
127
|
color: var(--vchasno-ui-input-font-color);
|
|
112
128
|
font-size: 0.8rem;
|
|
113
129
|
}
|
|
@@ -162,6 +178,7 @@
|
|
|
162
178
|
height: 30px;
|
|
163
179
|
padding: 5px 10px;
|
|
164
180
|
border-radius: 8px;
|
|
181
|
+
line-height: 20px;
|
|
165
182
|
white-space: nowrap;
|
|
166
183
|
}
|
|
167
184
|
|
|
@@ -239,27 +256,11 @@
|
|
|
239
256
|
z-index: 100;
|
|
240
257
|
}
|
|
241
258
|
|
|
242
|
-
.react-datepicker-popper[data-placement^='bottom'] {
|
|
243
|
-
margin-top: 8px;
|
|
244
|
-
}
|
|
245
|
-
|
|
246
|
-
.react-datepicker-popper[data-placement^='top'] {
|
|
247
|
-
margin-bottom: 8px;
|
|
248
|
-
}
|
|
249
|
-
|
|
250
|
-
.react-datepicker-popper[data-placement^='right'] {
|
|
251
|
-
margin-left: 6px;
|
|
252
|
-
}
|
|
253
|
-
|
|
254
259
|
.react-datepicker-popper[data-placement^='right'] .react-datepicker__triangle {
|
|
255
260
|
right: 42px;
|
|
256
261
|
left: auto;
|
|
257
262
|
}
|
|
258
263
|
|
|
259
|
-
.react-datepicker-popper[data-placement^='left'] {
|
|
260
|
-
margin-right: 6px;
|
|
261
|
-
}
|
|
262
|
-
|
|
263
264
|
.react-datepicker-popper[data-placement^='left'] .react-datepicker__triangle {
|
|
264
265
|
right: auto;
|
|
265
266
|
left: 42px;
|
|
@@ -392,17 +393,39 @@
|
|
|
392
393
|
top: 0;
|
|
393
394
|
right: 35px;
|
|
394
395
|
bottom: 0;
|
|
395
|
-
width:
|
|
396
|
-
height:
|
|
396
|
+
width: 20px;
|
|
397
|
+
height: 20px;
|
|
397
398
|
border: 0;
|
|
398
399
|
margin: auto;
|
|
399
|
-
background-
|
|
400
|
-
background-repeat: no-repeat;
|
|
401
|
-
background-size: contain;
|
|
400
|
+
background-color: transparent;
|
|
402
401
|
cursor: pointer;
|
|
403
402
|
outline: none;
|
|
404
403
|
}
|
|
405
404
|
|
|
405
|
+
.vchasno-ui-date-picker__wrapper .vchasno-ui-date-picker__custom-close-icon {
|
|
406
|
+
position: absolute;
|
|
407
|
+
top: 50%;
|
|
408
|
+
right: 35px;
|
|
409
|
+
width: 20px;
|
|
410
|
+
height: 20px;
|
|
411
|
+
color: var(--vchasno-ui-input-border-color-default);
|
|
412
|
+
pointer-events: none;
|
|
413
|
+
transform: translateY(-50%) scale(0);
|
|
414
|
+
transition:
|
|
415
|
+
color var(--vchasno-ui-transition-duration-sec, 0.3s),
|
|
416
|
+
transform var(--vchasno-ui-transition-duration-sec, 0.3s);
|
|
417
|
+
}
|
|
418
|
+
|
|
419
|
+
.vchasno-ui-date-picker__wrapper:has(.react-datepicker__close-icon)
|
|
420
|
+
.vchasno-ui-date-picker__custom-close-icon {
|
|
421
|
+
transform: translateY(-50%) scale(1);
|
|
422
|
+
}
|
|
423
|
+
|
|
424
|
+
.vchasno-ui-date-picker__wrapper:has(.react-datepicker__close-icon:hover)
|
|
425
|
+
.vchasno-ui-date-picker__custom-close-icon {
|
|
426
|
+
color: var(--vchasno-ui-calendar-color);
|
|
427
|
+
}
|
|
428
|
+
|
|
406
429
|
.react-datepicker__today-button {
|
|
407
430
|
padding: 5px 0;
|
|
408
431
|
border-top: 1px solid #aeaeae;
|
|
@@ -518,7 +541,7 @@
|
|
|
518
541
|
border: 1px solid var(--vchasno-ui-input-border-color-default, #b6cadb);
|
|
519
542
|
border-radius: 8px;
|
|
520
543
|
appearance: none;
|
|
521
|
-
background:
|
|
544
|
+
background: var(--vchasno-ui-input-bg-color);
|
|
522
545
|
font-size: var(--vchasno-ui-input-font-size, 0.8rem);
|
|
523
546
|
line-height: calc(var(--vchasno-ui-input-font-size, 0.8rem) * 2);
|
|
524
547
|
outline: 1px solid transparent;
|
|
@@ -566,7 +589,7 @@
|
|
|
566
589
|
font-size: 12px;
|
|
567
590
|
}
|
|
568
591
|
|
|
569
|
-
.vchasno-ui-date-picker__wrapper >
|
|
592
|
+
.vchasno-ui-date-picker__wrapper > .vchasno-ui-date-picker__custom-calendar-icon {
|
|
570
593
|
position: absolute;
|
|
571
594
|
top: 50%;
|
|
572
595
|
right: 10px;
|
|
@@ -575,7 +598,9 @@
|
|
|
575
598
|
transition: color var(--vchasno-ui-transition-duration-sec, 0.3s);
|
|
576
599
|
}
|
|
577
600
|
|
|
578
|
-
label[class^='vchasno-ui-']:focus-within
|
|
601
|
+
label[class^='vchasno-ui-']:focus-within
|
|
602
|
+
.vchasno-ui-date-picker__wrapper
|
|
603
|
+
> .vchasno-ui-date-picker__custom-calendar-icon {
|
|
579
604
|
color: var(--vchasno-ui-calendar-color);
|
|
580
605
|
}
|
|
581
606
|
|
|
@@ -88,7 +88,7 @@
|
|
|
88
88
|
.vchasno-ui-select
|
|
89
89
|
.vchasno-ui-select__control--menu-is-open
|
|
90
90
|
.vchasno-ui-select__dropdown-indicator {
|
|
91
|
-
color: var(--vchasno-ui-
|
|
91
|
+
color: var(--vchasno-ui-input-border-color-focused, #6b5fff);
|
|
92
92
|
transition:
|
|
93
93
|
background-color var(--vchasno-ui-transition-duration-sec, 0.3s),
|
|
94
94
|
color var(--vchasno-ui-transition-duration-sec, 0.3s);
|
|
@@ -136,23 +136,13 @@
|
|
|
136
136
|
}
|
|
137
137
|
|
|
138
138
|
.vchasno-ui-select .vchasno-ui-select__clear-indicator {
|
|
139
|
-
padding:
|
|
140
|
-
border-radius:
|
|
139
|
+
padding: 0;
|
|
140
|
+
border-radius: 4px;
|
|
141
141
|
color: var(--vchasno-ui-input-font-color);
|
|
142
|
-
outline: 3px solid transparent;
|
|
143
|
-
transition:
|
|
144
|
-
outline-color var(--vchasno-ui-transition-duration-sec, 0.3s),
|
|
145
|
-
background-color var(--vchasno-ui-transition-duration-sec, 0.3s);
|
|
146
142
|
}
|
|
147
143
|
|
|
148
144
|
.vchasno-ui-select .vchasno-ui-select__clear-indicator:hover {
|
|
149
|
-
background-color: rgb(0 0 0 / 10%);
|
|
150
145
|
cursor: pointer;
|
|
151
|
-
outline-color: rgb(0 0 0 / 10%);
|
|
152
|
-
}
|
|
153
|
-
|
|
154
|
-
.vchasno-ui-select .vchasno-ui-select__clear-indicator svg {
|
|
155
|
-
transform: scale(0.6);
|
|
156
146
|
}
|
|
157
147
|
|
|
158
148
|
.vchasno-ui-select .vchasno-ui-select__option--is-selected,
|
|
@@ -180,19 +170,21 @@
|
|
|
180
170
|
padding: 0;
|
|
181
171
|
padding-right: 3px;
|
|
182
172
|
background-color: transparent;
|
|
173
|
+
color: var(--vchasno-ui-label-color-default);
|
|
183
174
|
transition: color var(--vchasno-ui-transition-duration-sec, 0.3s);
|
|
184
175
|
}
|
|
185
176
|
|
|
186
|
-
.vchasno-ui-select .vchasno-ui-select__multi-value__remove svg {
|
|
187
|
-
width: 16px;
|
|
188
|
-
height: 16px;
|
|
189
|
-
}
|
|
190
|
-
|
|
191
177
|
.vchasno-ui-select .vchasno-ui-select__multi-value__remove:hover {
|
|
192
178
|
background-color: transparent;
|
|
179
|
+
color: var(--vchasno-ui-input-color-error);
|
|
193
180
|
cursor: pointer;
|
|
194
181
|
}
|
|
195
182
|
|
|
183
|
+
.vchasno-ui-select .vchasno-ui-select__multi-value__remove svg {
|
|
184
|
+
width: 20px;
|
|
185
|
+
height: 20px;
|
|
186
|
+
}
|
|
187
|
+
|
|
196
188
|
.vchasno-ui-select .vchasno-ui-select__indicators {
|
|
197
189
|
padding-right: 5px;
|
|
198
190
|
}
|
|
@@ -202,7 +194,7 @@
|
|
|
202
194
|
}
|
|
203
195
|
|
|
204
196
|
.vchasno-ui-select .vchasno-ui-select__multi-value__label {
|
|
205
|
-
padding: 6px;
|
|
197
|
+
padding: 6px 0 6px 6px;
|
|
206
198
|
font-size: 14px;
|
|
207
199
|
}
|
|
208
200
|
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import React, { HTMLAttributes, ButtonHTMLAttributes, InputHTMLAttributes } from 'react';
|
|
2
2
|
import { MaskedInputProps } from 'react-text-mask';
|
|
3
|
-
import { TextareaAutosizeProps } from '@mui/base/TextareaAutosize';
|
|
4
3
|
import * as _emotion_styled from '@emotion/styled';
|
|
5
4
|
import * as _mui_system from '@mui/system';
|
|
6
5
|
import * as _mui_material_styles from '@mui/material/styles';
|
|
@@ -116,6 +115,7 @@ declare const Text: React.ForwardRefExoticComponent<TextProps & React.RefAttribu
|
|
|
116
115
|
interface TitleProps extends EllipsisText, TextAlign, HTMLAttributes<HTMLHeadingElement> {
|
|
117
116
|
level?: 1 | 2 | 3 | 4 | 5;
|
|
118
117
|
className?: string;
|
|
118
|
+
pretty?: boolean;
|
|
119
119
|
}
|
|
120
120
|
declare const Title: React.ForwardRefExoticComponent<TitleProps & React.RefAttributes<HTMLHeadingElement>>;
|
|
121
121
|
|
|
@@ -126,12 +126,13 @@ interface ParagraphProps extends EllipsisText, TextAlign, HTMLAttributes<HTMLPar
|
|
|
126
126
|
}
|
|
127
127
|
declare const Paragraph: React.ForwardRefExoticComponent<ParagraphProps & React.RefAttributes<HTMLParagraphElement>>;
|
|
128
128
|
|
|
129
|
-
interface TextAreaInputProps extends
|
|
129
|
+
interface TextAreaInputProps extends Omit<React.TextareaHTMLAttributes<HTMLTextAreaElement>, 'children' | 'rows'>, Omit<InputProps, 'children'> {
|
|
130
130
|
textareaClassName?: string;
|
|
131
131
|
labelProps?: InputHTMLAttributes<HTMLLabelElement>;
|
|
132
|
-
|
|
132
|
+
minRows?: number;
|
|
133
|
+
maxRows?: number;
|
|
133
134
|
}
|
|
134
|
-
declare const TextAreaInput: React.ForwardRefExoticComponent<
|
|
135
|
+
declare const TextAreaInput: React.ForwardRefExoticComponent<TextAreaInputProps & React.RefAttributes<HTMLTextAreaElement>>;
|
|
135
136
|
|
|
136
137
|
type AlertType = 'error' | 'warning' | 'success' | 'info' | 'config';
|
|
137
138
|
type IconType = 'info' | 'cross' | 'error' | 'warning' | 'success' | 'config';
|
package/dist/index.js
CHANGED
|
@@ -278,7 +278,7 @@ var LabelText = function (_a) {
|
|
|
278
278
|
React$1.createElement("sup", null, "*")));
|
|
279
279
|
};
|
|
280
280
|
|
|
281
|
-
var css_248z$i = ".vchasno-ui-input {\n display: inline-flex;\n max-width: 100%;\n flex-direction: column;\n gap: 5px;\n}\n\n.vchasno-ui-input input::placeholder {\n color: var(--vchasno-ui-input-border-color-default);\n font-size: var(--vchasno-ui-input-font-size);\n line-height: calc(var(--vchasno-ui-input-font-size) * 1.2);\n transition: color var(--vchasno-ui-transition-duration-sec, 0.3s);\n}\n\n.vchasno-ui-input .vchasno-ui-text-input,\n.vchasno-ui-input .vchasno-ui-mask-input {\n flex-grow: 1;\n}\n\n.vchasno-ui-input.--wide {\n width: 100%;\n}\n\n.vchasno-ui-input__wrapper {\n position: relative;\n display: flex;\n min-height: 50px;\n box-sizing: border-box;\n align-items: center;\n padding-right: 33px;\n padding-left: 16px;\n border: 1px solid var(--vchasno-ui-input-border-color-default);\n border-radius: 8px;\n background-color: var(--vchasno-ui-input-bg-color);\n outline: solid 3px transparent;\n transition: border var(--vchasno-ui-transition-duration-sec, 0.3s);\n}\n\n.vchasno-ui-input__wrapper > input {\n max-width: 100%;\n}\n\n.vchasno-ui-input__wrapper__start-element {\n display: flex;\n flex-grow: 0;\n flex-shrink: 0;\n align-items: center;\n font-size: var(--vchasno-ui-input-font-size, 14px);\n line-height: var(--vchasno-ui-input-font-size, 14px);\n}\n\n.vchasno-ui-input__feedback {\n position: absolute;\n top: 10px;\n right: 10px;\n display: block;\n width: 18px;\n height: 18px;\n}\n\n.vchasno-ui-input .vchasno-ui-spinner__svg__circle {\n stroke: var(--vchasno-ui-input-border-color-focused);\n}\n\n.vchasno-ui-input.--disabled .vchasno-ui-input__wrapper {\n background-color: var(--vchasno-ui-input-bg-color-disabled);\n color: var(--vchasno-ui-input-font-color-disabled);\n}\n\n.vchasno-ui-input:not(.--disabled) .vchasno-ui-input__wrapper:hover {\n cursor: text;\n}\n\n.vchasno-ui-input:not(.--disabled):hover .vchasno-ui-input__wrapper,\n.vchasno-ui-input:not(.--disabled):focus-within .vchasno-ui-input__wrapper {\n border-color: var(--vchasno-ui-input-border-color-focused);\n outline-color: var(--vchasno-ui-input-outline-color-focused);\n}\n\n.vchasno-ui-input:not(.--disabled).--error .vchasno-ui-input__wrapper {\n border-color: var(--vchasno-ui-input-color-error);\n outline-color: var(--vchasno-ui-input-outline-color-error);\n}\n\n.vchasno-ui-input.--disabled,\n.vchasno-ui-input.--disabled * {\n cursor: not-allowed;\n opacity: 0.8;\n}\n";
|
|
281
|
+
var css_248z$i = ".vchasno-ui-input {\n display: inline-flex;\n max-width: 100%;\n flex-direction: column;\n gap: 5px;\n}\n\n.vchasno-ui-input input::placeholder {\n color: var(--vchasno-ui-input-border-color-default);\n font-size: var(--vchasno-ui-input-font-size);\n line-height: calc(var(--vchasno-ui-input-font-size) * 1.2);\n transition: color var(--vchasno-ui-transition-duration-sec, 0.3s);\n}\n\n.vchasno-ui-input .vchasno-ui-text-input,\n.vchasno-ui-input .vchasno-ui-mask-input {\n flex-grow: 1;\n}\n\n.vchasno-ui-input.--wide {\n width: 100%;\n}\n\n.vchasno-ui-input__wrapper {\n position: relative;\n display: flex;\n min-height: 50px;\n box-sizing: border-box;\n align-items: center;\n padding-right: 33px;\n padding-left: 16px;\n border: 1px solid var(--vchasno-ui-input-border-color-default);\n border-radius: 8px;\n background-color: var(--vchasno-ui-input-bg-color);\n outline: solid 3px transparent;\n transition: border var(--vchasno-ui-transition-duration-sec, 0.3s);\n}\n\n.vchasno-ui-input__wrapper > input {\n max-width: 100%;\n}\n\n.vchasno-ui-input__wrapper__start-element {\n display: flex;\n flex-grow: 0;\n flex-shrink: 0;\n align-items: center;\n margin-right: 5px;\n font-size: var(--vchasno-ui-input-font-size, 14px);\n line-height: var(--vchasno-ui-input-font-size, 14px);\n}\n\n.vchasno-ui-input__feedback {\n position: absolute;\n top: 10px;\n right: 10px;\n display: block;\n width: 18px;\n height: 18px;\n}\n\n.vchasno-ui-input .vchasno-ui-spinner__svg__circle {\n stroke: var(--vchasno-ui-input-border-color-focused);\n}\n\n.vchasno-ui-input.--disabled .vchasno-ui-input__wrapper {\n background-color: var(--vchasno-ui-input-bg-color-disabled);\n color: var(--vchasno-ui-input-font-color-disabled);\n}\n\n.vchasno-ui-input:not(.--disabled) .vchasno-ui-input__wrapper:hover {\n cursor: text;\n}\n\n.vchasno-ui-input:not(.--disabled):hover .vchasno-ui-input__wrapper,\n.vchasno-ui-input:not(.--disabled):focus-within .vchasno-ui-input__wrapper {\n border-color: var(--vchasno-ui-input-border-color-focused);\n outline-color: var(--vchasno-ui-input-outline-color-focused);\n}\n\n.vchasno-ui-input:not(.--disabled).--error .vchasno-ui-input__wrapper {\n border-color: var(--vchasno-ui-input-color-error);\n outline-color: var(--vchasno-ui-input-outline-color-error);\n}\n\n.vchasno-ui-input.--disabled,\n.vchasno-ui-input.--disabled * {\n cursor: not-allowed;\n opacity: 0.8;\n}\n";
|
|
282
282
|
styleInject(css_248z$i);
|
|
283
283
|
|
|
284
284
|
var Input = function (_a) {
|
|
@@ -290,7 +290,7 @@ var Input = function (_a) {
|
|
|
290
290
|
'--error': error,
|
|
291
291
|
}, className) }, labelProps),
|
|
292
292
|
React$1.createElement("span", { className: "vchasno-ui-input__wrapper" },
|
|
293
|
-
React$1.createElement("span", { className: "vchasno-ui-input__wrapper__start-element" }, startElement),
|
|
293
|
+
startElement && (React$1.createElement("span", { className: "vchasno-ui-input__wrapper__start-element" }, startElement)),
|
|
294
294
|
children,
|
|
295
295
|
React$1.createElement(LabelText, null, label),
|
|
296
296
|
React$1.createElement("span", { className: "vchasno-ui-input__feedback" }, loading && React$1.createElement(Spinner, { height: "100%" })),
|
|
@@ -443,12 +443,12 @@ Text.displayName = 'Text';
|
|
|
443
443
|
var css_248z$d = ".--text-start {\n text-align: start;\n}\n\n.--text-center {\n text-align: center;\n}\n\n.--text-end {\n text-align: end;\n}\n\n.--text-justify {\n text-align: justify;\n}\n";
|
|
444
444
|
styleInject(css_248z$d);
|
|
445
445
|
|
|
446
|
-
var css_248z$c = ".vchasno-ui-title {\n color: var(--vchasno-ui-text-primary-color, #333);\n}\n\n.vchasno-ui-title.--ellipsis {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\nh1.vchasno-ui-title,\n.vchasno-ui-title h1 {\n font-size: 32px;\n font-weight: 500;\n line-height: 1.35;\n}\n\nh2.vchasno-ui-title,\n.vchasno-ui-title h2 {\n font-size: 30px;\n font-weight: 500;\n line-height: 1.35;\n}\n\nh3.vchasno-ui-title,\n.vchasno-ui-title h3 {\n font-size: 24px;\n font-weight: 500;\n line-height: 1.35;\n}\n\nh4.vchasno-ui-title,\n.vchasno-ui-title h4 {\n font-size: 20px;\n font-weight: 400;\n line-height: 1.4;\n}\n\nh5.vchasno-ui-title,\n.vchasno-ui-title h5 {\n font-size: 16px;\n font-weight: 400;\n line-height: 1.5;\n}\n";
|
|
446
|
+
var css_248z$c = ".vchasno-ui-title {\n color: var(--vchasno-ui-text-primary-color, #333);\n}\n\n.vchasno-ui-title.--pretty {\n text-wrap: pretty;\n}\n\n.vchasno-ui-title.--ellipsis {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\nh1.vchasno-ui-title,\n.vchasno-ui-title h1 {\n font-size: 32px;\n font-weight: 500;\n line-height: 1.35;\n}\n\nh2.vchasno-ui-title,\n.vchasno-ui-title h2 {\n font-size: 30px;\n font-weight: 500;\n line-height: 1.35;\n}\n\nh3.vchasno-ui-title,\n.vchasno-ui-title h3 {\n font-size: 24px;\n font-weight: 500;\n line-height: 1.35;\n}\n\nh4.vchasno-ui-title,\n.vchasno-ui-title h4 {\n font-size: 20px;\n font-weight: 400;\n line-height: 1.4;\n}\n\nh5.vchasno-ui-title,\n.vchasno-ui-title h5 {\n font-size: 16px;\n font-weight: 400;\n line-height: 1.5;\n}\n";
|
|
447
447
|
styleInject(css_248z$c);
|
|
448
448
|
|
|
449
449
|
var Title = React$1.forwardRef(function (_a, ref) {
|
|
450
|
-
var _b = _a.level, level = _b === void 0 ? 1 : _b, className = _a.className, _c = _a.ellipsis, ellipsis = _c === void 0 ? false : _c, textAlign = _a.textAlign, rest = __rest(_a, ["level", "className", "ellipsis", "textAlign"]);
|
|
451
|
-
var classes = cn('vchasno-ui-title', className, { '--ellipsis': ellipsis }, textAlign && "--text-".concat(textAlign));
|
|
450
|
+
var _b = _a.level, level = _b === void 0 ? 1 : _b, className = _a.className, _c = _a.ellipsis, ellipsis = _c === void 0 ? false : _c, textAlign = _a.textAlign, _d = _a.pretty, pretty = _d === void 0 ? true : _d, rest = __rest(_a, ["level", "className", "ellipsis", "textAlign", "pretty"]);
|
|
451
|
+
var classes = cn('vchasno-ui-title', className, { '--ellipsis': ellipsis, '--pretty': pretty }, textAlign && "--text-".concat(textAlign));
|
|
452
452
|
switch (level) {
|
|
453
453
|
case 2:
|
|
454
454
|
return React$1.createElement("h2", __assign({}, rest, { ref: ref, className: classes }));
|
|
@@ -2874,7 +2874,7 @@ styleInject(css_248z$a);
|
|
|
2874
2874
|
var TextAreaInput = React$1.forwardRef(function (_a, ref) {
|
|
2875
2875
|
var className = _a.className, disabled = _a.disabled, startElement = _a.startElement, endElement = _a.endElement, error = _a.error, label = _a.label, hint = _a.hint, wide = _a.wide, required = _a.required, loading = _a.loading, minRows = _a.minRows, maxRows = _a.maxRows, textareaClassName = _a.textareaClassName, labelProps = _a.labelProps, rest = __rest(_a, ["className", "disabled", "startElement", "endElement", "error", "label", "hint", "wide", "required", "loading", "minRows", "maxRows", "textareaClassName", "labelProps"]);
|
|
2876
2876
|
return (React$1.createElement(Input, { required: required, wide: wide, className: cn(className, 'vchasno-ui-textarea-input-container'), loading: loading, disabled: disabled, label: label, error: error, hint: hint, endElement: endElement, labelProps: labelProps, startElement: startElement },
|
|
2877
|
-
React$1.createElement(TextareaAutosize, __assign({}, rest, { ref: ref, minRows: minRows, maxRows: maxRows, required: required, disabled: disabled,
|
|
2877
|
+
React$1.createElement(TextareaAutosize, __assign({}, rest, { ref: ref, minRows: minRows, maxRows: maxRows, required: required, disabled: disabled, className: cn('vchasno-ui-textarea-input', textareaClassName) }))));
|
|
2878
2878
|
});
|
|
2879
2879
|
TextAreaInput.displayName = 'TextAreaInput';
|
|
2880
2880
|
|