@mundogamernetwork/shared-ui 1.8.0 → 1.8.2
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/components/keys/KeyBrowser.vue +16 -10
- package/locales/de.json +1 -1
- package/locales/en.json +1 -1
- package/locales/pt-BR.json +1 -1
- package/locales/ro.json +1 -1
- package/package.json +1 -1
- package/pages/key-campaigns/redeem-key.vue +3 -0
|
@@ -147,12 +147,16 @@ function handleRequestKey(pool: KeyPool) {
|
|
|
147
147
|
|
|
148
148
|
// ─── Notification prompt ──────────────────────────────────────────────────────
|
|
149
149
|
|
|
150
|
+
// account-management/notification-preferences is the canonical, cross-product
|
|
151
|
+
// preferences endpoint (network-accounts, community-frontend, mobile all use
|
|
152
|
+
// it). Called with no mg_network_system_id so the row is global — one opt-in
|
|
153
|
+
// covers key_campaigns alerts on TV/community/agency alike, matching how the
|
|
154
|
+
// rest of the notification-preferences system already behaves.
|
|
150
155
|
async function _checkNotifPrompt() {
|
|
151
156
|
try {
|
|
152
|
-
const res = await httpService.get('/
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
if (res.data?.data === null) {
|
|
157
|
+
const res = await httpService.get('/account-management/notification-preferences')
|
|
158
|
+
const category = res.data?.data?.categories?.find((c: any) => c.category === 'key_campaigns')
|
|
159
|
+
if (category && category.is_set === false) {
|
|
156
160
|
notifPromptVisible.value = true
|
|
157
161
|
}
|
|
158
162
|
} catch {
|
|
@@ -163,12 +167,14 @@ async function _checkNotifPrompt() {
|
|
|
163
167
|
async function enableNotifAlerts() {
|
|
164
168
|
notifSaving.value = true
|
|
165
169
|
try {
|
|
166
|
-
await httpService.
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
170
|
+
await httpService.post('/account-management/notification-preferences', {
|
|
171
|
+
preferences: [{
|
|
172
|
+
category: 'key_campaigns',
|
|
173
|
+
enabled: true,
|
|
174
|
+
channel_email: true,
|
|
175
|
+
channel_push: true,
|
|
176
|
+
channel_in_app: true,
|
|
177
|
+
}],
|
|
172
178
|
})
|
|
173
179
|
} catch {
|
|
174
180
|
// ignore — user can configure later in settings
|
package/locales/de.json
CHANGED
|
@@ -151,7 +151,7 @@
|
|
|
151
151
|
"description_optional": "Beschreibung (optional)",
|
|
152
152
|
"description_placeholder": "Erzähl uns etwas über deinen Kanal...",
|
|
153
153
|
"sending": "Wird gesendet...",
|
|
154
|
-
"request_sent": "Anfrage gesendet!
|
|
154
|
+
"request_sent": "Anfrage gesendet! Wir informieren dich per E-Mail, sobald sie geprüft wurde.",
|
|
155
155
|
"error_loading": "Kampagnendaten konnten nicht geladen werden.",
|
|
156
156
|
"error_request": "Anfrage konnte nicht gesendet werden. Bitte erneut versuchen.",
|
|
157
157
|
"error_reveal": "Schlüssel konnte nicht enthüllt werden.",
|
package/locales/en.json
CHANGED
|
@@ -151,7 +151,7 @@
|
|
|
151
151
|
"description_optional": "Description (optional)",
|
|
152
152
|
"description_placeholder": "Tell us a bit about your channel or content plans...",
|
|
153
153
|
"sending": "Sending...",
|
|
154
|
-
"request_sent": "Request sent!
|
|
154
|
+
"request_sent": "Request sent! We'll email you once it's reviewed.",
|
|
155
155
|
"error_loading": "Failed to load campaign data.",
|
|
156
156
|
"error_request": "Could not submit request. Please try again.",
|
|
157
157
|
"error_reveal": "Could not reveal key. Please try again.",
|
package/locales/pt-BR.json
CHANGED
|
@@ -151,7 +151,7 @@
|
|
|
151
151
|
"description_optional": "Descrição (opcional)",
|
|
152
152
|
"description_placeholder": "Conte um pouco sobre seu canal ou planos de conteúdo...",
|
|
153
153
|
"sending": "Enviando...",
|
|
154
|
-
"request_sent": "Solicitação enviada!
|
|
154
|
+
"request_sent": "Solicitação enviada! Você será avisado por e-mail assim que for revisada.",
|
|
155
155
|
"error_loading": "Falha ao carregar dados da campanha.",
|
|
156
156
|
"error_request": "Não foi possível enviar a solicitação. Tente novamente.",
|
|
157
157
|
"error_reveal": "Não foi possível revelar a chave. Tente novamente.",
|
package/locales/ro.json
CHANGED
|
@@ -151,7 +151,7 @@
|
|
|
151
151
|
"description_optional": "Descriere (opțional)",
|
|
152
152
|
"description_placeholder": "Spune-ne puțin despre canalul tău...",
|
|
153
153
|
"sending": "Se trimite...",
|
|
154
|
-
"request_sent": "Cerere trimisă!
|
|
154
|
+
"request_sent": "Cerere trimisă! Te vom anunța prin e-mail după ce este analizată.",
|
|
155
155
|
"error_loading": "Eroare la încărcarea datelor campaniei.",
|
|
156
156
|
"error_request": "Nu s-a putut trimite cererea. Încearcă din nou.",
|
|
157
157
|
"error_reveal": "Nu s-a putut dezvălui cheia.",
|
package/package.json
CHANGED
|
@@ -203,6 +203,9 @@ function goBack() {
|
|
|
203
203
|
<div v-else-if="success" class="state success">
|
|
204
204
|
<MGIcon icon="check-circle" size="3x" />
|
|
205
205
|
<p>{{ $t("keys.campaigns.request_sent") }}</p>
|
|
206
|
+
<button class="btn" @click="goBack">
|
|
207
|
+
{{ $t("keys.campaigns.back_to_campaign") }}
|
|
208
|
+
</button>
|
|
206
209
|
</div>
|
|
207
210
|
|
|
208
211
|
<div v-else class="form-content">
|