@14ch/svelte-ui 0.0.20 → 0.0.22
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/assets/styles/variables.scss +2 -2
- package/dist/components/Button.svelte +6 -8
- package/dist/components/Button.svelte.d.ts +0 -1
- package/dist/components/Checkbox.svelte +6 -11
- package/dist/components/Checkbox.svelte.d.ts +1 -3
- package/dist/components/CheckboxGroup.svelte +14 -9
- package/dist/components/ColorPicker.svelte +0 -6
- package/dist/components/ColorPicker.svelte.d.ts +0 -2
- package/dist/components/Combobox.svelte +0 -4
- package/dist/components/Combobox.svelte.d.ts +0 -2
- package/dist/components/Datepicker.svelte +0 -5
- package/dist/components/Datepicker.svelte.d.ts +0 -2
- package/dist/components/Fab.svelte +9 -11
- package/dist/components/Fab.svelte.d.ts +0 -1
- package/dist/components/FileUploader.svelte +11 -6
- package/dist/components/Icon.svelte +11 -9
- package/dist/components/IconButton.svelte +0 -3
- package/dist/components/IconButton.svelte.d.ts +0 -1
- package/dist/components/ImageUploader.svelte +10 -6
- package/dist/components/Input.svelte +8 -14
- package/dist/components/Input.svelte.d.ts +0 -2
- package/dist/components/LoadingSpinner.svelte +23 -20
- package/dist/components/Radio.svelte +6 -11
- package/dist/components/Radio.svelte.d.ts +1 -3
- package/dist/components/RadioGroup.svelte +14 -9
- package/dist/components/SegmentedControl.svelte +2 -2
- package/dist/components/Select.svelte +1 -5
- package/dist/components/Select.svelte.d.ts +0 -2
- package/dist/components/Slider.svelte +80 -38
- package/dist/components/Slider.svelte.d.ts +0 -2
- package/dist/components/SnackbarItem.svelte +53 -42
- package/dist/components/Switch.svelte +1 -6
- package/dist/components/Switch.svelte.d.ts +0 -2
- package/dist/components/TabItem.svelte +15 -17
- package/dist/components/Textarea.svelte +10 -8
- package/dist/components/Textarea.svelte.d.ts +0 -1
- package/package.json +1 -1
|
@@ -146,22 +146,33 @@
|
|
|
146
146
|
|
|
147
147
|
<div
|
|
148
148
|
bind:this={snackbarRef}
|
|
149
|
-
class="snackbar-item
|
|
149
|
+
class="snackbar-item"
|
|
150
|
+
class:snackbar-item--top={position === 'top'}
|
|
151
|
+
class:snackbar-item--bottom={position === 'bottom'}
|
|
152
|
+
class:snackbar-item--hidden={!visible}
|
|
150
153
|
data-testid="snackbar-item"
|
|
151
154
|
>
|
|
152
155
|
<div
|
|
153
|
-
class="snackbar-item__content
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
156
|
+
class="snackbar-item__content"
|
|
157
|
+
class:snackbar-item__content--info={type === 'info'}
|
|
158
|
+
class:snackbar-item__content--success={type === 'success'}
|
|
159
|
+
class:snackbar-item__content--warning={type === 'warning'}
|
|
160
|
+
class:snackbar-item__content--error={type === 'error'}
|
|
161
|
+
class:snackbar-item__content--default={type === 'default'}
|
|
162
|
+
class:snackbar-item__content--filled={variant === 'filled'}
|
|
163
|
+
class:snackbar-item__content--outlined={variant === 'outlined'}
|
|
164
|
+
class:snackbar-item__content--top={position === 'top'}
|
|
165
|
+
class:snackbar-item__content--bottom={position === 'bottom'}
|
|
166
|
+
class:snackbar-item__content--visible={visible}
|
|
167
|
+
style:--internal-snackbar-item-custom-color={color ?? 'unset'}
|
|
168
|
+
style:--internal-snackbar-item-custom-text-color={textColor ?? 'unset'}
|
|
158
169
|
role={type === 'error' || type === 'warning' ? 'alert' : 'status'}
|
|
159
170
|
aria-live={type === 'error' || type === 'warning' ? 'assertive' : 'polite'}
|
|
160
171
|
aria-atomic="true"
|
|
161
172
|
aria-hidden={!visible}
|
|
162
173
|
>
|
|
163
174
|
{#if typeIcons[type]}
|
|
164
|
-
<div class="
|
|
175
|
+
<div class="snackbar-item__icon" aria-hidden="true">
|
|
165
176
|
<Icon name={typeIcons[type]} size={32}>{typeIcons[type]}</Icon>
|
|
166
177
|
</div>
|
|
167
178
|
{/if}
|
|
@@ -332,90 +343,90 @@
|
|
|
332
343
|
/* Type variants - filled */
|
|
333
344
|
.snackbar-item__content--filled.snackbar-item__content--info {
|
|
334
345
|
background-color: var(
|
|
335
|
-
--
|
|
346
|
+
--internal-snackbar-item-custom-color,
|
|
336
347
|
var(--svelte-ui-snackbar-info-filled-bg)
|
|
337
348
|
);
|
|
338
349
|
color: var(
|
|
339
|
-
--
|
|
350
|
+
--internal-snackbar-item-custom-text-color,
|
|
340
351
|
var(--svelte-ui-snackbar-info-filled-text-color)
|
|
341
352
|
);
|
|
342
353
|
}
|
|
343
354
|
|
|
344
355
|
.snackbar-item__content--filled.snackbar-item__content--info .snackbar-item__icon {
|
|
345
356
|
color: var(
|
|
346
|
-
--
|
|
357
|
+
--internal-snackbar-item-custom-text-color,
|
|
347
358
|
var(--svelte-ui-snackbar-info-filled-text-color)
|
|
348
359
|
);
|
|
349
360
|
}
|
|
350
361
|
|
|
351
362
|
.snackbar-item__content--filled.snackbar-item__content--success {
|
|
352
363
|
background-color: var(
|
|
353
|
-
--
|
|
364
|
+
--internal-snackbar-item-custom-color,
|
|
354
365
|
var(--svelte-ui-snackbar-success-filled-bg)
|
|
355
366
|
);
|
|
356
367
|
color: var(
|
|
357
|
-
--
|
|
368
|
+
--internal-snackbar-item-custom-text-color,
|
|
358
369
|
var(--svelte-ui-snackbar-success-filled-text-color)
|
|
359
370
|
);
|
|
360
371
|
}
|
|
361
372
|
|
|
362
373
|
.snackbar-item__content--filled.snackbar-item__content--success .snackbar-item__icon {
|
|
363
374
|
color: var(
|
|
364
|
-
--
|
|
375
|
+
--internal-snackbar-item-custom-text-color,
|
|
365
376
|
var(--svelte-ui-snackbar-success-filled-text-color)
|
|
366
377
|
);
|
|
367
378
|
}
|
|
368
379
|
|
|
369
380
|
.snackbar-item__content--filled.snackbar-item__content--warning {
|
|
370
381
|
background-color: var(
|
|
371
|
-
--
|
|
382
|
+
--internal-snackbar-item-custom-color,
|
|
372
383
|
var(--svelte-ui-snackbar-warning-filled-bg)
|
|
373
384
|
);
|
|
374
385
|
color: var(
|
|
375
|
-
--
|
|
386
|
+
--internal-snackbar-item-custom-text-color,
|
|
376
387
|
var(--svelte-ui-snackbar-warning-filled-text-color)
|
|
377
388
|
);
|
|
378
389
|
}
|
|
379
390
|
|
|
380
391
|
.snackbar-item__content--filled.snackbar-item__content--warning .snackbar-item__icon {
|
|
381
392
|
color: var(
|
|
382
|
-
--
|
|
393
|
+
--internal-snackbar-item-custom-text-color,
|
|
383
394
|
var(--svelte-ui-snackbar-warning-filled-text-color)
|
|
384
395
|
);
|
|
385
396
|
}
|
|
386
397
|
|
|
387
398
|
.snackbar-item__content--filled.snackbar-item__content--error {
|
|
388
399
|
background-color: var(
|
|
389
|
-
--
|
|
400
|
+
--internal-snackbar-item-custom-color,
|
|
390
401
|
var(--svelte-ui-snackbar-error-filled-bg)
|
|
391
402
|
);
|
|
392
403
|
color: var(
|
|
393
|
-
--
|
|
404
|
+
--internal-snackbar-item-custom-text-color,
|
|
394
405
|
var(--svelte-ui-snackbar-error-filled-text-color)
|
|
395
406
|
);
|
|
396
407
|
}
|
|
397
408
|
|
|
398
409
|
.snackbar-item__content--filled.snackbar-item__content--error .snackbar-item__icon {
|
|
399
410
|
color: var(
|
|
400
|
-
--
|
|
411
|
+
--internal-snackbar-item-custom-text-color,
|
|
401
412
|
var(--svelte-ui-snackbar-error-filled-text-color)
|
|
402
413
|
);
|
|
403
414
|
}
|
|
404
415
|
|
|
405
416
|
.snackbar-item__content--filled.snackbar-item__content--default {
|
|
406
417
|
background-color: var(
|
|
407
|
-
--
|
|
418
|
+
--internal-snackbar-item-custom-color,
|
|
408
419
|
var(--svelte-ui-snackbar-default-filled-bg)
|
|
409
420
|
);
|
|
410
421
|
color: var(
|
|
411
|
-
--
|
|
422
|
+
--internal-snackbar-item-custom-text-color,
|
|
412
423
|
var(--svelte-ui-snackbar-default-filled-text-color)
|
|
413
424
|
);
|
|
414
425
|
}
|
|
415
426
|
|
|
416
427
|
.snackbar-item__content--filled.snackbar-item__content--default .snackbar-item__icon {
|
|
417
428
|
color: var(
|
|
418
|
-
--
|
|
429
|
+
--internal-snackbar-item-custom-text-color,
|
|
419
430
|
var(--svelte-ui-snackbar-default-filled-text-color)
|
|
420
431
|
);
|
|
421
432
|
}
|
|
@@ -423,115 +434,115 @@
|
|
|
423
434
|
/* Type variants - outlined */
|
|
424
435
|
.snackbar-item__content--outlined.snackbar-item__content--info {
|
|
425
436
|
background-color: var(
|
|
426
|
-
--
|
|
437
|
+
--internal-snackbar-item-custom-color,
|
|
427
438
|
var(--svelte-ui-snackbar-info-outlined-bg)
|
|
428
439
|
);
|
|
429
440
|
color: var(
|
|
430
|
-
--
|
|
441
|
+
--internal-snackbar-item-custom-text-color,
|
|
431
442
|
var(--svelte-ui-snackbar-info-outlined-text-color)
|
|
432
443
|
);
|
|
433
444
|
box-shadow: inset 0 0 0 1px
|
|
434
445
|
var(
|
|
435
|
-
--
|
|
446
|
+
--internal-snackbar-item-custom-color,
|
|
436
447
|
var(--svelte-ui-snackbar-info-outlined-border-color)
|
|
437
448
|
);
|
|
438
449
|
}
|
|
439
450
|
|
|
440
451
|
.snackbar-item__content--outlined.snackbar-item__content--info .snackbar-item__icon {
|
|
441
452
|
color: var(
|
|
442
|
-
--
|
|
453
|
+
--internal-snackbar-item-custom-text-color,
|
|
443
454
|
var(--svelte-ui-snackbar-info-outlined-text-color)
|
|
444
455
|
);
|
|
445
456
|
}
|
|
446
457
|
|
|
447
458
|
.snackbar-item__content--outlined.snackbar-item__content--success {
|
|
448
459
|
background-color: var(
|
|
449
|
-
--
|
|
460
|
+
--internal-snackbar-item-custom-color,
|
|
450
461
|
var(--svelte-ui-snackbar-success-outlined-bg)
|
|
451
462
|
);
|
|
452
463
|
color: var(
|
|
453
|
-
--
|
|
464
|
+
--internal-snackbar-item-custom-text-color,
|
|
454
465
|
var(--svelte-ui-snackbar-success-outlined-text-color)
|
|
455
466
|
);
|
|
456
467
|
box-shadow: inset 0 0 0 1px
|
|
457
468
|
var(
|
|
458
|
-
--
|
|
469
|
+
--internal-snackbar-item-custom-color,
|
|
459
470
|
var(--svelte-ui-snackbar-success-outlined-border-color)
|
|
460
471
|
);
|
|
461
472
|
}
|
|
462
473
|
|
|
463
474
|
.snackbar-item__content--outlined.snackbar-item__content--success .snackbar-item__icon {
|
|
464
475
|
color: var(
|
|
465
|
-
--
|
|
476
|
+
--internal-snackbar-item-custom-text-color,
|
|
466
477
|
var(--svelte-ui-snackbar-success-outlined-text-color)
|
|
467
478
|
);
|
|
468
479
|
}
|
|
469
480
|
|
|
470
481
|
.snackbar-item__content--outlined.snackbar-item__content--warning {
|
|
471
482
|
background-color: var(
|
|
472
|
-
--
|
|
483
|
+
--internal-snackbar-item-custom-color,
|
|
473
484
|
var(--svelte-ui-snackbar-warning-outlined-bg)
|
|
474
485
|
);
|
|
475
486
|
color: var(
|
|
476
|
-
--
|
|
487
|
+
--internal-snackbar-item-custom-text-color,
|
|
477
488
|
var(--svelte-ui-snackbar-warning-outlined-text-color)
|
|
478
489
|
);
|
|
479
490
|
box-shadow: inset 0 0 0 1px
|
|
480
491
|
var(
|
|
481
|
-
--
|
|
492
|
+
--internal-snackbar-item-custom-color,
|
|
482
493
|
var(--svelte-ui-snackbar-warning-outlined-border-color)
|
|
483
494
|
);
|
|
484
495
|
}
|
|
485
496
|
|
|
486
497
|
.snackbar-item__content--outlined.snackbar-item__content--warning .snackbar-item__icon {
|
|
487
498
|
color: var(
|
|
488
|
-
--
|
|
499
|
+
--internal-snackbar-item-custom-text-color,
|
|
489
500
|
var(--svelte-ui-snackbar-warning-outlined-text-color)
|
|
490
501
|
);
|
|
491
502
|
}
|
|
492
503
|
|
|
493
504
|
.snackbar-item__content--outlined.snackbar-item__content--error {
|
|
494
505
|
background-color: var(
|
|
495
|
-
--
|
|
506
|
+
--internal-snackbar-item-custom-color,
|
|
496
507
|
var(--svelte-ui-snackbar-error-outlined-bg)
|
|
497
508
|
);
|
|
498
509
|
color: var(
|
|
499
|
-
--
|
|
510
|
+
--internal-snackbar-item-custom-text-color,
|
|
500
511
|
var(--svelte-ui-snackbar-error-outlined-text-color)
|
|
501
512
|
);
|
|
502
513
|
box-shadow: inset 0 0 0 1px
|
|
503
514
|
var(
|
|
504
|
-
--
|
|
515
|
+
--internal-snackbar-item-custom-color,
|
|
505
516
|
var(--svelte-ui-snackbar-error-outlined-border-color)
|
|
506
517
|
);
|
|
507
518
|
}
|
|
508
519
|
|
|
509
520
|
.snackbar-item__content--outlined.snackbar-item__content--error .snackbar-item__icon {
|
|
510
521
|
color: var(
|
|
511
|
-
--
|
|
522
|
+
--internal-snackbar-item-custom-text-color,
|
|
512
523
|
var(--svelte-ui-snackbar-error-outlined-text-color)
|
|
513
524
|
);
|
|
514
525
|
}
|
|
515
526
|
|
|
516
527
|
.snackbar-item__content--outlined.snackbar-item__content--default {
|
|
517
528
|
background-color: var(
|
|
518
|
-
--
|
|
529
|
+
--internal-snackbar-item-custom-color,
|
|
519
530
|
var(--svelte-ui-snackbar-default-outlined-bg)
|
|
520
531
|
);
|
|
521
532
|
color: var(
|
|
522
|
-
--
|
|
533
|
+
--internal-snackbar-item-custom-text-color,
|
|
523
534
|
var(--svelte-ui-snackbar-default-outlined-text-color)
|
|
524
535
|
);
|
|
525
536
|
box-shadow: inset 0 0 0 1px
|
|
526
537
|
var(
|
|
527
|
-
--
|
|
538
|
+
--internal-snackbar-item-custom-color,
|
|
528
539
|
var(--svelte-ui-snackbar-default-outlined-border-color)
|
|
529
540
|
);
|
|
530
541
|
}
|
|
531
542
|
|
|
532
543
|
.snackbar-item__content--outlined.snackbar-item__content--default .snackbar-item__icon {
|
|
533
544
|
color: var(
|
|
534
|
-
--
|
|
545
|
+
--internal-snackbar-item-custom-text-color,
|
|
535
546
|
var(--svelte-ui-snackbar-default-outlined-text-color)
|
|
536
547
|
);
|
|
537
548
|
}
|
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
|
|
3
3
|
<script lang="ts">
|
|
4
4
|
import type { Snippet } from 'svelte';
|
|
5
|
-
import type { HTMLInputAttributes } from 'svelte/elements';
|
|
6
5
|
import type {
|
|
7
6
|
FocusHandler,
|
|
8
7
|
KeyboardHandler,
|
|
@@ -23,8 +22,6 @@
|
|
|
23
22
|
|
|
24
23
|
// HTML属性系
|
|
25
24
|
id?: string;
|
|
26
|
-
inputAttributes?: HTMLInputAttributes | undefined;
|
|
27
|
-
|
|
28
25
|
// スタイル/レイアウト
|
|
29
26
|
size?: 'small' | 'medium' | 'large';
|
|
30
27
|
|
|
@@ -84,7 +81,6 @@
|
|
|
84
81
|
|
|
85
82
|
// HTML属性系
|
|
86
83
|
id = `switch-${Math.random().toString(36).substring(2, 15)}`,
|
|
87
|
-
inputAttributes,
|
|
88
84
|
|
|
89
85
|
// スタイル/レイアウト
|
|
90
86
|
size = 'medium',
|
|
@@ -290,7 +286,6 @@
|
|
|
290
286
|
{disabled}
|
|
291
287
|
{required}
|
|
292
288
|
{id}
|
|
293
|
-
{...inputAttributes}
|
|
294
289
|
onchange={handleChange}
|
|
295
290
|
onfocus={handleFocus}
|
|
296
291
|
onblur={handleBlur}
|
|
@@ -334,7 +329,7 @@
|
|
|
334
329
|
* Base Styles
|
|
335
330
|
* ============================================= */
|
|
336
331
|
.switch {
|
|
337
|
-
display: flex;
|
|
332
|
+
display: inline-flex;
|
|
338
333
|
align-items: center;
|
|
339
334
|
width: fit-content;
|
|
340
335
|
contain: layout;
|
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
import type { Snippet } from 'svelte';
|
|
2
|
-
import type { HTMLInputAttributes } from 'svelte/elements';
|
|
3
2
|
import type { FocusHandler, KeyboardHandler, MouseHandler, TouchHandler, PointerHandler } from '../types/callbackHandlers';
|
|
4
3
|
export type SwitchProps = {
|
|
5
4
|
children?: Snippet;
|
|
6
5
|
value: boolean;
|
|
7
6
|
id?: string;
|
|
8
|
-
inputAttributes?: HTMLInputAttributes | undefined;
|
|
9
7
|
size?: 'small' | 'medium' | 'large';
|
|
10
8
|
disabled?: boolean;
|
|
11
9
|
required?: boolean;
|
|
@@ -71,23 +71,19 @@
|
|
|
71
71
|
return `${pathPrefix}${tabItem.href.startsWith('/') ? '' : '/'}${tabItem.href}`;
|
|
72
72
|
});
|
|
73
73
|
|
|
74
|
-
//
|
|
75
|
-
const
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
if (selectedTextColor !== undefined)
|
|
79
|
-
parts.push(`--svelte-ui-tab-item-selected-text-color: ${selectedTextColor}`);
|
|
80
|
-
if (selectedBarColor !== undefined)
|
|
81
|
-
parts.push(`--svelte-ui-tab-item-selected-bar-color: ${selectedBarColor}`);
|
|
82
|
-
return parts.length > 0 ? parts.join('; ') : undefined;
|
|
83
|
-
});
|
|
74
|
+
// 明示的に渡されたときだけ内部CSS変数で上書き。未渡しなら variables の tab 用変数をそのまま参照
|
|
75
|
+
const internalTextColor = $derived(textColor);
|
|
76
|
+
const internalSelectedTextColor = $derived(selectedTextColor);
|
|
77
|
+
const internalSelectedBarColor = $derived(selectedBarColor);
|
|
84
78
|
</script>
|
|
85
79
|
|
|
86
80
|
{#if isDisabled}
|
|
87
81
|
<span
|
|
88
82
|
class="tab-item tab-item--disabled"
|
|
89
83
|
class:tab-item--selected={isSelected}
|
|
90
|
-
style={
|
|
84
|
+
style:--internal-tab-item-text-color={internalTextColor}
|
|
85
|
+
style:--internal-tab-item-selected-text-color={internalSelectedTextColor}
|
|
86
|
+
style:--internal-tab-item-selected-bar-color={internalSelectedBarColor}
|
|
91
87
|
role="tab"
|
|
92
88
|
aria-selected={isSelected}
|
|
93
89
|
aria-disabled="true"
|
|
@@ -116,7 +112,9 @@
|
|
|
116
112
|
href={hrefWithPrefix}
|
|
117
113
|
class="tab-item"
|
|
118
114
|
class:tab-item--selected={isSelected}
|
|
119
|
-
style={
|
|
115
|
+
style:--internal-tab-item-text-color={internalTextColor}
|
|
116
|
+
style:--internal-tab-item-selected-text-color={internalSelectedTextColor}
|
|
117
|
+
style:--internal-tab-item-selected-bar-color={internalSelectedBarColor}
|
|
120
118
|
role="tab"
|
|
121
119
|
aria-selected={isSelected}
|
|
122
120
|
tabindex={0}
|
|
@@ -149,7 +147,7 @@
|
|
|
149
147
|
gap: var(--svelte-ui-tab-item-icon-gap);
|
|
150
148
|
position: relative;
|
|
151
149
|
padding: var(--svelte-ui-tab-item-padding);
|
|
152
|
-
color: var(--svelte-ui-tab-item-text-color);
|
|
150
|
+
color: var(--internal-tab-item-text-color, var(--svelte-ui-tab-item-text-color));
|
|
153
151
|
white-space: nowrap;
|
|
154
152
|
text-decoration: none;
|
|
155
153
|
transition-property: background-color, color, outline;
|
|
@@ -159,7 +157,7 @@
|
|
|
159
157
|
|
|
160
158
|
@media (hover: hover) {
|
|
161
159
|
.tab-item:hover:not(.tab-item--selected) {
|
|
162
|
-
color: var(--svelte-ui-tab-item-selected-text-color);
|
|
160
|
+
color: var(--internal-tab-item-selected-text-color, var(--svelte-ui-tab-item-selected-text-color));
|
|
163
161
|
}
|
|
164
162
|
.tab-item:hover:not(.tab-item--selected)::before {
|
|
165
163
|
opacity: 1;
|
|
@@ -178,7 +176,7 @@
|
|
|
178
176
|
outline-offset: var(--svelte-ui-focus-outline-offset-inner);
|
|
179
177
|
}
|
|
180
178
|
.tab-item:focus:not(.tab-item--selected) {
|
|
181
|
-
color: var(--svelte-ui-tab-item-selected-text-color);
|
|
179
|
+
color: var(--internal-tab-item-selected-text-color, var(--svelte-ui-tab-item-selected-text-color));
|
|
182
180
|
}
|
|
183
181
|
.tab-item:focus:not(.tab-item--selected)::before {
|
|
184
182
|
opacity: 1;
|
|
@@ -193,7 +191,7 @@
|
|
|
193
191
|
bottom: 0;
|
|
194
192
|
width: calc(100% - 2 * var(--svelte-ui-tab-item-padding-x) + 2 * var(--svelte-ui-tab-item-selected-bar-offset));
|
|
195
193
|
height: var(--svelte-ui-tab-item-selected-bar-height);
|
|
196
|
-
background-color: var(--svelte-ui-tab-item-selected-bar-color);
|
|
194
|
+
background-color: var(--internal-tab-item-selected-bar-color, var(--svelte-ui-tab-item-selected-bar-color));
|
|
197
195
|
border-radius: var(--svelte-ui-tab-item-selected-bar-radius);
|
|
198
196
|
opacity: 0;
|
|
199
197
|
transition-property: opacity;
|
|
@@ -201,7 +199,7 @@
|
|
|
201
199
|
}
|
|
202
200
|
|
|
203
201
|
.tab-item--selected {
|
|
204
|
-
color: var(--svelte-ui-tab-item-selected-text-color);
|
|
202
|
+
color: var(--internal-tab-item-selected-text-color, var(--svelte-ui-tab-item-selected-text-color));
|
|
205
203
|
background-color: transparent;
|
|
206
204
|
}
|
|
207
205
|
|
|
@@ -33,8 +33,6 @@
|
|
|
33
33
|
wrap?: 'soft' | 'hard' | null;
|
|
34
34
|
spellcheck?: boolean | null;
|
|
35
35
|
autocapitalize?: 'off' | 'none' | 'on' | 'sentences' | 'words' | 'characters' | null;
|
|
36
|
-
textareaAttributes?: HTMLTextareaAttributes | undefined;
|
|
37
|
-
|
|
38
36
|
// スタイル/レイアウト
|
|
39
37
|
rows?: number;
|
|
40
38
|
minHeight?: string | number | null;
|
|
@@ -119,7 +117,6 @@
|
|
|
119
117
|
wrap = null,
|
|
120
118
|
spellcheck = null,
|
|
121
119
|
autocapitalize = null,
|
|
122
|
-
textareaAttributes,
|
|
123
120
|
|
|
124
121
|
// スタイル/レイアウト
|
|
125
122
|
rows = 3,
|
|
@@ -524,13 +521,16 @@
|
|
|
524
521
|
class:textarea--readonly={readonly}
|
|
525
522
|
class:textarea--focused={isFocused}
|
|
526
523
|
data-testid="textarea"
|
|
527
|
-
style=
|
|
524
|
+
style:width={widthStyle}
|
|
525
|
+
style:max-height={!inline ? maxHeightStyle : undefined}
|
|
528
526
|
>
|
|
529
527
|
<div
|
|
530
528
|
bind:this={displayTextRef}
|
|
531
529
|
class="textarea__display-text"
|
|
532
530
|
class:textarea__display-text--placeholder={!hasDisplayValue}
|
|
533
|
-
style
|
|
531
|
+
style:min-height={minHeightStyle}
|
|
532
|
+
style:max-height={maxHeightStyle}
|
|
533
|
+
style={customStyle}
|
|
534
534
|
>
|
|
535
535
|
{@html displayValue}
|
|
536
536
|
</div>
|
|
@@ -552,7 +552,8 @@
|
|
|
552
552
|
{spellcheck}
|
|
553
553
|
{autocapitalize}
|
|
554
554
|
class:resizable
|
|
555
|
-
style
|
|
555
|
+
style:min-height={minHeightStyle}
|
|
556
|
+
style={customStyle}
|
|
556
557
|
onchange={handleChange}
|
|
557
558
|
oninput={handleInput}
|
|
558
559
|
onfocus={handleFocus}
|
|
@@ -579,7 +580,6 @@
|
|
|
579
580
|
onpointermove={handlePointerMove}
|
|
580
581
|
onpointercancel={handlePointerCancel}
|
|
581
582
|
onscroll={handleScroll}
|
|
582
|
-
{...textareaAttributes}
|
|
583
583
|
{...restProps}
|
|
584
584
|
></textarea>
|
|
585
585
|
</div>
|
|
@@ -587,7 +587,9 @@
|
|
|
587
587
|
<div
|
|
588
588
|
bind:this={linkTextRef}
|
|
589
589
|
class="textarea__link-text"
|
|
590
|
-
style
|
|
590
|
+
style:min-height={minHeightStyle}
|
|
591
|
+
style:max-height={maxHeightStyle}
|
|
592
|
+
style={customStyle}
|
|
591
593
|
>
|
|
592
594
|
{@html linkHtmlValue}
|
|
593
595
|
</div>
|
|
@@ -13,7 +13,6 @@ export type TextareaProps = {
|
|
|
13
13
|
wrap?: 'soft' | 'hard' | null;
|
|
14
14
|
spellcheck?: boolean | null;
|
|
15
15
|
autocapitalize?: 'off' | 'none' | 'on' | 'sentences' | 'words' | 'characters' | null;
|
|
16
|
-
textareaAttributes?: HTMLTextareaAttributes | undefined;
|
|
17
16
|
rows?: number;
|
|
18
17
|
minHeight?: string | number | null;
|
|
19
18
|
maxHeight?: string | number | null;
|