@seatmap-fyi/map-domain 0.1.0-alpha.48 → 0.1.0-alpha.51

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 (42) hide show
  1. package/dist/arc-fan-rebuild.d.ts +9 -5
  2. package/dist/arc-fan-rebuild.js +78 -14
  3. package/dist/arc-fan-section-layout.d.ts +11 -0
  4. package/dist/arc-fan-section-layout.js +54 -0
  5. package/dist/arc-fan.interface.d.ts +18 -1
  6. package/dist/categories.d.ts +11 -2
  7. package/dist/categories.js +42 -10
  8. package/dist/editor-state.d.ts +2 -0
  9. package/dist/editor-state.js +3 -0
  10. package/dist/floors.d.ts +1 -1
  11. package/dist/floors.js +4 -9
  12. package/dist/geometry/decoration-bounds.d.ts +6 -1
  13. package/dist/geometry/decoration-bounds.js +23 -1
  14. package/dist/geometry/geometry.d.ts +4 -0
  15. package/dist/geometry/geometry.js +37 -10
  16. package/dist/geometry/inventory-outline.d.ts +8 -0
  17. package/dist/geometry/inventory-outline.js +46 -0
  18. package/dist/geometry/seat-shape.js +4 -4
  19. package/dist/geometry/seating-layout.d.ts +1 -0
  20. package/dist/geometry/seating-layout.js +7 -0
  21. package/dist/geometry/three-point-arc.d.ts +10 -0
  22. package/dist/geometry/three-point-arc.js +32 -0
  23. package/dist/geometry/venue-outline.js +44 -9
  24. package/dist/issues.d.ts +2 -0
  25. package/dist/issues.js +2 -0
  26. package/dist/layers.js +20 -4
  27. package/dist/media.d.ts +16 -2
  28. package/dist/media.js +19 -0
  29. package/dist/physical-document.interface.d.ts +77 -7
  30. package/dist/physical-document.interface.js +19 -0
  31. package/dist/schema.d.ts +174 -5
  32. package/dist/schema.js +82 -16
  33. package/dist/section-growth.d.ts +3 -3
  34. package/dist/section-growth.interface.d.ts +10 -2
  35. package/dist/section-growth.js +83 -36
  36. package/dist/section-layout.d.ts +9 -3
  37. package/dist/section-layout.js +2 -0
  38. package/dist/table-layout.d.ts +2 -1
  39. package/dist/table-layout.js +21 -13
  40. package/dist/validation.d.ts +1 -0
  41. package/dist/validation.js +13 -16
  42. package/package.json +9 -1
package/dist/schema.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { ArcFanFacing, ArcFanFit, ArcFanSectionOrigin } from "./arc-fan.interface.js";
2
2
  import { EntranceKind, GateUse, LineCap, LineJoin, LineEnding } from "./wayfinding.interface.js";
3
- import { TicketRestriction, TableBookingMode, TableChairDistribution, StandingBookingMode, SeatShape, type PhysicalDocumentV1, type SeatingGroup, type SeatSlot, type UUID, NumberingScheme, LabelDirection, RowLabelPosition, AccessNeed, SeatingKind, CurveMode, DecorationKind, LabelAlignment, RowAlignment, RowStagger, RowEnds, RowJoin, SectionOutlineRole, SectionTier, AreaKind, ShapeKind, VenueGlyph } from "./physical-document.interface.js";
3
+ import { TicketRestriction, TableBookingMode, TableChairDistribution, StandingBookingMode, SeatShape, type PhysicalDocumentV1, type SeatingGroup, type SeatSlot, type UUID, NumberingScheme, LabelDirection, TableChairNumberFormat, RowLabelPosition, AccessNeed, SeatingKind, CurveMode, DecorationKind, ReferencePlanLayer, LabelAlignment, RowAlignment, RowStagger, RowEnds, RowJoin, SectionOutlineRole, SectionTier, AreaKind, ShapeKind, VenueGlyph } from "./physical-document.interface.js";
4
4
  import { z } from "zod";
5
5
  import { type DomainIssue } from "./issues.js";
6
6
  export declare const storedLabelSchema: z.ZodString;
@@ -8,6 +8,17 @@ export declare const hexColourSchema: z.ZodString;
8
8
  export declare const buyerPhotoSchema: z.ZodObject<{
9
9
  assetId: z.ZodString;
10
10
  }, z.core.$strict>;
