@bagelink/vue 0.0.32 → 0.0.35

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.
Files changed (60) hide show
  1. package/package.json +4 -2
  2. package/src/components/Comments.vue +30 -11
  3. package/src/components/ContactArray.vue +21 -6
  4. package/src/components/ContactSubmissions.vue +6 -3
  5. package/src/components/DataPreview.vue +22 -9
  6. package/src/components/FileUploader.vue +17 -8
  7. package/src/components/FormKitTable.vue +120 -71
  8. package/src/components/FormSchema.vue +20 -6
  9. package/src/components/LangText.vue +3 -1
  10. package/src/components/ListItem.vue +5 -1
  11. package/src/components/ListView.vue +25 -10
  12. package/src/components/MaterialIcon.vue +4 -1
  13. package/src/components/Modal.vue +17 -5
  14. package/src/components/ModalForm.vue +23 -8
  15. package/src/components/NavBar.vue +15 -5
  16. package/src/components/PersonPreview.vue +5 -7
  17. package/src/components/PersonPreviewFormkit.vue +5 -5
  18. package/src/components/RTXEditor.vue +4 -0
  19. package/src/components/RouterWrapper.vue +10 -2
  20. package/src/components/TabbedLayout.vue +8 -5
  21. package/src/components/TableSchema.vue +49 -14
  22. package/src/components/charts/BarChart.vue +35 -9
  23. package/src/components/dashboard/Lineart.vue +47 -15
  24. package/src/components/form/ItemRef.vue +10 -3
  25. package/src/components/form/MaterialIcon.vue +3 -3
  26. package/src/components/form/PlainInputField.vue +2 -3
  27. package/src/components/form/inputs/CheckInput.vue +3 -3
  28. package/src/components/form/inputs/Checkbox.vue +10 -2
  29. package/src/components/form/inputs/ColorPicker.vue +13 -3
  30. package/src/components/form/inputs/CurrencyInput.vue +7 -3
  31. package/src/components/form/inputs/DateInput.vue +8 -2
  32. package/src/components/form/inputs/DatetimeInput.vue +8 -4
  33. package/src/components/form/inputs/DurationInput.vue +8 -4
  34. package/src/components/form/inputs/DynamicLinkField.vue +9 -7
  35. package/src/components/form/inputs/EmailInput.vue +7 -3
  36. package/src/components/form/inputs/FloatInput.vue +7 -3
  37. package/src/components/form/inputs/IntInput.vue +8 -4
  38. package/src/components/form/inputs/JSONInput.vue +7 -3
  39. package/src/components/form/inputs/LinkField.vue +26 -19
  40. package/src/components/form/inputs/Password.vue +2 -0
  41. package/src/components/form/inputs/PasswordInput.vue +13 -10
  42. package/src/components/form/inputs/PlainText.vue +14 -3
  43. package/src/components/form/inputs/ReadOnlyInput.vue +5 -1
  44. package/src/components/form/inputs/RichTextEditor.vue +9 -7
  45. package/src/components/form/inputs/SelectField.vue +10 -5
  46. package/src/components/form/inputs/TableField.vue +1 -3
  47. package/src/components/form/inputs/TextArea.vue +11 -2
  48. package/src/components/form/inputs/TextInput.vue +13 -3
  49. package/src/components/form/inputs/index.ts +0 -1
  50. package/src/components/formkit/AddressArray.vue +1 -1
  51. package/src/components/formkit/BankDetailsArray.vue +10 -10
  52. package/src/components/formkit/ContactArrayFormKit.vue +58 -17
  53. package/src/components/formkit/FileUploader.vue +7 -7
  54. package/src/components/formkit/MiscFields.vue +6 -1
  55. package/src/components/formkit/Toggle.vue +8 -4
  56. package/src/components/whatsapp/form/MsgTemplate.vue +15 -8
  57. package/src/components/whatsapp/form/TextVariableExamples.vue +8 -3
  58. package/src/utils/index.ts +9 -4
  59. package/src/utils/modal.ts +7 -1
  60. package/src/utils/strings.ts +8 -1
