@designcrowd/fe-shared-lib 1.2.6 → 1.2.7-ml-291-6

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 (72) hide show
  1. package/.github/workflows/auto-merge.yml +52 -0
  2. package/CLAUDE.md +71 -0
  3. package/Dockerfile +1 -1
  4. package/dist/css/tailwind-brandCrowd.css +2485 -0
  5. package/dist/css/tailwind-brandPage.css +2169 -0
  6. package/dist/css/tailwind-crazyDomains.css +2485 -0
  7. package/dist/css/tailwind-designCom.css +2485 -0
  8. package/dist/css/tailwind-designCrowd.css +2485 -0
  9. package/package.json +2 -2
  10. package/public/css/tailwind-brandCrowd.css +26 -0
  11. package/public/css/tailwind-brandPage.css +22 -0
  12. package/public/css/tailwind-crazyDomains.css +26 -0
  13. package/public/css/tailwind-designCom.css +26 -0
  14. package/public/css/tailwind-designCrowd.css +26 -0
  15. package/src/atoms/components/Price/Price.vue +1 -1
  16. package/src/bundles/bundled-translations.de-DE.json +49 -2
  17. package/src/bundles/bundled-translations.es-ES.json +49 -2
  18. package/src/bundles/bundled-translations.fr-FR.json +49 -2
  19. package/src/bundles/bundled-translations.json +49 -2
  20. package/src/bundles/bundled-translations.pt-PT.json +49 -2
  21. package/src/experiences/components/AuthFlow/ForgotPassword.vue +21 -9
  22. package/src/experiences/components/AuthFlow/ResetPassword.vue +37 -8
  23. package/src/experiences/components/PublishBrandPageModal/PublishBrandPageCard.vue +14 -10
  24. package/src/experiences/components/PublishBrandPageModal/PublishBrandPageModal.stories.js +29 -6
  25. package/src/experiences/components/PublishBrandPageModal/PublishBrandPageModal.vue +59 -27
  26. package/src/experiences/components/PublishBrandPageModal/i18n/publish-brand-page-modal.de-DE.json +22 -0
  27. package/src/experiences/components/PublishBrandPageModal/i18n/publish-brand-page-modal.es-ES.json +22 -0
  28. package/src/experiences/components/PublishBrandPageModal/i18n/publish-brand-page-modal.fr-FR.json +22 -0
  29. package/src/experiences/components/PublishBrandPageModal/i18n/publish-brand-page-modal.json +22 -0
  30. package/src/experiences/components/PublishBrandPageModal/i18n/publish-brand-page-modal.pt-PT.json +22 -0
  31. package/src/experiences/components/SellDomainNameList/SellDomainNameList.vue +15 -7
  32. package/src/experiences/components/SellDomainNameList/i18n/sell-domain-name-list.de-DE.json +8 -0
  33. package/src/experiences/components/SellDomainNameList/i18n/sell-domain-name-list.es-ES.json +8 -0
  34. package/src/experiences/components/SellDomainNameList/i18n/sell-domain-name-list.fr-FR.json +8 -0
  35. package/src/experiences/components/SellDomainNameList/i18n/sell-domain-name-list.json +8 -0
  36. package/src/experiences/components/SellDomainNameList/i18n/sell-domain-name-list.pt-PT.json +8 -0
  37. package/src/experiences/components/SellDomainNameListModal/SellDomainNameListModal.vue +12 -8
  38. package/src/experiences/components/SellDomainNameListModal/i18n/sell-domain-name-list-modal.de-DE.json +6 -0
  39. package/src/experiences/components/SellDomainNameListModal/i18n/sell-domain-name-list-modal.es-ES.json +6 -0
  40. package/src/experiences/components/SellDomainNameListModal/i18n/sell-domain-name-list-modal.fr-FR.json +6 -0
  41. package/src/experiences/components/SellDomainNameListModal/i18n/sell-domain-name-list-modal.json +6 -0
  42. package/src/experiences/components/SellDomainNameListModal/i18n/sell-domain-name-list-modal.pt-PT.json +6 -0
  43. package/src/experiences/components/SellDomainNameModalApplication/SellDomainNameModalApplication.vue +13 -9
  44. package/src/experiences/components/SellDomainNameModalApplication/i18n/sell-domain-name-modal-application.de-DE.json +6 -0
  45. package/src/experiences/components/SellDomainNameModalApplication/i18n/sell-domain-name-modal-application.es-ES.json +6 -0
  46. package/src/experiences/components/SellDomainNameModalApplication/i18n/sell-domain-name-modal-application.fr-FR.json +6 -0
  47. package/src/experiences/components/SellDomainNameModalApplication/i18n/sell-domain-name-modal-application.json +6 -0
  48. package/src/experiences/components/SellDomainNameModalApplication/i18n/sell-domain-name-modal-application.pt-PT.json +6 -0
  49. package/src/experiences/components/SellDomainNameSearch/SellDomainNameSearch.vue +18 -13
  50. package/src/experiences/components/SellDomainNameSearch/i18n/sell-domain-name-search.de-DE.json +8 -0
  51. package/src/experiences/components/SellDomainNameSearch/i18n/sell-domain-name-search.es-ES.json +8 -0
  52. package/src/experiences/components/SellDomainNameSearch/i18n/sell-domain-name-search.fr-FR.json +8 -0
  53. package/src/experiences/components/SellDomainNameSearch/i18n/sell-domain-name-search.json +8 -0
  54. package/src/experiences/components/SellDomainNameSearch/i18n/sell-domain-name-search.pt-PT.json +8 -0
  55. package/src/experiences/components/SellDomainNameSearchResult/SellDomainNameListSearchResult.vue +15 -5
  56. package/src/experiences/components/SellDomainNameSearchResult/i18n/sell-domain-name-list-search-result.de-DE.json +6 -0
  57. package/src/experiences/components/SellDomainNameSearchResult/i18n/sell-domain-name-list-search-result.es-ES.json +6 -0
  58. package/src/experiences/components/SellDomainNameSearchResult/i18n/sell-domain-name-list-search-result.fr-FR.json +6 -0
  59. package/src/experiences/components/SellDomainNameSearchResult/i18n/sell-domain-name-list-search-result.json +6 -0
  60. package/src/experiences/components/SellDomainNameSearchResult/i18n/sell-domain-name-list-search-result.pt-PT.json +6 -0
  61. package/src/experiences/components/SellDomainNameWidget/SellDomainNameWidget.vue +15 -12
  62. package/src/experiences/components/SellDomainNameWidget/i18n/sell-domain-name-widget.de-DE.json +8 -0
  63. package/src/experiences/components/SellDomainNameWidget/i18n/sell-domain-name-widget.es-ES.json +8 -0
  64. package/src/experiences/components/SellDomainNameWidget/i18n/sell-domain-name-widget.fr-FR.json +8 -0
  65. package/src/experiences/components/SellDomainNameWidget/i18n/sell-domain-name-widget.json +8 -0
  66. package/src/experiences/components/SellDomainNameWidget/i18n/sell-domain-name-widget.pt-PT.json +8 -0
  67. package/src/useSharedLibTranslate.js +37 -1
  68. package/src/experiences/components/PublishBrandPageModal/i18n/publish-modal.de-DE.json +0 -5
  69. package/src/experiences/components/PublishBrandPageModal/i18n/publish-modal.es-ES.json +0 -5
  70. package/src/experiences/components/PublishBrandPageModal/i18n/publish-modal.fr-FR.json +0 -5
  71. package/src/experiences/components/PublishBrandPageModal/i18n/publish-modal.json +0 -5
  72. package/src/experiences/components/PublishBrandPageModal/i18n/publish-modal.pt-PT.json +0 -5
