@ssgoi/core 6.1.0 → 6.2.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/index.cjs +11 -11
- package/dist/index.js +977 -729
- package/dist/transitions/axis/index.d.ts +9 -1
- package/dist/transitions/axis/index.d.ts.map +1 -1
- package/dist/transitions/axis/provider/index.d.ts.map +1 -1
- package/dist/transitions/axis/provider/x/index.d.ts +3 -1
- package/dist/transitions/axis/provider/x/index.d.ts.map +1 -1
- package/dist/transitions/axis/provider/y/directional.d.ts +3 -0
- package/dist/transitions/axis/provider/y/directional.d.ts.map +1 -0
- package/dist/transitions/axis/provider/y/index.d.ts +5 -0
- package/dist/transitions/axis/provider/y/index.d.ts.map +1 -0
- package/dist/transitions/axis/provider/y/non-directional.d.ts +3 -0
- package/dist/transitions/axis/provider/y/non-directional.d.ts.map +1 -0
- package/dist/transitions/axis/types.d.ts +9 -6
- package/dist/transitions/axis/types.d.ts.map +1 -1
- package/dist/transitions/fade/index.d.ts +2 -5
- package/dist/transitions/fade/index.d.ts.map +1 -1
- package/dist/transitions/fade/types.d.ts +2 -8
- package/dist/transitions/fade/types.d.ts.map +1 -1
- package/dist/transitions/hero/index.d.ts +10 -7
- package/dist/transitions/hero/index.d.ts.map +1 -1
- package/dist/transitions/hero/keys.d.ts +15 -0
- package/dist/transitions/hero/keys.d.ts.map +1 -0
- package/dist/transitions/hero/provider/fade.d.ts +3 -0
- package/dist/transitions/hero/provider/fade.d.ts.map +1 -0
- package/dist/transitions/hero/provider/index.d.ts +8 -0
- package/dist/transitions/hero/provider/index.d.ts.map +1 -0
- package/dist/transitions/hero/provider/static.d.ts +3 -0
- package/dist/transitions/hero/provider/static.d.ts.map +1 -0
- package/dist/transitions/hero/transition.d.ts +7 -6
- package/dist/transitions/hero/transition.d.ts.map +1 -1
- package/dist/transitions/hero/types.d.ts +50 -7
- package/dist/transitions/hero/types.d.ts.map +1 -1
- package/dist/transitions/zoom/provider/blur.d.ts.map +1 -1
- package/dist/transitions/zoom/provider/static.d.ts.map +1 -1
- package/dist/transitions/zoom/transition.d.ts.map +1 -1
- package/package.json +1 -1
- package/dist/transitions/axis/provider/y.d.ts +0 -3
- package/dist/transitions/axis/provider/y.d.ts.map +0 -1
|
@@ -6,6 +6,14 @@ import { SsgoiPathTransition } from '../../types/index.ts';
|
|
|
6
6
|
* - `"snappy"` — tight, decisive page swap (KakaoTalk style).
|
|
7
7
|
*/
|
|
8
8
|
export type AxisXVariant = "default" | "snappy";
|
|
9
|
+
/**
|
|
10
|
+
* Public `variant` value for `axis({ type: "y" })`.
|
|
11
|
+
*
|
|
12
|
+
* - `"default"` — directional fade-through. Forward = bottom→top.
|
|
13
|
+
* - `"non-directional"` — direction-agnostic. Incoming always rises from
|
|
14
|
+
* below; outgoing fades in place.
|
|
15
|
+
*/
|
|
16
|
+
export type AxisYVariant = "default" | "non-directional";
|
|
9
17
|
/**
|
|
10
18
|
* Legacy `feel` axis. Kept for source compatibility only.
|
|
11
19
|
*
|
|
@@ -32,7 +40,7 @@ export type AxisConfig = {
|
|
|
32
40
|
feel?: AxisFeelDeprecated;
|
|
33
41
|
} | {
|
|
34
42
|
type: "y";
|
|
35
|
-
variant?:
|
|
43
|
+
variant?: AxisYVariant;
|
|
36
44
|
options?: {};
|
|
37
45
|
} | {
|
|
38
46
|
type: "z";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/lib/transitions/axis/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,QAAQ,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/lib/transitions/axis/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,QAAQ,CAAC;AAmBlD;;;;;GAKG;AACH,MAAM,MAAM,YAAY,GAAG,SAAS,GAAG,QAAQ,CAAC;AAEhD;;;;;;GAMG;AACH,MAAM,MAAM,YAAY,GAAG,SAAS,GAAG,iBAAiB,CAAC;AAEzD;;;;;;;;GAQG;AACH,MAAM,MAAM,kBAAkB,GAAG,QAAQ,GAAG,OAAO,CAAC;AAEpD,MAAM,MAAM,UAAU,GAAG;IACvB,KAAK,EAAE,SAAS,MAAM,EAAE,CAAC;CAC1B,GAAG,CACA;IACE,IAAI,CAAC,EAAE,GAAG,CAAC;IACX,OAAO,CAAC,EAAE,YAAY,CAAC;IACvB,OAAO,CAAC,EAAE,EAAE,CAAC;IACb;;;;;;OAMG;IACH,IAAI,CAAC,EAAE,kBAAkB,CAAC;CAC3B,GACD;IAAE,IAAI,EAAE,GAAG,CAAC;IAAC,OAAO,CAAC,EAAE,YAAY,CAAC;IAAC,OAAO,CAAC,EAAE,EAAE,CAAA;CAAE,GACnD;IAAE,IAAI,EAAE,GAAG,CAAC;IAAC,OAAO,CAAC,EAAE,SAAS,CAAC;IAAC,OAAO,CAAC,EAAE,EAAE,CAAA;CAAE,CACnD,CAAC;AA+BF,wBAAgB,IAAI,CAAC,MAAM,EAAE,UAAU,GAAG,mBAAmB,EAAE,CAY9D"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lib/transitions/axis/provider/index.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,QAAQ,EAAE,YAAY,EAAE,QAAQ,EAAE,MAAM,UAAU,CAAC;AAKjE,KAAK,eAAe,GAAG;IAAE,MAAM,EAAE,YAAY,CAAA;CAAE,GAAG,OAAO,CACvD,MAAM,CAAC,QAAQ,EAAE,YAAY,CAAC,CAC/B,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lib/transitions/axis/provider/index.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,QAAQ,EAAE,YAAY,EAAE,QAAQ,EAAE,MAAM,UAAU,CAAC;AAKjE,KAAK,eAAe,GAAG;IAAE,MAAM,EAAE,YAAY,CAAA;CAAE,GAAG,OAAO,CACvD,MAAM,CAAC,QAAQ,EAAE,YAAY,CAAC,CAC/B,CAAC;AAIF,eAAO,MAAM,cAAc,EAAE,MAAM,CAAC,QAAQ,EAAE,eAAe,CAI5D,CAAC;AAEF,wBAAgB,mBAAmB,CACjC,IAAI,EAAE,QAAQ,EACd,IAAI,EAAE,QAAQ,GACb,YAAY,CAGd"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/lib/transitions/axis/provider/x/index.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,QAAQ,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/lib/transitions/axis/provider/x/index.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,QAAQ,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAQ1D,eAAO,MAAM,WAAW,EAAE;IAAE,MAAM,EAAE,YAAY,CAAA;CAAE,GAAG,OAAO,CAC1D,MAAM,CAAC,QAAQ,EAAE,YAAY,CAAC,CAI/B,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"directional.d.ts","sourceRoot":"","sources":["../../../../../src/lib/transitions/axis/provider/y/directional.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAEV,YAAY,EAEb,MAAM,aAAa,CAAC;AAoDrB,wBAAgB,0BAA0B,IAAI,YAAY,CAOzD"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/lib/transitions/axis/provider/y/index.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,QAAQ,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAO1D,eAAO,MAAM,WAAW,EAAE;IAAE,MAAM,EAAE,YAAY,CAAA;CAAE,GAAG,OAAO,CAC1D,MAAM,CAAC,QAAQ,EAAE,YAAY,CAAC,CAK/B,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"non-directional.d.ts","sourceRoot":"","sources":["../../../../../src/lib/transitions/axis/provider/y/non-directional.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAEV,YAAY,EAEb,MAAM,aAAa,CAAC;AA+CrB,wBAAgB,6BAA6B,IAAI,YAAY,CAO5D"}
|
|
@@ -3,14 +3,17 @@ import { MultiAnimationOptions } from '../../animation/multi-animation';
|
|
|
3
3
|
export type AxisType = "x" | "y" | "z";
|
|
4
4
|
export type AxisDirection = "forward" | "backward";
|
|
5
5
|
/**
|
|
6
|
-
* UX flavor *within* a single axis. Independent dimension from `AxisType
|
|
7
|
-
*
|
|
8
|
-
* - `
|
|
6
|
+
* UX flavor *within* a single axis. Independent dimension from `AxisType`; the
|
|
7
|
+
* set of meaningful values differs per type:
|
|
8
|
+
* - x: `snappy` (KakaoTalk tab swap) | `fluid` (Material SharedAxisTransition)
|
|
9
|
+
* - y: `directional` (forward = bottom→top) | `non-directional` (in always
|
|
10
|
+
* rises from below; out fades in place)
|
|
11
|
+
* - z: `snappy` only
|
|
9
12
|
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
13
|
+
* Providers may alias unsupported feels to an in-axis default — `snappy` is
|
|
14
|
+
* the universal fallback inside `resolveAxisProvider`.
|
|
12
15
|
*/
|
|
13
|
-
export type AxisFeel = "snappy" | "fluid";
|
|
16
|
+
export type AxisFeel = "snappy" | "fluid" | "directional" | "non-directional";
|
|
14
17
|
export interface AxisOptions {
|
|
15
18
|
type?: AxisType;
|
|
16
19
|
direction?: AxisDirection;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/lib/transitions/axis/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAC;AAC1D,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,iCAAiC,CAAC;AAE7E,MAAM,MAAM,QAAQ,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,CAAC;AACvC,MAAM,MAAM,aAAa,GAAG,SAAS,GAAG,UAAU,CAAC;AAEnD
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/lib/transitions/axis/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAC;AAC1D,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,iCAAiC,CAAC;AAE7E,MAAM,MAAM,QAAQ,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,CAAC;AACvC,MAAM,MAAM,aAAa,GAAG,SAAS,GAAG,UAAU,CAAC;AAEnD;;;;;;;;;;GAUG;AACH,MAAM,MAAM,QAAQ,GAAG,QAAQ,GAAG,OAAO,GAAG,aAAa,GAAG,iBAAiB,CAAC;AAE9E,MAAM,WAAW,WAAW;IAC1B,IAAI,CAAC,EAAE,QAAQ,CAAC;IAChB,SAAS,CAAC,EAAE,aAAa,CAAC;IAC1B,IAAI,CAAC,EAAE,QAAQ,CAAC;CACjB;AAED,MAAM,MAAM,eAAe,GAAG,CAAC,QAAQ,EAAE,MAAM,KAAK,WAAW,CAAC;AAEhE,MAAM,WAAW,cAAc;IAC7B,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,WAAW,CAAC;IACxB,OAAO,EAAE,eAAe,CAAC;CAC1B;AAED,MAAM,WAAW,mBAAmB;IAClC,GAAG,EAAE,cAAc,CAAC;IACpB,EAAE,EAAE,cAAc,CAAC;CACpB;AAED,MAAM,WAAW,qBAAqB;IACpC,SAAS,EAAE,aAAa,CAAC;CAC1B;AAED,MAAM,WAAW,YAAY;IAC3B;;;;;OAKG;IACH,UAAU,EAAE,cAAc,CAAC;IAC3B,qCAAqC;IACrC,SAAS,EAAE,cAAc,CAAC;IAC1B;;;;;OAKG;IACH,WAAW,CAAC,EAAE,qBAAqB,CAAC;IACpC,qEAAqE;IACrE,KAAK,EAAE,CAAC,IAAI,EAAE,qBAAqB,KAAK,mBAAmB,CAAC;CAC7D"}
|
|
@@ -3,11 +3,8 @@ import { PresetConfig } from '../utils';
|
|
|
3
3
|
import { FadeOptions, FadeType, FadeVariant } from './types';
|
|
4
4
|
export type { FadeOptions, FadeType, FadeVariant } from './types';
|
|
5
5
|
/**
|
|
6
|
-
* Fade preset configuration.
|
|
7
|
-
*
|
|
8
|
-
* Default `type` is `"fade-through"` (sequential fade-out → fade-in).
|
|
9
|
-
* The `"cross-fade"` type and `"smooth"` variant are tracked on the TODO
|
|
10
|
-
* board and intentionally not part of the public type yet.
|
|
6
|
+
* Fade preset configuration. Default `type` is `"fade-through"` —
|
|
7
|
+
* sequential fade-out → fade-in.
|
|
11
8
|
*/
|
|
12
9
|
export type FadeConfig = PresetConfig<{
|
|
13
10
|
paths: readonly string[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/lib/transitions/fade/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,QAAQ,CAAC;AAClD,OAAO,EAAkC,KAAK,YAAY,EAAE,MAAM,UAAU,CAAC;AAE7E,OAAO,KAAK,EAAE,WAAW,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAElE,YAAY,EAAE,WAAW,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAElE
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/lib/transitions/fade/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,QAAQ,CAAC;AAClD,OAAO,EAAkC,KAAK,YAAY,EAAE,MAAM,UAAU,CAAC;AAE7E,OAAO,KAAK,EAAE,WAAW,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAElE,YAAY,EAAE,WAAW,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAElE;;;GAGG;AACH,MAAM,MAAM,UAAU,GAAG,YAAY,CACnC;IAAE,KAAK,EAAE,SAAS,MAAM,EAAE,CAAA;CAAE,EAC5B,QAAQ,EACR,WAAW,EACX,WAAW,CACZ,CAAC;AAEF,wBAAgB,IAAI,CAAC,MAAM,EAAE,UAAU,GAAG,mBAAmB,EAAE,CAG9D"}
|
|
@@ -1,12 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Public option shapes for the fade preset.
|
|
3
|
-
*
|
|
4
|
-
* Default `type` is `"fade-through"` — the current sequential
|
|
5
|
-
* fade-out → fade-in behavior.
|
|
6
|
-
*
|
|
7
|
-
* Not yet exposed (tracked separately on the TODO board):
|
|
8
|
-
* - `type: "cross-fade"` (simultaneous fade)
|
|
9
|
-
* - `variant: "smooth"`
|
|
2
|
+
* Public option shapes for the fade preset. Default `type` is
|
|
3
|
+
* `"fade-through"` — the sequential fade-out → fade-in behavior.
|
|
10
4
|
*/
|
|
11
5
|
export type FadeType = "fade-through";
|
|
12
6
|
export type FadeVariant = "default";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/lib/transitions/fade/types.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/lib/transitions/fade/types.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,MAAM,MAAM,QAAQ,GAAG,cAAc,CAAC;AAEtC,MAAM,MAAM,WAAW,GAAG,SAAS,CAAC;AAEpC,MAAM,MAAM,WAAW,GAAG,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC"}
|
|
@@ -1,17 +1,20 @@
|
|
|
1
1
|
import { SsgoiPathTransition } from '../../types/index.ts';
|
|
2
2
|
import { PresetConfig } from '../utils';
|
|
3
|
-
import { HeroOptions, HeroVariant } from './types';
|
|
4
|
-
export type { HeroOptions, HeroVariant } from './types';
|
|
3
|
+
import { HeroOptions, HeroType, HeroVariant } from './types';
|
|
4
|
+
export type { HeroOptions, HeroType, HeroVariant } from './types';
|
|
5
5
|
/**
|
|
6
6
|
* Hero preset configuration.
|
|
7
7
|
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
8
|
+
* - `type: "static"` (default) — incoming-page chrome snaps in; the shared
|
|
9
|
+
* element morphs in place via clip-path inset + uniform scale.
|
|
10
|
+
* - `type: "fade"` — both pages cross-fade as whole surfaces while a
|
|
11
|
+
* temporary shared-element clone morphs above them. Use when each side has
|
|
12
|
+
* its own chrome (e.g., a detail screen with its own back button / app bar).
|
|
13
|
+
* - `variant: "default"` — only value today; reserved for future tonal
|
|
14
|
+
* variants without re-shaping the public API.
|
|
12
15
|
*/
|
|
13
16
|
export type HeroConfig = PresetConfig<{
|
|
14
17
|
paths: readonly string[];
|
|
15
|
-
},
|
|
18
|
+
}, HeroType, HeroVariant, HeroOptions>;
|
|
16
19
|
export declare function hero(config: HeroConfig): SsgoiPathTransition[];
|
|
17
20
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/lib/transitions/hero/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,QAAQ,CAAC;AAClD,OAAO,EAAkC,KAAK,YAAY,EAAE,MAAM,UAAU,CAAC;AAE7E,OAAO,KAAK,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/lib/transitions/hero/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,QAAQ,CAAC;AAClD,OAAO,EAAkC,KAAK,YAAY,EAAE,MAAM,UAAU,CAAC;AAE7E,OAAO,KAAK,EAAE,WAAW,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAElE,YAAY,EAAE,WAAW,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAElE;;;;;;;;;;GAUG;AACH,MAAM,MAAM,UAAU,GAAG,YAAY,CACnC;IAAE,KAAK,EAAE,SAAS,MAAM,EAAE,CAAA;CAAE,EAC5B,QAAQ,EACR,WAAW,EACX,WAAW,CACZ,CAAC;AAEF,wBAAgB,IAAI,CAAC,MAAM,EAAE,UAAU,GAAG,mBAAmB,EAAE,CAO9D"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Shared hero attribute keys. Lives in its own module so both the dispatcher
|
|
3
|
+
* (transition.ts) and the chrome providers can consume them without creating
|
|
4
|
+
* an import cycle through provider/index.ts.
|
|
5
|
+
*/
|
|
6
|
+
export declare const HERO_ENTER_KEY = "data-hero-enter-key";
|
|
7
|
+
export declare const HERO_EXIT_KEY = "data-hero-exit-key";
|
|
8
|
+
export declare const HERO_LEGACY_KEY = "data-hero-key";
|
|
9
|
+
/** CSS selector matching any hero-keyed element. */
|
|
10
|
+
export declare const HERO_ANY_KEY_SELECTOR = "[data-hero-enter-key],[data-hero-exit-key],[data-hero-key]";
|
|
11
|
+
/** True if `el` itself carries any hero key. */
|
|
12
|
+
export declare function isHeroKeyed(el: HTMLElement): boolean;
|
|
13
|
+
/** True if `el` is hero-keyed or contains any hero-keyed descendant. */
|
|
14
|
+
export declare function isOrContainsHeroKey(el: HTMLElement): boolean;
|
|
15
|
+
//# sourceMappingURL=keys.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"keys.d.ts","sourceRoot":"","sources":["../../../src/lib/transitions/hero/keys.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,eAAO,MAAM,cAAc,wBAAwB,CAAC;AACpD,eAAO,MAAM,aAAa,uBAAuB,CAAC;AAClD,eAAO,MAAM,eAAe,kBAAkB,CAAC;AAE/C,oDAAoD;AACpD,eAAO,MAAM,qBAAqB,+DAAgE,CAAC;AAEnG,gDAAgD;AAChD,wBAAgB,WAAW,CAAC,EAAE,EAAE,WAAW,GAAG,OAAO,CAMpD;AAED,wEAAwE;AACxE,wBAAgB,mBAAmB,CAAC,EAAE,EAAE,WAAW,GAAG,OAAO,CAG5D"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fade.d.ts","sourceRoot":"","sources":["../../../../src/lib/transitions/hero/provider/fade.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAqB,YAAY,EAAE,MAAM,UAAU,CAAC;AA4ChE,eAAO,MAAM,wBAAwB,QAAO,YACT,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { HeroStrategy, HeroType } from '../types';
|
|
2
|
+
/**
|
|
3
|
+
* Chrome-handling strategy keyed on `HeroType`. The dispatcher in
|
|
4
|
+
* transition.ts looks the factory up here and assembles it next to the
|
|
5
|
+
* always-on TileStrategy — never branches on the type itself.
|
|
6
|
+
*/
|
|
7
|
+
export declare const HERO_CHROME_PROVIDERS: Record<HeroType, () => HeroStrategy>;
|
|
8
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lib/transitions/hero/provider/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,QAAQ,EAAE,MAAM,UAAU,CAAC;AAIvD;;;;GAIG;AACH,eAAO,MAAM,qBAAqB,EAAE,MAAM,CAAC,QAAQ,EAAE,MAAM,YAAY,CAGtE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"static.d.ts","sourceRoot":"","sources":["../../../../src/lib/transitions/hero/provider/static.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAkB,YAAY,EAAE,MAAM,UAAU,CAAC;AAoB7D,eAAO,MAAM,0BAA0B,QAAO,YAChB,CAAC"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
import { TransitionConfig } from '../../types/index.ts';
|
|
2
|
+
import { HeroResolved, NormalizedHeroOptions } from './types';
|
|
3
|
+
export type { HeroType, HeroVariant, NormalizedHeroOptions } from './types';
|
|
4
|
+
type HeroExtras = {
|
|
5
|
+
resolved: HeroResolved;
|
|
6
|
+
};
|
|
7
|
+
export declare const hero: (options: NormalizedHeroOptions) => TransitionConfig<HeroExtras>;
|
|
7
8
|
//# sourceMappingURL=transition.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"transition.d.ts","sourceRoot":"","sources":["../../../src/lib/transitions/hero/transition.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"transition.d.ts","sourceRoot":"","sources":["../../../src/lib/transitions/hero/transition.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAkB,gBAAgB,EAAE,MAAM,QAAQ,CAAC;AAU/D,OAAO,KAAK,EAIV,YAAY,EAGZ,qBAAqB,EACtB,MAAM,SAAS,CAAC;AAEjB,YAAY,EAAE,QAAQ,EAAE,WAAW,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAC;AAua5E,KAAK,UAAU,GAAG;IAAE,QAAQ,EAAE,YAAY,CAAA;CAAE,CAAC;AAE7C,eAAO,MAAM,IAAI,GACf,SAAS,qBAAqB,KAC7B,gBAAgB,CAAC,UAAU,CA2E7B,CAAC"}
|
|
@@ -1,12 +1,55 @@
|
|
|
1
|
+
import { PhysicsOptions } from '../../types/index.ts';
|
|
2
|
+
import { Animation } from '../../animation';
|
|
1
3
|
/**
|
|
2
|
-
*
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
* Not yet exposed (tracked separately on the TODO board):
|
|
8
|
-
* - `variant: "snappy"`
|
|
4
|
+
* - `static` — the shared element morphs in place; the incoming page's chrome
|
|
5
|
+
* snaps in. Default.
|
|
6
|
+
* - `fade` — both pages cross-fade as whole surfaces while a temporary hero
|
|
7
|
+
* clone morphs above them.
|
|
9
8
|
*/
|
|
9
|
+
export type HeroType = "static" | "fade";
|
|
10
10
|
export type HeroVariant = "default";
|
|
11
11
|
export type HeroOptions = Record<string, never>;
|
|
12
|
+
export interface NormalizedHeroOptions {
|
|
13
|
+
type: HeroType;
|
|
14
|
+
variant: HeroVariant;
|
|
15
|
+
}
|
|
16
|
+
export interface HeroPair {
|
|
17
|
+
key: string;
|
|
18
|
+
fromEl: HTMLElement;
|
|
19
|
+
toEl: HTMLElement;
|
|
20
|
+
}
|
|
21
|
+
export interface HeroResolved {
|
|
22
|
+
pairs: HeroPair[];
|
|
23
|
+
}
|
|
24
|
+
export interface HeroPrepareCtx {
|
|
25
|
+
from: Promise<HTMLElement>;
|
|
26
|
+
to: Promise<HTMLElement>;
|
|
27
|
+
resolved: Promise<HeroResolved>;
|
|
28
|
+
}
|
|
29
|
+
export interface HeroContributeCtx {
|
|
30
|
+
from: HTMLElement;
|
|
31
|
+
to: HTMLElement;
|
|
32
|
+
resolved: HeroResolved;
|
|
33
|
+
physics: PhysicsOptions;
|
|
34
|
+
scrollOffset: {
|
|
35
|
+
x: number;
|
|
36
|
+
y: number;
|
|
37
|
+
};
|
|
38
|
+
positionedParent: HTMLElement;
|
|
39
|
+
maxDistance: number;
|
|
40
|
+
/**
|
|
41
|
+
* Mutation registry. Strategies push restore callbacks here; the dispatcher
|
|
42
|
+
* fires them on completion. Keeps cleanup local to each strategy instead of
|
|
43
|
+
* leaking back into the dispatcher.
|
|
44
|
+
*/
|
|
45
|
+
onComplete: (fn: () => void) => void;
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* Strategy interface. Both methods are optional — a no-op strategy is a
|
|
49
|
+
* legitimate factory return value (e.g. static chrome).
|
|
50
|
+
*/
|
|
51
|
+
export interface HeroStrategy {
|
|
52
|
+
prepare?: (ctx: HeroPrepareCtx) => void;
|
|
53
|
+
contribute?: (ctx: HeroContributeCtx) => Animation[];
|
|
54
|
+
}
|
|
12
55
|
//# sourceMappingURL=types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/lib/transitions/hero/types.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/lib/transitions/hero/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,QAAQ,CAAC;AAC7C,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAMjD;;;;;GAKG;AACH,MAAM,MAAM,QAAQ,GAAG,QAAQ,GAAG,MAAM,CAAC;AACzC,MAAM,MAAM,WAAW,GAAG,SAAS,CAAC;AACpC,MAAM,MAAM,WAAW,GAAG,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC;AAOhD,MAAM,WAAW,qBAAqB;IACpC,IAAI,EAAE,QAAQ,CAAC;IACf,OAAO,EAAE,WAAW,CAAC;CACtB;AAMD,MAAM,WAAW,QAAQ;IACvB,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,WAAW,CAAC;IACpB,IAAI,EAAE,WAAW,CAAC;CACnB;AAED,MAAM,WAAW,YAAY;IAC3B,KAAK,EAAE,QAAQ,EAAE,CAAC;CACnB;AAUD,MAAM,WAAW,cAAc;IAC7B,IAAI,EAAE,OAAO,CAAC,WAAW,CAAC,CAAC;IAC3B,EAAE,EAAE,OAAO,CAAC,WAAW,CAAC,CAAC;IACzB,QAAQ,EAAE,OAAO,CAAC,YAAY,CAAC,CAAC;CACjC;AAED,MAAM,WAAW,iBAAiB;IAChC,IAAI,EAAE,WAAW,CAAC;IAClB,EAAE,EAAE,WAAW,CAAC;IAChB,QAAQ,EAAE,YAAY,CAAC;IACvB,OAAO,EAAE,cAAc,CAAC;IACxB,YAAY,EAAE;QAAE,CAAC,EAAE,MAAM,CAAC;QAAC,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;IACvC,gBAAgB,EAAE,WAAW,CAAC;IAC9B,WAAW,EAAE,MAAM,CAAC;IACpB;;;;OAIG;IACH,UAAU,EAAE,CAAC,EAAE,EAAE,MAAM,IAAI,KAAK,IAAI,CAAC;CACtC;AAED;;;GAGG;AACH,MAAM,WAAW,YAAY;IAC3B,OAAO,CAAC,EAAE,CAAC,GAAG,EAAE,cAAc,KAAK,IAAI,CAAC;IACxC,UAAU,CAAC,EAAE,CAAC,GAAG,EAAE,iBAAiB,KAAK,SAAS,EAAE,CAAC;CACtD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"blur.d.ts","sourceRoot":"","sources":["../../../../src/lib/transitions/zoom/provider/blur.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,QAAQ,CAAC;AAC7C,OAAO,KAAK,EAEV,iBAAiB,EACjB,UAAU,EAEV,cAAc,EACd,YAAY,EACZ,YAAY,EACb,MAAM,UAAU,CAAC;AAClB,OAAO,
|
|
1
|
+
{"version":3,"file":"blur.d.ts","sourceRoot":"","sources":["../../../../src/lib/transitions/zoom/provider/blur.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,QAAQ,CAAC;AAC7C,OAAO,KAAK,EAEV,iBAAiB,EACjB,UAAU,EAEV,cAAc,EACd,YAAY,EACZ,YAAY,EACb,MAAM,UAAU,CAAC;AAClB,OAAO,EACL,SAAS,EAGV,MAAM,oBAAoB,CAAC;AAG5B,eAAO,MAAM,YAAY,EAAE,cAM1B,CAAC;AAmEF,qBAAa,sBAAuB,YAAW,YAAY;IACzD,QAAQ,CAAC,OAAO,iBAAgB;IAEhC,UAAU,CAAC,GAAG,EAAE,iBAAiB,GAAG,SAAS,EAAE;CAkBhD;AAQD,qBAAa,eAAgB,YAAW,YAAY;IAClD,OAAO,CAAC,GAAG,EAAE,cAAc,GAAG,OAAO,CAAC,UAAU,CAAC;IAQjD,UAAU,CAAC,GAAG,EAAE,iBAAiB,GAAG,SAAS,EAAE;CAWhD;AAMD,wBAAgB,kBAAkB,IAAI,YAAY,CASjD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"static.d.ts","sourceRoot":"","sources":["../../../../src/lib/transitions/zoom/provider/static.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,QAAQ,CAAC;AAC7C,OAAO,KAAK,EAEV,iBAAiB,EACjB,YAAY,EACZ,YAAY,EACb,MAAM,UAAU,CAAC;AAClB,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAG/C,eAAO,MAAM,cAAc,EAAE,
|
|
1
|
+
{"version":3,"file":"static.d.ts","sourceRoot":"","sources":["../../../../src/lib/transitions/zoom/provider/static.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,QAAQ,CAAC;AAC7C,OAAO,KAAK,EAEV,iBAAiB,EACjB,YAAY,EACZ,YAAY,EACb,MAAM,UAAU,CAAC;AAClB,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAG/C,eAAO,MAAM,cAAc,EAAE,cAM5B,CAAC;AAgBF,qBAAa,wBAAyB,YAAW,YAAY;IAC3D,QAAQ,CAAC,OAAO,iBAAkB;IAElC,UAAU,CAAC,IAAI,EAAE,iBAAiB,GAAG,SAAS,EAAE;CAGjD;AAMD,wBAAgB,oBAAoB,IAAI,YAAY,CAQnD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"transition.d.ts","sourceRoot":"","sources":["../../../src/lib/transitions/zoom/transition.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAkB,gBAAgB,EAAE,MAAM,QAAQ,CAAC;AAa/D,OAAO,KAAK,EACV,qBAAqB,EAGrB,UAAU,EAKX,MAAM,SAAS,CAAC;AAEjB,YAAY,EAAE,QAAQ,EAAE,WAAW,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"transition.d.ts","sourceRoot":"","sources":["../../../src/lib/transitions/zoom/transition.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAkB,gBAAgB,EAAE,MAAM,QAAQ,CAAC;AAa/D,OAAO,KAAK,EACV,qBAAqB,EAGrB,UAAU,EAKX,MAAM,SAAS,CAAC;AAEjB,YAAY,EAAE,QAAQ,EAAE,WAAW,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAC;AA4Q5E,eAAO,MAAM,IAAI,GACf,SAAS,qBAAqB,KAC7B,gBAAgB,CAAC,UAAU,CAmF7B,CAAC"}
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"y.d.ts","sourceRoot":"","sources":["../../../../src/lib/transitions/axis/provider/y.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAEV,YAAY,EAEb,MAAM,UAAU,CAAC;AAuClB,wBAAgB,eAAe,IAAI,YAAY,CAO9C"}
|