@@ -46,10 +46,9 @@
46
46
 
47
47
  <script lang="ts" setup>
48
48
  import { onMounted, ref } from 'vue';
49
- // @ts-ignore TODO: remove this
50
- import { formatString } from '../../composables';
51
- // @ts-ignore TODO: remove this
49
+
52
50
  import LangText from '../translation/LangText.vue';
51
+ import { formatString } from '@/utils/strings';
53
52
 
54
53
  const props = defineProps<{
55
54
  type: 'text' | 'number' | 'password' | 'email' | 'checkbox' | 'textarea';
@@ -83,7 +83,7 @@ onMounted(() => (inputVal.value = !!props.modelValue));
83
83
  display: none;
84
84
  }
85
85
 
86
- .radio-wrap input:checked:checked + label {
86
+ .radio-wrap input:checked:checked+label {
87
87
  background: var(--bgl-blue);
88
88
  color: var(--bgl-white);
89
89
  }
@@ -133,11 +133,11 @@ onMounted(() => (inputVal.value = !!props.modelValue));
133
133
  transition: 0.4s;
134
134
  }
135
135
 
136
- input:checked + .slider {
136
+ input:checked+.slider {
137
137
  background: var(--bgl-blue);
138
138
  }
139
139
 
140
- input:checked + .slider:before {
140
+ input:checked+.slider:before {
141
141
  transform: translateX(calc(var(--input-height) / 2));
142
142
  }
143
143
  </style>
@@ -1,6 +1,9 @@
1
1
  <template>
2
2
  <label class="primary-checkbox">
3
- <input type="checkbox" v-model="val" >
3
+ <input
4
+ type="checkbox"
5
+ v-model="val"
6
+ >
4
7
  <span>
5
8
  <MaterialIcon icon="check" />
6
9
  </span>
@@ -38,9 +41,11 @@ watch(
38
41
  .primary-checkbox input {
39
42
  display: none;
40
43
  }
44
+
41
45
  .primary-checkbox {
42
46
  margin-top: 8px;
43
47
  }
48
+
44
49
  .primary-checkbox span {
45
50
  display: flex;
46
51
  padding-top: 1px;
@@ -56,13 +61,16 @@ watch(
56
61
  transition: var(--bgl-transition);
57
62
  user-select: none;
58
63
  }
64
+
59
65
  .primary-checkbox span:hover {
60
66
  filter: brightness(90%);
61
67
  }
68
+
62
69
  .primary-checkbox span:active {
63
70
  filter: brightness(80%);
64
71
  }
65
- .primary-checkbox input:checked + span {
72
+
73
+ .primary-checkbox input:checked+span {
66
74
  background: var(--bgl-blue);
67
75
  border: none;
68
76
  }
@@ -1,10 +1,20 @@
1
1
  <template>
2
- <div class="bagel-input" :class="{ small }" :title="field.description" v-if="field.id">
2
+ <div
3
+ class="bagel-input"
4
+ :class="{ small }"
5
+ :title="field.description"
6
+ v-if="field.id"
7
+ >
3
8
  <label :for="field.id">
4
9
  {{ field.label }}
5
10
  <input
6
- :id="field.id" v-model="inputVal" type="color" :placeholder="field.placeholder || field.label"
7
- :class="{ 'no-edit': !editMode }" :required="required" v-bind="nativeInputAttrs"
11
+ :id="field.id"
12
+ v-model="inputVal"
13
+ type="color"
14
+ :placeholder="field.placeholder || field.label"
15
+ :class="{ 'no-edit': !editMode }"
16
+ :required="required"
17
+ v-bind="nativeInputAttrs"
8
18
  >
9
19
  </label>
10
20
  </div>
@@ -1,5 +1,9 @@
1
1
  <template>
2
- <div class="bagel-input" :title="field.description" :class="{ small: small }">
2
+ <div
3
+ class="bagel-input"
4
+ :title="field.description"
5
+ :class="{ small: small }"
6
+ >
3
7
  <label v-if="field.label">
4
8
  {{ field.label }}
5
9
  </label>
@@ -13,8 +17,8 @@
13
17
  >
14
18
  <p class="currency">
15
19
  {{
16
- currencies.find((c) => c.symbol === field.currency)?.character ||
17
- field.currency
20
+ currencies
21
+ .find((c) => c.symbol === field.currency)?.character || field.currency
18
22
  }}
19
23
  </p>
20
24
  </div>
@@ -1,5 +1,9 @@
1
1
  <template>
2
- <div class="bagel-input" :title="field.description" :class="{ small: small }">
2
+ <div
3
+ class="bagel-input"
4
+ :title="field.description"
5
+ :class="{ small: small }"
6
+ >
3
7
  <label v-if="field.label">
4
8
  {{ field.label }}
5
9
  </label>
@@ -43,7 +47,9 @@ const handleInput = () => {
43
47
  </script>
44
48
 
45
49
  <style scoped>
50
+ /*
46
51
  .date-picker {
47
- /* padding-inline-start: 10px; */
52
+ padding-inline-start: 10px;
48
53
  }
54
+ */
49
55
  </style>
@@ -1,5 +1,9 @@
1
1
  <template>
2
- <div class="bagel-input" :title="description" :class="{ small: small }">
2
+ <div
3
+ class="bagel-input"
4
+ :title="description"
5
+ :class="{ small: small }"
6
+ >
3
7
  <label v-if="label">
4
8
  <LangText :input="label" />
5
9
  </label>
@@ -15,11 +19,11 @@
15
19
 
16
20
  <script setup lang="ts">
17
21
  import { onMounted } from 'vue';
18
- // @ts-ignore TODO: remove this
22
+ // @ts-ignore TODO: remove this Nati
19
23
  import { bagelApp } from '../../../index';
20
24
 
21
25
  const emits = defineEmits(['update:modelValue']);
22
- // @ts-ignore TODO: remove this
26
+ // @ts-ignore TODO: remove this Nati
23
27
  const props = withDefaults(
24
28
  defineProps<{
25
29
  description?: string;
@@ -40,7 +44,7 @@ const handleInput = (e: Event) => {
40
44
  const el = e.target as HTMLInputElement;
41
45
  emits('update:modelValue', el.value);
42
46
  };
43
- onMounted(() => {});
47
+ onMounted(() => { });
44
48
  </script>
45
49
 
46
50
  <style scoped></style>
@@ -1,5 +1,9 @@
1
1
  <template>
2
- <div class="bagel-input" :title="description" :class="{ small: small }">
2
+ <div
3
+ class="bagel-input"
4
+ :title="description"
5
+ :class="{ small: small }"
6
+ >
3
7
  <label v-if="label">
4
8
  <LangText :input="label" />
5
9
  </label>
@@ -15,13 +19,13 @@
15
19
  </template>
16
20
 
17
21
  <script setup lang="ts">
18
- // @ts-ignore TODO: remove this
22
+ // @ts-ignore TODO: remove this Nati
19
23
  import { bagelApp } from '../../../index';
20
- // @ts-ignore TODO: remove this
24
+ // @ts-ignore TODO: remove this Nati
21
25
  import { formatDuration } from '../../../composables';
22
26
 
23
27
  const emits = defineEmits(['update:modelValue']);
24
- // @ts-ignore TODO: remove this
28
+ // @ts-ignore TODO: remove this Nati
25
29
  const props = withDefaults(
26
30
  defineProps<{
27
31
  description?: string;
@@ -1,5 +1,8 @@
1
1
  <template>
2
- <div class="bagel-input" :class="{ small: small }">
2
+ <div
3
+ class="bagel-input"
4
+ :class="{ small: small }"
5
+ >
3
6
  <label v-if="label">
4
7
  <LangText :input="label" />
5
8
  </label>
@@ -27,9 +30,8 @@
27
30
  @click.stop="handleSelect(item)"
28
31
  >
29
32
  {{
30
- useId || entity === 'Entity'
31
- ? item.value
32
- : item.label || item.description || item.value
33
+ useId || entity === 'Entity' ? item.value
34
+ : item.label || item.description || item.value
33
35
  }}
34
36
  </div>
35
37
  </div>
@@ -39,9 +41,9 @@
39
41
 
40
42
  <script lang="ts" setup>
41
43
  import { onMounted, ref } from 'vue';
42
- // @ts-ignore TODO: remove this
44
+ // @ts-ignore TODO: remove this Nati
43
45
  import { formatString } from '../../../composables';
44
- // @ts-ignore TODO: remove this
46
+ // @ts-ignore TODO: remove this Nati
45
47
  import { bagelApp } from '../../../index';
46
48
 
47
49
  const props = withDefaults(
@@ -96,7 +98,7 @@ interface ListItem {
96
98
  description?: string;
97
99
  }
98
100
 
99
- // @ts-ignore TODO: remove this
101
+ // @ts-ignore TODO: remove this Nati
100
102
  const initialized = ref(false);
101
103
 
102
104
  async function initList(e: Event) {
@@ -1,5 +1,9 @@
1
1
  <template>
2
- <div class="bagel-input" :title="description" :class="{ small: small }">
2
+ <div
3
+ class="bagel-input"
4
+ :title="description"
5
+ :class="{ small: small }"
6
+ >
3
7
  <label v-if="label">
4
8
  <LangText :input="label" />
5
9
  </label>
@@ -15,11 +19,11 @@
15
19
  </template>
16
20
 
17
21
  <script setup lang="ts">
18
- // @ts-ignore TODO: remove this
22
+ // @ts-ignore TODO: remove this Nati
19
23
  import { bagelApp } from '../../../index';
20
24
 
21
25
  const emits = defineEmits(['update:modelValue']);
22
- // @ts-ignore TODO: remove this
26
+ // @ts-ignore TODO: remove this Nati
23
27
  const props = withDefaults(
24
28
  defineProps<{
25
29
  description?: string;
@@ -1,5 +1,9 @@
1
1
  <template>
2
- <div class="bagel-input" :title="description" :class="{ small: small }">
2
+ <div
3
+ class="bagel-input"
4
+ :title="description"
5
+ :class="{ small: small }"
6
+ >
3
7
  <label v-if="label">
4
8
  <LangText :input="label" />
5
9
  </label>
@@ -14,11 +18,11 @@
14
18
  </template>
15
19
 
16
20
  <script setup lang="ts">
17
- // @ts-ignore TODO: remove this
21
+ // @ts-ignore TODO: remove this Nati
18
22
  import { bagelApp } from '../../../index';
19
23
 
20
24
  const emits = defineEmits(['update:modelValue']);
21
- // @ts-ignore TODO: remove this
25
+ // @ts-ignore TODO: remove this Nati
22
26
  const props = withDefaults(
23
27
  defineProps<{
24
28
  description?: string;
@@ -1,5 +1,9 @@
1
1
  <template>
2
- <div class="bagel-input" :title="description" :class="{ small: small }">
2
+ <div
3
+ class="bagel-input"
4
+ :title="description"
5
+ :class="{ small: small }"
6
+ >
3
7
  <label v-if="label">
4
8
  <LangText :input="label" />
5
9
  </label>
@@ -14,12 +18,12 @@
14
18
  </template>
15
19
 
16
20
  <script setup lang="ts">
17
- // @ts-ignore TODO: remove this
21
+ // @ts-ignore TODO: remove this Nati
18
22
  import { bagelApp } from '../../../index';
19
23
 
20
- // @ts-ignore TODO: remove this
24
+ // @ts-ignore TODO: remove this Nati
21
25
  const emits = defineEmits(['update:modelValue']);
22
- // @ts-ignore TODO: remove this
26
+ // @ts-ignore TODO: remove this Nati
23
27
  const props = withDefaults(
24
28
  defineProps<{
25
29
  description?: string;
@@ -1,5 +1,9 @@
1
1
  <template>
2
- <div class="bagel-input" :title="description" :class="{ small: small }">
2
+ <div
3
+ class="bagel-input"
4
+ :title="description"
5
+ :class="{ small: small }"
6
+ >
3
7
  <label v-if="label">
4
8
  <LangText :input="label" />
5
9
  </label>
@@ -13,11 +17,11 @@
13
17
  </template>
14
18
 
15
19
  <script setup lang="ts">
16
- // @ts-ignore TODO: remove this
20
+ // @ts-ignore TODO: remove this Nati
17
21
  import { bagelApp } from '../../../index';
18
22
 
19
23
  const emits = defineEmits(['update:modelValue']);
20
- // @ts-ignore TODO: remove this
24
+ // @ts-ignore TODO: remove this Nati
21
25
  const props = withDefaults(
22
26
  defineProps<{
23
27
  description?: string;
@@ -1,5 +1,9 @@
1
1
  <template>
2
- <div class="bagel-input" :title="description" :class="{ small: small }">
2
+ <div
3
+ class="bagel-input"
4
+ :title="description"
5
+ :class="{ small: small }"
6
+ >
3
7
  <label v-if="label">
4
8
  <LangText :input="label" />
5
9
  </label>
@@ -32,10 +36,16 @@
32
36
  :key="formatString(option.value, 'pascal')"
33
37
  @click.stop="handleSelect(option)"
34
38
  >
35
- <div class="option-label" v-if="option.label">
39
+ <div
40
+ class="option-label"
41
+ v-if="option.label"
42
+ >
36
43
  {{ option.label }}<span>ID: {{ option.value }}</span>
37
44
  </div>
38
- <div class="option-label" v-else>
45
+ <div
46
+ class="option-label"
47
+ v-else
48
+ >
39
49
  ID: {{ option.value }}
40
50
  </div>
41
51
  <div class="option-description">
@@ -50,10 +60,7 @@
50
60
 
51
61
  <script lang="ts" setup>
52
62
  import { onMounted, ref } from 'vue';
53
- // @ts-ignore TODO: remove this
54
- import { formatString } from '../../../composables';
55
- // @ts-ignore TODO: remove this
56
- import { bagelApp as api } from '../../../index';
63
+ import { formatString } from '@/utils/strings';
57
64
 
58
65
  const props = withDefaults(
59
66
  defineProps<{
@@ -111,8 +118,8 @@ async function getLinkOptions(inputString: string) {
111
118
  }
112
119
 
113
120
  function hideDrop(e: WheelEvent) {
114
- const dropRect = dropdown.value?.getBoundingClientRect?.()
115
- || ({
121
+ const dropRect = dropdown.value?.getBoundingClientRect?.() ||
122
+ ({
116
123
  left: 0,
117
124
  right: 0,
118
125
  } as DOMRect);
@@ -126,10 +133,10 @@ function openList() {
126
133
  showList.value = true;
127
134
  }
128
135
 
129
- // @ts-ignore TODO: remove this
136
+ // @ts-ignore TODO: remove this Nati
130
137
  function setPosition(e?: WheelEvent) {
131
- const elInfo = selectEl.value?.getBoundingClientRect?.()
132
- || ({
138
+ const elInfo = selectEl.value?.getBoundingClientRect?.() ||
139
+ ({
133
140
  top: 0,
134
141
  left: 0,
135
142
  bottom: 0,
@@ -140,8 +147,8 @@ function setPosition(e?: WheelEvent) {
140
147
 
141
148
  left.value = `${elInfo.left}px`;
142
149
  width.value = `${elInfo.width}px`;
143
- const dropRect = dropdown.value?.getBoundingClientRect?.()
144
- || ({
150
+ const dropRect = dropdown.value?.getBoundingClientRect?.() ||
151
+ ({
145
152
  height: 0,
146
153
  } as DOMRect);
147
154
 
@@ -156,7 +163,7 @@ interface ListItem {
156
163
  description?: string;
157
164
  }
158
165
 
159
- // @ts-ignore TODO: remove this
166
+ // @ts-ignore TODO: remove this Nati
160
167
  const initialized = ref(false);
161
168
 
162
169
  async function initList(e: Event) {
@@ -192,7 +199,7 @@ const handleInput = async (e: Event) => {
192
199
  await getLinkOptions(el.value);
193
200
  };
194
201
  onMounted(() => {
195
- bagel = props.bagelApp || api;
202
+ bagel = props.bagelApp;
196
203
  setPosition();
197
204
  window.addEventListener('wheel', hideDrop);
198
205
  selectedItem.value = props.modelValue;
@@ -279,15 +286,15 @@ onMounted(() => {
279
286
  pointer-events: all;
280
287
  }
281
288
 
282
- .custom-select-drop > * {
289
+ .custom-select-drop>* {
283
290
  padding: 0.5rem 0.75rem;
284
291
  }
285
292
 
286
- .custom-select-drop > *:hover {
293
+ .custom-select-drop>*:hover {
287
294
  background: var(--bgl-blue-light);
288
295
  }
289
296
 
290
- .custom-select-drop > *:active {
297
+ .custom-select-drop>*:active {
291
298
  filter: var(--bgl-hover-filter);
292
299
  }
293
300
  </style>
@@ -79,9 +79,11 @@ watch(inputVal, (newVal) => emits('update:modelValue', newVal));
79
79
  align-items: center;
80
80
  justify-content: center;
81
81
  }
82
+
82
83
  .icon-font:hover {
83
84
  background: var(--bgl-white);
84
85
  }
86
+
85
87
  .icon-font:active {
86
88
  background: var(--bgl-white);
87
89
  filter: brightness(90%);
@@ -1,5 +1,9 @@
1
1
  <template>
2
- <div class="bagel-input" :title="description" :class="{ small: small }">
2
+ <div
3
+ class="bagel-input"
4
+ :title="description"
5
+ :class="{ small: small }"
6
+ >
3
7
  <label v-if="label">
4
8
  <LangText :input="label" />
5
9
  </label>
@@ -8,10 +12,13 @@
8
12
  :value="modelValue"
9
13
  :type="inputType"
10
14
  @input="handleInput"
11
- :placeholder="bagelApp.translate(placeholder, true)"
15
+ :placeholder="placeholder"
12
16
  :class="{ 'no-edit': !editMode }"
13
17
  >
14
- <div class="icon-font password-icon" @mousedown="toggleInputType">
18
+ <div
19
+ class="icon-font password-icon"
20
+ @mousedown="toggleInputType"
21
+ >
15
22
  visibility
16
23
  </div>
17
24
  </div>
@@ -19,10 +26,6 @@
19
26
  </template>
20
27
 
21
28
  <script setup lang="ts">
22
- import { ref } from 'vue';
23
- // @ts-ignore TODO: remove this
24
- import { bagelApp } from '../../../index';
25
-
26
29
  const emits = defineEmits(['update:modelValue']);
27
30
  withDefaults(
28
31
  defineProps<{
@@ -41,18 +44,18 @@ withDefaults(
41
44
  },
42
45
  );
43
46
 
44
- const inputType = ref('password');
47
+ let inputType = $ref('password');
45
48
  const handleInput = (e: Event) => {
46
49
  const el = e.target as HTMLInputElement;
47
50
  emits('update:modelValue', el.value);
48
51
  };
49
52
 
50
53
  function toggleInputType() {
51
- inputType.value = 'text';
54
+ inputType = 'text';
52
55
  document.addEventListener(
53
56
  'mouseup',
54
57
  () => {
55
- inputType.value = 'password';
58
+ inputType = 'password';
56
59
  },
57
60
  { once: true },
58
61
  );
@@ -1,10 +1,21 @@
1
1
  <template>
2
- <div class="bagel-input" :class="{ small }" :title="field.description" v-if="field.id">
2
+ <div
3
+ class="bagel-input"
4
+ :class="{ small }"
5
+ :title="field.description"
6
+ v-if="field.id"
7
+ >
3
8
  <label :for="field.id">
4
9
  {{ field.label }}
5
10
  <input
6
- :id="field.id" v-model="inputVal" type="text" :placeholder="field.placeholder || field.label"
7
- :class="{ 'no-edit': !editMode }" :required="required" :pattern="pattern" v-bind="nativeInputAttrs"
11
+ :id="field.id"
12
+ v-model="inputVal"
13
+ type="text"
14
+ :placeholder="field.placeholder || field.label"
15
+ :class="{ 'no-edit': !editMode }"
16
+ :required="required"
17
+ :pattern="pattern"
18
+ v-bind="nativeInputAttrs"
8
19
  >
9
20
  </label>
10
21
  </div>
@@ -1,5 +1,9 @@
1
1
  <template>
2
- <div class="bagel-input" :title="field.description" :class="{ small: small }">
2
+ <div
3
+ class="bagel-input"
4
+ :title="field.description"
5
+ :class="{ small: small }"
6
+ >
3
7
  <label v-if="field.label">
4
8
  {{ field.label }}
5
9
  </label>
@@ -1,24 +1,26 @@
1
1
  <template>
2
- <div class="bagel-input" :title="description" :class="{ small: small }">
2
+ <div
3
+ class="bagel-input"
4
+ :title="description"
5
+ :class="{ small: small }"
6
+ >
3
7
  <label v-if="label">
4
8
  <LangText :input="label" />
5
9
  </label>
6
10
  <textarea
7
11
  :value="modelValue"
8
12
  @input="handleInput"
9
- :placeholder="bagelApp.translate(placeholder, true)"
13
+ :placeholder="placeholder"
10
14
  :class="{ 'no-edit': !editMode }"
11
15
  />
12
16
  </div>
13
17
  </template>
14
18
 
15
19
  <script setup lang="ts">
16
- // @ts-ignore TODO: remove this
17
- import { bagelApp } from '../../../index';
18
-
19
20
  const emits = defineEmits(['update:modelValue']);
20
- // @ts-ignore TODO: remove this
21
- const props = withDefaults(
21
+
22
+ // const props =
23
+ withDefaults(
22
24
  defineProps<{
23
25
  description?: string;
24
26
  label?: string;
@@ -4,7 +4,11 @@
4
4
  :class="{ 'no-edit': !editMode, small: small }"
5
5
  :title="description"
6
6
  >
7
- <label v-if="label" for="label" :class="{ active: showList }">
7
+ <label
8
+ v-if="label"
9
+ for="label"
10
+ :class="{ active: showList }"
11
+ >
8
12
  <LangText :input="label" />
9
13
  </label>
10
14
 
@@ -131,7 +135,7 @@ function hideDrop(e: WheelEvent) {
131
135
  watch(
132
136
  () => props.modelValue,
133
137
  () => {
134
- if (selectedValue.value !== props.modelValue) selectedValue.value = props.modelValue;
138
+ if (selectedValue.value !== props.modelValue) selectedValue.value = props.modelValue;
135
139
  },
136
140
  { immediate: true },
137
141
  );
@@ -235,18 +239,19 @@ onUnmounted(() => {
235
239
  /*transition: var(--bgl-transition);*/
236
240
  }
237
241
 
238
- .custom-select-drop > * {
242
+ .custom-select-drop>* {
239
243
  /*transition: var(--bgl-transition); */
240
244
  padding: 0.5rem 0.75rem;
241
245
  }
242
246
 
243
- .custom-select-drop > *:hover {
247
+ .custom-select-drop>*:hover {
244
248
  background: var(--bgl-blue-light);
245
249
  }
246
250
 
247
- .custom-select-drop > *:active {
251
+ .custom-select-drop>*:active {
248
252
  filter: var(--bgl-hover-filter);
249
253
  }
254
+
250
255
  .bagel-input label {
251
256
  margin-bottom: 0;
252
257
  }
@@ -47,9 +47,7 @@
47
47
  no-label
48
48
  :field-meta="field"
49
49
  :bagel-app="bagel"
50
- @update:modelValue="(value: any) =>
51
- handleUpdateModelValue(value, index, field.fieldname)
52
- "
50
+ @update:modelValue="(value: any) => handleUpdateModelValue(value, index, field.fieldname)"
53
51
  :model-value="row[field.fieldname]"
54
52
  />
55
53
  </div>