blixify-ui-web 1.2.169 → 1.2.172

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.
@@ -456,33 +456,44 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
456
456
  create: false,
457
457
  }), authMethods = _144[0], setAuthMethods = _144[1];
458
458
  var _145 = (0, react_1.useState)(""), selectedAuthMethod = _145[0], setSelectedAuthMethod = _145[1];
459
+ // INFO: the sign-in check of a users datasheet's record is running; the
460
+ // panel shows a spinner rather than nothing, which read as "no login"
461
+ var _146 = (0, react_1.useState)(false), authLoading = _146[0], setAuthLoading = _146[1];
462
+ // INFO: a delete is running — the ref answers a second tap at once, before
463
+ // the state has rendered, and the state disables the confirm button
464
+ var deletingRef = (0, react_1.useRef)(false);
465
+ var _147 = (0, react_1.useState)(false), deleting = _147[0], setDeleting = _147[1];
459
466
  // INFO: Used by Activity Log
460
- var _146 = (0, react_1.useState)(false), activityModal = _146[0], setActivityModal = _146[1];
461
- var _147 = (0, react_1.useState)(""), activityId = _147[0], setActivityId = _147[1];
467
+ var _148 = (0, react_1.useState)(false), activityModal = _148[0], setActivityModal = _148[1];
468
+ var _149 = (0, react_1.useState)(""), activityId = _149[0], setActivityId = _149[1];
462
469
  //INFO : Used by Export
463
- var _148 = (0, react_1.useState)(null), csvFile = _148[0], setCSVFile = _148[1];
464
- var _149 = (0, react_1.useState)([]), csvFileData = _149[0], setCSVFileData = _149[1];
465
- var _150 = (0, react_1.useState)(0), stepCSVIndex = _150[0], setStepCSVIndex = _150[1];
466
- var _151 = (0, react_1.useState)({}), listCSVMapAttribute = _151[0], setListCSVMapAttribute = _151[1];
467
- var _152 = (0, react_1.useState)({}), listCSVObjAttribute = _152[0], setListCSVObjAttribute = _152[1];
468
- var _153 = (0, react_1.useState)([]), csvAPIAttribute = _153[0], setCSVAPIAttribute = _153[1];
469
- var _154 = (0, react_1.useState)(((_p = props.devSettings.currentUser) === null || _p === void 0 ? void 0 : _p.userEmail) || ""), exportCSVEmail = _154[0], setExportCSVEmail = _154[1];
470
- var _155 = (0, react_1.useState)(((_r = (_q = props.organise) === null || _q === void 0 ? void 0 : _q.exportSettings) === null || _r === void 0 ? void 0 : _r.defaultExportPDFName) || ""), exportPDFTitle = _155[0], setExportPDFTitle = _155[1];
471
- var _156 = (0, react_1.useState)(false), exportPDFLoading = _156[0], setExportPDFLoading = _156[1];
472
- var _157 = (0, react_1.useState)(false), exportReadPDFLoading = _157[0], setExportReadPDFLoading = _157[1];
473
- var _158 = (0, react_1.useState)((_u = (_t = (_s = props.organise) === null || _s === void 0 ? void 0 : _s.exportSettings) === null || _t === void 0 ? void 0 : _t.sumColumnId) !== null && _u !== void 0 ? _u : []), exportSumAttributeIds = _158[0], setExportSumAttributeIds = _158[1];
474
- var _159 = (0, react_1.useState)((_x = (_w = (_v = props.organise) === null || _v === void 0 ? void 0 : _v.exportSettings) === null || _w === void 0 ? void 0 : _w.hideSubItems) !== null && _x !== void 0 ? _x : false), hideSubItems = _159[0], setHideSubItems = _159[1];
475
- var _160 = (0, react_1.useState)([]), importTableData = _160[0], setImportTableData = _160[1];
476
- var _161 = (0, react_1.useState)([]), queryList = _161[0], setQueryList = _161[1];
477
- var _162 = (0, react_1.useState)(undefined), allQueryList = _162[0], setAllQueryList = _162[1];
478
- var _163 = (0, react_1.useState)(-1), queryIndex = _163[0], setQueryIndex = _163[1];
479
- var _164 = (0, react_1.useState)((_y = props.organise) === null || _y === void 0 ? void 0 : _y.groupBy), groupId = _164[0], setGroupId = _164[1];
470
+ var _150 = (0, react_1.useState)(null), csvFile = _150[0], setCSVFile = _150[1];
471
+ var _151 = (0, react_1.useState)([]), csvFileData = _151[0], setCSVFileData = _151[1];
472
+ var _152 = (0, react_1.useState)(0), stepCSVIndex = _152[0], setStepCSVIndex = _152[1];
473
+ var _153 = (0, react_1.useState)({}), listCSVMapAttribute = _153[0], setListCSVMapAttribute = _153[1];
474
+ var _154 = (0, react_1.useState)({}), listCSVObjAttribute = _154[0], setListCSVObjAttribute = _154[1];
475
+ var _155 = (0, react_1.useState)([]), csvAPIAttribute = _155[0], setCSVAPIAttribute = _155[1];
476
+ var _156 = (0, react_1.useState)(((_p = props.devSettings.currentUser) === null || _p === void 0 ? void 0 : _p.userEmail) || ""), exportCSVEmail = _156[0], setExportCSVEmail = _156[1];
477
+ var _157 = (0, react_1.useState)(((_r = (_q = props.organise) === null || _q === void 0 ? void 0 : _q.exportSettings) === null || _r === void 0 ? void 0 : _r.defaultExportPDFName) || ""), exportPDFTitle = _157[0], setExportPDFTitle = _157[1];
478
+ var _158 = (0, react_1.useState)(false), exportPDFLoading = _158[0], setExportPDFLoading = _158[1];
479
+ var _159 = (0, react_1.useState)(false), exportReadPDFLoading = _159[0], setExportReadPDFLoading = _159[1];
480
+ var _160 = (0, react_1.useState)((_u = (_t = (_s = props.organise) === null || _s === void 0 ? void 0 : _s.exportSettings) === null || _t === void 0 ? void 0 : _t.sumColumnId) !== null && _u !== void 0 ? _u : []), exportSumAttributeIds = _160[0], setExportSumAttributeIds = _160[1];
481
+ var _161 = (0, react_1.useState)((_x = (_w = (_v = props.organise) === null || _v === void 0 ? void 0 : _v.exportSettings) === null || _w === void 0 ? void 0 : _w.hideSubItems) !== null && _x !== void 0 ? _x : false), hideSubItems = _161[0], setHideSubItems = _161[1];
482
+ var _162 = (0, react_1.useState)([]), importTableData = _162[0], setImportTableData = _162[1];
483
+ var _163 = (0, react_1.useState)([]), queryList = _163[0], setQueryList = _163[1];
484
+ var _164 = (0, react_1.useState)(undefined), allQueryList = _164[0], setAllQueryList = _164[1];
485
+ var _165 = (0, react_1.useState)(-1), queryIndex = _165[0], setQueryIndex = _165[1];
486
+ // INFO: a restored state wins over the prop; its "" is a list the user
487
+ // ungrouped, so it opens ungrouped
488
+ var _166 = (0, react_1.useState)((persistedState === null || persistedState === void 0 ? void 0 : persistedState.groupBy) !== undefined
489
+ ? persistedState.groupBy || undefined
490
+ : (_y = props.organise) === null || _y === void 0 ? void 0 : _y.groupBy), groupId = _166[0], setGroupId = _166[1];
480
491
  // INFO: Monday-board per-group paging. Keyed by the group key that
481
492
  // handleBuildNewTableGroups() produces (a list option or "Unknown/No Value").
482
493
  // Each group tracks its own loaded cursor + total so it can lazily load its
483
494
  // next page as the user scrolls inside that band, independent of every other
484
495
  // group. Only used when renderCheckGroupPaging() is true.
485
- var _165 = (0, react_1.useState)({}), groupPageState = _165[0], setGroupPageState = _165[1];
496
+ var _167 = (0, react_1.useState)({}), groupPageState = _167[0], setGroupPageState = _167[1];
486
497
  // INFO: read fresh inside the async per-group fetch so chained scroll fires
487
498
  // in one tick do not re-fetch an already in-flight page.
488
499
  var groupPageStateRef = (0, react_1.useRef)({});
@@ -491,59 +502,59 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
491
502
  // list was re-read (new search, filter, sort or grouping) is dropped on
492
503
  // arrival instead of appending rows that belong to the old list
493
504
  var groupPagingGenRef = (0, react_1.useRef)(0);
494
- var _166 = (0, react_1.useState)(""), readTabSection = _166[0], setReadTabSection = _166[1];
495
- var _167 = (0, react_1.useState)(false), readFloatingNav = _167[0], setReadFloatingNav = _167[1];
505
+ var _168 = (0, react_1.useState)(""), readTabSection = _168[0], setReadTabSection = _168[1];
506
+ var _169 = (0, react_1.useState)(false), readFloatingNav = _169[0], setReadFloatingNav = _169[1];
496
507
  var readTabSectionRefs = (0, react_1.useRef)({});
497
508
  //INFO : Used by Read
498
509
  //INFO : Used by Update
