@bagelink/vue 0.0.268 → 0.0.270
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/components/Drop.vue.d.ts +34 -0
- package/dist/components/Drop.vue.d.ts.map +1 -0
- package/dist/components/FileUploader.vue.d.ts +60 -0
- package/dist/components/FileUploader.vue.d.ts.map +1 -0
- package/dist/components/ModalForm.vue.d.ts.map +1 -1
- package/dist/components/form/BglField.vue.d.ts.map +1 -1
- package/dist/components/form/BglForm.vue.d.ts.map +1 -1
- package/dist/components/form/ItemRef.vue.d.ts +1 -0
- package/dist/components/form/ItemRef.vue.d.ts.map +1 -1
- package/dist/components/form/inputs/DateInput.vue.d.ts.map +1 -1
- package/dist/components/form/inputs/SelectField.vue.d.ts +1 -4
- package/dist/components/form/inputs/SelectField.vue.d.ts.map +1 -1
- package/dist/components/form/inputs/SelectInput.vue.d.ts.map +1 -1
- package/dist/components/form/inputs/TextInput.vue.d.ts.map +1 -1
- package/dist/components/form/inputs/index.d.ts +0 -1
- package/dist/components/form/inputs/index.d.ts.map +1 -1
- package/dist/index.cjs +8672 -9486
- package/dist/index.mjs +8671 -9485
- package/dist/plugins/modal.d.ts +1 -1
- package/dist/plugins/modal.d.ts.map +1 -1
- package/dist/style.css +18 -39
- package/dist/types/BagelForm.d.ts +1 -1
- package/dist/types/BagelForm.d.ts.map +1 -1
- package/package.json +2 -2
- package/src/components/ModalForm.vue +7 -35
- package/src/components/form/BglField.vue +22 -7
- package/src/components/form/BglFieldSet.vue +13 -0
- package/src/components/form/BglForm.vue +5 -22
- package/src/components/form/inputs/DateInput.vue +6 -2
- package/src/components/form/inputs/SelectInput.vue +2 -9
- package/src/components/form/inputs/TextInput.vue +12 -8
- package/src/components/form/inputs/index.ts +0 -1
- package/src/plugins/modal.ts +1 -1
- package/src/types/BagelForm.ts +20 -20
- package/src/components/form/inputs/TextArea.vue +0 -81
|
@@ -1,81 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div
|
|
3
|
-
class="bagel-input"
|
|
4
|
-
:title="description"
|
|
5
|
-
:class="{ small: small }"
|
|
6
|
-
>
|
|
7
|
-
<label v-if="label">
|
|
8
|
-
<LangText :input="label" />
|
|
9
|
-
</label>
|
|
10
|
-
<span
|
|
11
|
-
class="character-limit"
|
|
12
|
-
v-if="showCharacterLimit"
|
|
13
|
-
>
|
|
14
|
-
{{ modelValue?.length }}
|
|
15
|
-
{{ nativeInputAttrs?.maxlength ? `/${nativeInputAttrs.maxlength}` : '' }}
|
|
16
|
-
</span>
|
|
17
|
-
<textarea
|
|
18
|
-
:value="modelValue"
|
|
19
|
-
@input="handleInput"
|
|
20
|
-
:class="{ 'no-edit': !editMode }"
|
|
21
|
-
v-bind="nativeInputAttrs"
|
|
22
|
-
:required
|
|
23
|
-
/>
|
|
24
|
-
</div>
|
|
25
|
-
</template>
|
|
26
|
-
|
|
27
|
-
<script setup lang="ts">
|
|
28
|
-
import { LangText } from '@bagelink/vue';
|
|
29
|
-
|
|
30
|
-
const emits = defineEmits(['update:modelValue']);
|
|
31
|
-
|
|
32
|
-
withDefaults(
|
|
33
|
-
defineProps<{
|
|
34
|
-
description?: string;
|
|
35
|
-
label?: string;
|
|
36
|
-
modelValue: any;
|
|
37
|
-
placeholder?: string;
|
|
38
|
-
editMode?: boolean;
|
|
39
|
-
small?: boolean;
|
|
40
|
-
nativeInputAttrs?: Record<string, any>;
|
|
41
|
-
showCharacterLimit?: boolean;
|
|
42
|
-
required?: boolean;
|
|
43
|
-
}>(),
|
|
44
|
-
{
|
|
45
|
-
description: '',
|
|
46
|
-
editMode: true,
|
|
47
|
-
placeholder: '',
|
|
48
|
-
label: '',
|
|
49
|
-
},
|
|
50
|
-
);
|
|
51
|
-
const handleInput = (e: Event) => {
|
|
52
|
-
const el = e.target as HTMLInputElement;
|
|
53
|
-
emits('update:modelValue', el.value);
|
|
54
|
-
};
|
|
55
|
-
</script>
|
|
56
|
-
|
|
57
|
-
<style scoped>
|
|
58
|
-
.bagel-input {
|
|
59
|
-
height: 100%;
|
|
60
|
-
margin: 0;
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
.bagel-input label {
|
|
64
|
-
margin-bottom: 0;
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
.bagel-input textarea {
|
|
68
|
-
height: 100%;
|
|
69
|
-
resize: none;
|
|
70
|
-
background: var(--input-bg);
|
|
71
|
-
margin-bottom: 0.5rem;
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
.character-limit {
|
|
75
|
-
font-size: 0.6rem;
|
|
76
|
-
color: var(--input-color);
|
|
77
|
-
position: absolute;
|
|
78
|
-
top: 0.25rem;
|
|
79
|
-
inset-inline-end: 0;
|
|
80
|
-
}
|
|
81
|
-
</style>
|