@dative-gpi/foundation-shared-components 1.0.124 → 1.0.125

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.
@@ -205,31 +205,31 @@ export default defineComponent({
205
205
  const items = [
206
206
  {
207
207
  id: EntityType.Model,
208
- label: $tr("ui.entity-type.models", "Models")
208
+ label: $tr("ui.common.models", "Models")
209
209
  },
210
210
  {
211
211
  id: EntityType.Group,
212
- label: $tr("ui.entity-type.groups", "Groups")
212
+ label: $tr("ui.common.groups", "Groups")
213
213
  },
214
214
  {
215
215
  id: EntityType.Location,
216
- label: $tr("ui.entity-type.locations", "Locations")
216
+ label: $tr("ui.common.locations", "Locations")
217
217
  },
218
218
  {
219
219
  id: EntityType.Device,
220
- label: $tr("ui.entity-type.devices", "Devices")
220
+ label: $tr("ui.common.devices", "Devices")
221
221
  },
222
222
  {
223
223
  id: EntityType.User,
224
- label: $tr("ui.entity-type.users", "Users")
224
+ label: $tr("ui.common.users", "Users")
225
225
  },
226
226
  {
227
227
  id: EntityType.Dashboard,
228
- label: $tr("ui.entity-type.dashboards", "Dashboards")
228
+ label: $tr("ui.common.dashboards", "Dashboards")
229
229
  },
230
230
  {
231
231
  id: EntityType.Folder,
232
- label: $tr("ui.entity-type.folders", "Folders")
232
+ label: $tr("ui.common.folders", "Folders")
233
233
  }
234
234
  ];
235
235
 
@@ -1,6 +1,6 @@
1
1
  <template>
2
2
  <FSAutocompleteField
3
- :label="label ?? $tr('autcomplete.display-as.label','Display as')"
3
+ :label="label ?? $tr('autocomplete.display-as.label','Display as')"
4
4
  :items="displayAsItems"
5
5
  :modelValue="modelValue"
6
6
  @update:modelValue="$emit('update:modelValue', $event)"
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@dative-gpi/foundation-shared-components",
3
3
  "sideEffects": false,
4
- "version": "1.0.124",
4
+ "version": "1.0.125",
5
5
  "description": "",
6
6
  "publishConfig": {
7
7
  "access": "public"
@@ -10,8 +10,8 @@
10
10
  "author": "",
11
11
  "license": "ISC",
12
12
  "dependencies": {
13
- "@dative-gpi/foundation-shared-domain": "1.0.124",
14
- "@dative-gpi/foundation-shared-services": "1.0.124"
13
+ "@dative-gpi/foundation-shared-domain": "1.0.125",
14
+ "@dative-gpi/foundation-shared-services": "1.0.125"
15
15
  },
16
16
  "peerDependencies": {
17
17
  "@dative-gpi/bones-ui": "^1.0.0",
@@ -35,5 +35,5 @@
35
35
  "sass": "1.71.1",
36
36
  "sass-loader": "13.3.2"
37
37
  },
38
- "gitHead": "dbe55d5165ef715e8debfa3e459c0d76da412f2d"
38
+ "gitHead": "fe376a2d6846d6830925a36d0d7a54ec6e71a141"
39
39
  }
@@ -112,7 +112,7 @@ export const displayAsLabel = (display: DisplayAs | number): string => {
112
112
  switch (display) {
113
113
  case DisplayAs.Bars: return $tr("ui.common.bars", "Bars");
114
114
  case DisplayAs.Lines: return $tr("ui.common.lines", "Lines");
115
- case DisplayAs.Points: return $tr("ui.common.point", "Points");
115
+ case DisplayAs.Points: return $tr("ui.common.points", "Points");
116
116
  default: return $tr("ui.common.none", "None");
117
117
  }
118
118
  };
@@ -179,7 +179,7 @@ export const serieTypeLabel = (serieType: SerieType): string => {
179
179
  case SerieType.Operation: return $tr("ui.common.operation", "Operation");
180
180
  case SerieType.Planning: return $tr("ui.common.planning", "Planning");
181
181
  case SerieType.ScatterPlot: return $tr("ui.common.scatter-plot", "Scatter plot");
182
- case SerieType.Top: return $tr("ui.common.top", "Top");
182
+ case SerieType.Top: return $tr("ui.serie-type.top", "Top");
183
183
  case SerieType.Bars: return $tr("ui.common.bars", "Bars");
184
184
  case SerieType.StackedBars: return $tr("ui.common.stacked-bars", "Stacked bars");
185
185
  case SerieType.Pie: return $tr("ui.common.pie", "Pie");
@@ -187,7 +187,7 @@ export const serieTypeLabel = (serieType: SerieType): string => {
187
187
  case SerieType.Slider: return $tr("ui.common.slider", "Slider");
188
188
  case SerieType.Gauge: return $tr("ui.common.gauge", "Gauge");
189
189
  case SerieType.ScoreCard: return $tr("ui.common.score-card", "Score card");
190
- case SerieType.Table: return $tr("ui.common.table", "Table");
190
+ case SerieType.Table: return $tr("ui.serie-type.table", "Table");
191
191
  default: return "";
192
192
  }
193
193
  };
package/utils/sort.ts CHANGED
@@ -23,7 +23,7 @@ export const alphanumericSort = (a: any, b: any) => {
23
23
  if (b == null) {
24
24
  return 1;
25
25
  }
26
- a = asString(a);
27
- b = asString(b);
26
+ a = asString(a).trim();
27
+ b = asString(b).trim();
28
28
  return a.localeCompare(b, undefined, { numeric: true });
29
29
  };
package/utils/time.ts CHANGED
@@ -5,13 +5,13 @@ import { TimeUnit } from "@dative-gpi/foundation-shared-domain/enums"
5
5
  const { $tr } = useTranslationsProvider();
6
6
 
7
7
  export const timeSteps = [
8
- { id: TimeUnit.Second, label: $tr("ui.time-step.second.singular", "Second"), plural: $tr("ui.time-step.second.plural", "Seconds") },
9
- { id: TimeUnit.Minute, label: $tr("ui.time-step.minute.singular", "Minute"), plural: $tr("ui.time-step.minute.plural", "Minutes") },
10
- { id: TimeUnit.Hour, label: $tr("ui.time-step.hour.singular", "Hour"), plural: $tr("ui.time-step.hour.plural", "Hours") },
11
- { id: TimeUnit.Day, label: $tr("ui.time-step.day.singular", "Day"), plural: $tr("ui.time-step.day.plural", "Days") },
12
- { id: TimeUnit.Week, label: $tr("ui.time-step.week.singular", "Week"), plural: $tr("ui.time-step.week.plural", "Weeks") },
13
- { id: TimeUnit.Month, label: $tr("ui.time-step.month.singular", "Month"), plural: $tr("ui.time-step.month.plural", "Months") },
14
- { id: TimeUnit.Year, label: $tr("ui.time-step.year.singular", "Year"), plural: $tr("ui.time-step.year.plural", "Years") },
8
+ { id: TimeUnit.Second, label: $tr("ui.common.second", "Second"), plural: $tr("ui.common.seconds", "Seconds") },
9
+ { id: TimeUnit.Minute, label: $tr("ui.common.minute", "Minute"), plural: $tr("ui.common.minutes", "Minutes") },
10
+ { id: TimeUnit.Hour, label: $tr("ui.common.hour", "Hour"), plural: $tr("ui.common.hours", "Hours") },
11
+ { id: TimeUnit.Day, label: $tr("ui.common.day", "Day"), plural: $tr("ui.common.days", "Days") },
12
+ { id: TimeUnit.Week, label: $tr("ui.common.week", "Week"), plural: $tr("ui.common.weeks", "Weeks") },
13
+ { id: TimeUnit.Month, label: $tr("ui.common.month", "Month"), plural: $tr("ui.common.months", "Months") },
14
+ { id: TimeUnit.Year, label: $tr("ui.common.year", "Year"), plural: $tr("ui.common.years", "Years") },
15
15
  ];
16
16
 
17
17
  export const timeStepToString = (value: { value: number, unit: TimeUnit } | null): string => {
@@ -29,11 +29,11 @@ export const timeStepToString = (value: { value: number, unit: TimeUnit } | null
29
29
 
30
30
  // TODO : remove everything below this line
31
31
  export const timeScale: any[] = [
32
- { id: 1, label: $tr("ui.time-field.second.singular", "Second"), plural: $tr("ui.time-field.second.plural", "Seconds") },
33
- { id: 60, label: $tr("ui.time-field.minute.singular", "Minute"), plural: $tr("ui.time-field.minute.plural", "Minutes") },
34
- { id: 3600, label: $tr("ui.time-field.hour.singular", "Hour"), plural: $tr("ui.time-field.hour.plural", "Hours") },
35
- { id: 86400, label: $tr("ui.time-field.day.singular", "Day"), plural: $tr("ui.time-field.day.plural", "Days") },
36
- { id: 604800, label: $tr("ui.time-field.week.singular", "Week"), plural: $tr("ui.time-field.week.plural", "Weeks") },
32
+ { id: 1, label: $tr("ui.common.second", "Second"), plural: $tr("ui.common.seconds", "Seconds") },
33
+ { id: 60, label: $tr("ui.common.minute", "Minute"), plural: $tr("ui.common.minutes", "Minutes") },
34
+ { id: 3600, label: $tr("ui.common.hour", "Hour"), plural: $tr("ui.common.hours", "Hours") },
35
+ { id: 86400, label: $tr("ui.common.day", "Day"), plural: $tr("ui.common.days", "Days") },
36
+ { id: 604800, label: $tr("ui.common.week", "Week"), plural: $tr("ui.common.weeks", "Weeks") },
37
37
  ];
38
38
 
39
39
  export const getTimeScaleIndex = (value: number): number => {