499
- var _168 = (0, react_1.useState)(false), modalVisible = _168[0], setModalVisible = _168[1];
500
- var _169 = (0, react_1.useState)(false), deleteModal = _169[0], setDeleteModal = _169[1];
501
- var _170 = (0, react_1.useState)(false), excelModal = _170[0], setExcelModal = _170[1];
502
- var _171 = (0, react_1.useState)(false), exportExcel = _171[0], setExportExcel = _171[1];
503
- var _172 = (0, react_1.useState)(""), exportType = _172[0], setExportType = _172[1];
504
- var _173 = (0, react_1.useState)(false), exportQR = _173[0], setExportQR = _173[1];
505
- var _174 = (0, react_1.useState)(function () {
510
+ var _170 = (0, react_1.useState)(false), modalVisible = _170[0], setModalVisible = _170[1];
511
+ var _171 = (0, react_1.useState)(false), deleteModal = _171[0], setDeleteModal = _171[1];
512
+ var _172 = (0, react_1.useState)(false), excelModal = _172[0], setExcelModal = _172[1];
513
+ var _173 = (0, react_1.useState)(false), exportExcel = _173[0], setExportExcel = _173[1];
514
+ var _174 = (0, react_1.useState)(""), exportType = _174[0], setExportType = _174[1];
515
+ var _175 = (0, react_1.useState)(false), exportQR = _175[0], setExportQR = _175[1];
516
+ var _176 = (0, react_1.useState)(function () {
506
517
  var _a, _b;
507
518
  var firstTabId = (_b = (_a = structure.find(function (item) { return item.tabId; })) === null || _a === void 0 ? void 0 : _a.tabId) !== null && _b !== void 0 ? _b : "";
508
519
  return firstTabId;
509
- }), activeTab = _174[0], setActiveTab = _174[1];
510
- var _175 = (0, react_1.useState)(false), signatureSigning = _175[0], setSignatureSigning = _175[1];
511
- var _176 = (0, react_1.useState)({}), selectedData = _176[0], setSelectedData = _176[1];
512
- var _177 = (0, react_1.useState)(""), selectedObjectStructureId = _177[0], setSelectedObjectStructureId = _177[1];
513
- var _178 = (0, react_1.useState)(""), selectedObjectId = _178[0], setSelectedObjectId = _178[1];
514
- var _179 = (0, react_1.useState)(""), selectedListAddressId = _179[0], setSelectedListAddressId = _179[1];
515
- var _180 = (0, react_1.useState)(-1), selectedListAddressIndex = _180[0], setSelectedListAddressIndex = _180[1];
516
- var _181 = (0, react_1.useState)({
520
+ }), activeTab = _176[0], setActiveTab = _176[1];
521
+ var _177 = (0, react_1.useState)(false), signatureSigning = _177[0], setSignatureSigning = _177[1];
522
+ var _178 = (0, react_1.useState)({}), selectedData = _178[0], setSelectedData = _178[1];
523
+ var _179 = (0, react_1.useState)(""), selectedObjectStructureId = _179[0], setSelectedObjectStructureId = _179[1];
524
+ var _180 = (0, react_1.useState)(""), selectedObjectId = _180[0], setSelectedObjectId = _180[1];
525
+ var _181 = (0, react_1.useState)(""), selectedListAddressId = _181[0], setSelectedListAddressId = _181[1];
526
+ var _182 = (0, react_1.useState)(-1), selectedListAddressIndex = _182[0], setSelectedListAddressIndex = _182[1];
527
+ var _183 = (0, react_1.useState)({
517
528
  lat: 0,
518
529
  lng: 0,
519
530
  name: "",
520
- }), selectedListAddress = _181[0], setSelectedListAddress = _181[1];
521
- var _182 = (0, react_1.useState)({}), selectedObjectData = _182[0], setSelectedObjectData = _182[1];
522
- var _183 = (0, react_1.useState)(null), objectCellEdit = _183[0], setObjectCellEdit = _183[1];
523
- var _184 = (0, react_1.useState)(false), referenceLoading = _184[0], setReferenceLoading = _184[1];
524
- var _185 = (0, react_1.useState)({}), referencesOptions = _185[0], setReferencesOptions = _185[1];
525
- var _186 = (0, react_1.useState)({}), referencesDetails = _186[0], setReferencesDetails = _186[1];
526
- var _187 = (0, react_1.useState)({}), listReferencesOptions = _187[0], setListReferencesOptions = _187[1];
527
- var _188 = (0, react_1.useState)({}), referenceDeleteTableData = _188[0], setReferenceDeleteTableData = _188[1];
528
- var _189 = (0, react_1.useState)([]), relatedSections = _189[0], setRelatedSections = _189[1];
529
- var _190 = (0, react_1.useState)(0), referenceDeleteIndex = _190[0], setReferenceDeleteIndex = _190[1];
530
- var _191 = (0, react_1.useState)({
531
+ }), selectedListAddress = _183[0], setSelectedListAddress = _183[1];
532
+ var _184 = (0, react_1.useState)({}), selectedObjectData = _184[0], setSelectedObjectData = _184[1];
533
+ var _185 = (0, react_1.useState)(null), objectCellEdit = _185[0], setObjectCellEdit = _185[1];
534
+ var _186 = (0, react_1.useState)(false), referenceLoading = _186[0], setReferenceLoading = _186[1];
535
+ var _187 = (0, react_1.useState)({}), referencesOptions = _187[0], setReferencesOptions = _187[1];
536
+ var _188 = (0, react_1.useState)({}), referencesDetails = _188[0], setReferencesDetails = _188[1];
537
+ var _189 = (0, react_1.useState)({}), listReferencesOptions = _189[0], setListReferencesOptions = _189[1];
538
+ var _190 = (0, react_1.useState)({}), referenceDeleteTableData = _190[0], setReferenceDeleteTableData = _190[1];
539
+ var _191 = (0, react_1.useState)([]), relatedSections = _191[0], setRelatedSections = _191[1];
540
+ var _192 = (0, react_1.useState)(0), referenceDeleteIndex = _192[0], setReferenceDeleteIndex = _192[1];
541
+ var _193 = (0, react_1.useState)({
531
542
  id: "",
532
543
  name: "",
533
544
  type: "string",
534
- }), referenceCreationModal = _191[0], setReferenceCreationModal = _191[1];
535
- var _192 = (0, react_1.useState)({}), referenceModelSchema = _192[0], setReferenceSchema = _192[1];
536
- var _193 = (0, react_1.useState)([]), kanbanChecked = _193[0], setKanbanChecked = _193[1];
545
+ }), referenceCreationModal = _193[0], setReferenceCreationModal = _193[1];
546
+ var _194 = (0, react_1.useState)({}), referenceModelSchema = _194[0], setReferenceSchema = _194[1];
547
+ var _195 = (0, react_1.useState)([]), kanbanChecked = _195[0], setKanbanChecked = _195[1];
537
548
  //INFO : Offline
538
- var _194 = (0, react_1.useState)(0), offlineDataLength = _194[0], setOfflineDataLength = _194[1];
539
- var _195 = (0, react_1.useState)(false), offlineModal = _195[0], setOfflineModal = _195[1];
549
+ var _196 = (0, react_1.useState)(0), offlineDataLength = _196[0], setOfflineDataLength = _196[1];
550
+ var _197 = (0, react_1.useState)(false), offlineModal = _197[0], setOfflineModal = _197[1];
540
551
  // INFO: live-stream state — driven by socket connection and navigator.onLine
541
- var _196 = (0, react_1.useState)(false), isLive = _196[0], setIsLive = _196[1];
542
- var _197 = (0, react_1.useState)(false), isLiveOffline = _197[0], setIsLiveOffline = _197[1];
552
+ var _198 = (0, react_1.useState)(false), isLive = _198[0], setIsLive = _198[1];
553
+ var _199 = (0, react_1.useState)(false), isLiveOffline = _199[0], setIsLiveOffline = _199[1];
543
554
  // INFO: true when navigator is offline — used to switch ReadQueryHoc between
544
555
  // server reads (online, full pagination) and IndexedDB reads (offline, cached data).
545
556
  // Independent of SSE status so it works even when bareSocketName is not set.
546
- var _198 = (0, react_1.useState)(typeof navigator !== "undefined" ? !navigator.onLine : false), isNetworkOffline = _198[0], setIsNetworkOffline = _198[1];
557
+ var _200 = (0, react_1.useState)(typeof navigator !== "undefined" ? !navigator.onLine : false), isNetworkOffline = _200[0], setIsNetworkOffline = _200[1];
547
558
  var previousType = (0, react_1.useRef)(null);
548
559
  var previousSelectedData = (0, react_1.useRef)(null);
549
560
  var scrollSentinelRef = (0, react_1.useRef)(null);
@@ -760,7 +771,7 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
760
771
  var isSchemaHideMode = ((_10 = props.organise) === null || _10 === void 0 ? void 0 : _10.onChangeHide) ? true : false;
761
772
  // INFO: rows per page is a view setting the user can change, so it starts from
762
773
  // the persisted value and falls back to the consumer's limit
