@vev/silke 1.0.16 → 1.0.17

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 (58) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/dist/chunk-SOFGXMET.js +22 -0
  3. package/dist/{chunk-LAB2YEXC.js.map → chunk-SOFGXMET.js.map} +3 -3
  4. package/dist/index.js +43 -8
  5. package/dist/index.js.LEGAL.txt +6 -10
  6. package/dist/index.js.map +4 -4
  7. package/dist/{silke-code-editor-WEBZ7JXL.js → silke-code-editor-3Y2KM5KB.js} +3 -3
  8. package/dist/styles.css +411 -482
  9. package/package.json +4 -4
  10. package/src/components/silke-autocomplete-field/autocomplete-item.tsx +33 -7
  11. package/src/components/silke-autocomplete-field/autocomplete-tags.tsx +6 -2
  12. package/src/components/silke-autocomplete-field/autocomplete-types.ts +4 -0
  13. package/src/components/silke-autocomplete-field/silke-autocomplete-field.mdx +67 -24
  14. package/src/components/silke-autocomplete-field/silke-autocomplete-field.scss +32 -13
  15. package/src/components/silke-autocomplete-field/silke-autocomplete-field.spec.tsx +24 -109
  16. package/src/components/silke-autocomplete-field/silke-autocomplete-field.tsx +304 -220
  17. package/src/components/silke-box/silke-box.scss +9 -10
  18. package/src/components/silke-box/silke-box.tsx +9 -0
  19. package/src/components/silke-button/silke-button.scss +3 -3
  20. package/src/components/silke-color-picker/silke-color-info.tsx +2 -18
  21. package/src/components/silke-context-menu/silke-context-menu.tsx +0 -1
  22. package/src/components/silke-css-number-field/silke-css-number-field.mdx +43 -4
  23. package/src/components/silke-css-number-field/silke-css-number-field.scss +47 -14
  24. package/src/components/silke-css-number-field/silke-css-number-field.tsx +114 -186
  25. package/src/components/silke-css-number-field/utils.ts +25 -0
  26. package/src/components/silke-drawer/silke-drawer.tsx +0 -14
  27. package/src/components/silke-form/silke-form.tsx +1 -1
  28. package/src/components/silke-form-schema/fields/array-field.tsx +1 -1
  29. package/src/components/silke-form-schema/fields/utils/generate-title.ts +5 -4
  30. package/src/components/silke-image/silke-image.scss +2 -2
  31. package/src/components/silke-modal/silke-modal.tsx +11 -2
  32. package/src/components/silke-navigation-link/silke-navigation-link.scss +12 -2
  33. package/src/components/silke-navigation-link/silke-navigation-link.tsx +21 -17
  34. package/src/components/silke-notification/silke-notification.scss +1 -1
  35. package/src/components/silke-overflow-menu/silke-overflow-menu.tsx +1 -2
  36. package/src/components/silke-popover/silke-popover.tsx +1 -20
  37. package/src/components/silke-select-field/silke-select-field.mdx +137 -7
  38. package/src/components/silke-select-field/silke-select-field.spec.tsx +44 -126
  39. package/src/components/silke-sortable-list/silke-nested-sortable-item.tsx +17 -2
  40. package/src/components/silke-sortable-list/silke-nested-sortable-list.tsx +6 -2
  41. package/src/components/silke-sortable-list/silke-nested-sortable-utils.ts +6 -0
  42. package/src/components/silke-table/silke-table.tsx +1 -1
  43. package/src/components/silke-tag/silke-tag.tsx +1 -1
  44. package/src/components/silke-text-field/silke-text-field-item.tsx +12 -7
  45. package/src/components/silke-text-field/silke-text-field-outline.tsx +39 -42
  46. package/src/components/silke-text-field/silke-text-field.mdx +73 -6
  47. package/src/components/silke-text-field/silke-text-field.scss +153 -247
  48. package/src/components/silke-text-field/silke-text-field.tsx +4 -3
  49. package/src/components/silke-tooltip/silke-icon-tooltip.tsx +2 -1
  50. package/src/docs/app.tsx +9 -16
  51. package/src/hooks/form/use-form-field.ts +1 -1
  52. package/src/hooks/index.ts +1 -0
  53. package/src/hooks/use-uniq-id.ts +6 -0
  54. package/src/icons.tsx +8 -2
  55. package/dist/chunk-LAB2YEXC.js +0 -22
  56. /package/dist/{chunk-LAB2YEXC.js.LEGAL.txt → chunk-SOFGXMET.js.LEGAL.txt} +0 -0
  57. /package/dist/{silke-code-editor-WEBZ7JXL.js.LEGAL.txt → silke-code-editor-3Y2KM5KB.js.LEGAL.txt} +0 -0
  58. /package/dist/{silke-code-editor-WEBZ7JXL.js.map → silke-code-editor-3Y2KM5KB.js.map} +0 -0
