@toptal/picasso-tagselector 1.0.33 → 2.0.0
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-package/src/TagSelectorInput/TagSelectorInput.d.ts.map +1 -1
- package/dist-package/src/TagSelectorInput/TagSelectorInput.js +6 -11
- package/dist-package/src/TagSelectorInput/TagSelectorInput.js.map +1 -1
- package/dist-package/src/TagSelectorInput/index.d.ts +0 -1
- package/dist-package/src/TagSelectorInput/index.d.ts.map +1 -1
- package/dist-package/src/TagSelectorInput/index.js +0 -1
- package/dist-package/src/TagSelectorInput/index.js.map +1 -1
- package/package.json +7 -6
- package/src/TagSelector/__snapshots__/test.tsx.snap +9 -51
- package/src/TagSelectorInput/TagSelectorInput.tsx +11 -18
- package/src/TagSelectorInput/__snapshots__/test.tsx.snap +2 -16
- package/src/TagSelectorInput/index.ts +0 -1
- package/dist-package/src/TagSelectorInput/styles.d.ts +0 -4
- package/dist-package/src/TagSelectorInput/styles.d.ts.map +0 -1
- package/dist-package/src/TagSelectorInput/styles.js +0 -38
- package/dist-package/src/TagSelectorInput/styles.js.map +0 -1
- package/src/TagSelectorInput/styles.ts +0 -41
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TagSelectorInput.d.ts","sourceRoot":"","sources":["../../../src/TagSelectorInput/TagSelectorInput.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"TagSelectorInput.d.ts","sourceRoot":"","sources":["../../../src/TagSelectorInput/TagSelectorInput.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAqB,MAAM,OAAO,CAAA;AAMzC,eAAO,MAAM,gBAAgB,qHA0F5B,CAAA;AAUD,eAAe,gBAAgB,CAAA"}
|
|
@@ -11,13 +11,8 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
11
11
|
};
|
|
12
12
|
import React, { forwardRef } from 'react';
|
|
13
13
|
import cx from 'classnames';
|
|
14
|
-
import { makeStyles } from '@material-ui/core/styles';
|
|
15
14
|
import { OutlinedInput } from '@toptal/picasso-outlined-input';
|
|
16
15
|
import { usePropDeprecationWarning } from '@toptal/picasso-utils';
|
|
17
|
-
import styles from './styles';
|
|
18
|
-
const useStyles = makeStyles(styles, {
|
|
19
|
-
name: 'PicassoTagSelectorInput',
|
|
20
|
-
});
|
|
21
16
|
export const TagSelectorInput = forwardRef(function TagSelectorInput(props, ref) {
|
|
22
17
|
const { id, name, defaultValue, value, placeholder, status, error, disabled, autoFocus, autoComplete, children, multiline, width, style, rows, rowsMax, type, onChange, startAdornment, endAdornment,
|
|
23
18
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
@@ -33,15 +28,15 @@ export const TagSelectorInput = forwardRef(function TagSelectorInput(props, ref)
|
|
|
33
28
|
componentName: 'TagSelectorInput',
|
|
34
29
|
description: 'Use the `status` prop instead. `error` is deprecated and will be removed in the next major release.',
|
|
35
30
|
});
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
if (endAdornment) {
|
|
31
|
+
let usedEndAdornment;
|
|
32
|
+
if (endAdornment && React.isValidElement(endAdornment)) {
|
|
39
33
|
usedEndAdornment = React.cloneElement(endAdornment, {
|
|
40
|
-
className:
|
|
34
|
+
className: 'absolute top-[calc(50%-0.5em)] right-[0.625em] h-[1em]',
|
|
41
35
|
});
|
|
42
36
|
}
|
|
43
|
-
return (React.createElement(OutlinedInput, { inputRef: ref, style: style, className: cx(
|
|
44
|
-
|
|
37
|
+
return (React.createElement(OutlinedInput, { inputRef: ref, style: style, className: cx(`flex flex-wrap h-auto py-1 pl-1 cursor-pointer
|
|
38
|
+
[&>input]:min-w-[3em] [&>input]:flex-grow [&>input]:w-0 [&>input]:h-6 [&>input]:pl-1 [&>input]:pr-0 [&>input]:mb-0`, {
|
|
39
|
+
'pr-[2.25em]': Boolean(endAdornment),
|
|
45
40
|
}), highlight: highlight, id: id, name: name, defaultValue: defaultValue, value: value, placeholder: placeholder, status: error ? 'error' : status, disabled: disabled, autoFocus: autoFocus, autoComplete: autoComplete, multiline: multiline, rows: rows, rowsMax: rowsMax, type: type, width: width,
|
|
46
41
|
// html attributes
|
|
47
42
|
inputProps: Object.assign(Object.assign({}, rest), inputProps), testIds: testIds, endAdornment: usedEndAdornment, startAdornment: startAdornment, onChange: onChange }, children));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TagSelectorInput.js","sourceRoot":"","sources":["../../../src/TagSelectorInput/TagSelectorInput.tsx"],"names":[],"mappings":";;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"TagSelectorInput.js","sourceRoot":"","sources":["../../../src/TagSelectorInput/TagSelectorInput.tsx"],"names":[],"mappings":";;;;;;;;;;;AAAA,OAAO,KAAK,EAAE,EAAE,UAAU,EAAE,MAAM,OAAO,CAAA;AACzC,OAAO,EAAE,MAAM,YAAY,CAAA;AAC3B,OAAO,EAAE,aAAa,EAAE,MAAM,gCAAgC,CAAA;AAC9D,OAAO,EAAE,yBAAyB,EAAE,MAAM,uBAAuB,CAAA;AAGjE,MAAM,CAAC,MAAM,gBAAgB,GAAG,UAAU,CACxC,SAAS,gBAAgB,CAAC,KAAK,EAAE,GAAG;IAClC,MAAM,EACJ,EAAE,EACF,IAAI,EACJ,YAAY,EACZ,KAAK,EACL,WAAW,EACX,MAAM,EACN,KAAK,EACL,QAAQ,EACR,SAAS,EACT,YAAY,EACZ,QAAQ,EACR,SAAS,EACT,KAAK,EACL,KAAK,EACL,IAAI,EACJ,OAAO,EACP,IAAI,EACJ,QAAQ,EACR,cAAc,EACd,YAAY;IACZ,6DAA6D;IAC7D,YAAY;IACZ,6DAA6D;IAC7D,WAAW,EACX,UAAU,EACV,OAAO,EACP,SAAS,KAEP,KAAK,EADJ,IAAI,UACL,KAAK;IAET,kBAAkB;MA/BZ,2SA6BL,CAAQ,CAAA;IAET,kBAAkB;IAClB,yBAAyB,CAAC;QACxB,KAAK;QACL,IAAI,EAAE,OAAO;QACb,aAAa,EAAE,kBAAkB;QACjC,WAAW,EACT,qGAAqG;KACxG,CAAC,CAAA;IAEF,IAAI,gBAAiC,CAAA;IAErC,IAAI,YAAY,IAAI,KAAK,CAAC,cAAc,CAAC,YAAY,CAAC,EAAE;QACtD,gBAAgB,GAAG,KAAK,CAAC,YAAY,CAAC,YAAY,EAAE;YAClD,SAAS,EAAE,wDAAwD;SACpE,CAAC,CAAA;KACH;IAED,OAAO,CACL,oBAAC,aAAa,IACZ,QAAQ,EAAE,GAAG,EACb,KAAK,EAAE,KAAK,EACZ,SAAS,EAAE,EAAE,CACX;6HACmH,EACnH;YACE,aAAa,EAAE,OAAO,CAAC,YAAY,CAAC;SACrC,CACF,EACD,SAAS,EAAE,SAAS,EACpB,EAAE,EAAE,EAAE,EACN,IAAI,EAAE,IAAI,EACV,YAAY,EAAE,YAAY,EAC1B,KAAK,EAAE,KAAK,EACZ,WAAW,EAAE,WAAW,EACxB,MAAM,EAAE,KAAK,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,EAChC,QAAQ,EAAE,QAAQ,EAClB,SAAS,EAAE,SAAS,EACpB,YAAY,EAAE,YAAY,EAC1B,SAAS,EAAE,SAAS,EACpB,IAAI,EAAE,IAAI,EACV,OAAO,EAAE,OAAO,EAChB,IAAI,EAAE,IAAI,EACV,KAAK,EAAE,KAAK;QACZ,kBAAkB;QAClB,UAAU,kCACL,IAAI,GACJ,UAAU,GAEf,OAAO,EAAE,OAAO,EAChB,YAAY,EAAE,gBAAgB,EAC9B,cAAc,EAAE,cAAc,EAC9B,QAAQ,EAAE,QAAQ,IAEjB,QAAQ,CACK,CACjB,CAAA;AACH,CAAC,CACF,CAAA;AAED,gBAAgB,CAAC,YAAY,GAAG;IAC9B,SAAS,EAAE,KAAK;IAChB,KAAK,EAAE,MAAM;IACb,MAAM,EAAE,SAAS;CAClB,CAAA;AAED,gBAAgB,CAAC,WAAW,GAAG,kBAAkB,CAAA;AAEjD,eAAe,gBAAgB,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/TagSelectorInput/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,gBAAgB,EAAE,MAAM,oBAAoB,CAAA
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/TagSelectorInput/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,gBAAgB,EAAE,MAAM,oBAAoB,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/TagSelectorInput/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,gBAAgB,EAAE,MAAM,oBAAoB,CAAA
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/TagSelectorInput/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,gBAAgB,EAAE,MAAM,oBAAoB,CAAA"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@toptal/picasso-tagselector",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "2.0.0",
|
|
4
4
|
"description": "Toptal UI components library - Tagselector",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
@@ -22,11 +22,11 @@
|
|
|
22
22
|
},
|
|
23
23
|
"homepage": "https://github.com/toptal/picasso/tree/master/packages/picasso#readme",
|
|
24
24
|
"dependencies": {
|
|
25
|
-
"@toptal/picasso-autocomplete": "
|
|
26
|
-
"@toptal/picasso-form": "
|
|
27
|
-
"@toptal/picasso-outlined-input": "
|
|
25
|
+
"@toptal/picasso-autocomplete": "2.0.0",
|
|
26
|
+
"@toptal/picasso-form": "4.0.0",
|
|
27
|
+
"@toptal/picasso-outlined-input": "2.0.0",
|
|
28
28
|
"@toptal/picasso-shared": "15.0.0",
|
|
29
|
-
"@toptal/picasso-tag": "
|
|
29
|
+
"@toptal/picasso-tag": "3.0.0",
|
|
30
30
|
"@toptal/picasso-utils": "1.0.3",
|
|
31
31
|
"classnames": "^2.5.1"
|
|
32
32
|
},
|
|
@@ -35,10 +35,11 @@
|
|
|
35
35
|
"**/styles.js"
|
|
36
36
|
],
|
|
37
37
|
"peerDependencies": {
|
|
38
|
-
"@
|
|
38
|
+
"@toptal/picasso-tailwind": ">=2.6.0",
|
|
39
39
|
"react": ">=16.12.0 < 19.0.0"
|
|
40
40
|
},
|
|
41
41
|
"devDependencies": {
|
|
42
|
+
"@toptal/picasso-tailwind": "2.7.0",
|
|
42
43
|
"@toptal/picasso-test-utils": "1.1.1",
|
|
43
44
|
"popper.js": "^1.16.1"
|
|
44
45
|
},
|
|
@@ -12,10 +12,10 @@ exports[`TagSelector disabled render 1`] = `
|
|
|
12
12
|
role="combobox"
|
|
13
13
|
>
|
|
14
14
|
<div
|
|
15
|
-
class="
|
|
15
|
+
class="flex"
|
|
16
16
|
>
|
|
17
17
|
<div
|
|
18
|
-
class="
|
|
18
|
+
class="base-Input base- base-Input relative gap-y gap-x items-center rounded-sm [font-size:_unset] hover:[&_.resetButtonDirty]:visible p-2 w-[18.75rem] bg-gray after:content-[""] after:inline-block after:absolute after:top-0 after:bottom-0 after:right-0 after:left-0 after:pointer-events after:border-solid after:rounded-sm after:border-gray after:border [&:has(input:focus)]:after:shadow-[0_0_0_3px] [&:has(input:focus)]:after:shadow-blue text-gray flex flex-wrap h-auto py-1 pl-1 cursor-pointer [&>input]:min-w [&>input]:flex-grow [&>input]:w-0 [&>input]:h-6 [&>input]:pl-1 [&>input]:pr-0 [&>input]:mb-0"
|
|
19
19
|
>
|
|
20
20
|
<div
|
|
21
21
|
aria-disabled="true"
|
|
@@ -52,25 +52,11 @@ exports[`TagSelector disabled render 1`] = `
|
|
|
52
52
|
aria-autocomplete="list"
|
|
53
53
|
aria-invalid="false"
|
|
54
54
|
autocomplete="off"
|
|
55
|
-
class="
|
|
55
|
+
class="base-Input base- [&::-webkit-calendar-picker-indicator]:bg bg-transparent border-none box-border cursor-[inherit] h-full outline-none p-0 peer resize-none w-full text-md leading-4 text-gray [&::-webkit-text-fill-color]:text-gray [&::placeholder]:text-gray [&::placeholder]:opacity-100"
|
|
56
56
|
disabled=""
|
|
57
57
|
type="text"
|
|
58
58
|
value=""
|
|
59
59
|
/>
|
|
60
|
-
<fieldset
|
|
61
|
-
aria-hidden="true"
|
|
62
|
-
class="PrivateNotchedOutline-root MuiOutlinedInput-notchedOutline PicassoOutlinedInput-notchedOutline"
|
|
63
|
-
style="padding-left: 8px;"
|
|
64
|
-
>
|
|
65
|
-
<legend
|
|
66
|
-
class="PrivateNotchedOutline-legend"
|
|
67
|
-
style="width: 0.01px;"
|
|
68
|
-
>
|
|
69
|
-
<span>
|
|
70
|
-
|
|
71
|
-
</span>
|
|
72
|
-
</legend>
|
|
73
|
-
</fieldset>
|
|
74
60
|
</div>
|
|
75
61
|
</div>
|
|
76
62
|
<div
|
|
@@ -94,10 +80,10 @@ exports[`TagSelector preselected value 1`] = `
|
|
|
94
80
|
role="combobox"
|
|
95
81
|
>
|
|
96
82
|
<div
|
|
97
|
-
class="
|
|
83
|
+
class="flex"
|
|
98
84
|
>
|
|
99
85
|
<div
|
|
100
|
-
class="
|
|
86
|
+
class="base-Input base-Input relative gap-y gap-x items-center rounded-sm [font-size:_unset] hover:[&_.resetButtonDirty]:visible p-2 w-[18.75rem] bg-white after:content-[""] after:inline-block after:absolute after:top-0 after:bottom-0 after:right-0 after:left-0 after:pointer-events after:border-solid after:rounded-sm after:border-gray [&:has(input:focus)]:after:border-blue after:border [&:has(input:focus)]:after:shadow-[0_0_0_3px] [&:has(input:focus)]:after:shadow-blue hover:[&:not(:has(input:focus))]:after:border-gray text-black flex flex-wrap h-auto py-1 pl-1 cursor-pointer [&>input]:min-w [&>input]:flex-grow [&>input]:w-0 [&>input]:h-6 [&>input]:pl-1 [&>input]:pr-0 [&>input]:mb-0"
|
|
101
87
|
>
|
|
102
88
|
<div
|
|
103
89
|
class="text-lg transition-none border border-solid rounded-[6.25rem] h-6 max-w inline-flex justify-center items-center cursor-default bg-white group align-middle leading-[inherit] text-graphite border-gray"
|
|
@@ -133,24 +119,10 @@ exports[`TagSelector preselected value 1`] = `
|
|
|
133
119
|
aria-autocomplete="list"
|
|
134
120
|
aria-invalid="false"
|
|
135
121
|
autocomplete="off"
|
|
136
|
-
class="
|
|
122
|
+
class="base-Input [&::-webkit-calendar-picker-indicator]:bg bg-transparent border-none box-border cursor-[inherit] h-full outline-none p-0 peer resize-none w-full text-md leading-4 text-black [&::placeholder]:text-gray [&::placeholder]:opacity-100"
|
|
137
123
|
type="text"
|
|
138
124
|
value=""
|
|
139
125
|
/>
|
|
140
|
-
<fieldset
|
|
141
|
-
aria-hidden="true"
|
|
142
|
-
class="PrivateNotchedOutline-root MuiOutlinedInput-notchedOutline PicassoOutlinedInput-notchedOutline"
|
|
143
|
-
style="padding-left: 8px;"
|
|
144
|
-
>
|
|
145
|
-
<legend
|
|
146
|
-
class="PrivateNotchedOutline-legend"
|
|
147
|
-
style="width: 0.01px;"
|
|
148
|
-
>
|
|
149
|
-
<span>
|
|
150
|
-
|
|
151
|
-
</span>
|
|
152
|
-
</legend>
|
|
153
|
-
</fieldset>
|
|
154
126
|
</div>
|
|
155
127
|
</div>
|
|
156
128
|
<div
|
|
@@ -174,34 +146,20 @@ exports[`TagSelector renders 1`] = `
|
|
|
174
146
|
role="combobox"
|
|
175
147
|
>
|
|
176
148
|
<div
|
|
177
|
-
class="
|
|
149
|
+
class="flex"
|
|
178
150
|
>
|
|
179
151
|
<div
|
|
180
|
-
class="
|
|
152
|
+
class="base-Input base-Input relative gap-y gap-x items-center rounded-sm [font-size:_unset] hover:[&_.resetButtonDirty]:visible p-2 w-[18.75rem] bg-white after:content-[""] after:inline-block after:absolute after:top-0 after:bottom-0 after:right-0 after:left-0 after:pointer-events after:border-solid after:rounded-sm after:border-gray [&:has(input:focus)]:after:border-blue after:border [&:has(input:focus)]:after:shadow-[0_0_0_3px] [&:has(input:focus)]:after:shadow-blue hover:[&:not(:has(input:focus))]:after:border-gray text-black flex flex-wrap h-auto py-1 pl-1 cursor-pointer [&>input]:min-w [&>input]:flex-grow [&>input]:w-0 [&>input]:h-6 [&>input]:pl-1 [&>input]:pr-0 [&>input]:mb-0"
|
|
181
153
|
>
|
|
182
154
|
<input
|
|
183
155
|
aria-autocomplete="list"
|
|
184
156
|
aria-invalid="false"
|
|
185
157
|
autocomplete="off"
|
|
186
|
-
class="
|
|
158
|
+
class="base-Input [&::-webkit-calendar-picker-indicator]:bg bg-transparent border-none box-border cursor-[inherit] h-full outline-none p-0 peer resize-none w-full text-md leading-4 text-black [&::placeholder]:text-gray [&::placeholder]:opacity-100"
|
|
187
159
|
placeholder="Please select..."
|
|
188
160
|
type="text"
|
|
189
161
|
value=""
|
|
190
162
|
/>
|
|
191
|
-
<fieldset
|
|
192
|
-
aria-hidden="true"
|
|
193
|
-
class="PrivateNotchedOutline-root MuiOutlinedInput-notchedOutline PicassoOutlinedInput-notchedOutline"
|
|
194
|
-
style="padding-left: 8px;"
|
|
195
|
-
>
|
|
196
|
-
<legend
|
|
197
|
-
class="PrivateNotchedOutline-legend"
|
|
198
|
-
style="width: 0.01px;"
|
|
199
|
-
>
|
|
200
|
-
<span>
|
|
201
|
-
|
|
202
|
-
</span>
|
|
203
|
-
</legend>
|
|
204
|
-
</fieldset>
|
|
205
163
|
</div>
|
|
206
164
|
</div>
|
|
207
165
|
<div
|
|
@@ -1,18 +1,9 @@
|
|
|
1
|
-
import type { ReactElement } from 'react'
|
|
2
1
|
import React, { forwardRef } from 'react'
|
|
3
2
|
import cx from 'classnames'
|
|
4
|
-
import type { Theme } from '@material-ui/core/styles'
|
|
5
|
-
import { makeStyles } from '@material-ui/core/styles'
|
|
6
3
|
import { OutlinedInput } from '@toptal/picasso-outlined-input'
|
|
7
4
|
import { usePropDeprecationWarning } from '@toptal/picasso-utils'
|
|
8
5
|
import type { Props as InputProps } from '@toptal/picasso-input'
|
|
9
6
|
|
|
10
|
-
import styles from './styles'
|
|
11
|
-
|
|
12
|
-
const useStyles = makeStyles<Theme>(styles, {
|
|
13
|
-
name: 'PicassoTagSelectorInput',
|
|
14
|
-
})
|
|
15
|
-
|
|
16
7
|
export const TagSelectorInput = forwardRef<HTMLInputElement, InputProps>(
|
|
17
8
|
function TagSelectorInput(props, ref) {
|
|
18
9
|
const {
|
|
@@ -55,13 +46,11 @@ export const TagSelectorInput = forwardRef<HTMLInputElement, InputProps>(
|
|
|
55
46
|
'Use the `status` prop instead. `error` is deprecated and will be removed in the next major release.',
|
|
56
47
|
})
|
|
57
48
|
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
let usedEndAdornment = null
|
|
49
|
+
let usedEndAdornment: React.ReactNode
|
|
61
50
|
|
|
62
|
-
if (endAdornment) {
|
|
63
|
-
usedEndAdornment = React.cloneElement(endAdornment
|
|
64
|
-
className:
|
|
51
|
+
if (endAdornment && React.isValidElement(endAdornment)) {
|
|
52
|
+
usedEndAdornment = React.cloneElement(endAdornment, {
|
|
53
|
+
className: 'absolute top-[calc(50%-0.5em)] right-[0.625em] h-[1em]',
|
|
65
54
|
})
|
|
66
55
|
}
|
|
67
56
|
|
|
@@ -69,9 +58,13 @@ export const TagSelectorInput = forwardRef<HTMLInputElement, InputProps>(
|
|
|
69
58
|
<OutlinedInput
|
|
70
59
|
inputRef={ref}
|
|
71
60
|
style={style}
|
|
72
|
-
className={cx(
|
|
73
|
-
|
|
74
|
-
|
|
61
|
+
className={cx(
|
|
62
|
+
`flex flex-wrap h-auto py-1 pl-1 cursor-pointer
|
|
63
|
+
[&>input]:min-w-[3em] [&>input]:flex-grow [&>input]:w-0 [&>input]:h-6 [&>input]:pl-1 [&>input]:pr-0 [&>input]:mb-0`,
|
|
64
|
+
{
|
|
65
|
+
'pr-[2.25em]': Boolean(endAdornment),
|
|
66
|
+
}
|
|
67
|
+
)}
|
|
75
68
|
highlight={highlight}
|
|
76
69
|
id={id}
|
|
77
70
|
name={name}
|
|
@@ -6,30 +6,16 @@ exports[`TagSelectorInput renders 1`] = `
|
|
|
6
6
|
class="Picasso-root"
|
|
7
7
|
>
|
|
8
8
|
<div
|
|
9
|
-
class="
|
|
9
|
+
class="base-Input relative gap-y gap-x items-center rounded-sm [font-size:_unset] hover:[&_.resetButtonDirty]:visible p-2 w-[18.75rem] bg-white after:content-[""] after:inline-block after:absolute after:top-0 after:bottom-0 after:right-0 after:left-0 after:pointer-events after:border-solid after:rounded-sm after:border-gray [&:has(input:focus)]:after:border-blue after:border [&:has(input:focus)]:after:shadow-[0_0_0_3px] [&:has(input:focus)]:after:shadow-blue hover:[&:not(:has(input:focus))]:after:border-gray text-black flex flex-wrap h-auto py-1 pl-1 cursor-pointer [&>input]:min-w [&>input]:flex-grow [&>input]:w-0 [&>input]:h-6 [&>input]:pl-1 [&>input]:pr-0 [&>input]:mb-0"
|
|
10
10
|
>
|
|
11
11
|
<input
|
|
12
12
|
aria-invalid="false"
|
|
13
|
-
class="
|
|
13
|
+
class="base-Input [&::-webkit-calendar-picker-indicator]:bg bg-transparent border-none box-border cursor-[inherit] h-full outline-none p-0 peer resize-none w-full text-md leading-4 text-black [&::placeholder]:text-gray [&::placeholder]:opacity-100"
|
|
14
14
|
data-testid="data-testid"
|
|
15
15
|
placeholder="placeholder"
|
|
16
16
|
type="text"
|
|
17
17
|
value="value"
|
|
18
18
|
/>
|
|
19
|
-
<fieldset
|
|
20
|
-
aria-hidden="true"
|
|
21
|
-
class="PrivateNotchedOutline-root MuiOutlinedInput-notchedOutline PicassoOutlinedInput-notchedOutline"
|
|
22
|
-
style="padding-left: 8px;"
|
|
23
|
-
>
|
|
24
|
-
<legend
|
|
25
|
-
class="PrivateNotchedOutline-legend"
|
|
26
|
-
style="width: 0.01px;"
|
|
27
|
-
>
|
|
28
|
-
<span>
|
|
29
|
-
|
|
30
|
-
</span>
|
|
31
|
-
</legend>
|
|
32
|
-
</fieldset>
|
|
33
19
|
</div>
|
|
34
20
|
</div>
|
|
35
21
|
</div>
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
export declare const TAG_SELECTOR_INPUT_GUTTER_SIZE: string;
|
|
2
|
-
declare const _default: () => import("@material-ui/styles").StyleRules<{}, "inputBase" | "withEndAdornment" | "endAdornment" | "horizontalLayout">;
|
|
3
|
-
export default _default;
|
|
4
|
-
//# sourceMappingURL=styles.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../../src/TagSelectorInput/styles.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,8BAA8B,QAAa,CAAA;;AAIxD,wBAiCI"}
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
import { createStyles } from '@material-ui/core/styles';
|
|
2
|
-
import { rem } from '@toptal/picasso-shared';
|
|
3
|
-
export const TAG_SELECTOR_INPUT_GUTTER_SIZE = rem('4px');
|
|
4
|
-
const END_ADORNMENT_PADDING = '0.625em';
|
|
5
|
-
const END_ADORNMENT_HEIGHT = '1em';
|
|
6
|
-
export default () => createStyles({
|
|
7
|
-
inputBase: {
|
|
8
|
-
display: 'flex',
|
|
9
|
-
flexWrap: 'wrap',
|
|
10
|
-
height: 'auto',
|
|
11
|
-
paddingBottom: TAG_SELECTOR_INPUT_GUTTER_SIZE,
|
|
12
|
-
paddingLeft: TAG_SELECTOR_INPUT_GUTTER_SIZE,
|
|
13
|
-
paddingTop: TAG_SELECTOR_INPUT_GUTTER_SIZE,
|
|
14
|
-
cursor: 'pointer',
|
|
15
|
-
'& > input': {
|
|
16
|
-
minWidth: '3em',
|
|
17
|
-
flexGrow: 1,
|
|
18
|
-
width: 0,
|
|
19
|
-
height: rem('24px'),
|
|
20
|
-
paddingLeft: rem('4px'),
|
|
21
|
-
paddingRight: 0,
|
|
22
|
-
marginBottom: 0,
|
|
23
|
-
},
|
|
24
|
-
},
|
|
25
|
-
withEndAdornment: {
|
|
26
|
-
paddingRight: `calc(2*${END_ADORNMENT_PADDING} + ${END_ADORNMENT_HEIGHT})`,
|
|
27
|
-
},
|
|
28
|
-
endAdornment: {
|
|
29
|
-
position: 'absolute',
|
|
30
|
-
top: `calc(50% - 0.5 * ${END_ADORNMENT_HEIGHT})`,
|
|
31
|
-
right: '0.625em',
|
|
32
|
-
height: END_ADORNMENT_HEIGHT,
|
|
33
|
-
},
|
|
34
|
-
horizontalLayout: {
|
|
35
|
-
width: '100%',
|
|
36
|
-
},
|
|
37
|
-
});
|
|
38
|
-
//# sourceMappingURL=styles.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"styles.js","sourceRoot":"","sources":["../../../src/TagSelectorInput/styles.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAA;AACvD,OAAO,EAAE,GAAG,EAAE,MAAM,wBAAwB,CAAA;AAE5C,MAAM,CAAC,MAAM,8BAA8B,GAAG,GAAG,CAAC,KAAK,CAAC,CAAA;AACxD,MAAM,qBAAqB,GAAG,SAAS,CAAA;AACvC,MAAM,oBAAoB,GAAG,KAAK,CAAA;AAElC,eAAe,GAAG,EAAE,CAClB,YAAY,CAAC;IACX,SAAS,EAAE;QACT,OAAO,EAAE,MAAM;QACf,QAAQ,EAAE,MAAM;QAChB,MAAM,EAAE,MAAM;QACd,aAAa,EAAE,8BAA8B;QAC7C,WAAW,EAAE,8BAA8B;QAC3C,UAAU,EAAE,8BAA8B;QAC1C,MAAM,EAAE,SAAS;QAEjB,WAAW,EAAE;YACX,QAAQ,EAAE,KAAK;YACf,QAAQ,EAAE,CAAC;YACX,KAAK,EAAE,CAAC;YACR,MAAM,EAAE,GAAG,CAAC,MAAM,CAAC;YACnB,WAAW,EAAE,GAAG,CAAC,KAAK,CAAC;YACvB,YAAY,EAAE,CAAC;YACf,YAAY,EAAE,CAAC;SAChB;KACF;IACD,gBAAgB,EAAE;QAChB,YAAY,EAAE,UAAU,qBAAqB,MAAM,oBAAoB,GAAG;KAC3E;IACD,YAAY,EAAE;QACZ,QAAQ,EAAE,UAAU;QACpB,GAAG,EAAE,oBAAoB,oBAAoB,GAAG;QAChD,KAAK,EAAE,SAAS;QAChB,MAAM,EAAE,oBAAoB;KAC7B;IACD,gBAAgB,EAAE;QAChB,KAAK,EAAE,MAAM;KACd;CACF,CAAC,CAAA"}
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import { createStyles } from '@material-ui/core/styles'
|
|
2
|
-
import { rem } from '@toptal/picasso-shared'
|
|
3
|
-
|
|
4
|
-
export const TAG_SELECTOR_INPUT_GUTTER_SIZE = rem('4px')
|
|
5
|
-
const END_ADORNMENT_PADDING = '0.625em'
|
|
6
|
-
const END_ADORNMENT_HEIGHT = '1em'
|
|
7
|
-
|
|
8
|
-
export default () =>
|
|
9
|
-
createStyles({
|
|
10
|
-
inputBase: {
|
|
11
|
-
display: 'flex',
|
|
12
|
-
flexWrap: 'wrap',
|
|
13
|
-
height: 'auto',
|
|
14
|
-
paddingBottom: TAG_SELECTOR_INPUT_GUTTER_SIZE,
|
|
15
|
-
paddingLeft: TAG_SELECTOR_INPUT_GUTTER_SIZE,
|
|
16
|
-
paddingTop: TAG_SELECTOR_INPUT_GUTTER_SIZE,
|
|
17
|
-
cursor: 'pointer',
|
|
18
|
-
|
|
19
|
-
'& > input': {
|
|
20
|
-
minWidth: '3em',
|
|
21
|
-
flexGrow: 1,
|
|
22
|
-
width: 0,
|
|
23
|
-
height: rem('24px'),
|
|
24
|
-
paddingLeft: rem('4px'),
|
|
25
|
-
paddingRight: 0,
|
|
26
|
-
marginBottom: 0,
|
|
27
|
-
},
|
|
28
|
-
},
|
|
29
|
-
withEndAdornment: {
|
|
30
|
-
paddingRight: `calc(2*${END_ADORNMENT_PADDING} + ${END_ADORNMENT_HEIGHT})`,
|
|
31
|
-
},
|
|
32
|
-
endAdornment: {
|
|
33
|
-
position: 'absolute',
|
|
34
|
-
top: `calc(50% - 0.5 * ${END_ADORNMENT_HEIGHT})`,
|
|
35
|
-
right: '0.625em',
|
|
36
|
-
height: END_ADORNMENT_HEIGHT,
|
|
37
|
-
},
|
|
38
|
-
horizontalLayout: {
|
|
39
|
-
width: '100%',
|
|
40
|
-
},
|
|
41
|
-
})
|