@bagelink/vue 0.0.136 → 0.0.140
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/formkit/AddressArray.vue.d.ts +15 -11
- package/dist/components/formkit/AddressArray.vue.d.ts.map +1 -1
- package/dist/components/formkit/BankDetailsArray.vue.d.ts +17 -13
- package/dist/components/formkit/BankDetailsArray.vue.d.ts.map +1 -1
- package/dist/components/formkit/ContactArrayFormKit.vue.d.ts +13 -9
- package/dist/components/formkit/ContactArrayFormKit.vue.d.ts.map +1 -1
- package/dist/components/whatsapp/form/MsgTemplate.vue.d.ts +19 -3
- package/dist/components/whatsapp/form/MsgTemplate.vue.d.ts.map +1 -1
- package/dist/index.cjs +61 -48
- package/dist/index.mjs +61 -48
- package/dist/style.css +47 -47
- package/package.json +1 -1
- package/src/components/formkit/AddressArray.vue +25 -22
- package/src/components/formkit/BankDetailsArray.vue +29 -24
- package/src/components/formkit/ContactArrayFormKit.vue +22 -16
- package/src/components/whatsapp/form/MsgTemplate.vue +10 -6
|
@@ -11,20 +11,20 @@
|
|
|
11
11
|
v-if="deleteCandidate === i"
|
|
12
12
|
>
|
|
13
13
|
<p class="txt14">
|
|
14
|
-
{{
|
|
14
|
+
{{ formPlaceholders?.sure }}
|
|
15
15
|
</p>
|
|
16
16
|
<Btn
|
|
17
17
|
thin
|
|
18
18
|
color="red"
|
|
19
19
|
@click="deleteContact(address.id)"
|
|
20
20
|
>
|
|
21
|
-
{{
|
|
21
|
+
{{ formPlaceholders?.delete }}
|
|
22
22
|
</Btn>
|
|
23
23
|
<Btn
|
|
24
24
|
thin
|
|
25
25
|
@click="deleteCandidate = -1"
|
|
26
26
|
>
|
|
27
|
-
{{
|
|
27
|
+
{{ formPlaceholders?.cancel }}
|
|
28
28
|
</Btn>
|
|
29
29
|
</div>
|
|
30
30
|
<Checkbox
|
|
@@ -35,29 +35,29 @@
|
|
|
35
35
|
class="bglform-contact-label"
|
|
36
36
|
v-model="address.label"
|
|
37
37
|
type="text"
|
|
38
|
-
:placeholder="
|
|
38
|
+
:placeholder="formPlaceholders?.label"
|
|
39
39
|
>
|
|
40
40
|
<div class="bglform-contact-address">
|
|
41
41
|
<input
|
|
42
42
|
v-model="address.street"
|
|
43
|
-
:placeholder="
|
|
43
|
+
:placeholder="formPlaceholders?.street"
|
|
44
44
|
type="text"
|
|
45
45
|
>
|
|
46
46
|
<div class="bglform-contact-address-flex">
|
|
47
47
|
<input
|
|
48
48
|
v-model="address.city"
|
|
49
|
-
:placeholder="
|
|
49
|
+
:placeholder="formPlaceholders?.city"
|
|
50
50
|
type="text"
|
|
51
51
|
>
|
|
52
52
|
<input
|
|
53
53
|
v-model="address.postal_code"
|
|
54
|
-
:placeholder="
|
|
54
|
+
:placeholder="formPlaceholders?.zip"
|
|
55
55
|
type="text"
|
|
56
56
|
>
|
|
57
57
|
</div>
|
|
58
58
|
<input
|
|
59
59
|
v-model="address.country"
|
|
60
|
-
:placeholder="
|
|
60
|
+
:placeholder="formPlaceholders?.country"
|
|
61
61
|
type="text"
|
|
62
62
|
>
|
|
63
63
|
</div>
|
|
@@ -77,7 +77,7 @@
|
|
|
77
77
|
thin
|
|
78
78
|
@click="addNew"
|
|
79
79
|
>
|
|
80
|
-
{{
|
|
80
|
+
{{ formPlaceholders?.add }}
|
|
81
81
|
{{ context?.label }}
|
|
82
82
|
</Btn>
|
|
83
83
|
</div>
|
|
@@ -92,26 +92,29 @@ import { Btn, useBagel } from '@bagelink/vue';
|
|
|
92
92
|
import Checkbox from '../form/inputs/Checkbox.vue';
|
|
93
93
|
|
|
94
94
|
export interface AddressArrContext {
|
|
95
|
-
|
|
96
95
|
label?: string;
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
96
|
+
id?: string;
|
|
97
|
+
value: any[];
|
|
98
|
+
node: Record<string, any>;
|
|
99
|
+
attrs: {
|
|
100
|
+
formPlaceholders?: {
|
|
101
|
+
add?: string;
|
|
102
|
+
cancel?: string;
|
|
103
|
+
city?: string;
|
|
104
|
+
country?: string;
|
|
105
|
+
delete?: string;
|
|
106
|
+
label?: string;
|
|
107
|
+
sure?: string;
|
|
108
|
+
zip?: string;
|
|
109
|
+
street?: string;
|
|
110
|
+
};
|
|
107
111
|
};
|
|
108
|
-
[key: string]: any;
|
|
109
|
-
|
|
110
112
|
}
|
|
111
113
|
const bagel = useBagel();
|
|
112
114
|
const props = defineProps<{
|
|
113
115
|
context: AddressArrContext
|
|
114
116
|
}>();
|
|
117
|
+
const formPlaceholders = $computed(() => props.context?.attrs?.formPlaceholders);
|
|
115
118
|
|
|
116
119
|
let val = $ref<any[]>([]);
|
|
117
120
|
const addNew = () => {
|
|
@@ -11,20 +11,20 @@
|
|
|
11
11
|
v-if="deleteCandidate === i"
|
|
12
12
|
>
|
|
13
13
|
<p class="txt14">
|
|
14
|
-
{{
|
|
14
|
+
{{ formPlaceholders?.sure }}
|
|
15
15
|
</p>
|
|
16
16
|
<Btn
|
|
17
17
|
thin
|
|
18
18
|
color="red"
|
|
19
19
|
@click="deleteContact(bank_account.id)"
|
|
20
20
|
>
|
|
21
|
-
{{
|
|
21
|
+
{{ formPlaceholders?.delete }}
|
|
22
22
|
</Btn>
|
|
23
23
|
<Btn
|
|
24
24
|
thin
|
|
25
25
|
@click="deleteCandidate = -1"
|
|
26
26
|
>
|
|
27
|
-
{{
|
|
27
|
+
{{ formPlaceholders?.cancel }}
|
|
28
28
|
</Btn>
|
|
29
29
|
</div>
|
|
30
30
|
<Checkbox
|
|
@@ -35,25 +35,25 @@
|
|
|
35
35
|
class="bglform-contact-label"
|
|
36
36
|
v-model="bank_account.label"
|
|
37
37
|
type="text"
|
|
38
|
-
:placeholder="
|
|
38
|
+
:placeholder="formPlaceholders?.label"
|
|
39
39
|
>
|
|
40
40
|
<div class="bglform-contact-address">
|
|
41
41
|
<input
|
|
42
42
|
v-model="bank_account.bank_name"
|
|
43
|
-
:placeholder="
|
|
43
|
+
:placeholder="formPlaceholders?.bankName"
|
|
44
44
|
type="text"
|
|
45
45
|
required
|
|
46
46
|
>
|
|
47
47
|
<div class="bglform-contact-address-flex">
|
|
48
48
|
<input
|
|
49
49
|
v-model="bank_account.branch"
|
|
50
|
-
:placeholder="
|
|
50
|
+
:placeholder="formPlaceholders?.bankBranch"
|
|
51
51
|
type="text"
|
|
52
52
|
required
|
|
53
53
|
>
|
|
54
54
|
<input
|
|
55
55
|
v-model="bank_account.account_number"
|
|
56
|
-
:placeholder="
|
|
56
|
+
:placeholder="formPlaceholders?.bankAccount"
|
|
57
57
|
type="text"
|
|
58
58
|
required
|
|
59
59
|
>
|
|
@@ -61,13 +61,13 @@
|
|
|
61
61
|
<div class="grid gap-2">
|
|
62
62
|
<input
|
|
63
63
|
v-model="bank_account.bank_account_holder"
|
|
64
|
-
:placeholder="
|
|
64
|
+
:placeholder="formPlaceholders?.bankAccountHolder"
|
|
65
65
|
type="text"
|
|
66
66
|
required
|
|
67
67
|
>
|
|
68
68
|
<input
|
|
69
69
|
v-model="bank_account.bank_account_holder_id"
|
|
70
|
-
:placeholder="
|
|
70
|
+
:placeholder="formPlaceholders?.bankAccountHolderID"
|
|
71
71
|
type="text"
|
|
72
72
|
>
|
|
73
73
|
<input
|
|
@@ -82,7 +82,7 @@
|
|
|
82
82
|
>
|
|
83
83
|
<input
|
|
84
84
|
v-model="bank_account.bank_address"
|
|
85
|
-
:placeholder="
|
|
85
|
+
:placeholder="formPlaceholders?.bankAddress"
|
|
86
86
|
type="text"
|
|
87
87
|
>
|
|
88
88
|
</div>
|
|
@@ -103,7 +103,7 @@
|
|
|
103
103
|
thin
|
|
104
104
|
@click="val.push({})"
|
|
105
105
|
>
|
|
106
|
-
{{
|
|
106
|
+
{{ formPlaceholders?.add }} {{ context?.label }}
|
|
107
107
|
</Btn>
|
|
108
108
|
</div>
|
|
109
109
|
</div>
|
|
@@ -118,26 +118,31 @@ import Checkbox from '../form/inputs/Checkbox.vue';
|
|
|
118
118
|
|
|
119
119
|
export interface BankDetailsContext {
|
|
120
120
|
label?: string;
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
121
|
+
id?: string;
|
|
122
|
+
value: any[];
|
|
123
|
+
node: Record<string, any>;
|
|
124
|
+
attrs: {
|
|
125
|
+
formPlaceholders?: {
|
|
126
|
+
sure?: string;
|
|
127
|
+
delete?: string;
|
|
128
|
+
cancel?: string;
|
|
129
|
+
label?: string;
|
|
130
|
+
bankName?: string;
|
|
131
|
+
bankBranch?: string;
|
|
132
|
+
bankAccount?: string;
|
|
133
|
+
bankAccountHolder?: string;
|
|
134
|
+
bankAccountHolderID?: string;
|
|
135
|
+
bankAddress?: string;
|
|
136
|
+
add?: string;
|
|
137
|
+
};
|
|
133
138
|
};
|
|
134
|
-
[key: string]: any;
|
|
135
139
|
}
|
|
136
140
|
const bagel = useBagel();
|
|
137
141
|
|
|
138
142
|
const props = defineProps<{
|
|
139
143
|
context: BankDetailsContext;
|
|
140
144
|
}>();
|
|
145
|
+
const formPlaceholders = $computed(() => props.context?.attrs?.formPlaceholders);
|
|
141
146
|
|
|
142
147
|
let val = $ref<any[]>([]);
|
|
143
148
|
|
|
@@ -11,20 +11,20 @@
|
|
|
11
11
|
v-if="deleteCandidate === i"
|
|
12
12
|
>
|
|
13
13
|
<p class="txt14">
|
|
14
|
-
{{
|
|
14
|
+
{{ formPlaceholders?.sure }}
|
|
15
15
|
</p>
|
|
16
16
|
<Btn
|
|
17
17
|
thin
|
|
18
18
|
color="red"
|
|
19
19
|
@click="deleteContact(contact.id)"
|
|
20
20
|
>
|
|
21
|
-
{{
|
|
21
|
+
{{ formPlaceholders?.delete }}
|
|
22
22
|
</Btn>
|
|
23
23
|
<Btn
|
|
24
24
|
thin
|
|
25
25
|
@click="deleteCandidate = -1"
|
|
26
26
|
>
|
|
27
|
-
{{
|
|
27
|
+
{{ formPlaceholders?.cancel }}
|
|
28
28
|
</Btn>
|
|
29
29
|
</div>
|
|
30
30
|
<Checkbox
|
|
@@ -35,18 +35,18 @@
|
|
|
35
35
|
class="bglform-contact-label"
|
|
36
36
|
v-model="contact.label"
|
|
37
37
|
type="text"
|
|
38
|
-
:placeholder="
|
|
38
|
+
:placeholder="formPlaceholders?.label"
|
|
39
39
|
>
|
|
40
40
|
|
|
41
41
|
<input
|
|
42
42
|
v-model="contact.email"
|
|
43
|
-
:placeholder="
|
|
43
|
+
:placeholder="formPlaceholders?.email"
|
|
44
44
|
v-if="context?.id === 'email'"
|
|
45
45
|
type="email"
|
|
46
46
|
>
|
|
47
47
|
<input
|
|
48
48
|
v-model="contact.phone"
|
|
49
|
-
:placeholder="
|
|
49
|
+
:placeholder="formPlaceholders?.phone"
|
|
50
50
|
v-if="context?.id === 'phone'"
|
|
51
51
|
type="tel"
|
|
52
52
|
>
|
|
@@ -68,7 +68,7 @@
|
|
|
68
68
|
thin
|
|
69
69
|
@click="val.push({})"
|
|
70
70
|
>
|
|
71
|
-
{{
|
|
71
|
+
{{ formPlaceholders?.add }} {{ context?.label }}
|
|
72
72
|
</Btn>
|
|
73
73
|
</div>
|
|
74
74
|
</div>
|
|
@@ -83,16 +83,20 @@ import Checkbox from '../form/inputs/Checkbox.vue';
|
|
|
83
83
|
|
|
84
84
|
export interface ContactArrContext {
|
|
85
85
|
label?: string;
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
86
|
+
id?: string;
|
|
87
|
+
value: any[];
|
|
88
|
+
node: Record<string, any>;
|
|
89
|
+
attrs: {
|
|
90
|
+
formPlaceholders?: {
|
|
91
|
+
sure?: string
|
|
92
|
+
delete?: string
|
|
93
|
+
cancel?: string
|
|
94
|
+
label?: string
|
|
95
|
+
email?: string
|
|
96
|
+
phone?: string
|
|
97
|
+
add?: string
|
|
98
|
+
};
|
|
94
99
|
};
|
|
95
|
-
[key: string]: any;
|
|
96
100
|
}
|
|
97
101
|
const bagel = useBagel();
|
|
98
102
|
|
|
@@ -100,6 +104,8 @@ const props = defineProps<{
|
|
|
100
104
|
context: ContactArrContext
|
|
101
105
|
}>();
|
|
102
106
|
|
|
107
|
+
const formPlaceholders = $computed(() => props.context?.attrs?.formPlaceholders);
|
|
108
|
+
|
|
103
109
|
let val = $ref<any[]>([]);
|
|
104
110
|
let deleteCandidate = $ref<number>(-1);
|
|
105
111
|
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
class="whatsapp-preview"
|
|
15
15
|
:class="{ whatsappHebrew: localWhatsappData?.language === 'he' }"
|
|
16
16
|
>
|
|
17
|
-
|
|
17
|
+
{{ previewLabel }}
|
|
18
18
|
<div class="whatsapp-msg">
|
|
19
19
|
<b>{{
|
|
20
20
|
localWhatsappData?.headerText?.replace(regex, replaceHeader)
|
|
@@ -46,11 +46,15 @@ import {
|
|
|
46
46
|
FooterComponent,
|
|
47
47
|
} from '../interfaces';
|
|
48
48
|
|
|
49
|
-
const props =
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
49
|
+
const props = withDefaults(
|
|
50
|
+
defineProps<{
|
|
51
|
+
whatsappTemplateSchema: () => FormKitSchemaDefinition;
|
|
52
|
+
router: Router;
|
|
53
|
+
route: RouteLocationNormalizedLoaded;
|
|
54
|
+
previewLabel?: string;
|
|
55
|
+
}>(),
|
|
56
|
+
{ previewLabel: 'Preview' },
|
|
57
|
+
);
|
|
54
58
|
|
|
55
59
|
const bagel = useBagel();
|
|
56
60
|
|