@plumile/backoffice-react 0.1.201 → 0.1.206

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 (192) hide show
  1. package/README.md +11 -4
  2. package/lib/esm/auth/login/LoginFlow.js.map +1 -1
  3. package/lib/esm/auth/pages/AcceptInvitationScreen.js.map +1 -1
  4. package/lib/esm/auth/pages/PasswordResetCompleteScreen.js.map +1 -1
  5. package/lib/esm/auth/pages/PasswordResetRequestScreen.js.map +1 -1
  6. package/lib/esm/components/backoffice/detail/BackofficeEntitySummaryHeader.js +28 -28
  7. package/lib/esm/components/backoffice/detail/BackofficeEntitySummaryHeader.js.map +1 -1
  8. package/lib/esm/components/backoffice/pickers/EntityIdPickerDialog.js +123 -70
  9. package/lib/esm/components/backoffice/pickers/EntityIdPickerDialog.js.map +1 -1
  10. package/lib/esm/components/backoffice/scaffolds/BackofficeEntityListScaffold.js +206 -204
  11. package/lib/esm/components/backoffice/scaffolds/BackofficeEntityListScaffold.js.map +1 -1
  12. package/lib/esm/hooks/useAuth.js +56 -56
  13. package/lib/esm/hooks/useAuth.js.map +1 -1
  14. package/lib/esm/hooks/useConditionalSubscription.js +18 -18
  15. package/lib/esm/hooks/useConditionalSubscription.js.map +1 -1
  16. package/lib/esm/hooks/useInfiniteConnection.js +40 -38
  17. package/lib/esm/hooks/useInfiniteConnection.js.map +1 -1
  18. package/lib/esm/i18n/locales/en/backofficeReact.js +1 -0
  19. package/lib/esm/i18n/locales/en/backofficeReact.js.map +1 -1
  20. package/lib/esm/i18n/locales/fr/backofficeReact.js +1 -0
  21. package/lib/esm/i18n/locales/fr/backofficeReact.js.map +1 -1
  22. package/lib/esm/index.js +56 -64
  23. package/lib/esm/pages/BackofficeEntityDetailPage.js +97 -97
  24. package/lib/esm/pages/BackofficeEntityDetailPage.js.map +1 -1
  25. package/lib/esm/pages/BackofficeEntityListDataPage.js +39 -31
  26. package/lib/esm/pages/BackofficeEntityListDataPage.js.map +1 -1
  27. package/lib/esm/pages/BackofficeEntityListPage.js +2 -0
  28. package/lib/esm/pages/BackofficeEntityListPage.js.map +1 -1
  29. package/lib/esm/pages/BackofficeLayoutPage.js +19 -19
  30. package/lib/esm/pages/BackofficeLayoutPage.js.map +1 -1
  31. package/lib/esm/provider/BackofficeProvider.js +33 -33
  32. package/lib/esm/router/createBackofficeRoutes.js +26 -28
  33. package/lib/esm/router/createBackofficeRoutes.js.map +1 -1
  34. package/lib/esm/storybook/relay/RelayStory.js +32 -32
  35. package/lib/esm/storybook/relay/RelayStory.js.map +1 -1
  36. package/lib/esm/storybook/relay/mockResolvers.js.map +1 -1
  37. package/lib/esm/style.css +1 -1
  38. package/lib/types/components/backoffice/detail/BackofficeEntitySummaryHeader.d.ts +1 -1
  39. package/lib/types/components/backoffice/detail/BackofficeEntitySummaryHeader.d.ts.map +1 -1
  40. package/lib/types/components/backoffice/pickers/EntityIdPickerDialog.d.ts.map +1 -1
  41. package/lib/types/components/backoffice/scaffolds/BackofficeEntityListScaffold.d.ts +2 -0
  42. package/lib/types/components/backoffice/scaffolds/BackofficeEntityListScaffold.d.ts.map +1 -1
  43. package/lib/types/hooks/useAuth.d.ts.map +1 -1
  44. package/lib/types/hooks/useConditionalSubscription.d.ts.map +1 -1
  45. package/lib/types/hooks/useInfiniteConnection.d.ts +3 -2
  46. package/lib/types/hooks/useInfiniteConnection.d.ts.map +1 -1
  47. package/lib/types/i18n/locales/en/backofficeReact.d.ts +5 -0
  48. package/lib/types/i18n/locales/fr/backofficeReact.d.ts +5 -0
  49. package/lib/types/i18n/resources.d.ts +2 -0
  50. package/lib/types/i18n/resources.d.ts.map +1 -1
  51. package/lib/types/index.d.ts +1 -9
  52. package/lib/types/index.d.ts.map +1 -1
  53. package/lib/types/pages/BackofficeEntityListDataPage.d.ts.map +1 -1
  54. package/lib/types/pages/BackofficeEntityListPage.d.ts.map +1 -1
  55. package/lib/types/pages/BackofficeLayoutPage.d.ts.map +1 -1
  56. package/lib/types/router/createBackofficeRoutes.d.ts +3 -3
  57. package/lib/types/router/createBackofficeRoutes.d.ts.map +1 -1
  58. package/lib/types/storybook/relay/RelayStory.d.ts +1 -1
  59. package/lib/types/storybook/relay/RelayStory.d.ts.map +1 -1
  60. package/lib/types/storybook/relay/mockResolvers.d.ts +9 -1
  61. package/lib/types/storybook/relay/mockResolvers.d.ts.map +1 -1
  62. package/package.json +12 -15
  63. package/lib/esm/_virtual/_rolldown/runtime.js +0 -7
  64. package/lib/esm/components/backoffice/detail/BackofficeDetailFlagTag.js +0 -13
  65. package/lib/esm/components/backoffice/detail/BackofficeDetailFlagTag.js.map +0 -1
  66. package/lib/esm/components/backoffice/detail/BackofficeDetailTaggedValue.js +0 -12
  67. package/lib/esm/components/backoffice/detail/BackofficeDetailTaggedValue.js.map +0 -1
  68. package/lib/esm/components/backoffice/detail/BackofficeEnumLabel.js +0 -16
  69. package/lib/esm/components/backoffice/detail/BackofficeEnumLabel.js.map +0 -1
  70. package/lib/esm/components/backoffice/detail/BackofficeReferenceValue.js +0 -17
  71. package/lib/esm/components/backoffice/detail/BackofficeReferenceValue.js.map +0 -1
  72. package/lib/esm/components/backoffice/detail/BackofficeStatusGroup.js +0 -8
  73. package/lib/esm/components/backoffice/detail/BackofficeStatusGroup.js.map +0 -1
  74. package/lib/esm/components/backoffice/detail/BackofficeStatusMetaBadge.js +0 -16
  75. package/lib/esm/components/backoffice/detail/BackofficeStatusMetaBadge.js.map +0 -1
  76. package/lib/esm/components/backoffice/detail/backofficeDetailRelationLink.css.js +0 -6
  77. package/lib/esm/components/backoffice/detail/backofficeDetailRelationLink.css.js.map +0 -1
  78. package/lib/esm/components/backoffice/refs/backofficeEntityIdRef.css.js +0 -6
  79. package/lib/esm/components/backoffice/refs/backofficeEntityIdRef.css.js.map +0 -1
  80. package/lib/esm/components/backoffice/routing/BackofficeRoutePendingBar.js +0 -12
  81. package/lib/esm/components/backoffice/routing/BackofficeRoutePendingBar.js.map +0 -1
  82. package/lib/esm/components/backoffice/routing/backofficeRoutePendingBar.css.js +0 -7
  83. package/lib/esm/components/backoffice/routing/backofficeRoutePendingBar.css.js.map +0 -1
  84. package/lib/esm/hooks/useBackofficeLoadMore.js +0 -18
  85. package/lib/esm/hooks/useBackofficeLoadMore.js.map +0 -1
  86. package/lib/esm/modules/base64.js +0 -21
  87. package/lib/esm/modules/base64.js.map +0 -1
  88. package/lib/esm/node_modules/@babel/runtime/helpers/arrayLikeToArray.js +0 -15
  89. package/lib/esm/node_modules/@babel/runtime/helpers/arrayLikeToArray.js.map +0 -1
  90. package/lib/esm/node_modules/@babel/runtime/helpers/arrayWithoutHoles.js +0 -15
  91. package/lib/esm/node_modules/@babel/runtime/helpers/arrayWithoutHoles.js.map +0 -1
  92. package/lib/esm/node_modules/@babel/runtime/helpers/defineProperty.js +0 -20
  93. package/lib/esm/node_modules/@babel/runtime/helpers/defineProperty.js.map +0 -1
  94. package/lib/esm/node_modules/@babel/runtime/helpers/interopRequireDefault.js +0 -13
  95. package/lib/esm/node_modules/@babel/runtime/helpers/interopRequireDefault.js.map +0 -1
  96. package/lib/esm/node_modules/@babel/runtime/helpers/iterableToArray.js +0 -13
  97. package/lib/esm/node_modules/@babel/runtime/helpers/iterableToArray.js.map +0 -1
  98. package/lib/esm/node_modules/@babel/runtime/helpers/nonIterableSpread.js +0 -13
  99. package/lib/esm/node_modules/@babel/runtime/helpers/nonIterableSpread.js.map +0 -1
  100. package/lib/esm/node_modules/@babel/runtime/helpers/objectSpread2.js +0 -33
  101. package/lib/esm/node_modules/@babel/runtime/helpers/objectSpread2.js.map +0 -1
  102. package/lib/esm/node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js +0 -19
  103. package/lib/esm/node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js.map +0 -1
  104. package/lib/esm/node_modules/@babel/runtime/helpers/toConsumableArray.js +0 -18
  105. package/lib/esm/node_modules/@babel/runtime/helpers/toConsumableArray.js.map +0 -1
  106. package/lib/esm/node_modules/@babel/runtime/helpers/toPrimitive.js +0 -22
  107. package/lib/esm/node_modules/@babel/runtime/helpers/toPrimitive.js.map +0 -1
  108. package/lib/esm/node_modules/@babel/runtime/helpers/toPropertyKey.js +0 -17
  109. package/lib/esm/node_modules/@babel/runtime/helpers/toPropertyKey.js.map +0 -1
  110. package/lib/esm/node_modules/@babel/runtime/helpers/typeof.js +0 -18
  111. package/lib/esm/node_modules/@babel/runtime/helpers/typeof.js.map +0 -1
  112. package/lib/esm/node_modules/@babel/runtime/helpers/unsupportedIterableToArray.js +0 -19
  113. package/lib/esm/node_modules/@babel/runtime/helpers/unsupportedIterableToArray.js.map +0 -1
  114. package/lib/esm/node_modules/fbjs/lib/areEqual.js +0 -42
  115. package/lib/esm/node_modules/fbjs/lib/areEqual.js.map +0 -1
  116. package/lib/esm/node_modules/invariant/browser.js +0 -30
  117. package/lib/esm/node_modules/invariant/browser.js.map +0 -1
  118. package/lib/esm/node_modules/relay-test-utils/index.js +0 -11
  119. package/lib/esm/node_modules/relay-test-utils/index.js.map +0 -1
  120. package/lib/esm/node_modules/relay-test-utils/lib/RelayMockPayloadGenerator.js +0 -288
  121. package/lib/esm/node_modules/relay-test-utils/lib/RelayMockPayloadGenerator.js.map +0 -1
  122. package/lib/esm/node_modules/relay-test-utils/lib/RelayModernMockEnvironment.js +0 -183
  123. package/lib/esm/node_modules/relay-test-utils/lib/RelayModernMockEnvironment.js.map +0 -1
  124. package/lib/esm/node_modules/relay-test-utils/lib/RelayResolverTestUtils.js +0 -19
  125. package/lib/esm/node_modules/relay-test-utils/lib/RelayResolverTestUtils.js.map +0 -1
  126. package/lib/esm/node_modules/relay-test-utils/lib/index.js +0 -21
  127. package/lib/esm/node_modules/relay-test-utils/lib/index.js.map +0 -1
  128. package/lib/esm/node_modules/relay-test-utils/lib/unwrapContainer.js +0 -16
  129. package/lib/esm/node_modules/relay-test-utils/lib/unwrapContainer.js.map +0 -1
  130. package/lib/esm/relay/RelayProvider.js +0 -2
  131. package/lib/esm/relay/envHelpers.js +0 -63
  132. package/lib/esm/relay/envHelpers.js.map +0 -1
  133. package/lib/esm/relay/environment.js +0 -2
  134. package/lib/esm/relay/shortAccessTokenEnvironment.js +0 -2
  135. package/lib/esm/relay/useRelayOperationActivity.js +0 -2
  136. package/lib/esm/storybook/relay/relay-test-utils.d.js +0 -0
  137. package/lib/types/auth/AuthFlows.stories.d.ts +0 -19
  138. package/lib/types/auth/AuthFlows.stories.d.ts.map +0 -1
  139. package/lib/types/components/backoffice/billing/BackofficeBillingUsageChart.stories.d.ts +0 -41
  140. package/lib/types/components/backoffice/billing/BackofficeBillingUsageChart.stories.d.ts.map +0 -1
  141. package/lib/types/components/backoffice/detail/BackofficeDetailFlagTag.d.ts +0 -11
  142. package/lib/types/components/backoffice/detail/BackofficeDetailFlagTag.d.ts.map +0 -1
  143. package/lib/types/components/backoffice/detail/BackofficeDetailPrimitives.stories.d.ts +0 -17
  144. package/lib/types/components/backoffice/detail/BackofficeDetailPrimitives.stories.d.ts.map +0 -1
  145. package/lib/types/components/backoffice/detail/BackofficeDetailTaggedValue.d.ts +0 -13
  146. package/lib/types/components/backoffice/detail/BackofficeDetailTaggedValue.d.ts.map +0 -1
  147. package/lib/types/components/backoffice/detail/BackofficeEnumLabel.d.ts +0 -9
  148. package/lib/types/components/backoffice/detail/BackofficeEnumLabel.d.ts.map +0 -1
  149. package/lib/types/components/backoffice/detail/BackofficeReferenceValue.d.ts +0 -10
  150. package/lib/types/components/backoffice/detail/BackofficeReferenceValue.d.ts.map +0 -1
  151. package/lib/types/components/backoffice/detail/BackofficeStatusGroup.d.ts +0 -8
  152. package/lib/types/components/backoffice/detail/BackofficeStatusGroup.d.ts.map +0 -1
  153. package/lib/types/components/backoffice/detail/BackofficeStatusMetaBadge.d.ts +0 -11
  154. package/lib/types/components/backoffice/detail/BackofficeStatusMetaBadge.d.ts.map +0 -1
  155. package/lib/types/components/backoffice/detail/backofficeDetailRelationLink.css.d.ts +0 -6
  156. package/lib/types/components/backoffice/detail/backofficeDetailRelationLink.css.d.ts.map +0 -1
  157. package/lib/types/components/backoffice/errors/BackofficeErrorBoundary.stories.d.ts +0 -12
  158. package/lib/types/components/backoffice/errors/BackofficeErrorBoundary.stories.d.ts.map +0 -1
  159. package/lib/types/components/backoffice/filters/EntityIdFilterField.stories.d.ts +0 -12
  160. package/lib/types/components/backoffice/filters/EntityIdFilterField.stories.d.ts.map +0 -1
  161. package/lib/types/components/backoffice/hub/BackofficeHubTemplate.stories.d.ts +0 -49
  162. package/lib/types/components/backoffice/hub/BackofficeHubTemplate.stories.d.ts.map +0 -1
  163. package/lib/types/components/backoffice/overview/BackofficeOverviewLayout.stories.d.ts +0 -11
  164. package/lib/types/components/backoffice/overview/BackofficeOverviewLayout.stories.d.ts.map +0 -1
  165. package/lib/types/components/backoffice/pickers/EntityIdPickerDialog.stories.d.ts +0 -12
  166. package/lib/types/components/backoffice/pickers/EntityIdPickerDialog.stories.d.ts.map +0 -1
  167. package/lib/types/components/backoffice/refs/backofficeEntityIdRef.css.d.ts +0 -2
  168. package/lib/types/components/backoffice/refs/backofficeEntityIdRef.css.d.ts.map +0 -1
  169. package/lib/types/components/backoffice/routing/BackofficeRoutePendingBar.d.ts +0 -4
  170. package/lib/types/components/backoffice/routing/BackofficeRoutePendingBar.d.ts.map +0 -1
  171. package/lib/types/components/backoffice/routing/backofficeRoutePendingBar.css.d.ts +0 -3
  172. package/lib/types/components/backoffice/routing/backofficeRoutePendingBar.css.d.ts.map +0 -1
  173. package/lib/types/components/backoffice/scaffolds/BackofficeTabbedDetailShell.stories.d.ts +0 -11
  174. package/lib/types/components/backoffice/scaffolds/BackofficeTabbedDetailShell.stories.d.ts.map +0 -1
  175. package/lib/types/components/backoffice/tools/BackofficeTools.stories.d.ts +0 -17
  176. package/lib/types/components/backoffice/tools/BackofficeTools.stories.d.ts.map +0 -1
  177. package/lib/types/hooks/useBackofficeLoadMore.d.ts +0 -9
  178. package/lib/types/hooks/useBackofficeLoadMore.d.ts.map +0 -1
  179. package/lib/types/modules/base64.d.ts +0 -3
  180. package/lib/types/modules/base64.d.ts.map +0 -1
  181. package/lib/types/pages/BackofficeDashboardPage.stories.d.ts +0 -9
  182. package/lib/types/pages/BackofficeDashboardPage.stories.d.ts.map +0 -1
  183. package/lib/types/relay/RelayProvider.d.ts +0 -2
  184. package/lib/types/relay/RelayProvider.d.ts.map +0 -1
  185. package/lib/types/relay/envHelpers.d.ts +0 -25
  186. package/lib/types/relay/envHelpers.d.ts.map +0 -1
  187. package/lib/types/relay/environment.d.ts +0 -2
  188. package/lib/types/relay/environment.d.ts.map +0 -1
  189. package/lib/types/relay/shortAccessTokenEnvironment.d.ts +0 -5
  190. package/lib/types/relay/shortAccessTokenEnvironment.d.ts.map +0 -1
  191. package/lib/types/relay/useRelayOperationActivity.d.ts +0 -2
  192. package/lib/types/relay/useRelayOperationActivity.d.ts.map +0 -1
