@nvent-addon/app 0.5.14 → 1.0.0-alpha.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.
Files changed (95) hide show
  1. package/dist/module.json +1 -1
  2. package/dist/module.mjs +3 -2
  3. package/dist/runtime/app/components/DashboardCard.d.vue.ts +1 -1
  4. package/dist/runtime/app/components/DashboardCard.vue.d.ts +1 -1
  5. package/dist/runtime/app/composables/useWorkers.d.ts +57 -0
  6. package/dist/runtime/app/composables/useWorkers.js +42 -0
  7. package/dist/runtime/app/pages/dashboard.vue +1 -654
  8. package/dist/runtime/app/pages/index.vue +25 -41
  9. package/dist/runtime/app/pages/workers.vue +458 -0
  10. package/dist/runtime/server/api/_workers/index.get.d.ts +8 -0
  11. package/dist/runtime/server/api/_workers/index.get.js +14 -0
  12. package/package.json +12 -11
  13. package/dist/runtime/app/components/ComponentRouter.d.vue.ts +0 -46
  14. package/dist/runtime/app/components/ComponentRouter.vue +0 -26
  15. package/dist/runtime/app/components/ComponentRouter.vue.d.ts +0 -46
  16. package/dist/runtime/app/components/ComponentShell.d.vue.ts +0 -23
  17. package/dist/runtime/app/components/ComponentShell.vue +0 -97
  18. package/dist/runtime/app/components/ComponentShell.vue.d.ts +0 -23
  19. package/dist/runtime/app/components/ConfirmDialog.d.vue.ts +0 -33
  20. package/dist/runtime/app/components/ConfirmDialog.vue +0 -120
  21. package/dist/runtime/app/components/ConfirmDialog.vue.d.ts +0 -33
  22. package/dist/runtime/app/composables/useComponentRouter.d.ts +0 -46
  23. package/dist/runtime/app/composables/useComponentRouter.js +0 -248
  24. package/dist/runtime/app/pages/flows/[name].vue +0 -750
  25. package/dist/runtime/app/pages/flows/index.d.vue.ts +0 -3
  26. package/dist/runtime/app/pages/flows/index.vue +0 -381
  27. package/dist/runtime/app/pages/flows/index.vue.d.ts +0 -3
  28. package/dist/runtime/app/pages/queues/index.d.vue.ts +0 -3
  29. package/dist/runtime/app/pages/queues/index.vue +0 -236
  30. package/dist/runtime/app/pages/queues/index.vue.d.ts +0 -3
  31. package/dist/runtime/app/pages/queues/job.d.vue.ts +0 -3
  32. package/dist/runtime/app/pages/queues/job.vue +0 -261
  33. package/dist/runtime/app/pages/queues/job.vue.d.ts +0 -3
  34. package/dist/runtime/app/pages/queues/jobs.d.vue.ts +0 -3
  35. package/dist/runtime/app/pages/queues/jobs.vue +0 -595
  36. package/dist/runtime/app/pages/queues/jobs.vue.d.ts +0 -3
  37. package/dist/runtime/app/pages/settings/scheduler.d.vue.ts +0 -3
  38. package/dist/runtime/app/pages/settings/scheduler.vue +0 -310
  39. package/dist/runtime/app/pages/settings/scheduler.vue.d.ts +0 -3
  40. package/dist/runtime/app/pages/triggers/[name]/edit.d.vue.ts +0 -3
  41. package/dist/runtime/app/pages/triggers/[name]/edit.vue +0 -429
  42. package/dist/runtime/app/pages/triggers/[name]/edit.vue.d.ts +0 -3
  43. package/dist/runtime/app/pages/triggers/[name].d.vue.ts +0 -3
  44. package/dist/runtime/app/pages/triggers/[name].vue +0 -870
  45. package/dist/runtime/app/pages/triggers/[name].vue.d.ts +0 -3
  46. package/dist/runtime/app/pages/triggers/index.d.vue.ts +0 -3
  47. package/dist/runtime/app/pages/triggers/index.vue +0 -525
  48. package/dist/runtime/app/pages/triggers/index.vue.d.ts +0 -3
  49. package/dist/runtime/app/pages/triggers/new.d.vue.ts +0 -3
  50. package/dist/runtime/app/pages/triggers/new.vue +0 -610
  51. package/dist/runtime/app/pages/triggers/new.vue.d.ts +0 -3
  52. package/dist/runtime/server/api/_flows/[name]/clear-history.delete.d.ts +0 -10
  53. package/dist/runtime/server/api/_flows/[name]/clear-history.delete.js +0 -49
  54. package/dist/runtime/server/api/_flows/[name]/runs/[runId]/cancel.post.d.ts +0 -2
  55. package/dist/runtime/server/api/_flows/[name]/runs/[runId]/cancel.post.js +0 -21
  56. package/dist/runtime/server/api/_flows/[name]/runs/[runId]/restart.post.d.ts +0 -2
  57. package/dist/runtime/server/api/_flows/[name]/runs/[runId]/restart.post.js +0 -21
  58. package/dist/runtime/server/api/_flows/[name]/runs.get.d.ts +0 -17
  59. package/dist/runtime/server/api/_flows/[name]/runs.get.js +0 -64
  60. package/dist/runtime/server/api/_flows/[name]/start.post.d.ts +0 -2
  61. package/dist/runtime/server/api/_flows/[name]/start.post.js +0 -9
  62. package/dist/runtime/server/api/_flows/index.get.d.ts +0 -7
  63. package/dist/runtime/server/api/_flows/index.get.js +0 -5
  64. package/dist/runtime/server/api/_flows/recent-runs.get.d.ts +0 -15
  65. package/dist/runtime/server/api/_flows/recent-runs.get.js +0 -67
  66. package/dist/runtime/server/api/_flows/ws.d.ts +0 -80
  67. package/dist/runtime/server/api/_flows/ws.js +0 -309
  68. package/dist/runtime/server/api/_queues/[name]/job/[id].get.d.ts +0 -2
  69. package/dist/runtime/server/api/_queues/[name]/job/[id].get.js +0 -14
  70. package/dist/runtime/server/api/_queues/[name]/job/index.get.d.ts +0 -2
  71. package/dist/runtime/server/api/_queues/[name]/job/index.get.js +0 -39
  72. package/dist/runtime/server/api/_queues/index.get.d.ts +0 -2
  73. package/dist/runtime/server/api/_queues/index.get.js +0 -106
  74. package/dist/runtime/server/api/_queues/ws.d.ts +0 -48
  75. package/dist/runtime/server/api/_queues/ws.js +0 -215
  76. package/dist/runtime/server/api/_scheduler/jobs.get.d.ts +0 -19
  77. package/dist/runtime/server/api/_scheduler/jobs.get.js +0 -36
  78. package/dist/runtime/server/api/_triggers/[name]/events.get.d.ts +0 -6
  79. package/dist/runtime/server/api/_triggers/[name]/events.get.js +0 -43
  80. package/dist/runtime/server/api/_triggers/[name]/index.get.d.ts +0 -6
  81. package/dist/runtime/server/api/_triggers/[name]/index.get.js +0 -76
  82. package/dist/runtime/server/api/_triggers/[name].delete.d.ts +0 -7
  83. package/dist/runtime/server/api/_triggers/[name].delete.js +0 -37
  84. package/dist/runtime/server/api/_triggers/[name].patch.d.ts +0 -7
  85. package/dist/runtime/server/api/_triggers/[name].patch.js +0 -117
  86. package/dist/runtime/server/api/_triggers/index.get.d.ts +0 -6
  87. package/dist/runtime/server/api/_triggers/index.get.js +0 -44
  88. package/dist/runtime/server/api/_triggers/index.post.d.ts +0 -7
  89. package/dist/runtime/server/api/_triggers/index.post.js +0 -124
  90. package/dist/runtime/server/api/_triggers/stats.get.d.ts +0 -6
  91. package/dist/runtime/server/api/_triggers/stats.get.js +0 -41
  92. package/dist/runtime/server/api/_triggers/ws.d.ts +0 -74
  93. package/dist/runtime/server/api/_triggers/ws.js +0 -315
  94. /package/dist/runtime/app/pages/{flows/[name].d.vue.ts → workers.d.vue.ts} +0 -0
  95. /package/dist/runtime/app/pages/{flows/[name].vue.d.ts → workers.vue.d.ts} +0 -0