763
- var _199 = (0, react_1.useState)((_12 = (_11 = (isPersistEnabled ? persistedState === null || persistedState === void 0 ? void 0 : persistedState.pageLimit : undefined)) !== null && _11 !== void 0 ? _11 : props.limit) !== null && _12 !== void 0 ? _12 : 10), pageLimit = _199[0], setPageLimit = _199[1];
774
+ var _201 = (0, react_1.useState)((_12 = (_11 = (isPersistEnabled ? persistedState === null || persistedState === void 0 ? void 0 : persistedState.pageLimit : undefined)) !== null && _11 !== void 0 ? _11 : props.limit) !== null && _12 !== void 0 ? _12 : 10), pageLimit = _201[0], setPageLimit = _201[1];
764
775
  var limit = pageLimit;
765
776
  var isSavedViewsEnabled = !!((_13 = props.organise) === null || _13 === void 0 ? void 0 : _13.savedViews) && resolvedType === "list";
766
777
  // INFO: an app that stores views takes over from this browser's storage, so
@@ -785,7 +796,7 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
785
796
  setCursor("");
786
797
  setLastCursor("");
787
798
  };
788
- var _200 = (0, permissions_1.handleResolveDataTemplateWritePermissions)(props.edit), canUpdateRecord = _200.canUpdateRecord, canInlineUpdate = _200.canInlineUpdate, canBatchUpdate = _200.canBatchUpdate, canDeleteRecord = _200.canDeleteRecord;
799
+ var _202 = (0, permissions_1.handleResolveDataTemplateWritePermissions)(props.edit), canUpdateRecord = _202.canUpdateRecord, canInlineUpdate = _202.canInlineUpdate, canBatchUpdate = _202.canBatchUpdate, canDeleteRecord = _202.canDeleteRecord;
789
800
  var isEditor = ((_17 = props.edit) === null || _17 === void 0 ? void 0 : _17.allEditable) ? true : false;
790
801
  var isOffline = (_18 = props.bareSettings) === null || _18 === void 0 ? void 0 : _18.bareOffline;
791
802
  // INFO: when bareOfflineNetworkAware is true, the save path is also gated on
@@ -1900,15 +1911,17 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
1900
1911
  }); };
1901
1912
  // INFO : Set Updated Structure — skip on initial mount when persistViewState
1902
1913
  // restored column visibility/order from localStorage
1903
- if (!isPersistEnabled ||
1904
- !persistedState ||
1905
- persistedViewMountedRef.current) {
1914
+ var isRestoringView = isPersistEnabled && !!persistedState && !persistedViewMountedRef.current;
1915
+ if (!isRestoringView) {
1906
1916
  setStructure((_a = props.model) !== null && _a !== void 0 ? _a : []);
1907
1917
  schemaStructureRef.current = null;
1908
1918
  }
1909
1919
  persistedViewMountedRef.current = true;
1910
1920
  setAdditionalQuery((_c = (_b = props.organise) === null || _b === void 0 ? void 0 : _b.additionalQuery) !== null && _c !== void 0 ? _c : []);
1911
- setGroupId((_e = (_d = props.organise) === null || _d === void 0 ? void 0 : _d.groupBy) !== null && _e !== void 0 ? _e : "");
1921
+ // INFO: the restored grouping is set at mount; a later change of the
1922
+ // host's groupBy still applies
1923
+ if (!isRestoringView)
1924
+ setGroupId((_e = (_d = props.organise) === null || _d === void 0 ? void 0 : _d.groupBy) !== null && _e !== void 0 ? _e : "");
1912
1925
  setExportPDFTitle((_h = (_g = (_f = props.organise) === null || _f === void 0 ? void 0 : _f.exportSettings) === null || _g === void 0 ? void 0 : _g.defaultExportPDFName) !== null && _h !== void 0 ? _h : "");
1913
1926
  var currentTabProps = {
1914
1927
  id: props.id,
@@ -3243,10 +3256,20 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
3243
3256
  return __generator(this, function (_f) {
3244
3257
  switch (_f.label) {
3245
3258
  case 0:
3246
- if (!(props.space && props.space.authDatabase)) return [3 /*break*/, 2];
3247
- return [4 /*yield*/, (0, authModule_1.handleAuthMethods)(props.space, (_a = props.id) !== null && _a !== void 0 ? _a : "", (_b = props.lib) === null || _b === void 0 ? void 0 : _b.axios)];
3259
+ if (!(props.space && props.space.authDatabase)) return [3 /*break*/, 5];
3260
+ setAuthLoading(true);
3261
+ authProviders = null;
3262
+ _f.label = 1;
3248
3263
  case 1:
3264
+ _f.trys.push([1, , 3, 4]);
3265
+ return [4 /*yield*/, (0, authModule_1.handleAuthMethods)(props.space, (_a = props.id) !== null && _a !== void 0 ? _a : "", (_b = props.lib) === null || _b === void 0 ? void 0 : _b.axios)];
3266
+ case 2:
3249
3267
  authProviders = _f.sent();
3268
+ return [3 /*break*/, 4];
3269
+ case 3:
3270
+ setAuthLoading(false);
3271
+ return [7 /*endfinally*/];
3272
+ case 4:
3250
3273
  if (authProviders)
3251
3274
  setAuthMethods(authProviders);
3252
3275
  else
@@ -3257,8 +3280,8 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
3257
3280
  disabled: false,
3258
3281
  create: true,
3259
3282
  });
3260
- _f.label = 2;
3261
- case 2: return [2 /*return*/];
3283
+ _f.label = 5;
3284
+ case 5: return [2 /*return*/];
3262
3285
  }
3263
3286
  });
3264
3287
  }); };
@@ -3539,7 +3562,7 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
3539
3562
  }