@@ -7,30 +7,30 @@ import { DeferredFilterSearchInput as a } from "../filters/DeferredFilterSearchI
7
7
  import { EntityFilterValue as o, EntityFilterValueText as s } from "../filters/EntityFilterValue.js";
8
8
  import { BACKOFFICE_LIST_BODY_SCROLL_MODE as c } from "./backofficeListScrollMode.js";
9
9
  import { useBackofficeInfiniteScrollSentinel as l } from "../../../hooks/useBackofficeInfiniteScrollSentinel.js";
10
- import { isDevEnv as u } from "../../../relay/envHelpers.js";
11
- import { controlsRow as d, embeddedContainer as ee, embeddedHeader as te, entityIdListFilter as ne, entityIdListTags as re, filterInput as f, refreshingIndicator as ie, tableHost as ae } from "./backofficeEntityListScaffold.css.js";
12
- import { useCallback as oe, useEffect as se, useMemo as p, useState as m } from "react";
13
- import { InlineBanner as ce } from "@plumile/ui/components/feedback/InlineBanner.js";
14
- import { Fragment as h, jsx as g, jsxs as _ } from "react/jsx-runtime";
15
- import { useTranslation as le } from "react-i18next";
16
- import { Button as v } from "@plumile/ui/atomic/atoms/button/Button.js";
17
- import { SimpleSelect as y } from "@plumile/ui/components/select/SimpleSelect.js";
18
- import { Spinner as ue } from "@plumile/ui/backoffice/atoms/spinner/Spinner.js";
19
- import { BackofficeEmptyState as b } from "@plumile/ui/backoffice/molecules/backoffice_empty_state/BackofficeEmptyState.js";
20
- import { Tag as de } from "@plumile/ui/backoffice/atoms/tag/Tag.js";
10
+ import { controlsRow as u, embeddedContainer as d, embeddedHeader as ee, entityIdListFilter as te, entityIdListTags as ne, filterInput as f, refreshingIndicator as re, tableHost as ie } from "./backofficeEntityListScaffold.css.js";
11
+ import { useCallback as p, useEffect as ae, useMemo as m, useState as h } from "react";
12
+ import { InlineBanner as oe } from "@plumile/ui/components/feedback/InlineBanner.js";
13
+ import { Fragment as g, jsx as _, jsxs as v } from "react/jsx-runtime";
14
+ import { useTranslation as se } from "react-i18next";
15
+ import { Button as y } from "@plumile/ui/atomic/atoms/button/Button.js";
16
+ import { SimpleSelect as b } from "@plumile/ui/components/select/SimpleSelect.js";
17
+ import { Spinner as ce } from "@plumile/ui/backoffice/atoms/spinner/Spinner.js";
18
+ import { BackofficeEmptyState as le } from "@plumile/ui/backoffice/molecules/backoffice_empty_state/BackofficeEmptyState.js";
19
+ import { Tag as ue } from "@plumile/ui/backoffice/atoms/tag/Tag.js";
21
20
  import { readWhereValue as x, setWhereValue as S } from "@plumile/backoffice-core/filters/where.js";
