@datametria/vue-components 2.4.1 → 2.4.2
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/README.md +57 -5
- package/dist/index.es.js +5812 -2837
- package/dist/index.umd.js +670 -10
- package/dist/src/components/DatametriaCheckbox.vue.d.ts +2 -0
- package/dist/src/components/DatametriaCheckboxGroup.vue.d.ts +6 -0
- package/dist/src/components/DatametriaFileUpload.vue.d.ts +5 -0
- package/dist/src/components/DatametriaFloatingBar.vue.d.ts +1 -1
- package/dist/src/components/DatametriaInput.vue.d.ts +2 -22
- package/dist/src/components/DatametriaNavbar.vue.d.ts +1 -1
- package/dist/src/components/DatametriaPasswordInput.vue.d.ts +2 -0
- package/dist/src/components/DatametriaRadio.vue.d.ts +2 -0
- package/dist/src/components/DatametriaRadioGroup.vue.d.ts +6 -0
- package/dist/src/components/DatametriaSelect.vue.d.ts +2 -3
- package/dist/src/components/DatametriaSidebar.vue.d.ts +1 -1
- package/dist/src/components/DatametriaSwitch.vue.d.ts +8 -1
- package/dist/src/components/DatametriaTabs.vue.d.ts +2 -2
- package/dist/src/components/DatametriaTextarea.vue.d.ts +6 -0
- package/dist/src/composables/useAnalytics.d.ts +8 -0
- package/dist/src/types/analytics.d.ts +50 -0
- package/dist/vue-components.css +1 -1
- package/package.json +3 -2
- package/src/components/DatametriaButton.vue +196 -195
- package/src/components/DatametriaCheckbox.vue +289 -197
- package/src/components/DatametriaCheckboxGroup.vue +124 -3
- package/src/components/DatametriaFileUpload.vue +493 -414
- package/src/components/DatametriaInput.vue +342 -316
- package/src/components/DatametriaPasswordInput.vue +433 -446
- package/src/components/DatametriaRadio.vue +240 -151
- package/src/components/DatametriaRadioGroup.vue +124 -3
- package/src/components/DatametriaSelect.vue +409 -313
- package/src/components/DatametriaSwitch.vue +319 -146
- package/src/components/DatametriaTabs.vue +2 -2
- package/src/components/DatametriaTextarea.vue +285 -213
- package/src/composables/useAnalytics.ts +70 -0
- package/src/types/analytics.ts +59 -0
|
@@ -1,316 +1,342 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div class="datametria-input" :class="inputWrapperClasses">
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
ref="inputRef"
|
|
22
|
-
v-model="inputValue"
|
|
23
|
-
:type="type"
|
|
24
|
-
:placeholder="placeholder"
|
|
25
|
-
:disabled="disabled"
|
|
26
|
-
:readonly="readonly"
|
|
27
|
-
:maxlength="maxlength"
|
|
28
|
-
:
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
<div v-if="
|
|
56
|
-
|
|
57
|
-
</div>
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
required?: boolean
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
const
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
'
|
|
119
|
-
}
|
|
120
|
-
|
|
121
|
-
const
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
}
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
}
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
.
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
margin-
|
|
192
|
-
font-size:
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
border-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
}
|
|
221
|
-
|
|
222
|
-
.datametria-input--
|
|
223
|
-
border-color: var(--
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
}
|
|
243
|
-
|
|
244
|
-
.datametria-input__field:disabled {
|
|
245
|
-
cursor: not-allowed;
|
|
246
|
-
}
|
|
247
|
-
|
|
248
|
-
.datametria-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
border
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
border-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
1
|
+
<template>
|
|
2
|
+
<div class="datametria-input" :class="inputWrapperClasses">
|
|
3
|
+
<label v-if="label" :for="inputId" class="datametria-input__label">
|
|
4
|
+
{{ label }}
|
|
5
|
+
<span v-if="required" class="datametria-input__required">*</span>
|
|
6
|
+
</label>
|
|
7
|
+
|
|
8
|
+
<div v-if="$slots.prepend" class="datametria-input__prepend">
|
|
9
|
+
<slot name="prepend" />
|
|
10
|
+
</div>
|
|
11
|
+
|
|
12
|
+
<div class="datametria-input__inner">
|
|
13
|
+
<span v-if="$slots.prefix || prefixIcon" class="datametria-input__prefix">
|
|
14
|
+
<slot name="prefix">
|
|
15
|
+
<span v-if="prefixIcon">{{ prefixIcon }}</span>
|
|
16
|
+
</slot>
|
|
17
|
+
</span>
|
|
18
|
+
|
|
19
|
+
<input
|
|
20
|
+
:id="inputId"
|
|
21
|
+
ref="inputRef"
|
|
22
|
+
v-model="inputValue"
|
|
23
|
+
:type="type"
|
|
24
|
+
:placeholder="placeholder"
|
|
25
|
+
:disabled="disabled"
|
|
26
|
+
:readonly="readonly"
|
|
27
|
+
:maxlength="maxlength"
|
|
28
|
+
:aria-label="label || placeholder"
|
|
29
|
+
:aria-required="required"
|
|
30
|
+
:aria-invalid="!!errorMessage"
|
|
31
|
+
:aria-describedby="errorMessage ? `${inputId}-error` : undefined"
|
|
32
|
+
:class="inputClasses"
|
|
33
|
+
@input="handleInput"
|
|
34
|
+
@change="handleChange"
|
|
35
|
+
@focus="handleFocus"
|
|
36
|
+
@blur="handleBlur"
|
|
37
|
+
/>
|
|
38
|
+
|
|
39
|
+
<span v-if="showClear || $slots.suffix || suffixIcon" class="datametria-input__suffix">
|
|
40
|
+
<button
|
|
41
|
+
v-if="showClear"
|
|
42
|
+
class="datametria-input__clear"
|
|
43
|
+
type="button"
|
|
44
|
+
aria-label="Limpar"
|
|
45
|
+
@click="handleClear"
|
|
46
|
+
>
|
|
47
|
+
×
|
|
48
|
+
</button>
|
|
49
|
+
<slot name="suffix">
|
|
50
|
+
<span v-if="suffixIcon">{{ suffixIcon }}</span>
|
|
51
|
+
</slot>
|
|
52
|
+
</span>
|
|
53
|
+
</div>
|
|
54
|
+
|
|
55
|
+
<div v-if="$slots.append" class="datametria-input__append">
|
|
56
|
+
<slot name="append" />
|
|
57
|
+
</div>
|
|
58
|
+
|
|
59
|
+
<div
|
|
60
|
+
v-if="errorMessage"
|
|
61
|
+
:id="`${inputId}-error`"
|
|
62
|
+
role="alert"
|
|
63
|
+
aria-live="polite"
|
|
64
|
+
class="datametria-input__error"
|
|
65
|
+
>
|
|
66
|
+
{{ errorMessage }}
|
|
67
|
+
</div>
|
|
68
|
+
</div>
|
|
69
|
+
</template>
|
|
70
|
+
|
|
71
|
+
<script setup lang="ts">
|
|
72
|
+
import { ref, computed } from 'vue'
|
|
73
|
+
import { useAnalytics } from '@/composables/useAnalytics'
|
|
74
|
+
|
|
75
|
+
interface Props {
|
|
76
|
+
modelValue?: string | number
|
|
77
|
+
label?: string
|
|
78
|
+
required?: boolean
|
|
79
|
+
errorMessage?: string
|
|
80
|
+
type?: 'text' | 'password' | 'email' | 'number' | 'tel' | 'url'
|
|
81
|
+
placeholder?: string
|
|
82
|
+
disabled?: boolean
|
|
83
|
+
readonly?: boolean
|
|
84
|
+
clearable?: boolean
|
|
85
|
+
maxlength?: number
|
|
86
|
+
prefixIcon?: string
|
|
87
|
+
suffixIcon?: string
|
|
88
|
+
size?: 'xs' | 'sm' | 'md' | 'lg' | 'xl'
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
const props = withDefaults(defineProps<Props>(), {
|
|
92
|
+
modelValue: '',
|
|
93
|
+
type: 'text',
|
|
94
|
+
placeholder: '',
|
|
95
|
+
disabled: false,
|
|
96
|
+
readonly: false,
|
|
97
|
+
clearable: false,
|
|
98
|
+
required: false,
|
|
99
|
+
size: 'md'
|
|
100
|
+
})
|
|
101
|
+
|
|
102
|
+
const emit = defineEmits<{
|
|
103
|
+
'update:modelValue': [value: string | number]
|
|
104
|
+
'input': [value: string | number]
|
|
105
|
+
'change': [value: string | number]
|
|
106
|
+
'focus': [event: FocusEvent]
|
|
107
|
+
'blur': [event: FocusEvent]
|
|
108
|
+
'clear': []
|
|
109
|
+
}>()
|
|
110
|
+
|
|
111
|
+
const { trackEvent } = useAnalytics()
|
|
112
|
+
const inputRef = ref<HTMLInputElement>()
|
|
113
|
+
const isFocused = ref(false)
|
|
114
|
+
const inputId = `datametria-input-${Math.random().toString(36).substr(2, 9)}`
|
|
115
|
+
|
|
116
|
+
const inputValue = computed({
|
|
117
|
+
get: () => props.modelValue,
|
|
118
|
+
set: (value) => emit('update:modelValue', value)
|
|
119
|
+
})
|
|
120
|
+
|
|
121
|
+
const showClear = computed(() => {
|
|
122
|
+
return props.clearable && !props.disabled && !props.readonly && inputValue.value
|
|
123
|
+
})
|
|
124
|
+
|
|
125
|
+
const inputWrapperClasses = computed(() => ({
|
|
126
|
+
'datametria-input--disabled': props.disabled,
|
|
127
|
+
'datametria-input--focused': isFocused.value,
|
|
128
|
+
'datametria-input--error': !!props.errorMessage,
|
|
129
|
+
[`datametria-input--${props.size}`]: true
|
|
130
|
+
}))
|
|
131
|
+
|
|
132
|
+
const inputClasses = computed(() => ({
|
|
133
|
+
'datametria-input__field': true
|
|
134
|
+
}))
|
|
135
|
+
|
|
136
|
+
const handleInput = (event: Event) => {
|
|
137
|
+
const target = event.target as HTMLInputElement
|
|
138
|
+
emit('input', target.value)
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
const handleChange = (event: Event) => {
|
|
142
|
+
const target = event.target as HTMLInputElement
|
|
143
|
+
trackEvent('input_change', {
|
|
144
|
+
component: 'DatametriaInput',
|
|
145
|
+
type: props.type,
|
|
146
|
+
hasValue: !!target.value
|
|
147
|
+
})
|
|
148
|
+
emit('change', target.value)
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
const handleFocus = (event: FocusEvent) => {
|
|
152
|
+
isFocused.value = true
|
|
153
|
+
trackEvent('input_focus', {
|
|
154
|
+
component: 'DatametriaInput',
|
|
155
|
+
type: props.type,
|
|
156
|
+
size: props.size
|
|
157
|
+
})
|
|
158
|
+
emit('focus', event)
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
const handleBlur = (event: FocusEvent) => {
|
|
162
|
+
isFocused.value = false
|
|
163
|
+
emit('blur', event)
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
const handleClear = () => {
|
|
167
|
+
trackEvent('input_clear', {
|
|
168
|
+
component: 'DatametriaInput',
|
|
169
|
+
type: props.type
|
|
170
|
+
})
|
|
171
|
+
emit('update:modelValue', '')
|
|
172
|
+
emit('clear')
|
|
173
|
+
inputRef.value?.focus()
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
defineExpose({
|
|
177
|
+
focus: () => inputRef.value?.focus(),
|
|
178
|
+
blur: () => inputRef.value?.blur()
|
|
179
|
+
})
|
|
180
|
+
</script>
|
|
181
|
+
|
|
182
|
+
<style scoped>
|
|
183
|
+
.datametria-input {
|
|
184
|
+
display: inline-flex;
|
|
185
|
+
flex-direction: column;
|
|
186
|
+
width: 100%;
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
.datametria-input__label {
|
|
190
|
+
display: block;
|
|
191
|
+
margin-bottom: 4px;
|
|
192
|
+
font-size: 14px;
|
|
193
|
+
font-weight: 500;
|
|
194
|
+
color: var(--color-text-primary, #1f2937);
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
.datametria-input__required {
|
|
198
|
+
color: var(--color-error, #ef4444);
|
|
199
|
+
margin-left: 2px;
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
.datametria-input__inner {
|
|
203
|
+
position: relative;
|
|
204
|
+
display: inline-flex;
|
|
205
|
+
align-items: center;
|
|
206
|
+
width: 100%;
|
|
207
|
+
background: var(--color-background, #ffffff);
|
|
208
|
+
border: 1px solid var(--color-border, #d1d5db);
|
|
209
|
+
border-radius: 6px;
|
|
210
|
+
transition: all 0.2s;
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
.datametria-input__inner:hover:not(.datametria-input--disabled .datametria-input__inner) {
|
|
214
|
+
border-color: var(--color-primary, #3b82f6);
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
.datametria-input--focused .datametria-input__inner {
|
|
218
|
+
border-color: var(--color-primary, #3b82f6);
|
|
219
|
+
box-shadow: 0 0 0 3px var(--color-primary-alpha, rgba(59, 130, 246, 0.1));
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
.datametria-input--error .datametria-input__inner {
|
|
223
|
+
border-color: var(--color-error, #ef4444);
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
.datametria-input--disabled .datametria-input__inner {
|
|
227
|
+
background: var(--color-background-muted, #f3f4f6);
|
|
228
|
+
cursor: not-allowed;
|
|
229
|
+
opacity: 0.6;
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
.datametria-input__field {
|
|
233
|
+
flex: 1;
|
|
234
|
+
width: 100%;
|
|
235
|
+
border: none;
|
|
236
|
+
outline: none;
|
|
237
|
+
background: transparent;
|
|
238
|
+
color: var(--color-text-primary, #1f2937);
|
|
239
|
+
font-size: 14px;
|
|
240
|
+
touch-action: manipulation;
|
|
241
|
+
-webkit-tap-highlight-color: transparent;
|
|
242
|
+
}
|
|
243
|
+
|
|
244
|
+
.datametria-input__field:disabled {
|
|
245
|
+
cursor: not-allowed;
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
.datametria-input__field::placeholder {
|
|
249
|
+
color: var(--color-text-secondary, #6b7280);
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
.datametria-input__prefix,
|
|
253
|
+
.datametria-input__suffix {
|
|
254
|
+
display: inline-flex;
|
|
255
|
+
align-items: center;
|
|
256
|
+
padding: 0 8px;
|
|
257
|
+
color: var(--color-text-secondary, #6b7280);
|
|
258
|
+
}
|
|
259
|
+
|
|
260
|
+
.datametria-input__clear {
|
|
261
|
+
background: none;
|
|
262
|
+
border: none;
|
|
263
|
+
font-size: 18px;
|
|
264
|
+
line-height: 1;
|
|
265
|
+
color: var(--color-text-secondary, #6b7280);
|
|
266
|
+
cursor: pointer;
|
|
267
|
+
padding: 0 4px;
|
|
268
|
+
transition: color 0.2s;
|
|
269
|
+
min-width: 44px;
|
|
270
|
+
min-height: 44px;
|
|
271
|
+
}
|
|
272
|
+
|
|
273
|
+
.datametria-input__clear:hover {
|
|
274
|
+
color: var(--color-text-primary, #1f2937);
|
|
275
|
+
}
|
|
276
|
+
|
|
277
|
+
.datametria-input__prepend,
|
|
278
|
+
.datametria-input__append {
|
|
279
|
+
display: inline-flex;
|
|
280
|
+
align-items: center;
|
|
281
|
+
padding: 0 12px;
|
|
282
|
+
background: var(--color-background-alt, #f9fafb);
|
|
283
|
+
border: 1px solid var(--color-border, #d1d5db);
|
|
284
|
+
white-space: nowrap;
|
|
285
|
+
}
|
|
286
|
+
|
|
287
|
+
.datametria-input__prepend {
|
|
288
|
+
border-right: none;
|
|
289
|
+
border-radius: 6px 0 0 6px;
|
|
290
|
+
}
|
|
291
|
+
|
|
292
|
+
.datametria-input__append {
|
|
293
|
+
border-left: none;
|
|
294
|
+
border-radius: 0 6px 6px 0;
|
|
295
|
+
}
|
|
296
|
+
|
|
297
|
+
.datametria-input__error {
|
|
298
|
+
margin-top: 4px;
|
|
299
|
+
font-size: 12px;
|
|
300
|
+
color: var(--color-error, #ef4444);
|
|
301
|
+
}
|
|
302
|
+
|
|
303
|
+
/* Tamanhos */
|
|
304
|
+
.datametria-input--xs .datametria-input__field {
|
|
305
|
+
padding: 2px 6px;
|
|
306
|
+
font-size: 11px;
|
|
307
|
+
min-height: 1.75rem;
|
|
308
|
+
}
|
|
309
|
+
|
|
310
|
+
.datametria-input--sm .datametria-input__field {
|
|
311
|
+
padding: 4px 8px;
|
|
312
|
+
font-size: 12px;
|
|
313
|
+
min-height: 2rem;
|
|
314
|
+
}
|
|
315
|
+
|
|
316
|
+
.datametria-input--md .datametria-input__field {
|
|
317
|
+
padding: 8px 12px;
|
|
318
|
+
font-size: 14px;
|
|
319
|
+
min-height: 2.5rem;
|
|
320
|
+
}
|
|
321
|
+
|
|
322
|
+
.datametria-input--lg .datametria-input__field {
|
|
323
|
+
padding: 12px 16px;
|
|
324
|
+
font-size: 16px;
|
|
325
|
+
min-height: 3rem;
|
|
326
|
+
}
|
|
327
|
+
|
|
328
|
+
.datametria-input--xl .datametria-input__field {
|
|
329
|
+
padding: 16px 20px;
|
|
330
|
+
font-size: 18px;
|
|
331
|
+
min-height: 3.5rem;
|
|
332
|
+
}
|
|
333
|
+
|
|
334
|
+
/* Responsividade mobile */
|
|
335
|
+
@media (max-width: 640px) {
|
|
336
|
+
.datametria-input--xs .datametria-input__field { min-height: 2rem; }
|
|
337
|
+
.datametria-input--sm .datametria-input__field { min-height: 2.25rem; }
|
|
338
|
+
.datametria-input--md .datametria-input__field { min-height: 2.75rem; }
|
|
339
|
+
.datametria-input--lg .datametria-input__field { min-height: 3.25rem; }
|
|
340
|
+
.datametria-input--xl .datametria-input__field { min-height: 3.75rem; }
|
|
341
|
+
}
|
|
342
|
+
</style>
|