@tekkare/romulus 0.1.111 → 0.1.112

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/module.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "compatibility": {
5
5
  "nuxt": ">=3.16.0"
6
6
  },
7
- "version": "0.1.110",
7
+ "version": "0.1.111",
8
8
  "builder": {
9
9
  "@nuxt/module-builder": "0.8.4",
10
10
  "unbuild": "2.0.0"
@@ -78,6 +78,10 @@ const FR = {
78
78
  refusal: {
79
79
  too_broad: (n: string, max: string) =>
80
80
  `Cette vue est trop large pour être surveillée : ${n} documents, alors qu’une alerte en suit ${max} au maximum. Resserrez le périmètre de la vue, sur une marque ou une molécule par exemple.`,
81
+ too_many_brands: (n: string, max: string) =>
82
+ `Cette vue couvre ${n} marques, alors qu'une alerte en suit ${max} au maximum. Une veille se fait sur un portefeuille ou sur des concurrents : resserrez la vue sur les marques qui vous intéressent.`,
83
+ too_heavy: (n: string) =>
84
+ `Ce périmètre demande trop de mémoire pour être suivi champ par champ (${n} Mo). Réduisez la vue, ou choisissez les champs à suivre plutôt que « n'importe quel changement ».`,
81
85
  collapse: (n: string) =>
82
86
  `Les résultats se sont effondrés (${n} documents restants) : c’est un incident sur les données, pas une nouvelle. Rien n’a été signalé, l’alerte reprendra au prochain passage sain.`,
83
87
  growth: (n: string) =>
@@ -131,6 +135,10 @@ const EN = {
131
135
  refusal: {
132
136
  too_broad: (n: string, max: string) =>
133
137
  `This view is too wide to watch: ${n} documents, where an alert tracks at most ${max}. Narrow the view, to one brand or molecule for instance.`,
138
+ too_many_brands: (n: string, max: string) =>
139
+ `This view covers ${n} brands, where an alert tracks at most ${max}. Monitoring is done on a portfolio or on competitors: narrow the view to the brands you care about.`,
140
+ too_heavy: (n: string) =>
141
+ `This scope needs too much memory to be tracked field by field (${n} MB). Narrow the view, or pick the fields to watch instead of "any change".`,
134
142
  collapse: (n: string) =>
135
143
  `Results collapsed (${n} documents left): that is a data incident, not news. Nothing was reported; the alert resumes on the next healthy run.`,
136
144
  growth: (n: string) =>
@@ -169,9 +177,11 @@ const refusal = computed<string | null>(() => {
169
177
  if (typeof sentence === 'string') return sentence
170
178
 
171
179
  const count = number(props.alert.lastErrorCount ?? 0)
172
- return kind === 'too_broad'
173
- ? sentence(count, number(props.alert.maxTracked ?? 10000))
174
- : sentence(count)
180
+ // Deux plafonds se disent avec leur valeur : le nombre de documents et le
181
+ // nombre de marques.
182
+ if (kind === 'too_broad') return sentence(count, number(props.alert.maxTracked ?? 10000))
183
+ if (kind === 'too_many_brands') return sentence(count, number(props.alert.maxBrands ?? 20))
184
+ return sentence(count)
175
185
  })
176
186
 
177
187
  /** Les etats qui demandent une explication, pas seulement une pastille. */
@@ -54,6 +54,8 @@ export interface RmAlert {
54
54
  lastErrorCount?: number | null;
55
55
  /** Plafond de documents qu'une alerte peut suivre. */
56
56
  maxTracked?: number | null;
57
+ /** Plafond de marques distinctes qu'une alerte peut suivre. */
58
+ maxBrands?: number | null;
57
59
  lastRunAt?: string | null;
58
60
  /** Date de la derniere remise a zero de la reference, s'il y en a eu une. */
59
61
  reseededAt?: string | null;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tekkare/romulus",
3
- "version": "0.1.111",
3
+ "version": "0.1.112",
4
4
  "description": "Romulus Design System - Nuxt module by Tekkare",
5
5
  "license": "MIT",
6
6
  "type": "module",