kaafil-react-uikit 0.6.0 → 0.7.1
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.
- package/CHANGELOG.md +26 -0
- package/dist/admin/index.cjs +468 -446
- package/dist/admin/index.cjs.map +1 -1
- package/dist/admin/index.js +128 -106
- package/dist/admin/index.js.map +1 -1
- package/dist/{chunk-53ITV6GF.cjs → chunk-4R7QBTNL.cjs} +4 -4
- package/dist/{chunk-53ITV6GF.cjs.map → chunk-4R7QBTNL.cjs.map} +1 -1
- package/dist/{chunk-HNENKHHJ.js → chunk-57DYMIWS.js} +5 -5
- package/dist/{chunk-HNENKHHJ.js.map → chunk-57DYMIWS.js.map} +1 -1
- package/dist/{chunk-XPF737RG.cjs → chunk-7COMKJTM.cjs} +9 -9
- package/dist/{chunk-XPF737RG.cjs.map → chunk-7COMKJTM.cjs.map} +1 -1
- package/dist/{chunk-OOHU3ECL.cjs → chunk-7O3TPYK4.cjs} +17 -17
- package/dist/{chunk-OOHU3ECL.cjs.map → chunk-7O3TPYK4.cjs.map} +1 -1
- package/dist/{chunk-4QMYUKW4.cjs → chunk-ASFUY3IE.cjs} +5368 -5358
- package/dist/chunk-ASFUY3IE.cjs.map +1 -0
- package/dist/{chunk-CJMUPBZ7.js → chunk-DYOAKTGJ.js} +5 -5
- package/dist/{chunk-CJMUPBZ7.js.map → chunk-DYOAKTGJ.js.map} +1 -1
- package/dist/{chunk-JHLPO6LZ.js → chunk-E3KOQYY2.js} +3 -3
- package/dist/{chunk-JHLPO6LZ.js.map → chunk-E3KOQYY2.js.map} +1 -1
- package/dist/{chunk-F6B4CDUL.js → chunk-GKR52SVU.js} +3 -3
- package/dist/{chunk-F6B4CDUL.js.map → chunk-GKR52SVU.js.map} +1 -1
- package/dist/chunk-LBTAK5JA.cjs +12 -0
- package/dist/{chunk-V45VFRBI.cjs.map → chunk-LBTAK5JA.cjs.map} +1 -1
- package/dist/{chunk-77RKNRNH.cjs → chunk-MP4IMAPF.cjs} +55 -55
- package/dist/{chunk-77RKNRNH.cjs.map → chunk-MP4IMAPF.cjs.map} +1 -1
- package/dist/{chunk-AWOKWGTB.cjs → chunk-PQJGV3RE.cjs} +83 -83
- package/dist/{chunk-AWOKWGTB.cjs.map → chunk-PQJGV3RE.cjs.map} +1 -1
- package/dist/{chunk-F6YBM6EE.js → chunk-Q4B25EZO.js} +3 -3
- package/dist/{chunk-F6YBM6EE.js.map → chunk-Q4B25EZO.js.map} +1 -1
- package/dist/{chunk-XPCCR7OH.cjs → chunk-TDFM563X.cjs} +12 -12
- package/dist/{chunk-XPCCR7OH.cjs.map → chunk-TDFM563X.cjs.map} +1 -1
- package/dist/{chunk-PWZNUXKT.js → chunk-VU5BCK2P.js} +3 -3
- package/dist/{chunk-PWZNUXKT.js.map → chunk-VU5BCK2P.js.map} +1 -1
- package/dist/{chunk-4BPCKBLP.js → chunk-YHGAFRN6.js} +3 -3
- package/dist/{chunk-4BPCKBLP.js.map → chunk-YHGAFRN6.js.map} +1 -1
- package/dist/{chunk-SEPFCHBJ.js → chunk-ZURCZQQ7.js} +5368 -5358
- package/dist/chunk-ZURCZQQ7.js.map +1 -0
- package/dist/core/index.cjs +107 -107
- package/dist/core/index.js +10 -10
- package/dist/index.css +1 -1
- package/dist/manager/index.cjs +239 -239
- package/dist/manager/index.js +6 -6
- package/dist/traveller/index.cjs +35 -35
- package/dist/traveller/index.js +5 -5
- package/package.json +1 -1
- package/dist/chunk-4QMYUKW4.cjs.map +0 -1
- package/dist/chunk-SEPFCHBJ.js.map +0 -1
- package/dist/chunk-V45VFRBI.cjs +0 -12
package/dist/admin/index.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { useAgencySettings, useAgencyChecklistTemplates, useAgencyForms, useAgencyManagerProfile, useAgencyJourneyTriggers, useBookings, useDirectories, useCapabilityStatuses, useAgencyTrip, useAgencyAdminMe, useTravellerFormResponses, useBuildShareUrl, familySafeSections, useShareLinks, usePaginatedList, useAgencyTrips, useAgencyTripManifest, resolveBlockerDeepLink } from '../chunk-
|
|
2
|
-
import { useChecklists, useFiles, useExpenses, useVendors, useFloat, useManagers, useForms, useItinerary, useCollections, useParties, usePickups, useRooming, useSeating, classifyError, useTravellerProfile, roomingHeuristicSeverity, useManagerToday, useCloseout, parseRoomingTone, TONE_FAMILIES, SHADES_PER_FAMILY, FALLBACK_GLYPH } from '../chunk-
|
|
3
|
-
import '../chunk-
|
|
4
|
-
export { BootErrorScreen, LockedTripScreen, NotFoundScreen, OfflineFallbackScreen, PlanLockedScreen, SessionExpiredScreen } from '../chunk-
|
|
5
|
-
import { createRegistry, useKaafilChrome, tokenStyle, useSession, useKaafilClient } from '../chunk-
|
|
1
|
+
import { useAgencySettings, useAgencyChecklistTemplates, useAgencyForms, useAgencyManagerProfile, useAgencyJourneyTriggers, useBookings, useDirectories, useCapabilityStatuses, useAgencyTrip, useAgencyAdminMe, useTravellerFormResponses, useBuildShareUrl, familySafeSections, useShareLinks, usePaginatedList, useAgencyTrips, useAgencyTripManifest, resolveBlockerDeepLink } from '../chunk-57DYMIWS.js';
|
|
2
|
+
import { useChecklists, useFiles, useExpenses, useVendors, useFloat, useManagers, useForms, useItinerary, useCollections, useParties, usePickups, useRooming, useSeating, classifyError, useTravellerProfile, roomingHeuristicSeverity, useManagerToday, useCloseout, parseRoomingTone, TONE_FAMILIES, SHADES_PER_FAMILY, FALLBACK_GLYPH } from '../chunk-VU5BCK2P.js';
|
|
3
|
+
import '../chunk-GKR52SVU.js';
|
|
4
|
+
export { BootErrorScreen, LockedTripScreen, NotFoundScreen, OfflineFallbackScreen, PlanLockedScreen, SessionExpiredScreen } from '../chunk-YHGAFRN6.js';
|
|
5
|
+
import { createRegistry, useKaafilChrome, tokenStyle, useSession, useKaafilClient } from '../chunk-ZURCZQQ7.js';
|
|
6
6
|
import { useState, useEffect, useCallback, useMemo, useId, useRef, Children } from 'react';
|
|
7
7
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
8
8
|
|
|
@@ -14453,36 +14453,51 @@ var KIND_LABEL_KEY = {
|
|
|
14453
14453
|
CORPORATE: "chrome.tripManifest.partyKind.corporate",
|
|
14454
14454
|
OTHER: "chrome.tripManifest.partyKind.other"
|
|
14455
14455
|
};
|
|
14456
|
-
|
|
14456
|
+
var NEW_GROUP = "__new__";
|
|
14457
|
+
function ManageGroupsDialog({
|
|
14457
14458
|
tripRef,
|
|
14458
|
-
|
|
14459
|
-
|
|
14459
|
+
rows,
|
|
14460
|
+
initialPartyId,
|
|
14460
14461
|
onClose,
|
|
14461
14462
|
onSaved
|
|
14462
14463
|
}) {
|
|
14463
14464
|
const { t } = useKaafilChrome();
|
|
14464
14465
|
const titleId = useId();
|
|
14465
14466
|
const { createParty, patchParty, deleteParty } = useDirectories();
|
|
14466
|
-
const
|
|
14467
|
-
|
|
14467
|
+
const groups = deriveManifestGroups(rows).filter(
|
|
14468
|
+
(group) => group.id !== SOLO_GROUP_ID && group.party !== null
|
|
14469
|
+
);
|
|
14470
|
+
const openable = initialPartyId !== void 0 && groups.some((group) => group.id === initialPartyId) ? initialPartyId : groups[0]?.id ?? NEW_GROUP;
|
|
14471
|
+
const [selectedId, setSelectedId] = useState(openable);
|
|
14472
|
+
const selected = groups.find((group) => group.id === selectedId);
|
|
14473
|
+
const creating = selectedId === NEW_GROUP;
|
|
14474
|
+
const editing = selected?.party ?? null;
|
|
14468
14475
|
const [kind, setKind] = useState(
|
|
14469
|
-
|
|
14476
|
+
editing?.kind ?? "OTHER"
|
|
14470
14477
|
);
|
|
14471
|
-
const [label, setLabel] = useState(
|
|
14478
|
+
const [label, setLabel] = useState(editing?.label ?? "");
|
|
14472
14479
|
const [members, setMembers] = useState(
|
|
14473
|
-
new Set((
|
|
14480
|
+
new Set((selected?.rows ?? []).map((row) => row.traveller.travellerId))
|
|
14474
14481
|
);
|
|
14475
14482
|
const [pending, setPending] = useState(false);
|
|
14476
14483
|
const [errorCode, setErrorCode] = useState(void 0);
|
|
14477
|
-
|
|
14478
|
-
|
|
14479
|
-
|
|
14484
|
+
function select(nextId) {
|
|
14485
|
+
const next = groups.find((group) => group.id === nextId);
|
|
14486
|
+
setSelectedId(nextId);
|
|
14487
|
+
setKind(next?.party?.kind ?? "OTHER");
|
|
14488
|
+
setLabel(next?.party?.label ?? "");
|
|
14489
|
+
setMembers(new Set((next?.rows ?? []).map((row) => row.traveller.travellerId)));
|
|
14490
|
+
setErrorCode(void 0);
|
|
14491
|
+
}
|
|
14480
14492
|
function toggle(travellerId) {
|
|
14481
14493
|
const next = new Set(members);
|
|
14482
14494
|
if (next.has(travellerId)) next.delete(travellerId);
|
|
14483
14495
|
else next.add(travellerId);
|
|
14484
14496
|
setMembers(next);
|
|
14485
14497
|
}
|
|
14498
|
+
const moving = rows.filter(
|
|
14499
|
+
(row) => members.has(row.traveller.travellerId) && row.party != null && row.party.id !== selectedId
|
|
14500
|
+
);
|
|
14486
14501
|
function report(error) {
|
|
14487
14502
|
const classification = error !== null && typeof error === "object" && "classification" in error ? error.classification : void 0;
|
|
14488
14503
|
setErrorCode(classification?.code ?? "unknown");
|
|
@@ -14499,24 +14514,20 @@ function EditPartyDialog({
|
|
|
14499
14514
|
...trimmed.length === 0 ? {} : { label: trimmed },
|
|
14500
14515
|
travellerRefs: [...members]
|
|
14501
14516
|
});
|
|
14502
|
-
|
|
14503
|
-
|
|
14517
|
+
} else {
|
|
14518
|
+
await patchParty({
|
|
14519
|
+
tripRef,
|
|
14520
|
+
partyId: editing.id,
|
|
14521
|
+
// The PARTY's own version, off the row's denormalised party. The
|
|
14522
|
+
// manifest row carries a `version` too — that one guards the
|
|
14523
|
+
// TripTraveller LINK, not this, and sending the wrong one would be
|
|
14524
|
+
// a guard token for a different row.
|
|
14525
|
+
version: editing.version,
|
|
14526
|
+
kind,
|
|
14527
|
+
label: trimmed.length === 0 ? null : trimmed,
|
|
14528
|
+
travellerRefs: [...members]
|
|
14529
|
+
});
|
|
14504
14530
|
}
|
|
14505
|
-
await patchParty({
|
|
14506
|
-
tripRef,
|
|
14507
|
-
partyId: editing.id,
|
|
14508
|
-
// The PARTY's own version, off the row's denormalised party. Note the
|
|
14509
|
-
// manifest row also carries a `version` — that one guards the
|
|
14510
|
-
// TripTraveller LINK, not this. The endpoint returns both because a
|
|
14511
|
-
// console needs both, and confusing them would send a guard token for
|
|
14512
|
-
// the wrong row.
|
|
14513
|
-
version: editing.version,
|
|
14514
|
-
kind,
|
|
14515
|
-
// `null` CLEARS the label; a trimmed-empty box means "no label",
|
|
14516
|
-
// which is a clear rather than a set to empty string.
|
|
14517
|
-
label: trimmed.length === 0 ? null : trimmed,
|
|
14518
|
-
travellerRefs: [...members]
|
|
14519
|
-
});
|
|
14520
14531
|
onSaved();
|
|
14521
14532
|
} catch (error) {
|
|
14522
14533
|
report(error);
|
|
@@ -14525,10 +14536,10 @@ function EditPartyDialog({
|
|
|
14525
14536
|
}
|
|
14526
14537
|
}
|
|
14527
14538
|
async function retire() {
|
|
14539
|
+
if (editing === null) return;
|
|
14528
14540
|
setPending(true);
|
|
14529
14541
|
setErrorCode(void 0);
|
|
14530
14542
|
try {
|
|
14531
|
-
if (editing === null) return;
|
|
14532
14543
|
await deleteParty({ tripRef, partyId: editing.id });
|
|
14533
14544
|
onSaved();
|
|
14534
14545
|
} catch (error) {
|
|
@@ -14537,19 +14548,27 @@ function EditPartyDialog({
|
|
|
14537
14548
|
setPending(false);
|
|
14538
14549
|
}
|
|
14539
14550
|
}
|
|
14551
|
+
const enoughMembers = members.size >= MIN_PARTY_MEMBERS;
|
|
14540
14552
|
return /* @__PURE__ */ jsxs(
|
|
14541
14553
|
SheetDialog,
|
|
14542
14554
|
{
|
|
14543
14555
|
titleId,
|
|
14544
|
-
title: t(
|
|
14545
|
-
|
|
14546
|
-
),
|
|
14547
|
-
description: t(
|
|
14548
|
-
creating ? "chrome.tripManifest.newGroupBody" : "chrome.tripManifest.editGroupBody"
|
|
14549
|
-
),
|
|
14556
|
+
title: t("chrome.tripManifest.manageGroupsTitle"),
|
|
14557
|
+
description: t("chrome.tripManifest.manageGroupsBody"),
|
|
14550
14558
|
onClose,
|
|
14551
14559
|
closeLabel: t("chrome.tripManifest.close"),
|
|
14552
14560
|
footer: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
14561
|
+
creating ? null : /* @__PURE__ */ jsx(
|
|
14562
|
+
"button",
|
|
14563
|
+
{
|
|
14564
|
+
type: "button",
|
|
14565
|
+
className: "kf-trip-manifest-section__dialog-danger",
|
|
14566
|
+
onClick: () => void retire(),
|
|
14567
|
+
disabled: pending,
|
|
14568
|
+
children: t("chrome.tripManifest.retireGroup")
|
|
14569
|
+
}
|
|
14570
|
+
),
|
|
14571
|
+
/* @__PURE__ */ jsx("span", { className: "kf-trip-manifest-section__toolbar-spacer" }),
|
|
14553
14572
|
/* @__PURE__ */ jsx(
|
|
14554
14573
|
"button",
|
|
14555
14574
|
{
|
|
@@ -14572,6 +14591,37 @@ function EditPartyDialog({
|
|
|
14572
14591
|
)
|
|
14573
14592
|
] }),
|
|
14574
14593
|
children: [
|
|
14594
|
+
/* @__PURE__ */ jsxs("fieldset", { className: "kf-trip-manifest-section__share-fieldset", children: [
|
|
14595
|
+
/* @__PURE__ */ jsx("legend", { className: "kf-trip-manifest-section__share-legend", children: t("chrome.tripManifest.groupPickerLegend") }),
|
|
14596
|
+
/* @__PURE__ */ jsxs("div", { className: "kf-trip-manifest-section__share-chips", children: [
|
|
14597
|
+
groups.map((group) => /* @__PURE__ */ jsxs(
|
|
14598
|
+
"button",
|
|
14599
|
+
{
|
|
14600
|
+
type: "button",
|
|
14601
|
+
className: "kf-trip-manifest-section__share-chip",
|
|
14602
|
+
"data-active": selectedId === group.id ? "true" : void 0,
|
|
14603
|
+
onClick: () => select(group.id),
|
|
14604
|
+
disabled: pending,
|
|
14605
|
+
children: [
|
|
14606
|
+
group.party?.label ?? t("chrome.tripManifest.unnamedGroup"),
|
|
14607
|
+
/* @__PURE__ */ jsx("span", { className: "kf-trip-manifest-section__chip-count", children: group.rows.length })
|
|
14608
|
+
]
|
|
14609
|
+
},
|
|
14610
|
+
group.id
|
|
14611
|
+
)),
|
|
14612
|
+
/* @__PURE__ */ jsx(
|
|
14613
|
+
"button",
|
|
14614
|
+
{
|
|
14615
|
+
type: "button",
|
|
14616
|
+
className: "kf-trip-manifest-section__share-chip",
|
|
14617
|
+
"data-active": creating ? "true" : void 0,
|
|
14618
|
+
onClick: () => select(NEW_GROUP),
|
|
14619
|
+
disabled: pending,
|
|
14620
|
+
children: t("chrome.tripManifest.newGroupChip")
|
|
14621
|
+
}
|
|
14622
|
+
)
|
|
14623
|
+
] })
|
|
14624
|
+
] }),
|
|
14575
14625
|
editing !== null && editing.source === "DERIVED" ? /* @__PURE__ */ jsx("p", { className: "kf-trip-manifest-section__dialog-note", "data-tone": "warn", children: t("chrome.tripManifest.pinNote") }) : null,
|
|
14576
14626
|
/* @__PURE__ */ jsxs("label", { className: "kf-trip-manifest-section__field", children: [
|
|
14577
14627
|
/* @__PURE__ */ jsx("span", { className: "kf-trip-manifest-section__field-label", children: t("chrome.tripManifest.fieldGroupLabel") }),
|
|
@@ -14601,38 +14651,39 @@ function EditPartyDialog({
|
|
|
14601
14651
|
] }),
|
|
14602
14652
|
/* @__PURE__ */ jsxs("fieldset", { className: "kf-trip-manifest-section__share-fieldset", children: [
|
|
14603
14653
|
/* @__PURE__ */ jsx("legend", { className: "kf-trip-manifest-section__share-legend", children: t("chrome.tripManifest.fieldGroupMembers") }),
|
|
14604
|
-
/* @__PURE__ */ jsx("div", { className: "kf-trip-manifest-section__share-grid", children:
|
|
14605
|
-
|
|
14606
|
-
|
|
14607
|
-
|
|
14608
|
-
|
|
14609
|
-
|
|
14610
|
-
|
|
14611
|
-
|
|
14612
|
-
|
|
14613
|
-
|
|
14614
|
-
|
|
14615
|
-
|
|
14616
|
-
|
|
14617
|
-
|
|
14618
|
-
|
|
14619
|
-
|
|
14620
|
-
|
|
14621
|
-
|
|
14622
|
-
|
|
14654
|
+
/* @__PURE__ */ jsx("div", { className: "kf-trip-manifest-section__share-grid", children: rows.map((row) => {
|
|
14655
|
+
const inThisGroup = row.party != null && row.party.id === selectedId;
|
|
14656
|
+
const elsewhere = row.party != null && !inThisGroup ? row.party : null;
|
|
14657
|
+
return /* @__PURE__ */ jsxs(
|
|
14658
|
+
"label",
|
|
14659
|
+
{
|
|
14660
|
+
className: "kf-trip-manifest-section__member-option",
|
|
14661
|
+
children: [
|
|
14662
|
+
/* @__PURE__ */ jsx(
|
|
14663
|
+
"input",
|
|
14664
|
+
{
|
|
14665
|
+
type: "checkbox",
|
|
14666
|
+
checked: members.has(row.traveller.travellerId),
|
|
14667
|
+
onChange: () => toggle(row.traveller.travellerId)
|
|
14668
|
+
}
|
|
14669
|
+
),
|
|
14670
|
+
/* @__PURE__ */ jsx("span", { className: "kf-trip-manifest-section__member-name", children: row.traveller.fullName }),
|
|
14671
|
+
elsewhere === null ? null : /* @__PURE__ */ jsx("span", { className: "kf-trip-manifest-section__member-current", children: t("chrome.tripManifest.memberInGroup").replace(
|
|
14672
|
+
"{group}",
|
|
14673
|
+
elsewhere.label ?? t("chrome.tripManifest.unnamedGroup")
|
|
14674
|
+
) })
|
|
14675
|
+
]
|
|
14676
|
+
},
|
|
14677
|
+
row.traveller.travellerId
|
|
14678
|
+
);
|
|
14679
|
+
}) }),
|
|
14680
|
+
moving.length > 0 ? /* @__PURE__ */ jsx("p", { className: "kf-trip-manifest-section__dialog-note", "data-tone": "warn", children: t(
|
|
14681
|
+
moving.length === 1 ? "chrome.tripManifest.movesOne" : "chrome.tripManifest.movesMany"
|
|
14682
|
+
).replace("{count}", String(moving.length)) }) : null,
|
|
14683
|
+
members.size < MIN_PARTY_MEMBERS ? /* @__PURE__ */ jsx("p", { className: "kf-trip-manifest-section__dialog-note", children: t("chrome.tripManifest.tooFewMembers") }) : null
|
|
14623
14684
|
] }),
|
|
14624
|
-
creating ? null : /* @__PURE__ */ jsx("div", { className: "kf-trip-manifest-section__danger-lane", children: /* @__PURE__ */ jsx(
|
|
14625
|
-
"button",
|
|
14626
|
-
{
|
|
14627
|
-
type: "button",
|
|
14628
|
-
className: "kf-trip-manifest-section__dialog-danger",
|
|
14629
|
-
onClick: () => void retire(),
|
|
14630
|
-
disabled: pending,
|
|
14631
|
-
children: t("chrome.tripManifest.retireGroup")
|
|
14632
|
-
}
|
|
14633
|
-
) }),
|
|
14634
14685
|
errorCode === void 0 ? null : /* @__PURE__ */ jsx("p", { className: "kf-trip-manifest-section__dialog-error", role: "alert", children: t(
|
|
14635
|
-
errorCode === "CONFLICT_VERSION" ? "chrome.tripManifest.
|
|
14686
|
+
errorCode === "CONFLICT_VERSION" ? "chrome.tripManifest.groupConflict" : "chrome.tripManifest.groupFailed"
|
|
14636
14687
|
) })
|
|
14637
14688
|
]
|
|
14638
14689
|
}
|
|
@@ -16219,10 +16270,10 @@ function TripManifestSection({
|
|
|
16219
16270
|
{
|
|
16220
16271
|
type: "button",
|
|
16221
16272
|
className: "kf-trip-manifest-section__toolbar-button",
|
|
16222
|
-
onClick: () => setOverlay({ kind: "
|
|
16273
|
+
onClick: () => setOverlay({ kind: "groups" }),
|
|
16223
16274
|
children: [
|
|
16224
|
-
/* @__PURE__ */ jsx(
|
|
16225
|
-
t("chrome.tripManifest.
|
|
16275
|
+
/* @__PURE__ */ jsx(GroupIcon, {}),
|
|
16276
|
+
t("chrome.tripManifest.manageGroups")
|
|
16226
16277
|
]
|
|
16227
16278
|
}
|
|
16228
16279
|
) : null
|
|
@@ -16238,7 +16289,7 @@ function TripManifestSection({
|
|
|
16238
16289
|
onOpen: (row) => setOverlay({ kind: "detail", row }),
|
|
16239
16290
|
onRemove: (row) => setOverlay({ kind: "remove", row }),
|
|
16240
16291
|
onShareLink: (row) => setOverlay({ kind: "shareTraveller", row }),
|
|
16241
|
-
onEditGroup: (partyId) => setOverlay({ kind: "
|
|
16292
|
+
onEditGroup: (partyId) => setOverlay({ kind: "groups", partyId }),
|
|
16242
16293
|
onRowsChange: setVisibleRows,
|
|
16243
16294
|
...onOpenTravellerProfile !== void 0 ? {
|
|
16244
16295
|
onOpenProfile: (row) => onOpenTravellerProfile(row.traveller.travellerId, row.traveller.fullName)
|
|
@@ -16267,21 +16318,12 @@ function TripManifestSection({
|
|
|
16267
16318
|
}
|
|
16268
16319
|
) : null,
|
|
16269
16320
|
overlay.kind === "add" ? /* @__PURE__ */ jsx(AddTravellerDialog, { tripRef, onClose: closeOverlay, onAdded: afterWrite }) : null,
|
|
16270
|
-
overlay.kind === "
|
|
16271
|
-
|
|
16321
|
+
overlay.kind === "groups" ? /* @__PURE__ */ jsx(
|
|
16322
|
+
ManageGroupsDialog,
|
|
16272
16323
|
{
|
|
16273
16324
|
tripRef,
|
|
16274
|
-
partyId: overlay.partyId,
|
|
16275
16325
|
rows: visibleRows,
|
|
16276
|
-
|
|
16277
|
-
onSaved: afterWrite
|
|
16278
|
-
}
|
|
16279
|
-
) : null,
|
|
16280
|
-
overlay.kind === "newParty" ? /* @__PURE__ */ jsx(
|
|
16281
|
-
EditPartyDialog,
|
|
16282
|
-
{
|
|
16283
|
-
tripRef,
|
|
16284
|
-
candidates: visibleRows,
|
|
16326
|
+
...overlay.partyId !== void 0 ? { initialPartyId: overlay.partyId } : {},
|
|
16285
16327
|
onClose: closeOverlay,
|
|
16286
16328
|
onSaved: afterWrite
|
|
16287
16329
|
}
|
|
@@ -16306,26 +16348,6 @@ function TripManifestSection({
|
|
|
16306
16348
|
) : null
|
|
16307
16349
|
] });
|
|
16308
16350
|
}
|
|
16309
|
-
function EditPartyForId({
|
|
16310
|
-
tripRef,
|
|
16311
|
-
partyId,
|
|
16312
|
-
rows,
|
|
16313
|
-
onClose,
|
|
16314
|
-
onSaved
|
|
16315
|
-
}) {
|
|
16316
|
-
const group = deriveManifestGroups(rows).find((candidate) => candidate.id === partyId);
|
|
16317
|
-
if (group === void 0) return null;
|
|
16318
|
-
return /* @__PURE__ */ jsx(
|
|
16319
|
-
EditPartyDialog,
|
|
16320
|
-
{
|
|
16321
|
-
tripRef,
|
|
16322
|
-
group,
|
|
16323
|
-
candidates: rows,
|
|
16324
|
-
onClose,
|
|
16325
|
-
onSaved
|
|
16326
|
-
}
|
|
16327
|
-
);
|
|
16328
|
-
}
|
|
16329
16351
|
|
|
16330
16352
|
// src/admin/composite/office/TripPaymentsSection/internal/derivePayments.ts
|
|
16331
16353
|
function liveCollections(rows) {
|