3540
3563
  createFirebaseUploadHandler_1 = function (collectionId, dataId, fieldId) {
3541
3564
  return function (file, path) { return __awaiter(void 0, void 0, void 0, function () {
3542
- var pathParts, filename, responseData, imageEndpoint, token, encodedPath, firebaseUrl, error_1;
3565
+ var pathParts, filename, responseData, imageEndpoint, token, error_1;
3543
3566
  var _a, _b, _c, _d;
3544
3567
  return __generator(this, function (_e) {
3545
3568
  switch (_e.label) {
@@ -3558,9 +3581,7 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
3558
3581
  else if ((_c = responseData === null || responseData === void 0 ? void 0 : responseData.data) === null || _c === void 0 ? void 0 : _c.data) {
3559
3582
  imageEndpoint = ((_d = props.devSettings) === null || _d === void 0 ? void 0 : _d.imageEndpoint) || devSettings.imageEndpoint;
3560
3583
  token = responseData.data.data;
3561
- encodedPath = encodeURIComponent(path);
3562
- firebaseUrl = "".concat(imageEndpoint).concat(encodedPath, "?alt=media&token=").concat(token);
3563
- return [2 /*return*/, firebaseUrl];
3584
+ return [2 /*return*/, (0, blobModule_1.handleRenderUploadedFileLink)(imageEndpoint, path, token)];
3564
3585
  }
3565
3586
  throw new Error("No URL returned from upload");
3566
3587
  case 2:
@@ -3886,14 +3907,12 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
3886
3907
  if (!selectedField || !selectedField["remove"])
3887
3908
  return [2 /*return*/];
3888
3909
  return [4 /*yield*/, Promise.all(selectedField["remove"].map(function (eachField) { return __awaiter(void 0, void 0, void 0, function () {
3889
- var startIndex, endIndex, imageFileName, imageCollectionName, imageParentId;
3910
+ var imageFileName, imageCollectionName, imageParentId;
3890
3911
  var _a, _b;
3891
3912
  return __generator(this, function (_c) {
3892
3913
  switch (_c.label) {
3893
3914
  case 0:
3894
- startIndex = eachField.fileName.lastIndexOf("%2F") + 3;
3895
- endIndex = eachField.fileName.indexOf("?alt=media&token=");
3896
- imageFileName = eachField.fileName.substring(startIndex, endIndex);
3915
+ imageFileName = (0, blobModule_1.handleReadLinkFileName)(eachField.fileName);
3897
3916
  imageCollectionName = (_a = eachImage.imageCollectionName) !== null && _a !== void 0 ? _a : "";
3898
3917
  if (objectId) {
3899
3918
  imageCollectionName += "/".concat(dataId);
@@ -4230,14 +4249,20 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
4230
4249
  return __generator(this, function (_f) {
4231
4250
  switch (_f.label) {
4232
4251
  case 0:
4233
- _f.trys.push([0, 16, , 17]);
4252
+ if (deletingRef.current)
4253
+ return [2 /*return*/];
4254
+ deletingRef.current = true;
4255
+ setDeleting(true);
4256
+ _f.label = 1;
4257
+ case 1:
4258
+ _f.trys.push([1, 17, 18, 19]);
4234
4259
  setLoading(true);
4235
4260
  setModalVisible(true);
4236
4261
  passcodeMatch = deletePasscodeInput === deletePasscode;
4237
- if (!passcodeMatch) return [3 /*break*/, 14];
4238
- if (!((_a = props.bareSettings) === null || _a === void 0 ? void 0 : _a.bareOffline)) return [3 /*break*/, 3];
4262
+ if (!passcodeMatch) return [3 /*break*/, 15];
4263
+ if (!((_a = props.bareSettings) === null || _a === void 0 ? void 0 : _a.bareOffline)) return [3 /*break*/, 4];
4239
4264
  return [4 /*yield*/, indexedDb_1.indexedDb.getValue("local", props.collectionId)];
4240
- case 1:
4265
+ case 2:
4241
4266
  offlineDataResp = _f.sent();
4242
4267
  offlineData = (_b = offlineDataResp === null || offlineDataResp === void 0 ? void 0 : offlineDataResp.data) !== null && _b !== void 0 ? _b : [];
4243
4268
  filteredData = offlineData.filter(function (eachOfflineData) {
@@ -4247,31 +4272,31 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
4247
4272
  data: filteredData,
4248
4273
  type: props.collectionId,
4249
4274
  })];
4250
- case 2:
4251
- _f.sent();
4252
- return [3 /*break*/, 13];
4253
4275
  case 3:
4276
+ _f.sent();
4277
+ return [3 /*break*/, 14];
4278
+ case 4:
4254
4279
  ids = [];
4255
4280
  notReferenceId = [];
4256
- if (!selectAll) return [3 /*break*/, 7];
4281
+ if (!selectAll) return [3 /*break*/, 8];
4257
4282
  query = renderImpSearchFilterConditions();
4258
4283
  return [4 /*yield*/, readServerQuery.call({
4259
4284
  type: "list",
4260
4285
  query: query,
4261
4286
  stopLimit: true,
4262
4287
  })];
4263
- case 4:
4288
+ case 5:
4264
4289
  responseData = _f.sent();
4265
4290
  return [4 /*yield*/, handleCheckDeleteReference((_c = responseData === null || responseData === void 0 ? void 0 : responseData.data) !== null && _c !== void 0 ? _c : [], true)];
4266
- case 5:
4291
+ case 6:
4267
4292
  notReferenceId = _f.sent();
4268
4293
  return [4 /*yield*/, writeServerQuery.call("batchDelete", {
4269
4294
  id: notReferenceId,
4270
4295
  })];
4271
- case 6:
4296
+ case 7:
4272
4297
  ids = _f.sent();
4273
- return [3 /*break*/, 11];
4274
- case 7: return [4 /*yield*/, readServerQuery.call({
4298
+ return [3 /*break*/, 12];
4299
+ case 8: return [4 /*yield*/, readServerQuery.call({
4275
4300
  type: "list",
4276
4301
  query: [
4277
4302
  {
@@ -4282,18 +4307,18 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
4282
4307
  ],
4283
4308
  stopLimit: true,
4284
4309
  })];
4285
- case 8:
4310
+ case 9:
4286
4311
  responseData = _f.sent();
4287
4312
  return [4 /*yield*/, handleCheckDeleteReference((_d = responseData === null || responseData === void 0 ? void 0 : responseData.data) !== null && _d !== void 0 ? _d : [], true)];
4288
- case 9:
4313
+ case 10:
4289
4314
  notReferenceId = _f.sent();
4290
4315
  return [4 /*yield*/, writeServerQuery.call("batchDelete", {
4291
4316
  id: notReferenceId,
4292
4317
  })];
4293
- case 10:
4294
- ids = _f.sent();
4295
- _f.label = 11;
4296
4318
  case 11:
4319
+ ids = _f.sent();
4320
+ _f.label = 12;
4321
+ case 12:
4297
4322
  data = new FormData();
4298
4323
  data.append("data[assetCollectionName]", props.collectionId);
4299
4324
  data.append("data[assetParentId]", JSON.stringify(ids !== null && ids !== void 0 ? ids : []));
@@ -4308,13 +4333,13 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
4308
4333
  url: "".concat(uploadEndpoint, "/batchDeleteDirectory"),
4309
4334
  headers: { "Content-Type": "multipart/form-data" },
4310
4335
  }))];
4311
- case 12:
4336
+ case 13:
4312
4337
  _f.sent();
4313
4338
  if (mapViewRef.current)
4314
4339
  mapViewRef.current.handleClearPolygons();
4315
- _f.label = 13;
4316
- case 13: return [3 /*break*/, 15];
4317
- case 14:
4340
+ _f.label = 14;
4341
+ case 14: return [3 /*break*/, 16];
4342
+ case 15:
4318
4343
  setNotification({
4319
4344
  type: false,
4320
4345
  title: "Incorrect Passcode",
@@ -4323,11 +4348,15 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
4323
4348
  setLoading(false);
4324
4349
  setModalVisible(false);
4325
4350
  return [2 /*return*/];
4326
- case 15: return [3 /*break*/, 17];
4327
- case 16:
4328
- err_12 = _f.sent();
4329
- return [3 /*break*/, 17];
4351
+ case 16: return [3 /*break*/, 19];
4330
4352
  case 17:
4353
+ err_12 = _f.sent();
4354
+ return [3 /*break*/, 19];
4355
+ case 18:
4356
+ deletingRef.current = false;
4357
+ setDeleting(false);
4358
+ return [7 /*endfinally*/];
4359
+ case 19:
4331
4360
  setDeletePasscodeInput("");
4332
4361
  handleRefresh();
4333
4362
  return [2 /*return*/];
@@ -4335,33 +4364,44 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
4335
4364
  });
4336
4365
  }); };
4337
4366
  var handleRemoveSelectedData = function () { return __awaiter(void 0, void 0, void 0, function () {
4338
- var deletable, selectedId_1, deleteIds, res, offlineDataResp, offlineData, selectedIndex_2, doc, err_13;
4367
+ var deleted, deletable, selectedId_1, deleteIds, res, offlineDataResp, offlineData, selectedIndex_2, doc, err_13;
4339
4368
  var _a, _b, _c, _d, _e, _f, _g, _h, _j;
4340
4369
  return __generator(this, function (_k) {
4341
4370
  switch (_k.label) {
4342
4371
  case 0:
4343
- _k.trys.push([0, 13, , 14]);
4372
+ if (deletingRef.current)
4373
+ return [2 /*return*/];
4374
+ deletingRef.current = true;
4375
+ setDeleting(true);
4376
+ // INFO: shown before the reference check, which reads other datasheets
4377
+ // first — without it the confirm sat still and invited a second tap
4378
+ setLoading(true);
4379
+ setModalVisible(true);
4380
+ deleted = false;
4381
+ _k.label = 1;
4382
+ case 1:
4383
+ _k.trys.push([1, 14, 15, 16]);
4344
4384
  deletable = true;
4345
4385
  selectedId_1 = deleteFeedId || props.id;
4346
4386
  return [4 /*yield*/, handleCheckDeleteReference([selectedData])];
4347
- case 1:
4387
+ case 2:
4348
4388
  deleteIds = _k.sent();
4349
4389
  if (deleteIds && deleteIds.length <= 0)
4350
4390
  deletable = false;
4351
- if (!(deletable && ((_a = props.bareSettings) === null || _a === void 0 ? void 0 : _a.bareUpdateHandlePreComplete))) return [3 /*break*/, 3];
4391
+ if (!(deletable && ((_a = props.bareSettings) === null || _a === void 0 ? void 0 : _a.bareUpdateHandlePreComplete))) return [3 /*break*/, 4];
4352
4392
  return [4 /*yield*/, props.bareSettings.bareUpdateHandlePreComplete({}, handleResolveRawData())];
4353
- case 2:
4354
- deletable = _k.sent();
4355
- _k.label = 3;
4356
4393
  case 3:
4357
- if (!(selectedId_1 && deletable)) return [3 /*break*/, 12];
4394
+ deletable = _k.sent();
4395
+ _k.label = 4;
4396
+ case 4:
4397
+ if (!(selectedId_1 && deletable)) return [3 /*break*/, 13];
4358
4398
  setLoading(true);
4359
4399
  setModalVisible(true);
4360
4400
  setDeleteModal(true);
4361
4401
  res = void 0;
4362
- if (!((_b = props.bareSettings) === null || _b === void 0 ? void 0 : _b.bareOffline)) return [3 /*break*/, 6];
4402
+ if (!((_b = props.bareSettings) === null || _b === void 0 ? void 0 : _b.bareOffline)) return [3 /*break*/, 7];
4363
4403
  return [4 /*yield*/, indexedDb_1.indexedDb.getValue("local", props.collectionId)];
4364
- case 4:
4404
+ case 5:
4365
4405
  offlineDataResp = _k.sent();
4366
4406
  offlineData = (_c = offlineDataResp === null || offlineDataResp === void 0 ? void 0 : offlineDataResp.data) !== null && _c !== void 0 ? _c : [];
4367
4407
  selectedIndex_2 = -1;
@@ -4394,41 +4434,51 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
4394
4434
  data: offlineData,
4395
4435
  type: props.collectionId,
4396
4436
  })];
4397
- case 5:
4437
+ case 6:
4398
4438
  _k.sent();
4399
4439
  res = true;
4400
- return [3 /*break*/, 9];
4401
- case 6: return [4 /*yield*/, handleRemoveImage((_d = devSettings.bucketName) !== null && _d !== void 0 ? _d : "")];
4402
- case 7:
4440
+ return [3 /*break*/, 10];
4441
+ case 7: return [4 /*yield*/, handleRemoveImage((_d = devSettings.bucketName) !== null && _d !== void 0 ? _d : "")];
4442
+ case 8:
4403
4443
  _k.sent();
4404
4444
  return [4 /*yield*/, writeServerQuery.call("delete", { id: selectedId_1 })];
4405
- case 8:
4406
- res = _k.sent();
4407
- _k.label = 9;
4408
4445
  case 9:
4409
- if (!res) return [3 /*break*/, 12];
4410
- if (!((_e = props.bareSettings) === null || _e === void 0 ? void 0 : _e.bareUpdateHandlePostComplete)) return [3 /*break*/, 11];
4411
- return [4 /*yield*/, props.bareSettings.bareUpdateHandlePostComplete({}, handleResolveRawData())];
4446
+ res = _k.sent();
4447
+ _k.label = 10;
4412
4448
  case 10:
4413
- _k.sent();
4414
- _k.label = 11;
4449
+ if (!res) return [3 /*break*/, 13];
4450
+ if (!((_e = props.bareSettings) === null || _e === void 0 ? void 0 : _e.bareUpdateHandlePostComplete)) return [3 /*break*/, 12];
4451
+ return [4 /*yield*/, props.bareSettings.bareUpdateHandlePostComplete({}, handleResolveRawData())];
4415
4452
  case 11:
4453
+ _k.sent();
4454
+ _k.label = 12;
4455
+ case 12:
4456
+ deleted = true;
4416
4457
  if (selectedTab) {
4417
4458
  (_g = (_f = props.organise) === null || _f === void 0 ? void 0 : _f.handleNavigate) === null || _g === void 0 ? void 0 : _g.call(_f, "list", "", selectedTab.id);
4418
4459
  }
4419
4460
  else
4420
4461
  (_j = (_h = props.organise) === null || _h === void 0 ? void 0 : _h.handleNavigate) === null || _j === void 0 ? void 0 : _j.call(_h, "list", "", "general");
4421
- _k.label = 12;
4422
- case 12: return [3 /*break*/, 14];
4423
- case 13:
4462
+ _k.label = 13;
4463
+ case 13: return [3 /*break*/, 16];
4464
+ case 14:
4424
4465
  err_13 = _k.sent();
4425
4466
  setDeleteModal(false);
4426
4467
  setDeleteFeedId("");
4427
- return [3 /*break*/, 14];
4428
- case 14:
4468
+ return [3 /*break*/, 16];
4469
+ case 15:
4470
+ // INFO: released here so an early return (offline refusal) cannot leave
4471
+ // delete blocked
4472
+ deletingRef.current = false;
4473
+ setDeleting(false);
4474
+ return [7 /*endfinally*/];
4475
+ case 16:
4429
4476
  setLoading(false);
4430
4477
  setDeleteModal(false);
4431
4478
  setModalVisible(false);
4479
+ // INFO: the list it returns to still held the deleted row
4480
+ if (deleted)
4481
+ handleRefresh();
4432
4482
  return [2 /*return*/];
4433
4483
  }
4434
4484
  });
@@ -7756,7 +7806,7 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
7756
7806
  })) })) }));
7757
7807
  };
7758
7808
  var renderContent = function () {
7759
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, _14, _15, _16, _17, _18, _19, _20, _21, _22, _23, _24, _25, _26, _27, _28, _29, _30, _31, _32, _33, _34, _35, _36, _37, _38, _39, _40, _41, _42, _43, _44, _45;
7809
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, _14, _15, _16, _17, _18, _19, _20, _21, _22, _23, _24, _25, _26, _27, _28, _29, _30, _31, _32, _33, _34, _35, _36, _37, _38, _39, _40, _41, _42, _43, _44, _45, _46;
7760
7810
  var isBottom = ((_a = props.bareSettings) === null || _a === void 0 ? void 0 : _a.bareUpdateActionBottom) ? true : false;
7761
7811
  var tabs = renderTabs();
7762
7812
  var pages = [
@@ -7804,12 +7854,14 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
7804
7854
  ((_m = props.bareSettings) === null || _m === void 0 ? void 0 : _m.bareUpdateActionTop) &&
7805
7855
  !selectedRelated &&
7806
7856
  renderReadBar(),
7807
- anyAuthMethod && (react_1.default.createElement("div", { className: "bg-primary-100 text-gray-700 mt-3 px-5 py-3 rounded" }, renderAuthContent())),
7857
+ (anyAuthMethod ||
7858
+ (authLoading && ((_o = props.space) === null || _o === void 0 ? void 0 : _o.authDatabase))) && (react_1.default.createElement("div", { className: "bg-primary-100 text-gray-700 mt-3 px-5 py-3 rounded" }, authLoading ? (react_1.default.createElement("div", { className: "flex justify-center py-1", "data-testid": "dtw-auth-loading" },
7859
+ react_1.default.createElement(loading_1.Loading, { sizeClassName: "h-6 w-6" }))) : (renderAuthContent()))),
7808
7860
  react_1.default.createElement("div", { ref: exportReadPDFRef },
7809
- selectedRelated ? (react_1.default.createElement(relatedRecords_1.RelatedRecords, { key: "".concat(props.id, "-").concat(selectedRelated.id), source: selectedRelated.source, recordId: (_o = props.id) !== null && _o !== void 0 ? _o : "", renderList: renderRelatedList })) : (!((_p = props.bareSettings) === null || _p === void 0 ? void 0 : _p.bareReadComponentHide) && (react_1.default.createElement("div", null, renderTabContent(tabs, resolvedType, viewType)))),
7810
- ((_q = props.bareSettings) === null || _q === void 0 ? void 0 : _q.bareReadComponentPos) !== "top" &&
7861
+ selectedRelated ? (react_1.default.createElement(relatedRecords_1.RelatedRecords, { key: "".concat(props.id, "-").concat(selectedRelated.id), source: selectedRelated.source, recordId: (_p = props.id) !== null && _p !== void 0 ? _p : "", renderList: renderRelatedList })) : (!((_q = props.bareSettings) === null || _q === void 0 ? void 0 : _q.bareReadComponentHide) && (react_1.default.createElement("div", null, renderTabContent(tabs, resolvedType, viewType)))),
7862
+ ((_r = props.bareSettings) === null || _r === void 0 ? void 0 : _r.bareReadComponentPos) !== "top" &&
7811
7863
  renderBareReadComp()),
7812
- !((_r = props.bareSettings) === null || _r === void 0 ? void 0 : _r.bareUpdateActionTop) &&
7864
+ !((_s = props.bareSettings) === null || _s === void 0 ? void 0 : _s.bareUpdateActionTop) &&
7813
7865
  !selectedRelated &&
7814
7866
  renderReadBar()))));
7815
7867
  case "update":
@@ -7821,12 +7873,12 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
7821
7873
  });
7822
7874
  }
7823
7875
  pages.push({
7824
- name: (_u = selectedData === null || selectedData === void 0 ? void 0 : selectedData[(_t = (_s = props.organise) === null || _s === void 0 ? void 0 : _s.breadcrumbAttributeId) !== null && _t !== void 0 ? _t : serverId]) !== null && _u !== void 0 ? _u : (props.id ? props.id : "new"),
7876
+ name: (_v = selectedData === null || selectedData === void 0 ? void 0 : selectedData[(_u = (_t = props.organise) === null || _t === void 0 ? void 0 : _t.breadcrumbAttributeId) !== null && _u !== void 0 ? _u : serverId]) !== null && _v !== void 0 ? _v : (props.id ? props.id : "new"),
7825
7877
  href: "#",
7826
7878
  current: true,
7827
7879
  });
7828
7880
  var filterModel_1 = [];
7829
- var disabledOnEnter_1 = (_w = (_v = props.organise) === null || _v === void 0 ? void 0 : _v.disabledOnEnter) !== null && _w !== void 0 ? _w : false;
7881
+ var disabledOnEnter_1 = (_x = (_w = props.organise) === null || _w === void 0 ? void 0 : _w.disabledOnEnter) !== null && _x !== void 0 ? _x : false;
7830
7882
  structure.map(function (eachModel) {
7831
7883
  var _a;
7832
7884
  var present = false;
@@ -7939,12 +7991,12 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
7939
7991
  }
7940
7992
  }
7941
7993
  };
