@seatlayer/core 0.46.0 → 0.47.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/dist/chunk-AZODENEL.js +97 -0
- package/dist/chunk-AZODENEL.js.map +1 -0
- package/dist/chunk-FVCOOLJO.js +335 -0
- package/dist/chunk-FVCOOLJO.js.map +1 -0
- package/dist/{chunk-5MRJCIZP.js → chunk-TCTAS4Z2.js} +88 -14
- package/dist/chunk-TCTAS4Z2.js.map +1 -0
- package/dist/{de-UHAOVDS3.js → de-ST4H423D.js} +6 -3
- package/dist/{de-UHAOVDS3.js.map → de-ST4H423D.js.map} +1 -1
- package/dist/{es-6TJS2L7S.js → es-WEC5NHRT.js} +6 -3
- package/dist/{es-6TJS2L7S.js.map → es-WEC5NHRT.js.map} +1 -1
- package/dist/{fr-MMSY7FPE.js → fr-SGBFNAQV.js} +6 -3
- package/dist/{fr-MMSY7FPE.js.map → fr-SGBFNAQV.js.map} +1 -1
- package/dist/index.cjs +251 -39
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +119 -4
- package/dist/index.d.ts +119 -4
- package/dist/index.js +152 -24
- package/dist/index.js.map +1 -1
- package/dist/{types-DBnRO2hX.d.cts → types-CE63BK0j.d.cts} +88 -10
- package/dist/{types-DBnRO2hX.d.ts → types-CE63BK0j.d.ts} +88 -10
- package/dist/view/panoramaDelivery.cjs +126 -0
- package/dist/view/panoramaDelivery.cjs.map +1 -0
- package/dist/view/panoramaDelivery.d.cts +34 -0
- package/dist/view/panoramaDelivery.d.ts +34 -0
- package/dist/view/panoramaDelivery.js +17 -0
- package/dist/view/panoramaDelivery.js.map +1 -0
- package/dist/view3d/crossfade/panorama.cjs +453 -0
- package/dist/view3d/crossfade/panorama.cjs.map +1 -0
- package/dist/view3d/crossfade/panorama.d.cts +110 -0
- package/dist/view3d/crossfade/panorama.d.ts +110 -0
- package/dist/view3d/crossfade/panorama.js +30 -0
- package/dist/view3d/crossfade/panorama.js.map +1 -0
- package/dist/view3d/index.cjs +1176 -128
- package/dist/view3d/index.cjs.map +1 -1
- package/dist/view3d/index.d.cts +73 -35
- package/dist/view3d/index.d.ts +73 -35
- package/dist/view3d/index.js +960 -300
- package/dist/view3d/index.js.map +1 -1
- package/package.json +28 -1
- package/dist/chunk-5MRJCIZP.js.map +0 -1
package/dist/view3d/index.d.cts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { C as ChartDoc, E as ExpandedSeat } from '../types-
|
|
1
|
+
import { C as ChartDoc, E as ExpandedSeat } from '../types-CE63BK0j.cjs';
|
|
2
|
+
import { SeatView } from './crossfade/panorama.cjs';
|
|
2
3
|
|
|
3
4
|
/**
|
|
4
5
|
* Dirty-flag render loop. A frame is drawn only while the camera is moving /
|
|
@@ -234,6 +235,8 @@ interface SeatInstanceData {
|
|
|
234
235
|
* Real seats very nearly touch. See `chairHalfWidth`.
|
|
235
236
|
*/
|
|
236
237
|
iChairWidth: Float32Array;
|
|
238
|
+
/** 1 = physical chair; 0 = sellable empty wheelchair bay. */
|
|
239
|
+
iPhysicalSeat: Float32Array;
|
|
237
240
|
/** seatId → instance index (drives targeted availability updates). */
|
|
238
241
|
idToIndex: Map<string, number>;
|
|
239
242
|
}
|
|
@@ -288,6 +291,15 @@ interface SceneSection {
|
|
|
288
291
|
/** What this section faces — the camera approaches from this side. */
|
|
289
292
|
focalWorld: [number, number, number];
|
|
290
293
|
}
|
|
294
|
+
/** One authored row resolved for guided large-venue navigation. */
|
|
295
|
+
interface SceneRow {
|
|
296
|
+
id: string;
|
|
297
|
+
label: string;
|
|
298
|
+
sectionId?: string;
|
|
299
|
+
seatCount: number;
|
|
300
|
+
center: [number, number, number];
|
|
301
|
+
radius: number;
|
|
302
|
+
}
|
|
291
303
|
/** A navigable floor — a logical level of the venue. */
|
|
292
304
|
interface SceneFloor {
|
|
293
305
|
index: number;
|
|
@@ -329,6 +341,8 @@ interface SceneModel {
|
|
|
329
341
|
stages: StageBounds[];
|
|
330
342
|
/** Seated sections, in authored order — the navigable middle rung. */
|
|
331
343
|
sections: SceneSection[];
|
|
344
|
+
/** Rows used by the Section → Row → Seat locator. */
|
|
345
|
+
rows: SceneRow[];
|
|
332
346
|
/**
|
|
333
347
|
* The venue's floors, in authored order. A single-floor chart reports one.
|
|
334
348
|
*
|
|
@@ -348,44 +362,13 @@ interface SceneModel {
|
|
|
348
362
|
interface SceneModelInput {
|
|
349
363
|
doc: ChartDoc;
|
|
350
364
|
seats: ExpandedSeat[];
|
|
365
|
+
/** Overrides the chart's active layout without mutating its authored data. */
|
|
366
|
+
eventConfigurationId?: string;
|
|
351
367
|
/** Optional initial per-seat state (default all available). */
|
|
352
368
|
initialState?: (seat: ExpandedSeat) => SeatState3D;
|
|
353
369
|
}
|
|
354
370
|
declare function buildSceneModel(input: SceneModelInput): SceneModel;
|
|
355
371
|
|
|
356
|
-
/**
|
|
357
|
-
* Slice 3 hand-off — the DOM panorama overlay the fly-to-seat cinematic
|
|
358
|
-
* dissolves into. Decoupled by design: the CALLER supplies the equirectangular
|
|
359
|
-
* image (via mountVenue3D's getSeatView), so view3d never imports the app's
|
|
360
|
-
* panorama generator and the chunk stays lean.
|
|
361
|
-
*
|
|
362
|
-
* Technique (mirrors SeatPicker.openSeatView, reimplemented small): an equirect
|
|
363
|
-
* image panned with `repeat-x`; the initial horizontal offset is set so the
|
|
364
|
-
* panorama's bearing matches the final camera yaw — the dissolve reads as the
|
|
365
|
-
* same view sharpening, not a cut. CSS opacity fade is compositor-only.
|
|
366
|
-
*/
|
|
367
|
-
interface SeatView {
|
|
368
|
-
url: string;
|
|
369
|
-
/**
|
|
370
|
-
* True when `url` is a SYNTHESISED panorama rather than a real photograph.
|
|
371
|
-
*
|
|
372
|
-
* It decides which of two very different things the buyer gets, so the caller
|
|
373
|
-
* must say rather than the renderer guess. A generated equirect is a picture
|
|
374
|
-
* of a 3D scene the renderer already has: at 2048×1024 it covers 106° of
|
|
375
|
-
* horizontal view in ~600 source pixels, which a 3072-device-pixel viewport
|
|
376
|
-
* magnifies FIVE times, and no amount of art survives that. So a generated
|
|
377
|
-
* view is not drawn as an image at all — the camera simply looks around the
|
|
378
|
-
* real scene, which has no resolution ceiling.
|
|
379
|
-
*
|
|
380
|
-
* A real photo has no such substitute and goes on the sphere, where a 5760 or
|
|
381
|
-
* 8192-wide capture has three to four times the detail to give.
|
|
382
|
-
*/
|
|
383
|
-
generated?: boolean;
|
|
384
|
-
/** Bearing (deg, 0 = facing the focal/stage) the panorama should open centred
|
|
385
|
-
* on, to match the camera's final yaw. Default 0 (both face the stage). */
|
|
386
|
-
initialBearingDeg?: number;
|
|
387
|
-
}
|
|
388
|
-
|
|
389
372
|
/**
|
|
390
373
|
* view3d analytics — a tiny, decoupled event emitter for the venue view. The
|
|
391
374
|
* caller (app/harness) supplies `onAnalytics`; this class owns the per-mount
|
|
@@ -394,6 +377,36 @@ interface SeatView {
|
|
|
394
377
|
* rendering. No DOM, no GL — unit-testable in isolation.
|
|
395
378
|
*/
|
|
396
379
|
type Analytics3DCallback = (event: string, props?: Record<string, unknown>) => void;
|
|
380
|
+
/**
|
|
381
|
+
* Where the CPU scene was compiled, as a closed enum (never free text).
|
|
382
|
+
* - `worker` — built off the UI thread by `prepareVenue3D`.
|
|
383
|
+
* - `main` — `prepareVenue3D` ran but the worker was unavailable or failed
|
|
384
|
+
* (no `Worker`, a host CSP blocking the module worker, a throw, or
|
|
385
|
+
* the 15s timeout) and the same pure compiler ran on the UI thread.
|
|
386
|
+
* - `inline` — the caller never used `prepareVenue3D`; the scene was compiled
|
|
387
|
+
* synchronously inside `mountVenue3D`. Kept distinct from `main`
|
|
388
|
+
* so worker uptake is not diluted by callers that never asked.
|
|
389
|
+
*/
|
|
390
|
+
type Scene3DPrepSource = 'worker' | 'main' | 'inline';
|
|
391
|
+
|
|
392
|
+
interface PreparedVenue3D {
|
|
393
|
+
model: SceneModel;
|
|
394
|
+
buildMs: number;
|
|
395
|
+
/** Reported on `3d_opened` as `prepSource`. `inline` is not reachable here —
|
|
396
|
+
* it is what `mountVenue3D` reports when no prepared scene was handed in. */
|
|
397
|
+
source: Exclude<Scene3DPrepSource, 'inline'>;
|
|
398
|
+
}
|
|
399
|
+
interface PrepareVenue3DInput {
|
|
400
|
+
doc: ChartDoc;
|
|
401
|
+
seats: ExpandedSeat[];
|
|
402
|
+
eventConfigurationId?: string;
|
|
403
|
+
}
|
|
404
|
+
/**
|
|
405
|
+
* Build the CPU-heavy merged mesh and seat buffers off the UI thread. Worker
|
|
406
|
+
* failure is non-fatal: old browsers and restrictive hosts fall back to the
|
|
407
|
+
* exact same pure compiler on the main thread.
|
|
408
|
+
*/
|
|
409
|
+
declare function prepareVenue3D(input: PrepareVenue3DInput): Promise<PreparedVenue3D>;
|
|
397
410
|
|
|
398
411
|
/**
|
|
399
412
|
* view3d — the sole dynamic-import boundary for the lazy OGL venue-view chunk.
|
|
@@ -414,10 +427,17 @@ interface Venue3DInput {
|
|
|
414
427
|
seats: ExpandedSeat[];
|
|
415
428
|
/** Optional initial per-seat state (default all available). */
|
|
416
429
|
initialState?: (seat: ExpandedSeat) => SeatState3D;
|
|
430
|
+
/** CPU scene prepared by `prepareVenue3D`; avoids rebuilding on mount. */
|
|
431
|
+
prepared?: PreparedVenue3D;
|
|
417
432
|
}
|
|
418
433
|
interface Venue3DOptions {
|
|
419
434
|
/** Fired on a tap that hits a seat (GPU color-pick). Not fired on empty taps. */
|
|
420
435
|
onSeatPick?: (seatId: string) => void;
|
|
436
|
+
/** Overview → section drill state. A stand tap reports its owning section;
|
|
437
|
+
* Overview reports null so host navigation can stay in sync. */
|
|
438
|
+
onSectionFocusChange?: (sectionId: string | null) => void;
|
|
439
|
+
/** Camera target changes, including internal next/previous and Overview UI. */
|
|
440
|
+
onViewTargetChange?: (seatId: string | null) => void;
|
|
421
441
|
/**
|
|
422
442
|
* Supplies the view-from-seat panorama for the cinematic hand-off. Decoupled:
|
|
423
443
|
* the caller (app/harness) owns panorama generation; view3d never imports it.
|
|
@@ -432,6 +452,13 @@ interface Venue3DOptions {
|
|
|
432
452
|
* rendering. Absent = no events emitted.
|
|
433
453
|
*/
|
|
434
454
|
onAnalytics?: Analytics3DCallback;
|
|
455
|
+
/**
|
|
456
|
+
* Let portrait overview framing crop the venue's far edges within a bounded
|
|
457
|
+
* landscape fit so seats stay discoverable instead of shrinking the whole
|
|
458
|
+
* bowl to fit. Opt-in because designer/editor previews still prefer strict
|
|
459
|
+
* contain framing; validated for the buyer across `/dev/3d` fixtures.
|
|
460
|
+
*/
|
|
461
|
+
portraitOverviewCrop?: boolean;
|
|
435
462
|
}
|
|
436
463
|
interface Venue3DStats extends RenderLoopStats {
|
|
437
464
|
drawCalls: number;
|
|
@@ -448,6 +475,8 @@ interface Venue3DHandle {
|
|
|
448
475
|
* view-from-seat panorama. Resolves at flight end; a drag cancels it, a second
|
|
449
476
|
* call retargets, dispose resolves early. Reduced-motion → a short fade. */
|
|
450
477
|
flyToSeat(seatId: string): Promise<void>;
|
|
478
|
+
/** Cancel a seat flight/panorama and frame the complete venue. */
|
|
479
|
+
focusOverview(): void;
|
|
451
480
|
resize(): void;
|
|
452
481
|
stats(): Venue3DStats;
|
|
453
482
|
loseContextForTest(): void;
|
|
@@ -474,6 +503,15 @@ interface Venue3DHandle {
|
|
|
474
503
|
* been answered. Returns false for an unknown or empty section.
|
|
475
504
|
*/
|
|
476
505
|
focusSection(sectionId: string): boolean;
|
|
506
|
+
/** Rows in the venue, optionally narrowed to a section. */
|
|
507
|
+
rows(sectionId?: string): SceneRow[];
|
|
508
|
+
/** Seats in one row, in authored order. */
|
|
509
|
+
seatsInRow(rowId: string): Array<{
|
|
510
|
+
id: string;
|
|
511
|
+
label: string;
|
|
512
|
+
}>;
|
|
513
|
+
/** Frame a row closely enough for its on-demand seat numbers to be legible. */
|
|
514
|
+
focusRow(rowId: string): boolean;
|
|
477
515
|
/** The venue's floors (id, name, seat count) in authored order. */
|
|
478
516
|
floors(): SceneFloor[];
|
|
479
517
|
/**
|
|
@@ -489,4 +527,4 @@ interface Venue3DHandle {
|
|
|
489
527
|
}
|
|
490
528
|
declare function mountVenue3D(container: HTMLElement, input: Venue3DInput, opts?: Venue3DOptions): Venue3DHandle;
|
|
491
529
|
|
|
492
|
-
export { type Analytics3DCallback, type
|
|
530
|
+
export { type Analytics3DCallback, type Scene3DPrepSource, type SeatState3D, SeatView, type Venue3DHandle, type Venue3DInput, type Venue3DOptions, type Venue3DStats, buildSceneModel, mountVenue3D, prepareVenue3D };
|
package/dist/view3d/index.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { C as ChartDoc, E as ExpandedSeat } from '../types-
|
|
1
|
+
import { C as ChartDoc, E as ExpandedSeat } from '../types-CE63BK0j.js';
|
|
2
|
+
import { SeatView } from './crossfade/panorama.js';
|
|
2
3
|
|
|
3
4
|
/**
|
|
4
5
|
* Dirty-flag render loop. A frame is drawn only while the camera is moving /
|
|
@@ -234,6 +235,8 @@ interface SeatInstanceData {
|
|
|
234
235
|
* Real seats very nearly touch. See `chairHalfWidth`.
|
|
235
236
|
*/
|
|
236
237
|
iChairWidth: Float32Array;
|
|
238
|
+
/** 1 = physical chair; 0 = sellable empty wheelchair bay. */
|
|
239
|
+
iPhysicalSeat: Float32Array;
|
|
237
240
|
/** seatId → instance index (drives targeted availability updates). */
|
|
238
241
|
idToIndex: Map<string, number>;
|
|
239
242
|
}
|
|
@@ -288,6 +291,15 @@ interface SceneSection {
|
|
|
288
291
|
/** What this section faces — the camera approaches from this side. */
|
|
289
292
|
focalWorld: [number, number, number];
|
|
290
293
|
}
|
|
294
|
+
/** One authored row resolved for guided large-venue navigation. */
|
|
295
|
+
interface SceneRow {
|
|
296
|
+
id: string;
|
|
297
|
+
label: string;
|
|
298
|
+
sectionId?: string;
|
|
299
|
+
seatCount: number;
|
|
300
|
+
center: [number, number, number];
|
|
301
|
+
radius: number;
|
|
302
|
+
}
|
|
291
303
|
/** A navigable floor — a logical level of the venue. */
|
|
292
304
|
interface SceneFloor {
|
|
293
305
|
index: number;
|
|
@@ -329,6 +341,8 @@ interface SceneModel {
|
|
|
329
341
|
stages: StageBounds[];
|
|
330
342
|
/** Seated sections, in authored order — the navigable middle rung. */
|
|
331
343
|
sections: SceneSection[];
|
|
344
|
+
/** Rows used by the Section → Row → Seat locator. */
|
|
345
|
+
rows: SceneRow[];
|
|
332
346
|
/**
|
|
333
347
|
* The venue's floors, in authored order. A single-floor chart reports one.
|
|
334
348
|
*
|
|
@@ -348,44 +362,13 @@ interface SceneModel {
|
|
|
348
362
|
interface SceneModelInput {
|
|
349
363
|
doc: ChartDoc;
|
|
350
364
|
seats: ExpandedSeat[];
|
|
365
|
+
/** Overrides the chart's active layout without mutating its authored data. */
|
|
366
|
+
eventConfigurationId?: string;
|
|
351
367
|
/** Optional initial per-seat state (default all available). */
|
|
352
368
|
initialState?: (seat: ExpandedSeat) => SeatState3D;
|
|
353
369
|
}
|
|
354
370
|
declare function buildSceneModel(input: SceneModelInput): SceneModel;
|
|
355
371
|
|
|
356
|
-
/**
|
|
357
|
-
* Slice 3 hand-off — the DOM panorama overlay the fly-to-seat cinematic
|
|
358
|
-
* dissolves into. Decoupled by design: the CALLER supplies the equirectangular
|
|
359
|
-
* image (via mountVenue3D's getSeatView), so view3d never imports the app's
|
|
360
|
-
* panorama generator and the chunk stays lean.
|
|
361
|
-
*
|
|
362
|
-
* Technique (mirrors SeatPicker.openSeatView, reimplemented small): an equirect
|
|
363
|
-
* image panned with `repeat-x`; the initial horizontal offset is set so the
|
|
364
|
-
* panorama's bearing matches the final camera yaw — the dissolve reads as the
|
|
365
|
-
* same view sharpening, not a cut. CSS opacity fade is compositor-only.
|
|
366
|
-
*/
|
|
367
|
-
interface SeatView {
|
|
368
|
-
url: string;
|
|
369
|
-
/**
|
|
370
|
-
* True when `url` is a SYNTHESISED panorama rather than a real photograph.
|
|
371
|
-
*
|
|
372
|
-
* It decides which of two very different things the buyer gets, so the caller
|
|
373
|
-
* must say rather than the renderer guess. A generated equirect is a picture
|
|
374
|
-
* of a 3D scene the renderer already has: at 2048×1024 it covers 106° of
|
|
375
|
-
* horizontal view in ~600 source pixels, which a 3072-device-pixel viewport
|
|
376
|
-
* magnifies FIVE times, and no amount of art survives that. So a generated
|
|
377
|
-
* view is not drawn as an image at all — the camera simply looks around the
|
|
378
|
-
* real scene, which has no resolution ceiling.
|
|
379
|
-
*
|
|
380
|
-
* A real photo has no such substitute and goes on the sphere, where a 5760 or
|
|
381
|
-
* 8192-wide capture has three to four times the detail to give.
|
|
382
|
-
*/
|
|
383
|
-
generated?: boolean;
|
|
384
|
-
/** Bearing (deg, 0 = facing the focal/stage) the panorama should open centred
|
|
385
|
-
* on, to match the camera's final yaw. Default 0 (both face the stage). */
|
|
386
|
-
initialBearingDeg?: number;
|
|
387
|
-
}
|
|
388
|
-
|
|
389
372
|
/**
|
|
390
373
|
* view3d analytics — a tiny, decoupled event emitter for the venue view. The
|
|
391
374
|
* caller (app/harness) supplies `onAnalytics`; this class owns the per-mount
|
|
@@ -394,6 +377,36 @@ interface SeatView {
|
|
|
394
377
|
* rendering. No DOM, no GL — unit-testable in isolation.
|
|
395
378
|
*/
|
|
396
379
|
type Analytics3DCallback = (event: string, props?: Record<string, unknown>) => void;
|
|
380
|
+
/**
|
|
381
|
+
* Where the CPU scene was compiled, as a closed enum (never free text).
|
|
382
|
+
* - `worker` — built off the UI thread by `prepareVenue3D`.
|
|
383
|
+
* - `main` — `prepareVenue3D` ran but the worker was unavailable or failed
|
|
384
|
+
* (no `Worker`, a host CSP blocking the module worker, a throw, or
|
|
385
|
+
* the 15s timeout) and the same pure compiler ran on the UI thread.
|
|
386
|
+
* - `inline` — the caller never used `prepareVenue3D`; the scene was compiled
|
|
387
|
+
* synchronously inside `mountVenue3D`. Kept distinct from `main`
|
|
388
|
+
* so worker uptake is not diluted by callers that never asked.
|
|
389
|
+
*/
|
|
390
|
+
type Scene3DPrepSource = 'worker' | 'main' | 'inline';
|
|
391
|
+
|
|
392
|
+
interface PreparedVenue3D {
|
|
393
|
+
model: SceneModel;
|
|
394
|
+
buildMs: number;
|
|
395
|
+
/** Reported on `3d_opened` as `prepSource`. `inline` is not reachable here —
|
|
396
|
+
* it is what `mountVenue3D` reports when no prepared scene was handed in. */
|
|
397
|
+
source: Exclude<Scene3DPrepSource, 'inline'>;
|
|
398
|
+
}
|
|
399
|
+
interface PrepareVenue3DInput {
|
|
400
|
+
doc: ChartDoc;
|
|
401
|
+
seats: ExpandedSeat[];
|
|
402
|
+
eventConfigurationId?: string;
|
|
403
|
+
}
|
|
404
|
+
/**
|
|
405
|
+
* Build the CPU-heavy merged mesh and seat buffers off the UI thread. Worker
|
|
406
|
+
* failure is non-fatal: old browsers and restrictive hosts fall back to the
|
|
407
|
+
* exact same pure compiler on the main thread.
|
|
408
|
+
*/
|
|
409
|
+
declare function prepareVenue3D(input: PrepareVenue3DInput): Promise<PreparedVenue3D>;
|
|
397
410
|
|
|
398
411
|
/**
|
|
399
412
|
* view3d — the sole dynamic-import boundary for the lazy OGL venue-view chunk.
|
|
@@ -414,10 +427,17 @@ interface Venue3DInput {
|
|
|
414
427
|
seats: ExpandedSeat[];
|
|
415
428
|
/** Optional initial per-seat state (default all available). */
|
|
416
429
|
initialState?: (seat: ExpandedSeat) => SeatState3D;
|
|
430
|
+
/** CPU scene prepared by `prepareVenue3D`; avoids rebuilding on mount. */
|
|
431
|
+
prepared?: PreparedVenue3D;
|
|
417
432
|
}
|
|
418
433
|
interface Venue3DOptions {
|
|
419
434
|
/** Fired on a tap that hits a seat (GPU color-pick). Not fired on empty taps. */
|
|
420
435
|
onSeatPick?: (seatId: string) => void;
|
|
436
|
+
/** Overview → section drill state. A stand tap reports its owning section;
|
|
437
|
+
* Overview reports null so host navigation can stay in sync. */
|
|
438
|
+
onSectionFocusChange?: (sectionId: string | null) => void;
|
|
439
|
+
/** Camera target changes, including internal next/previous and Overview UI. */
|
|
440
|
+
onViewTargetChange?: (seatId: string | null) => void;
|
|
421
441
|
/**
|
|
422
442
|
* Supplies the view-from-seat panorama for the cinematic hand-off. Decoupled:
|
|
423
443
|
* the caller (app/harness) owns panorama generation; view3d never imports it.
|
|
@@ -432,6 +452,13 @@ interface Venue3DOptions {
|
|
|
432
452
|
* rendering. Absent = no events emitted.
|
|
433
453
|
*/
|
|
434
454
|
onAnalytics?: Analytics3DCallback;
|
|
455
|
+
/**
|
|
456
|
+
* Let portrait overview framing crop the venue's far edges within a bounded
|
|
457
|
+
* landscape fit so seats stay discoverable instead of shrinking the whole
|
|
458
|
+
* bowl to fit. Opt-in because designer/editor previews still prefer strict
|
|
459
|
+
* contain framing; validated for the buyer across `/dev/3d` fixtures.
|
|
460
|
+
*/
|
|
461
|
+
portraitOverviewCrop?: boolean;
|
|
435
462
|
}
|
|
436
463
|
interface Venue3DStats extends RenderLoopStats {
|
|
437
464
|
drawCalls: number;
|
|
@@ -448,6 +475,8 @@ interface Venue3DHandle {
|
|
|
448
475
|
* view-from-seat panorama. Resolves at flight end; a drag cancels it, a second
|
|
449
476
|
* call retargets, dispose resolves early. Reduced-motion → a short fade. */
|
|
450
477
|
flyToSeat(seatId: string): Promise<void>;
|
|
478
|
+
/** Cancel a seat flight/panorama and frame the complete venue. */
|
|
479
|
+
focusOverview(): void;
|
|
451
480
|
resize(): void;
|
|
452
481
|
stats(): Venue3DStats;
|
|
453
482
|
loseContextForTest(): void;
|
|
@@ -474,6 +503,15 @@ interface Venue3DHandle {
|
|
|
474
503
|
* been answered. Returns false for an unknown or empty section.
|
|
475
504
|
*/
|
|
476
505
|
focusSection(sectionId: string): boolean;
|
|
506
|
+
/** Rows in the venue, optionally narrowed to a section. */
|
|
507
|
+
rows(sectionId?: string): SceneRow[];
|
|
508
|
+
/** Seats in one row, in authored order. */
|
|
509
|
+
seatsInRow(rowId: string): Array<{
|
|
510
|
+
id: string;
|
|
511
|
+
label: string;
|
|
512
|
+
}>;
|
|
513
|
+
/** Frame a row closely enough for its on-demand seat numbers to be legible. */
|
|
514
|
+
focusRow(rowId: string): boolean;
|
|
477
515
|
/** The venue's floors (id, name, seat count) in authored order. */
|
|
478
516
|
floors(): SceneFloor[];
|
|
479
517
|
/**
|
|
@@ -489,4 +527,4 @@ interface Venue3DHandle {
|
|
|
489
527
|
}
|
|
490
528
|
declare function mountVenue3D(container: HTMLElement, input: Venue3DInput, opts?: Venue3DOptions): Venue3DHandle;
|
|
491
529
|
|
|
492
|
-
export { type Analytics3DCallback, type
|
|
530
|
+
export { type Analytics3DCallback, type Scene3DPrepSource, type SeatState3D, SeatView, type Venue3DHandle, type Venue3DInput, type Venue3DOptions, type Venue3DStats, buildSceneModel, mountVenue3D, prepareVenue3D };
|