@simonbackx/vue-app-navigation 2.5.2 → 2.6.0

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,66 +1,17 @@
1
1
  import { ComponentWithProperties } from './ComponentWithProperties';
2
+ import { Ref } from 'vue';
2
3
 
3
- declare const StackComponent: import('vue').DefineComponent<{}, {}, {
4
- components: ComponentWithProperties[];
5
- }, {}, {
6
- getCustomProvide(index: number, key: number): {
7
- reactive_navigation_pop: () => void;
8
- reactive_navigation_can_pop: boolean;
9
- reactive_navigation_dismiss: () => void;
10
- reactive_navigation_can_dismiss: boolean;
11
- reactive_navigation_focused: boolean;
12
- };
13
- show(component: ComponentWithProperties): void;
14
- getFocusedComponent(): {
15
- component: any;
16
- properties: Record<string, any>;
17
- provide: Record<string, any>;
18
- inheritedDisplayerProvide: Record<string, any>;
19
- inheritedParentProvide: Record<string, any>;
20
- key: number;
21
- type: string | null;
22
- vnode: import('vue').VNode<import('vue').RendererNode, import('vue').RendererElement, {
23
- [key: string]: any;
24
- }> | null;
25
- unmount: ((vnode: import('vue').VNode<import('vue').RendererNode, import('vue').RendererElement, {
26
- [key: string]: any;
27
- }>) => void) | null;
28
- keepAlive: boolean;
29
- isKeptAlive: boolean;
30
- modalDisplayStyle: import('./ComponentWithProperties').ModalDisplayStyle;
31
- animated: boolean;
32
- checkRoutes: boolean;
33
- isDismissing: boolean;
34
- historyIndex: number | null;
35
- setCheckRoutes: () => ComponentWithProperties;
36
- readonly combinedProvide: {
37
- [x: string]: any;
38
- };
39
- inheritFromDisplayer: (component: ComponentWithProperties) => void;
40
- inheritFromParent: (component: ComponentWithProperties) => void;
41
- clone: () => ComponentWithProperties;
42
- beforeMount: () => void;
43
- getHistoryIndex: () => number | null | undefined;
44
- deleteHistoryIndex: () => void;
45
- hasHistoryIndex: () => boolean;
46
- assignHistoryIndex: () => void;
47
- inheritHistoryIndex: (index: number) => void;
48
- ownsHistoryIndex: () => boolean;
49
- overrideUrl: (url: import('./HistoryManager.ts').HistoryUrl, title?: string | undefined) => void;
50
- setUrl: (url: import('./HistoryManager.ts').HistoryUrl, title?: string | undefined) => void;
51
- setTitle: (title: string) => void;
52
- returnToHistoryIndex: () => boolean;
53
- componentInstance: () => import('vue').ComponentPublicInstance | null;
54
- shouldNavigateAway: () => Promise<boolean>;
55
- destroy: (vnode: import('vue').VNode<import('vue').RendererNode, import('vue').RendererElement, {
56
- [key: string]: any;
57
- }>) => void;
58
- setDisplayStyle: (style: import('./ComponentWithProperties').ModalDisplayStyle) => ComponentWithProperties;
59
- setAnimated: (animated: boolean) => ComponentWithProperties;
60
- } | null;
61
- removeAt(index: number, key: number): void;
62
- }, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, ("present" | "returnToHistoryIndex")[], "present" | "returnToHistoryIndex", import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{}>> & {
63
- onPresent?: ((...args: any[]) => any) | undefined;
4
+ declare function removeAt(index: number, key: number): void;
5
+ declare function getFocusedComponent(): ComponentWithProperties | null;
6
+ declare function show(component: ComponentWithProperties): void;
7
+ declare const _default: import('vue').DefineComponent<{}, {
8
+ show: typeof show;
9
+ getFocusedComponent: typeof getFocusedComponent;
10
+ removeAt: typeof removeAt;
11
+ children: Ref<ComponentWithProperties[], ComponentWithProperties[]>;
12
+ }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
13
+ returnToHistoryIndex: (...args: any[]) => void;
14
+ }, string, import('vue').PublicProps, Readonly<{}> & Readonly<{
64
15
  onReturnToHistoryIndex?: ((...args: any[]) => any) | undefined;
65
- }, {}, {}>;
66
- export default StackComponent;
16
+ }>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
17
+ export default _default;
@@ -2,5 +2,5 @@ import { ComponentCustomProperties } from 'vue';
2
2
 
