@designcrowd/fe-shared-lib 1.4.3 → 1.4.4-locale-demical-price
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/.claude/settings.local.json +10 -0
- package/package.json +1 -1
- package/src/atoms/components/Price/Price.vue +5 -5
- package/src/experiences/clients/brand-crowd-api.client.js +12 -1
- package/src/experiences/components/UploadYourLogoApplication/UploadYourLogoApplication.vue +6 -0
- package/src/experiences/components/UploadYourLogoOnBoarding/LogoUploader.vue +6 -1
- package/src/experiences/components/UploadYourLogoOnBoarding/UploadYourLogoOnBoarding.vue +6 -0
- package/public/css/tailwind-brandCrowd.css +0 -2408
- package/public/css/tailwind-brandPage.css +0 -2092
- package/public/css/tailwind-crazyDomains.css +0 -2408
- package/public/css/tailwind-designCom.css +0 -2408
- package/public/css/tailwind-designCrowd.css +0 -2408
package/package.json
CHANGED
|
@@ -71,6 +71,10 @@ export default {
|
|
|
71
71
|
if (!this.amount || this.amount === 0) {
|
|
72
72
|
return this.free;
|
|
73
73
|
}
|
|
74
|
+
const parsedAmount = Number.parseFloat(this.amount);
|
|
75
|
+
const hasFraction = parsedAmount % 1 !== 0;
|
|
76
|
+
|
|
77
|
+
const fractionToDisplay = (!hasFraction && !this.alwaysShowFraction) ? 0 : this.fraction;
|
|
74
78
|
|
|
75
79
|
if (this.locale != null)
|
|
76
80
|
{
|
|
@@ -78,7 +82,7 @@ export default {
|
|
|
78
82
|
this.amount,
|
|
79
83
|
this.locale,
|
|
80
84
|
this.currency,
|
|
81
|
-
|
|
85
|
+
fractionToDisplay,
|
|
82
86
|
this.showAbbreviation
|
|
83
87
|
);
|
|
84
88
|
|
|
@@ -87,14 +91,10 @@ export default {
|
|
|
87
91
|
}
|
|
88
92
|
}
|
|
89
93
|
|
|
90
|
-
const parsedAmount = Number.parseFloat(this.amount);
|
|
91
|
-
|
|
92
94
|
if (Number.isNaN(parsedAmount)) {
|
|
93
95
|
return this.amount;
|
|
94
96
|
}
|
|
95
97
|
|
|
96
|
-
const hasFraction = parsedAmount % 1 !== 0;
|
|
97
|
-
|
|
98
98
|
if (!hasFraction && !this.alwaysShowFraction) {
|
|
99
99
|
return parsedAmount.toFixed(0);
|
|
100
100
|
}
|
|
@@ -12,10 +12,21 @@ const getAxios = () => {
|
|
|
12
12
|
return internalAxios || axios;
|
|
13
13
|
};
|
|
14
14
|
|
|
15
|
-
|
|
15
|
+
/**
|
|
16
|
+
* @param {File} logoFile
|
|
17
|
+
* @param {Object} data
|
|
18
|
+
* @returns Promise<{ success: boolean, response: any, error: any }>
|
|
19
|
+
*/
|
|
20
|
+
const uploadLogoAndGetDetails = async (logoFile, data) => {
|
|
16
21
|
const formData = new FormData();
|
|
17
22
|
formData.append('logoImage', logoFile && logoFile.file);
|
|
18
23
|
|
|
24
|
+
if (data && Object.keys(data).length > 0) {
|
|
25
|
+
Object.keys(data).forEach((key) => {
|
|
26
|
+
formData.append(key, data[key]);
|
|
27
|
+
});
|
|
28
|
+
}
|
|
29
|
+
|
|
19
30
|
try {
|
|
20
31
|
const response = await getAxios()({
|
|
21
32
|
method: 'post',
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
<UploadYourLogoOnBoarding
|
|
4
4
|
v-if="active"
|
|
5
5
|
:logo-file="logoData.logoFile"
|
|
6
|
+
:custom-upload-data="customUploadData"
|
|
6
7
|
:use-dropzone="useDropzone"
|
|
7
8
|
:is-post-purchase-user-upload="isPostPurchaseUserUpload"
|
|
8
9
|
@on-exit="onExit"
|
|
@@ -36,6 +37,11 @@ export default {
|
|
|
36
37
|
required: false,
|
|
37
38
|
default: false,
|
|
38
39
|
},
|
|
40
|
+
customUploadData: {
|
|
41
|
+
type: Object,
|
|
42
|
+
required: false,
|
|
43
|
+
default: null,
|
|
44
|
+
},
|
|
39
45
|
},
|
|
40
46
|
data() {
|
|
41
47
|
return {
|
|
@@ -19,6 +19,11 @@ export default {
|
|
|
19
19
|
required: true,
|
|
20
20
|
default: undefined,
|
|
21
21
|
},
|
|
22
|
+
customUploadData: {
|
|
23
|
+
type: Object,
|
|
24
|
+
required: false,
|
|
25
|
+
default: null,
|
|
26
|
+
},
|
|
22
27
|
eventCategory: {
|
|
23
28
|
type: String,
|
|
24
29
|
required: true,
|
|
@@ -50,7 +55,7 @@ export default {
|
|
|
50
55
|
duration = Date.now() - start;
|
|
51
56
|
}, 1);
|
|
52
57
|
|
|
53
|
-
const result = await brandCrowdClient.uploadLogoAndGetDetails(this.logoFile);
|
|
58
|
+
const result = await brandCrowdClient.uploadLogoAndGetDetails(this.logoFile, this.customUploadData);
|
|
54
59
|
|
|
55
60
|
clearInterval(intervalTimer);
|
|
56
61
|
this.isRunning = false;
|
|
@@ -20,6 +20,7 @@
|
|
|
20
20
|
<LogoUploader
|
|
21
21
|
v-if="logoFile && !isAttemptingToExit && !hasError && currentStep === 1"
|
|
22
22
|
:logo-file="logoFile"
|
|
23
|
+
:custom-upload-data="customUploadData"
|
|
23
24
|
:event-category="eventCategory"
|
|
24
25
|
@on-upload-success="onUploadSuccess"
|
|
25
26
|
@on-upload-error="onUploadError"
|
|
@@ -127,6 +128,11 @@ export default {
|
|
|
127
128
|
required: false,
|
|
128
129
|
default: false,
|
|
129
130
|
},
|
|
131
|
+
customUploadData: {
|
|
132
|
+
type: Object,
|
|
133
|
+
required: false,
|
|
134
|
+
default: undefined,
|
|
135
|
+
},
|
|
130
136
|
},
|
|
131
137
|
setup() {
|
|
132
138
|
return {
|