@@ -5,6 +5,7 @@ import { SilkeIcon } from '../silke-icon';
5
5
  import { SilkeText } from '../silke-text/silke-text';
6
6
  import styles from './silke-text-field.scss';
7
7
  import { useTextFieldContext } from './text-field-context';
8
+ import { SilkeTextFieldItem } from './silke-text-field-item';
8
9
 
9
10
  type InputSize = 'tiny' | 'small' | 'base' | 'large';
10
11
 
@@ -28,15 +29,16 @@ export type SilkeTextFieldOutlineProps = {
28
29
  // Makes text field flex
29
30
  flex?: boolean;
30
31
  size?: BoxSize;
31
- kind?: 'default' | 'ghost' | 'secondary';
32
+ kind?: 'default' | 'ghost' | 'zombie';
32
33
  width?: number;
33
34
  /** Flex gap added to the container with the children */
34
35
  gap?: BoxSpace;
35
36
  /** Horizontal padding added to the container with the children */
36
37
  hPad?: BoxSpace;
37
38
  hAlign?: BoxProps['hAlign'];
39
+ vAlign?: BoxProps['vAlign'];
38
40
  /** Inline will add the label before the input field */
39
- inline?: boolean;
41
+ inline?: boolean | 'label-inside';
40
42
  /** Width of the inline label */
41
43
  inlineLabelWidth?: number;
42
44
  /** Field required input (if string the string will be used as error msg) */
@@ -49,6 +51,7 @@ export type SilkeTextFieldOutlineProps = {
49
51
  /** Id to link help label with (input should have aria-describedby) */
50
52
  helpId?: string;
51
53
  labelId?: string;
54
+ labelUsingAria?: boolean;
52
55
  onClick?: (e: React.MouseEvent<HTMLElement>) => void;
53
56
  onMouseDown?: (e: React.MouseEvent<HTMLElement>) => void;
54
57
  disabled?: boolean;
@@ -64,6 +67,7 @@ export const SilkeTextFieldOutline = React.forwardRef<HTMLDivElement, SilkeTextF
64
67
  gap,
65
68
  hPad,
66
69
  hAlign,
70
+ vAlign,
67
71
  inline,
68
72
  children,
69
73
  help,
@@ -71,6 +75,7 @@ export const SilkeTextFieldOutline = React.forwardRef<HTMLDivElement, SilkeTextF
71
75
  helpId,
72
76
  label,
73
77
  labelId,
78
+ labelUsingAria,
74
79
  width,
75
80
  flex,
76
81
  onClick,
@@ -96,6 +101,20 @@ export const SilkeTextFieldOutline = React.forwardRef<HTMLDivElement, SilkeTextF
96
101
 
97
102
  const showError = Boolean(error);
98
103
  const showHelp = Boolean((help || helpRight) && !error);
104
+ const boxSize: BoxSize = size === 'xs' ? 's' : size === 's' ? 'base' : 'm';
105
+
106
+ const labelComponent = label && (
107
+ <SilkeText
108
+ className={styles.label}
109
+ tag="label"
110
+ id={labelUsingAria ? labelId : undefined}
111
+ htmlFor={!labelUsingAria ? labelId : undefined}
112
+ color="neutral-100"
113
+ style={inlineLabelWidth ? { width: `${inlineLabelWidth}px` } : undefined}
114
+ >
115
+ {label}
116
+ </SilkeText>
117
+ );
99
118
  return (
100
119
  <SilkeBox
101
120
  data-size={`data-input-${mappedSize}`}
@@ -108,63 +127,41 @@ export const SilkeTextFieldOutline = React.forwardRef<HTMLDivElement, SilkeTextF
108
127
  onClick={onClick}
109
128
  onMouseDown={onMouseDown}
110
129
  >
111
- {label && (
112
- <SilkeText
113
- className={styles.label}
114
- tag="label"
115
- htmlFor={labelId}
116
- color="neutral-100"
117
- style={inlineLabelWidth ? { width: `${inlineLabelWidth}px` } : undefined}
118
- >
119
- {label}
120
- </SilkeText>
121
- )}
130
+ {inline !== 'label-inside' && labelComponent}
122
131
 
123
132
  <ButtonContext kind="ghost" size="base">
124
133
  <SilkeBox
125
134
  gap={gap}
126
135
  hPad={hPad}
127
136
  hAlign={hAlign}
137
+ vAlign={vAlign}
128
138
  className={styles.field}
129
- flex={inline}
139
+ flex={!!inline}
130
140
  ref={ref}
131
141
  >
142
+ {labelComponent && inline === 'label-inside' && (
143
+ <SilkeTextFieldItem before minWidth={boxSize} hPad="xs">
144
+ {labelComponent}
145
+ </SilkeTextFieldItem>
146
+ )}
132
147
  {children}
133
- <div className={styles.border} />
134
148
  </SilkeBox>
135
149
  </ButtonContext>
136
150
 
137
151
  {!inline && (
138
- <>
139
- {showHelp && (
140
- <SilkeBox hAlign="spread" className={styles.help}>
141
- {help && (
142
- <SilkeText tag="span" flex color="neutral-80" id={helpId}>
143
- {help}
144
- </SilkeText>
145
- )}
146
- {helpRight && <SilkeText>{helpRight}</SilkeText>}
147
- </SilkeBox>
152
+ <SilkeBox hAlign="spread" className={styles.help}>
153
+ {showHelp && help && (
154
+ <SilkeText flex id={helpId}>
155
+ {help}
156
+ </SilkeText>
148
157
  )}
158
+ {showHelp && helpRight && <SilkeText>{helpRight}</SilkeText>}
149
159
  {showError && (
150
- <SilkeBox height="s">
151
- <SilkeText
152
- flex
153
- tag="small"
154
- className={styles.formErrorMessage}
155
- color="error-30"
156
- aria-live="polite"
157
- role="alert"
158
- >
159
- {error}{' '}
160
- <SilkeIcon
161
- icon="error.circle"
162
- style={{ fontSize: '1.25rem', paddingLeft: '4px', verticalAlign: 'middle' }}
163
- />
164
- </SilkeText>
165
- </SilkeBox>
160
+ <SilkeText flex aria-live="polite" role="alert">
161
+ {error}
162
+ </SilkeText>
166
163
  )}
167
- </>
164
+ </SilkeBox>
168
165
  )}
169
166
  </SilkeBox>
170
167
  );
@@ -6,9 +6,9 @@
6
6
  const [value, setValue] = React.useState("");
7
7
 
8
8
  <SilkeBox column gap="l">
9
- {["default", "secondary", "ghost"].map((kind) => (
10
- <SilkeBox key={kind} gap="l" vAlign="end">
11
- {["xs", "s", "base", "l", undefined].map((size) => (
9
+ {["default", "zombie", "ghost"].map((kind) =>
10
+ ["base", "s", "xs"].map((size) => (
11
+ <SilkeBox key={kind} gap="l" vAlign="end">
12
12
  <SilkeTextField
13
13
  flex
14
14
  key={size || "default"}
@@ -20,9 +20,75 @@ const [value, setValue] = React.useState("");
20
20
  value={value}
21
21
  onChange={setValue}
22
22
  />
23
- ))}
24
- </SilkeBox>
25
- ))}
23
+ <SilkeTextField
24
+ flex
25
+ error="Got error"
26
+ key={size || "default"}
27
+ label={`${kind || "default"} - ${size}`}
28
+ placeholder={kind || "default" + " " + size}
29
+ size={size}
30
+ kind={kind}
31
+ value={value}
32
+ onChange={setValue}
33
+ />
34
+ <SilkeTextField
35
+ flex
36
+ disabled
37
+ key={size || "default"}
38
+ label={`${kind || "default"} - ${size}`}
39
+ placeholder={kind || "default" + " " + size}
40
+ size={size}
41
+ kind={kind}
42
+ help={kind + " -- " + "help"}
43
+ value={value}
44
+ onChange={setValue}
45
+ />
46
+ </SilkeBox>
47
+ ))
48
+ )}
49
+ </SilkeBox>;
50
+ ```
51
+
52
+ ## Inline fields
53
+
54
+ ```js
55
+ const [value, setValue] = React.useState("");
56
+
57
+ <SilkeBox column gap="l">
58
+ {["default", "zombie", "ghost"].map((kind) =>
59
+ ["base", "s", "xs"].map((size) => (
60
+ <SilkeBox key={kind} gap="l" vAlign="center">
61
+ <SilkeBox width="xxl">
62
+ {kind}/{size}
63
+ </SilkeBox>
64
+ <SilkeTextField
65
+ flex
66
+ inline
67
+ key={size || "default"}
68
+ label={`${kind || "default"} - ${size}`}
69
+ placeholder={kind || "default" + " " + size}
70
+ size={size}
71
+ kind={kind}
72
+ help={kind + " -- " + "help"}
73
+ value={value}
74
+ onChange={setValue}
75
+ />
76
+ <SilkeTextField
77
+ flex
78
+ inline="label-inside"
79
+ key={size || "default"}
80
+ label={`${kind || "default"} - ${size}`}
81
+ placeholder={kind || "default" + " " + size}
82
+ size={size}
83
+ kind={kind}
84
+ error="Testing"
85
+ help={kind + " -- " + "help"}
86
+ value={value}
87
+ onChange={setValue}
88
+ />
89
+ </SilkeBox>
90
+ ))
91
+ )}
26
92
  </SilkeBox>;
27
93
  ```
28
94
 
@@ -92,6 +158,7 @@ const items = ipsum.list((i) => ({
92
158
  <SilkeTextFieldItem>
93
159
  <SilkeSelectField
94
160
  kind="ghost"
161
+ inline
95
162
  onChange={() => console.log("selected")}
96
163
  value={items[1].value}
97
164
  items={items}
@@ -1,98 +1,178 @@
1
- @use '../../variables' as *;
2
- $kinds: (
3
- name: default,
4
- bg: var(--color-neutral-20),
5
- bg-disabled: var(--color-neutral-10),
6
- border-width: 1px,
7
- border-color: var(--color-neutral-20),
8
- border-color-hover: var(--color-neutral-40),
9
- border-color-focus: var(--color-neutral-60),
10
- border-radius: var(--border-radius-small),
11
- ),
12
- (
13
- name: secondary,
14
- bg: transparent,
15
- bg-disabled: transparent,
16
- bg-hover: transparent,
17
- border-width: 0 0 1px 0,
18
- border-color: var(--color-neutral-30),
19
- border-color-hover: var(--color-neutral-70),
20
- border-color-focus: var(--color-neutral-90),
21
- ),
22
- (
23
- name: ghost,
24
- bg: transparent,
25
- bg-hover: transparent,
26
- bg-disabled: transparent,
27
- border-width: 0 0 1px 0,
28
- border-color: transparent,
29
- border-color-hover: transparent,
30
- border-color-focus: var(--color-neutral-90),
31
- );
1
+ @use "../../variables" as *;
32
2
 
33
3
  .root {
4
+ --text-field-font-size: 14px;
5
+ --text-field-height: 40px;
6
+ --text-field-error-color: var(--color-error-30);
7
+ --text-field-help-color: var(--color-neutral-70);
8
+ --text-field-disabled-color: var(--color-neutral-30);
9
+ --text-field-placeholder-color: var(--color-neutral-70);
10
+ --text-field-disabled-placeholder-color: var(--color-neutral-50);
11
+
12
+ --text-field-bg: var(--color-neutral-20);
13
+ --text-field-hover-bg: var(--color-neutral-20);
14
+ --text-field-disabled-bg: var(--color-neutral-10);
15
+
16
+ --text-field-border-width: 1px;
17
+ --text-field-border-color: var(--color-neutral-20);
18
+ --text-field-hover-border-color: var(--color-neutral-40);
19
+ --text-field-focus-border-color: var(--color-neutral-60);
20
+ --text-field-disabled-border-color: var(--text-field-disabled-bg);
21
+ --text-field-error-border-color: var(--color-error-20);
22
+
23
+ --text-field-border-radius: var(--border-radius-small);
24
+
25
+ ----current-border-color:transparent;
26
+
34
27
  width: 100%;
35
28
  min-width: 0;
36
- }
29
+ font-size: var(--text-field-font-size);
30
+
31
+ &.ghost {
32
+ /** Zoombie fileds for now */
33
+ // --text-field-bg: transparent;
34
+ // --text-field-hover-bg: transparent;
35
+ // --text-field-disabled-bg: transparent;
36
+
37
+ // --text-field-border-width: 1px;
38
+ // --text-field-border-color: transparent;
39
+ // --text-field-hover-border-color: var(--color-neutral-20);
40
+ // --text-field-focus-border-color: var(--color-accent-30);
41
+
42
+ /** True ghost field code but Betsy wanted to tweak more on design */
43
+ --text-field-bg: transparent;
44
+ --text-field-hover-bg: transparent;
45
+ --text-field-disabled-bg: transparent;
46
+
47
+ --text-field-border-width: 0;
48
+ --text-field-border-color: transparent;
49
+ --text-field-hover-border-color: transparent;
50
+ --text-field-focus-border-color: transparent;
51
+ }
52
+
53
+ &.zombie {
54
+ --text-field-bg: transparent;
55
+ --text-field-hover-bg: transparent;
56
+ --text-field-disabled-bg: transparent;
57
+
58
+ --text-field-border-width: 1px;
59
+ --text-field-border-color: transparent;
60
+ --text-field-hover-border-color: var(--color-neutral-20);
61
+ --text-field-focus-border-color: var(--color-accent-30);
62
+ }
63
+
64
+ &.disabled {
65
+ .field {
66
+ background-color: var(--text-field-disabled-bg);
67
+ }
37
68
 
38
- .field {
39
- position: relative;
40
- }
69
+ .field {
70
+ border-color: var(--text-field-disabled-border-color);
71
+ }
41
72
 
42
- .label,
43
- .formErrorMessage {
44
- line-height: 1;
45
- }
73
+ .label,
74
+ .help,
75
+ .input {
76
+ color: var(--text-field-disabled-color);
77
+ }
46
78
 
47
- .formErrorMessage {
48
- font-weight: 400;
49
- }
79
+ .input::placeholder {
80
+ color: var(--text-field-disabled-placeholder-color);
81
+ }
82
+ }
50
83
 
51
- .label {
52
- font-weight: 600;
53
- }
84
+ &:not(.disabled):hover {
85
+ .field {
86
+ background-color: var(--text-field-hover-bg);
87
+ --current-border-color: var(--text-field-hover-border-color);
88
+ }
89
+ }
54
90
 
55
- .error {
56
- .border {
57
- border-color: var(--color-error-30);
91
+ &.error {
92
+ .field {
93
+ --current-border-color: var(--text-field-error-border-color);
94
+ }
95
+
96
+ .help {
97
+ color: var(--text-field-error-color);
98
+ }
99
+ }
100
+
101
+ .field:has(.input:focus),
102
+ .field:has([data-input]:focus) {
103
+ --current-border-color: var(--text-field-focus-border-color);
58
104
  }
59
105
  }
60
106
 
61
- .formErrorMessage {
62
- color: var(--color-error-30);
107
+ .tiny,
108
+ .small {
109
+ --text-field-border-radius: var(--border-radius-tiny);
63
110
  }
64
111
 
65
- .help {
66
- color: var(--color-neutral-80);
67
- line-height: 1;
112
+ .tiny {
113
+ --text-field-font-size: 12px;
114
+ --text-field-height: 24px;
115
+ }
116
+
117
+ .small {
118
+ --text-field-font-size: 14px;
119
+ --text-field-height: 32px;
68
120
  }
69
121
 
70
- .disabled {
71
- .label, .help, .input {
72
- color: var(--color-neutral-50);
122
+ .field {
123
+ position: relative;
124
+ background-color: var(--text-field-bg);
125
+ overflow: hidden;
126
+ border-radius: var(--text-field-border-radius);
127
+ transition: color 80ms;
128
+
129
+ &::after{
130
+ content: "";
131
+ display: block;
132
+ position: absolute;
133
+ inset: 0 0 0 0;
134
+ border: 0 solid var(--current-border-color);
135
+ border-radius: var(--text-field-border-radius);
136
+ border-width: var(--text-field-border-width);
137
+ pointer-events: none;
138
+ }
139
+ // Label placed inside field
140
+ .label {
141
+ font-weight: 400;
142
+ color: var(--text-field-help-color);
143
+ font-size: var(--text-field-font-size);
73
144
  }
74
145
  }
75
146
 
76
- .secondary.disabled .border {
77
- border-color: var(--color-neutral-30);
147
+ .label {
148
+ font-weight: 600;
149
+ }
150
+
151
+ .help {
152
+ color: var(--text-field-help-color);
153
+ font-size: 0.85em;
78
154
  }
79
155
 
80
- .default.disabled .border {
81
- border-color: var(--color-neutral-10);
156
+ .help,
157
+ .label {
158
+ line-height: 1;
82
159
  }
83
160
 
84
- .input {
161
+ .input,
162
+ [data-input] {
85
163
  @include font(14px);
86
164
  flex: 1;
87
165
  background: transparent;
88
166
  outline: none;
89
167
  border: none;
168
+ white-space: nowrap;
90
169
  /** Hack to fix flex padding so input does not push out text field items */
91
170
  overflow: hidden;
92
- padding: 0;
171
+ padding: 0 8px;
93
172
  resize: none;
94
173
  color: var(--color-neutral-100);
95
- line-height: 1;
174
+ line-height: var(--text-field-height);
175
+ font-size: var(--text-field-font-size);
96
176
 
97
177
  &::selection {
98
178
  background-color: rgba(var(--color-accent-30-rgb), 0.32);
@@ -100,200 +180,26 @@ $kinds: (
100
180
  }
101
181
 
102
182
  &::placeholder {
103
- color: var(--color-neutral-60);
183
+ color: var(--text-field-placeholder-color);
104
184
  }
105
185
  }
186
+ [data-placeholder]:empty::before {
187
+ white-space: nowrap;
188
+ content: attr(data-placeholder);
189
+ display: block;
190
+ color: var(--text-field-placeholder-color);
191
+ }
106
192
 
107
193
  textarea {
108
194
  margin-top: 8px;
109
195
  margin-bottom: 8px;
110
196
  }
111
197
 
112
- .border {
113
- position: absolute;
114
- bottom: 0;
115
- left: 0;
116
- right: 0;
117
- top: 0;
118
- pointer-events: none;
119
- margin: 0;
120
- border: 0 solid currentColor;
121
-
122
- &:hover {
123
- color: var(--color-neutral-30)
124
- }
125
- }
126
-
127
- @each $kind in $kinds {
128
- .#{map-get($kind, name)} {
129
- .field {
130
- background-color: map-get($kind, bg);
131
- border-radius: map-get($kind, border-radius);
132
- }
133
-
134
- .border {
135
- border-width: map-get($kind, border-width);
136
- color: map-get($kind, border-color);
137
- transition: color 80ms;
138
- border-radius: map-get($kind, border-radius);
139
- }
140
-
141
- &.disabled .field {
142
- background-color: map-get($kind, bg-disabled);
143
- }
144
-
145
- &:not(.disabled):hover {
146
- .field {
147
- background-color: map-get($kind, bg-hover);
148
- }
149
-
150
- .border {
151
- color: map-get($kind, border-color-hover);
152
- }
153
-
154
- .input, [contenteditable="true"] {
155
- &:focus ~ .border {
156
- color: map-get($kind, var(--color-neutral-100));
157
- }
158
- }
159
- }
160
-
161
- .input, [contenteditable="true"] {
162
- &:focus ~ .border {
163
- color: map-get($kind, border-color-focus);
164
- }
165
- }
166
-
167
- &.error input ~ .border {
168
- color: var(--color-warning-30);
169
- }
170
- }
171
- }
172
-
173
- textarea.input{
198
+ .inputMultiline {
174
199
  line-height: 1.2em !important;
200
+ white-space: pre-line;
175
201
  }
176
202
 
177
- .tiny {
178
- font-size: 12px;
179
-
180
- .input {
181
- font-size: 12px;
182
- line-height: 24px;
183
- }
184
-
185
- .help, .formErrorMessage {
186
- font-size: 10px;
187
- }
188
-
189
- &.default {
190
- .field {
191
- border-radius: var(--border-radius-tiny);
192
- }
193
-
194
- .border {
195
- border-radius: var(--border-radius-tiny);
196
- }
197
-
198
- .input {
199
- padding: 0 8px;
200
- }
201
- }
202
- }
203
-
204
- .small {
205
- font-size: 14px;
206
-
207
- .input {
208
- font-size: 14px;
209
- line-height: 32px;
210
- }
211
-
212
- .help, .formErrorMessage {
213
- font-size: 12px;
214
- }
215
-
216
- &.default {
217
- .field {
218
- border-radius: var(--border-radius-tiny);
219
- }
220
-
221
- .border {
222
- border-radius: var(--border-radius-tiny);
223
- }
224
-
225
- .input {
226
- padding: 0 8px;
227
- }
228
- }
229
- }
230
-
231
- .base {
232
- font-size: 16px;
233
-
234
- .help, .label, .formErrorMessage {
235
- font-size: 14px;
236
- }
237
-
238
- .input {
239
- line-height: 40px;
240
- }
241
-
242
- &.default {
243
- .field, .border {
244
- border-radius: var(--border-radius-small);
245
- }
246
-
247
- .input {
248
- padding: 0 8px;
249
- }
250
- }
251
- .ghost {
252
- .field, .border {
253
- outline: none;
254
- border: none;
255
- }
256
- }
257
- }
258
-
259
- .large {
260
- font-size: 16px;
261
-
262
- .help, .label, .formErrorMessage {
263
- font-size: 14px;
264
- }
265
-
266
- .input {
267
- line-height: 48px;
268
- }
269
-
270
- &.default {
271
- .field, .border {
272
- border-radius: var(--border-radius-small);
273
- }
274
-
275
- .input {
276
- padding-left: 16px;
277
- padding-right: 16px;
278
- }
279
- }
280
- }
281
-
282
- .tiny, .small, .base, .large {
283
- .inputMultiline {
284
- line-height: 1.4;
285
- overflow-y: auto;
286
- }
287
- }
288
-
289
- // Place the border on the outside of secondary fields
290
- .secondary .border {
291
- top: -1px;
292
- left: -1px;
293
- bottom: -1px;
294
- right: -1px;
295
- }
296
-
297
- .itemBefore ~ .input {
203
+ .itemBefore ~ .input, .itemBefore ~ [data-input] {
298
204
  padding: 0;
299
205
  }