@plumile/backoffice-react 0.1.125 → 0.1.131

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 (68) hide show
  1. package/lib/esm/auth/login/loginPage.css.js +1 -0
  2. package/lib/esm/auth/login/loginPage.css.js.map +1 -1
  3. package/lib/esm/components/backoffice/billing/BackofficeBillingUsageChart.js +37 -26
  4. package/lib/esm/components/backoffice/billing/BackofficeBillingUsageChart.js.map +1 -1
  5. package/lib/esm/components/backoffice/detail/BackofficeDetailBadgeRow.js +2 -1
  6. package/lib/esm/components/backoffice/detail/BackofficeDetailBadgeRow.js.map +1 -1
  7. package/lib/esm/components/backoffice/detail/BackofficeKpiStrip.js +23 -23
  8. package/lib/esm/components/backoffice/detail/BackofficeKpiStrip.js.map +1 -1
  9. package/lib/esm/components/backoffice/detail/backofficeDetailRelationLink.css.js +1 -0
  10. package/lib/esm/components/backoffice/detail/backofficeKpiStrip.css.js +14 -2
  11. package/lib/esm/components/backoffice/detail/backofficeKpiStrip.css.js.map +1 -1
  12. package/lib/esm/components/backoffice/filters/DeferredFilterSearchInput.js +64 -50
  13. package/lib/esm/components/backoffice/filters/DeferredFilterSearchInput.js.map +1 -1
  14. package/lib/esm/components/backoffice/filters/EntityIdFilterField.js +45 -50
  15. package/lib/esm/components/backoffice/filters/EntityIdFilterField.js.map +1 -1
  16. package/lib/esm/components/backoffice/filters/deferredFilterSearchInput.css.js +2 -2
  17. package/lib/esm/components/backoffice/filters/deferredFilterSearchInput.css.js.map +1 -1
  18. package/lib/esm/components/backoffice/filters/entityIdFilterField.css.js +1 -1
  19. package/lib/esm/components/backoffice/filters/entityIdFilterField.css.js.map +1 -1
  20. package/lib/esm/components/backoffice/hub/backofficeHubTemplate.css.js.map +1 -1
  21. package/lib/esm/components/backoffice/layout/backofficeSidebarActions.css.js +0 -1
  22. package/lib/esm/components/backoffice/pickers/entityIdPickerDialog.css.js.map +1 -1
  23. package/lib/esm/components/backoffice/refs/backofficeRelatedCountLink.css.js.map +1 -1
  24. package/lib/esm/components/backoffice/routing/backofficeRoutePendingBar.css.js.map +1 -1
  25. package/lib/esm/components/backoffice/scaffolds/BackofficeEntityListScaffold.js +1 -1
  26. package/lib/esm/components/backoffice/scaffolds/BackofficeEntityListScaffold.js.map +1 -1
  27. package/lib/esm/components/backoffice/shared/BackofficeFormattedCurrency.js +2 -1
  28. package/lib/esm/components/backoffice/shared/BackofficeFormattedCurrency.js.map +1 -1
  29. package/lib/esm/components/backoffice/tools/backofficeToolsDocPanel.css.js.map +1 -1
  30. package/lib/esm/i18n/locales/en/backofficeReact.js +3 -3
  31. package/lib/esm/i18n/locales/en/backofficeReact.js.map +1 -1
  32. package/lib/esm/i18n/locales/fr/backofficeReact.js +3 -3
  33. package/lib/esm/i18n/locales/fr/backofficeReact.js.map +1 -1
  34. package/lib/esm/i18n/useBackofficeFormats.js +28 -12
  35. package/lib/esm/i18n/useBackofficeFormats.js.map +1 -1
  36. package/lib/esm/pages/BackofficeEntityDetailPage.js +197 -196
  37. package/lib/esm/pages/BackofficeEntityDetailPage.js.map +1 -1
  38. package/lib/esm/pages/BackofficeEntityDetailPage.view-helpers.js +74 -70
  39. package/lib/esm/pages/BackofficeEntityDetailPage.view-helpers.js.map +1 -1
  40. package/lib/esm/pages/BackofficeEntityListPage.js +46 -53
  41. package/lib/esm/pages/BackofficeEntityListPage.js.map +1 -1
  42. package/lib/esm/pages/backofficeEntityListPage.css.js +1 -1
  43. package/lib/esm/pages/backofficeEntityListPage.css.js.map +1 -1
  44. package/lib/esm/pages/dashboard/dashboardPanel.css.js.map +1 -1
  45. package/lib/esm/provider/BackofficeProvider.js +1 -1
  46. package/lib/esm/provider/BackofficeProvider.js.map +1 -1
  47. package/lib/esm/style.css +1 -1
  48. package/lib/types/components/backoffice/billing/BackofficeBillingUsageChart.d.ts.map +1 -1
  49. package/lib/types/components/backoffice/detail/BackofficeDetailBadgeRow.d.ts.map +1 -1
  50. package/lib/types/components/backoffice/detail/BackofficeKpiStrip.d.ts.map +1 -1
  51. package/lib/types/components/backoffice/detail/backofficeKpiStrip.css.d.ts +24 -0
  52. package/lib/types/components/backoffice/detail/backofficeKpiStrip.css.d.ts.map +1 -1
  53. package/lib/types/components/backoffice/filters/DeferredFilterSearchInput.d.ts +1 -1
  54. package/lib/types/components/backoffice/filters/DeferredFilterSearchInput.d.ts.map +1 -1
  55. package/lib/types/components/backoffice/filters/EntityIdFilterField.d.ts.map +1 -1
  56. package/lib/types/components/backoffice/filters/deferredFilterSearchInput.css.d.ts +2 -0
  57. package/lib/types/components/backoffice/filters/deferredFilterSearchInput.css.d.ts.map +1 -1
  58. package/lib/types/components/backoffice/filters/entityIdFilterField.css.d.ts.map +1 -1
  59. package/lib/types/components/backoffice/shared/BackofficeFormattedCurrency.d.ts.map +1 -1
  60. package/lib/types/i18n/resources.d.ts +6 -6
  61. package/lib/types/i18n/useBackofficeFormats.d.ts +1 -0
  62. package/lib/types/i18n/useBackofficeFormats.d.ts.map +1 -1
  63. package/lib/types/pages/BackofficeEntityDetailPage.d.ts.map +1 -1
  64. package/lib/types/pages/BackofficeEntityDetailPage.view-helpers.d.ts +1 -0
  65. package/lib/types/pages/BackofficeEntityDetailPage.view-helpers.d.ts.map +1 -1
  66. package/lib/types/pages/BackofficeEntityListPage.d.ts.map +1 -1
  67. package/lib/types/pages/backofficeEntityListPage.css.d.ts.map +1 -1
  68. package/package.json +11 -11
@@ -1,3 +1,4 @@
1
+ /* empty css */
1
2
  /* empty css */
2
3
  //#region src/auth/login/loginPage.css.ts
3
4
  var e = "txvbqbdr8 txvbqbf6i txvbqbffw", t = "txvbqbdr8 txvbqbf6i txvbqb17w0", n = "txvbqb19dn txvbqb9j txvbqbm9g txvbqblzp", r = "txvbqbey txvbqb19dn txvbqbdr8 txvbqbff6 txvbqbq1l txvbqbn84", i = "txvbqb197r txvbqbi1s txvbqbdxd txvbqb2is txvbqb19e7", a = "txvbqbey txvbqbdr8 txvbqbf91 txvbqbffj txvbqbjus txvbqbq0v", o = "w8yhmy0 txvbqb1933 txvbqb1g5 txvbqb2e3 txvbqb19d9 txvbqbv txvbqbfd0 txvbqbux3 txvbqb3f txvbqb7h txvbqb76 txvbqb7t txvbqb1bwh txvbqb1czl", s = "txvbqbypl txvbqbzn6 txvbqb10kr txvbqbvwu txvbqbabd txvbqba5l txvbqbalh txvbqbahi", c = "txvbqbdr8 txvbqbf6i txvbqbffw", l = "txvbqb17w0", u = "txvbqbm9g txvbqbam txvbqbfdd txvbqb19d9 txvbqbkvm", d = "txvbqbq18", f = "w8yhmy1 txvbqb1cw txvbqb1w1 txvbqb2et txvbqb19d9 txvbqb1983 txvbqb7h txvbqb75 txvbqb7t";