@@ -13,7 +13,7 @@
13
13
  {{ title }}
14
14
  </h2>
15
15
  <p class="tw-mb-8 tw-text-grayscale-600">{{ description }}</p>
16
- <form id="resetPassword" method="post" @submit="validate">
16
+ <form id="resetPassword" ref="resetPasswordForm" method="post" @submit="validate">
17
17
  <input name="__RequestVerificationToken" type="hidden" :value="antiForgeryToken" />
18
18
  <input name="userName" type="hidden" :value="userName" />
19
19
  <input name="resetPasswordToken" type="hidden" :value="resetPasswordToken" />
@@ -25,14 +25,14 @@
25
25
  aria-required="true"
26
26
  :aria-invalid="!!passwordError"
27
27
  autocomplete="new-password"
28
- placeholder="New password"
28
+ :placeholder="newPasswordPlaceholder"
29
29
  class="password-input tw-mb-3 tw-h-12 tw-bg-no-repeat tw-w-full tw-rounded tw-shadow-inner tw-outline-none tw-py-4 tw-pl-10-important tw-pr-2 tw-text-grayscale-600 tw-border tw-border-grayscale-500 focus:tw-border-grayscale-700"
30
30
  :class="{ 'tw-border-error-500': !!passwordError }"
31
31
  />
32
32
  <p v-if="!!passwordError" class="tw-text-error-500 tw-text-sm tw-text-left tw-mb-4">
33
33
  {{ passwordError }}
34
34
  </p>
35
- <label for="confirmPassword" class="tw-sr-only"> Confirm Password </label>
35
+ <label for="confirmPassword" class="tw-sr-only">{{ confirmPasswordLabel }}</label>
36
36
  <input
37
37
  v-model="confirmPassword"
38
38
  name="confirmPassword"
@@ -40,7 +40,7 @@
40
40
  aria-required="true"
41
41
  :aria-invalid="!!confirmPasswordError"
42
42
  autocomplete="off"
43
- placeholder="Confirm new password"
43
+ :placeholder="confirmPasswordPlaceholder"
44
44
  class="password-input tw-mb-3 tw-h-12 tw-bg-no-repeat tw-w-full tw-rounded tw-shadow-inner tw-outline-none tw-py-4 tw-pl-10-important tw-pr-2 tw-text-grayscale-600 tw-border tw-border-grayscale-500 focus:tw-border-grayscale-700"
45
45
  :class="{ 'tw-border-error-500': !!confirmPasswordError }"
46
46
  />
@@ -50,7 +50,7 @@
50
50
  <SubmissionButton
51
51
  variant="primary"
52
52
  size="medium"
53
- label="UPDATE PASSWORD"
53
+ :label="updatePasswordLabel"
54
54
  label-size="larger"
55
55
  :is-loading="isLoading"
56
56
  :disabled="isLoading"
@@ -63,6 +63,7 @@
63
63
  </div>
64
64
  </template>
65
65
  <script>
66
+ import { getCurrentLocale } from '../../../useSharedLibTranslate';
66
67
  import HelloBar from '../../../../src/atoms/components/HelloBar/HelloBar.vue';