7942
- var hasTabAlign_1 = ((_x = props.organise) === null || _x === void 0 ? void 0 : _x.tabAlign) || ((_y = props.space) === null || _y === void 0 ? void 0 : _y.tabAlign);
7943
- var leftTabAlign = ((_z = props.organise) === null || _z === void 0 ? void 0 : _z.tabAlign) === "left" ||
7944
- ((_0 = props.space) === null || _0 === void 0 ? void 0 : _0.tabAlign) === "left";
7945
- var topTabAlign = ((_1 = props.organise) === null || _1 === void 0 ? void 0 : _1.tabAlign) === "top" || ((_2 = props.space) === null || _2 === void 0 ? void 0 : _2.tabAlign) === "top";
7946
- var stepperTabAlign = ((_3 = props.organise) === null || _3 === void 0 ? void 0 : _3.tabAlign) === "stepper" ||
7947
- ((_4 = props.space) === null || _4 === void 0 ? void 0 : _4.tabAlign) === "stepper";
7994
+ var hasTabAlign_1 = ((_y = props.organise) === null || _y === void 0 ? void 0 : _y.tabAlign) || ((_z = props.space) === null || _z === void 0 ? void 0 : _z.tabAlign);
7995
+ var leftTabAlign = ((_0 = props.organise) === null || _0 === void 0 ? void 0 : _0.tabAlign) === "left" ||
7996
+ ((_1 = props.space) === null || _1 === void 0 ? void 0 : _1.tabAlign) === "left";
7997
+ var topTabAlign = ((_2 = props.organise) === null || _2 === void 0 ? void 0 : _2.tabAlign) === "top" || ((_3 = props.space) === null || _3 === void 0 ? void 0 : _3.tabAlign) === "top";
7998
+ var stepperTabAlign = ((_4 = props.organise) === null || _4 === void 0 ? void 0 : _4.tabAlign) === "stepper" ||
7999
+ ((_5 = props.space) === null || _5 === void 0 ? void 0 : _5.tabAlign) === "stepper";
7948
8000
  var uniqueTabIds_2 = Array.from(new Set(filterModel_1
7949
8001
  .map(function (item) { return item.tabId; })
7950
8002
  .filter(function (id) { return id !== undefined; })));