11
+ export declare const venueBuyerPhotoSchema: z.ZodObject<{
12
+ assetId: z.ZodString;
13
+ initialBearingDeg: z.ZodOptional<z.ZodNumber>;
14
+ initialPitchDeg: z.ZodOptional<z.ZodNumber>;
15
+ capturedAt: z.ZodOptional<z.ZodISODate>;
16
+ sourceLabel: z.ZodOptional<z.ZodString>;
17
+ sourceDimensions: z.ZodOptional<z.ZodObject<{
18
+ width: z.ZodInt;
19
+ height: z.ZodInt;
20
+ }, z.core.$strict>>;
21
+ }, z.core.$strict>;
11
22
  export declare const seatPresentationSchema: z.ZodObject<{
12
23
  buyerPhoto: z.ZodOptional<z.ZodObject<{
13
24
  assetId: z.ZodString;
@@ -86,6 +97,15 @@ export declare const segmentedRowSchema: z.ZodObject<{
86
97
  labelOverride: z.ZodOptional<z.ZodString>;
87
98
  }, z.core.$strict>>;
88
99
  }, z.core.$strict>;
100
+ export declare const tableChairNumberingSchema: z.ZodObject<{
101
+ startAt: z.ZodNumber;
102
+ direction: z.ZodEnum<{
103
+ forward: LabelDirection.Forward;
104
+ reverse: LabelDirection.Reverse;
105
+ }>;
106
+ format: z.ZodEnum<typeof TableChairNumberFormat>;
107
+ }, z.core.$strict>;
108
+ export declare const tableBuyerNounSchema: z.ZodString;
89
109
  export declare const groupSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
90
110
  kind: z.ZodLiteral<SeatingKind.Straight>;
91
111
  recipe: z.ZodObject<{
@@ -115,6 +135,10 @@ export declare const groupSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
115
135
  }, z.core.$strict>;
116
136
  sectionId: z.ZodNullable<z.ZodString>;
117
137
  sectionOrigin: z.ZodEnum<typeof ArcFanSectionOrigin>;
138
+ sectionOutlineGridOriginM: z.ZodOptional<z.ZodObject<{
139
+ x: z.ZodNumber;
140
+ y: z.ZodNumber;
141
+ }, z.core.$strict>>;
118
142
  members: z.ZodArray<z.ZodObject<{
119
143
  rowId: z.ZodString;
120
144
  bookingLabel: z.ZodString;
@@ -352,6 +376,10 @@ export declare const groupSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
352
376
  }, z.core.$strict>;
353
377
  sectionId: z.ZodNullable<z.ZodString>;
354
378
  sectionOrigin: z.ZodEnum<typeof ArcFanSectionOrigin>;
379
+ sectionOutlineGridOriginM: z.ZodOptional<z.ZodObject<{
380
+ x: z.ZodNumber;
381
+ y: z.ZodNumber;
382
+ }, z.core.$strict>>;
355
383
  members: z.ZodArray<z.ZodObject<{
356
384
  rowId: z.ZodString;
357
385
  bookingLabel: z.ZodString;
@@ -554,6 +582,7 @@ export declare const groupSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
554
582
  }, z.core.$strict>], "kind">>;