67
68
  import SubmissionButton from './SubmissionButton.vue';
68
69
 
@@ -80,7 +81,7 @@ export default {
80
81
  description: {
81
82
  type: String,
82
83
  required: false,
83
- default: 'Enter and confirm your new password',
84
+ default: undefined,
84
85
  },
85
86
  userName: {
86
87
  type: String,
@@ -104,6 +105,16 @@ export default {
104
105
  required: false,
105
106
  default: undefined,
106
107
  },
108
+ submitAction: {
109
+ type: String,
110
+ required: false,
111
+ default: undefined,
112
+ },
113
+ resetPasswordContent: {
114
+ type: Object,
115
+ required: false,
116
+ default: () => {},
117
+ },
107
118
  },
108
119
  data() {
109
120
  return {
@@ -112,10 +123,28 @@ export default {
112
123
  confirmPassword: undefined,
113
124
  passwordError: undefined,
114
125
  confirmPasswordError: undefined,
126
+
127
+ newPasswordLabel: this.resetPasswordContent?.newPasswordLabel ?? 'New Password',
128
+ newPasswordPlaceholder: this.resetPasswordContent?.newPasswordPlaceholder ?? 'New password',
129
+ confirmPasswordLabel: this.resetPasswordContent?.confirmPasswordLabel ?? 'Confirm Password',
130
+ confirmPasswordPlaceholder: this.resetPasswordContent?.confirmPasswordPlaceholder ?? 'Confirm new password',
131
+ updatePasswordLabel: this.resetPasswordContent?.updatePasswordLabel ?? 'UPDATE PASSWORD',
132
+ passwordRequiredError: this.resetPasswordContent?.passwordRequiredError ?? 'Please enter a password',
133
+ passwordsDoNotMatchError: this.resetPasswordContent?.passwordsDoNotMatchError ?? 'Passwords do not match',
115
134
  };
116
135
  },
136
+ computed: {
137
+ currentLocale() {
138
+ return getCurrentLocale();
139
+ },
140
+ },
117
141
  methods: {
118
142
  validate(e) {
143
+ if (this.submitAction) {
144
+ const url = new URL(this.submitAction, window.location.origin);
145
+ url.searchParams.set('locale', this.currentLocale);
146
+ this.$refs.resetPasswordForm.action = url.toString();
147
+ }
119
148
  if (this.password && this.password === this.confirmPassword) {
120
149
  this.isLoading = true;
121
150
  return true;
@@ -127,9 +156,9 @@ export default {
127
156
  this.confirmPasswordError = undefined;
128
157
 
129
158
  if (!this.password) {
130
- this.passwordError = 'Please enter a password';
159
+ this.passwordError = this.passwordRequiredError;
131
160
  } else if (!this.confirmPassword || this.password !== this.confirmPassword) {
132
- this.confirmPasswordError = 'Passwords do not match';
161
+ this.confirmPasswordError = this.passwordsDoNotMatchError;
133
162
  }
134
163
 
135
164
  e.preventDefault();
@@ -12,10 +12,10 @@
12
12
  {{ title }}
13
13
  </p>
14
14
  <span
15
- v-if="showLabel"
15
+ v-if="pillLabel"
16
16
  class="tw-text-xs tw-h-4 tw-w-fit tw-text-primary-500 tw-border tw-border-solid tw-border-primary-500 tw-rounded-full tw-px-2 tw-font-sans tw-uppercase"
17
17
  >
18
- Recommended
18
+ {{ pillLabel }}
19
19
  </span>
20
20
  </div>
21
21
  <p class="tw-mt-2 md:tw-mt-0 tw-text-grayscale-600 tw-text-sm">
@@ -27,15 +27,15 @@
27
27
  </div>
28
28
  <div v-if="hasSearchButton" class="tw-w-full md:tw-w-auto md:tw-justify-end md:tw-pl-4 desktop-cta">
29
29
  <Button
30
- label="Search"
30
+ :label="searchButtonLabel"
31
31
  class="tw-flex tw-items-center tw-justify-center md:tw-ml-2 tw-mt-2 md:tw-mt-0 tw-font-sans tw-font-bold tw-transition-colors tw-duration-300 tw-text-sm tw-w-full tw-rounded tw-cursor-pointer tw-w-full md:tw-w-24"
32
32
  data-test-brand-page-search-button
33
33
  variant="primary"
34
34
  size="small-medium"
35
- @on-click="onClick"
36
35
  :class="{
37
36
  'tw-uppercase': !isDesignCom,
38
37
  }"
38
+ @on-click="onClick"
39
39
  />
40
40
  </div>
41
41
  </div>
@@ -47,23 +47,23 @@
47
47
  </div>
48
48
  <div v-if="hasSearchButton" class="tw-w-full md:tw-w-auto md:tw-justify-end md:tw-pl-4 mobile-cta tw-mt-2">
49
49
  <Button
50
- label="Search"
50
+ :label="searchButtonLabel"
51
51
  class="tw-flex tw-items-center tw-justify-center md:tw-ml-2 tw-mt-2 md:tw-mt-0 tw-font-sans tw-font-bold tw-transition-colors tw-duration-300 tw-text-sm tw-w-full tw-rounded tw-cursor-pointer tw-w-full md:tw-w-24"
52
52
  data-test-brand-page-search-button
53
53
  variant="primary"
54
54
  size="small-medium"
55
55
  :full-width="true"
56
- @on-click="onClick"
57
56
  :class="{
58
57
  'tw-uppercase': !isDesignCom,
59
58
  }"
59
+ @on-click="onClick"
60
60
  />
61
61
  </div>
62
62
  </div>
63
63
  </div>
64
64
  </template>
65
65
  <script setup lang="ts">
66
- import Button from '../../../../src/atoms/components/Button/Button.vue';
66
+ import Button from '../../../atoms/components/Button/Button.vue';
67
67
 
68
68
  const props = defineProps({
69
69
  title: {
@@ -86,9 +86,13 @@ const props = defineProps({
86
86
  type: Boolean,
87
87
  default: true,
88
88
  },
89
- showLabel: {
90
- type: Boolean,
91
- default: false,
89
+ searchButtonLabel: {
90
+ type: String,
91
+ default: () => 'Search',
92
+ },
93
+ pillLabel: {
94
+ type: String,
95
+ default: null,
92
96
  },
93
97
  });
94
98
 
@@ -1,12 +1,19 @@
1
1
  import Card from './PublishBrandPageCard.vue';
2
2
  import PublishBrandPageModal from './PublishBrandPageModal.vue';
3
3
  import { domains } from './__fixtures__/data';
4
+ import { setSharedLibLocaleAsync } from '../../../useSharedLibTranslate';
4
5
 
5
6
  export default {
6
7
  title: 'Components/PublishBrandPageModal',
7
8
  component: PublishBrandPageModal,
8
9
  };
9
10
 
11
+ const locale = 'en-US';
12
+
13
+ const loadTranslationAsync = async () => {
14
+ await setSharedLibLocaleAsync(locale);
15
+ };
16
+
10
17
  export const NotPublishedWithPurchasedDomains = () => {
11
18
  return {
12
19
  components: {
@@ -15,6 +22,7 @@ export const NotPublishedWithPurchasedDomains = () => {
15
22
  data() {
16
23
  return {
17
24
  domains,
25
+ show: false,
18
26
  };
19
27
  },
20
28
  methods: {},
@@ -26,7 +34,7 @@ export const NotPublishedWithPurchasedDomains = () => {
26
34
  should-publish
27
35
  :domains="domains"
28
36
  brand-page-display-name='Website'
29
- brand-page-base-url="https://brand.site/"
37
+ brand-page-base-url="https://brand.site"
30
38
  radio-value="slug"
31
39
  :show-radio-buttons="domains.length > 0"
32
40
  />
@@ -34,6 +42,8 @@ export const NotPublishedWithPurchasedDomains = () => {
34
42
  };
35
43
  };
36
44
 
45
+ NotPublishedWithPurchasedDomains.loaders = [loadTranslationAsync];
46
+
37
47
  export const PublishWithSelectedDomain = () => {
38
48
  return {
39
49
  components: {
@@ -66,7 +76,7 @@ export const PublishWithSelectedDomain = () => {
66
76
  :domains="domains"
67
77
  :custom-domain="customDomain"
68
78
  brand-page-display-name='Website'
69
- brand-page-base-url="https://brand.site/"
79
+ brand-page-base-url="https://brand.site"
70
80
  radio-value="purchased"
71
81
  :show-radio-buttons="domains.length > 0"
72
82
  @radio-button-changed="onRadioButtonChanged"
@@ -75,6 +85,8 @@ export const PublishWithSelectedDomain = () => {
75
85
  };
76
86
  };
77
87
 
88
+ PublishWithSelectedDomain.loaders = [loadTranslationAsync];
89
+
78
90
  export const SetSlug = () => {
79
91
  return {
80
92
  components: {
@@ -94,13 +106,16 @@ export const SetSlug = () => {
94
106
  should-publish
95
107
  :domains="domains"
96
108
  brand-page-display-name='Website'
97
- brand-page-base-url="https://brand.site/"
109
+ brand-page-base-url="https://brand.site"
98
110
  brand-page-slug='test-slug'
99
111
  :show-radio-buttons="domains.length > 0"
100
112
  />
101
113
  `,
102
114
  };
103
115
  };
116
+
117
+ SetSlug.loaders = [loadTranslationAsync];
118
+
104
119
  export const Published = () => {
105
120
  return {
106
121
  components: {
@@ -119,13 +134,16 @@ export const Published = () => {
119
134
  should-publish
120
135
  :domains="domains"
121
136
  brand-page-display-name='Website'
122
- brand-page-base-url="https://brand.site/"
137
+ brand-page-base-url="https://brand.site"
123
138
  radio-value="slug"
124
139
  brand-page-url="https://brand.site/brandname"
125
140
  />
126
141
  `,
127
142
  };
128
143
  };
144
+
145
+ Published.loaders = [loadTranslationAsync];
146
+
129
147
  export const PublishedNoDomains = () => {
130
148
  return {
131
149
  components: {
@@ -146,13 +164,16 @@ export const PublishedNoDomains = () => {
146
164
  :domains="domains"
147
165
  brand-page-display-name='Website'
148
166
  brand-page-slug='test-slug'
149
- brand-page-base-url="https://brand.site/"
167
+ brand-page-base-url="https://brand.site"
150
168
  radio-value="slug"
151
169
  brand-page-url="https://brand.site/test-slug"
152
170
  />
153
171
  `,
154
172
  };
155
173
  };
174
+
175
+ PublishedNoDomains.loaders = [loadTranslationAsync];
176
+
156
177
  export const Free = () => {
157
178
  return {
158
179
  components: {
@@ -180,7 +201,7 @@ export const Free = () => {
180
201
  should-publish
181
202
  :domains="domains"
182
203
  brand-page-display-name='Website'
183
- brand-page-base-url="https://brand.site/"
204
+ brand-page-base-url="https://brand.site"
184
205
  radio-value="slug"
185
206
  brand-page-url="https://brand.site/brandname"
186
207
  :show-radio-buttons="domains.length > 0"
@@ -201,3 +222,5 @@ export const Free = () => {
201
222
  `,
202
223
  };
203
224
  };
225
+
226
+ Free.loaders = [loadTranslationAsync];
@@ -11,15 +11,15 @@
11
11
  >
12
12
  <template #header>
13
13
  <div v-if="isNotPublished || isSlugEditMode" class="tw-text-center tw-font-bold tw-mb-8 tw-mt-8 tw-text-4xl">
14
- <span>Set the URL for your {{ brandPageDisplayName }}</span>
14
+ <span>{{ firstTimePublishHeaderLabel }}</span>
15
15
  </div>
16
16
  <div v-if="isPublished && !isSlugEditMode" class="tw-text-center tw-font-bold tw-mb-8 tw-mt-8">
17
- <p class="tw-font-bold tw-text-black tw-mb-2 tw-text-4xl">Site published!</p>
17
+ <p class="tw-font-bold tw-text-black tw-mb-2 tw-text-4xl">{{ sitePublishedLabel }}</p>
18
18
  <p v-if="hasPurchasedDomains || isCustomDomainActive" class="tw-text-grayscale-600 tw-mb-8">
19
- Your {{ brandPageDisplayName }} is live! Start using your link:
19
+ {{ publishSuccessLabel }}
20
20
  </p>
21
21
  <p v-else class="tw-text-grayscale-600 tw-mb-8 tw-font-normal">
22
- {{ headerSubtitle }}
22
+ {{ publishedSuccessDescriptionLabel }}
23
23
  </p>
24
24
  </div>
25
25
  </template>
@@ -44,25 +44,25 @@
44
44
  for="domain-type"
45
45
  class="tw-font-sans tw-w-full tw-text-grayscale-600 tw-text-sm tw-cursor-pointer tw-ml-2"
46
46
  >
47
- <span class="tw-inline-block tw-rounded-full">Free domain</span>
47
+ <span class="tw-inline-block tw-rounded-full">{{ freeDomainLabel }}</span>
48
48
  </label>
49
49
  </div>
50
50
  <div v-if="isNotPublished || isSlugEditMode" class="tw-mt-4">
51
51
  <PublishBrandPageCard
52
52
  v-if="!hasPurchasedDomains"
53
53
  :img-url="iconUrl"
54
- title="Free Address"
55
- description="Choose a free address to publish now. You can always edit the URL later"
54
+ :title="freePublishCardTitleLabel"
55
+ :description="freePublishCardDescriptionLabel"
56
56
  :is-design-com="isDesignCom"
57
57
  :has-search-button="false"
58
58
  >
59
59
  <template #slug>
60
60
  <div class="tw-flex tw-flex-col md:tw-flex-row tw-justify-between">
61
- <div>
61
+ <div class="tw-grow md:tw-mr-2">
62
62
  <TextInput
63
63
  v-model="internalSlug"
64
- element-classes="tw-mb-0 !tw-rounded-l-none tw-text-md tw-w-1/3"
65
- :prefix-text="`${brandPageBaseUrl}/`"
64
+ element-classes="tw-mb-0 !tw-rounded-l-none tw-text-md"
65
+ :prefix-text="`${brandPageBaseUrlWithoutHttps}/`"
66
66
  :error="!!slugValidationError"
67
67
  :disabled="isInputEnabled"
68
68
  :placeholder="getPlaceHolder"
@@ -78,9 +78,9 @@
78
78
  </div>
79
79
  </div>
80
80
  <Button
81
- label="Publish"
81
+ :label="publishLabel"
82
82
  :disabled="isPublishingDisabled"
83
- class="tw-flex tw-items-center tw-justify-center md:tw-ml-2 tw-mt-2 md:tw-mt-0 tw-font-sans tw-font-bold tw-transition-colors tw-duration-300 tw-text-sm tw-w-full tw-rounded tw-cursor-pointer tw-w-full md:tw-w-24"
83
+ class="tw-flex tw-items-center tw-justify-center tw-mt-2 md:tw-mt-0 tw-font-bold tw-transition-colors tw-duration-300"
84
84
  data-test-brand-page-publish-button
85
85
  variant="primary"
86
86
  size="small-medium"
@@ -97,7 +97,7 @@
97
97
  <TextInput
98
98
  v-model="internalSlug"
99
99
  element-classes="tw-mb-0 !tw-rounded-l-none tw-text-lg"
100
- :prefix-text="`${brandPageBaseUrl}/`"
100
+ :prefix-text="`${brandPageBaseUrlWithoutHttps}/`"
101
101
  :error="!!slugValidationError"
102
102
  :disabled="isInputEnabled"
103
103
  :placeholder="getPlaceHolder"
@@ -128,7 +128,7 @@
128
128
  for="domain-type"
129
129
  class="tw-font-sans tw-w-full tw-text-grayscale-600 tw-text-sm tw-cursor-pointer tw-ml-2"
130
130
  >
131
- <span class="tw-inline-block tw-rounded-full">Purchased domain</span>
131
+ <span class="tw-inline-block tw-rounded-full">{{ purchasedDomainLabel }}</span>
132
132
  </label>
133
133
  </div>
134
134
  <div class="tw-mt-4 domain-dropdown">
@@ -143,7 +143,7 @@
143
143
  :class="{
144
144
  'tw-text-grayscale-600 tw-font-normal': !selectedCustomDomain,
145
145
  }"
146
- :title="(selectedCustomDomain && selectedCustomDomain.domainName) || 'Select domain name'"
146
+ :title="(selectedCustomDomain && selectedCustomDomain.domainName) || selectDomainDropdownPlaceholder"
147
147
  >
148
148
  <DropdownItem
149
149
  v-for="purchasedDomain of domains"
@@ -167,7 +167,7 @@
167
167
  :style="isMobile ? 'padding-left: 1.5rem; padding-right: 1.5rem;' : ''"
168
168
  >
169
169
  <Button
170
- :label="isSlugEditMode ? 'Set URL' : 'Publish'"
170
+ :label="isSlugEditMode ? setUrlLabel : publishLabel"
171
171
  :variant="isDesignCom ? 'primary' : 'primary-with-icon'"
172
172
  icon="chevron-right-wide"
173
173
  :disabled="isPublishingDisabled"
@@ -177,7 +177,7 @@
177
177
  @on-click="onPublish"
178
178
  />
179
179
  <Button
180
- label="No thanks, maybe later"
180
+ :label="hasAlreadyPurchasedDomainCloseButtonLabel"
181
181
  variant="no-border"
182
182
  size="large"
183
183
  class="tw-my-4"
@@ -200,7 +200,7 @@
200
200
  />
201
201
  </div>
202
202
  <Button
203
- label="VIEW MORE DOMAINS"
203
+ :label="viewMoreDomainLabel"
204
204
  variant="no-border"
205
205
  size="small-medium"
206
206
  class="tw-text-center"
@@ -211,11 +211,13 @@
211
211
  <TextCopyField
212
212
  button-variant="secondary"
213
213
  :text="brandPageUrl"
214
+ :default-copy-button-text="copyLabel"
215
+ :copied-button-text="copySuccessLabel"
214
216
  data-test-brand-page-copy-input
215
217
  @on-click="onCopyUrlClick"
216
218
  />
217
219
  <Button
218
- :label="`View ${brandPageDisplayName}`"
220
+ :label="viewMyWebsiteLabel"
219
221
  :variant="isDesignCom ? 'primary' : 'primary-with-icon'"
220
222
  icon="chevron-right-wide"
221
223
  size="medium"
@@ -246,7 +248,6 @@
246
248
  </div>
247
249
  </template>
248
250
  <script>
249
- import { computed } from 'vue';
250
251
  import Modal from '../../../atoms/components/Modal/Modal.vue';
251
252
  import PublishBrandPageCard from './PublishBrandPageCard.vue';
252
253
  import TextInput from '../../../atoms/components/TextInput/TextInput.vue';
@@ -260,9 +261,7 @@ import SellDomainNameListModal from '../SellDomainNameListModal/SellDomainNameLi
260
261
  import brandCrowdApiClient from '../../clients/brand-crowd-api.client';
261
262
  import Events, { sitePublishedModal } from '../../constants/event-constants';
262
263
  import mediaQueryMixin from '../../mixins/mediaQueryMixin';
263
- import { tr } from '../../../useSharedLibTranslate';
264
-
265
- const headerSubtitle = 'Buy matching domain name for your brand';
264
+ import { publishBrandPageModalTr } from '../../../useSharedLibTranslate';
266
265
 
267
266
  const DOMAIN_TYPES = {
268
267
  slug: 'slug',
@@ -417,8 +416,22 @@ export default {
417
416
  ],
418
417
  setup() {
419
418
  return {
420
- tr,
421
- testMessage: computed(() => tr('publishModal.test')),
419
+ publishBrandPageModalTr,
420
+ sitePublishedLabel: publishBrandPageModalTr('sitePublishedLabel'),
421
+ freePublishCardTitleLabel: publishBrandPageModalTr('freePublishCardTitleLabel'),
422
+ freePublishCardDescriptionLabel: publishBrandPageModalTr('freePublishCardDescriptionLabel'),
423
+ slugInputPlaceholderYourNameLabel: publishBrandPageModalTr('slugInputPlaceholderYourNameLabel'),
424
+ slugInputPlaceholderYourBusinessNameLabel: publishBrandPageModalTr('slugInputPlaceholderYourBusinessNameLabel'),
425
+ freeDomainLabel: publishBrandPageModalTr('freeDomainLabel'),
426
+ purchasedDomainLabel: publishBrandPageModalTr('purchasedDomainLabel'),
427
+ setUrlLabel: publishBrandPageModalTr('setUrlLabel'),
428
+ publishLabel: publishBrandPageModalTr('publishLabel'),
429
+ viewMoreDomainLabel: publishBrandPageModalTr('viewMoreDomainLabel'),
430
+ copyLabel: publishBrandPageModalTr('copyLabel'),
431
+ copySuccessLabel: publishBrandPageModalTr('copySuccessLabel'),
432
+ hasAlreadyPurchasedDomainCloseButtonLabel: publishBrandPageModalTr('hasAlreadyPurchasedDomainCloseButtonLabel'),
433
+ publishedSuccessDescriptionLabel: publishBrandPageModalTr('publishedSuccessDescriptionLabel'),
434
+ selectDomainDropdownPlaceholder: publishBrandPageModalTr('selectDomainDropdownPlaceholder'),
422
435
  };
423
436
  },
424
437
  data() {
@@ -427,7 +440,6 @@ export default {
427
440
  domainTypeValue: this.radioValue,
428
441
  internalSlug: this.brandPageSlug,
429
442
  selectedCustomDomain: this.customDomain,
430
- headerSubtitle,
431
443
  userCurrency: undefined,
432
444
  isModalVisible: false,
433
445
  isLoading: false,
@@ -438,6 +450,24 @@ export default {
438
450
  };
439
451
  },
440
452
  computed: {
453
+ brandPageBaseUrlWithoutHttps() {
454
+ return this.brandPageBaseUrl.replace('https://', '');
455
+ },
456
+ firstTimePublishHeaderLabel() {
457
+ return this.publishBrandPageModalTr('firstTimePublishHeaderLabel', {
458
+ brandPageDisplayName: this.brandPageDisplayName,
459
+ });
460
+ },
461
+ publishSuccessLabel() {
462
+ return this.publishBrandPageModalTr('publishSuccessLabel', {
463
+ brandPageDisplayName: this.brandPageDisplayName,
464
+ });
465
+ },
466
+ viewMyWebsiteLabel() {
467
+ return this.publishBrandPageModalTr('viewMyWebsiteLabel', {
468
+ brandPageDisplayName: this.brandPageDisplayName,
469
+ });
470
+ },
441
471
  allowPublish() {
442
472
  if (this.domainTypeValue === DOMAIN_TYPES.slug) {
443
473
  return this.internalSlug && !this.slugValidationError;
@@ -466,7 +496,9 @@ export default {
466
496
  return !this.allowPublish || this.isPublishing;
467
497
  },
468
498
  getPlaceHolder() {
469
- return this.brandPageType === 'brandContact' ? 'your-name' : 'your-business-name';
499
+ return this.brandPageType === 'brandContact'
500
+ ? this.slugInputPlaceholderYourNameLabel
501
+ : this.slugInputPlaceholderYourBusinessNameLabel;
470
502
  },
471
503
  },
472
504
  watch: {
@@ -0,0 +1,22 @@
1
+ {
2
+ "publishBrandPageModal" : {
3
+ "firstTimePublishHeaderLabel" : "Legen Sie die URL für {{brandPageDisplayName}} fest",
4
+ "sitePublishedLabel" : "Seite veröffentlicht!",
5
+ "publishSuccessLabel" : "Ihr {{brandPageDisplayName}} ist live! Beginnen Sie mit der Nutzung Ihres Links:",
6
+ "freePublishCardTitleLabel" : "Freie Adresse",
7
+ "freePublishCardDescriptionLabel" : "Wählen Sie jetzt eine kostenlose Adresse zur Veröffentlichung aus. Sie können die URL später jederzeit bearbeiten",
8
+ "slugInputPlaceholderYourNameLabel" : "ihr-name",
9
+ "slugInputPlaceholderYourBusinessNameLabel" : "ihr-firmen-name",
10
+ "freeDomainLabel" : "Kostenlose Domain",
11
+ "purchasedDomainLabel" : "Erworbene Domain",
12
+ "setUrlLabel" : "URL festlegen",
13
+ "publishLabel" : "Veröffentlichen",
14
+ "viewMoreDomainLabel" : "WEITERE DOMAINS ANZEIGEN",
15
+ "viewMyWebsiteLabel" : "{{brandPageDisplayName}} anzeigen",
16
+ "copyLabel" : "Kopieren",
17
+ "copySuccessLabel" : "Kopiert!",
18
+ "publishedSuccessDescriptionLabel" : "Kaufen Sie eine passende Domain für Ihre Marke",
19
+ "hasAlreadyPurchasedDomainCloseButtonLabel" : "Nein, danke, vielleicht später",
20
+ "selectDomainDropdownPlaceholder" : "Domain auswählen"
21
+ }
22
+ }
@@ -0,0 +1,22 @@
1
+ {
2
+ "publishBrandPageModal" : {
3
+ "firstTimePublishHeaderLabel" : "Establece la URL para {{brandPageDisplayName}}",
4
+ "sitePublishedLabel" : "¡Sitio publicado!",
5
+ "publishSuccessLabel" : "¡Tu {{brandPageDisplayName}} está activo! Comienza a usar tu enlace:",
6
+ "freePublishCardTitleLabel" : "Dirección gratuita",
7
+ "freePublishCardDescriptionLabel" : "Elige una dirección gratuita para publicar ahora. Siempre puedes editar la URL más tarde",
8
+ "slugInputPlaceholderYourNameLabel" : "tu-nombre",
9
+ "slugInputPlaceholderYourBusinessNameLabel" : "nombre-de-tu-negocio",
10
+ "freeDomainLabel" : "Dominio gratis",
11
+ "purchasedDomainLabel" : "Dominio adquirido",
12
+ "setUrlLabel" : "Establece URL",
13
+ "publishLabel" : "Publicar",
14
+ "viewMoreDomainLabel" : "VER MÁS DOMINIOS",
15
+ "viewMyWebsiteLabel" : "Ver {{brandPageDisplayName}}",
16
+ "copyLabel" : "Copiar",
17
+ "copySuccessLabel" : "¡Copiado!",
18
+ "publishedSuccessDescriptionLabel" : "Compra un nombre de dominio que coincida con tu marca",
19
+ "hasAlreadyPurchasedDomainCloseButtonLabel" : "No gracias, quizás más tarde",
20
+ "selectDomainDropdownPlaceholder" : "Selecciona un nombre de dominio"
21
+ }
22
+ }
@@ -0,0 +1,22 @@
1
+ {
2
+ "publishBrandPageModal" : {
3
+ "firstTimePublishHeaderLabel" : "Définissez l'URL pour {{brandPageDisplayName}}",
4
+ "sitePublishedLabel" : "Site publié !",
5
+ "publishSuccessLabel" : "Votre {{brandPageDisplayName}} est en ligne ! Commencez à utiliser votre lien :",
6
+ "freePublishCardTitleLabel" : "Adresse libre",
7
+ "freePublishCardDescriptionLabel" : "Choisissez une adresse gratuite pour publier maintenant. Vous pouvez toujours modifier l'URL plus tard",
8
+ "slugInputPlaceholderYourNameLabel" : "your-name",
9
+ "slugInputPlaceholderYourBusinessNameLabel" : "nom-de-votre-entreprise",
10
+ "freeDomainLabel" : "Domaine gratuit",
11
+ "purchasedDomainLabel" : "Domaine acheté",
12
+ "setUrlLabel" : "Définir l'URL",
13
+ "publishLabel" : "Publier",
14
+ "viewMoreDomainLabel" : "VOIR PLUS DE NOMS DE DOMAINE",
15
+ "viewMyWebsiteLabel" : "Voir {{brandPageDisplayName}}",
16
+ "copyLabel" : "Copier",
17
+ "copySuccessLabel" : "Copié !",
18
+ "publishedSuccessDescriptionLabel" : "Achetez un nom de domaine correspondant à votre marque",
19
+ "hasAlreadyPurchasedDomainCloseButtonLabel" : "Non merci, peut-être plus tard",
20
+ "selectDomainDropdownPlaceholder" : "Sélectionner un nom de domaine"
21
+ }
22
+ }
@@ -0,0 +1,22 @@
1
+ {
2
+ "publishBrandPageModal": {
3
+ "firstTimePublishHeaderLabel": "Set the URL for {{brandPageDisplayName}}",
4
+ "sitePublishedLabel": "Site published!",
5
+ "publishSuccessLabel": "Your {{brandPageDisplayName}} is live! Start using your link:",
6
+ "freePublishCardTitleLabel": "Free Address",
7
+ "freePublishCardDescriptionLabel": "Choose a free address to publish now. You can always edit the URL later",
8
+ "slugInputPlaceholderYourNameLabel": "your-name",
9
+ "slugInputPlaceholderYourBusinessNameLabel": "your-business-name",
10
+ "freeDomainLabel": "Free domain",
11
+ "purchasedDomainLabel": "Purchased domain",
12
+ "setUrlLabel": "Set URL",
13
+ "publishLabel": "Publish",
14
+ "viewMoreDomainLabel": "VIEW MORE DOMAINS",
15
+ "viewMyWebsiteLabel": "View {{brandPageDisplayName}}",
16
+ "copyLabel": "Copy",
17
+ "copySuccessLabel": "Copied!",
18
+ "publishedSuccessDescriptionLabel": "Buy matching domain name for your brand",
19
+ "hasAlreadyPurchasedDomainCloseButtonLabel": "No thanks, maybe later",
20
+ "selectDomainDropdownPlaceholder": "Select domain name"
21
+ }
22
+ }
@@ -0,0 +1,22 @@
1
+ {
2
+ "publishBrandPageModal" : {
3
+ "firstTimePublishHeaderLabel" : "Defina o URL para {{brandPageDisplayName}}",
4
+ "sitePublishedLabel" : "Site publicado!",
5
+ "publishSuccessLabel" : "A sua página {{brandPageDisplayName}} está ativa! Comece a utilizar o link:",
6
+ "freePublishCardTitleLabel" : "Endereço gratuito",
7
+ "freePublishCardDescriptionLabel" : "Escolha um endereço gratuito para publicar agora. Pode sempre editar o URL mais tarde",
8
+ "slugInputPlaceholderYourNameLabel" : "o-seu-nome",
9
+ "slugInputPlaceholderYourBusinessNameLabel" : "nome-da-sua-empresa",
10
+ "freeDomainLabel" : "Domínio gratuito",
11
+ "purchasedDomainLabel" : "Domínio comprado",
12
+ "setUrlLabel" : "Definir URL",
13
+ "publishLabel" : "Publicar",
14
+ "viewMoreDomainLabel" : "VER MAIS DOMÍNIOS",
15
+ "viewMyWebsiteLabel" : "Ver {{brandPageDisplayName}}",
16
+ "copyLabel" : "Copiar",
17
+ "copySuccessLabel" : "Copiado!",
18
+ "publishedSuccessDescriptionLabel" : "Compre um nome de domínio que corresponda à sua marca",
19
+ "hasAlreadyPurchasedDomainCloseButtonLabel" : "Não, obrigado, talvez mais tarde",
20
+ "selectDomainDropdownPlaceholder" : "Selecionar nome de domínio"
21
+ }
22
+ }