@eturnity/eturnity_reusable_components 8.16.9-SLD.4 → 8.16.9-SLD.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/package.json
CHANGED
@@ -1,4 +1,3 @@
|
|
1
|
-
<svg width="
|
2
|
-
<path
|
3
|
-
<path d="M26.027 32.4384L25.9726 32L26.027 31.5616C26.2236 29.9764 27.4763 28.7236 29.0616 28.527L29.5 28.4726L29.9384 28.527C31.6671 28.7414 33 30.2112 33 32C33 33.7888 31.6671 35.2586 29.9384 35.473L29.5 35.5274L29.0616 35.473C27.4764 35.2764 26.2236 34.0236 26.027 32.4384Z" stroke="black" stroke-miterlimit="8"/>
|
1
|
+
<svg width="40" height="64" viewBox="0 0 40 64" fill="none" xmlns="http://www.w3.org/2000/svg">
|
2
|
+
<path d="M33.2002 28.0615C35.0754 28.3926 36.5 30.0298 36.5 32C36.5 33.9702 35.0754 35.6063 33.2002 35.9375V64H31.7998V35.9375C30.1521 35.6465 28.8535 34.3479 28.5625 32.7002H0V31.2998H28.5625C28.8535 29.652 30.152 28.3525 31.7998 28.0615V0H33.2002V28.0615Z" fill="black"/>
|
4
3
|
</svg>
|
@@ -0,0 +1,4 @@
|
|
1
|
+
<svg width="34" height="65" viewBox="0 0 34 65" fill="none" xmlns="http://www.w3.org/2000/svg">
|
2
|
+
<path fill-rule="evenodd" clip-rule="evenodd" d="M25.5308 32.5C25.7556 34.3125 27.1875 35.7444 29 35.9692L29 64.1365H30L30 35.9692C31.9763 35.7241 33.5 34.044 33.5 32C33.5 29.956 31.9763 28.2759 30 28.0308L30 0H29L29 28.0308C27.1875 28.2556 25.7556 29.6875 25.5308 31.5L0 31.5V32.5L25.5308 32.5Z" fill="black"/>
|
3
|
+
<path d="M26.027 32.4384L25.9726 32L26.027 31.5616C26.2236 29.9764 27.4763 28.7236 29.0616 28.527L29.5 28.4726L29.9384 28.527C31.6671 28.7414 33 30.2112 33 32C33 33.7888 31.6671 35.2586 29.9384 35.473L29.5 35.5274L29.0616 35.473C27.4764 35.2764 26.2236 34.0236 26.027 32.4384Z" stroke="black" stroke-miterlimit="8"/>
|
4
|
+
</svg>
|
@@ -0,0 +1,3 @@
|
|
1
|
+
<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
|
2
|
+
<path class='isStrokePath' d="M2.1068 13.2607L2.95525 10.7154C2.97979 10.6418 3.02115 10.5748 3.07603 10.52L11.5353 2.06066C11.7306 1.8654 12.0472 1.8654 12.2424 2.06066L13.9393 3.75756C14.1346 3.95282 14.1346 4.2694 13.9393 4.46466L5.48004 12.924C5.42515 12.9789 5.35824 13.0202 5.2846 13.0448L2.73925 13.8932C2.34837 14.0235 1.9765 13.6516 2.1068 13.2607Z" stroke="lime"/>
|
3
|
+
</svg>
|
@@ -4,6 +4,7 @@
|
|
4
4
|
:app-theme="appTheme"
|
5
5
|
:button-size="buttonSize"
|
6
6
|
:custom-color="customColor"
|
7
|
+
:height="height"
|
7
8
|
:is-active="isActive"
|
8
9
|
:is-disabled="isDisabled"
|
9
10
|
:min-width="minWidth"
|
@@ -13,6 +14,7 @@
|
|
13
14
|
<IconContainer
|
14
15
|
:app-theme="appTheme"
|
15
16
|
:button-size="buttonSize"
|
17
|
+
:height="height"
|
16
18
|
:type="type"
|
17
19
|
:variant="variant"
|
18
20
|
>
|
@@ -30,7 +32,7 @@
|
|
30
32
|
size="14px"
|
31
33
|
/>
|
32
34
|
</IconContainer>
|
33
|
-
<ButtonContainer :button-size="buttonSize">
|
35
|
+
<ButtonContainer :button-size="buttonSize" :height="height">
|
34
36
|
{{ text }}
|
35
37
|
</ButtonContainer>
|
36
38
|
</ButtonWrapper>
|
@@ -64,9 +66,11 @@
|
|
64
66
|
variant: String,
|
65
67
|
appTheme: String,
|
66
68
|
isActive: Boolean,
|
69
|
+
height: String,
|
67
70
|
}
|
68
71
|
const ButtonWrapper = styled('div', ButtonAttrs)`
|
69
72
|
display: grid;
|
73
|
+
height: ${({ height }) => height};
|
70
74
|
grid-template-columns: auto 1fr;
|
71
75
|
font-size: ${(props) =>
|
72
76
|
props.theme?.mainButton?.size?.[props.buttonSize]?.fontSize};
|
@@ -128,9 +132,11 @@
|
|
128
132
|
|
129
133
|
const ButtonContainerAttrs = {
|
130
134
|
buttonSize: String,
|
135
|
+
height: String,
|
131
136
|
}
|
132
137
|
const ButtonContainer = styled('div', ButtonContainerAttrs)`
|
133
138
|
display: flex;
|
139
|
+
height: ${({ height }) => height};
|
134
140
|
align-items: center;
|
135
141
|
justify-content: center;
|
136
142
|
padding: ${(props) =>
|
@@ -143,9 +149,11 @@
|
|
143
149
|
appTheme: String,
|
144
150
|
type: String,
|
145
151
|
variant: String,
|
152
|
+
height: String,
|
146
153
|
}
|
147
154
|
const IconContainer = styled('div', IconContainerAttrs)`
|
148
155
|
display: grid;
|
156
|
+
height: ${({ height }) => height};
|
149
157
|
align-items: center;
|
150
158
|
justify-items: center;
|
151
159
|
width: ${(props) =>
|
@@ -236,6 +244,10 @@
|
|
236
244
|
type: Boolean,
|
237
245
|
default: false,
|
238
246
|
},
|
247
|
+
height: {
|
248
|
+
type: String,
|
249
|
+
default: 'auto',
|
250
|
+
},
|
239
251
|
},
|
240
252
|
data() {
|
241
253
|
return {
|
@@ -30,17 +30,16 @@
|
|
30
30
|
:color-mode="colorMode"
|
31
31
|
:data-id="item.hasOwnProperty('dataId') ? item.dataId : ''"
|
32
32
|
:inactive-color="inactiveColor"
|
33
|
-
:is-active="
|
33
|
+
:is-active="value == item.value"
|
34
34
|
:primary-color="primaryColor"
|
35
35
|
:secondary-color="secondaryColor"
|
36
36
|
:size="size"
|
37
|
+
:width="item.width || 'auto'"
|
37
38
|
@click="selectItem(item.value)"
|
38
39
|
>
|
39
40
|
<OptionIconContainer v-if="item.icon">
|
40
41
|
<RCIcon
|
41
|
-
:color="
|
42
|
-
selectedValue == item.value ? primaryColor : inactiveColor
|
43
|
-
"
|
42
|
+
:color="value == item.value ? primaryColor : inactiveColor"
|
44
43
|
:name="item.icon"
|
45
44
|
:size="item.iconSize"
|
46
45
|
/>
|
@@ -84,7 +83,6 @@
|
|
84
83
|
const OptionIconContainer = styled.div`
|
85
84
|
display: flex;
|
86
85
|
align-items: center;
|
87
|
-
margin-right: 5px;
|
88
86
|
`
|
89
87
|
const Container = styled.div``
|
90
88
|
|
@@ -130,6 +128,7 @@
|
|
130
128
|
secondaryColor: String,
|
131
129
|
inactiveColor: String,
|
132
130
|
size: String,
|
131
|
+
width: String,
|
133
132
|
}
|
134
133
|
const SwitchOption = styled('div', optionAttrs)`
|
135
134
|
color: ${(props) =>
|
@@ -140,6 +139,8 @@
|
|
140
139
|
${(props) =>
|
141
140
|
props.isActive ? props.secondaryColor : props.inactiveColor};
|
142
141
|
display: flex;
|
142
|
+
width: ${({ width }) => width};
|
143
|
+
word-break: break-word;
|
143
144
|
align-items: center;
|
144
145
|
justify-content: center;
|
145
146
|
flex-grow: 1;
|
@@ -156,6 +157,7 @@
|
|
156
157
|
margin-right: -1px;
|
157
158
|
transition: all 0.1s ease-in-out;
|
158
159
|
overflow: hidden;
|
160
|
+
gap: 5px;
|
159
161
|
& :hover {
|
160
162
|
cursor: pointer;
|
161
163
|
}
|
@@ -236,20 +238,12 @@
|
|
236
238
|
},
|
237
239
|
data() {
|
238
240
|
return {
|
239
|
-
selectedValue: null,
|
240
241
|
primaryColor: 'white',
|
241
242
|
secondaryColor: 'black',
|
242
243
|
inactiveColor: 'grey6',
|
243
244
|
}
|
244
245
|
},
|
245
|
-
watch: {
|
246
|
-
value(val) {
|
247
|
-
this.selectedValue = val
|
248
|
-
},
|
249
|
-
},
|
250
246
|
created() {
|
251
|
-
this.selectedValue = this.value
|
252
|
-
|
253
247
|
if (this.colorMode == 'dark') {
|
254
248
|
this.primaryColor = theme.colors.black
|
255
249
|
this.secondaryColor = theme.colors.white
|
@@ -265,8 +259,7 @@
|
|
265
259
|
if (this.disabled) {
|
266
260
|
return
|
267
261
|
}
|
268
|
-
this
|
269
|
-
this.$emit('on-switch-change', this.selectedValue)
|
262
|
+
this.$emit('on-switch-change', value)
|
270
263
|
},
|
271
264
|
},
|
272
265
|
}
|