@@ -7953,7 +8005,7 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
7953
8005
  if (shouldIncludeOthers) {
7954
8006
  uniqueTabIds_2.push("");
7955
8007
  }
7956
- var customTabComponent_1 = (_7 = (_6 = (_5 = props.bareSettings) === null || _5 === void 0 ? void 0 : _5.bareUpdateTabComponent) === null || _6 === void 0 ? void 0 : _6.call(_5, uniqueTabIds_2)) !== null && _7 !== void 0 ? _7 : [];
8008
+ var customTabComponent_1 = (_8 = (_7 = (_6 = props.bareSettings) === null || _6 === void 0 ? void 0 : _6.bareUpdateTabComponent) === null || _7 === void 0 ? void 0 : _7.call(_6, uniqueTabIds_2)) !== null && _8 !== void 0 ? _8 : [];
7957
8009
  var stepperSteps = uniqueTabIds_2.map(function (eachTabId) {
7958
8010
  var _a, _b;
7959
8011
  var customTabMatch = customTabComponent_1.find(function (eachTab) { return eachTab.tabId === eachTabId; });
@@ -7988,7 +8040,7 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
7988
8040
  props.id && props.id !== "new" && structure.length >= 1 && (react_1.default.createElement(readQueryHoc_1.ReadQueryHoc, { ref: readQueryHocRef, database: {
7989
8041
  dbModule: dbModule,
7990
8042
  dbType: devSettings.server,
7991
- dbCollection: (_9 = (_8 = props === null || props === void 0 ? void 0 : props.space) === null || _8 === void 0 ? void 0 : _8.pipelineDefaultSpaceId) !== null && _9 !== void 0 ? _9 : props.collectionId,
8043
+ dbCollection: (_10 = (_9 = props === null || props === void 0 ? void 0 : props.space) === null || _9 === void 0 ? void 0 : _9.pipelineDefaultSpaceId) !== null && _10 !== void 0 ? _10 : props.collectionId,
7992
8044
  dbEndpoint: devSettings.dbEndpoint,
7993
8045
  dbAPIToken: devSettings.dbAPIToken,
7994
8046
  dbUserToken: devSettings.dbUserToken,
@@ -7996,11 +8048,11 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
7996
8048
  type: "get",
7997
8049
  id: props.id,
7998
8050
  pipeline: pipeline,
7999
- }, offline: ((_10 = props.bareSettings) === null || _10 === void 0 ? void 0 : _10.bareOffline) && isNetworkOffline, onChangeData: handleRetrieveSelectedData, onError: handleGetItemError })),
8051
+ }, offline: ((_11 = props.bareSettings) === null || _11 === void 0 ? void 0 : _11.bareOffline) && isNetworkOffline, onChangeData: handleRetrieveSelectedData, onError: handleGetItemError })),
8000
8052
  renderBreadcrumb(pages),
8001
8053
  react_1.default.createElement("div", { className: "flex flex-col py-2 sm:items-center sm:flex-row" },
8002
8054
  (props.title || props.description) && (react_1.default.createElement("div", { className: "flex flex-col w-full" },
8003
- props.title && (react_1.default.createElement("p", { className: "text-xl font-medium ".concat(((_11 = props.organise) === null || _11 === void 0 ? void 0 : _11.darkMode) ? "text-white" : "") }, props.title)),
8055
+ props.title && (react_1.default.createElement("p", { className: "text-xl font-medium ".concat(((_12 = props.organise) === null || _12 === void 0 ? void 0 : _12.darkMode) ? "text-white" : "") }, props.title)),
8004
8056
  props.description && (react_1.default.createElement("span", { className: "text-sm text-gray-500" }, props.description)))),
8005
8057
  (!isBottom || hasTabAlign_1 || resolvedType === "update") &&
8006
8058
  renderActionButtons(resolvedType, hasTabAlign_1, uniqueTabIds_2)),
@@ -8019,10 +8071,10 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
8019
8071
  var tabId = uniqueTabIds_2[stepIndex];
8020
8072
  handleUpdateTabId(tabId);
8021
8073
  } })),
8022
- ((_12 = props.bareSettings) === null || _12 === void 0 ? void 0 : _12.bareUpdateComponentAbove) &&
8023
- ((_13 = props.bareSettings) === null || _13 === void 0 ? void 0 : _13.bareUpdateComponent) &&
8024
- ((_14 = props.bareSettings) === null || _14 === void 0 ? void 0 : _14.bareUpdateComponent(selectedData, handleResolveRawData())),
8025
- ((_15 = props.bareSettings) === null || _15 === void 0 ? void 0 : _15.bareUpdateActionTop) &&
8074
+ ((_13 = props.bareSettings) === null || _13 === void 0 ? void 0 : _13.bareUpdateComponentAbove) &&
8075
+ ((_14 = props.bareSettings) === null || _14 === void 0 ? void 0 : _14.bareUpdateComponent) &&
8076
+ ((_15 = props.bareSettings) === null || _15 === void 0 ? void 0 : _15.bareUpdateComponent(selectedData, handleResolveRawData())),
8077
+ ((_16 = props.bareSettings) === null || _16 === void 0 ? void 0 : _16.bareUpdateActionTop) &&
8026
8078
  renderStepBar(uniqueTabIds_2),
8027
8079
  react_1.default.createElement(form_1.Form, { className: "mt-6", ref: formRef, refList: __spreadArray(__spreadArray([], modalFormInputRefs, true), flexTableRefs, true), handleComplete: handleSubmit, disabledOnEnter: disabledOnEnter_1, handleOnFailValidation: handleOnFailValidation },
8028
8080
  uniqueTabIds_2.map(function (tabId) {
@@ -8044,8 +8096,8 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
8044
8096
  ((_c = (_b = props.organise) === null || _b === void 0 ? void 0 : _b.tabDescriptions) === null || _c === void 0 ? void 0 : _c[tabId]) && (react_1.default.createElement("p", { className: "text-sm mt-0.5 ".concat(((_d = props.organise) === null || _d === void 0 ? void 0 : _d.darkMode) ? "text-gray-400" : "text-gray-500") }, props.organise.tabDescriptions[tabId])))),
8045
8097
  renderDataTemplateFormContent(selectedData, filterByTab, modalFormInputRefs, false, false, undefined, undefined)));
8046
8098
  }),
8047
- !((_16 = props.bareSettings) === null || _16 === void 0 ? void 0 : _16.bareUpdateComponentAbove) &&
8048
- ((_17 = props.bareSettings) === null || _17 === void 0 ? void 0 : _17.bareUpdateComponent) && (
8099
+ !((_17 = props.bareSettings) === null || _17 === void 0 ? void 0 : _17.bareUpdateComponentAbove) &&
8100
+ ((_18 = props.bareSettings) === null || _18 === void 0 ? void 0 : _18.bareUpdateComponent) && (
8049
8101
  // INFO: the form is a grid-cols-12. A child with no column span is one
8050
8102
  // column, and a grid item cannot shrink below its longest word, so on a
8051
8103
  // phone it wraps one word per line. `contents` takes this wrapper out of
@@ -8055,20 +8107,20 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
8055
8107
  react_1.default.createElement("div", { className: "contents [&>*:not([class*=col-span])]:col-span-12" }, props.bareSettings.bareUpdateComponent(selectedData, handleResolveRawData())))),
8056
8108
  react_1.default.createElement("div", { className: "mt-8" }, renderListAddress(resolvedType)),
8057
8109
  react_1.default.createElement("div", { className: "mt-8" }, renderListObject(resolvedType)),
8058
- !((_18 = props.bareSettings) === null || _18 === void 0 ? void 0 : _18.bareUpdateActionTop) &&
8110
+ !((_19 = props.bareSettings) === null || _19 === void 0 ? void 0 : _19.bareUpdateActionTop) &&
8059
8111
  renderStepBar(uniqueTabIds_2),
8060
8112
  isBottom &&
8061
8113
  resolvedType !== "update" &&
