@nemigo/layout 2.4.0 → 2.5.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.
@@ -1,11 +1,11 @@
1
1
  <script lang="ts">import { delay } from "@nemigo/helpers/async";
2
- import { Navigation } from "@nemigo/svelte/kit/navigation";
2
+ import { Navigation as NavigationController } from "@nemigo/svelte/kit/navigation";
3
3
  import { linear } from "svelte/easing";
4
4
  import { blur } from "svelte/transition";
5
- const { class: className, duration = 290, handler, children } = $props();
6
- const __navigation = Navigation.default(handler).hydrate();
5
+ const { class: className, duration = 290, controller, handler, children } = $props();
6
+ const __controller = controller ?? NavigationController.default(handler).hydrate();
7
7
  let animate = $state(false);
8
- const show = $derived(!__navigation.state.signal && !animate);
8
+ const show = $derived(!__controller.state.signal && !animate);
9
9
  const stepper = {
10
10
  in: {
11
11
  get duration() {
@@ -1,5 +1,5 @@
1
1
  import type { NavigationHandler } from "@nemigo/svelte/kit/navigation";
2
- import { Navigation } from "@nemigo/svelte/kit/navigation";
2
+ import { Navigation as NavigationController } from "@nemigo/svelte/kit/navigation";
3
3
  import type { Snippet } from "svelte";
4
4
  import type { ClassValue } from "svelte/elements";
5
5
  interface Props {
@@ -8,6 +8,7 @@ interface Props {
8
8
  * @default 290
9
9
  */
10
10
  duration?: number;
11
+ controller?: NavigationController;
11
12
  handler?: NavigationHandler;
12
13
  children: Snippet;
13
14
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nemigo/layout",
3
- "version": "2.4.0",
3
+ "version": "2.5.1",
4
4
  "private": false,
5
5
  "license": "MPL-2.0",
6
6
  "author": {
@@ -51,8 +51,8 @@
51
51
  }
52
52
  },
53
53
  "devDependencies": {
54
- "@nemigo/configs": "2.4.0",
55
- "@nemigo/helpers": "2.4.0",
56
- "@nemigo/svelte": "2.4.0"
54
+ "@nemigo/configs": "2.5.0",
55
+ "@nemigo/helpers": "2.5.0",
56
+ "@nemigo/svelte": "2.5.0"
57
57
  }
58
58
  }