@@ -1 +1 @@
1
- {"version":3,"file":"loginPage.css.js","names":[],"sources":["../../../../src/auth/login/loginPage.css.ts"],"sourcesContent":["import { style } from '@vanilla-extract/css';\nimport { sprinkles, stateSprinkles } from '@plumile/ui/theme/sprinkles.css.js';\nimport { vars } from '@plumile/ui/theme/themeContract.js';\n\nexport const stack = sprinkles({\n display: 'flex',\n flexDirection: 'column',\n gap: 4,\n});\n\nexport const formSurface = sprinkles({\n display: 'flex',\n flexDirection: 'column',\n width: 'full',\n});\n\nexport const helper = sprinkles({\n color: 'brandDarkGray',\n fontSize: 'sm',\n margin: 0,\n lineHeight: 1.6,\n});\n\nexport const divider = sprinkles({\n alignItems: 'center',\n color: 'brandDarkGray',\n display: 'flex',\n gap: 2,\n marginTop: 5,\n marginBottom: 3,\n});\n\nexport const dividerLine = sprinkles({\n backgroundColor: 'brandPrimaryRed',\n height: 'px',\n flex: 1,\n borderRadius: 'full',\n opacity: 35,\n});\n\nexport const actionsRow = sprinkles({\n alignItems: 'center',\n display: 'flex',\n flexWrap: 'wrap',\n gap: 3,\n justifyContent: 'space-between',\n marginTop: 3,\n});\n\nexport const inlineLink = style([\n sprinkles({\n backgroundColor: 'transparent',\n borderWidth: 0,\n borderStyle: 'none',\n color: 'brandPrimaryRed',\n cursor: 'pointer',\n fontWeight: 'semibold',\n padding: 0,\n textDecoration: 'none',\n transitionProperty: 'colors',\n transitionDuration: 150,\n transitionTimingFunction: 'ease',\n }),\n stateSprinkles({\n color: { hover: 'brandSecondaryOrange' },\n textDecoration: { hover: 'underline' },\n }),\n]);\n\nexport const panel = sprinkles({\n borderTopLeftRadius: 'none',\n borderTopRightRadius: 'none',\n borderBottomLeftRadius: '2xl',\n borderBottomRightRadius: '2xl',\n paddingX: 6,\n paddingY: 6,\n});\n\nexport const block = sprinkles({\n display: 'flex',\n flexDirection: 'column',\n gap: 4,\n});\n\nexport const fullWidth = sprinkles({\n width: 'full',\n});\n\nexport const panelTitle = sprinkles({\n margin: 0,\n fontSize: 'xl',\n fontWeight: 'bold',\n color: 'brandPrimaryRed',\n letterSpacing: 'tight',\n});\n\nexport const footer = sprinkles({\n marginTop: 4,\n});\n\nexport const brandGhostButton = style([\n sprinkles({\n borderColor: 'brandPrimaryRed',\n borderWidth: 'px',\n borderStyle: 'solid',\n color: 'brandPrimaryRed',\n backgroundColor: 'brandLightGray',\n transitionProperty: 'colors',\n transitionDuration: 120,\n transitionTimingFunction: 'ease',\n }),\n {\n selectors: {\n '&:hover:not(:disabled)': {\n backgroundColor: `color-mix(in srgb, ${vars.colors.brandPrimaryRed} 8%, transparent)`,\n color: vars.colors.brandSecondaryOrange,\n borderColor: vars.colors.brandSecondaryOrange,\n },\n },\n },\n]);\n"],"mappings":""}
1
+ {"version":3,"file":"loginPage.css.js","names":[],"sources":["../../../../src/auth/login/loginPage.css.ts"],"sourcesContent":["import { style } from '@vanilla-extract/css';\nimport { sprinkles, stateSprinkles } from '@plumile/ui/theme/sprinkles.css.js';\nimport { vars } from '@plumile/ui/theme/themeContract.css.js';\n\nexport const stack = sprinkles({\n display: 'flex',\n flexDirection: 'column',\n gap: 4,\n});\n\nexport const formSurface = sprinkles({\n display: 'flex',\n flexDirection: 'column',\n width: 'full',\n});\n\nexport const helper = sprinkles({\n color: 'brandDarkGray',\n fontSize: 'sm',\n margin: 0,\n lineHeight: 1.6,\n});\n\nexport const divider = sprinkles({\n alignItems: 'center',\n color: 'brandDarkGray',\n display: 'flex',\n gap: 2,\n marginTop: 5,\n marginBottom: 3,\n});\n\nexport const dividerLine = sprinkles({\n backgroundColor: 'brandPrimaryRed',\n height: 'px',\n flex: 1,\n borderRadius: 'full',\n opacity: 35,\n});\n\nexport const actionsRow = sprinkles({\n alignItems: 'center',\n display: 'flex',\n flexWrap: 'wrap',\n gap: 3,\n justifyContent: 'space-between',\n marginTop: 3,\n});\n\nexport const inlineLink = style([\n sprinkles({\n backgroundColor: 'transparent',\n borderWidth: 0,\n borderStyle: 'none',\n color: 'brandPrimaryRed',\n cursor: 'pointer',\n fontWeight: 'semibold',\n padding: 0,\n textDecoration: 'none',\n transitionProperty: 'colors',\n transitionDuration: 150,\n transitionTimingFunction: 'ease',\n }),\n stateSprinkles({\n color: { hover: 'brandSecondaryOrange' },\n textDecoration: { hover: 'underline' },\n }),\n]);\n\nexport const panel = sprinkles({\n borderTopLeftRadius: 'none',\n borderTopRightRadius: 'none',\n borderBottomLeftRadius: '2xl',\n borderBottomRightRadius: '2xl',\n paddingX: 6,\n paddingY: 6,\n});\n\nexport const block = sprinkles({\n display: 'flex',\n flexDirection: 'column',\n gap: 4,\n});\n\nexport const fullWidth = sprinkles({\n width: 'full',\n});\n\nexport const panelTitle = sprinkles({\n margin: 0,\n fontSize: 'xl',\n fontWeight: 'bold',\n color: 'brandPrimaryRed',\n letterSpacing: 'tight',\n});\n\nexport const footer = sprinkles({\n marginTop: 4,\n});\n\nexport const brandGhostButton = style([\n sprinkles({\n borderColor: 'brandPrimaryRed',\n borderWidth: 'px',\n borderStyle: 'solid',\n color: 'brandPrimaryRed',\n backgroundColor: 'brandLightGray',\n transitionProperty: 'colors',\n transitionDuration: 120,\n transitionTimingFunction: 'ease',\n }),\n {\n selectors: {\n '&:hover:not(:disabled)': {\n backgroundColor: `color-mix(in srgb, ${vars.colors.brandPrimaryRed} 8%, transparent)`,\n color: vars.colors.brandSecondaryOrange,\n borderColor: vars.colors.brandSecondaryOrange,\n },\n },\n },\n]);\n"],"mappings":""}
@@ -6,55 +6,66 @@ import { TimeSeriesLineChart as s } from "@plumile/ui/components/charts/TimeSeri
6
6
  import { formatCurrencyAmount as c } from "@plumile/ui/shared/currencyAmount.js";
7
7
  import { toUtcDailyCategorySeries as l } from "@plumile/ui/shared/timeSeries.js";
8
8
  //#region src/components/backoffice/billing/BackofficeBillingUsageChart.tsx