8062
8114
  renderActionButtons(resolvedType, hasTabAlign_1, uniqueTabIds_2)))) : (react_1.default.createElement("div", null,
8063
- ((_19 = props.bareSettings) === null || _19 === void 0 ? void 0 : _19.bareUpdateComponentAbove) &&
8064
- ((_20 = props.bareSettings) === null || _20 === void 0 ? void 0 : _20.bareUpdateComponent) &&
8065
- ((_21 = props.bareSettings) === null || _21 === void 0 ? void 0 : _21.bareUpdateComponent(selectedData, handleResolveRawData())),
8066
- ((_22 = props.bareSettings) === null || _22 === void 0 ? void 0 : _22.bareUpdateActionTop) &&
8115
+ ((_20 = props.bareSettings) === null || _20 === void 0 ? void 0 : _20.bareUpdateComponentAbove) &&
8116
+ ((_21 = props.bareSettings) === null || _21 === void 0 ? void 0 : _21.bareUpdateComponent) &&
8117
+ ((_22 = props.bareSettings) === null || _22 === void 0 ? void 0 : _22.bareUpdateComponent(selectedData, handleResolveRawData())),
8118
+ ((_23 = props.bareSettings) === null || _23 === void 0 ? void 0 : _23.bareUpdateActionTop) &&
8067
8119
  renderStepBar(uniqueTabIds_2),
8068
8120
  react_1.default.createElement(form_1.Form, { className: "grid ".concat(formColumn, " ").concat(gridGap, " mt-6"), ref: formRef, refList: __spreadArray(__spreadArray([], modalFormInputRefs, true), flexTableRefs, true), handleComplete: handleSubmit, disabledOnEnter: disabledOnEnter_1, handleOnFailValidation: handleOnFailValidation },
8069
8121
  renderDataTemplateFormContent(selectedData, filterModel_1, modalFormInputRefs, false, false),
8070
- !((_23 = props.bareSettings) === null || _23 === void 0 ? void 0 : _23.bareUpdateComponentAbove) &&
8071
- ((_24 = props.bareSettings) === null || _24 === void 0 ? void 0 : _24.bareUpdateComponent) && (
8122
+ !((_24 = props.bareSettings) === null || _24 === void 0 ? void 0 : _24.bareUpdateComponentAbove) &&
8123
+ ((_25 = props.bareSettings) === null || _25 === void 0 ? void 0 : _25.bareUpdateComponent) && (
8072
8124
  // INFO: the form is a grid-cols-12. A child with no column span is one
8073
8125
  // column, and a grid item cannot shrink below its longest word, so on a
8074
8126
  // phone it wraps one word per line. `contents` takes this wrapper out of
@@ -8078,7 +8130,7 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
8078
8130
  react_1.default.createElement("div", { className: "contents [&>*:not([class*=col-span])]:col-span-12" }, props.bareSettings.bareUpdateComponent(selectedData, handleResolveRawData())))),
8079
8131
  react_1.default.createElement("div", { className: "mt-8" }, renderListAddress(resolvedType)),
8080
8132
  react_1.default.createElement("div", { className: "mt-8" }, renderListObject(resolvedType)),
8081
- !((_25 = props.bareSettings) === null || _25 === void 0 ? void 0 : _25.bareUpdateActionTop) &&
8133
+ !((_26 = props.bareSettings) === null || _26 === void 0 ? void 0 : _26.bareUpdateActionTop) &&
8082
8134
  renderStepBar(uniqueTabIds_2)))));
8083
8135
  case "list":
8084
8136
  case "union":
@@ -8087,20 +8139,20 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
8087
8139
  var actionComponent = renderActionButtons(resolvedType);
8088
8140
  // INFO: active flex filter count for the icon badge + floating search.
8089
8141
  // Counts query output so the badge matches what's actually filtered.
8090
- var activeFlexFilterCount_1 = ((_26 = props.bareSettings) === null || _26 === void 0 ? void 0 : _26.bareFlexFilters)
8142
+ var activeFlexFilterCount_1 = ((_27 = props.bareSettings) === null || _27 === void 0 ? void 0 : _27.bareFlexFilters)
8091
8143
  ? (0, listModule_1.renderFlexFilterConditions)(flexFilters, structure).length
8092
8144
  : 0;
8093
8145
  var listReadQueryHOC = (react_1.default.createElement(readQueryHoc_1.ReadQueryHoc, { ref: listRQueryHocRef, database: {
8094
8146
  dbModule: dbModule,
8095
8147
  dbType: devSettings.server,
8096
- dbCollection: (_28 = (_27 = props === null || props === void 0 ? void 0 : props.space) === null || _27 === void 0 ? void 0 : _27.pipelineDefaultSpaceId) !== null && _28 !== void 0 ? _28 : props.collectionId,
8148
+ dbCollection: (_29 = (_28 = props === null || props === void 0 ? void 0 : props.space) === null || _28 === void 0 ? void 0 : _28.pipelineDefaultSpaceId) !== null && _29 !== void 0 ? _29 : props.collectionId,
8097
8149
  dbEndpoint: devSettings.dbEndpoint,
8098
8150
  dbAPIToken: devSettings.dbAPIToken,
8099
8151
  dbUserToken: devSettings.dbUserToken,
8100
- }, cond: handleReadQueryHocCond(), offline: ((_29 = props.bareSettings) === null || _29 === void 0 ? void 0 : _29.bareOffline) && isNetworkOffline, onChangeData: function (data, cond) {
8152
+ }, cond: handleReadQueryHocCond(), offline: ((_30 = props.bareSettings) === null || _30 === void 0 ? void 0 : _30.bareOffline) && isNetworkOffline, onChangeData: function (data, cond) {
8101
8153
  handleGetListData(data, "", "", cond);
8102
8154
  }, onError: handleGetItemError }));