@@ -1,26 +0,0 @@
1
- <template>
2
- <slot
3
- :component="component"
4
- :route="route"
5
- :push="push"
6
- />
7
- </template>
8
-
9
- <script setup>
10
- import { useComponentRouter } from "#imports";
11
- const props = defineProps({
12
- routes: { type: [Array, Object], required: true },
13
- base: { type: String, required: false, default: "fp" },
14
- mode: { type: String, required: false, default: "query" },
15
- initial: { type: String, required: false },
16
- debug: { type: Boolean, required: false, default: false }
17
- });
18
- const { component, route, push, replace } = useComponentRouter({
19
- routes: props.routes,
20
- base: props.base,
21
- mode: props.mode,
22
- initial: props.initial,
23
- debug: props.debug
24
- });
25
- defineExpose({ push, replace, route });
26
- </script>
@@ -1,46 +0,0 @@
1
- type ComponentRouteRecord = {
2
- path: string;
3
- component: any;
4
- name?: string;
5
- };
6
- type ComponentRouterMode = 'query' | 'hash' | 'memory';
7
- type __VLS_Props = {
8
- routes: ComponentRouteRecord[] | Record<string, any>;
9
- base?: string;
10
- mode?: ComponentRouterMode;
11
- initial?: string;
12
- debug?: boolean;
13
- };
14
- declare var __VLS_1: {
15
- component: any;
16
- route: any;
17
- push: any;
18
- };
19
- type __VLS_Slots = {} & {
20
- default?: (props: typeof __VLS_1) => any;
21
- };
22
- declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {
23
- push: (path: string) => Promise<void>;
24
- replace: (path: string) => Promise<void>;
25
- route: import("vue").ShallowRef<{
26
- path: string;
27
- params: Record<string, string>;
28
- query: Record<string, any>;
29
- } | undefined, {
30
- path: string;
31
- params: Record<string, string>;
32
- query: Record<string, any>;
33
- } | undefined>;
34
- }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
35
- mode: ComponentRouterMode;
36
- base: string;
37
- debug: boolean;
38
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
39
- declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
40
- declare const _default: typeof __VLS_export;
41
- export default _default;
42
- type __VLS_WithSlots<T, S> = T & {
43
- new (): {
44
- $slots: S;
45
- };
46
- };
@@ -1,23 +0,0 @@
1
- import type { NavigationMenuItem } from '@nuxt/ui';
2
- type __VLS_Props = {
3
- orientation?: 'horizontal' | 'vertical';
4
- items?: NavigationMenuItem[][];
5
- activeMatch?: 'exact' | 'prefix';
6
- fullPage?: boolean;
7
- };
8
- declare var __VLS_6: {};
9
- type __VLS_Slots = {} & {
10
- default?: (props: typeof __VLS_6) => any;
11
- };
12
- declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
13
- orientation: "horizontal" | "vertical";
14
- activeMatch: "exact" | "prefix";
15
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
16
- declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
17
- declare const _default: typeof __VLS_export;
18
- export default _default;
19
- type __VLS_WithSlots<T, S> = T & {
20
- new (): {
21
- $slots: S;
22
- };
23
- };
@@ -1,97 +0,0 @@
1
- <template>
2
- <section class="h-full">
3
- <!-- Layout container switches between column (horizontal nav top) and row (vertical nav left) -->
4
- <div
5
- :class="
6
- orientation === 'vertical' ? 'flex h-full' : 'flex flex-col w-full'
7
- "
8
- :style="containerStyle"
9
- >
10
- <!-- Navigation using UNavigationMenu -->
11
- <div
12
- :class="[
13
- 'border-gray-200',
14
- orientation === 'vertical' ? 'min-w-[256px] border-r' : 'border-b'
15
- ]"
16
- >
17
- <UNavigationMenu
18
- :items="navigationItems"
19
- :orientation="orientation"
20
- content-orientation="vertical"
21
- :class="orientation === 'horizontal' ? 'px-4' : ''"
22
- />
23
- </div>
24
-
25
- <!-- Main Content -->
26
- <div
27
- class="flex-1 min-h-0 overflow-hidden"
28
- >
29
- <slot />
30
- </div>
31
- </div>
32
- </section>
33
- </template>
34
-
35
- <script setup>
36
- import { computed } from "vue";
37
- import { useComponentRouter, useRoute, useRuntimeConfig } from "#imports";
38
- const props = defineProps({
39
- orientation: { type: String, required: false, default: "horizontal" },
40
- items: { type: Array, required: false },
41
- activeMatch: { type: String, required: false, default: "prefix" },
42
- fullPage: { type: Boolean, required: false }
43
- });
44
- const router = useComponentRouter();
45
- const nuxtRoute = useRoute();
46
- const config = useRuntimeConfig();
47
- const isFullPage = computed(() => {
48
- const nventPath = config.public.nventapp?.routePath || "/_nvent";
49
- return nuxtRoute?.path?.startsWith(nventPath) ?? false;
50
- });
51
- const containerStyle = computed(() => {
52
- return isFullPage.value ? "height: 100vh" : "height: calc(100vh - 4rem)";
53
- });
54
- const navigationItems = computed(() => {
55
- if (!props.items) return [];
56
- const transformItem = (item) => {
57
- const path = item.path;
58
- const transformed = {
59
- ...item,
60
- onSelect: (e) => {
61
- e.preventDefault();
62
- if (path) {
63
- router.push(path);
64
- }
65
- if (item.onSelect) {
66
- item.onSelect(e);
67
- }
68
- },
69
- active: path ? isActive(path) : item.active
70
- };
71
- if (item.children) {
72
- if (Array.isArray(item.children[0]) && Array.isArray(item.children[0][0])) {
73
- transformed.children = item.children.map(
74
- (childGroup) => childGroup.map(transformItem)
75
- );
76
- } else {
77
- transformed.children = item.children.map(transformItem);
78
- }
79
- }
80
- return transformed;
81
- };
82
- return props.items.map(
83
- (group) => group.map(transformItem)
84
- );
85
- });
86
- function isActive(path) {
87
- if (!path) return false;
88
- const current = router.route?.value?.path || "";
89
- if (props.activeMatch === "prefix") return isPrefixActive(current, path);
90
- return current === path;
91
- }
92
- function isPrefixActive(current, base) {
93
- if (base === "/") return current === "/";
94
- if (current === base) return true;
95
- return current.startsWith(base.endsWith("/") ? base : base + "/");
96
- }
97
- </script>
@@ -1,23 +0,0 @@
1
- import type { NavigationMenuItem } from '@nuxt/ui';
2
- type __VLS_Props = {
3
- orientation?: 'horizontal' | 'vertical';
4
- items?: NavigationMenuItem[][];
5
- activeMatch?: 'exact' | 'prefix';
6
- fullPage?: boolean;
7
- };
8
- declare var __VLS_6: {};
9
- type __VLS_Slots = {} & {
10
- default?: (props: typeof __VLS_6) => any;
11
- };
12
- declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
13
- orientation: "horizontal" | "vertical";
14
- activeMatch: "exact" | "prefix";
15
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
16
- declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
17
- declare const _default: typeof __VLS_export;
18
- export default _default;
19
- type __VLS_WithSlots<T, S> = T & {
20
- new (): {
21
- $slots: S;
22
- };
23
- };
@@ -1,33 +0,0 @@
1
- interface Props {
2
- title: string;
3
- description?: string;
4
- items?: string[];
5
- warning?: string;
6
- confirmLabel?: string;
7
- cancelLabel?: string;
8
- confirmColor?: 'primary' | 'error' | 'warning' | 'success';
9
- icon?: string;
10
- iconColor?: 'primary' | 'error' | 'warning' | 'success' | 'info';
11
- loading?: boolean;
12
- }
13
- type __VLS_Props = Props;
14
- type __VLS_ModelProps = {
15
- 'open'?: boolean;
16
- };
17
- type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
18
- declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
19
- cancel: () => any;
20
- confirm: () => any;
21
- "update:open": (value: boolean) => any;
22
- }, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
23
- onCancel?: (() => any) | undefined;
24
- onConfirm?: (() => any) | undefined;
25
- "onUpdate:open"?: ((value: boolean) => any) | undefined;
26
- }>, {
27
- confirmLabel: string;
28
- cancelLabel: string;
29
- confirmColor: "primary" | "error" | "warning" | "success";
30
- iconColor: "primary" | "error" | "warning" | "success" | "info";
31
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
32
- declare const _default: typeof __VLS_export;
33
- export default _default;
@@ -1,120 +0,0 @@
1
- <template>
2
- <UModal
3
- v-model:open="isOpen"
4
- :ui="{
5
- content: 'max-w-md'
6
- }"
7
- >
8
- <template #header>
9
- <div class="flex items-start gap-3">
10
- <div
11
- v-if="icon"
12
- class="shrink-0 rounded-full p-2"
13
- :class="iconColorClasses"
14
- >
15
- <UIcon
16
- :name="icon"
17
- class="size-5"
18
- />
19
- </div>
20
- <div class="flex-1 min-w-0">
21
- <h3 class="text-base font-semibold text-gray-900 dark:text-gray-100">
22
- {{ title }}
23
- </h3>
24
- </div>
25
- </div>
26
- </template>
27
-
28
- <template #body>
29
- <div class="space-y-3">
30
- <p
31
- v-if="description"
32
- class="text-sm text-gray-600 dark:text-gray-400"
33
- >
34
- {{ description }}
35
- </p>
36
- <ul
37
- v-if="items && items.length > 0"
38
- class="space-y-2 text-sm text-gray-600 dark:text-gray-400"
39
- >
40
- <li
41
- v-for="(item, index) in items"
42
- :key="index"
43
- class="flex items-start gap-2"
44
- >
45
- <UIcon
46
- name="i-lucide-circle"
47
- class="size-1.5 mt-1.5 shrink-0"
48
- />
49
- <span>{{ item }}</span>
50
- </li>
51
- </ul>
52
- <p
53
- v-if="warning"
54
- class="text-sm font-medium text-amber-600 dark:text-amber-400"
55
- >
56
- {{ warning }}
57
- </p>
58
- </div>
59
- </template>
60
-
61
- <template #footer>
62
- <div class="flex justify-end gap-2">
63
- <UButton
64
- color="neutral"
65
- variant="ghost"
66
- :disabled="loading"
67
- @click="handleCancel"
68
- >
69
- {{ cancelLabel }}
70
- </UButton>
71
- <UButton
72
- :color="confirmColor"
73
- :loading="loading"
74
- @click="handleConfirm"
75
- >
76
- {{ confirmLabel }}
77
- </UButton>
78
- </div>
79
- </template>
80
- </UModal>
81
- </template>
82
-
83
- <script setup>
84
- import { computed } from "#imports";
85
- const props = defineProps({
86
- title: { type: String, required: true },
87
- description: { type: String, required: false },
88
- items: { type: Array, required: false },
89
- warning: { type: String, required: false },
90
- confirmLabel: { type: String, required: false, default: "Confirm" },
91
- cancelLabel: { type: String, required: false, default: "Cancel" },
92
- confirmColor: { type: String, required: false, default: "primary" },
93
- icon: { type: String, required: false },
94
- iconColor: { type: String, required: false, default: "primary" },
95
- loading: { type: Boolean, required: false }
96
- });
97
- const isOpen = defineModel("open", { type: Boolean, ...{ default: false } });
98
- const emit = defineEmits(["confirm", "cancel"]);
99
- const iconColorClasses = computed(() => {
100
- switch (props.iconColor) {
101
- case "error":
102
- return "bg-red-50 dark:bg-red-950/50 text-red-600 dark:text-red-400";
103
- case "warning":
104
- return "bg-amber-50 dark:bg-amber-950/50 text-amber-600 dark:text-amber-400";
105
- case "success":
106
- return "bg-emerald-50 dark:bg-emerald-950/50 text-emerald-600 dark:text-emerald-400";
107
- case "info":
108
- return "bg-blue-50 dark:bg-blue-950/50 text-blue-600 dark:text-blue-400";
109
- default:
110
- return "bg-primary-50 dark:bg-primary-950/50 text-primary-600 dark:text-primary-400";
111
- }
112
- });
113
- const handleConfirm = () => {
114
- emit("confirm");
115
- };
116
- const handleCancel = () => {
117
- isOpen.value = false;
118
- emit("cancel");
119
- };
120
- </script>
@@ -1,33 +0,0 @@
1
- interface Props {
2
- title: string;
3
- description?: string;
4
- items?: string[];
5
- warning?: string;
6
- confirmLabel?: string;
7
- cancelLabel?: string;
8
- confirmColor?: 'primary' | 'error' | 'warning' | 'success';
9
- icon?: string;
10
- iconColor?: 'primary' | 'error' | 'warning' | 'success' | 'info';
11
- loading?: boolean;
12
- }
13
- type __VLS_Props = Props;
14
- type __VLS_ModelProps = {
15
- 'open'?: boolean;
16
- };
17
- type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
18
- declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
19
- cancel: () => any;
20
- confirm: () => any;
21
- "update:open": (value: boolean) => any;
22
- }, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
23
- onCancel?: (() => any) | undefined;
24
- onConfirm?: (() => any) | undefined;
25
- "onUpdate:open"?: ((value: boolean) => any) | undefined;
26
- }>, {
27
- confirmLabel: string;
28
- cancelLabel: string;
29
- confirmColor: "primary" | "error" | "warning" | "success";
30
- iconColor: "primary" | "error" | "warning" | "success" | "info";
31
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
32
- declare const _default: typeof __VLS_export;
33
- export default _default;
@@ -1,46 +0,0 @@
1
- import { shallowRef } from '#imports';
2
- import { createHooks } from 'hookable';
3
- export type ComponentRouteRecord = {
4
- path: string;
5
- component: any;
6
- name?: string;
7
- };
8
- export type ComponentRouterMode = 'query' | 'hash' | 'memory';
9
- export interface UseComponentRouterOptions {
10
- routes: ComponentRouteRecord[] | Record<string, any>;
11
- base?: string;
12
- mode?: ComponentRouterMode;
13
- initial?: string;
14
- provideKey?: string;
15
- debug?: boolean;
16
- }
17
- type RouterHooks = {
18
- navigated: (data: {
19
- path: string;
20
- params: Record<string, string>;
21
- }) => void;
22
- };
23
- type RouterContext = {
24
- route: ReturnType<typeof shallowRef<{
25
- path: string;
26
- params: Record<string, string>;
27
- query: Record<string, any>;
28
- }>>;
29
- push: (path: string) => Promise<void>;
30
- replace: (path: string) => Promise<void>;
31
- makePath: (patternOrPath: string, params?: Record<string, any>) => string;
32
- makeHref: (patternOrPath: string, params?: Record<string, any>) => string;
33
- pushTo: (patternOrPath: string, params?: Record<string, any>) => Promise<void>;
34
- replaceTo: (patternOrPath: string, params?: Record<string, any>) => Promise<void>;
35
- hooks: ReturnType<typeof createHooks<RouterHooks>>;
36
- };
37
- export declare function useComponentRouter(): RouterContext & {
38
- component?: any;
39
- };
40
- export declare function useComponentRouter(opts: UseComponentRouterOptions): RouterContext & {
41
- component: any;
42
- };
43
- export default useComponentRouter;
44
- export declare function createComponentRoutes(glob: Record<string, () => Promise<any>>, options?: {
45
- base?: string;
46
- }): ComponentRouteRecord[];