9
- var u = "->", d = ({ ariaLabel: d, buckets: f, categories: p, currency: m, emptyLabel: h, from: g, rangePrefix: _, to: v, totalAmount: y }) => {
10
- let b = r(() => p.map((e) => e.id), [p]), x = r(() => Object.fromEntries(p.map((e) => [e.id, e.color])), [p]), S = r(() => Object.fromEntries(p.map((e) => [e.id, e.label])), [p]), C = r(() => g == null || v == null ? [] : l({
11
- fromIsoDateTime: g,
12
- toIsoDateTime: v,
13
- buckets: f,
14
- categories: b
9
+ var u = "->", d = (e, t) => new Intl.NumberFormat(void 0, {
10
+ style: "currency",
11
+ currency: t,
12
+ minimumFractionDigits: 0,
13
+ maximumFractionDigits: 0
14
+ }).format(e), f = ({ ariaLabel: f, buckets: p, categories: m, currency: h, emptyLabel: g, from: _, rangePrefix: v, to: y, totalAmount: b }) => {
15
+ let x = r(() => m.map((e) => e.id), [m]), S = r(() => Object.fromEntries(m.map((e) => [e.id, e.color])), [m]), C = r(() => Object.fromEntries(m.map((e) => [e.id, e.label])), [m]), w = r(() => _ == null || y == null ? [] : l({
16
+ fromIsoDateTime: _,
17
+ toIsoDateTime: y,
18
+ buckets: p,
19
+ categories: x
15
20
  }), [
16
- f,
17
- b,
18
- g,
19
- v
20
- ]), w = (e) => c({
21
+ p,
22
+ x,
23
+ _,
24
+ y
25
+ ]), T = (e) => c({
21
26
  amount: e,
22
- currency: m
27
+ currency: h
23
28
  });
24
- return f.length === 0 ? /* @__PURE__ */ i("p", {
29
+ return p.length === 0 ? /* @__PURE__ */ i("p", {
25
30
  className: e,
26
- children: h
31
+ children: g
27
32
  }) : /* @__PURE__ */ a("div", {
28
33
  className: t,
29
34
  children: [
30
35
  /* @__PURE__ */ i("p", {
31
36
  className: n,
32
- children: w(y)
37
+ children: T(b)
33
38
  }),
34
- g != null && v != null && /* @__PURE__ */ a("p", {
39
+ _ != null && y != null && /* @__PURE__ */ a("p", {
35
40
  className: "txvbqb96 txvbqb19cd txvbqbm9g",
36
41
  children: [
37
- _,
42
+ v,
38
43
  " ",
39
- /* @__PURE__ */ i(o, { value: g }),
44
+ /* @__PURE__ */ i(o, { value: _ }),
40
45
  " ",
41
46
  u,
42
47
  " ",
43
- /* @__PURE__ */ i(o, { value: v })
48
+ /* @__PURE__ */ i(o, { value: y })
44
49
  ]
45
50
  }),
46
51
  /* @__PURE__ */ i(s, {
47
- ariaLabel: d,
48
- categoryColorById: x,
49
- categoryLabel: (e) => S[e] ?? e,
50
- categoryOrder: b,
51
- formatValue: w,
52
- series: C
52
+ ariaLabel: f,
53
+ categoryColorById: S,
54
+ categoryLabel: (e) => C[e] ?? e,
55
+ categoryOrder: x,
56
+ formatValue: T,
57
+ series: w,
58
+ yAxis: {
59
+ min: 0,
60
+ minTickStep: 1,
61
+ maxTickCount: 5,
62
+ formatValue: (e) => d(e, h)
63
+ }
53
64
  })
54
65
  ]
55
66
  });
56
67
  };
57
68
  //#endregion
58
- export { d as BackofficeBillingUsageChart, d as default };
69
+ export { f as BackofficeBillingUsageChart, f as default };
59
70
 
60
71
  //# sourceMappingURL=BackofficeBillingUsageChart.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"BackofficeBillingUsageChart.js","names":[],"sources":["../../../../../src/components/backoffice/billing/BackofficeBillingUsageChart.tsx"],"sourcesContent":["import { useMemo, type JSX } from 'react';\nimport { FormattedDate } from '@plumile/ui/atomic/atoms/formatted-date/FormattedDate.js';\nimport { TimeSeriesLineChart } from '@plumile/ui/components/charts/TimeSeriesLineChart.js';\nimport { formatCurrencyAmount } from '@plumile/ui/shared/currencyAmount.js';\nimport { toUtcDailyCategorySeries } from '@plumile/ui/shared/timeSeries.js';\n\nimport * as styles from './backofficeBillingUsageChart.css.js';\n\nexport type BackofficeBillingUsageChartBucket = {\n readonly day: string;\n readonly category: string;\n readonly value: number;\n};\n\nexport type BackofficeBillingUsageChartCategory = {\n readonly id: string;\n readonly label: string;\n readonly color: string;\n};\n\nexport type BackofficeBillingUsageChartProps = {\n readonly currency: string;\n readonly totalAmount: number;\n readonly from: string | null;\n readonly to: string | null;\n readonly buckets: readonly BackofficeBillingUsageChartBucket[];\n readonly categories: readonly BackofficeBillingUsageChartCategory[];\n readonly emptyLabel: string;\n readonly rangePrefix: string;\n readonly ariaLabel: string;\n};\n\nconst dateSeparator = '->';\n\nexport const BackofficeBillingUsageChart = ({\n ariaLabel,\n buckets,\n categories,\n currency,\n emptyLabel,\n from,\n rangePrefix,\n to,\n totalAmount,\n}: BackofficeBillingUsageChartProps): JSX.Element => {\n const categoryOrder = useMemo(() => {\n return categories.map((category) => {\n return category.id;\n });\n }, [categories]);\n\n const categoryColorById = useMemo(() => {\n return Object.fromEntries(\n categories.map((category) => {\n return [category.id, category.color];\n }),\n );\n }, [categories]);\n\n const categoryLabelById = useMemo(() => {\n return Object.fromEntries(\n categories.map((category) => {\n return [category.id, category.label];\n }),\n );\n }, [categories]);\n\n const series = useMemo(() => {\n if (from == null || to == null) {\n return [];\n }\n\n return toUtcDailyCategorySeries({\n fromIsoDateTime: from,\n toIsoDateTime: to,\n buckets,\n categories: categoryOrder,\n });\n }, [buckets, categoryOrder, from, to]);\n\n const formatChartValue = (value: number): string => {\n return formatCurrencyAmount({\n amount: value,\n currency,\n });\n };\n\n if (buckets.length === 0) {\n return <p className={styles.rangeText}>{emptyLabel}</p>;\n }\n\n return (\n <div className={styles.root}>\n <p className={styles.totalValue}>{formatChartValue(totalAmount)}</p>\n {from != null && to != null && (\n <p className={styles.rangeText}>\n {rangePrefix} <FormattedDate value={from} /> {dateSeparator}{' '}\n <FormattedDate value={to} />\n </p>\n )}\n <TimeSeriesLineChart\n ariaLabel={ariaLabel}\n categoryColorById={categoryColorById}\n categoryLabel={(category) => {\n return categoryLabelById[category] ?? category;\n }}\n categoryOrder={categoryOrder}\n formatValue={formatChartValue}\n series={series}\n />\n </div>\n );\n};\n\nexport default BackofficeBillingUsageChart;\n"],"mappings":";;;;;;;;AAgCA,IAAM,IAAgB,MAET,KAA+B,EAC1C,cACA,YACA,eACA,aACA,eACA,SACA,gBACA,OACA,qBACmD;CACnD,IAAM,IAAgB,QACb,EAAW,KAAK,MACd,EAAS,GAChB,EACD,CAAC,EAAW,CAAC,EAEV,IAAoB,QACjB,OAAO,YACZ,EAAW,KAAK,MACP,CAAC,EAAS,IAAI,EAAS,MAAM,CACpC,CACH,EACA,CAAC,EAAW,CAAC,EAEV,IAAoB,QACjB,OAAO,YACZ,EAAW,KAAK,MACP,CAAC,EAAS,IAAI,EAAS,MAAM,CACpC,CACH,EACA,CAAC,EAAW,CAAC,EAEV,IAAS,QACT,KAAQ,QAAQ,KAAM,OACjB,EAAE,GAGJ,EAAyB;EAC9B,iBAAiB;EACjB,eAAe;EACf;EACA,YAAY;EACb,CAAC,EACD;EAAC;EAAS;EAAe;EAAM;EAAG,CAAC,EAEhC,KAAoB,MACjB,EAAqB;EAC1B,QAAQ;EACR;EACD,CAAC;CAOJ,OAJI,EAAQ,WAAW,IACd,kBAAC,KAAD;EAAG,WAAW;YAAmB;EAAe,CAAA,GAIvD,kBAAC,OAAD;EAAK,WAAW;YAAhB;GACE,kBAAC,KAAD;IAAG,WAAW;cAAoB,EAAiB,EAAY;IAAK,CAAA;GACnE,KAAQ,QAAQ,KAAM,QACrB,kBAAC,KAAD;IAAG,WAAW;cAAd;KACG;KAAY;KAAC,kBAAC,GAAD,EAAe,OAAO,GAAQ,CAAA;;KAAE;KAAe;KAC7D,kBAAC,GAAD,EAAe,OAAO,GAAM,CAAA;KAC1B;;GAEN,kBAAC,GAAD;IACa;IACQ;IACnB,gBAAgB,MACP,EAAkB,MAAa;IAEzB;IACf,aAAa;IACL;IACR,CAAA;GACE"}
1
+ {"version":3,"file":"BackofficeBillingUsageChart.js","names":[],"sources":["../../../../../src/components/backoffice/billing/BackofficeBillingUsageChart.tsx"],"sourcesContent":["import { useMemo, type JSX } from 'react';\nimport { FormattedDate } from '@plumile/ui/atomic/atoms/formatted-date/FormattedDate.js';\nimport { TimeSeriesLineChart } from '@plumile/ui/components/charts/TimeSeriesLineChart.js';\nimport { formatCurrencyAmount } from '@plumile/ui/shared/currencyAmount.js';\nimport { toUtcDailyCategorySeries } from '@plumile/ui/shared/timeSeries.js';\n\nimport * as styles from './backofficeBillingUsageChart.css.js';\n\nexport type BackofficeBillingUsageChartBucket = {\n readonly day: string;\n readonly category: string;\n readonly value: number;\n};\n\nexport type BackofficeBillingUsageChartCategory = {\n readonly id: string;\n readonly label: string;\n readonly color: string;\n};\n\nexport type BackofficeBillingUsageChartProps = {\n readonly currency: string;\n readonly totalAmount: number;\n readonly from: string | null;\n readonly to: string | null;\n readonly buckets: readonly BackofficeBillingUsageChartBucket[];\n readonly categories: readonly BackofficeBillingUsageChartCategory[];\n readonly emptyLabel: string;\n readonly rangePrefix: string;\n readonly ariaLabel: string;\n};\n\nconst dateSeparator = '->';\n\nconst formatBillingAxisValue = (value: number, currency: string): string => {\n return new Intl.NumberFormat(undefined, {\n style: 'currency',\n currency,\n minimumFractionDigits: 0,\n maximumFractionDigits: 0,\n }).format(value);\n};\n\nexport const BackofficeBillingUsageChart = ({\n ariaLabel,\n buckets,\n categories,\n currency,\n emptyLabel,\n from,\n rangePrefix,\n to,\n totalAmount,\n}: BackofficeBillingUsageChartProps): JSX.Element => {\n const categoryOrder = useMemo(() => {\n return categories.map((category) => {\n return category.id;\n });\n }, [categories]);\n\n const categoryColorById = useMemo(() => {\n return Object.fromEntries(\n categories.map((category) => {\n return [category.id, category.color];\n }),\n );\n }, [categories]);\n\n const categoryLabelById = useMemo(() => {\n return Object.fromEntries(\n categories.map((category) => {\n return [category.id, category.label];\n }),\n );\n }, [categories]);\n\n const series = useMemo(() => {\n if (from == null || to == null) {\n return [];\n }\n\n return toUtcDailyCategorySeries({\n fromIsoDateTime: from,\n toIsoDateTime: to,\n buckets,\n categories: categoryOrder,\n });\n }, [buckets, categoryOrder, from, to]);\n\n const formatChartValue = (value: number): string => {\n return formatCurrencyAmount({\n amount: value,\n currency,\n });\n };\n\n if (buckets.length === 0) {\n return <p className={styles.rangeText}>{emptyLabel}</p>;\n }\n\n return (\n <div className={styles.root}>\n <p className={styles.totalValue}>{formatChartValue(totalAmount)}</p>\n {from != null && to != null && (\n <p className={styles.rangeText}>\n {rangePrefix} <FormattedDate value={from} /> {dateSeparator}{' '}\n <FormattedDate value={to} />\n </p>\n )}\n <TimeSeriesLineChart\n ariaLabel={ariaLabel}\n categoryColorById={categoryColorById}\n categoryLabel={(category) => {\n return categoryLabelById[category] ?? category;\n }}\n categoryOrder={categoryOrder}\n formatValue={formatChartValue}\n series={series}\n yAxis={{\n min: 0,\n minTickStep: 1,\n maxTickCount: 5,\n formatValue: (value) => {\n return formatBillingAxisValue(value, currency);\n },\n }}\n />\n </div>\n );\n};\n\nexport default BackofficeBillingUsageChart;\n"],"mappings":";;;;;;;;AAgCA,IAAM,IAAgB,MAEhB,KAA0B,GAAe,MACtC,IAAI,KAAK,aAAa,KAAA,GAAW;CACtC,OAAO;CACP;CACA,uBAAuB;CACvB,uBAAuB;CACxB,CAAC,CAAC,OAAO,EAAM,EAGL,KAA+B,EAC1C,cACA,YACA,eACA,aACA,eACA,SACA,gBACA,OACA,qBACmD;CACnD,IAAM,IAAgB,QACb,EAAW,KAAK,MACd,EAAS,GAChB,EACD,CAAC,EAAW,CAAC,EAEV,IAAoB,QACjB,OAAO,YACZ,EAAW,KAAK,MACP,CAAC,EAAS,IAAI,EAAS,MAAM,CACpC,CACH,EACA,CAAC,EAAW,CAAC,EAEV,IAAoB,QACjB,OAAO,YACZ,EAAW,KAAK,MACP,CAAC,EAAS,IAAI,EAAS,MAAM,CACpC,CACH,EACA,CAAC,EAAW,CAAC,EAEV,IAAS,QACT,KAAQ,QAAQ,KAAM,OACjB,EAAE,GAGJ,EAAyB;EAC9B,iBAAiB;EACjB,eAAe;EACf;EACA,YAAY;EACb,CAAC,EACD;EAAC;EAAS;EAAe;EAAM;EAAG,CAAC,EAEhC,KAAoB,MACjB,EAAqB;EAC1B,QAAQ;EACR;EACD,CAAC;CAOJ,OAJI,EAAQ,WAAW,IACd,kBAAC,KAAD;EAAG,WAAW;YAAmB;EAAe,CAAA,GAIvD,kBAAC,OAAD;EAAK,WAAW;YAAhB;GACE,kBAAC,KAAD;IAAG,WAAW;cAAoB,EAAiB,EAAY;IAAK,CAAA;GACnE,KAAQ,QAAQ,KAAM,QACrB,kBAAC,KAAD;IAAG,WAAW;cAAd;KACG;KAAY;KAAC,kBAAC,GAAD,EAAe,OAAO,GAAQ,CAAA;;KAAE;KAAe;KAC7D,kBAAC,GAAD,EAAe,OAAO,GAAM,CAAA;KAC1B;;GAEN,kBAAC,GAAD;IACa;IACQ;IACnB,gBAAgB,MACP,EAAkB,MAAa;IAEzB;IACf,aAAa;IACL;IACR,OAAO;KACL,KAAK;KACL,aAAa;KACb,cAAc;KACd,cAAc,MACL,EAAuB,GAAO,EAAS;KAEjD;IACD,CAAA;GACE"}
@@ -8,9 +8,10 @@ var i = ({ items: i }) => {
8
8
  return /* @__PURE__ */ t("div", {
9
9
  className: e,
10
10
  children: i.map((e) => {
11
- let n = typeof e.label == "function" ? e.label(a) : e.label;
11
+ let n = typeof e.label == "function" ? e.label(a) : e.label, i = typeof e.title == "function" ? e.title(a) : e.title;
12
12
  return /* @__PURE__ */ t(r, {
13
13
  tone: e.tone ?? "neutral",
14
+ title: i,
14
15
  children: n
15
16
  }, e.id);
16
17
  })
@@ -1 +1 @@
1
- {"version":3,"file":"BackofficeDetailBadgeRow.js","names":[],"sources":["../../../../../src/components/backoffice/detail/BackofficeDetailBadgeRow.tsx"],"sourcesContent":["/* eslint-disable no-ternary */\nimport { type JSX } from 'react';\nimport { useTranslation } from 'react-i18next';\n\nimport type { BackofficeBadgeItem } from '@plumile/backoffice-core/types.js';\nimport { Tag } from '@plumile/ui/backoffice/atoms/tag/Tag.js';\n\nimport * as styles from './backofficeDetailBadgeRow.css.js';\n\nexport type BackofficeDetailBadgeRowProps = {\n items: readonly BackofficeBadgeItem[];\n};\n\nexport const BackofficeDetailBadgeRow = ({\n items,\n}: BackofficeDetailBadgeRowProps): JSX.Element => {\n const { t } = useTranslation();\n return (\n <div className={styles.row}>\n {items.map((item) => {\n const label =\n typeof item.label === 'function' ? item.label(t) : item.label;\n return (\n <Tag key={item.id} tone={item.tone ?? 'neutral'}>\n {label}\n </Tag>\n );\n })}\n </div>\n );\n};\n\nexport default BackofficeDetailBadgeRow;\n"],"mappings":";;;;;AAaA,IAAa,KAA4B,EACvC,eACgD;CAChD,IAAM,EAAE,SAAM,GAAgB;CAC9B,OACE,kBAAC,OAAD;EAAK,WAAW;YACb,EAAM,KAAK,MAAS;GACnB,IAAM,IACJ,OAAO,EAAK,SAAU,aAAa,EAAK,MAAM,EAAE,GAAG,EAAK;GAC1D,OACE,kBAAC,GAAD;IAAmB,MAAM,EAAK,QAAQ;cACnC;IACG,EAFI,EAAK,GAET;IAER;EACE,CAAA"}
1
+ {"version":3,"file":"BackofficeDetailBadgeRow.js","names":[],"sources":["../../../../../src/components/backoffice/detail/BackofficeDetailBadgeRow.tsx"],"sourcesContent":["/* eslint-disable no-ternary */\nimport { type JSX } from 'react';\nimport { useTranslation } from 'react-i18next';\n\nimport type { BackofficeBadgeItem } from '@plumile/backoffice-core/types.js';\nimport { Tag } from '@plumile/ui/backoffice/atoms/tag/Tag.js';\n\nimport * as styles from './backofficeDetailBadgeRow.css.js';\n\nexport type BackofficeDetailBadgeRowProps = {\n items: readonly BackofficeBadgeItem[];\n};\n\nexport const BackofficeDetailBadgeRow = ({\n items,\n}: BackofficeDetailBadgeRowProps): JSX.Element => {\n const { t } = useTranslation();\n return (\n <div className={styles.row}>\n {items.map((item) => {\n const label =\n typeof item.label === 'function' ? item.label(t) : item.label;\n const title =\n typeof item.title === 'function' ? item.title(t) : item.title;\n return (\n <Tag key={item.id} tone={item.tone ?? 'neutral'} title={title}>\n {label}\n </Tag>\n );\n })}\n </div>\n );\n};\n\nexport default BackofficeDetailBadgeRow;\n"],"mappings":";;;;;AAaA,IAAa,KAA4B,EACvC,eACgD;CAChD,IAAM,EAAE,SAAM,GAAgB;CAC9B,OACE,kBAAC,OAAD;EAAK,WAAW;YACb,EAAM,KAAK,MAAS;GACnB,IAAM,IACJ,OAAO,EAAK,SAAU,aAAa,EAAK,MAAM,EAAE,GAAG,EAAK,OACpD,IACJ,OAAO,EAAK,SAAU,aAAa,EAAK,MAAM,EAAE,GAAG,EAAK;GAC1D,OACE,kBAAC,GAAD;IAAmB,MAAM,EAAK,QAAQ;IAAkB;cACrD;IACG,EAFI,EAAK,GAET;IAER;EACE,CAAA"}
@@ -1,31 +1,31 @@
1
1
  import { useBackofficeReactTranslation as e } from "../../../i18n/useBackofficeReactTranslation.js";
2
- import { card as t, compactGroup as n, group as r, value as i } from "./backofficeKpiStrip.css.js";
3
- import { cx as a } from "@plumile/ui/theme/tools.js";
4
- import { jsx as o } from "react/jsx-runtime";
5
- import { CopyableText as s } from "@plumile/ui/backoffice/atoms/copyable_text/CopyableText.js";
6
- import { MetricCard as c } from "@plumile/ui/components/dashboard/metric_card/MetricCard.js";
7
- import { MetricTileGroup as l } from "@plumile/ui/components/dashboard/metric_tile_group/MetricTileGroup.js";
2
+ import { card as t, cardTone as n, compactGroup as r, group as i, value as a } from "./backofficeKpiStrip.css.js";
3
+ import { cx as o } from "@plumile/ui/theme/tools.js";
4
+ import { jsx as s } from "react/jsx-runtime";
5
+ import { CopyableText as c } from "@plumile/ui/backoffice/atoms/copyable_text/CopyableText.js";
6
+ import { MetricCard as l } from "@plumile/ui/components/dashboard/metric_card/MetricCard.js";
7
+ import { MetricTileGroup as u } from "@plumile/ui/components/dashboard/metric_tile_group/MetricTileGroup.js";
8
8
  //#region src/components/backoffice/detail/BackofficeKpiStrip.tsx
9
- var u = ({ items: u, density: d = "comfortable" }) => {
10
- let { t: f } = e();
11
- if (u.length === 0) return null;
12
- let p = r;
13
- return d === "compact" && (p = a(r, n)), /* @__PURE__ */ o(l, {
14
- className: p,
15
- children: u.map((e) => {
16
- let n = e.value;
17
- return e.copyValue != null && e.copyValue !== "" && (n = /* @__PURE__ */ o(s, {
9
+ var d = ({ items: d, density: f = "comfortable" }) => {
10
+ let { t: p } = e();
11
+ if (d.length === 0) return null;
12
+ let m = i;
13
+ return f === "compact" && (m = o(i, r)), /* @__PURE__ */ s(u, {
14
+ className: m,
15
+ children: d.map((e) => {
16
+ let r = e.value;
17
+ return e.copyValue != null && e.copyValue !== "" && (r = /* @__PURE__ */ s(c, {
18
18
  value: e.copyValue,
19
19
  copyValue: e.copyValue,
20
20
  truncate: !1,
21
- copyLabel: f("common.actions.copy"),
22
- copiedLabel: f("common.actions.copied")
23
- })), /* @__PURE__ */ o(c, {
24
- className: t,
21
+ copyLabel: p("common.actions.copy"),
22
+ copiedLabel: p("common.actions.copied")
23
+ })), /* @__PURE__ */ s(l, {
24
+ className: o(t, n({ tone: e.tone ?? "neutral" })),
25
25
  label: e.label,
26
- value: /* @__PURE__ */ o("span", {
27
- className: i,
28
- children: n
26
+ value: /* @__PURE__ */ s("span", {
27
+ className: a,
28
+ children: r
29
29
  }),
30
30
  hint: e.hint
31
31
  }, e.id);
@@ -33,6 +33,6 @@ var u = ({ items: u, density: d = "comfortable" }) => {
33
33
  });
34
34
  };
35
35
  //#endregion
36
- export { u as BackofficeKpiStrip, u as default };
36
+ export { d as BackofficeKpiStrip, d as default };
37
37
 
38
38
  //# sourceMappingURL=BackofficeKpiStrip.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"BackofficeKpiStrip.js","names":[],"sources":["../../../../../src/components/backoffice/detail/BackofficeKpiStrip.tsx"],"sourcesContent":["import { type JSX, type ReactNode } from 'react';\nimport { CopyableText } from '@plumile/ui/backoffice/atoms/copyable_text/CopyableText.js';\nimport { MetricCard } from '@plumile/ui/components/dashboard/metric_card/MetricCard.js';\nimport { MetricTileGroup } from '@plumile/ui/components/dashboard/metric_tile_group/MetricTileGroup.js';\nimport { cx } from '@plumile/ui/theme/tools.js';\n\nimport { useBackofficeReactTranslation } from '../../../i18n/useBackofficeReactTranslation.js';\nimport * as styles from './backofficeKpiStrip.css.js';\n\nexport type BackofficeKpiTone =\n | 'neutral'\n | 'info'\n | 'success'\n | 'warning'\n | 'danger';\n\nexport type BackofficeKpiItem = {\n readonly id: string;\n readonly label: string;\n readonly value: ReactNode;\n readonly hint?: ReactNode;\n readonly tone?: BackofficeKpiTone;\n readonly copyValue?: string;\n};\n\nexport type BackofficeKpiStripProps = {\n readonly items: readonly BackofficeKpiItem[];\n readonly density?: 'compact' | 'comfortable';\n};\n\nexport const BackofficeKpiStrip = ({\n items,\n density = 'comfortable',\n}: BackofficeKpiStripProps): JSX.Element | null => {\n const { t } = useBackofficeReactTranslation();\n\n if (items.length === 0) {\n return null;\n }\n\n let groupClassName: string | undefined = styles.group;\n if (density === 'compact') {\n groupClassName = cx(styles.group, styles.compactGroup);\n }\n\n return (\n <MetricTileGroup className={groupClassName}>\n {items.map((item) => {\n let valueNode = item.value;\n if (item.copyValue != null && item.copyValue !== '') {\n valueNode = (\n <CopyableText\n value={item.copyValue}\n copyValue={item.copyValue}\n truncate={false}\n copyLabel={t('common.actions.copy')}\n copiedLabel={t('common.actions.copied')}\n />\n );\n }\n\n return (\n <MetricCard\n key={item.id}\n className={styles.card}\n label={item.label}\n value={<span className={styles.value}>{valueNode}</span>}\n hint={item.hint}\n />\n );\n })}\n </MetricTileGroup>\n );\n};\n\nexport default BackofficeKpiStrip;\n"],"mappings":";;;;;;;;AA8BA,IAAa,KAAsB,EACjC,UACA,aAAU,oBACuC;CACjD,IAAM,EAAE,SAAM,GAA+B;CAE7C,IAAI,EAAM,WAAW,GACnB,OAAO;CAGT,IAAI,IAAqC;CAKzC,OAJI,MAAY,cACd,IAAiB,EAAG,GAAc,EAAoB,GAItD,kBAAC,GAAD;EAAiB,WAAW;YACzB,EAAM,KAAK,MAAS;GACnB,IAAI,IAAY,EAAK;GAarB,OAZI,EAAK,aAAa,QAAQ,EAAK,cAAc,OAC/C,IACE,kBAAC,GAAD;IACE,OAAO,EAAK;IACZ,WAAW,EAAK;IAChB,UAAU;IACV,WAAW,EAAE,sBAAsB;IACnC,aAAa,EAAE,wBAAwB;IACvC,CAAA,GAKJ,kBAAC,GAAD;IAEE,WAAW;IACX,OAAO,EAAK;IACZ,OAAO,kBAAC,QAAD;KAAM,WAAW;eAAe;KAAiB,CAAA;IACxD,MAAM,EAAK;IACX,EALK,EAAK,GAKV;IAEJ;EACc,CAAA"}
1
+ {"version":3,"file":"BackofficeKpiStrip.js","names":[],"sources":["../../../../../src/components/backoffice/detail/BackofficeKpiStrip.tsx"],"sourcesContent":["import { type JSX, type ReactNode } from 'react';\nimport { CopyableText } from '@plumile/ui/backoffice/atoms/copyable_text/CopyableText.js';\nimport { MetricCard } from '@plumile/ui/components/dashboard/metric_card/MetricCard.js';\nimport { MetricTileGroup } from '@plumile/ui/components/dashboard/metric_tile_group/MetricTileGroup.js';\nimport { cx } from '@plumile/ui/theme/tools.js';\n\nimport { useBackofficeReactTranslation } from '../../../i18n/useBackofficeReactTranslation.js';\nimport * as styles from './backofficeKpiStrip.css.js';\n\nexport type BackofficeKpiTone =\n | 'neutral'\n | 'info'\n | 'success'\n | 'warning'\n | 'danger';\n\nexport type BackofficeKpiItem = {\n readonly id: string;\n readonly label: string;\n readonly value: ReactNode;\n readonly hint?: ReactNode;\n readonly tone?: BackofficeKpiTone;\n readonly copyValue?: string;\n};\n\nexport type BackofficeKpiStripProps = {\n readonly items: readonly BackofficeKpiItem[];\n readonly density?: 'compact' | 'comfortable';\n};\n\nexport const BackofficeKpiStrip = ({\n items,\n density = 'comfortable',\n}: BackofficeKpiStripProps): JSX.Element | null => {\n const { t } = useBackofficeReactTranslation();\n\n if (items.length === 0) {\n return null;\n }\n\n let groupClassName: string | undefined = styles.group;\n if (density === 'compact') {\n groupClassName = cx(styles.group, styles.compactGroup);\n }\n\n return (\n <MetricTileGroup className={groupClassName}>\n {items.map((item) => {\n let valueNode = item.value;\n if (item.copyValue != null && item.copyValue !== '') {\n valueNode = (\n <CopyableText\n value={item.copyValue}\n copyValue={item.copyValue}\n truncate={false}\n copyLabel={t('common.actions.copy')}\n copiedLabel={t('common.actions.copied')}\n />\n );\n }\n\n return (\n <MetricCard\n key={item.id}\n className={cx(\n styles.card,\n styles.cardTone({ tone: item.tone ?? 'neutral' }),\n )}\n label={item.label}\n value={<span className={styles.value}>{valueNode}</span>}\n hint={item.hint}\n />\n );\n })}\n </MetricTileGroup>\n );\n};\n\nexport default BackofficeKpiStrip;\n"],"mappings":";;;;;;;;AA8BA,IAAa,KAAsB,EACjC,UACA,aAAU,oBACuC;CACjD,IAAM,EAAE,SAAM,GAA+B;CAE7C,IAAI,EAAM,WAAW,GACnB,OAAO;CAGT,IAAI,IAAqC;CAKzC,OAJI,MAAY,cACd,IAAiB,EAAG,GAAc,EAAoB,GAItD,kBAAC,GAAD;EAAiB,WAAW;YACzB,EAAM,KAAK,MAAS;GACnB,IAAI,IAAY,EAAK;GAarB,OAZI,EAAK,aAAa,QAAQ,EAAK,cAAc,OAC/C,IACE,kBAAC,GAAD;IACE,OAAO,EAAK;IACZ,WAAW,EAAK;IAChB,UAAU;IACV,WAAW,EAAE,sBAAsB;IACnC,aAAa,EAAE,wBAAwB;IACvC,CAAA,GAKJ,kBAAC,GAAD;IAEE,WAAW,EACT,GACA,EAAgB,EAAE,MAAM,EAAK,QAAQ,WAAW,CAAC,CAClD;IACD,OAAO,EAAK;IACZ,OAAO,kBAAC,QAAD;KAAM,WAAW;eAAe;KAAiB,CAAA;IACxD,MAAM,EAAK;IACX,EARK,EAAK,GAQV;IAEJ;EACc,CAAA"}
@@ -1,3 +1,4 @@
1
+ /* empty css */
1
2
  /* empty css */
2
3
  //#region src/components/backoffice/detail/backofficeDetailRelationLink.css.ts
3
4
  var e = "_93gupm0 qbwcueg qbwcuee txvbqb2g9 txvbqb19c9 txvbqb3f txvbqb7g txvbqb76 txvbqb7t qbwcuef txvbqb1aep txvbqb1b29 qbwcue0 txvbqb1cb0 txvbqb1cws txvbqbyoi txvbqbzm3 txvbqb10jb txvbqbvve txvbqb7h txvbqb75 txvbqbdr8 txvbqbjus txvbqbffj txvbqb1uy txvbqb2et txvbqbik txvbqb1933 txvbqbey txvbqbem txvbqbf65 txvbqbf6j txvbqb1aes txvbqb1b2c", t = "txvbqb9j txvbqbfcn txvbqbt9i txvbqbutu", n = "txvbqbdsb txvbqbey txvbqbfet txvbqbf7y txvbqbt9i", r = "txvbqb96 txvbqb19cb txvbqbutu txvbqb16fn", i = "txvbqbdsb txvbqbey txvbqbjtp txvbqb19cd txvbqb9j txvbqbl11";
@@ -1,7 +1,19 @@
1
+ import { createRuntimeFn as e } from "../../../node_modules/@vanilla-extract/recipes/dist/createRuntimeFn-62c9670f.esm.js";
1
2
  /* empty css */
2
3
  //#region src/components/backoffice/detail/backofficeKpiStrip.css.ts
3
- var e = "txvbqbdrl txvbqbffj txvbqbheb", t = "txvbqbff6", n = "txvbqbt9i", r = "txvbqbdr8 txvbqbey txvbqbff6";
4
+ var t = "txvbqbdrl txvbqbffj txvbqbheb", n = "txvbqbff6", r = "txvbqbt9i", i = e({
5
+ defaultClassName: "_1bcdpm60",
6
+ variantClassNames: { tone: {
7
+ neutral: "_1bcdpm61",
8
+ info: "_1bcdpm62",
9
+ success: "_1bcdpm63",
10
+ warning: "_1bcdpm64",
11
+ danger: "_1bcdpm65"
12
+ } },
13
+ defaultVariants: {},
14
+ compoundVariants: []
15
+ }), a = "txvbqbdr8 txvbqbey txvbqbff6";
4
16
  //#endregion
5
- export { n as card, t as compactGroup, e as group, r as value };
17
+ export { r as card, i as cardTone, n as compactGroup, t as group, a as value };
6
18
 
7
19
  //# sourceMappingURL=backofficeKpiStrip.css.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"backofficeKpiStrip.css.js","names":[],"sources":["../../../../../src/components/backoffice/detail/backofficeKpiStrip.css.ts"],"sourcesContent":["import { sprinkles } from '@plumile/ui/theme/sprinkles.css.js';\n\nexport const group = sprinkles({\n display: 'grid',\n gap: 3,\n gridTemplateColumns: 'autoFitMinmax180',\n});\n\nexport const compactGroup = sprinkles({\n gap: 2,\n});\n\nexport const card = sprinkles({\n minWidth: 0,\n});\n\nexport const value = sprinkles({\n display: 'flex',\n alignItems: 'center',\n gap: 2,\n});\n"],"mappings":""}
1
+ {"version":3,"file":"backofficeKpiStrip.css.js","names":[],"sources":["../../../../../src/components/backoffice/detail/backofficeKpiStrip.css.ts"],"sourcesContent":["import { recipe } from '@vanilla-extract/recipes';\nimport { sprinkles } from '@plumile/ui/theme/sprinkles.css.js';\nimport { vars } from '@plumile/ui/theme/themeContract.css.js';\n\nexport const group = sprinkles({\n display: 'grid',\n gap: 3,\n gridTemplateColumns: 'autoFitMinmax180',\n});\n\nexport const compactGroup = sprinkles({\n gap: 2,\n});\n\nexport const card = sprinkles({\n minWidth: 0,\n});\n\nexport const cardTone = recipe({\n variants: {\n tone: {\n neutral: {\n backgroundImage: `linear-gradient(135deg, color-mix(in srgb, ${vars.colors.primaryLight} 26%, transparent), transparent 58%)`,\n boxShadow: `inset 3px 0 0 color-mix(in srgb, ${vars.colors.primary} 42%, transparent)`,\n },\n info: {\n backgroundImage: `linear-gradient(135deg, ${vars.colors.infoLight}, transparent 58%)`,\n boxShadow: `inset 3px 0 0 ${vars.colors.info}`,\n },\n success: {\n backgroundImage: `linear-gradient(135deg, ${vars.colors.successLight}, transparent 58%)`,\n boxShadow: `inset 3px 0 0 ${vars.colors.success}`,\n },\n warning: {\n backgroundImage: `linear-gradient(135deg, ${vars.colors.warningLight}, transparent 58%)`,\n boxShadow: `inset 3px 0 0 ${vars.colors.warning}`,\n },\n danger: {\n backgroundImage: `linear-gradient(135deg, ${vars.colors['error-8']}, transparent 58%)`,\n boxShadow: `inset 3px 0 0 ${vars.colors.error}`,\n },\n },\n },\n});\n\nexport const value = sprinkles({\n display: 'flex',\n alignItems: 'center',\n gap: 2,\n});\n"],"mappings":""}
@@ -1,69 +1,83 @@
1
1
  import { useBackofficeReactTranslation as e } from "../../../i18n/useBackofficeReactTranslation.js";
2
- import { actions as t, container as n } from "./deferredFilterSearchInput.css.js";
3
- import { useEffect as r, useState as i } from "react";
4
- import { jsx as a, jsxs as o } from "react/jsx-runtime";
5
- import { Button as s } from "@plumile/ui/atomic/atoms/button/Button.js";
6
- import { Input as c } from "@plumile/ui/atomic/atoms/input/Input.js";
7
- import { SidebarSearchSvg as l } from "@plumile/ui/icons/SidebarSearchSvg.js";
2
+ import { actionButton as t, actionButtonSpacer as n, actions as r, container as i } from "./deferredFilterSearchInput.css.js";
3
+ import { useEffect as a, useState as o } from "react";
4
+ import { jsx as s, jsxs as c } from "react/jsx-runtime";
5
+ import { Input as l } from "@plumile/ui/atomic/atoms/input/Input.js";
6
+ import { ModalCloseSvg as u } from "@plumile/ui/icons/ModalCloseSvg.js";
7
+ import { CheckSvg as d } from "@plumile/ui/icons/CheckSvg.js";
8
+ import { SidebarSearchSvg as f } from "@plumile/ui/icons/SidebarSearchSvg.js";
8
9
  //#region src/components/backoffice/filters/DeferredFilterSearchInput.tsx
9
- var u = ({ value: u, placeholder: d, ariaLabel: f, className: p, inputMode: m = "search", type: h = "search", onApply: g }) => {
10
- let { t: _ } = e(), [v, y] = i(u);
11
- r(() => {
12
- y(u);
13
- }, [u]);
14
- let b = v.trim(), x = u.trim(), S = b !== "", C = b !== x, w = S || x !== "", T = "secondary";
15
- C && (T = "primary");
16
- let E = () => {
17
- C && g(b);
18
- };
19
- return /* @__PURE__ */ a("form", {
20
- className: p,
10
+ var p = ({ value: p, placeholder: m, ariaLabel: h, className: g, inputMode: _ = "search", type: v = "text", onApply: y }) => {
11
+ let { t: b } = e(), [x, S] = o(p);
12
+ a(() => {
13
+ S(p);
14
+ }, [p]);
15
+ let C = x.trim(), w = p.trim(), T = C !== "", E = C !== w, D = T || w !== "", O = h ?? m, k = b("filters.actions.clearFilter", { label: O }), A = b("filters.actions.applyFilter", { label: O }), j = () => {
16
+ E && y(C);
17
+ }, M = () => {
18
+ S(""), w !== "" && y("");
19
+ }, N = /* @__PURE__ */ s("span", {
20
+ className: n,
21
+ "aria-hidden": "true"
22
+ });
23
+ return D && (N = /* @__PURE__ */ s("button", {
24
+ type: "button",
25
+ className: t,
26
+ "aria-label": k,
27
+ title: k,
28
+ onClick: M,
29
+ children: /* @__PURE__ */ s(u, {
30
+ width: 16,
31
+ height: 16,
32
+ "aria-hidden": "true"
33
+ })
34
+ })), /* @__PURE__ */ s("form", {
35
+ className: g,
21
36
  onSubmit: (e) => {
22
- e.preventDefault(), E();
37
+ e.preventDefault(), j();
23
38
  },
24
- children: /* @__PURE__ */ o("div", {
25
- className: n,
26
- children: [/* @__PURE__ */ a(c, {
27
- type: h,
28
- inputMode: m,
29
- value: v,
30
- onChange: (e) => {
31
- y(e.target.value);
39
+ children: /* @__PURE__ */ s("div", {
40
+ className: i,
41
+ children: /* @__PURE__ */ s(l, {
42
+ type: v,
43
+ inputMode: _,
44
+ value: x,
45
+ onInput: (e) => {
46
+ S(e.currentTarget.value);
32
47
  },
33
48
  onKeyDown: (e) => {
34
- e.key === "Escape" && (e.preventDefault(), y(u));
49
+ e.key === "Enter" && (e.preventDefault(), j()), e.key === "Escape" && (e.preventDefault(), S(p));
35
50
  },
36
- placeholder: d,
37
- "aria-label": f ?? d,
51
+ placeholder: m,
52
+ "aria-label": O,
38
53
  size: "small",
39
54
  fullWidth: !0,
40
- leftIcon: /* @__PURE__ */ a(l, {
55
+ leftIcon: /* @__PURE__ */ s(f, {
41
56
  width: 18,
42
57
  height: 18,
43
58
  "aria-hidden": "true"
59
+ }),
60
+ rightIconIsInteractive: !0,
61
+ rightIcon: /* @__PURE__ */ c("span", {
62
+ className: r,
63
+ children: [N, /* @__PURE__ */ s("button", {
64
+ type: "submit",
65
+ className: t,
66
+ "aria-label": A,
67
+ title: A,
68
+ disabled: !E,
69
+ children: /* @__PURE__ */ s(d, {
70
+ width: 16,
71
+ height: 16,
72
+ "aria-hidden": "true"
73
+ })
74
+ })]
44
75
  })
45
- }), /* @__PURE__ */ o("div", {
46
- className: t,
47
- children: [w && /* @__PURE__ */ a(s, {
48
- type: "button",
49
- variant: "text",
50
- size: "small",
51
- onClick: () => {
52
- y(""), x !== "" && g("");
53
- },
54
- children: _("common.actions.clear")
55
- }), /* @__PURE__ */ a(s, {
56
- type: "submit",
57
- variant: T,
58
- size: "small",
59
- disabled: !C,
60
- children: _("filters.actions.apply")
61
- })]
62
- })]
76
+ })
63
77
  })
64
78
  });
65
79
  };
66
80
  //#endregion
67
- export { u as DeferredFilterSearchInput, u as default };
81
+ export { p as DeferredFilterSearchInput, p as default };
68
82
 
69
83
  //# sourceMappingURL=DeferredFilterSearchInput.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"DeferredFilterSearchInput.js","names":[],"sources":["../../../../../src/components/backoffice/filters/DeferredFilterSearchInput.tsx"],"sourcesContent":["import {\n useEffect,\n useState,\n type ChangeEvent,\n type FormEvent,\n type JSX,\n type KeyboardEvent,\n} from 'react';\n\nimport { Button } from '@plumile/ui/atomic/atoms/button/Button.js';\nimport { Input } from '@plumile/ui/atomic/atoms/input/Input.js';\nimport { SidebarSearchSvg } from '@plumile/ui/icons/SidebarSearchSvg.js';\n\nimport { useBackofficeReactTranslation } from '../../../i18n/useBackofficeReactTranslation.js';\n\nimport * as styles from './deferredFilterSearchInput.css.js';\n\nexport type DeferredFilterSearchInputProps = {\n value: string;\n placeholder: string;\n ariaLabel?: string;\n className?: string;\n inputMode?: 'search' | 'numeric' | 'decimal';\n type?: 'search' | 'number' | 'datetime-local';\n onApply: (value: string) => void;\n};\n\nexport const DeferredFilterSearchInput = ({\n value,\n placeholder,\n ariaLabel,\n className,\n inputMode = 'search',\n type = 'search',\n onApply,\n}: DeferredFilterSearchInputProps): JSX.Element => {\n const { t } = useBackofficeReactTranslation();\n const [draftValue, setDraftValue] = useState(value);\n\n useEffect(() => {\n setDraftValue(value);\n }, [value]);\n\n const normalizedDraft = draftValue.trim();\n const normalizedValue = value.trim();\n const hasDraft = normalizedDraft !== '';\n const hasPendingValue = normalizedDraft !== normalizedValue;\n const canClear = hasDraft || normalizedValue !== '';\n let submitVariant: 'primary' | 'secondary' = 'secondary';\n if (hasPendingValue) {\n submitVariant = 'primary';\n }\n\n const applyDraft = () => {\n if (!hasPendingValue) {\n return;\n }\n onApply(normalizedDraft);\n };\n\n const clearValue = () => {\n setDraftValue('');\n if (normalizedValue !== '') {\n onApply('');\n }\n };\n\n return (\n <form\n className={className}\n onSubmit={(event: FormEvent<HTMLFormElement>) => {\n event.preventDefault();\n applyDraft();\n }}\n >\n <div className={styles.container}>\n <Input\n type={type}\n inputMode={inputMode}\n value={draftValue}\n onChange={(event: ChangeEvent<HTMLInputElement>) => {\n setDraftValue(event.target.value);\n }}\n onKeyDown={(event: KeyboardEvent<HTMLInputElement>) => {\n if (event.key === 'Escape') {\n event.preventDefault();\n setDraftValue(value);\n }\n }}\n placeholder={placeholder}\n aria-label={ariaLabel ?? placeholder}\n size=\"small\"\n fullWidth\n leftIcon={\n <SidebarSearchSvg width={18} height={18} aria-hidden=\"true\" />\n }\n />\n <div className={styles.actions}>\n {canClear && (\n <Button\n type=\"button\"\n variant=\"text\"\n size=\"small\"\n onClick={clearValue}\n >\n {t('common.actions.clear')}\n </Button>\n )}\n <Button\n type=\"submit\"\n variant={submitVariant}\n size=\"small\"\n disabled={!hasPendingValue}\n >\n {t('filters.actions.apply')}\n </Button>\n </div>\n </div>\n </form>\n );\n};\n\nexport default DeferredFilterSearchInput;\n"],"mappings":";;;;;;;;AA2BA,IAAa,KAA6B,EACxC,UACA,gBACA,cACA,cACA,eAAY,UACZ,UAAO,UACP,iBACiD;CACjD,IAAM,EAAE,SAAM,GAA+B,EACvC,CAAC,GAAY,KAAiB,EAAS,EAAM;CAEnD,QAAgB;EACd,EAAc,EAAM;IACnB,CAAC,EAAM,CAAC;CAEX,IAAM,IAAkB,EAAW,MAAM,EACnC,IAAkB,EAAM,MAAM,EAC9B,IAAW,MAAoB,IAC/B,IAAkB,MAAoB,GACtC,IAAW,KAAY,MAAoB,IAC7C,IAAyC;CAC7C,AAAI,MACF,IAAgB;CAGlB,IAAM,UAAmB;EAClB,KAGL,EAAQ,EAAgB;;CAU1B,OACE,kBAAC,QAAD;EACa;EACX,WAAW,MAAsC;GAE/C,AADA,EAAM,gBAAgB,EACtB,GAAY;;YAGd,kBAAC,OAAD;GAAK,WAAW;aAAhB,CACE,kBAAC,GAAD;IACQ;IACK;IACX,OAAO;IACP,WAAW,MAAyC;KAClD,EAAc,EAAM,OAAO,MAAM;;IAEnC,YAAY,MAA2C;KACrD,AAAI,EAAM,QAAQ,aAChB,EAAM,gBAAgB,EACtB,EAAc,EAAM;;IAGX;IACb,cAAY,KAAa;IACzB,MAAK;IACL,WAAA;IACA,UACE,kBAAC,GAAD;KAAkB,OAAO;KAAI,QAAQ;KAAI,eAAY;KAAS,CAAA;IAEhE,CAAA,EACF,kBAAC,OAAD;IAAK,WAAW;cAAhB,CACG,KACC,kBAAC,GAAD;KACE,MAAK;KACL,SAAQ;KACR,MAAK;KACL,eA3Ca;MAEvB,AADA,EAAc,GAAG,EACb,MAAoB,MACtB,EAAQ,GAAG;;eA0CF,EAAE,uBAAuB;KACnB,CAAA,EAEX,kBAAC,GAAD;KACE,MAAK;KACL,SAAS;KACT,MAAK;KACL,UAAU,CAAC;eAEV,EAAE,wBAAwB;KACpB,CAAA,CACL;MACF;;EACD,CAAA"}
1
+ {"version":3,"file":"DeferredFilterSearchInput.js","names":[],"sources":["../../../../../src/components/backoffice/filters/DeferredFilterSearchInput.tsx"],"sourcesContent":["import {\n useEffect,\n useState,\n type FormEvent,\n type JSX,\n type KeyboardEvent,\n} from 'react';\n\nimport { Input } from '@plumile/ui/atomic/atoms/input/Input.js';\nimport { CheckSvg } from '@plumile/ui/icons/CheckSvg.js';\nimport { ModalCloseSvg } from '@plumile/ui/icons/ModalCloseSvg.js';\nimport { SidebarSearchSvg } from '@plumile/ui/icons/SidebarSearchSvg.js';\n\nimport { useBackofficeReactTranslation } from '../../../i18n/useBackofficeReactTranslation.js';\n\nimport * as styles from './deferredFilterSearchInput.css.js';\n\nexport type DeferredFilterSearchInputProps = {\n value: string;\n placeholder: string;\n ariaLabel?: string;\n className?: string;\n inputMode?: 'search' | 'numeric' | 'decimal';\n type?: 'search' | 'text' | 'number' | 'datetime-local';\n onApply: (value: string) => void;\n};\n\nexport const DeferredFilterSearchInput = ({\n value,\n placeholder,\n ariaLabel,\n className,\n inputMode = 'search',\n type = 'text',\n onApply,\n}: DeferredFilterSearchInputProps): JSX.Element => {\n const { t } = useBackofficeReactTranslation();\n const [draftValue, setDraftValue] = useState(value);\n\n useEffect(() => {\n setDraftValue(value);\n }, [value]);\n\n const normalizedDraft = draftValue.trim();\n const normalizedValue = value.trim();\n const hasDraft = normalizedDraft !== '';\n const hasPendingValue = normalizedDraft !== normalizedValue;\n const canClear = hasDraft || normalizedValue !== '';\n const inputLabel = ariaLabel ?? placeholder;\n const clearLabel = t('filters.actions.clearFilter', { label: inputLabel });\n const applyLabel = t('filters.actions.applyFilter', { label: inputLabel });\n\n const applyDraft = () => {\n if (!hasPendingValue) {\n return;\n }\n onApply(normalizedDraft);\n };\n\n const clearValue = () => {\n setDraftValue('');\n if (normalizedValue !== '') {\n onApply('');\n }\n };\n\n let clearActionNode: JSX.Element = (\n <span className={styles.actionButtonSpacer} aria-hidden=\"true\" />\n );\n if (canClear) {\n clearActionNode = (\n <button\n type=\"button\"\n className={styles.actionButton}\n aria-label={clearLabel}\n title={clearLabel}\n onClick={clearValue}\n >\n <ModalCloseSvg width={16} height={16} aria-hidden=\"true\" />\n </button>\n );\n }\n\n return (\n <form\n className={className}\n onSubmit={(event: FormEvent<HTMLFormElement>) => {\n event.preventDefault();\n applyDraft();\n }}\n >\n <div className={styles.container}>\n <Input\n type={type}\n inputMode={inputMode}\n value={draftValue}\n onInput={(event: FormEvent<HTMLInputElement>) => {\n setDraftValue(event.currentTarget.value);\n }}\n onKeyDown={(event: KeyboardEvent<HTMLInputElement>) => {\n if (event.key === 'Enter') {\n event.preventDefault();\n applyDraft();\n }\n if (event.key === 'Escape') {\n event.preventDefault();\n setDraftValue(value);\n }\n }}\n placeholder={placeholder}\n aria-label={inputLabel}\n size=\"small\"\n fullWidth\n leftIcon={\n <SidebarSearchSvg width={18} height={18} aria-hidden=\"true\" />\n }\n rightIconIsInteractive\n rightIcon={\n <span className={styles.actions}>\n {clearActionNode}\n <button\n type=\"submit\"\n className={styles.actionButton}\n aria-label={applyLabel}\n title={applyLabel}\n disabled={!hasPendingValue}\n >\n <CheckSvg width={16} height={16} aria-hidden=\"true\" />\n </button>\n </span>\n }\n />\n </div>\n </form>\n );\n};\n\nexport default DeferredFilterSearchInput;\n"],"mappings":";;;;;;;;;AA2BA,IAAa,KAA6B,EACxC,UACA,gBACA,cACA,cACA,eAAY,UACZ,UAAO,QACP,iBACiD;CACjD,IAAM,EAAE,SAAM,GAA+B,EACvC,CAAC,GAAY,KAAiB,EAAS,EAAM;CAEnD,QAAgB;EACd,EAAc,EAAM;IACnB,CAAC,EAAM,CAAC;CAEX,IAAM,IAAkB,EAAW,MAAM,EACnC,IAAkB,EAAM,MAAM,EAC9B,IAAW,MAAoB,IAC/B,IAAkB,MAAoB,GACtC,IAAW,KAAY,MAAoB,IAC3C,IAAa,KAAa,GAC1B,IAAa,EAAE,+BAA+B,EAAE,OAAO,GAAY,CAAC,EACpE,IAAa,EAAE,+BAA+B,EAAE,OAAO,GAAY,CAAC,EAEpE,UAAmB;EAClB,KAGL,EAAQ,EAAgB;IAGpB,UAAmB;EAEvB,AADA,EAAc,GAAG,EACb,MAAoB,MACtB,EAAQ,GAAG;IAIX,IACF,kBAAC,QAAD;EAAM,WAAW;EAA2B,eAAY;EAAS,CAAA;CAgBnE,OAdI,MACF,IACE,kBAAC,UAAD;EACE,MAAK;EACL,WAAW;EACX,cAAY;EACZ,OAAO;EACP,SAAS;YAET,kBAAC,GAAD;GAAe,OAAO;GAAI,QAAQ;GAAI,eAAY;GAAS,CAAA;EACpD,CAAA,GAKX,kBAAC,QAAD;EACa;EACX,WAAW,MAAsC;GAE/C,AADA,EAAM,gBAAgB,EACtB,GAAY;;YAGd,kBAAC,OAAD;GAAK,WAAW;aACd,kBAAC,GAAD;IACQ;IACK;IACX,OAAO;IACP,UAAU,MAAuC;KAC/C,EAAc,EAAM,cAAc,MAAM;;IAE1C,YAAY,MAA2C;KAKrD,AAJI,EAAM,QAAQ,YAChB,EAAM,gBAAgB,EACtB,GAAY,GAEV,EAAM,QAAQ,aAChB,EAAM,gBAAgB,EACtB,EAAc,EAAM;;IAGX;IACb,cAAY;IACZ,MAAK;IACL,WAAA;IACA,UACE,kBAAC,GAAD;KAAkB,OAAO;KAAI,QAAQ;KAAI,eAAY;KAAS,CAAA;IAEhE,wBAAA;IACA,WACE,kBAAC,QAAD;KAAM,WAAW;eAAjB,CACG,GACD,kBAAC,UAAD;MACE,MAAK;MACL,WAAW;MACX,cAAY;MACZ,OAAO;MACP,UAAU,CAAC;gBAEX,kBAAC,GAAD;OAAU,OAAO;OAAI,QAAQ;OAAI,eAAY;OAAS,CAAA;MAC/C,CAAA,CACJ;;IAET,CAAA;GACE,CAAA;EACD,CAAA"}
@@ -1,98 +1,93 @@
1
1
  import { useBackofficeReactTranslation as e } from "../../../i18n/useBackofficeReactTranslation.js";
2
2
  import { actionIcon as t, clearButton as n, container as r, content as i, labelText as a, pickActionButton as o, pickerButton as s, pickerControl as c, placeholder as l, valueText as u } from "./entityIdFilterField.css.js";
3
3
  import { jsx as d, jsxs as f } from "react/jsx-runtime";
4
- import { BackofficeSidebarPenToolSvg as p } from "@plumile/ui/icons/backoffice/BackofficeSidebarPenToolSvg.js";
5
- import { BackofficeSidebarSearchSvg as m } from "@plumile/ui/icons/backoffice/BackofficeSidebarSearchSvg.js";
4
+ import { ModalCloseSvg as p } from "@plumile/ui/icons/ModalCloseSvg.js";
5
+ import { BackofficeSidebarPenToolSvg as m } from "@plumile/ui/icons/backoffice/BackofficeSidebarPenToolSvg.js";
6
+ import { BackofficeSidebarSearchSvg as h } from "@plumile/ui/icons/backoffice/BackofficeSidebarSearchSvg.js";
6
7
  //#region src/components/backoffice/filters/EntityIdFilterField.tsx
7
- var h = (h) => {
8
- let { disabled: g = !1, id: _, label: v, value: y, displayValue: b, placeholder: x, ariaDescribedBy: S, ariaInvalid: C, isResolving: w = !1, onPick: T, onClear: E } = h, { t: D } = e(), O = y?.trim() ?? "", k = b?.trim() ?? "", A = O !== "", j = k !== "", M = x ?? D("filters.placeholders.anyEntity", { label: v }), N = D("filters.placeholders.unresolved"), P;
9
- P = j ? /* @__PURE__ */ d("span", {
8
+ var g = (g) => {
9
+ let { disabled: _ = !1, id: v, label: y, value: b, displayValue: x, placeholder: S, ariaDescribedBy: C, ariaInvalid: w, isResolving: T = !1, onPick: E, onClear: D } = g, { t: O } = e(), k = b?.trim() ?? "", A = x?.trim() ?? "", j = k !== "", M = A !== "", N = S ?? O("filters.placeholders.anyEntity", { label: y }), P = O("filters.placeholders.unresolved"), F;
10
+ F = M ? /* @__PURE__ */ d("span", {
10
11
  className: u,
11
- children: k
12
- }) : A ? /* @__PURE__ */ d("span", {
12
+ children: A
13
+ }) : j ? /* @__PURE__ */ d("span", {
13
14
  className: l,
14
- children: N
15
+ children: P
15
16
  }) : /* @__PURE__ */ d("span", {
16
17
  className: l,
17
- children: M
18
+ children: N
18
19
  });
19
- let F = D("common.actions.pick");
20
- A && (F = D("common.actions.change"));
21
- let I = `${F} ${v}`, L = `${D("common.actions.clear")} ${v}`, R = null;
22
- A && E != null && (R = /* @__PURE__ */ d("button", {
20
+ let I = O("common.actions.pick");
21
+ j && (I = O("filters.actions.changeFilterValue", { label: y }));
22
+ let L = O("filters.actions.filterBy", { label: y });
23
+ j && (L = I);
24
+ let R = O("filters.actions.clearFilter", { label: y }), z = null;
25
+ j && D != null && (z = /* @__PURE__ */ d("button", {
23
26
  type: "button",
24
27
  className: n,
25
- "aria-label": L,
26
- disabled: g,
28
+ "aria-label": R,
29
+ disabled: _,
27
30
  onClick: (e) => {
28
- e.stopPropagation(), E();
31
+ e.stopPropagation(), D();
29
32
  },
30
- children: /* @__PURE__ */ d("svg", {
31
- width: "12",
32
- height: "12",
33
- viewBox: "0 0 12 12",
34
- fill: "none",
35
- "aria-hidden": "true",
36
- children: /* @__PURE__ */ d("path", {
37
- d: "M3 3L9 9M9 3L3 9",
38
- stroke: "currentColor",
39
- strokeWidth: "1.6",
40
- strokeLinecap: "round"
41
- })
33
+ children: /* @__PURE__ */ d(p, {
34
+ width: 16,
35
+ height: 16,
36
+ "aria-hidden": "true"
42
37
  })
43
38
  }));
44
- let z = null;
45
- if (T != null) {
46
- let e = /* @__PURE__ */ d(m, {
39
+ let B = null;
40
+ if (E != null) {
41
+ let e = /* @__PURE__ */ d(h, {
47
42
  className: t,
48
43
  "aria-hidden": "true"
49
44
  });
50
- A && (e = /* @__PURE__ */ d(p, {
45
+ j && (e = /* @__PURE__ */ d(m, {
51
46
  className: t,
52
47
  "aria-hidden": "true"
53
- })), z = /* @__PURE__ */ f("div", {
48
+ })), B = /* @__PURE__ */ f("div", {
54
49
  className: c,
55
50
  children: [
56
51
  /* @__PURE__ */ d("button", {
57
- id: _,
52
+ id: v,
58
53
  type: "button",
59
54
  className: s,
60
- "aria-label": I,
61
- "aria-describedby": S,
62
- "aria-invalid": C,
63
- "aria-busy": w || void 0,
64
- disabled: g,
65
- onClick: T,
55
+ "aria-label": L,
56
+ "aria-describedby": C,
57
+ "aria-invalid": w,
58
+ "aria-busy": T || void 0,
59
+ disabled: _,
60
+ onClick: E,
66
61
  children: /* @__PURE__ */ f("span", {
67
62
  className: i,
68
63
  children: [/* @__PURE__ */ d("span", {
69
64
  className: a,
70
- children: v
71
- }), P]
65
+ children: y
66
+ }), F]
72
67
  })
73
68
  }),
74
69
  /* @__PURE__ */ d("button", {
75
70
  type: "button",
76
71
  className: o,
77
- "aria-label": I,
78
- title: I,
79
- disabled: g,
80
- onClick: T,
72
+ "aria-label": L,
73
+ title: L,
74
+ disabled: _,
75
+ onClick: E,
81
76
  children: e
82
77
  }),
83
- R
78
+ z
84
79
  ]
85
80
  });
86
81
  }
87
82
  return /* @__PURE__ */ d("div", {
88
83
  className: r,
89
- children: z ?? /* @__PURE__ */ d("div", {
84
+ children: B ?? /* @__PURE__ */ d("div", {
90
85
  className: "txvbqbdxd txvbqbt9i txvbqbdr8 txvbqbey txvbqbusr",
91
- children: P
86
+ children: F
92
87
  })
93
88
  });
94
89
  };
95
90
  //#endregion
96
- export { h as EntityIdFilterField, h as default };
91
+ export { g as EntityIdFilterField, g as default };
97
92
 
98
93
  //# sourceMappingURL=EntityIdFilterField.js.map