@designcrowd/fe-shared-lib 1.2.6-ml-291-1 → 1.2.6-ml-291-3
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/package.json
CHANGED
|
@@ -73,7 +73,7 @@
|
|
|
73
73
|
</div>
|
|
74
74
|
</template>
|
|
75
75
|
<script>
|
|
76
|
-
import
|
|
76
|
+
import { getCurrentLocale } from '../../../useSharedLibTranslate';
|
|
77
77
|
import HelloBar from '../../../../src/atoms/components/HelloBar/HelloBar.vue';
|
|
78
78
|
import SubmissionButton from './SubmissionButton.vue';
|
|
79
79
|
|
|
@@ -138,13 +138,14 @@ export default {
|
|
|
138
138
|
goBackToLoginLabel: this.forgotPasswordContent?.goBackToLoginLabel ?? 'Go back to login',
|
|
139
139
|
emailAddressPlaceholderLabel: this.forgotPasswordContent?.emailAddressPlaceholderLabel ?? 'Email address',
|
|
140
140
|
emailLabel: this.forgotPasswordContent?.emailLabel ?? 'Email',
|
|
141
|
+
emailErrorMessage: this.forgotPasswordContent?.emailErrorMessage ?? 'Please enter a valid email address',
|
|
141
142
|
modalDescription: this.forgotPasswordContent?.description ?? 'Enter your email below. We will then send a reset-password link to your email address.',
|
|
142
143
|
title: this.forgotPasswordContent?.title ?? 'Forgot your password?',
|
|
143
144
|
};
|
|
144
145
|
},
|
|
145
146
|
computed: {
|
|
146
147
|
currentLocale() {
|
|
147
|
-
return
|
|
148
|
+
return getCurrentLocale();
|
|
148
149
|
},
|
|
149
150
|
getRedirectToSignInUrl() {
|
|
150
151
|
const url = new URL(`https://${window.location.host}${this.signInUrl}`);
|
|
@@ -187,7 +188,7 @@ export default {
|
|
|
187
188
|
this.emailError = undefined;
|
|
188
189
|
|
|
189
190
|
if (!this.aEmail) {
|
|
190
|
-
this.emailError =
|
|
191
|
+
this.emailError = this.emailErrorMessage;
|
|
191
192
|
}
|
|
192
193
|
|
|
193
194
|
e.preventDefault();
|
|
@@ -64,7 +64,7 @@
|
|
|
64
64
|
</div>
|
|
65
65
|
</template>
|
|
66
66
|
<script>
|
|
67
|
-
import
|
|
67
|
+
import { getCurrentLocale } from '../../../useSharedLibTranslate';
|
|
68
68
|
import HelloBar from '../../../../src/atoms/components/HelloBar/HelloBar.vue';
|
|
69
69
|
import SubmissionButton from './SubmissionButton.vue';
|
|
70
70
|
|
|
@@ -138,7 +138,7 @@ export default {
|
|
|
138
138
|
},
|
|
139
139
|
computed: {
|
|
140
140
|
currentLocale() {
|
|
141
|
-
return
|
|
141
|
+
return getCurrentLocale();
|
|
142
142
|
},
|
|
143
143
|
},
|
|
144
144
|
methods: {
|
|
@@ -35,4 +35,8 @@ const tr = (key, valuesToInterpolate = {}) => {
|
|
|
35
35
|
return translated;
|
|
36
36
|
};
|
|
37
37
|
|
|
38
|
-
|
|
38
|
+
const getCurrentLocale = () => {
|
|
39
|
+
return i18next.language || 'en-US';
|
|
40
|
+
};
|
|
41
|
+
|
|
42
|
+
export { setSharedLibLocaleAsync, tr, getCurrentLocale };
|