8103
- if ((_30 = props.renderSettings) === null || _30 === void 0 ? void 0 : _30.renderListUI) {
8155
+ if ((_31 = props.renderSettings) === null || _31 === void 0 ? void 0 : _31.renderListUI) {
8104
8156
  return (react_1.default.createElement(react_1.default.Fragment, null,
8105
8157
  listReadQueryHOC,
8106
8158
  props.renderSettings.renderListUI(actionComponent, filterComponent_1, dataComponent)));
@@ -8312,47 +8364,47 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
8312
8364
  };
8313
8365
  return (react_1.default.createElement(react_1.default.Fragment, null,
8314
8366
  listReadQueryHOC,
8315
- react_1.default.createElement("div", { className: "flex py-2 ".concat(((_31 = props.bareSettings) === null || _31 === void 0 ? void 0 : _31.bareCompactMode)
8367
+ react_1.default.createElement("div", { className: "flex py-2 ".concat(((_32 = props.bareSettings) === null || _32 === void 0 ? void 0 : _32.bareCompactMode)
8316
8368
  ? // INFO: the grow spacer is hidden on phones (search lives in
8317
8369
  // the floating bar), so the row itself pushes the actions right
8318
8370
  "w-full flex-row flex-wrap sm:flex-nowrap items-end justify-between sm:justify-start"
8319
8371
  : "flex-col md:items-end md:flex-row") },
8320
8372
  (props.title || props.description) && (react_1.default.createElement("div", { className: "flex flex-col" },
8321
8373
  props.title && (react_1.default.createElement("div", { className: "flex items-center gap-2" },
8322
- react_1.default.createElement("p", { className: "text-xl font-medium ".concat(((_32 = props.organise) === null || _32 === void 0 ? void 0 : _32.darkMode) ? "text-white" : "") }, props.title),
8323
- ((_33 = props.bareSettings) === null || _33 === void 0 ? void 0 : _33.bareSocketName) &&
8374
+ react_1.default.createElement("p", { className: "text-xl font-medium ".concat(((_33 = props.organise) === null || _33 === void 0 ? void 0 : _33.darkMode) ? "text-white" : "") }, props.title),
8375
+ ((_34 = props.bareSettings) === null || _34 === void 0 ? void 0 : _34.bareSocketName) &&
8324
8376
  isLive &&
8325
8377
  !isLiveOffline && (react_1.default.createElement("span", { className: "inline-flex items-center gap-1 rounded-full bg-green-100 px-2 py-0.5 text-xs font-medium text-green-700" },
8326
8378
  react_1.default.createElement("span", { className: "h-1.5 w-1.5 rounded-full bg-green-500" }),
8327
8379
  "LIVE")),
8328
- ((_34 = props.bareSettings) === null || _34 === void 0 ? void 0 : _34.bareSocketName) && isLiveOffline && (react_1.default.createElement("span", { className: "inline-flex items-center gap-1 rounded-full bg-orange-100 px-2 py-0.5 text-xs font-medium text-orange-700" },
8380
+ ((_35 = props.bareSettings) === null || _35 === void 0 ? void 0 : _35.bareSocketName) && isLiveOffline && (react_1.default.createElement("span", { className: "inline-flex items-center gap-1 rounded-full bg-orange-100 px-2 py-0.5 text-xs font-medium text-orange-700" },
8329
8381
  react_1.default.createElement("span", { className: "h-1.5 w-1.5 rounded-full bg-orange-400" }),
8330
8382
  "OFFLINE")))),
8331
8383
  props.description && (react_1.default.createElement("span", { className: "text-sm text-gray-500" }, props.description)))),
8332
- react_1.default.createElement("div", { className: ((_35 = props.bareSettings) === null || _35 === void 0 ? void 0 : _35.bareCompactMode)
8384
+ react_1.default.createElement("div", { className: ((_36 = props.bareSettings) === null || _36 === void 0 ? void 0 : _36.bareCompactMode)
8333
8385
  ? "hidden sm:block grow"
8334
8386
  : "grow" }),
8335
8387
  react_1.default.createElement("div", { className: "ml-auto flex flex-row items-end" },
8336
8388
  renderListFilterElements(),
8337
8389
  renderListActionElements())),
8338
8390
  renderListNewRowFilterElements(),
8339
- (schemaPresent || ((_36 = props.bareSettings) === null || _36 === void 0 ? void 0 : _36.bareReadListTabs)) && (react_1.default.createElement(tabs_1.Tabs, { tabs: tabs, selectedId: viewType, linkType: props.linkType, custom: props.custom, onClick: function (id) { return handleSelectTab(id); }, darkMode: (_37 = props.organise) === null || _37 === void 0 ? void 0 : _37.darkMode })),
8391
+ (schemaPresent || ((_37 = props.bareSettings) === null || _37 === void 0 ? void 0 : _37.bareReadListTabs)) && (react_1.default.createElement(tabs_1.Tabs, { tabs: tabs, selectedId: viewType, linkType: props.linkType, custom: props.custom, onClick: function (id) { return handleSelectTab(id); }, darkMode: (_38 = props.organise) === null || _38 === void 0 ? void 0 : _38.darkMode })),
8340
8392
  renderScopedTabContent(tabs, resolvedType, viewType),
8341
- ((_38 = props.bareSettings) === null || _38 === void 0 ? void 0 : _38.bareListMobileFloatingSearch) && (react_1.default.createElement("div", { className: "h-28 md:hidden", "aria-hidden": "true" })),
8342
- ((_39 = props.bareSettings) === null || _39 === void 0 ? void 0 : _39.bareListMobileFloatingSearch) &&
8393
+ ((_39 = props.bareSettings) === null || _39 === void 0 ? void 0 : _39.bareListMobileFloatingSearch) && (react_1.default.createElement("div", { className: "h-28 md:hidden", "aria-hidden": "true" })),
8394
+ ((_40 = props.bareSettings) === null || _40 === void 0 ? void 0 : _40.bareListMobileFloatingSearch) &&
8343
8395
  (0, listModule_1.renderFloatingMobileSearch)({
8344
8396
  filterSearch: filterSearch,
8345
8397
  handleNameSearch: handleNameSearch,
8346
8398
  onFilterClick: function () { return setFlexFilterModalOpen(true); },
8347
- hideSearch: (_40 = props.organise) === null || _40 === void 0 ? void 0 : _40.hideSearch,
8348
- darkMode: (_41 = props.organise) === null || _41 === void 0 ? void 0 : _41.darkMode,
8349
- floatingOffset: (_42 = props.bareSettings) === null || _42 === void 0 ? void 0 : _42.bareListFloatingActionOffset,
8350
- hideFilter: !((_43 = props.bareSettings) === null || _43 === void 0 ? void 0 : _43.bareFlexFilters),
8351
- activeFilterCount: ((_44 = props.bareSettings) === null || _44 === void 0 ? void 0 : _44.bareFlexFilters)
8399
+ hideSearch: (_41 = props.organise) === null || _41 === void 0 ? void 0 : _41.hideSearch,
8400
+ darkMode: (_42 = props.organise) === null || _42 === void 0 ? void 0 : _42.darkMode,
8401
+ floatingOffset: (_43 = props.bareSettings) === null || _43 === void 0 ? void 0 : _43.bareListFloatingActionOffset,
8402
+ hideFilter: !((_44 = props.bareSettings) === null || _44 === void 0 ? void 0 : _44.bareFlexFilters),
8403
+ activeFilterCount: ((_45 = props.bareSettings) === null || _45 === void 0 ? void 0 : _45.bareFlexFilters)
8352
8404
  ? activeFlexFilterCount_1
8353
8405
  : undefined,
8354
8406
  // INFO: Hides when items are selected so NewTable's multi-action bar takes over.
8355
- hidden: selectAll || ((_45 = selectedIds === null || selectedIds === void 0 ? void 0 : selectedIds.length) !== null && _45 !== void 0 ? _45 : 0) > 0,
8407
+ hidden: selectAll || ((_46 = selectedIds === null || selectedIds === void 0 ? void 0 : selectedIds.length) !== null && _46 !== void 0 ? _46 : 0) > 0,
8356
8408
  })));
8357
8409
  default:
8358
8410
  return react_1.default.createElement(react_1.default.Fragment, null);
@@ -8622,19 +8674,23 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
8622
8674
  // group absent from the first page would never appear; those keep the
8623
8675
  // global scroll instead. Firebase pages by document cursor, not by count.
8624
8676
  var renderCheckGroupPaging = function () {
8625
- var _a, _b, _c, _d;
8677
+ var _a, _b, _c, _d, _e, _f;
8626
8678
  var paginationType = renderResolvedPaginationType();
8627
8679
  if (paginationType !== "scroll" && paginationType !== "page")
8628
8680
  return false;
8629
8681
  if (!groupId || isFirebase)
8630
8682
  return false;
8683
+ // INFO: a union list pages by skip, which a per-band cursor cannot express,
8684
+ // so it keeps the single pager and groups the loaded rows
8685
+ if ((_b = (_a = props.organise) === null || _a === void 0 ? void 0 : _a.unionCollections) === null || _b === void 0 ? void 0 : _b.length)
8686
+ return false;
8631
8687
  // INFO: the mobile list draws no bands, so it keeps the normal pagination
8632
- if (!((_a = props.bareSettings) === null || _a === void 0 ? void 0 : _a.bareNewDTW) ||
8633
- ((_b = props.bareSettings) === null || _b === void 0 ? void 0 : _b.bareListMobileView))
8688
+ if (!((_c = props.bareSettings) === null || _c === void 0 ? void 0 : _c.bareNewDTW) ||
8689
+ ((_d = props.bareSettings) === null || _d === void 0 ? void 0 : _d.bareListMobileView))
8634
8690
  return false;
8635
8691
  var groupAttributeDS = structure.find(function (eachDS) { return eachDS.id === groupId; });
8636
8692
  return ((groupAttributeDS === null || groupAttributeDS === void 0 ? void 0 : groupAttributeDS.type) === "list" &&
8637
- ((_d = (_c = groupAttributeDS.listSelection) === null || _c === void 0 ? void 0 : _c.length) !== null && _d !== void 0 ? _d : 0) > 0);
8693
+ ((_f = (_e = groupAttributeDS.listSelection) === null || _e === void 0 ? void 0 : _e.length) !== null && _f !== void 0 ? _f : 0) > 0);
8638
8694
  };
8639
8695
  var renderResolvedPaginationType = function () {
8640
8696
  var _a;
@@ -8952,7 +9008,7 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
8952
9008
  // same prettifier so its rows carry the shape of every other row. Returns
8953
9009
  // undefined when the list was re-read while the page was in flight.
8954
9010
  var handleReadGroupPage = function (groupKey, cursor) { return __awaiter(void 0, void 0, void 0, function () {
8955
- var generation, groupAttributeDS, groupQuery, baseQuery, responseData, rawRows, count, prettierRows;
9011
+ var generation, groupAttributeDS, groupQuery, mainCond, responseData, rawRows, count, prettierRows;
8956
9012
  var _a, _b, _c, _d, _e, _f, _g, _h;
8957
9013
  return __generator(this, function (_j) {
8958
9014
  switch (_j.label) {
@@ -8968,14 +9024,8 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
8968
9024
  },
8969
9025
  ]
8970
9026
  : [{ type: "=", queryId: groupId !== null && groupId !== void 0 ? groupId : "", value: groupKey }];
8971
- baseQuery = (_b = renderImpSearchFilterConditions()) !== null && _b !== void 0 ? _b : [];
8972
- return [4 /*yield*/, readServerQuery.call({
8973
- type: "list",
8974
- query: __spreadArray(__spreadArray([], baseQuery, true), groupQuery, true),
8975
- cursor: cursor,
8976
- limit: limit,
8977
- sort: handleReadQueryHocSort(baseQuery),
8978
- })];
9027
+ mainCond = handleReadQueryHocCond();
9028
+ return [4 /*yield*/, readServerQuery.call(__assign(__assign({}, mainCond), { query: __spreadArray(__spreadArray([], ((_b = mainCond.query) !== null && _b !== void 0 ? _b : []), true), groupQuery, true), cursor: cursor, limit: limit, stopLimit: undefined, skip: 0 }))];
8979
9029
  case 1:
8980
9030
  responseData = _j.sent();
8981
9031
  if (generation !== groupPagingGenRef.current)
@@ -10900,7 +10950,7 @@ exports.DataTemplate = (0, react_1.forwardRef)(function (props, ref) {
10900
10950
  setDeletePasscodeInput("");
10901
10951
  setDeleteModal(false);
10902
10952
  } }),
10903
- react_1.default.createElement(button_1.Button, { id: "dtw-delete-confirm", text: "Delete", size: "small", type: "danger", onClick: function () {
10953
+ react_1.default.createElement(button_1.Button, { id: "dtw-delete-confirm", text: "Delete", size: "small", type: "danger", disable: deleting, onClick: function () {
10904
10954
  if (selectedTab &&
10905
10955
  selectedTab.viewType === "feeds" &&
10906
10956
  deleteFeedId) {