@embedpdf/plugin-stage 3.0.0-next.13 → 3.0.0-next.15
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/README.md +33 -23
- package/dist/contract/host.cjs +16 -0
- package/dist/contract/host.cjs.map +1 -0
- package/dist/contract/host.d.cts +3 -0
- package/dist/contract/host.d.ts +3 -0
- package/dist/contract/host.js +8 -0
- package/dist/contract/host.js.map +1 -0
- package/dist/contract-BoOt8rJM.js +11 -0
- package/dist/contract-BoOt8rJM.js.map +1 -0
- package/dist/contract-CjHtrfJj.d.ts +568 -0
- package/dist/contract-DZR_jRer.d.cts +568 -0
- package/dist/contract-iSNhoXLC.cjs +16 -0
- package/dist/contract-iSNhoXLC.cjs.map +1 -0
- package/dist/contract.cjs +1 -1
- package/dist/contract.d.cts +2 -3
- package/dist/contract.d.ts +2 -3
- package/dist/contract.js +1 -1
- package/dist/host-contract-CPtbnJ4j.d.cts +95 -0
- package/dist/host-contract-Du5tEZ4h.d.ts +95 -0
- package/dist/index.cjs +1770 -1399
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +57 -64
- package/dist/index.d.ts +57 -64
- package/dist/index.js +1772 -1379
- package/dist/index.js.map +1 -1
- package/package.json +10 -10
- package/dist/contract-BU33R4oL.cjs +0 -13
- package/dist/contract-BU33R4oL.cjs.map +0 -1
- package/dist/contract-CPSX8ANN.js +0 -8
- package/dist/contract-CPSX8ANN.js.map +0 -1
- package/dist/destination.cjs +0 -147
- package/dist/destination.cjs.map +0 -1
- package/dist/destination.d.cts +0 -19
- package/dist/destination.d.ts +0 -19
- package/dist/destination.js +0 -146
- package/dist/destination.js.map +0 -1
- package/dist/types-CdIFKQnj.d.ts +0 -656
- package/dist/types-qdO_v-V-.d.cts +0 -656
package/dist/index.d.cts
CHANGED
|
@@ -1,104 +1,97 @@
|
|
|
1
|
-
import { C as Viewpoint, S as
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import { Size } from "@embedpdf/core-stage";
|
|
6
|
-
import { InteractionCapability, InteractionHandler } from "@embedpdf/plugin-interaction/contract";
|
|
1
|
+
import { A as StageCapability, B as StageViewportChangedEvent, C as ScrollBehaviorKind, D as SpreadMode, E as SizingMode, F as StageScrollToOptions, G as VisiblePage, H as Viewpoint, I as StageSettings, J as ZoomSpec, K as ZoomMode, L as StageSettingsChangedEvent, M as StageMotionEndedEvent, N as StagePageChangedEvent, O as StageBox, P as StagePluginOptions, R as StageSettingsPatch, S as RevealZoom, T as Size, U as ViewportPoint, V as StageZoomChangedEvent, W as ViewportRect, X as StageToken, Y as ZoomToOptions, _ as Point, a as ArrivalAlignValue, b as RevealAnchorValue, c as Camera, d as Gap, f as GoToDestinationOptions, g as PageFrame, h as LayoutKind, i as AlignmentValue, j as StageConfig, k as StageCameraChangedEvent, l as Direction, m as GridColumns, n as AlignValue, o as ArrivalAlignment, p as GoToOptions, q as ZoomModeValue, r as Alignment, s as BoxQuery, t as Align, u as FlowMode, v as ResponsiveRule, w as ScrollMetrics, x as RevealOptions, y as RevealAnchor, z as StageViewState } from "./contract-DZR_jRer.cjs";
|
|
2
|
+
import { c as StageState, o as StageHostCapability } from "./host-contract-CPtbnJ4j.cjs";
|
|
3
|
+
import { Size as Size$1 } from "@embedpdf/core-stage";
|
|
4
|
+
import { InteractionHandler, InteractionHostCapability } from "@embedpdf/plugin-interaction/contract/host";
|
|
7
5
|
//#region src/stage.plugin.d.ts
|
|
8
6
|
/**
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
15
|
-
* plugins = [
|
|
16
|
-
* stagePlugin(), // main lens
|
|
17
|
-
* stagePlugin({ id: 'stage-thumbs', token: ThumbsToken,
|
|
18
|
-
* layout: 'grid', columns: 'auto', zoom: { level: 0.2 } }),
|
|
19
|
-
* ];
|
|
20
|
-
*
|
|
21
|
-
* Everything multiplexes automatically: state slices, capabilities, and teardown
|
|
22
|
-
* are already keyed by plugin-id × document in the kernel.
|
|
23
|
-
*/
|
|
24
|
-
interface StagePluginOptions extends StageConfig {
|
|
25
|
-
id?: string;
|
|
26
|
-
token?: CapabilityToken<StageCapability>;
|
|
27
|
-
}
|
|
28
|
-
/**
|
|
29
|
-
* Wires the parts into a kernel plugin. This file is the "manifest": it says what
|
|
30
|
-
* the plugin IS (id, token, state, reducer, capability) — the how lives in the
|
|
31
|
-
* sibling files.
|
|
7
|
+
* The stage plugin: one lens's camera, layout, zoom and navigation over a
|
|
8
|
+
* document. Document-scoped. The actions plugin is optional: with it, the
|
|
9
|
+
* main lens feeds page state to it and interprets GoTo and Named page
|
|
10
|
+
* actions. Pointer input is opted into by the surface binding
|
|
11
|
+
* (`<Stage interaction>` / `createStageSurface`), which both forwards pointer
|
|
12
|
+
* samples and registers this lens's scroll handler.
|
|
32
13
|
*/
|
|
33
|
-
declare const stagePlugin: (options?: StagePluginOptions) => import("@embedpdf/core").PluginDef<StageState,
|
|
14
|
+
declare const stagePlugin: (options?: StagePluginOptions) => import("@embedpdf/core").PluginDef<StageState, StageHostCapability, import("@embedpdf/core").NoSettings>;
|
|
15
|
+
//#endregion
|
|
16
|
+
//#region src/state.d.ts
|
|
17
|
+
declare const stageState: import("@embedpdf/core").StateDeclaration<StageCapability, {
|
|
18
|
+
zoomLevel: number;
|
|
19
|
+
zoomMode: import("@embedpdf/core-stage").ZoomModeValue | "custom";
|
|
20
|
+
currentPageIndex: number;
|
|
21
|
+
currentPage: import("@embedpdf/core").PageRef | null;
|
|
22
|
+
pageCount: number;
|
|
23
|
+
viewRotation: import("@embedpdf/core-geometry").PageRotation;
|
|
24
|
+
activeRules: readonly string[];
|
|
25
|
+
}>;
|
|
34
26
|
//#endregion
|
|
35
27
|
//#region src/scroll-handler.d.ts
|
|
36
28
|
interface ScrollHandlerOptions {
|
|
37
29
|
/**
|
|
38
|
-
* Let a drag over a page
|
|
39
|
-
* cursor there
|
|
40
|
-
*
|
|
41
|
-
*
|
|
30
|
+
* Let a drag over a page gap pan regardless of the active tool, and show a
|
|
31
|
+
* grab cursor there, so the gutter always pans (outside a page there is
|
|
32
|
+
* nothing to draw on or select). On-page behavior is untouched: the tool's
|
|
33
|
+
* own gesture still owns page space. Default true.
|
|
42
34
|
*/
|
|
43
35
|
panFallback?: boolean;
|
|
44
36
|
}
|
|
45
37
|
/**
|
|
46
38
|
* Pan-the-camera as an interaction handler. Live under the built-in `pan` tool
|
|
47
|
-
* (the `scroll` tag) and
|
|
48
|
-
* captures
|
|
49
|
-
* claims them first at higher priority). It uses the sample's viewport delta,
|
|
50
|
-
* it pans over the whole viewport (pages and gaps).
|
|
39
|
+
* (the `scroll` tag) and, with `panFallback`, under every tool, where it then
|
|
40
|
+
* captures only page-gap drags (on-page downs belong to the active tool, which
|
|
41
|
+
* claims them first at higher priority). It uses the sample's viewport delta,
|
|
42
|
+
* so it pans over the whole viewport (pages and gaps).
|
|
51
43
|
*
|
|
52
|
-
*
|
|
44
|
+
* Cursors: a closed hand (`grabbing`) while dragging; an open hand (`grab`)
|
|
53
45
|
* hovering a gap under a non-pan tool. The pan tool's own resting `grab` comes
|
|
54
46
|
* from its `Tool.cursor`, so hovering it needs no claim here.
|
|
55
47
|
*/
|
|
56
|
-
declare function createScrollHandler(stage: StageCapability, interaction:
|
|
48
|
+
declare function createScrollHandler(stage: StageCapability, interaction: InteractionHostCapability, options?: ScrollHandlerOptions): InteractionHandler;
|
|
57
49
|
//#endregion
|
|
58
50
|
//#region src/settings.d.ts
|
|
59
51
|
/**
|
|
60
|
-
* Out-of-the-box defaults
|
|
61
|
-
*
|
|
62
|
-
*
|
|
63
|
-
*
|
|
64
|
-
*
|
|
52
|
+
* Out-of-the-box defaults: a document-reading feel. Every field is overridable
|
|
53
|
+
* in `stagePlugin(config)` and at runtime through `updateSettings()`. The
|
|
54
|
+
* plugin ships no named presets ("document", "canvas", …): a preset is an
|
|
55
|
+
* object the app keeps and passes to `updateSettings()`, so that taxonomy
|
|
56
|
+
* stays the app's concern.
|
|
65
57
|
*/
|
|
66
58
|
declare const DEFAULT_SETTINGS: StageSettings;
|
|
67
59
|
/**
|
|
68
|
-
* Out-of-the-box responsive rules
|
|
69
|
-
* a compact container gets the thin gutter phones use (space, not device
|
|
60
|
+
* Out-of-the-box responsive rules, the platform feel with zero configuration:
|
|
61
|
+
* a compact container gets the thin gutter phones use (space, not device: an
|
|
70
62
|
* embedded 500px pane on a desktop is compact too). Override the whole list
|
|
71
63
|
* with `stagePlugin({ responsive: [...] })`; `responsive: []` opts out. The
|
|
72
|
-
* 'compact' name is queryable app
|
|
64
|
+
* 'compact' name is queryable by the app through `stage.matchesRule('compact')`.
|
|
73
65
|
*/
|
|
74
66
|
declare const DEFAULT_RESPONSIVE: readonly ResponsiveRule[];
|
|
75
|
-
/** Field-by-field settings equality, derived from the registry
|
|
76
|
-
* covered automatically
|
|
77
|
-
declare const settingsEqual: (
|
|
67
|
+
/** Field-by-field settings equality, derived from the registry, so a new
|
|
68
|
+
* setting is covered automatically: what an adapter compares settings with. */
|
|
69
|
+
declare const settingsEqual: (left: StageSettings, right: StageSettings) => boolean;
|
|
78
70
|
//#endregion
|
|
79
71
|
//#region src/responsive.d.ts
|
|
80
72
|
/**
|
|
81
|
-
* Container queries for the settings bag
|
|
82
|
-
* the driver (when to re-resolve, how to react); the
|
|
83
|
-
* box is, when a query matches, and what the effective settings are. No
|
|
84
|
-
*
|
|
73
|
+
* Container queries for the settings bag, the pure half. The capability owns
|
|
74
|
+
* the driver (when to re-resolve, how to react); the laws live here: what a
|
|
75
|
+
* box is, when a query matches, and what the effective settings are. No
|
|
76
|
+
* state, so they are property-testable in isolation.
|
|
85
77
|
*
|
|
86
|
-
* The query vocabulary is
|
|
87
|
-
*
|
|
88
|
-
*
|
|
89
|
-
* (`PointerSample.pointerType`) or the app's own business via
|
|
78
|
+
* The query vocabulary is only the box: a headless, DOM-free stage knows
|
|
79
|
+
* exactly one environmental fact, the viewport it was told. Anything else
|
|
80
|
+
* (pointer coarseness, platform, app state) is either per event
|
|
81
|
+
* (`PointerSample.pointerType`) or the app's own business via
|
|
82
|
+
* `updateSettings()`.
|
|
90
83
|
*/
|
|
91
84
|
/** The reported viewport as a queryable box. A square box is 'portrait' (CSS). */
|
|
92
|
-
declare const boxOf: (
|
|
93
|
-
/** All bounds inclusive, all fields optional,
|
|
94
|
-
declare const matchesQuery: (
|
|
85
|
+
declare const boxOf: (size: Size$1) => StageBox;
|
|
86
|
+
/** All bounds inclusive, all fields optional, every condition must hold (CSS ranges). */
|
|
87
|
+
declare const matchesQuery: (query: BoxQuery, box: StageBox) => boolean;
|
|
95
88
|
interface ResolvedResponsive {
|
|
96
|
-
/** base
|
|
89
|
+
/** The base merged with every matching rule's patch, in source order (later wins per key). */
|
|
97
90
|
effective: StageSettings;
|
|
98
91
|
/** Names of the matching rules, in source order. */
|
|
99
92
|
active: string[];
|
|
100
93
|
}
|
|
101
94
|
declare const resolveResponsive: (base: StageSettings, rules: readonly ResponsiveRule[], box: StageBox) => ResolvedResponsive;
|
|
102
95
|
//#endregion
|
|
103
|
-
export { type Align, type Alignment, type
|
|
96
|
+
export { type Align, type AlignValue, type Alignment, type AlignmentValue, ArrivalAlignValue, ArrivalAlignment, BoxQuery, type Camera, DEFAULT_RESPONSIVE, DEFAULT_SETTINGS, type Direction, FlowMode, Gap, GoToDestinationOptions, GoToOptions, GridColumns, LayoutKind, type PageFrame, type Point, ResponsiveRule, RevealAnchor, RevealAnchorValue, RevealOptions, RevealZoom, ScrollBehaviorKind, type ScrollHandlerOptions, type ScrollMetrics, type Size, type SizingMode, type SpreadMode, StageBox, StageCameraChangedEvent, StageCapability, StageConfig, StageMotionEndedEvent, StagePageChangedEvent, StagePluginOptions, StageScrollToOptions, StageSettings, StageSettingsChangedEvent, StageSettingsPatch, StageToken, StageViewState, StageViewportChangedEvent, StageZoomChangedEvent, Viewpoint, ViewportPoint, ViewportRect, VisiblePage, ZoomMode, type ZoomModeValue, type ZoomSpec, ZoomToOptions, boxOf, createScrollHandler, matchesQuery, resolveResponsive, settingsEqual, stagePlugin, stageState };
|
|
104
97
|
//# sourceMappingURL=index.d.cts.map
|
package/dist/index.d.ts
CHANGED
|
@@ -1,104 +1,97 @@
|
|
|
1
|
-
import { C as Viewpoint, S as
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import { Size } from "@embedpdf/core-stage";
|
|
6
|
-
import { InteractionCapability, InteractionHandler } from "@embedpdf/plugin-interaction/contract";
|
|
1
|
+
import { A as StageCapability, B as StageViewportChangedEvent, C as ScrollBehaviorKind, D as SpreadMode, E as SizingMode, F as StageScrollToOptions, G as VisiblePage, H as Viewpoint, I as StageSettings, J as ZoomSpec, K as ZoomMode, L as StageSettingsChangedEvent, M as StageMotionEndedEvent, N as StagePageChangedEvent, O as StageBox, P as StagePluginOptions, R as StageSettingsPatch, S as RevealZoom, T as Size, U as ViewportPoint, V as StageZoomChangedEvent, W as ViewportRect, X as StageToken, Y as ZoomToOptions, _ as Point, a as ArrivalAlignValue, b as RevealAnchorValue, c as Camera, d as Gap, f as GoToDestinationOptions, g as PageFrame, h as LayoutKind, i as AlignmentValue, j as StageConfig, k as StageCameraChangedEvent, l as Direction, m as GridColumns, n as AlignValue, o as ArrivalAlignment, p as GoToOptions, q as ZoomModeValue, r as Alignment, s as BoxQuery, t as Align, u as FlowMode, v as ResponsiveRule, w as ScrollMetrics, x as RevealOptions, y as RevealAnchor, z as StageViewState } from "./contract-CjHtrfJj.js";
|
|
2
|
+
import { c as StageState, o as StageHostCapability } from "./host-contract-Du5tEZ4h.js";
|
|
3
|
+
import { Size as Size$1 } from "@embedpdf/core-stage";
|
|
4
|
+
import { InteractionHandler, InteractionHostCapability } from "@embedpdf/plugin-interaction/contract/host";
|
|
7
5
|
//#region src/stage.plugin.d.ts
|
|
8
6
|
/**
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
15
|
-
* plugins = [
|
|
16
|
-
* stagePlugin(), // main lens
|
|
17
|
-
* stagePlugin({ id: 'stage-thumbs', token: ThumbsToken,
|
|
18
|
-
* layout: 'grid', columns: 'auto', zoom: { level: 0.2 } }),
|
|
19
|
-
* ];
|
|
20
|
-
*
|
|
21
|
-
* Everything multiplexes automatically: state slices, capabilities, and teardown
|
|
22
|
-
* are already keyed by plugin-id × document in the kernel.
|
|
23
|
-
*/
|
|
24
|
-
interface StagePluginOptions extends StageConfig {
|
|
25
|
-
id?: string;
|
|
26
|
-
token?: CapabilityToken<StageCapability>;
|
|
27
|
-
}
|
|
28
|
-
/**
|
|
29
|
-
* Wires the parts into a kernel plugin. This file is the "manifest": it says what
|
|
30
|
-
* the plugin IS (id, token, state, reducer, capability) — the how lives in the
|
|
31
|
-
* sibling files.
|
|
7
|
+
* The stage plugin: one lens's camera, layout, zoom and navigation over a
|
|
8
|
+
* document. Document-scoped. The actions plugin is optional: with it, the
|
|
9
|
+
* main lens feeds page state to it and interprets GoTo and Named page
|
|
10
|
+
* actions. Pointer input is opted into by the surface binding
|
|
11
|
+
* (`<Stage interaction>` / `createStageSurface`), which both forwards pointer
|
|
12
|
+
* samples and registers this lens's scroll handler.
|
|
32
13
|
*/
|
|
33
|
-
declare const stagePlugin: (options?: StagePluginOptions) => import("@embedpdf/core").PluginDef<StageState,
|
|
14
|
+
declare const stagePlugin: (options?: StagePluginOptions) => import("@embedpdf/core").PluginDef<StageState, StageHostCapability, import("@embedpdf/core").NoSettings>;
|
|
15
|
+
//#endregion
|
|
16
|
+
//#region src/state.d.ts
|
|
17
|
+
declare const stageState: import("@embedpdf/core").StateDeclaration<StageCapability, {
|
|
18
|
+
zoomLevel: number;
|
|
19
|
+
zoomMode: import("@embedpdf/core-stage").ZoomModeValue | "custom";
|
|
20
|
+
currentPageIndex: number;
|
|
21
|
+
currentPage: import("@embedpdf/core").PageRef | null;
|
|
22
|
+
pageCount: number;
|
|
23
|
+
viewRotation: import("@embedpdf/core-geometry").PageRotation;
|
|
24
|
+
activeRules: readonly string[];
|
|
25
|
+
}>;
|
|
34
26
|
//#endregion
|
|
35
27
|
//#region src/scroll-handler.d.ts
|
|
36
28
|
interface ScrollHandlerOptions {
|
|
37
29
|
/**
|
|
38
|
-
* Let a drag over a page
|
|
39
|
-
* cursor there
|
|
40
|
-
*
|
|
41
|
-
*
|
|
30
|
+
* Let a drag over a page gap pan regardless of the active tool, and show a
|
|
31
|
+
* grab cursor there, so the gutter always pans (outside a page there is
|
|
32
|
+
* nothing to draw on or select). On-page behavior is untouched: the tool's
|
|
33
|
+
* own gesture still owns page space. Default true.
|
|
42
34
|
*/
|
|
43
35
|
panFallback?: boolean;
|
|
44
36
|
}
|
|
45
37
|
/**
|
|
46
38
|
* Pan-the-camera as an interaction handler. Live under the built-in `pan` tool
|
|
47
|
-
* (the `scroll` tag) and
|
|
48
|
-
* captures
|
|
49
|
-
* claims them first at higher priority). It uses the sample's viewport delta,
|
|
50
|
-
* it pans over the whole viewport (pages and gaps).
|
|
39
|
+
* (the `scroll` tag) and, with `panFallback`, under every tool, where it then
|
|
40
|
+
* captures only page-gap drags (on-page downs belong to the active tool, which
|
|
41
|
+
* claims them first at higher priority). It uses the sample's viewport delta,
|
|
42
|
+
* so it pans over the whole viewport (pages and gaps).
|
|
51
43
|
*
|
|
52
|
-
*
|
|
44
|
+
* Cursors: a closed hand (`grabbing`) while dragging; an open hand (`grab`)
|
|
53
45
|
* hovering a gap under a non-pan tool. The pan tool's own resting `grab` comes
|
|
54
46
|
* from its `Tool.cursor`, so hovering it needs no claim here.
|
|
55
47
|
*/
|
|
56
|
-
declare function createScrollHandler(stage: StageCapability, interaction:
|
|
48
|
+
declare function createScrollHandler(stage: StageCapability, interaction: InteractionHostCapability, options?: ScrollHandlerOptions): InteractionHandler;
|
|
57
49
|
//#endregion
|
|
58
50
|
//#region src/settings.d.ts
|
|
59
51
|
/**
|
|
60
|
-
* Out-of-the-box defaults
|
|
61
|
-
*
|
|
62
|
-
*
|
|
63
|
-
*
|
|
64
|
-
*
|
|
52
|
+
* Out-of-the-box defaults: a document-reading feel. Every field is overridable
|
|
53
|
+
* in `stagePlugin(config)` and at runtime through `updateSettings()`. The
|
|
54
|
+
* plugin ships no named presets ("document", "canvas", …): a preset is an
|
|
55
|
+
* object the app keeps and passes to `updateSettings()`, so that taxonomy
|
|
56
|
+
* stays the app's concern.
|
|
65
57
|
*/
|
|
66
58
|
declare const DEFAULT_SETTINGS: StageSettings;
|
|
67
59
|
/**
|
|
68
|
-
* Out-of-the-box responsive rules
|
|
69
|
-
* a compact container gets the thin gutter phones use (space, not device
|
|
60
|
+
* Out-of-the-box responsive rules, the platform feel with zero configuration:
|
|
61
|
+
* a compact container gets the thin gutter phones use (space, not device: an
|
|
70
62
|
* embedded 500px pane on a desktop is compact too). Override the whole list
|
|
71
63
|
* with `stagePlugin({ responsive: [...] })`; `responsive: []` opts out. The
|
|
72
|
-
* 'compact' name is queryable app
|
|
64
|
+
* 'compact' name is queryable by the app through `stage.matchesRule('compact')`.
|
|
73
65
|
*/
|
|
74
66
|
declare const DEFAULT_RESPONSIVE: readonly ResponsiveRule[];
|
|
75
|
-
/** Field-by-field settings equality, derived from the registry
|
|
76
|
-
* covered automatically
|
|
77
|
-
declare const settingsEqual: (
|
|
67
|
+
/** Field-by-field settings equality, derived from the registry, so a new
|
|
68
|
+
* setting is covered automatically: what an adapter compares settings with. */
|
|
69
|
+
declare const settingsEqual: (left: StageSettings, right: StageSettings) => boolean;
|
|
78
70
|
//#endregion
|
|
79
71
|
//#region src/responsive.d.ts
|
|
80
72
|
/**
|
|
81
|
-
* Container queries for the settings bag
|
|
82
|
-
* the driver (when to re-resolve, how to react); the
|
|
83
|
-
* box is, when a query matches, and what the effective settings are. No
|
|
84
|
-
*
|
|
73
|
+
* Container queries for the settings bag, the pure half. The capability owns
|
|
74
|
+
* the driver (when to re-resolve, how to react); the laws live here: what a
|
|
75
|
+
* box is, when a query matches, and what the effective settings are. No
|
|
76
|
+
* state, so they are property-testable in isolation.
|
|
85
77
|
*
|
|
86
|
-
* The query vocabulary is
|
|
87
|
-
*
|
|
88
|
-
*
|
|
89
|
-
* (`PointerSample.pointerType`) or the app's own business via
|
|
78
|
+
* The query vocabulary is only the box: a headless, DOM-free stage knows
|
|
79
|
+
* exactly one environmental fact, the viewport it was told. Anything else
|
|
80
|
+
* (pointer coarseness, platform, app state) is either per event
|
|
81
|
+
* (`PointerSample.pointerType`) or the app's own business via
|
|
82
|
+
* `updateSettings()`.
|
|
90
83
|
*/
|
|
91
84
|
/** The reported viewport as a queryable box. A square box is 'portrait' (CSS). */
|
|
92
|
-
declare const boxOf: (
|
|
93
|
-
/** All bounds inclusive, all fields optional,
|
|
94
|
-
declare const matchesQuery: (
|
|
85
|
+
declare const boxOf: (size: Size$1) => StageBox;
|
|
86
|
+
/** All bounds inclusive, all fields optional, every condition must hold (CSS ranges). */
|
|
87
|
+
declare const matchesQuery: (query: BoxQuery, box: StageBox) => boolean;
|
|
95
88
|
interface ResolvedResponsive {
|
|
96
|
-
/** base
|
|
89
|
+
/** The base merged with every matching rule's patch, in source order (later wins per key). */
|
|
97
90
|
effective: StageSettings;
|
|
98
91
|
/** Names of the matching rules, in source order. */
|
|
99
92
|
active: string[];
|
|
100
93
|
}
|
|
101
94
|
declare const resolveResponsive: (base: StageSettings, rules: readonly ResponsiveRule[], box: StageBox) => ResolvedResponsive;
|
|
102
95
|
//#endregion
|
|
103
|
-
export { type Align, type Alignment, type
|
|
96
|
+
export { type Align, type AlignValue, type Alignment, type AlignmentValue, ArrivalAlignValue, ArrivalAlignment, BoxQuery, type Camera, DEFAULT_RESPONSIVE, DEFAULT_SETTINGS, type Direction, FlowMode, Gap, GoToDestinationOptions, GoToOptions, GridColumns, LayoutKind, type PageFrame, type Point, ResponsiveRule, RevealAnchor, RevealAnchorValue, RevealOptions, RevealZoom, ScrollBehaviorKind, type ScrollHandlerOptions, type ScrollMetrics, type Size, type SizingMode, type SpreadMode, StageBox, StageCameraChangedEvent, StageCapability, StageConfig, StageMotionEndedEvent, StagePageChangedEvent, StagePluginOptions, StageScrollToOptions, StageSettings, StageSettingsChangedEvent, StageSettingsPatch, StageToken, StageViewState, StageViewportChangedEvent, StageZoomChangedEvent, Viewpoint, ViewportPoint, ViewportRect, VisiblePage, ZoomMode, type ZoomModeValue, type ZoomSpec, ZoomToOptions, boxOf, createScrollHandler, matchesQuery, resolveResponsive, settingsEqual, stagePlugin, stageState };
|
|
104
97
|
//# sourceMappingURL=index.d.ts.map
|