22
- import { BackofficeFilterDrawer as fe } from "@plumile/ui/backoffice/molecules/backoffice_filter_drawer/BackofficeFilterDrawer.js";
23
- import { BackofficeFilterField as pe } from "@plumile/ui/backoffice/molecules/backoffice_filter_field/BackofficeFilterField.js";
24
- import { BackofficeListFooter as me } from "@plumile/ui/backoffice/molecules/backoffice_list_footer/BackofficeListFooter.js";
25
- import { BackofficePageHeader as he } from "@plumile/ui/backoffice/molecules/backoffice_page_header/BackofficePageHeader.js";
26
- import { BackofficeToolbar as ge } from "@plumile/ui/backoffice/molecules/backoffice_toolbar/BackofficeToolbar.js";
27
- import { BackofficeTableSkeleton as _e } from "@plumile/ui/backoffice/molecules/backoffice_table_skeleton/BackofficeTableSkeleton.js";
28
- import { FilterChipRow as ve } from "@plumile/ui/backoffice/molecules/filter_chip_row/FilterChipRow.js";
29
- import { ListPageTemplate as ye } from "@plumile/ui/backoffice/templates/list_page_template/ListPageTemplate.js";
30
- import { ResponsiveRecordList as be } from "@plumile/ui/components/data-table/ResponsiveRecordList.js";
31
- import { VirtualizedConnectionTable as xe } from "@plumile/ui/components/data-table/VirtualizedConnectionTable.js";
32
- import { denseTableClass as Se } from "@plumile/ui/shared/backofficeTableDensity.css.js";
33
- import { resolveBackofficeListRuntimeConfig as Ce } from "@plumile/backoffice-core/config/listRuntime.js";
21
+ import { BackofficeFilterDrawer as de } from "@plumile/ui/backoffice/molecules/backoffice_filter_drawer/BackofficeFilterDrawer.js";
22
+ import { BackofficeFilterField as fe } from "@plumile/ui/backoffice/molecules/backoffice_filter_field/BackofficeFilterField.js";
23
+ import { BackofficeListFooter as pe } from "@plumile/ui/backoffice/molecules/backoffice_list_footer/BackofficeListFooter.js";
24
+ import { BackofficePageHeader as me } from "@plumile/ui/backoffice/molecules/backoffice_page_header/BackofficePageHeader.js";
25
+ import { BackofficeToolbar as he } from "@plumile/ui/backoffice/molecules/backoffice_toolbar/BackofficeToolbar.js";
26
+ import { BackofficeTableSkeleton as ge } from "@plumile/ui/backoffice/molecules/backoffice_table_skeleton/BackofficeTableSkeleton.js";
27
+ import { FilterChipRow as _e } from "@plumile/ui/backoffice/molecules/filter_chip_row/FilterChipRow.js";
28
+ import { ListPageTemplate as ve } from "@plumile/ui/backoffice/templates/list_page_template/ListPageTemplate.js";
29
+ import { ResponsiveRecordList as ye } from "@plumile/ui/components/data-table/ResponsiveRecordList.js";
30
+ import { VirtualizedConnectionTable as be } from "@plumile/ui/components/data-table/VirtualizedConnectionTable.js";
31
+ import { denseTableClass as xe } from "@plumile/ui/shared/backofficeTableDensity.css.js";
32
+ import { resolveBackofficeListRuntimeConfig as Se } from "@plumile/backoffice-core/config/listRuntime.js";
33
+ import { isDevEnv as Ce } from "@plumile/relay/envHelpers.js";
34
34
  //#region src/components/backoffice/scaffolds/BackofficeEntityListScaffold.tsx
