forstok-ui-lib 8.2.3 → 8.3.1
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/index.d.ts +4 -2
- package/dist/index.js +62 -47
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +28 -13
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/assets/stylesheets/shares.styles.ts +27 -12
- package/src/components/image/channel.tsx +2 -2
- package/src/components/select/all.tsx +28 -5
- package/src/components/select/asyncPaginate.tsx +28 -5
- package/src/components/select/index.tsx +25 -4
package/package.json
CHANGED
|
@@ -3690,7 +3690,7 @@ export const DropdownList = styled.ul<{ $mode?: 'no-border' }>`
|
|
|
3690
3690
|
}
|
|
3691
3691
|
}
|
|
3692
3692
|
@media only screen and (min-width: 768px) {
|
|
3693
|
-
padding:
|
|
3693
|
+
padding: 8px;
|
|
3694
3694
|
}
|
|
3695
3695
|
@media only screen and (min-width: 1366px) {
|
|
3696
3696
|
max-height: 50vh;
|
|
@@ -3708,6 +3708,15 @@ export const DropdownItem = styled.li<{ $mode?: 'common' | 'categories', $isActi
|
|
|
3708
3708
|
grid-auto-flow: column;
|
|
3709
3709
|
grid-template-columns: 100px auto;
|
|
3710
3710
|
}
|
|
3711
|
+
${({ $mode }) => !$mode && css`
|
|
3712
|
+
padding: 8px .5em;
|
|
3713
|
+
&:first-child {
|
|
3714
|
+
padding-top: 4px;
|
|
3715
|
+
}
|
|
3716
|
+
&:last-child {
|
|
3717
|
+
padding-bottom: 4px;
|
|
3718
|
+
}
|
|
3719
|
+
`}
|
|
3711
3720
|
${({ $mode }) => $mode === 'categories' && css`
|
|
3712
3721
|
grid-auto-flow: column;
|
|
3713
3722
|
grid-template-columns: 22px auto;
|
|
@@ -3723,18 +3732,21 @@ export const DropdownItem = styled.li<{ $mode?: 'common' | 'categories', $isActi
|
|
|
3723
3732
|
}
|
|
3724
3733
|
`}
|
|
3725
3734
|
${({ $mode }) => $mode === 'common' && css`
|
|
3726
|
-
margin-
|
|
3727
|
-
margin-bottom: .125rem;
|
|
3735
|
+
margin-bottom: 4px;
|
|
3728
3736
|
color: var(--pri-clr);
|
|
3729
3737
|
line-height: 20px;
|
|
3730
3738
|
align-items: center;
|
|
3731
3739
|
padding: .5rem .75rem;
|
|
3732
3740
|
display: block;
|
|
3733
3741
|
min-height: auto;
|
|
3742
|
+
border-radius: var(--nav-rd);
|
|
3734
3743
|
&:hover {
|
|
3735
3744
|
background-color: var(--nav-clr-bg__hvr);
|
|
3736
3745
|
border-radius: var(--nav-rd);
|
|
3737
3746
|
}
|
|
3747
|
+
&:last-child {
|
|
3748
|
+
margin-bottom: 0;
|
|
3749
|
+
}
|
|
3738
3750
|
> label, > span {
|
|
3739
3751
|
cursor: pointer;
|
|
3740
3752
|
text-transform: capitalize;
|
|
@@ -3756,7 +3768,6 @@ export const DropdownItem = styled.li<{ $mode?: 'common' | 'categories', $isActi
|
|
|
3756
3768
|
`}
|
|
3757
3769
|
${({ $mode, $isActive }) => ($mode === 'common' && $isActive) && css`
|
|
3758
3770
|
background-color: var(--nav-clr-bg__hvr);
|
|
3759
|
-
border-radius: var(--nav-rd);
|
|
3760
3771
|
padding-right: 1.75em;
|
|
3761
3772
|
&, > label, > span {
|
|
3762
3773
|
font-weight: 500;
|
|
@@ -4456,8 +4467,8 @@ export const NavChildItem = styled.div<{ $activated?: boolean, $mode?: 'counter'
|
|
|
4456
4467
|
position: relative;
|
|
4457
4468
|
grid-gap: 6px;
|
|
4458
4469
|
margin-left: 1.5rem;
|
|
4459
|
-
margin-top:
|
|
4460
|
-
margin-bottom:
|
|
4470
|
+
margin-top: 0;
|
|
4471
|
+
margin-bottom: 4px;
|
|
4461
4472
|
padding-top: .25rem;
|
|
4462
4473
|
padding-bottom: .25rem;
|
|
4463
4474
|
padding-left: .5rem;
|
|
@@ -4688,19 +4699,23 @@ export const ItemQtyLabel = styled.span`
|
|
|
4688
4699
|
display: grid;
|
|
4689
4700
|
`
|
|
4690
4701
|
|
|
4691
|
-
export const
|
|
4692
|
-
color: var(--act-clr);
|
|
4702
|
+
export const OptCustomLabel = styled.label<{$mode?: string}>`
|
|
4693
4703
|
font-size: 10px;
|
|
4694
|
-
text-transform:
|
|
4704
|
+
text-transform: capitalize;
|
|
4695
4705
|
letter-spacing: .5px;
|
|
4696
4706
|
padding: 3px 5px;
|
|
4697
|
-
background-color: #21BA45;
|
|
4698
4707
|
display: block;
|
|
4699
4708
|
position: absolute;
|
|
4700
4709
|
right: 10px;
|
|
4701
|
-
top:
|
|
4710
|
+
top: 50%;
|
|
4711
|
+
transform: translateY(-50%);
|
|
4702
4712
|
z-index: 1;
|
|
4703
|
-
|
|
4713
|
+
background-color: #EFEFEF;
|
|
4714
|
+
border-radius: var(--nav-rd);
|
|
4715
|
+
color: var(--pri-clr);
|
|
4716
|
+
${({ $mode }) => $mode === 'label' && css`
|
|
4717
|
+
transform: translateY(0);
|
|
4718
|
+
`}
|
|
4704
4719
|
`
|
|
4705
4720
|
|
|
4706
4721
|
export const TableContentWrapper = styled.div<{ $mode?: 'package' }>`
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import Image from '.'
|
|
2
2
|
|
|
3
|
-
import { InitialContainer,
|
|
3
|
+
import { InitialContainer, OptCustomLabel } from '../../assets/stylesheets/shares.styles'
|
|
4
4
|
import LinkComponent from '../link';
|
|
5
5
|
|
|
6
6
|
import { ImageMode } from './typed'
|
|
@@ -89,7 +89,7 @@ const ImageChannelComponent = (props: TImage) => {
|
|
|
89
89
|
) : (
|
|
90
90
|
<span className='multi-elipsis' title={defName}>
|
|
91
91
|
{defName}
|
|
92
|
-
{isAPI && <
|
|
92
|
+
{isAPI && <OptCustomLabel className='_refLabel'>API</OptCustomLabel>}
|
|
93
93
|
</span>
|
|
94
94
|
)
|
|
95
95
|
)}
|
|
@@ -153,16 +153,39 @@ const SelectAllComponent = (props: TSelect) => {
|
|
|
153
153
|
} as CSSObjectWithLabel),
|
|
154
154
|
option: (provided: CSSObject, state: { isSelected: any }) => ({
|
|
155
155
|
...provided,
|
|
156
|
-
|
|
157
|
-
|
|
156
|
+
width: '100%',
|
|
157
|
+
margin: '0 0 4px',
|
|
158
|
+
color: 'var(--pri-clr)',
|
|
159
|
+
borderRadius: 'var(--nav-rd)',
|
|
160
|
+
backgroundColor: state.isSelected ? 'var(--nav-clr-bg__hvr)' : 'transparent',
|
|
158
161
|
cursor: 'pointer',
|
|
162
|
+
overflowWrap: 'break-word',
|
|
163
|
+
wordBreak: 'break-all',
|
|
164
|
+
fontWeight: state.isSelected ? 500 : 'normal',
|
|
165
|
+
position: 'relative',
|
|
166
|
+
'&:last-child': {
|
|
167
|
+
marginBottom: 0,
|
|
168
|
+
},
|
|
159
169
|
'&:hover': {
|
|
160
|
-
backgroundColor: '
|
|
161
|
-
|
|
162
|
-
|
|
170
|
+
backgroundColor: 'var(--nav-clr-bg__hvr)',
|
|
171
|
+
},
|
|
172
|
+
...(state.isSelected && {
|
|
173
|
+
paddingRight: '1.75em',
|
|
174
|
+
'&:after': {
|
|
175
|
+
content: '"✔"',
|
|
176
|
+
position: 'absolute',
|
|
177
|
+
top: '50%',
|
|
178
|
+
transform: 'translateY(-50%)',
|
|
179
|
+
right: '7px',
|
|
180
|
+
bottom: '0',
|
|
181
|
+
width: '12px',
|
|
182
|
+
height: '20px'
|
|
183
|
+
}
|
|
184
|
+
})
|
|
163
185
|
} as CSSObjectWithLabel),
|
|
164
186
|
menu: (provided: CSSObject) => ({
|
|
165
187
|
...provided,
|
|
188
|
+
padding: '8px',
|
|
166
189
|
borderRadius: '.75rem',
|
|
167
190
|
boxShadow: '0rem .5rem 1.5rem -.5rem rgba(0, 0, 0, .05), 0rem .5rem 1rem -.25rem rgba(0, 0, 0, .05), 0rem .1875rem .375rem 0rem rgba(0, 0, 0, .05), 0rem .125rem .25rem 0rem rgba(0, 0, 0, .05), 0rem .0625rem .125rem 0rem rgba(0, 0, 0, .05), 0rem 0rem 0rem .0625rem rgba(0, 0, 0, .06)',
|
|
168
191
|
border: 'none'
|
|
@@ -182,16 +182,39 @@ const SelectAsyncPaginateComponent = ({ loadOptions, ...props }: TSelect) => {
|
|
|
182
182
|
} as CSSObjectWithLabel),
|
|
183
183
|
option: (provided: CSSObject, state: OptionProps<TOption, boolean>) => ({
|
|
184
184
|
...provided,
|
|
185
|
-
|
|
186
|
-
|
|
185
|
+
width: '100%',
|
|
186
|
+
margin: '0 0 4px',
|
|
187
|
+
color: 'var(--pri-clr)',
|
|
188
|
+
borderRadius: 'var(--nav-rd)',
|
|
189
|
+
backgroundColor: state.isSelected || state.isFocused ? 'var(--nav-clr-bg__hvr)' : 'transparent',
|
|
187
190
|
cursor: 'pointer',
|
|
191
|
+
overflowWrap: 'break-word',
|
|
192
|
+
wordBreak: 'break-all',
|
|
193
|
+
fontWeight: state.isSelected ? 500 : 'normal',
|
|
194
|
+
position: 'relative',
|
|
195
|
+
'&:last-child': {
|
|
196
|
+
marginBottom: 0,
|
|
197
|
+
},
|
|
188
198
|
'&:hover': {
|
|
189
|
-
backgroundColor: '
|
|
190
|
-
|
|
191
|
-
|
|
199
|
+
backgroundColor: 'var(--nav-clr-bg__hvr)',
|
|
200
|
+
},
|
|
201
|
+
...(state.isSelected && {
|
|
202
|
+
paddingRight: '1.75em',
|
|
203
|
+
'&:after': {
|
|
204
|
+
content: '"✔"',
|
|
205
|
+
position: 'absolute',
|
|
206
|
+
top: '50%',
|
|
207
|
+
transform: 'translateY(-50%)',
|
|
208
|
+
right: '7px',
|
|
209
|
+
bottom: '0',
|
|
210
|
+
width: '12px',
|
|
211
|
+
height: '20px'
|
|
212
|
+
}
|
|
213
|
+
})
|
|
192
214
|
} as CSSObjectWithLabel),
|
|
193
215
|
menu: (provided: CSSObject) => ({
|
|
194
216
|
...provided,
|
|
217
|
+
padding: '8px',
|
|
195
218
|
borderRadius: '.75rem',
|
|
196
219
|
boxShadow: '0rem .5rem 1.5rem -.5rem rgba(0, 0, 0, .05), 0rem .5rem 1rem -.25rem rgba(0, 0, 0, .05), 0rem .1875rem .375rem 0rem rgba(0, 0, 0, .05), 0rem .125rem .25rem 0rem rgba(0, 0, 0, .05), 0rem .0625rem .125rem 0rem rgba(0, 0, 0, .05), 0rem 0rem 0rem .0625rem rgba(0, 0, 0, .06)',
|
|
197
220
|
border: 'none'
|
|
@@ -249,19 +249,40 @@ const SelectComponent = ({ type, isError=false, mode, customOption, customLabel,
|
|
|
249
249
|
option: (provided: CSSObject, state: OptionProps<TOption, typeof isMulti>) => ({
|
|
250
250
|
...provided,
|
|
251
251
|
...(!state.isDisabled && {
|
|
252
|
-
|
|
253
|
-
|
|
252
|
+
width: '100%',
|
|
253
|
+
margin: '0 0 4px',
|
|
254
|
+
color: 'var(--pri-clr)',
|
|
255
|
+
borderRadius: 'var(--nav-rd)',
|
|
256
|
+
backgroundColor: state.isSelected || state.isFocused ? 'var(--nav-clr-bg__hvr)' : 'transparent',
|
|
254
257
|
cursor: 'pointer',
|
|
255
258
|
overflowWrap: 'break-word',
|
|
256
259
|
wordBreak: 'break-all',
|
|
260
|
+
fontWeight: state.isSelected ? 500 : 'normal',
|
|
261
|
+
position: 'relative',
|
|
262
|
+
'&:last-child': {
|
|
263
|
+
marginBottom: 0,
|
|
264
|
+
},
|
|
257
265
|
'&:hover': {
|
|
258
|
-
backgroundColor: '
|
|
259
|
-
|
|
266
|
+
backgroundColor: 'var(--nav-clr-bg__hvr)',
|
|
267
|
+
}
|
|
268
|
+
}),
|
|
269
|
+
...(state.isSelected && {
|
|
270
|
+
paddingRight: '1.75em',
|
|
271
|
+
'&:after': {
|
|
272
|
+
content: '"✔"',
|
|
273
|
+
position: 'absolute',
|
|
274
|
+
top: '50%',
|
|
275
|
+
transform: 'translateY(-50%)',
|
|
276
|
+
right: '7px',
|
|
277
|
+
bottom: '0',
|
|
278
|
+
width: '12px',
|
|
279
|
+
height: '20px'
|
|
260
280
|
}
|
|
261
281
|
})
|
|
262
282
|
} as CSSObjectWithLabel),
|
|
263
283
|
menu: (provided: CSSObject) => ({
|
|
264
284
|
...provided,
|
|
285
|
+
padding: '8px',
|
|
265
286
|
borderRadius: '.75rem',
|
|
266
287
|
boxShadow: '0rem .5rem 1.5rem -.5rem rgba(0, 0, 0, .05), 0rem .5rem 1rem -.25rem rgba(0, 0, 0, .05), 0rem .1875rem .375rem 0rem rgba(0, 0, 0, .05), 0rem .125rem .25rem 0rem rgba(0, 0, 0, .05), 0rem .0625rem .125rem 0rem rgba(0, 0, 0, .05), 0rem 0rem 0rem .0625rem rgba(0, 0, 0, .06)',
|
|
267
288
|
border: 'none'
|