555
583
  }, z.core.$strict>, z.ZodObject<{
556
584
  kind: z.ZodLiteral<SeatingKind.Rectangular>;
585
+ surfaceColor: z.ZodOptional<z.ZodString>;
557
586
  selling: z.ZodOptional<z.ZodDiscriminatedUnion<[z.ZodObject<{
558
587
  mode: z.ZodEnum<{
559
588
  individual: TableBookingMode.Individual;
@@ -578,7 +607,14 @@ export declare const groupSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
578
607
  automaticSize: z.ZodOptional<z.ZodBoolean>;
579
608
  seatArcDeg: z.ZodOptional<z.ZodNumber>;
580
609
  }, z.core.$strict>>;
610
+ conversionSides: z.ZodOptional<z.ZodObject<{
611
+ top: z.ZodBoolean;
612
+ bottom: z.ZodBoolean;
613
+ left: z.ZodBoolean;
614
+ right: z.ZodBoolean;
615
+ }, z.core.$strict>>;
581
616
  labels: z.ZodObject<{
617
+ buyerNoun: z.ZodOptional<z.ZodString>;
582
618
  chairs: z.ZodObject<{
583
619
  scheme: z.ZodEnum<typeof NumberingScheme>;
584
620
  startAt: z.ZodNumber;
@@ -591,6 +627,14 @@ export declare const groupSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
591
627
  }>>;
592
628
  lastAt: z.ZodOptional<z.ZodNumber>;
593
629
  }, z.core.$strict>;
630
+ chairNumbering: z.ZodOptional<z.ZodObject<{
631
+ startAt: z.ZodNumber;
632
+ direction: z.ZodEnum<{
633
+ forward: LabelDirection.Forward;
634
+ reverse: LabelDirection.Reverse;
635
+ }>;
636
+ format: z.ZodEnum<typeof TableChairNumberFormat>;
637
+ }, z.core.$strict>>;
594
638
  tableStyle: z.ZodObject<{
595
639
  visible: z.ZodBoolean;
596
640
  fontSizeM: z.ZodNumber;
@@ -831,6 +875,7 @@ export declare const groupSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
831
875
  }, z.core.$strict>], "kind">>;
832
876
  }, z.core.$strict>, z.ZodObject<{
833
877
  kind: z.ZodLiteral<SeatingKind.Round>;
878
+ surfaceColor: z.ZodOptional<z.ZodString>;
834
879
  selling: z.ZodOptional<z.ZodDiscriminatedUnion<[z.ZodObject<{
835
880
  mode: z.ZodEnum<{
836
881
  individual: TableBookingMode.Individual;
@@ -856,14 +901,15 @@ export declare const groupSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
856
901
  chairPitchM: z.ZodOptional<z.ZodNumber>;
857
902
  chairDistribution: z.ZodOptional<z.ZodEnum<typeof TableChairDistribution>>;
858
903
  }, z.core.$strict>;
859
- sides: z.ZodObject<{
904
+ sides: z.ZodOptional<z.ZodObject<{
860
905
  top: z.ZodBoolean;
861
906
  bottom: z.ZodBoolean;
862
907
  left: z.ZodBoolean;
863
908
  right: z.ZodBoolean;
864
- }, z.core.$strict>;
909
+ }, z.core.$strict>>;
865
910
  }, z.core.$strict>>;
866
911
  labels: z.ZodObject<{
912
+ buyerNoun: z.ZodOptional<z.ZodString>;
867
913
  chairs: z.ZodObject<{
868
914
  scheme: z.ZodEnum<typeof NumberingScheme>;
869
915
  startAt: z.ZodNumber;
@@ -876,6 +922,14 @@ export declare const groupSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
876
922
  }>>;
877
923
  lastAt: z.ZodOptional<z.ZodNumber>;
878
924
  }, z.core.$strict>;
925
+ chairNumbering: z.ZodOptional<z.ZodObject<{
926
+ startAt: z.ZodNumber;
927
+ direction: z.ZodEnum<{
928
+ forward: LabelDirection.Forward;
929
+ reverse: LabelDirection.Reverse;
930
+ }>;
931
+ format: z.ZodEnum<typeof TableChairNumberFormat>;
932
+ }, z.core.$strict>>;
879
933
  tableStyle: z.ZodObject<{
880
934
  visible: z.ZodBoolean;
881
935
  fontSizeM: z.ZodNumber;
@@ -995,6 +1049,11 @@ export declare const decorationStyleSchema: z.ZodObject<{
995
1049
  }, z.core.$strict>>;
996
1050
  strokeWidthM: z.ZodOptional<z.ZodNumber>;
997
1051
  }, z.core.$strict>;
1052
+ export declare const stageLabelStyleSchema: z.ZodObject<{
1053
+ color: z.ZodOptional<z.ZodString>;
1054
+ fontFamily: z.ZodOptional<z.ZodString>;
1055
+ underline: z.ZodOptional<z.ZodBoolean>;
1056
+ }, z.core.$strict>;
998
1057
  export declare const ticketOptionSchema: z.ZodObject<{
999
1058
  id: z.ZodString;
1000
1059
  name: z.ZodString;
@@ -1035,10 +1094,19 @@ export declare const categoriesSchema: z.ZodArray<z.ZodObject<{
1035
1094
  export declare const documentSchema: z.ZodObject<{
1036
1095
  buyerPhoto: z.ZodOptional<z.ZodObject<{
1037
1096
  assetId: z.ZodString;
1097
+ initialBearingDeg: z.ZodOptional<z.ZodNumber>;
1098
+ initialPitchDeg: z.ZodOptional<z.ZodNumber>;
1099
+ capturedAt: z.ZodOptional<z.ZodISODate>;
1100
+ sourceLabel: z.ZodOptional<z.ZodString>;
1101
+ sourceDimensions: z.ZodOptional<z.ZodObject<{
1102
+ width: z.ZodInt;
1103
+ height: z.ZodInt;
1104
+ }, z.core.$strict>>;
1038
1105
  }, z.core.$strict>>;
1039
1106
  schemaVersion: z.ZodLiteral<1>;
1040
1107
  mapId: z.ZodString;
1041
1108
  name: z.ZodString;
1109
+ venueName: z.ZodOptional<z.ZodString>;
1042
1110
  coordinateSystem: z.ZodObject<{
1043
1111
  unit: z.ZodLiteral<"metre">;
1044
1112
  xAxis: z.ZodLiteral<"right">;
@@ -1198,6 +1266,10 @@ export declare const documentSchema: z.ZodObject<{
1198
1266
  }, z.core.$strict>;
1199
1267
  sectionId: z.ZodNullable<z.ZodString>;
1200
1268
  sectionOrigin: z.ZodEnum<typeof ArcFanSectionOrigin>;
1269
+ sectionOutlineGridOriginM: z.ZodOptional<z.ZodObject<{
1270
+ x: z.ZodNumber;
1271
+ y: z.ZodNumber;
1272
+ }, z.core.$strict>>;
1201
1273
  members: z.ZodArray<z.ZodObject<{
1202
1274
  rowId: z.ZodString;
1203
1275
  bookingLabel: z.ZodString;
@@ -1435,6 +1507,10 @@ export declare const documentSchema: z.ZodObject<{
1435
1507
  }, z.core.$strict>;
1436
1508
  sectionId: z.ZodNullable<z.ZodString>;
1437
1509
  sectionOrigin: z.ZodEnum<typeof ArcFanSectionOrigin>;
1510
+ sectionOutlineGridOriginM: z.ZodOptional<z.ZodObject<{
1511
+ x: z.ZodNumber;
1512
+ y: z.ZodNumber;
1513
+ }, z.core.$strict>>;
1438
1514
  members: z.ZodArray<z.ZodObject<{
1439
1515
  rowId: z.ZodString;
1440
1516
  bookingLabel: z.ZodString;
@@ -1637,6 +1713,7 @@ export declare const documentSchema: z.ZodObject<{
1637
1713
  }, z.core.$strict>], "kind">>;
1638
1714
  }, z.core.$strict>, z.ZodObject<{
1639
1715
  kind: z.ZodLiteral<SeatingKind.Rectangular>;
1716
+ surfaceColor: z.ZodOptional<z.ZodString>;
1640
1717
  selling: z.ZodOptional<z.ZodDiscriminatedUnion<[z.ZodObject<{
1641
1718
  mode: z.ZodEnum<{
1642
1719
  individual: TableBookingMode.Individual;
@@ -1661,7 +1738,14 @@ export declare const documentSchema: z.ZodObject<{
1661
1738
  automaticSize: z.ZodOptional<z.ZodBoolean>;
1662
1739
  seatArcDeg: z.ZodOptional<z.ZodNumber>;
1663
1740
  }, z.core.$strict>>;
1741
+ conversionSides: z.ZodOptional<z.ZodObject<{
1742
+ top: z.ZodBoolean;
1743
+ bottom: z.ZodBoolean;
1744
+ left: z.ZodBoolean;
1745
+ right: z.ZodBoolean;
1746
+ }, z.core.$strict>>;
1664
1747
  labels: z.ZodObject<{
1748
+ buyerNoun: z.ZodOptional<z.ZodString>;
1665
1749
  chairs: z.ZodObject<{
1666
1750
  scheme: z.ZodEnum<typeof NumberingScheme>;
1667
1751
  startAt: z.ZodNumber;
@@ -1674,6 +1758,14 @@ export declare const documentSchema: z.ZodObject<{
1674
1758
  }>>;
1675
1759
  lastAt: z.ZodOptional<z.ZodNumber>;
1676
1760
  }, z.core.$strict>;
1761
+ chairNumbering: z.ZodOptional<z.ZodObject<{
1762
+ startAt: z.ZodNumber;
1763
+ direction: z.ZodEnum<{
1764
+ forward: LabelDirection.Forward;
1765
+ reverse: LabelDirection.Reverse;
1766
+ }>;
1767
+ format: z.ZodEnum<typeof TableChairNumberFormat>;
1768
+ }, z.core.$strict>>;
1677
1769
  tableStyle: z.ZodObject<{
1678
1770
  visible: z.ZodBoolean;
1679
1771
  fontSizeM: z.ZodNumber;
@@ -1914,6 +2006,7 @@ export declare const documentSchema: z.ZodObject<{
1914
2006
  }, z.core.$strict>], "kind">>;
1915
2007
  }, z.core.$strict>, z.ZodObject<{
1916
2008
  kind: z.ZodLiteral<SeatingKind.Round>;
2009
+ surfaceColor: z.ZodOptional<z.ZodString>;
1917
2010
  selling: z.ZodOptional<z.ZodDiscriminatedUnion<[z.ZodObject<{
1918
2011
  mode: z.ZodEnum<{
1919
2012
  individual: TableBookingMode.Individual;
@@ -1939,14 +2032,15 @@ export declare const documentSchema: z.ZodObject<{
1939
2032
  chairPitchM: z.ZodOptional<z.ZodNumber>;
1940
2033
  chairDistribution: z.ZodOptional<z.ZodEnum<typeof TableChairDistribution>>;
1941
2034
  }, z.core.$strict>;
1942
- sides: z.ZodObject<{
2035
+ sides: z.ZodOptional<z.ZodObject<{
1943
2036
  top: z.ZodBoolean;
1944
2037
  bottom: z.ZodBoolean;
1945
2038
  left: z.ZodBoolean;
1946
2039
  right: z.ZodBoolean;
1947
- }, z.core.$strict>;
2040
+ }, z.core.$strict>>;
1948
2041
  }, z.core.$strict>>;
1949
2042
  labels: z.ZodObject<{
2043
+ buyerNoun: z.ZodOptional<z.ZodString>;
1950
2044
  chairs: z.ZodObject<{
1951
2045
  scheme: z.ZodEnum<typeof NumberingScheme>;
1952
2046
  startAt: z.ZodNumber;
@@ -1959,6 +2053,14 @@ export declare const documentSchema: z.ZodObject<{
1959
2053
  }>>;
1960
2054
  lastAt: z.ZodOptional<z.ZodNumber>;
1961
2055
  }, z.core.$strict>;
2056
+ chairNumbering: z.ZodOptional<z.ZodObject<{
2057
+ startAt: z.ZodNumber;
2058
+ direction: z.ZodEnum<{
2059
+ forward: LabelDirection.Forward;
2060
+ reverse: LabelDirection.Reverse;
2061
+ }>;
2062
+ format: z.ZodEnum<typeof TableChairNumberFormat>;
2063
+ }, z.core.$strict>>;
1962
2064
  tableStyle: z.ZodObject<{
1963
2065
  visible: z.ZodBoolean;
1964
2066
  fontSizeM: z.ZodNumber;
@@ -2367,6 +2469,13 @@ export declare const documentSchema: z.ZodObject<{
2367
2469
  opens: z.ZodOptional<z.ZodString>;
2368
2470
  showToBuyers: z.ZodOptional<z.ZodBoolean>;
2369
2471
  }, z.core.$strict>>;
2472
+ stage: z.ZodOptional<z.ZodObject<{
2473
+ labelStyle: z.ZodOptional<z.ZodObject<{
2474
+ color: z.ZodOptional<z.ZodString>;
2475
+ fontFamily: z.ZodOptional<z.ZodString>;
2476
+ underline: z.ZodOptional<z.ZodBoolean>;
2477
+ }, z.core.$strict>>;
2478
+ }, z.core.$strict>>;
2370
2479
  boundary: z.ZodObject<{
2371
2480
  outer: z.ZodArray<z.ZodObject<{
2372
2481
  x: z.ZodNumber;
@@ -2441,6 +2550,29 @@ export declare const documentSchema: z.ZodObject<{
2441
2550
  zIndex: z.ZodNumber;
2442
2551
  }, z.core.$strict>, z.ZodObject<{
2443
2552
  kind: z.ZodLiteral<DecorationKind.Image>;
2553
+ referencePlan: z.ZodOptional<z.ZodLiteral<true>>;
2554
+ referenceSource: z.ZodOptional<z.ZodObject<{
2555
+ fileName: z.ZodString;
2556
+ page: z.ZodOptional<z.ZodInt>;
2557
+ }, z.core.$strict>>;
2558
+ referenceLayer: z.ZodOptional<z.ZodEnum<typeof ReferencePlanLayer>>;
2559
+ referenceCrop: z.ZodOptional<z.ZodObject<{
2560
+ left: z.ZodNumber;
2561
+ top: z.ZodNumber;
2562
+ width: z.ZodNumber;
2563
+ height: z.ZodNumber;
2564
+ }, z.core.$strict>>;
2565
+ referenceCalibration: z.ZodOptional<z.ZodObject<{
2566
+ firstPx: z.ZodObject<{
2567
+ x: z.ZodNumber;
2568
+ y: z.ZodNumber;
2569
+ }, z.core.$strict>;
2570
+ secondPx: z.ZodObject<{
2571
+ x: z.ZodNumber;
2572
+ y: z.ZodNumber;
2573
+ }, z.core.$strict>;
2574
+ distanceM: z.ZodNumber;
2575
+ }, z.core.$strict>>;
2444
2576
  assetId: z.ZodString;
2445
2577
  sizeM: z.ZodObject<{
2446
2578
  width: z.ZodNumber;
@@ -2761,6 +2893,13 @@ export declare const decorationSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
2761
2893
  opens: z.ZodOptional<z.ZodString>;
2762
2894
  showToBuyers: z.ZodOptional<z.ZodBoolean>;
2763
2895
  }, z.core.$strict>>;
2896
+ stage: z.ZodOptional<z.ZodObject<{
2897
+ labelStyle: z.ZodOptional<z.ZodObject<{
2898
+ color: z.ZodOptional<z.ZodString>;
2899
+ fontFamily: z.ZodOptional<z.ZodString>;
2900
+ underline: z.ZodOptional<z.ZodBoolean>;
2901
+ }, z.core.$strict>>;
2902
+ }, z.core.$strict>>;
2764
2903
  boundary: z.ZodObject<{
2765
2904
  outer: z.ZodArray<z.ZodObject<{
2766
2905
  x: z.ZodNumber;
@@ -2835,6 +2974,29 @@ export declare const decorationSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
2835
2974
  zIndex: z.ZodNumber;
2836
2975
  }, z.core.$strict>, z.ZodObject<{
2837
2976
  kind: z.ZodLiteral<DecorationKind.Image>;
2977
+ referencePlan: z.ZodOptional<z.ZodLiteral<true>>;
2978
+ referenceSource: z.ZodOptional<z.ZodObject<{
2979
+ fileName: z.ZodString;
2980
+ page: z.ZodOptional<z.ZodInt>;
2981
+ }, z.core.$strict>>;
2982
+ referenceLayer: z.ZodOptional<z.ZodEnum<typeof ReferencePlanLayer>>;
2983
+ referenceCrop: z.ZodOptional<z.ZodObject<{
2984
+ left: z.ZodNumber;
2985
+ top: z.ZodNumber;
2986
+ width: z.ZodNumber;
2987
+ height: z.ZodNumber;
2988
+ }, z.core.$strict>>;
2989
+ referenceCalibration: z.ZodOptional<z.ZodObject<{
2990
+ firstPx: z.ZodObject<{
2991
+ x: z.ZodNumber;
2992
+ y: z.ZodNumber;
2993
+ }, z.core.$strict>;
2994
+ secondPx: z.ZodObject<{
2995
+ x: z.ZodNumber;
2996
+ y: z.ZodNumber;
2997
+ }, z.core.$strict>;
2998
+ distanceM: z.ZodNumber;
2999
+ }, z.core.$strict>>;
2838
3000
  assetId: z.ZodString;
2839
3001
  sizeM: z.ZodObject<{
2840
3002
  width: z.ZodNumber;
@@ -3014,6 +3176,7 @@ export declare const labelSequenceSchema: z.ZodObject<{
3014
3176
  lastAt: z.ZodOptional<z.ZodNumber>;
3015
3177
  }, z.core.$strict>;
3016
3178
  export declare const inventoryLabelSchema: z.ZodString;
3179
+ export declare const authoredSectionDisplayLabelSchema: z.ZodString;
3017
3180
  export declare const attributesSchema: z.ZodOptional<z.ZodObject<{
3018
3181
  wheelchair: z.ZodOptional<z.ZodEnum<{
3019
3182
  seat: "seat";
@@ -3112,6 +3275,12 @@ export declare function validateSequences(group: SeatingGroup): z.ZodSafeParseRe
3112
3275
  color?: string | undefined;
3113
3276
  };
3114
3277
  code: string;
3278
+ buyerNoun?: string | undefined;
3279
+ chairNumbering?: {
3280
+ startAt: number;
3281
+ direction: LabelDirection.Forward | LabelDirection.Reverse;
3282
+ format: TableChairNumberFormat;
3283
+ } | undefined;
3115
3284
  name?: string | undefined;
3116
3285
  }>;
3117
3286
  export declare enum DocumentParseStatus {
package/dist/schema.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { ArcFanFacing, ArcFanFit, ArcFanMaximumRows, ArcFanMaximumPartsPerRow, ArcFanSectionOrigin, } from "./arc-fan.interface.js";
2
2
  import { EntranceKind, GateUse, LineCap, LineJoin, LineEnding } from "./wayfinding.interface.js";
3
3
  import { polygonContour, polygonContourVertexCount, PolygonVertexLimit, PolygonCornerRadiusMaxM, } from "./geometry/polygon-curves.js";
4
- import { DocumentLimits, TicketRestriction, TableBookingMode, TableChairDistribution, StandingBookingMode, SeatShape, TicketOptionLimit, NumberingScheme, LabelDirection, RowLabelPosition, AccessNeed, SeatingKind, CurveMode, DecorationKind, LabelAlignment, RowAlignment, RowStagger, RowEnds, RowJoin, SectionOutlineRole, RowRefitStrength, SectionRotation, SectionScale, SectionTier, SectionRake, SectionFrontRowHeight, AreaKind, ShapeKind, VenueGlyph, } from "./physical-document.interface.js";
4
+ import { DocumentLimits, TicketRestriction, TableBookingMode, TableChairDistribution, StandingBookingMode, SeatShape, TicketOptionLimit, NumberingScheme, LabelDirection, TableChairNumberFormat, RowLabelPosition, AccessNeed, SeatingKind, CurveMode, DecorationKind, ReferencePlanLayer, ReferencePlanPageLimit, LabelAlignment, RowAlignment, RowStagger, RowEnds, RowJoin, SectionOutlineRole, RowRefitStrength, SectionRotation, SectionScale, SectionTier, SectionRake, SectionFrontRowHeight, AreaKind, ShapeKind, VenueGlyph, VenuePhotoLimit, } from "./physical-document.interface.js";
5
5
  import { z } from "zod";
6
6
  import { tableSellingValid, standingSellingValid } from "./selling.js";
7
7
  import { ticketOptionNameKey } from "./categories.js";
@@ -120,6 +120,15 @@ const rowLabelStyle = labelStyle.extend({
120
120
  rotationDeg: angle.optional(),
121
121
  });
122
122
  export const buyerPhotoSchema = z.strictObject({ assetId: uuid });
123
+ export const venueBuyerPhotoSchema = buyerPhotoSchema.extend({
124
+ initialBearingDeg: finite.min(-VenuePhotoLimit.BearingDeg).max(VenuePhotoLimit.BearingDeg).optional(),
125
+ initialPitchDeg: finite.min(-VenuePhotoLimit.PitchDeg).max(VenuePhotoLimit.PitchDeg).optional(),
126
+ capturedAt: z.iso.date().optional(),
127
+ sourceLabel: text(VenuePhotoLimit.SourceLabel)
128
+ .refine((value) => value === value.trim(), "Use a trimmed source label.")
129
+ .optional(),
130
+ sourceDimensions: z.strictObject({ width: z.int().positive(), height: z.int().positive() }).optional(),
131
+ });
123
132
  export const seatPresentationSchema = z.strictObject({
124
133
  buyerPhoto: buyerPhotoSchema.optional(),
125
134
  gap: z.boolean().optional(),
@@ -260,9 +269,20 @@ export const segmentedRowSchema = z.strictObject({
260
269
  .max(DocumentLimits.PhysicalSeats),
261
270
  });
262
271
  const inventoryNaming = { code: label, name: label.optional() };
272
+ export const tableChairNumberingSchema = z.strictObject({
273
+ startAt: z.number().int().min(0).max(999),
274
+ direction: z.enum([LabelDirection.Forward, LabelDirection.Reverse]),
275
+ format: z.enum(TableChairNumberFormat),
276
+ });
277
+ export const tableBuyerNounSchema = z
278
+ .string()
279
+ .min(1)
280
+ .refine((value) => value === value.trim() && !unsupportedText.test(value), "Use trimmed text without unsupported characters.");
263
281
  const tableLabels = z.strictObject({
264
282
  ...inventoryNaming,
283
+ buyerNoun: tableBuyerNounSchema.optional(),
265
284
  chairs: sequence,
285
+ chairNumbering: tableChairNumberingSchema.optional(),
266
286
  tableStyle: labelStyle,
267
287
  });
268
288
  const roundTableRecipe = z.strictObject({
@@ -279,17 +299,18 @@ const rectangularTableRecipe = z.strictObject({
279
299
  chairPitchM: dimension.optional(),
280
300
  chairDistribution: z.enum(TableChairDistribution).optional(),
281
301
  });
282
- const longTableLayout = z
302
+ const tableChairSideSelection = z
283
303
  .strictObject({
284
- recipe: rectangularTableRecipe,
285
- sides: z.strictObject({
286
- top: z.boolean(),
287
- bottom: z.boolean(),
288
- left: z.boolean(),
289
- right: z.boolean(),
290
- }),
304
+ top: z.boolean(),
305
+ bottom: z.boolean(),
306
+ left: z.boolean(),
307
+ right: z.boolean(),
291
308
  })
292
- .refine((value) => Object.values(value.sides).some(Boolean), "Choose at least one table side.");
309
+ .refine((value) => Object.values(value).some(Boolean), "Choose at least one table side.");
310
+ const longTableLayout = z.strictObject({
311
+ recipe: rectangularTableRecipe,
312
+ sides: tableChairSideSelection.optional(),
313
+ });
293
314
  const arcFanRecipeSchema = z
294
315
  .strictObject({
295
316
  rowCount: finite.int().min(1).max(ArcFanMaximumRows),
@@ -310,6 +331,7 @@ const arcFanGenerationSchema = z.strictObject({
310
331
  recipe: arcFanRecipeSchema,
311
332
  sectionId: uuid.nullable(),
312
333
  sectionOrigin: z.enum(ArcFanSectionOrigin),
334
+ sectionOutlineGridOriginM: point.optional(),
313
335
  members: z
314
336
  .array(z.strictObject({ rowId: uuid, bookingLabel: storedLabelSchema, labelOverride: storedLabelSchema.optional() }))
315
337
  .min(1)
@@ -361,9 +383,11 @@ export const groupSchema = z.discriminatedUnion("kind", [
361
383
  .strictObject({
362
384
  ...groupBase,
363
385
  kind: z.literal(SeatingKind.Rectangular),
386
+ surfaceColor: hexColourSchema.optional(),
364
387
  selling: tableSelling.optional(),
365
388
  recipe: rectangularTableRecipe,
366
389
  roundLayout: roundTableRecipe.optional(),
390
+ conversionSides: tableChairSideSelection.optional(),
367
391
  labels: tableLabels,
368
392
  chairsBySide: z.strictObject({
369
393
  top: z.array(seat).max(DocumentLimits.PhysicalSeats),
@@ -378,6 +402,7 @@ export const groupSchema = z.discriminatedUnion("kind", [
378
402
  .strictObject({
379
403
  ...groupBase,
380
404
  kind: z.literal(SeatingKind.Round),
405
+ surfaceColor: hexColourSchema.optional(),
381
406
  selling: tableSelling.optional(),
382
407
  recipe: roundTableRecipe,
383
408
  longLayout: longTableLayout.optional(),
@@ -391,12 +416,36 @@ export const decorationStyleSchema = z.strictObject({
391
416
  stroke: paint.optional(),
392
417
  strokeWidthM: nonNegative.optional(),
393
418
  });
419
+ export const stageLabelStyleSchema = z.strictObject({
420
+ color: hexColourSchema.optional(),
421
+ fontFamily: storedLabelSchema.min(1).optional(),
422
+ underline: z.boolean().optional(),
423
+ });
394
424
  const decorationBase = {
395
425
  ...drawable,
396
426
  label: storedLabelSchema.optional(),
397
427
  heightM: nonNegative.optional(),
398
428
  style: decorationStyleSchema.optional(),
399
429
  };
430
+ const referenceSource = z.strictObject({
431
+ // 255 is the basename limit for common file systems. No path is stored.
432
+ fileName: z.string().min(1).max(255),
433
+ page: z.int().min(1).max(ReferencePlanPageLimit).optional(),
434
+ });
435
+ const imageFraction = finite.min(0).max(1);
436
+ const positiveImageFraction = imageFraction.positive();
437
+ const referenceCrop = z
438
+ .strictObject({
439
+ left: imageFraction,
440
+ top: imageFraction,
441
+ width: positiveImageFraction,
442
+ height: positiveImageFraction,
443
+ })
444
+ .refine(({ left, top, width, height }) => left + width <= 1 + Number.EPSILON && top + height <= 1 + Number.EPSILON, "Crop must fit inside the image.");
445
+ const imagePixel = z.strictObject({ x: finite.nonnegative(), y: finite.nonnegative() });
446
+ const referenceCalibration = z
447
+ .strictObject({ firstPx: imagePixel, secondPx: imagePixel, distanceM: finite.positive() })
448
+ .refine(({ firstPx, secondPx }) => firstPx.x !== secondPx.x || firstPx.y !== secondPx.y, "Mark two distinct points.");
400
449
  const decoration = z.discriminatedUnion("kind", [
401
450
  z.strictObject({
402
451
  ...decorationBase,
@@ -429,25 +478,36 @@ const decoration = z.discriminatedUnion("kind", [
429
478
  endEnding: z.enum(LineEnding).optional(),
430
479
  pointsM: z.array(point).min(2).max(10000),
431
480
  }),
432
- z.strictObject({
481
+ z
482
+ .strictObject({
433
483
  ...decorationBase,
434
484
  kind: z.literal(DecorationKind.Polygon),
435
485
  gate: gateDetails.optional(),
486
+ stage: z.strictObject({ labelStyle: stageLabelStyleSchema.optional() }).optional(),
436
487
  boundary: polygon,
437
- }),
488
+ })
489
+ .refine((value) => !value.gate || !value.stage, "A stage cannot also be a gate."),
438
490
  z.strictObject({
439
491
  ...decorationBase,
440
492
  kind: z.literal(DecorationKind.Icon),
441
493
  iconId: z.enum(VenueGlyph),
442
494
  sizeM: size,
443
495
  }),
444
- z.strictObject({
496
+ z
497
+ .strictObject({
445
498
  ...decorationBase,
446
499
  kind: z.literal(DecorationKind.Image),
500
+ referencePlan: z.literal(true).optional(),
501
+ referenceSource: referenceSource.optional(),
502
+ referenceLayer: z.enum(ReferencePlanLayer).optional(),
503
+ referenceCrop: referenceCrop.optional(),
504
+ referenceCalibration: referenceCalibration.optional(),
447
505
  assetId: uuid,
448
506
  sizeM: size,
449
507
  opacity: finite.min(0).max(1),
450
- }),
508
+ })
509
+ .refine((image) => image.referencePlan ||
510
+ (!image.referenceSource && !image.referenceLayer && !image.referenceCrop && !image.referenceCalibration), "Plan settings require a private reference image."),
451
511
  ]);
452
512
  const areaBase = {
453
513
  entrance: entranceSchema.optional(),
@@ -528,10 +588,11 @@ export const categoriesSchema = z
528
588
  }
529
589
  });
530
590
  export const documentSchema = z.strictObject({
531
- buyerPhoto: buyerPhotoSchema.optional(),
591
+ buyerPhoto: venueBuyerPhotoSchema.optional(),
532
592
  schemaVersion: z.literal(1),
533
593
  mapId: uuid,
534
594
  name,
595
+ venueName: name.optional(),
535
596
  coordinateSystem: z.strictObject({
536
597
  unit: z.literal("metre"),
537
598
  xAxis: z.literal("right"),
@@ -568,7 +629,11 @@ export const documentSchema = z.strictObject({
568
629
  .describe("Authored section slope and front-row elevation relative to its floor.")
569
630
  .optional(),
570
631
  categoryId: uuid.nullable().optional(),
571
- displayLabel: text(80, true).optional(),
632
+ displayLabel: z
633
+ .string()
634
+ .refine((value) => !unsupportedText.test(value.replace(/\n/g, "")), "Use text without unsupported characters.")
635
+ .describe("Stored section display name. LF is permitted and generated copy names retain their full text.")
636
+ .optional(),
572
637
  outline: polygon.optional(),
573
638
  outlineRole: z.enum(SectionOutlineRole).optional(),
574
639
  rotationDeg: z.number().int().min(SectionRotation.min).max(SectionRotation.max).optional(),
@@ -622,6 +687,7 @@ export const rotationSchema = angle;
622
687
  export const positiveCountSchema = finite.int().min(1).max(DocumentLimits.PhysicalSeats);
623
688
  export const labelSequenceSchema = sequence;
624
689
  export const inventoryLabelSchema = label;
690
+ export const authoredSectionDisplayLabelSchema = text(80, true);
625
691
  export const attributesSchema = seat.shape.attributes;
626
692
  export const seatOverrideSchema = seat.shape.override;
627
693
  export function validateRecipe(group) {
@@ -3,9 +3,9 @@ import type { ExpandedInventorySection } from "./section-growth.interface.js";
3
3
  import { type PhysicalDocumentV1, type UUID } from "./physical-document.interface.js";
4
4
  export declare const sectionInventoryGrowthInputSchema: z.ZodObject<{
5
5
  inventory: z.ZodArray<z.ZodString>;
6
- createdInSection: z.ZodNullable<z.ZodString>;
6
+ workspaceSectionId: z.ZodNullable<z.ZodString>;
7
7
  }, z.core.$strict>;
8
- /** Expand boundaries atomically for moved/resized inventory and rows drawn in the active section. */
9
- export declare function expandedInventorySections(before: PhysicalDocumentV1, after: PhysicalDocumentV1, changed: ReadonlySet<UUID>, createdInSection: UUID | null): ReadonlyMap<UUID, ExpandedInventorySection> | null;
8
+ /** Grow the entered workspace for its edited inventory, or the primary boundary for chart-wide edits. */
9
+ export declare function expandedInventorySections(before: PhysicalDocumentV1, after: PhysicalDocumentV1, changed: ReadonlySet<UUID>, workspaceSectionId: UUID | null): ReadonlyMap<UUID, ExpandedInventorySection> | null;
10
10
  /** Apply only computed outlines; every other locked section property stays with its source. */
11
11
  export declare function projectInventorySectionGrowth(document: PhysicalDocumentV1, grown: ReadonlyMap<UUID, ExpandedInventorySection>): PhysicalDocumentV1;
@@ -1,11 +1,19 @@
1
1
  import type { z } from "zod";
2
2
  import type { sectionInventoryGrowthInputSchema } from "./section-growth.js";
3
- import type { Bounds } from "./geometry/geometry.js";
3
+ import type { Bounds, Matrix } from "./geometry/geometry.js";
4
4
  import type { UUID, Section, PolygonM } from "./physical-document.interface.js";
5
- export interface InventoryLayout {
5
+ export interface InventoryFootprint {
6
6
  bounds: Bounds;
7
+ rowMarkers?: Matrix[];
8
+ }
9
+ export interface InventoryLayout extends InventoryFootprint {
7
10
  floorId: UUID | null;
8
11
  }
12
+ export interface InventoryGrowthRequest {
13
+ bounds: Bounds;
14
+ rowMarkers: Matrix[];
15
+ otherBounds?: Bounds;
16
+ }
9
17
  export type SectionInventoryGrowthInput = z.infer<typeof sectionInventoryGrowthInputSchema>;
10
18
  export interface ExpandedInventorySection extends Section {
11
19
  outline: PolygonM;