35
35
  var C = (e, t) => e(t), we = (e, t) => {
36
36
  if (e.fromGraphQL != null && t != null) return e.fromGraphQL(t);
@@ -44,7 +44,7 @@ var C = (e, t) => e(t), we = (e, t) => {
44
44
  if (t == null) return null;
45
45
  if (Array.isArray(t)) {
46
46
  let n = Te(t);
47
- return n.length === 0 ? null : e.kind === "entityIdList" ? /* @__PURE__ */ g(h, { children: n.map((t, r) => /* @__PURE__ */ _("span", { children: [/* @__PURE__ */ g(o, {
47
+ return n.length === 0 ? null : e.kind === "entityIdList" ? /* @__PURE__ */ _(g, { children: n.map((t, r) => /* @__PURE__ */ v("span", { children: [/* @__PURE__ */ _(o, {
48
48
  entityId: e.entity,
49
49
  id: t
50
50
  }), r < n.length - 1 ? ", " : null] }, t)) }) : n.join(", ");
@@ -52,7 +52,7 @@ var C = (e, t) => e(t), we = (e, t) => {
52
52
  if (typeof t == "boolean") return e.kind === "boolean" ? n.booleanLabel(t) : t ? n.fallbackBooleanLabels.yes : n.fallbackBooleanLabels.no;
53
53
  if (typeof t != "string" && typeof t != "number") return null;
54
54
  let r = String(t).trim();
55
- return r === "" ? null : e.kind === "entityId" ? /* @__PURE__ */ g(o, {
55
+ return r === "" ? null : e.kind === "entityId" ? /* @__PURE__ */ _(o, {
56
56
  entityId: e.entity,
57
57
  id: r
58
58
  }) : e.kind === "enum" ? n.enumLabel(r) : r;
@@ -67,7 +67,7 @@ var C = (e, t) => e(t), we = (e, t) => {
67
67
  let n = new Date(t);
68
68
  return Number.isNaN(n.getTime()) ? t : n.toISOString();
69
69
  }, w = (x) => {
70
- let { t: w } = le(), { t: T } = e(), { config: E, state: D, pushState: O, rows: k, getRowId: A, columns: j, gridTemplateColumns: ke, hasNextPage: M, isLoadingMore: N, isRefreshing: P = !1, onLoadMore: Ae, onRefresh: F, totalCount: I, loadedCountLabel: je, emptyState: Me, statusBanner: Ne, header: Pe, headerActions: Fe, isLoadingInitial: L = !1, variant: Ie = "page", showFilters: Le = !0 } = x, R = E.list, { listDefaults: Re } = E, z = p(() => j.some((e) => e.isPrimary === !0) || j.length === 0 ? j : j.map((e, t) => {
70
+ let { t: w } = se(), { t: T } = e(), { config: E, state: D, pushState: O, rows: k, getRowId: ke, columns: A, gridTemplateColumns: Ae, hasNextPage: j, isLoadingMore: M, incrementalError: N = null, isRefreshing: P = !1, onLoadMore: F, onRetryLoadMore: je, onRefresh: I, totalCount: L, loadedCountLabel: Me, emptyState: Ne, statusBanner: Pe, header: Fe, headerActions: Ie, isLoadingInitial: R = !1, variant: Le = "page", showFilters: Re = !0 } = x, z = E.list, { listDefaults: B } = E, V = m(() => A.some((e) => e.isPrimary === !0) || A.length === 0 ? A : A.map((e, t) => {
71
71
  let { header: n } = e;
72
72
  return t === 0 ? {
73
73
  ...e,
@@ -77,9 +77,9 @@ var C = (e, t) => e(t), we = (e, t) => {
77
77
  ...e,
78
78
  header: n
79
79
  };
80
- }), [j]), B = p(() => {
80
+ }), [A]), H = m(() => {
81
81
  let e = [];
82
- for (let t of R.filters) {
82
+ for (let t of z.filters) {
83
83
  let n = we(t, D.where), r = Ee(t, n, {
84
84
  enumLabel: (e) => {
85
85
  if (t.kind !== "enum") return e;
@@ -101,7 +101,7 @@ var C = (e, t) => e(t), we = (e, t) => {
101
101
  if (r != null) {
102
102
  let i = String(n);
103
103
  Array.isArray(n) && (i = n.join(","));
104
- let a = /* @__PURE__ */ _("span", { children: [
104
+ let a = /* @__PURE__ */ v("span", { children: [
105
105
  C(t.label, w),
106
106
  ": ",
107
107
  r
@@ -121,14 +121,14 @@ var C = (e, t) => e(t), we = (e, t) => {
121
121
  }
122
122
  return e;
123
123
  }, [
124
- R.filters,
124
+ z.filters,
125
125
  O,
126
126
  D,
127
127
  T,
128
128
  w
129
- ]), V = oe(() => {
130
- O({ ...Re });
131
- }, [Re, O]), [ze, Be] = m(!1), [Ve, He] = m(""), H = x.filterDrawerState ?? {
129
+ ]), U = p(() => {
130
+ O({ ...B });
131
+ }, [B, O]), [ze, Be] = h(!1), [Ve, He] = h(""), W = x.filterDrawerState ?? {
132
132
  isOpen: ze,
133
133
  search: Ve,
134
134
  setOpen: Be,
@@ -136,13 +136,13 @@ var C = (e, t) => e(t), we = (e, t) => {
136
136
  reset: () => {
137
137
  Be(!1), He("");
138
138
  }
139
- }, Ue = H.isOpen, U = H.search, W = H.setOpen, We = H.setSearch, Ge = H.reset, [G, K] = m(null), q = oe((e) => {
139
+ }, Ue = W.isOpen, G = W.search, K = W.setOpen, We = W.setSearch, Ge = W.reset, [q, J] = h(null), Y = p((e) => {
140
140
  let n = e.whereKey ?? e.id, r = we(e, D.where), i = "";
141
141
  typeof r == "string" && (i = r), typeof r == "number" && Number.isFinite(r) && (i = String(r));
142
142
  let c = C(e.label, w);
143
143
  if (e.kind === "text") {
144
144
  let t = e.placeholderLabel == null ? c : C(e.placeholderLabel, w), r = T("filters.placeholders.search", { label: t });
145
- return e.placeholderText != null && (r = C(e.placeholderText, w)), /* @__PURE__ */ g(a, {
145
+ return e.placeholderText != null && (r = C(e.placeholderText, w)), /* @__PURE__ */ _(a, {
146
146
  value: i,
147
147
  onApply: (t) => {
148
148
  let r = S(D.where, n, t, e.path);
@@ -158,7 +158,7 @@ var C = (e, t) => e(t), we = (e, t) => {
158
158
  }
159
159
  if (e.kind === "datetime") {
160
160
  let t = e.placeholderLabel == null ? c : C(e.placeholderLabel, w), r = T("filters.placeholders.search", { label: t });
161
- return e.placeholderText != null && (r = C(e.placeholderText, w)), /* @__PURE__ */ g(a, {
161
+ return e.placeholderText != null && (r = C(e.placeholderText, w)), /* @__PURE__ */ _(a, {
162
162
  value: De(i),
163
163
  onApply: (t) => {
164
164
  let r = Oe(t), i = S(D.where, n, r, e.path);
@@ -175,7 +175,7 @@ var C = (e, t) => e(t), we = (e, t) => {
175
175
  }
176
176
  if (e.kind === "number") {
177
177
  let t = e.placeholderLabel == null ? c : C(e.placeholderLabel, w), r = T("filters.placeholders.search", { label: t });
178
- return e.placeholderText != null && (r = C(e.placeholderText, w)), /* @__PURE__ */ g(a, {
178
+ return e.placeholderText != null && (r = C(e.placeholderText, w)), /* @__PURE__ */ _(a, {
179
179
  value: i,
180
180
  onApply: (t) => {
181
181
  let r = t.trim(), i = r === "" ? null : Number(r), a = S(D.where, n, Number.isFinite(i) ? i : null, e.path);
@@ -201,7 +201,7 @@ var C = (e, t) => e(t), we = (e, t) => {
201
201
  value: e.value,
202
202
  label: C(e.label, w)
203
203
  }))];
204
- return /* @__PURE__ */ g(y, {
204
+ return /* @__PURE__ */ _(b, {
205
205
  options: t,
206
206
  value: i,
207
207
  size: "small",
@@ -237,7 +237,7 @@ var C = (e, t) => e(t), we = (e, t) => {
237
237
  label: o
238
238
  }
239
239
  ];
240
- return /* @__PURE__ */ g(y, {
240
+ return /* @__PURE__ */ _(b, {
241
241
  options: s,
242
242
  value: i,
243
243
  size: "small",
@@ -264,15 +264,15 @@ var C = (e, t) => e(t), we = (e, t) => {
264
264
  where: a
265
265
  });
266
266
  };
267
- return /* @__PURE__ */ _("div", {
268
- className: ne,
269
- children: [/* @__PURE__ */ g(t, {
267
+ return /* @__PURE__ */ v("div", {
268
+ className: te,
269
+ children: [/* @__PURE__ */ _(t, {
270
270
  label: c,
271
271
  value: a === 0 ? null : i.join(","),
272
272
  displayValue: s,
273
273
  placeholder: T("filters.placeholders.anyEntity", { label: c }),
274
274
  onPick: () => {
275
- K({
275
+ J({
276
276
  entity: e.entity,
277
277
  whereKey: n,
278
278
  label: c,
@@ -289,14 +289,14 @@ var C = (e, t) => e(t), we = (e, t) => {
289
289
  where: t
290
290
  });
291
291
  }
292
- }), i.length > 0 ? /* @__PURE__ */ g("div", {
293
- className: re,
294
- children: i.map((t) => /* @__PURE__ */ g(de, {
292
+ }), i.length > 0 ? /* @__PURE__ */ _("div", {
293
+ className: ne,
294
+ children: i.map((t) => /* @__PURE__ */ _(ue, {
295
295
  removeLabel: T("filters.actions.removeFilterValue", { label: c }),
296
296
  onRemove: () => {
297
297
  u(t);
298
298
  },
299
- children: /* @__PURE__ */ g(o, {
299
+ children: /* @__PURE__ */ _(o, {
300
300
  entityId: e.entity,
301
301
  id: t
302
302
  })
@@ -306,7 +306,7 @@ var C = (e, t) => e(t), we = (e, t) => {
306
306
  }
307
307
  if (e.kind === "stringList") {
308
308
  let t = e.placeholderLabel == null ? c : C(e.placeholderLabel, w), r = T("filters.placeholders.search", { label: t });
309
- return e.placeholderText != null && (r = C(e.placeholderText, w)), /* @__PURE__ */ g(a, {
309
+ return e.placeholderText != null && (r = C(e.placeholderText, w)), /* @__PURE__ */ _(a, {
310
310
  value: i,
311
311
  onApply: (t) => {
312
312
  let r = t.split(/[\n,]+/u).map((e) => e.trim()).filter((e) => e !== ""), i = S(D.where, n, r, e.path);
@@ -324,14 +324,14 @@ var C = (e, t) => e(t), we = (e, t) => {
324
324
  typeof r == "string" && (u = r);
325
325
  let d = (r = null, i = !1) => {
326
326
  let a = r?.trim() ?? "";
327
- return /* @__PURE__ */ g(t, {
327
+ return /* @__PURE__ */ _(t, {
328
328
  label: c,
329
329
  value: u,
330
330
  displayValue: a,
331
331
  isResolving: i,
332
332
  placeholder: T("filters.placeholders.anyEntity", { label: c }),
333
333
  onPick: () => {
334
- K({
334
+ J({
335
335
  entity: e.entity,
336
336
  whereKey: n,
337
337
  label: c,
@@ -349,7 +349,7 @@ var C = (e, t) => e(t), we = (e, t) => {
349
349
  }
350
350
  });
351
351
  };
352
- return u == null || u.trim() === "" ? d() : /* @__PURE__ */ g(s, {
352
+ return u == null || u.trim() === "" ? d() : /* @__PURE__ */ _(s, {
353
353
  entityId: e.entity,
354
354
  id: u,
355
355
  children: (e, t) => {
@@ -362,34 +362,34 @@ var C = (e, t) => e(t), we = (e, t) => {
362
362
  D,
363
363
  T,
364
364
  w
365
- ]), Ke = p(() => R.filters.some((e) => e.placement != null), [R.filters]), J = p(() => {
366
- if (R.filters.length === 0) return [];
367
- let e = R.ui?.toolbar?.maxPromotedFilters ?? 3;
368
- return Ke ? R.filters.filter((e) => e.placement === "quick" || e.placement === "both") : R.filters.slice(0, e);
365
+ ]), Ke = m(() => z.filters.some((e) => e.placement != null), [z.filters]), X = m(() => {
366
+ if (z.filters.length === 0) return [];
367
+ let e = z.ui?.toolbar?.maxPromotedFilters ?? 3;
368
+ return Ke ? z.filters.filter((e) => e.placement === "quick" || e.placement === "both") : z.filters.slice(0, e);
369
369
  }, [
370
- R.filters,
371
- R.ui?.toolbar,
370
+ z.filters,
371
+ z.ui?.toolbar,
372
372
  Ke
373
- ]), Y = p(() => R.filters.filter((e) => e.placement == null || e.placement === "drawer" || e.placement === "both"), [R.filters]), X = p(() => J.find((e) => e.kind === "text"), [J]), qe = p(() => {
374
- let e = J.filter((e) => e !== X);
375
- return e.length === 0 ? null : /* @__PURE__ */ g("div", {
376
- className: d,
377
- children: e.map((e) => /* @__PURE__ */ g("span", { children: q(e) }, e.id))
373
+ ]), Z = m(() => z.filters.filter((e) => e.placement == null || e.placement === "drawer" || e.placement === "both"), [z.filters]), Q = m(() => X.find((e) => e.kind === "text"), [X]), qe = m(() => {
374
+ let e = X.filter((e) => e !== Q);
375
+ return e.length === 0 ? null : /* @__PURE__ */ _("div", {
376
+ className: u,
377
+ children: e.map((e) => /* @__PURE__ */ _("span", { children: Y(e) }, e.id))
378
378
  });
379
379
  }, [
380
- J,
381
- q,
382
- X
383
- ]), Je = p(() => X == null ? null : q(X), [q, X]), Ye = p(() => {
384
- if (R.sorts.length === 0) return null;
385
- let e = R.sorts[0];
380
+ X,
381
+ Y,
382
+ Q
383
+ ]), Je = m(() => Q == null ? null : Y(Q), [Y, Q]), Ye = m(() => {
384
+ if (z.sorts.length === 0) return null;
385
+ let e = z.sorts[0];
386
386
  if (e == null) return null;
387
- let t = R.sorts.map((e) => ({
387
+ let t = z.sorts.map((e) => ({
388
388
  id: e.id,
389
389
  value: e.id,
390
390
  label: C(e.label, w)
391
391
  }));
392
- return /* @__PURE__ */ g(y, {
392
+ return /* @__PURE__ */ _(b, {
393
393
  options: t,
394
394
  value: D.sort ?? e.id,
395
395
  size: "small",
@@ -402,24 +402,24 @@ var C = (e, t) => e(t), we = (e, t) => {
402
402
  }
403
403
  });
404
404
  }, [
405
- R.sorts,
405
+ z.sorts,
406
406
  O,
407
407
  D,
408
408
  T,
409
409
  w
410
- ]), Xe = p(() => B.length === 0 ? null : /* @__PURE__ */ g(ve, {
411
- chips: B,
412
- onClearAll: V
413
- }), [B, V]), Ze = p(() => {
414
- if (Y.length === 0) return [];
415
- let e = U.trim().toLowerCase(), t = [];
416
- for (let n of Y) {
410
+ ]), Xe = m(() => H.length === 0 ? null : /* @__PURE__ */ _(_e, {
411
+ chips: H,
412
+ onClearAll: U
413
+ }), [H, U]), Ze = m(() => {
414
+ if (Z.length === 0) return [];
415
+ let e = G.trim().toLowerCase(), t = [];
416
+ for (let n of Z) {
417
417
  let r = C(n.label, w);
418
418
  (e === "" || r.toLowerCase().includes(e)) && t.push({
419
419
  id: n.id,
420
- node: /* @__PURE__ */ g(pe, {
420
+ node: /* @__PURE__ */ _(fe, {
421
421
  label: r,
422
- children: q(n)
422
+ children: Y(n)
423
423
  })
424
424
  });
425
425
  }
@@ -429,254 +429,256 @@ var C = (e, t) => e(t), we = (e, t) => {
429
429
  items: t
430
430
  }];
431
431
  }, [
432
+ Z,
433
+ G,
432
434
  Y,
433
- U,
434
- q,
435
435
  T,
436
436
  w
437
- ]), Qe = p(() => {
438
- if (Y.length === 0) return null;
439
- let e = B.length, t = T("filters.trigger");
440
- return e > 0 && (t = T("filters.triggerWithCount", { count: e })), /* @__PURE__ */ g(v, {
437
+ ]), Qe = m(() => {
438
+ if (Z.length === 0) return null;
439
+ let e = H.length, t = T("filters.trigger");
440
+ return e > 0 && (t = T("filters.triggerWithCount", { count: e })), /* @__PURE__ */ _(y, {
441
441
  type: "button",
442
442
  variant: "secondary",
443
443
  size: "small",
444
444
  onClick: () => {
445
- W(!0);
445
+ K(!0);
446
446
  },
447
447
  children: t
448
448
  });
449
449
  }, [
450
- B.length,
451
- Y.length,
452
- W,
450
+ H.length,
451
+ Z.length,
452
+ K,
453
453
  T
454
- ]), $e = U.trim() === "" ? void 0 : T("filters.drawer.emptySearchResults"), et = /* @__PURE__ */ g(fe, {
454
+ ]), $e = G.trim() === "" ? void 0 : T("filters.drawer.emptySearchResults"), et = /* @__PURE__ */ _(de, {
455
455
  isOpen: Ue,
456
456
  onClose: () => {
457
457
  Ge();
458
458
  },
459
459
  sections: Ze,
460
- searchValue: U,
460
+ searchValue: G,
461
461
  onSearchChange: (e) => {
462
462
  We(e);
463
463
  },
464
- onReset: V,
464
+ onReset: U,
465
465
  emptyLabel: $e
466
- }), tt = p(() => Me ?? (L ? /* @__PURE__ */ g(_e, {
466
+ }), tt = m(() => Ne ?? (R ? /* @__PURE__ */ _(ge, {
467
467
  variant: "embedded",
468
468
  ariaLabel: T("common.loading")
469
- }) : B.length > 0 ? /* @__PURE__ */ g(b, {
469
+ }) : H.length > 0 ? /* @__PURE__ */ _(le, {
470
470
  title: T("emptyState.listEmpty.title"),
471
471
  description: T("emptyState.listEmptyFiltered.description"),
472
- actions: /* @__PURE__ */ g(v, {
472
+ actions: /* @__PURE__ */ _(y, {
473
473
  type: "button",
474
474
  variant: "secondary",
475
475
  size: "small",
476
- onClick: V,
476
+ onClick: U,
477
477
  children: T("emptyState.listEmptyFiltered.actions.reset")
478
478
  })
479
- }) : /* @__PURE__ */ g(b, {
479
+ }) : /* @__PURE__ */ _(le, {
480
480
  title: T("emptyState.listEmpty.title"),
481
481
  description: T("emptyState.listEmpty.description")
482
482
  })), [
483
- B.length,
484
- Me,
485
- V,
486
- L,
483
+ H.length,
484
+ Ne,
485
+ U,
486
+ R,
487
487
  T
488
- ]), nt = p(() => je ?? (typeof I == "number" ? /* @__PURE__ */ g("span", { children: T("list.showing", {
488
+ ]), nt = m(() => Me ?? (typeof L == "number" ? /* @__PURE__ */ _("span", { children: T("list.showing", {
489
489
  shown: k.length,
490
- total: I
491
- }) }) : k.length === 0 ? null : /* @__PURE__ */ g("span", { children: T("list.loaded", { count: k.length }) })), [
492
- je,
490
+ total: L
491
+ }) }) : k.length === 0 ? null : /* @__PURE__ */ _("span", { children: T("list.loaded", { count: k.length }) })), [
492
+ Me,
493
493
  k.length,
494
494
  T,
495
- I
496
- ]), Z = p(() => {
497
- let e = R.ui?.displayMode ?? R.responsive?.mode ?? "auto";
498
- return Ce({
499
- kind: R.kind,
495
+ L
496
+ ]), $ = m(() => {
497
+ let e = z.ui?.displayMode ?? z.responsive?.mode ?? "auto";
498
+ return Se({
499
+ kind: z.kind,
500
500
  displayMode: e,
501
- ui: R.ui
501
+ ui: z.ui
502
502
  });
503
503
  }, [
504
- R.kind,
505
- R.responsive?.mode,
506
- R.ui
507
- ]), Q = typeof I == "number" && k.length < I && !M;
508
- se(() => {
509
- !Q || !Z.infiniteScroll.showInconsistentPageInfo || !u() || console.warn("Backoffice list received inconsistent pageInfo: loaded rows are lower than totalCount but hasNextPage is false.", {
504
+ z.kind,
505
+ z.responsive?.mode,
506
+ z.ui
507
+ ]), rt = typeof L == "number" && k.length < L && !j;
508
+ ae(() => {
509
+ !rt || !$.infiniteScroll.showInconsistentPageInfo || !Ce() || console.warn("Backoffice list received inconsistent pageInfo: loaded rows are lower than totalCount but hasNextPage is false.", {
510
510
  entityId: E.id,
511
511
  loadedCount: k.length,
512
- totalCount: I
512
+ totalCount: L
513
513
  });
514
514
  }, [
515
515
  E.id,
516
- Q,
516
+ rt,
517
517
  k.length,
518
- Z.infiniteScroll.showInconsistentPageInfo,
519
- I
518
+ $.infiniteScroll.showInconsistentPageInfo,
519
+ L
520
520
  ]);
521
- let rt = x.virtualize === !0 || Z.virtualization.enabled, { sentinelRef: it } = l({
522
- enabled: !rt && Z.infiniteScroll.enabled,
523
- hasNextPage: M,
524
- isLoading: N,
525
- onIntersect: Ae,
526
- rootMargin: Z.infiniteScroll.rootMargin,
527
- threshold: Z.infiniteScroll.threshold
528
- }), at = Pe?.title ?? C(R.title, w), ot = Pe?.subtitle, st = z.find((e) => e.mobileRole === "action" || e.id === "actions"), ct = R.ui?.displayMode ?? R.responsive?.mode ?? "auto", lt = R.ui?.density ?? R.responsive?.density ?? "compact", ut = rt ? /* @__PURE__ */ g(xe, {
529
- columns: z,
521
+ let it = x.virtualize === !0 || $.virtualization.enabled, { sentinelRef: at } = l({
522
+ enabled: !it && $.infiniteScroll.enabled && N == null,
523
+ hasNextPage: j,
524
+ isLoading: M,
525
+ onIntersect: F,
526
+ rootMargin: $.infiniteScroll.rootMargin,
527
+ threshold: $.infiniteScroll.threshold
528
+ }), ot = Fe?.title ?? C(z.title, w), st = Fe?.subtitle, ct = V.find((e) => e.mobileRole === "action" || e.id === "actions"), lt = z.ui?.displayMode ?? z.responsive?.mode ?? "auto", ut = z.ui?.density ?? z.responsive?.density ?? "compact", dt = it ? /* @__PURE__ */ _(be, {
529
+ columns: V,
530
530
  rows: k,
531
- getRowId: A,
531
+ getRowId: ke,
532
532
  emptyState: tt,
533
- className: Se,
534
- gridTemplateColumns: ke,
535
- virtualization: Z.virtualization,
533
+ className: xe,
534
+ gridTemplateColumns: Ae,
535
+ virtualization: $.virtualization,
536
536
  infiniteScroll: {
537
- enabled: Z.infiniteScroll.enabled,
538
- thresholdPx: Z.infiniteScroll.thresholdPx,
539
- autoLoad: Z.infiniteScroll.autoLoad
537
+ enabled: $.infiniteScroll.enabled,
538
+ thresholdPx: $.infiniteScroll.thresholdPx,
539
+ autoLoad: $.infiniteScroll.autoLoad
540
540
  },
541
- hasNextPage: M,
542
- isLoadingMore: N,
543
- onLoadMore: Ae,
541
+ hasNextPage: j,
542
+ isLoadingMore: M,
543
+ onLoadMore: N == null ? F : () => {},
544
544
  bodyScrollMode: c
545
- }) : /* @__PURE__ */ g(be, {
546
- columns: z,
545
+ }) : /* @__PURE__ */ _(ye, {
546
+ columns: V,
547
547
  rows: k,
548
- getRowId: A,
548
+ getRowId: ke,
549
549
  emptyState: tt,
550
- className: Se,
551
- gridTemplateColumns: ke,
552
- mode: ct,
553
- density: lt,
550
+ className: xe,
551
+ gridTemplateColumns: Ae,
552
+ mode: lt,
553
+ density: ut,
554
554
  bodyScrollMode: c,
555
- bodyFooterNode: Z.infiniteScroll.enabled ? /* @__PURE__ */ g("div", {
556
- ref: it,
555
+ bodyFooterNode: $.infiniteScroll.enabled ? /* @__PURE__ */ _("div", {
556
+ ref: at,
557
557
  "aria-hidden": "true"
558
558
  }) : null,
559
- renderAction: (e) => st?.cell(e) ?? null
560
- }), dt = /* @__PURE__ */ g(n, {
559
+ renderAction: (e) => ct?.cell(e) ?? null
560
+ }), ft = /* @__PURE__ */ _(n, {
561
561
  fallback: (e) => {
562
562
  let { reset: t } = e;
563
- return /* @__PURE__ */ g(ce, {
563
+ return /* @__PURE__ */ _(oe, {
564
564
  tone: "danger",
565
565
  title: T("list.errors.title"),
566
- actions: /* @__PURE__ */ g(v, {
566
+ actions: /* @__PURE__ */ _(y, {
567
567
  type: "button",
568
568
  variant: "secondary",
569
569
  size: "small",
570
570
  onClick: () => {
571
- t(), F?.();
571
+ t(), I?.();
572
572
  },
573
573
  children: T("list.actions.retry")
574
574
  }),
575
575
  children: T("list.errors.tableFailed")
576
576
  });
577
577
  },
578
- children: ut
579
- }), ft = Le ? /* @__PURE__ */ _(h, { children: [/* @__PURE__ */ g(ge, {
578
+ children: dt
579
+ }), pt = Re ? /* @__PURE__ */ v(g, { children: [/* @__PURE__ */ _(he, {
580
580
  search: Je,
581
581
  primaryFilters: qe,
582
582
  filterDrawerTrigger: Qe,
583
583
  sort: Ye,
584
- utilityActions: F == null ? null : /* @__PURE__ */ g(v, {
584
+ utilityActions: I == null ? null : /* @__PURE__ */ _(y, {
585
585
  type: "button",
586
586
  variant: "secondary",
587
587
  size: "small",
588
588
  isLoading: P,
589
589
  loadingLabel: T("list.actions.refreshing"),
590
590
  onClick: () => {
591
- F();
591
+ I();
592
592
  },
593
593
  children: T("list.actions.refresh")
594
594
  }),
595
595
  chips: Xe,
596
596
  density: "compact"
597
- }), et] }) : null, pt = /* @__PURE__ */ _("div", {
598
- className: ae,
597
+ }), et] }) : null, mt = /* @__PURE__ */ v("div", {
598
+ className: ie,
599
599
  "aria-busy": P ? "true" : void 0,
600
600
  children: [
601
- P && !L ? /* @__PURE__ */ _("div", {
602
- className: ie,
601
+ P && !R ? /* @__PURE__ */ v("div", {
602
+ className: re,
603
603
  role: "status",
604
- children: [/* @__PURE__ */ g(ue, {
604
+ children: [/* @__PURE__ */ _(ce, {
605
605
  size: 14,
606
606
  ariaLabel: T("list.refreshingRows")
607
- }), /* @__PURE__ */ g("span", { children: T("list.refreshingRows") })]
607
+ }), /* @__PURE__ */ _("span", { children: T("list.refreshingRows") })]
608
608
  }) : null,
609
- dt,
610
- /* @__PURE__ */ g(r, {
611
- isOpen: G != null,
612
- entity: G?.entity ?? E.id,
613
- title: G?.label ?? T("picker.title"),
614
- scope: G?.scope,
609
+ ft,
610
+ /* @__PURE__ */ _(r, {
611
+ isOpen: q != null,
612
+ entity: q?.entity ?? E.id,
613
+ title: q?.label ?? T("picker.title"),
614
+ scope: q?.scope,
615
615
  onClose: () => {
616
- K(null);
616
+ J(null);
617
617
  },
618
618
  onSelectId: (e) => {
619
- if (G == null) return;
620
- if (G.mode === "list") {
621
- let t = G.currentIds ?? [], n = t.includes(e) ? t : [...t, e], r = S(D.where, G.whereKey, n, G.path);
622
- W(!0), O({
619
+ if (q == null) return;
620
+ if (q.mode === "list") {
621
+ let t = q.currentIds ?? [], n = t.includes(e) ? t : [...t, e], r = S(D.where, q.whereKey, n, q.path);
622
+ K(!0), O({
623
623
  ...D,
624
624
  where: r
625
625
  });
626
626
  return;
627
627
  }
628
- let t = S(D.where, G.whereKey, e, G.path);
629
- W(!0), O({
628
+ let t = S(D.where, q.whereKey, e, q.path);
629
+ K(!0), O({
630
630
  ...D,
631
631
  where: t
632
632
  });
633
633
  }
634
634
  })
635
635
  ]
636
- }), $ = k.length > 0 || N || M ? /* @__PURE__ */ g(h, { children: /* @__PURE__ */ g(me, {
637
- mode: "status",
636
+ }), ht = k.length > 0 || M || j ? /* @__PURE__ */ _(g, { children: /* @__PURE__ */ _(pe, {
637
+ state: N != null && je != null ? {
638
+ kind: "error",
639
+ message: N.message,
640
+ onRetry: je
641
+ } : M ? { kind: "loading" } : j ? { kind: "idle" } : { kind: "end" },
638
642
  loadedCount: k.length,
639
- totalCount: I,
640
- hasNextPage: M,
641
- isLoading: N,
642
- pageInfoState: Q ? "inconsistent" : N ? "loading" : M ? "ready" : "complete",
643
+ totalCount: L,
643
644
  labels: {
644
645
  loaded: nt,
645
646
  loading: T("list.loadMore.loading"),
646
- end: T("list.loadMore.end")
647
+ end: T("list.loadMore.end"),
648
+ retry: T("list.actions.retry")
647
649
  }
648
650
  }) }) : null;
649
- return Ie === "embedded" ? /* @__PURE__ */ g(i, {
651
+ return Le === "embedded" ? /* @__PURE__ */ _(i, {
650
652
  config: E,
651
653
  state: D,
652
654
  pushState: O,
653
- children: /* @__PURE__ */ _("div", {
654
- className: ee,
655
+ children: /* @__PURE__ */ v("div", {
656
+ className: d,
655
657
  children: [
656
- /* @__PURE__ */ g("div", {
657
- className: te,
658
- children: at
658
+ /* @__PURE__ */ _("div", {
659
+ className: ee,
660
+ children: ot
659
661
  }),
660
- ft,
661
- Ne,
662
662
  pt,
663
- $
663
+ Pe,
664
+ mt,
665
+ ht
664
666
  ]
665
667
  })
666
- }) : /* @__PURE__ */ g(i, {
668
+ }) : /* @__PURE__ */ _(i, {
667
669
  config: E,
668
670
  state: D,
669
671
  pushState: O,
670
- children: /* @__PURE__ */ g(ye, {
671
- headerNode: /* @__PURE__ */ g(he, {
672
- title: at,
673
- subtitle: ot,
674
- actions: Fe
672
+ children: /* @__PURE__ */ _(ve, {
673
+ headerNode: /* @__PURE__ */ _(me, {
674
+ title: ot,
675
+ subtitle: st,
676
+ actions: Ie
675
677
  }),
676
- toolbarNode: ft,
677
- statusNode: Ne,
678
- tableNode: pt,
679
- tableFooterNode: $,
678
+ toolbarNode: pt,
679
+ statusNode: Pe,
680
+ tableNode: mt,
681
+ tableFooterNode: ht,
680
682
  presentation: "flat",
681
683
  bodyScrollMode: c
682
684
  })