@contractspec/module.notifications 2.3.0 → 2.5.0
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/browser/channels/index.js +187 -1
- package/dist/browser/contracts/index.js +12 -0
- package/dist/browser/entities/index.js +12 -0
- package/dist/browser/i18n/catalogs/en.js +64 -0
- package/dist/browser/i18n/catalogs/es.js +64 -0
- package/dist/browser/i18n/catalogs/fr.js +64 -0
- package/dist/browser/i18n/catalogs/index.js +165 -0
- package/dist/browser/i18n/index.js +225 -0
- package/dist/browser/i18n/keys.js +33 -0
- package/dist/browser/i18n/locale.js +25 -0
- package/dist/browser/i18n/messages.js +186 -0
- package/dist/browser/index.js +279 -3
- package/dist/browser/notifications.capability.js +12 -0
- package/dist/browser/notifications.feature.js +12 -0
- package/dist/browser/templates/index.js +104 -2
- package/dist/channels/index.d.ts +4 -0
- package/dist/channels/index.js +187 -1
- package/dist/contracts/index.js +12 -0
- package/dist/entities/index.js +12 -0
- package/dist/i18n/catalogs/en.d.ts +6 -0
- package/dist/i18n/catalogs/en.js +65 -0
- package/dist/i18n/catalogs/es.d.ts +6 -0
- package/dist/i18n/catalogs/es.js +65 -0
- package/dist/i18n/catalogs/fr.d.ts +6 -0
- package/dist/i18n/catalogs/fr.js +65 -0
- package/dist/i18n/catalogs/index.d.ts +8 -0
- package/dist/i18n/catalogs/index.js +166 -0
- package/dist/i18n/i18n.test.d.ts +1 -0
- package/dist/i18n/index.d.ts +14 -0
- package/dist/i18n/index.js +226 -0
- package/dist/i18n/keys.d.ts +29 -0
- package/dist/i18n/keys.js +34 -0
- package/dist/i18n/locale.d.ts +8 -0
- package/dist/i18n/locale.js +26 -0
- package/dist/i18n/messages.d.ts +14 -0
- package/dist/i18n/messages.js +187 -0
- package/dist/index.js +279 -3
- package/dist/node/channels/index.js +187 -1
- package/dist/node/contracts/index.js +12 -0
- package/dist/node/entities/index.js +12 -0
- package/dist/node/i18n/catalogs/en.js +64 -0
- package/dist/node/i18n/catalogs/es.js +64 -0
- package/dist/node/i18n/catalogs/fr.js +64 -0
- package/dist/node/i18n/catalogs/index.js +165 -0
- package/dist/node/i18n/index.js +225 -0
- package/dist/node/i18n/keys.js +33 -0
- package/dist/node/i18n/locale.js +25 -0
- package/dist/node/i18n/messages.js +186 -0
- package/dist/node/index.js +279 -3
- package/dist/node/notifications.capability.js +12 -0
- package/dist/node/notifications.feature.js +12 -0
- package/dist/node/templates/index.js +104 -2
- package/dist/notifications.capability.js +12 -0
- package/dist/notifications.feature.js +12 -0
- package/dist/templates/index.d.ts +17 -7
- package/dist/templates/index.js +104 -2
- package/package.json +147 -6
|
@@ -0,0 +1,226 @@
|
|
|
1
|
+
// @bun
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __export = (target, all) => {
|
|
4
|
+
for (var name in all)
|
|
5
|
+
__defProp(target, name, {
|
|
6
|
+
get: all[name],
|
|
7
|
+
enumerable: true,
|
|
8
|
+
configurable: true,
|
|
9
|
+
set: (newValue) => all[name] = () => newValue
|
|
10
|
+
});
|
|
11
|
+
};
|
|
12
|
+
var __esm = (fn, res) => () => (fn && (res = fn(fn = 0)), res);
|
|
13
|
+
|
|
14
|
+
// src/i18n/catalogs/en.ts
|
|
15
|
+
import { defineTranslation } from "@contractspec/lib.contracts-spec/translations";
|
|
16
|
+
var enMessages;
|
|
17
|
+
var init_en = __esm(() => {
|
|
18
|
+
enMessages = defineTranslation({
|
|
19
|
+
meta: {
|
|
20
|
+
key: "notifications.messages",
|
|
21
|
+
version: "1.0.0",
|
|
22
|
+
domain: "notifications",
|
|
23
|
+
description: "Template and channel strings for the notifications module",
|
|
24
|
+
owners: ["platform"],
|
|
25
|
+
stability: "experimental"
|
|
26
|
+
},
|
|
27
|
+
locale: "en",
|
|
28
|
+
fallback: "en",
|
|
29
|
+
messages: {
|
|
30
|
+
"template.welcome.name": {
|
|
31
|
+
value: "Welcome",
|
|
32
|
+
description: "Welcome template display name"
|
|
33
|
+
},
|
|
34
|
+
"template.welcome.description": {
|
|
35
|
+
value: "Sent when a user signs up.",
|
|
36
|
+
description: "Welcome template description"
|
|
37
|
+
},
|
|
38
|
+
"template.orgInvite.name": {
|
|
39
|
+
value: "Organization Invitation",
|
|
40
|
+
description: "Org invite template display name"
|
|
41
|
+
},
|
|
42
|
+
"template.orgInvite.description": {
|
|
43
|
+
value: "Sent when a user is invited to an organization.",
|
|
44
|
+
description: "Org invite template description"
|
|
45
|
+
},
|
|
46
|
+
"template.mention.name": {
|
|
47
|
+
value: "Mention",
|
|
48
|
+
description: "Mention template display name"
|
|
49
|
+
},
|
|
50
|
+
"template.mention.description": {
|
|
51
|
+
value: "Sent when a user is mentioned.",
|
|
52
|
+
description: "Mention template description"
|
|
53
|
+
},
|
|
54
|
+
"channel.webhook.noUrl": {
|
|
55
|
+
value: "No webhook URL configured",
|
|
56
|
+
description: "Error when webhook channel has no URL"
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
});
|
|
60
|
+
});
|
|
61
|
+
|
|
62
|
+
// src/i18n/catalogs/fr.ts
|
|
63
|
+
import { defineTranslation as defineTranslation2 } from "@contractspec/lib.contracts-spec/translations";
|
|
64
|
+
var frMessages;
|
|
65
|
+
var init_fr = __esm(() => {
|
|
66
|
+
frMessages = defineTranslation2({
|
|
67
|
+
meta: {
|
|
68
|
+
key: "notifications.messages",
|
|
69
|
+
version: "1.0.0",
|
|
70
|
+
domain: "notifications",
|
|
71
|
+
description: "Template and channel strings (French)",
|
|
72
|
+
owners: ["platform"],
|
|
73
|
+
stability: "experimental"
|
|
74
|
+
},
|
|
75
|
+
locale: "fr",
|
|
76
|
+
fallback: "en",
|
|
77
|
+
messages: {
|
|
78
|
+
"template.welcome.name": {
|
|
79
|
+
value: "Bienvenue",
|
|
80
|
+
description: "Welcome template display name"
|
|
81
|
+
},
|
|
82
|
+
"template.welcome.description": {
|
|
83
|
+
value: "Envoy\xE9 lorsqu'un utilisateur s'inscrit.",
|
|
84
|
+
description: "Welcome template description"
|
|
85
|
+
},
|
|
86
|
+
"template.orgInvite.name": {
|
|
87
|
+
value: "Invitation \xE0 l'organisation",
|
|
88
|
+
description: "Org invite template display name"
|
|
89
|
+
},
|
|
90
|
+
"template.orgInvite.description": {
|
|
91
|
+
value: "Envoy\xE9 lorsqu'un utilisateur est invit\xE9 \xE0 une organisation.",
|
|
92
|
+
description: "Org invite template description"
|
|
93
|
+
},
|
|
94
|
+
"template.mention.name": {
|
|
95
|
+
value: "Mention",
|
|
96
|
+
description: "Mention template display name"
|
|
97
|
+
},
|
|
98
|
+
"template.mention.description": {
|
|
99
|
+
value: "Envoy\xE9 lorsqu'un utilisateur est mentionn\xE9.",
|
|
100
|
+
description: "Mention template description"
|
|
101
|
+
},
|
|
102
|
+
"channel.webhook.noUrl": {
|
|
103
|
+
value: "Aucune URL de webhook configur\xE9e",
|
|
104
|
+
description: "Error when webhook channel has no URL"
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
});
|
|
108
|
+
});
|
|
109
|
+
|
|
110
|
+
// src/i18n/catalogs/es.ts
|
|
111
|
+
import { defineTranslation as defineTranslation3 } from "@contractspec/lib.contracts-spec/translations";
|
|
112
|
+
var esMessages;
|
|
113
|
+
var init_es = __esm(() => {
|
|
114
|
+
esMessages = defineTranslation3({
|
|
115
|
+
meta: {
|
|
116
|
+
key: "notifications.messages",
|
|
117
|
+
version: "1.0.0",
|
|
118
|
+
domain: "notifications",
|
|
119
|
+
description: "Template and channel strings (Spanish)",
|
|
120
|
+
owners: ["platform"],
|
|
121
|
+
stability: "experimental"
|
|
122
|
+
},
|
|
123
|
+
locale: "es",
|
|
124
|
+
fallback: "en",
|
|
125
|
+
messages: {
|
|
126
|
+
"template.welcome.name": {
|
|
127
|
+
value: "Bienvenida",
|
|
128
|
+
description: "Welcome template display name"
|
|
129
|
+
},
|
|
130
|
+
"template.welcome.description": {
|
|
131
|
+
value: "Enviado cuando un usuario se registra.",
|
|
132
|
+
description: "Welcome template description"
|
|
133
|
+
},
|
|
134
|
+
"template.orgInvite.name": {
|
|
135
|
+
value: "Invitaci\xF3n a la organizaci\xF3n",
|
|
136
|
+
description: "Org invite template display name"
|
|
137
|
+
},
|
|
138
|
+
"template.orgInvite.description": {
|
|
139
|
+
value: "Enviado cuando un usuario es invitado a una organizaci\xF3n.",
|
|
140
|
+
description: "Org invite template description"
|
|
141
|
+
},
|
|
142
|
+
"template.mention.name": {
|
|
143
|
+
value: "Menci\xF3n",
|
|
144
|
+
description: "Mention template display name"
|
|
145
|
+
},
|
|
146
|
+
"template.mention.description": {
|
|
147
|
+
value: "Enviado cuando un usuario es mencionado.",
|
|
148
|
+
description: "Mention template description"
|
|
149
|
+
},
|
|
150
|
+
"channel.webhook.noUrl": {
|
|
151
|
+
value: "No se ha configurado una URL de webhook",
|
|
152
|
+
description: "Error when webhook channel has no URL"
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
});
|
|
156
|
+
});
|
|
157
|
+
|
|
158
|
+
// src/i18n/messages.ts
|
|
159
|
+
var exports_messages = {};
|
|
160
|
+
__export(exports_messages, {
|
|
161
|
+
resetI18nRegistry: () => resetI18nRegistry,
|
|
162
|
+
getDefaultI18n: () => getDefaultI18n,
|
|
163
|
+
createNotificationsI18n: () => createNotificationsI18n
|
|
164
|
+
});
|
|
165
|
+
import {
|
|
166
|
+
createI18nFactory
|
|
167
|
+
} from "@contractspec/lib.contracts-spec/translations";
|
|
168
|
+
var factory, createNotificationsI18n, getDefaultI18n, resetI18nRegistry;
|
|
169
|
+
var init_messages = __esm(() => {
|
|
170
|
+
init_en();
|
|
171
|
+
init_fr();
|
|
172
|
+
init_es();
|
|
173
|
+
factory = createI18nFactory({
|
|
174
|
+
specKey: "notifications.messages",
|
|
175
|
+
catalogs: [enMessages, frMessages, esMessages]
|
|
176
|
+
});
|
|
177
|
+
createNotificationsI18n = factory.create;
|
|
178
|
+
getDefaultI18n = factory.getDefault;
|
|
179
|
+
resetI18nRegistry = factory.resetRegistry;
|
|
180
|
+
});
|
|
181
|
+
|
|
182
|
+
// src/i18n/locale.ts
|
|
183
|
+
import {
|
|
184
|
+
DEFAULT_LOCALE,
|
|
185
|
+
SUPPORTED_LOCALES,
|
|
186
|
+
resolveLocale,
|
|
187
|
+
isSupportedLocale
|
|
188
|
+
} from "@contractspec/lib.contracts-spec/translations";
|
|
189
|
+
|
|
190
|
+
// src/i18n/keys.ts
|
|
191
|
+
var TEMPLATE_KEYS = {
|
|
192
|
+
"template.welcome.name": "template.welcome.name",
|
|
193
|
+
"template.welcome.description": "template.welcome.description",
|
|
194
|
+
"template.orgInvite.name": "template.orgInvite.name",
|
|
195
|
+
"template.orgInvite.description": "template.orgInvite.description",
|
|
196
|
+
"template.mention.name": "template.mention.name",
|
|
197
|
+
"template.mention.description": "template.mention.description"
|
|
198
|
+
};
|
|
199
|
+
var CHANNEL_KEYS = {
|
|
200
|
+
"channel.webhook.noUrl": "channel.webhook.noUrl"
|
|
201
|
+
};
|
|
202
|
+
var I18N_KEYS = {
|
|
203
|
+
...TEMPLATE_KEYS,
|
|
204
|
+
...CHANNEL_KEYS
|
|
205
|
+
};
|
|
206
|
+
|
|
207
|
+
// src/i18n/index.ts
|
|
208
|
+
init_messages();
|
|
209
|
+
init_en();
|
|
210
|
+
init_fr();
|
|
211
|
+
init_es();
|
|
212
|
+
export {
|
|
213
|
+
resolveLocale,
|
|
214
|
+
resetI18nRegistry,
|
|
215
|
+
isSupportedLocale,
|
|
216
|
+
getDefaultI18n,
|
|
217
|
+
frMessages,
|
|
218
|
+
esMessages,
|
|
219
|
+
enMessages,
|
|
220
|
+
createNotificationsI18n,
|
|
221
|
+
TEMPLATE_KEYS,
|
|
222
|
+
SUPPORTED_LOCALES,
|
|
223
|
+
I18N_KEYS,
|
|
224
|
+
DEFAULT_LOCALE,
|
|
225
|
+
CHANNEL_KEYS
|
|
226
|
+
};
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Typed message keys for the notifications i18n system.
|
|
3
|
+
*
|
|
4
|
+
* Organized by domain: template (names/descriptions), channel (errors).
|
|
5
|
+
*
|
|
6
|
+
* @module i18n/keys
|
|
7
|
+
*/
|
|
8
|
+
export declare const TEMPLATE_KEYS: {
|
|
9
|
+
readonly 'template.welcome.name': "template.welcome.name";
|
|
10
|
+
readonly 'template.welcome.description': "template.welcome.description";
|
|
11
|
+
readonly 'template.orgInvite.name': "template.orgInvite.name";
|
|
12
|
+
readonly 'template.orgInvite.description': "template.orgInvite.description";
|
|
13
|
+
readonly 'template.mention.name': "template.mention.name";
|
|
14
|
+
readonly 'template.mention.description': "template.mention.description";
|
|
15
|
+
};
|
|
16
|
+
export declare const CHANNEL_KEYS: {
|
|
17
|
+
readonly 'channel.webhook.noUrl': "channel.webhook.noUrl";
|
|
18
|
+
};
|
|
19
|
+
export declare const I18N_KEYS: {
|
|
20
|
+
readonly 'channel.webhook.noUrl': "channel.webhook.noUrl";
|
|
21
|
+
readonly 'template.welcome.name': "template.welcome.name";
|
|
22
|
+
readonly 'template.welcome.description': "template.welcome.description";
|
|
23
|
+
readonly 'template.orgInvite.name': "template.orgInvite.name";
|
|
24
|
+
readonly 'template.orgInvite.description': "template.orgInvite.description";
|
|
25
|
+
readonly 'template.mention.name': "template.mention.name";
|
|
26
|
+
readonly 'template.mention.description': "template.mention.description";
|
|
27
|
+
};
|
|
28
|
+
/** Union type of all valid notifications i18n keys */
|
|
29
|
+
export type NotificationsMessageKey = keyof typeof I18N_KEYS;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
// @bun
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __export = (target, all) => {
|
|
4
|
+
for (var name in all)
|
|
5
|
+
__defProp(target, name, {
|
|
6
|
+
get: all[name],
|
|
7
|
+
enumerable: true,
|
|
8
|
+
configurable: true,
|
|
9
|
+
set: (newValue) => all[name] = () => newValue
|
|
10
|
+
});
|
|
11
|
+
};
|
|
12
|
+
var __esm = (fn, res) => () => (fn && (res = fn(fn = 0)), res);
|
|
13
|
+
|
|
14
|
+
// src/i18n/keys.ts
|
|
15
|
+
var TEMPLATE_KEYS = {
|
|
16
|
+
"template.welcome.name": "template.welcome.name",
|
|
17
|
+
"template.welcome.description": "template.welcome.description",
|
|
18
|
+
"template.orgInvite.name": "template.orgInvite.name",
|
|
19
|
+
"template.orgInvite.description": "template.orgInvite.description",
|
|
20
|
+
"template.mention.name": "template.mention.name",
|
|
21
|
+
"template.mention.description": "template.mention.description"
|
|
22
|
+
};
|
|
23
|
+
var CHANNEL_KEYS = {
|
|
24
|
+
"channel.webhook.noUrl": "channel.webhook.noUrl"
|
|
25
|
+
};
|
|
26
|
+
var I18N_KEYS = {
|
|
27
|
+
...TEMPLATE_KEYS,
|
|
28
|
+
...CHANNEL_KEYS
|
|
29
|
+
};
|
|
30
|
+
export {
|
|
31
|
+
TEMPLATE_KEYS,
|
|
32
|
+
I18N_KEYS,
|
|
33
|
+
CHANNEL_KEYS
|
|
34
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Locale utilities for the notifications package.
|
|
3
|
+
*
|
|
4
|
+
* Re-exported from the shared i18n factory in contracts-spec.
|
|
5
|
+
*
|
|
6
|
+
* @module i18n/locale
|
|
7
|
+
*/
|
|
8
|
+
export { DEFAULT_LOCALE, SUPPORTED_LOCALES, resolveLocale, isSupportedLocale, type SupportedLocale, } from '@contractspec/lib.contracts-spec/translations';
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
// @bun
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __export = (target, all) => {
|
|
4
|
+
for (var name in all)
|
|
5
|
+
__defProp(target, name, {
|
|
6
|
+
get: all[name],
|
|
7
|
+
enumerable: true,
|
|
8
|
+
configurable: true,
|
|
9
|
+
set: (newValue) => all[name] = () => newValue
|
|
10
|
+
});
|
|
11
|
+
};
|
|
12
|
+
var __esm = (fn, res) => () => (fn && (res = fn(fn = 0)), res);
|
|
13
|
+
|
|
14
|
+
// src/i18n/locale.ts
|
|
15
|
+
import {
|
|
16
|
+
DEFAULT_LOCALE,
|
|
17
|
+
SUPPORTED_LOCALES,
|
|
18
|
+
resolveLocale,
|
|
19
|
+
isSupportedLocale
|
|
20
|
+
} from "@contractspec/lib.contracts-spec/translations";
|
|
21
|
+
export {
|
|
22
|
+
resolveLocale,
|
|
23
|
+
isSupportedLocale,
|
|
24
|
+
SUPPORTED_LOCALES,
|
|
25
|
+
DEFAULT_LOCALE
|
|
26
|
+
};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Translation helper for the notifications package.
|
|
3
|
+
* @module i18n/messages
|
|
4
|
+
*/
|
|
5
|
+
import { type I18nInstance } from '@contractspec/lib.contracts-spec/translations';
|
|
6
|
+
import type { NotificationsMessageKey } from './keys';
|
|
7
|
+
/** I18n instance type for the notifications package. */
|
|
8
|
+
export type NotificationsI18n = I18nInstance<NotificationsMessageKey>;
|
|
9
|
+
/** Create an i18n instance for a given locale. */
|
|
10
|
+
export declare const createNotificationsI18n: (optionsLocale?: string, runtimeLocale?: string) => I18nInstance<"template.welcome.name" | "template.welcome.description" | "template.orgInvite.name" | "template.orgInvite.description" | "template.mention.name" | "template.mention.description" | "channel.webhook.noUrl">;
|
|
11
|
+
/** Create a default (English) i18n instance. */
|
|
12
|
+
export declare const getDefaultI18n: () => I18nInstance<"template.welcome.name" | "template.welcome.description" | "template.orgInvite.name" | "template.orgInvite.description" | "template.mention.name" | "template.mention.description" | "channel.webhook.noUrl">;
|
|
13
|
+
/** Reset the shared registry (useful for testing). @internal */
|
|
14
|
+
export declare const resetI18nRegistry: () => void;
|
|
@@ -0,0 +1,187 @@
|
|
|
1
|
+
// @bun
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __export = (target, all) => {
|
|
4
|
+
for (var name in all)
|
|
5
|
+
__defProp(target, name, {
|
|
6
|
+
get: all[name],
|
|
7
|
+
enumerable: true,
|
|
8
|
+
configurable: true,
|
|
9
|
+
set: (newValue) => all[name] = () => newValue
|
|
10
|
+
});
|
|
11
|
+
};
|
|
12
|
+
var __esm = (fn, res) => () => (fn && (res = fn(fn = 0)), res);
|
|
13
|
+
|
|
14
|
+
// src/i18n/catalogs/en.ts
|
|
15
|
+
import { defineTranslation } from "@contractspec/lib.contracts-spec/translations";
|
|
16
|
+
var enMessages;
|
|
17
|
+
var init_en = __esm(() => {
|
|
18
|
+
enMessages = defineTranslation({
|
|
19
|
+
meta: {
|
|
20
|
+
key: "notifications.messages",
|
|
21
|
+
version: "1.0.0",
|
|
22
|
+
domain: "notifications",
|
|
23
|
+
description: "Template and channel strings for the notifications module",
|
|
24
|
+
owners: ["platform"],
|
|
25
|
+
stability: "experimental"
|
|
26
|
+
},
|
|
27
|
+
locale: "en",
|
|
28
|
+
fallback: "en",
|
|
29
|
+
messages: {
|
|
30
|
+
"template.welcome.name": {
|
|
31
|
+
value: "Welcome",
|
|
32
|
+
description: "Welcome template display name"
|
|
33
|
+
},
|
|
34
|
+
"template.welcome.description": {
|
|
35
|
+
value: "Sent when a user signs up.",
|
|
36
|
+
description: "Welcome template description"
|
|
37
|
+
},
|
|
38
|
+
"template.orgInvite.name": {
|
|
39
|
+
value: "Organization Invitation",
|
|
40
|
+
description: "Org invite template display name"
|
|
41
|
+
},
|
|
42
|
+
"template.orgInvite.description": {
|
|
43
|
+
value: "Sent when a user is invited to an organization.",
|
|
44
|
+
description: "Org invite template description"
|
|
45
|
+
},
|
|
46
|
+
"template.mention.name": {
|
|
47
|
+
value: "Mention",
|
|
48
|
+
description: "Mention template display name"
|
|
49
|
+
},
|
|
50
|
+
"template.mention.description": {
|
|
51
|
+
value: "Sent when a user is mentioned.",
|
|
52
|
+
description: "Mention template description"
|
|
53
|
+
},
|
|
54
|
+
"channel.webhook.noUrl": {
|
|
55
|
+
value: "No webhook URL configured",
|
|
56
|
+
description: "Error when webhook channel has no URL"
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
});
|
|
60
|
+
});
|
|
61
|
+
|
|
62
|
+
// src/i18n/catalogs/fr.ts
|
|
63
|
+
import { defineTranslation as defineTranslation2 } from "@contractspec/lib.contracts-spec/translations";
|
|
64
|
+
var frMessages;
|
|
65
|
+
var init_fr = __esm(() => {
|
|
66
|
+
frMessages = defineTranslation2({
|
|
67
|
+
meta: {
|
|
68
|
+
key: "notifications.messages",
|
|
69
|
+
version: "1.0.0",
|
|
70
|
+
domain: "notifications",
|
|
71
|
+
description: "Template and channel strings (French)",
|
|
72
|
+
owners: ["platform"],
|
|
73
|
+
stability: "experimental"
|
|
74
|
+
},
|
|
75
|
+
locale: "fr",
|
|
76
|
+
fallback: "en",
|
|
77
|
+
messages: {
|
|
78
|
+
"template.welcome.name": {
|
|
79
|
+
value: "Bienvenue",
|
|
80
|
+
description: "Welcome template display name"
|
|
81
|
+
},
|
|
82
|
+
"template.welcome.description": {
|
|
83
|
+
value: "Envoy\xE9 lorsqu'un utilisateur s'inscrit.",
|
|
84
|
+
description: "Welcome template description"
|
|
85
|
+
},
|
|
86
|
+
"template.orgInvite.name": {
|
|
87
|
+
value: "Invitation \xE0 l'organisation",
|
|
88
|
+
description: "Org invite template display name"
|
|
89
|
+
},
|
|
90
|
+
"template.orgInvite.description": {
|
|
91
|
+
value: "Envoy\xE9 lorsqu'un utilisateur est invit\xE9 \xE0 une organisation.",
|
|
92
|
+
description: "Org invite template description"
|
|
93
|
+
},
|
|
94
|
+
"template.mention.name": {
|
|
95
|
+
value: "Mention",
|
|
96
|
+
description: "Mention template display name"
|
|
97
|
+
},
|
|
98
|
+
"template.mention.description": {
|
|
99
|
+
value: "Envoy\xE9 lorsqu'un utilisateur est mentionn\xE9.",
|
|
100
|
+
description: "Mention template description"
|
|
101
|
+
},
|
|
102
|
+
"channel.webhook.noUrl": {
|
|
103
|
+
value: "Aucune URL de webhook configur\xE9e",
|
|
104
|
+
description: "Error when webhook channel has no URL"
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
});
|
|
108
|
+
});
|
|
109
|
+
|
|
110
|
+
// src/i18n/catalogs/es.ts
|
|
111
|
+
import { defineTranslation as defineTranslation3 } from "@contractspec/lib.contracts-spec/translations";
|
|
112
|
+
var esMessages;
|
|
113
|
+
var init_es = __esm(() => {
|
|
114
|
+
esMessages = defineTranslation3({
|
|
115
|
+
meta: {
|
|
116
|
+
key: "notifications.messages",
|
|
117
|
+
version: "1.0.0",
|
|
118
|
+
domain: "notifications",
|
|
119
|
+
description: "Template and channel strings (Spanish)",
|
|
120
|
+
owners: ["platform"],
|
|
121
|
+
stability: "experimental"
|
|
122
|
+
},
|
|
123
|
+
locale: "es",
|
|
124
|
+
fallback: "en",
|
|
125
|
+
messages: {
|
|
126
|
+
"template.welcome.name": {
|
|
127
|
+
value: "Bienvenida",
|
|
128
|
+
description: "Welcome template display name"
|
|
129
|
+
},
|
|
130
|
+
"template.welcome.description": {
|
|
131
|
+
value: "Enviado cuando un usuario se registra.",
|
|
132
|
+
description: "Welcome template description"
|
|
133
|
+
},
|
|
134
|
+
"template.orgInvite.name": {
|
|
135
|
+
value: "Invitaci\xF3n a la organizaci\xF3n",
|
|
136
|
+
description: "Org invite template display name"
|
|
137
|
+
},
|
|
138
|
+
"template.orgInvite.description": {
|
|
139
|
+
value: "Enviado cuando un usuario es invitado a una organizaci\xF3n.",
|
|
140
|
+
description: "Org invite template description"
|
|
141
|
+
},
|
|
142
|
+
"template.mention.name": {
|
|
143
|
+
value: "Menci\xF3n",
|
|
144
|
+
description: "Mention template display name"
|
|
145
|
+
},
|
|
146
|
+
"template.mention.description": {
|
|
147
|
+
value: "Enviado cuando un usuario es mencionado.",
|
|
148
|
+
description: "Mention template description"
|
|
149
|
+
},
|
|
150
|
+
"channel.webhook.noUrl": {
|
|
151
|
+
value: "No se ha configurado una URL de webhook",
|
|
152
|
+
description: "Error when webhook channel has no URL"
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
});
|
|
156
|
+
});
|
|
157
|
+
|
|
158
|
+
// src/i18n/messages.ts
|
|
159
|
+
var exports_messages = {};
|
|
160
|
+
__export(exports_messages, {
|
|
161
|
+
resetI18nRegistry: () => resetI18nRegistry,
|
|
162
|
+
getDefaultI18n: () => getDefaultI18n,
|
|
163
|
+
createNotificationsI18n: () => createNotificationsI18n
|
|
164
|
+
});
|
|
165
|
+
import {
|
|
166
|
+
createI18nFactory
|
|
167
|
+
} from "@contractspec/lib.contracts-spec/translations";
|
|
168
|
+
var factory, createNotificationsI18n, getDefaultI18n, resetI18nRegistry;
|
|
169
|
+
var init_messages = __esm(() => {
|
|
170
|
+
init_en();
|
|
171
|
+
init_fr();
|
|
172
|
+
init_es();
|
|
173
|
+
factory = createI18nFactory({
|
|
174
|
+
specKey: "notifications.messages",
|
|
175
|
+
catalogs: [enMessages, frMessages, esMessages]
|
|
176
|
+
});
|
|
177
|
+
createNotificationsI18n = factory.create;
|
|
178
|
+
getDefaultI18n = factory.getDefault;
|
|
179
|
+
resetI18nRegistry = factory.resetRegistry;
|
|
180
|
+
});
|
|
181
|
+
init_messages();
|
|
182
|
+
|
|
183
|
+
export {
|
|
184
|
+
resetI18nRegistry,
|
|
185
|
+
getDefaultI18n,
|
|
186
|
+
createNotificationsI18n
|
|
187
|
+
};
|