tide-design-system 2.4.4 → 2.4.6
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/css/reset.css +1 -1
- package/dist/css/utilities-responsive.css +0 -546
- package/dist/style.css +1 -1
- package/dist/tide-design-system.cjs +2 -2
- package/dist/tide-design-system.esm.d.ts +42 -11
- package/dist/tide-design-system.esm.js +1536 -1454
- package/dist/utilities/storybook.ts +6 -2
- package/dist/utilities/validation.ts +1 -1
- package/index.ts +6 -4
- package/package.json +1 -1
- package/src/assets/css/reset.css +1 -1
- package/src/assets/css/utilities-responsive.css +0 -546
- package/src/components/TideAlert.vue +46 -3
- package/src/components/TideButton.vue +14 -4
- package/src/components/TideButtonIcon.vue +12 -2
- package/src/components/TideButtonPagination.vue +11 -16
- package/src/components/TideButtonSegmented.vue +1 -0
- package/src/components/TideCard.vue +11 -2
- package/src/components/TideCarousel.vue +9 -4
- package/src/components/TideChipAction.vue +1 -0
- package/src/components/TideChipFilter.vue +1 -0
- package/src/components/TideChipInput.vue +1 -0
- package/src/components/TideIcon.vue +1 -1
- package/src/components/TideImage.vue +9 -9
- package/src/components/TideInputText.vue +2 -0
- package/src/components/TideInputTextDeprecated.vue +2 -0
- package/src/components/TideInputTextarea.vue +2 -2
- package/src/components/TideLink.vue +2 -1
- package/src/components/TideModal.vue +91 -85
- package/src/components/TideSwitch.vue +1 -0
- package/src/stories/TideAlert.stories.ts +37 -1
- package/src/stories/TideButtonPagination.stories.ts +6 -6
- package/src/stories/TideCarousel.stories.ts +0 -1
- package/src/stories/TideInputCheckbox.stories.ts +58 -23
- package/src/stories/TideInputRadio.stories.ts +39 -30
- package/src/stories/TideInputSelect.stories.ts +51 -27
- package/src/stories/TideInputText.stories.ts +83 -23
- package/src/stories/TideInputTextarea.stories.ts +66 -17
- package/src/stories/TideLink.stories.ts +1 -14
- package/src/stories/TidePagination.stories.ts +2 -2
- package/src/stories/TidePopover.stories.ts +1 -1
- package/src/types/Badge.ts +4 -0
- package/src/types/Element.ts +2 -2
- package/src/types/Storybook.ts +4 -6
- package/src/types/Type.ts +6 -0
- package/src/utilities/storybook.ts +6 -2
- package/src/utilities/validation.ts +1 -1
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
<script lang="ts" setup>
|
|
2
|
-
import { computed } from 'vue';
|
|
2
|
+
import { Comment, computed, useSlots } from 'vue';
|
|
3
3
|
|
|
4
4
|
import TideButtonIcon from '@/components/TideButtonIcon.vue';
|
|
5
5
|
import TideIcon from '@/components/TideIcon.vue';
|
|
6
|
+
import TideLink from '@/components/TideLink.vue';
|
|
6
7
|
import { ALERT } from '@/types/Alert';
|
|
8
|
+
import { ELEMENT } from '@/types/Element';
|
|
7
9
|
import { ICON } from '@/types/Icon';
|
|
8
10
|
import { PRIORITY } from '@/types/Priority';
|
|
9
11
|
import { SIZE } from '@/types/Size';
|
|
@@ -13,6 +15,7 @@
|
|
|
13
15
|
|
|
14
16
|
type Props = {
|
|
15
17
|
heading?: string;
|
|
18
|
+
ctaLabel?: string;
|
|
16
19
|
isDismissible?: boolean;
|
|
17
20
|
isToast?: boolean;
|
|
18
21
|
type?: Alert;
|
|
@@ -20,9 +23,11 @@
|
|
|
20
23
|
|
|
21
24
|
type Emits = {
|
|
22
25
|
(event: 'close'): void;
|
|
26
|
+
(event: 'ctaClick'): void;
|
|
23
27
|
};
|
|
24
28
|
|
|
25
29
|
const props = withDefaults(defineProps<Props>(), {
|
|
30
|
+
ctaLabel: undefined,
|
|
26
31
|
heading: undefined,
|
|
27
32
|
isDismissible: true,
|
|
28
33
|
isToast: false,
|
|
@@ -30,6 +35,15 @@
|
|
|
30
35
|
});
|
|
31
36
|
|
|
32
37
|
const emit = defineEmits<Emits>();
|
|
38
|
+
const slots = useSlots();
|
|
39
|
+
const hasBody = computed(() => {
|
|
40
|
+
const nodes = slots.default?.();
|
|
41
|
+
if (!nodes) return false;
|
|
42
|
+
|
|
43
|
+
return nodes.some(
|
|
44
|
+
(node) => node.type !== Comment && (typeof node.children !== 'string' || node.children.trim().length > 0)
|
|
45
|
+
);
|
|
46
|
+
});
|
|
33
47
|
|
|
34
48
|
const iconType = computed(() => {
|
|
35
49
|
if (props.type === ALERT.ERROR) return ICON.PRIORITY_HIGH;
|
|
@@ -78,8 +92,24 @@
|
|
|
78
92
|
/>
|
|
79
93
|
</div>
|
|
80
94
|
|
|
81
|
-
<div
|
|
82
|
-
|
|
95
|
+
<div
|
|
96
|
+
:class="[
|
|
97
|
+
'tide-alert-heading',
|
|
98
|
+
CSS.DISPLAY.FLEX,
|
|
99
|
+
CSS.AXIS2.CENTER,
|
|
100
|
+
CSS.FLEX.DIRECTION.ROW,
|
|
101
|
+
!hasBody ? [CSS.AXIS1.BETWEEN, CSS.MARGIN.RIGHT.HALF] : '',
|
|
102
|
+
]"
|
|
103
|
+
>
|
|
104
|
+
<span :class="CSS.FONT.ROLE.LABEL_2_SEMIBOLD">{{ props.heading }}</span>
|
|
105
|
+
|
|
106
|
+
<TideLink
|
|
107
|
+
:class="[CSS.FONT.ROLE.LINK_2]"
|
|
108
|
+
:element="ELEMENT.BUTTON"
|
|
109
|
+
:label="props.ctaLabel"
|
|
110
|
+
@click="emit('ctaClick')"
|
|
111
|
+
v-if="props.ctaLabel && !hasBody"
|
|
112
|
+
/>
|
|
83
113
|
</div>
|
|
84
114
|
|
|
85
115
|
<TideButtonIcon
|
|
@@ -93,6 +123,19 @@
|
|
|
93
123
|
|
|
94
124
|
<div :class="['tide-alert-body', CSS.FONT.ROLE.BODY_2, !props.isToast && CSS.FONT.COLOR.SURFACE.DEFAULT]">
|
|
95
125
|
<slot />
|
|
126
|
+
|
|
127
|
+
<div
|
|
128
|
+
:class="[CSS.MARGIN.TOP.HALF]"
|
|
129
|
+
v-if="props.ctaLabel && hasBody"
|
|
130
|
+
>
|
|
131
|
+
<TideLink
|
|
132
|
+
:class="[CSS.FONT.ROLE.LINK_2]"
|
|
133
|
+
:element="ELEMENT.BUTTON"
|
|
134
|
+
:label="props.ctaLabel"
|
|
135
|
+
@click="emit('ctaClick')"
|
|
136
|
+
v-if="props.ctaLabel"
|
|
137
|
+
/>
|
|
138
|
+
</div>
|
|
96
139
|
</div>
|
|
97
140
|
</div>
|
|
98
141
|
</template>
|
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
<script lang="ts" setup>
|
|
2
|
+
import { computed } from 'vue';
|
|
3
|
+
|
|
2
4
|
import TideIcon from '@/components/TideIcon.vue';
|
|
3
5
|
import { ELEMENT } from '@/types/Element';
|
|
4
6
|
import { PRIORITY } from '@/types/Priority';
|
|
@@ -10,6 +12,7 @@
|
|
|
10
12
|
import type { Icon } from '@/types/Icon';
|
|
11
13
|
import type { Priority } from '@/types/Priority';
|
|
12
14
|
import type { SizeButton } from '@/types/Size';
|
|
15
|
+
import type { ButtonType } from '@/types/Type';
|
|
13
16
|
|
|
14
17
|
type Props = {
|
|
15
18
|
disabled?: boolean;
|
|
@@ -21,6 +24,7 @@
|
|
|
21
24
|
label: string;
|
|
22
25
|
priority?: Priority;
|
|
23
26
|
size?: SizeButton;
|
|
27
|
+
type?: ButtonType;
|
|
24
28
|
};
|
|
25
29
|
|
|
26
30
|
const props = withDefaults(defineProps<Props>(), {
|
|
@@ -33,7 +37,12 @@
|
|
|
33
37
|
label: undefined,
|
|
34
38
|
priority: PRIORITY.PRIMARY,
|
|
35
39
|
size: SIZE_BUTTON.LARGE,
|
|
40
|
+
type: undefined,
|
|
36
41
|
});
|
|
42
|
+
|
|
43
|
+
const typeAttribute = computed<string | undefined>(() =>
|
|
44
|
+
props.element === ELEMENT.BUTTON ? props.type ?? ELEMENT.BUTTON : undefined
|
|
45
|
+
);
|
|
37
46
|
</script>
|
|
38
47
|
|
|
39
48
|
<template>
|
|
@@ -43,18 +52,19 @@
|
|
|
43
52
|
props.priority && `tide-button-${props.priority}`,
|
|
44
53
|
props.element === ELEMENT.LINK ? [CSS.DISPLAY.INLINE_FLEX] : [CSS.DISPLAY.FLEX],
|
|
45
54
|
props.element === ELEMENT.LINK ? CSS.UNDERLINE.REST.OFF : '',
|
|
46
|
-
size === SIZE_BUTTON.SMALL
|
|
47
|
-
|
|
55
|
+
size === SIZE_BUTTON.SMALL
|
|
56
|
+
? [CSS.FONT.ROLE.BUTTON_2, CSS.PADDING.X.ONE, CSS.PADDING.Y.HALF, CSS.BORDER.RADIUS.QUARTER]
|
|
57
|
+
: [CSS.FONT.ROLE.BUTTON_1, CSS.PADDING.X.TWO, CSS.PADDING.Y.ONE, CSS.BORDER.RADIUS.HALF],
|
|
48
58
|
CSS.AXIS1.CENTER,
|
|
49
59
|
CSS.AXIS2.CENTER,
|
|
50
60
|
CSS.GAP.HALF,
|
|
51
|
-
CSS.BORDER.RADIUS.HALF,
|
|
52
61
|
CSS.FONT.ROLE.LABEL_1_SEMIBOLD,
|
|
53
62
|
]"
|
|
54
63
|
:disabled="props.element === ELEMENT.BUTTON && props.disabled"
|
|
55
64
|
:href="props.element === ELEMENT.LINK && props.href ? props.href : undefined"
|
|
56
65
|
:target="props.element === ELEMENT.LINK && props.isNewTab ? TARGET.BLANK : TARGET.SELF"
|
|
57
|
-
:
|
|
66
|
+
:type="typeAttribute"
|
|
67
|
+
:is="element"
|
|
58
68
|
>
|
|
59
69
|
<TideIcon
|
|
60
70
|
:icon="props.iconLeading"
|
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
<script lang="ts" setup>
|
|
2
|
+
import { computed } from 'vue';
|
|
3
|
+
|
|
2
4
|
import TideIcon from '@/components/TideIcon.vue';
|
|
3
5
|
import { ELEMENT } from '@/types/Element';
|
|
4
6
|
import { PRIORITY } from '@/types/Priority';
|
|
@@ -9,6 +11,7 @@
|
|
|
9
11
|
import type { Element } from '@/types/Element';
|
|
10
12
|
import type { Icon } from '@/types/Icon';
|
|
11
13
|
import type { Priority } from '@/types/Priority';
|
|
14
|
+
import type { ButtonType } from '@/types/Type';
|
|
12
15
|
|
|
13
16
|
type Props = {
|
|
14
17
|
disabled?: boolean;
|
|
@@ -17,6 +20,7 @@
|
|
|
17
20
|
icon: Icon;
|
|
18
21
|
isNewTab?: boolean;
|
|
19
22
|
priority?: Priority;
|
|
23
|
+
type?: ButtonType;
|
|
20
24
|
};
|
|
21
25
|
|
|
22
26
|
const props = withDefaults(defineProps<Props>(), {
|
|
@@ -26,14 +30,19 @@
|
|
|
26
30
|
icon: undefined,
|
|
27
31
|
isNewTab: false,
|
|
28
32
|
priority: PRIORITY.PRIMARY,
|
|
33
|
+
type: undefined,
|
|
29
34
|
});
|
|
35
|
+
|
|
36
|
+
const typeAttribute = computed<string | undefined>(() =>
|
|
37
|
+
props.element === ELEMENT.BUTTON ? props.type ?? ELEMENT.BUTTON : undefined
|
|
38
|
+
);
|
|
30
39
|
</script>
|
|
31
40
|
|
|
32
41
|
<template>
|
|
33
42
|
<component
|
|
34
43
|
:aria-label="props.icon"
|
|
35
44
|
:class="[
|
|
36
|
-
|
|
45
|
+
'tide-button-icon',
|
|
37
46
|
props.priority && `tide-button-${props.priority}`,
|
|
38
47
|
[CSS.DISPLAY.FLEX, CSS.AXIS1.CENTER, CSS.AXIS2.CENTER, CSS.BORDER.RADIUS.FULL, CSS.PADDING.FULL.HALF],
|
|
39
48
|
props.element === ELEMENT.LINK ? [CSS.UNDERLINE.REST.OFF] : '',
|
|
@@ -41,7 +50,8 @@
|
|
|
41
50
|
:disabled="props.element === ELEMENT.BUTTON && props.disabled"
|
|
42
51
|
:href="props.element === ELEMENT.LINK && props.href ? props.href : undefined"
|
|
43
52
|
:target="props.element === ELEMENT.LINK && props.isNewTab ? TARGET.BLANK : TARGET.SELF"
|
|
44
|
-
:
|
|
53
|
+
:type="typeAttribute"
|
|
54
|
+
:is="element"
|
|
45
55
|
>
|
|
46
56
|
<TideIcon
|
|
47
57
|
:icon="props.icon"
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
<script lang="ts" setup>
|
|
2
|
-
import {
|
|
2
|
+
import { ELEMENT_BROAD } from '@/types/Element';
|
|
3
3
|
import { CSS } from '@/types/Styles';
|
|
4
4
|
|
|
5
|
-
import type {
|
|
5
|
+
import type { ElementBroad } from '@/types/Element';
|
|
6
6
|
|
|
7
7
|
type Props = {
|
|
8
8
|
disabled?: boolean;
|
|
9
|
-
element?:
|
|
9
|
+
element?: ElementBroad;
|
|
10
10
|
href?: string;
|
|
11
11
|
label: string | number;
|
|
12
12
|
};
|
|
13
13
|
|
|
14
14
|
const props = withDefaults(defineProps<Props>(), {
|
|
15
15
|
disabled: false,
|
|
16
|
-
element:
|
|
16
|
+
element: ELEMENT_BROAD.BUTTON,
|
|
17
17
|
href: undefined,
|
|
18
18
|
label: undefined,
|
|
19
19
|
});
|
|
@@ -22,21 +22,16 @@
|
|
|
22
22
|
<template>
|
|
23
23
|
<component
|
|
24
24
|
:class="[
|
|
25
|
-
|
|
25
|
+
'tide-button-icon',
|
|
26
26
|
[CSS.DISPLAY.INLINE_BLOCK, CSS.BORDER.RADIUS.FULL, CSS.PADDING.FULL.HALF],
|
|
27
|
-
props.element ===
|
|
28
|
-
props.element ===
|
|
27
|
+
props.element === ELEMENT_BROAD.LINK ? [CSS.UNDERLINE.REST.OFF] : '',
|
|
28
|
+
props.element === ELEMENT_BROAD.DIV ? [CSS.CURSOR.POINTER] : '',
|
|
29
29
|
[CSS.FONT.ROLE.HEADLINE_3],
|
|
30
30
|
]"
|
|
31
|
-
:disabled="props.element ===
|
|
32
|
-
:href="props.element ===
|
|
33
|
-
:
|
|
34
|
-
|
|
35
|
-
? 'a'
|
|
36
|
-
: props.element === ELEMENT_TEXT_AS_ICON.BUTTON
|
|
37
|
-
? 'button'
|
|
38
|
-
: 'div'
|
|
39
|
-
"
|
|
31
|
+
:disabled="props.element === ELEMENT_BROAD.BUTTON && props.disabled"
|
|
32
|
+
:href="props.element === ELEMENT_BROAD.LINK && props.href ? props.href : undefined"
|
|
33
|
+
:type="element === ELEMENT_BROAD.BUTTON ? ELEMENT_BROAD.BUTTON : undefined"
|
|
34
|
+
:is="element"
|
|
40
35
|
>
|
|
41
36
|
<span :class="['label', CSS.DISPLAY.FLEX, CSS.AXIS1.CENTER, CSS.AXIS2.CENTER]">
|
|
42
37
|
{{ props.label }}
|
|
@@ -1,10 +1,14 @@
|
|
|
1
1
|
<script lang="ts" setup>
|
|
2
|
+
import { computed } from 'vue';
|
|
3
|
+
|
|
2
4
|
import TideIcon from '@/components/TideIcon.vue';
|
|
3
5
|
import { TYPE_CARD } from '@/types/Card';
|
|
6
|
+
import { ELEMENT_BROAD } from '@/types/Element';
|
|
4
7
|
import { SIZE } from '@/types/Size';
|
|
5
8
|
import { CSS } from '@/types/Styles';
|
|
6
9
|
|
|
7
10
|
import type { CardType } from '@/types/Card';
|
|
11
|
+
import type { ElementBroad } from '@/types/Element';
|
|
8
12
|
import type { Icon } from '@/types/Icon';
|
|
9
13
|
|
|
10
14
|
type Props = {
|
|
@@ -16,13 +20,17 @@
|
|
|
16
20
|
href?: string;
|
|
17
21
|
};
|
|
18
22
|
|
|
19
|
-
withDefaults(defineProps<Props>(), {
|
|
23
|
+
const props = withDefaults(defineProps<Props>(), {
|
|
20
24
|
description: undefined,
|
|
21
25
|
href: undefined,
|
|
22
26
|
icon: undefined,
|
|
23
27
|
selected: undefined,
|
|
24
28
|
type: TYPE_CARD.INFORMATIONAL,
|
|
25
29
|
});
|
|
30
|
+
|
|
31
|
+
const rootElement = computed<ElementBroad>(() =>
|
|
32
|
+
props.href ? ELEMENT_BROAD.LINK : props.type === TYPE_CARD.INFORMATIONAL ? ELEMENT_BROAD.DIV : ELEMENT_BROAD.DIV
|
|
33
|
+
);
|
|
26
34
|
</script>
|
|
27
35
|
|
|
28
36
|
<template>
|
|
@@ -42,7 +50,8 @@
|
|
|
42
50
|
type === TYPE_CARD.SELECTABLE && selected && 'selected',
|
|
43
51
|
]"
|
|
44
52
|
:href="href"
|
|
45
|
-
:
|
|
53
|
+
:type="rootElement === ELEMENT_BROAD.BUTTON ? ELEMENT_BROAD.BUTTON : undefined"
|
|
54
|
+
:is="rootElement"
|
|
46
55
|
>
|
|
47
56
|
<TideIcon
|
|
48
57
|
:class="[CSS.FLEX.GROW.OFF, CSS.FLEX.SHRINK.OFF]"
|
|
@@ -12,7 +12,6 @@
|
|
|
12
12
|
isHeadline1?: boolean;
|
|
13
13
|
isHideawayButtons?: boolean;
|
|
14
14
|
isScrollByPage?: boolean;
|
|
15
|
-
isTouchscreen?: boolean;
|
|
16
15
|
maxDots?: number;
|
|
17
16
|
subtitle?: string;
|
|
18
17
|
title?: string;
|
|
@@ -24,7 +23,6 @@
|
|
|
24
23
|
isHeadline1: false,
|
|
25
24
|
isHideawayButtons: true,
|
|
26
25
|
isScrollByPage: true,
|
|
27
|
-
isTouchscreen: undefined,
|
|
28
26
|
maxDots: 5,
|
|
29
27
|
subtitle: undefined,
|
|
30
28
|
title: undefined,
|
|
@@ -83,6 +81,7 @@
|
|
|
83
81
|
|
|
84
82
|
contentWidth.value = containerRef.value.scrollWidth;
|
|
85
83
|
frameWidth.value = containerRef.value.clientWidth;
|
|
84
|
+
showButtons.value = contentWidth.value > frameWidth.value;
|
|
86
85
|
};
|
|
87
86
|
|
|
88
87
|
const observeSlides = () => {
|
|
@@ -237,14 +236,14 @@
|
|
|
237
236
|
v-if="props.title"
|
|
238
237
|
>
|
|
239
238
|
<div
|
|
240
|
-
:class="[
|
|
239
|
+
:class="[isHeadline1 ? CSS.FONT.ROLE.HEADLINE_1 : CSS.FONT.ROLE.HEADLINE_2]"
|
|
241
240
|
v-if="props.title"
|
|
242
241
|
>
|
|
243
242
|
{{ props.title }}
|
|
244
243
|
</div>
|
|
245
244
|
|
|
246
245
|
<div
|
|
247
|
-
:class="[CSS.
|
|
246
|
+
:class="[CSS.FONT.ROLE.LABEL_2, CSS.FONT.COLOR.SURFACE.VARIANT]"
|
|
248
247
|
v-if="props.subtitle"
|
|
249
248
|
>
|
|
250
249
|
{{ props.subtitle }}
|
|
@@ -393,4 +392,10 @@
|
|
|
393
392
|
transform: scale(1);
|
|
394
393
|
opacity: 1;
|
|
395
394
|
}
|
|
395
|
+
|
|
396
|
+
@media (pointer: coarse) {
|
|
397
|
+
.tide-carousel .tide-carousel-button-overlay {
|
|
398
|
+
display: none;
|
|
399
|
+
}
|
|
400
|
+
}
|
|
396
401
|
</style>
|
|
@@ -61,14 +61,6 @@
|
|
|
61
61
|
<picture
|
|
62
62
|
:class="['tide-image', CSS.DISPLAY.BLOCK]"
|
|
63
63
|
ref="picture"
|
|
64
|
-
:style="
|
|
65
|
-
width || height
|
|
66
|
-
? {
|
|
67
|
-
width: width || undefined,
|
|
68
|
-
height: height || undefined,
|
|
69
|
-
}
|
|
70
|
-
: undefined
|
|
71
|
-
"
|
|
72
64
|
>
|
|
73
65
|
<source
|
|
74
66
|
:key="source.srcset"
|
|
@@ -79,11 +71,19 @@
|
|
|
79
71
|
|
|
80
72
|
<img
|
|
81
73
|
:alt="alt"
|
|
82
|
-
:class="[
|
|
74
|
+
:class="[
|
|
75
|
+
'tide-image-img',
|
|
76
|
+
!props.width && CSS.WIDTH.FULL,
|
|
77
|
+
!props.height && CSS.HEIGHT.FULL,
|
|
78
|
+
CSS.OBJECT.CENTER,
|
|
79
|
+
objectFitClassName,
|
|
80
|
+
]"
|
|
83
81
|
:fetchpriority="isLazy ? undefined : 'high'"
|
|
82
|
+
:height="props.height"
|
|
84
83
|
:loading="props.isLazy ? 'lazy' : 'eager'"
|
|
85
84
|
ref="img"
|
|
86
85
|
:src="src ?? imageDefault"
|
|
86
|
+
:width="props.width"
|
|
87
87
|
@error="setImageFromDefault"
|
|
88
88
|
/>
|
|
89
89
|
</picture>
|
|
@@ -253,6 +253,7 @@
|
|
|
253
253
|
|
|
254
254
|
<button
|
|
255
255
|
@click="handleClear"
|
|
256
|
+
type="button"
|
|
256
257
|
v-if="shouldShowClearButton"
|
|
257
258
|
>
|
|
258
259
|
<TideIcon
|
|
@@ -264,6 +265,7 @@
|
|
|
264
265
|
|
|
265
266
|
<button
|
|
266
267
|
@click="showPassword = !showPassword"
|
|
268
|
+
type="button"
|
|
267
269
|
v-if="shouldShowPasswordButton"
|
|
268
270
|
>
|
|
269
271
|
<TideIcon
|
|
@@ -234,6 +234,7 @@
|
|
|
234
234
|
|
|
235
235
|
<button
|
|
236
236
|
@click="handleClear"
|
|
237
|
+
type="button"
|
|
237
238
|
v-if="hasClear && type !== TEXT_INPUT_TYPE.PASSWORD"
|
|
238
239
|
>
|
|
239
240
|
<TideIcon
|
|
@@ -245,6 +246,7 @@
|
|
|
245
246
|
|
|
246
247
|
<button
|
|
247
248
|
@click="showPassword = !showPassword"
|
|
249
|
+
type="button"
|
|
248
250
|
v-if="type === TEXT_INPUT_TYPE.PASSWORD"
|
|
249
251
|
>
|
|
250
252
|
<TideIcon
|
|
@@ -119,7 +119,6 @@
|
|
|
119
119
|
CSS.GAP.HALF,
|
|
120
120
|
CSS.POSITION.RELATIVE,
|
|
121
121
|
CSS.BORDER.RADIUS.HALF,
|
|
122
|
-
CSS.PADDING.LEFT.ONE,
|
|
123
122
|
CSS.PADDING.TOP.HALF,
|
|
124
123
|
CSS.OVERFLOW.XY.HIDDEN,
|
|
125
124
|
CSS.BG.SURFACE.DEFAULT,
|
|
@@ -132,6 +131,7 @@
|
|
|
132
131
|
<div
|
|
133
132
|
:class="[
|
|
134
133
|
'tide-input-textarea-label',
|
|
134
|
+
CSS.PADDING.X.ONE,
|
|
135
135
|
hasMinilabel ? ['minilabel', CSS.FONT.ROLE.LABEL_3] : CSS.FONT.ROLE.LABEL_1,
|
|
136
136
|
!showError && CSS.FONT.COLOR.SURFACE.VARIANT,
|
|
137
137
|
CSS.POINTER_EVENTS.OFF,
|
|
@@ -142,7 +142,7 @@
|
|
|
142
142
|
</div>
|
|
143
143
|
|
|
144
144
|
<textarea
|
|
145
|
-
:class="[CSS.DISPLAY.BLOCK, CSS.
|
|
145
|
+
:class="[CSS.DISPLAY.BLOCK, CSS.FONT.ROLE.BODY_1, CSS.PADDING.X.ONE, CSS.WIDTH.FULL]"
|
|
146
146
|
:maxlength="maxlength"
|
|
147
147
|
:minlength="minlength"
|
|
148
148
|
:name="name"
|
|
@@ -38,7 +38,8 @@
|
|
|
38
38
|
]"
|
|
39
39
|
:href="props.href"
|
|
40
40
|
:target="props.isNewTab ? TARGET.BLANK : TARGET.SELF"
|
|
41
|
-
:
|
|
41
|
+
:type="element === ELEMENT.BUTTON ? ELEMENT.BUTTON : undefined"
|
|
42
|
+
:is="element"
|
|
42
43
|
>
|
|
43
44
|
<TideIcon
|
|
44
45
|
:class="[CSS.DISPLAY.INLINE_BLOCK, CSS.ALIGN.Y.MIDDLE, CSS.MARGIN.RIGHT.QUARTER]"
|