3
3
  export declare class VueComponent implements ComponentCustomProperties {
4
4
  constructor();
5
- __getter(object: any, key: any, proxy: any): any;
5
+ __getter(object: any, key: string | symbol, _proxy: any): any;
6
6
  }
@@ -71,7 +71,7 @@ export type OnCheckRoutesHandler = () => Promise<void> | void;
71
71
  export declare function onCheckRoutes(handler: OnCheckRoutesHandler): void;
72
72
  export declare function onNotCheckRoutes(handler: OnCheckRoutesHandler): void;
73
73
  export declare function defineRoutes(routes: (Route<any, undefined>[]) | (() => Promise<boolean | (Route<any, undefined>[])>)): void;
74
- export declare function useCurrentHref(): Ref<string>;
74
+ export declare function useCurrentHref(): Ref<string, string>;
75
75
  export declare function useCheckRoute(): <Params extends Record<string, unknown>>(prop1: string | Route<Params, unknown>, prop2?: RouteNavigationOptions<Params>) => boolean;
76
76
  export declare function normalizePushOptions(o: PushOptions | ComponentWithProperties, currentComponent: ComponentWithProperties | null, urlHelpers: ReturnType<typeof useUrl>): PushOptions;
77
77
  export declare function useShow(): (options: PushOptions | ComponentWithProperties) => Promise<void>;
@@ -96,6 +96,6 @@ export declare function useUrl(): {
96
96
  setTitle(title: string): void;
97
97
  extendUrl(url: string): string;
98
98
  match<Params>(template: string, params?: UrlParamsConstructors<Params>): UrlMatchResult<Params> | undefined;
99
- matchCurrent<Params_1>(template: string, params?: UrlParamsConstructors<Params_1> | undefined): UrlMatchResult<Params_1> | undefined;
99
+ matchCurrent<Params>(template: string, params?: UrlParamsConstructors<Params>): UrlMatchResult<Params> | undefined;
100
100
  overrideUrl(url: HistoryUrl, title?: string): void;
101
101
  };
@@ -0,0 +1,4 @@
1
+ import { default as ModalStackComponent } from '../ModalStackComponent.vue';
2
+ import { Ref } from 'vue';
3
+
4
+ export declare function useModalStackComponent(): Ref<InstanceType<typeof ModalStackComponent> | null>;
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@simonbackx/vue-app-navigation",
3
3
  "main": "./dist/index.js",
4
4
  "types": "./dist/index.d.ts",
5
- "version": "2.5.2",
5
+ "version": "2.6.0",
6
6
  "exports": {
7
7
  ".": {
8
8
  "import": "./dist/index.js",
@@ -36,22 +36,22 @@
36
36
  "@typescript-eslint/parser": "^7.7.1",
37
37
  "@vitejs/plugin-vue": "^5.0.4",
38
38
  "@vue/eslint-config-typescript": "^13.0.0",
39
- "@vue/runtime-core": "^3.4.25",
39
+ "@vue/runtime-core": "^3.5.12",
40
40
  "eslint": "^8",
41
41
  "eslint-plugin-simple-import-sort": "^12.1.0",
42
42
  "eslint-plugin-vue": "^9.25.0",
43
43
  "sass": "^1.32.4",
44
44
  "tslib": "^2.6.2",
45
- "typescript": "^5.4.5",
45
+ "typescript": "^5.6.2",
46
46
  "typescript-eslint": "^7.7.1",
47
47
  "vite": "^5.2.10",
48
48
  "vite-plugin-dts": "^3.9.0",
49
- "vue": "^3.4.25"
49
+ "vue": "^3.5.12"
50
50
  },
51
51
  "peerDependencies": {
52
- "vue": "^3.4.25"
52
+ "vue": "^3.5.12"
53
53
  },
54
54
  "dependencies": {
55
- "@vue/shared": "^3.4.25"
55
+ "@vue/shared": "^3.5.12"
56
56
  }
57
57
  }