@ai-matrx/design-system 0.53.3 → 0.54.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -34807,6 +34807,7 @@ function ConfirmDialog({
34807
34807
  variant = "default",
34808
34808
  busy = false,
34809
34809
  confirmDisabled = false,
34810
+ confirmHeld = false,
34810
34811
  portalContainer,
34811
34812
  onConfirm
34812
34813
  }) {
@@ -34823,7 +34824,7 @@ function ConfirmDialog({
34823
34824
  content ?? null,
34824
34825
  /* @__PURE__ */ jsxs6(AlertDialogFooter, { children: [
34825
34826
  cancelLabel === null ? null : /* @__PURE__ */ jsx10(AlertDialogCancel, { className: "max-lg:min-h-11", disabled: busy, children: cancelLabel }),
34826
- /* @__PURE__ */ jsxs6(
34827
+ confirmHeld ? null : /* @__PURE__ */ jsxs6(
34827
34828
  AlertDialogAction,
34828
34829
  {
34829
34830
  disabled: busy || confirmDisabled,
@@ -56529,32 +56530,14 @@ function MatrxDataTableCore(coreProps) {
56529
56530
  ]
56530
56531
  }
56531
56532
  ) : null,
56532
- appendQuery.pagination.loadAll?.isLoading ? /* @__PURE__ */ jsx58(
56533
- Button,
56534
- {
56535
- type: "button",
56536
- variant: "outline",
56537
- className: "h-8 shrink-0 px-3 text-sm",
56538
- onClick: appendQuery.pagination.loadAll.stop,
56539
- children: "Stop loading"
56540
- }
56541
- ) : scrollPagination.error ? /* @__PURE__ */ jsx58(
56542
- Button,
56543
- {
56544
- type: "button",
56545
- variant: "outline",
56546
- className: "h-8 shrink-0 px-3 text-sm",
56547
- onClick: appendQuery.pagination.retrySource ?? (appendQuery.pagination.hasNextPage ? appendQuery.pagination.loadNextPage : appendQuery.pagination.refresh),
56548
- children: appendQuery.pagination.retrySource ? "Retry source" : appendQuery.pagination.hasNextPage ? "Retry" : "Reload rows"
56549
- }
56550
- ) : appendQuery.pagination.hasNextPage || scrollPagination.error ? /* @__PURE__ */ jsxs47("div", { className: "flex min-w-0 max-w-full flex-wrap gap-0", children: [
56533
+ /* @__PURE__ */ jsxs47("div", { className: "flex min-w-0 max-w-full flex-wrap gap-0", children: [
56551
56534
  /* @__PURE__ */ jsx58(
56552
56535
  Button,
56553
56536
  {
56554
56537
  type: "button",
56555
56538
  variant: "outline",
56556
56539
  className: "h-8 px-3 text-sm",
56557
- disabled: isLoading || isFetching,
56540
+ disabled: isLoading || isFetching || Boolean(appendQuery.pagination.loadAll?.isLoading) || Boolean(scrollPagination.error) || !appendQuery.pagination.hasNextPage,
56558
56541
  onClick: () => void scrollPagination.requestNextPage(),
56559
56542
  children: "Load more"
56560
56543
  }
@@ -56565,12 +56548,31 @@ function MatrxDataTableCore(coreProps) {
56565
56548
  type: "button",
56566
56549
  variant: "ghost",
56567
56550
  className: "h-8 px-3 text-sm",
56568
- disabled: isLoading || isFetching,
56551
+ disabled: isLoading || isFetching || Boolean(appendQuery.pagination.loadAll?.isLoading) || Boolean(scrollPagination.error) || !appendQuery.pagination.hasNextPage,
56569
56552
  onClick: appendQuery.pagination.loadAll.request,
56570
56553
  children: "Load all"
56571
56554
  }
56572
56555
  ) : null
56573
- ] }) : !isLoading && appendQuery.pagination.totalItems !== void 0 && data.length === appendQuery.pagination.totalItems ? /* @__PURE__ */ jsx58("span", { className: "min-w-0 max-w-full break-words whitespace-normal px-3 text-xs text-muted-foreground sm:text-sm", children: "All rows loaded" }) : null
56556
+ ] }),
56557
+ appendQuery.pagination.loadAll?.isLoading ? /* @__PURE__ */ jsx58(
56558
+ Button,
56559
+ {
56560
+ type: "button",
56561
+ variant: "outline",
56562
+ className: "h-8 shrink-0 px-3 text-sm",
56563
+ onClick: appendQuery.pagination.loadAll.stop,
56564
+ children: "Stop loading"
56565
+ }
56566
+ ) : scrollPagination.error ? /* @__PURE__ */ jsx58(
56567
+ Button,
56568
+ {
56569
+ type: "button",
56570
+ variant: "outline",
56571
+ className: "h-8 shrink-0 px-3 text-sm",
56572
+ onClick: appendQuery.pagination.retrySource ?? (appendQuery.pagination.hasNextPage ? appendQuery.pagination.loadNextPage : appendQuery.pagination.refresh),
56573
+ children: appendQuery.pagination.retrySource ? "Retry source" : appendQuery.pagination.hasNextPage ? "Retry" : "Reload rows"
56574
+ }
56575
+ ) : !isLoading && appendQuery.pagination.totalItems !== void 0 && data.length === appendQuery.pagination.totalItems ? /* @__PURE__ */ jsx58("span", { className: "min-w-0 max-w-full break-words whitespace-normal px-3 text-xs text-muted-foreground sm:text-sm", children: "All rows loaded" }) : null
56574
56576
  ]
56575
56577
  }
56576
56578
  ) : embedded && !hidePagination && !drillGrouped && (localProgressiveEnabled || pageCount <= 1 || remoteQuery?.mode === "controlled") ? (