File tree Expand file tree Collapse file tree 2 files changed +25
-1
lines changed
packages/client/src/components Expand file tree Collapse file tree 2 files changed +25
-1
lines changed Original file line number Diff line number Diff line change @@ -74,6 +74,7 @@ export default defineConfig({
74
74
} ,
75
75
} )
76
76
} ,
77
+ experimentalRunAllSpecs : true ,
77
78
} ,
78
79
env : {
79
80
E2E_BASE : process . env . E2E_BASE ?? '/' ,
Original file line number Diff line number Diff line change @@ -23,6 +23,29 @@ const guardEvent = (event: MouseEvent): boolean | void => {
23
23
return true
24
24
}
25
25
26
+ export interface RouteLinkProps {
27
+ /**
28
+ * Whether the link is active to have an active class
29
+ *
30
+ * Notice that the active status is not automatically determined according to the current route.
31
+ *
32
+ * @default false
33
+ */
34
+ active ?: boolean
35
+
36
+ /**
37
+ * The class to add when the link is active
38
+ *
39
+ * @default 'route-link-active'
40
+ */
41
+ activeClass ?: string
42
+
43
+ /**
44
+ * The route path to link to
45
+ */
46
+ to : string
47
+ }
48
+
26
49
/**
27
50
* Component to render a link to another route.
28
51
*
@@ -80,7 +103,7 @@ export const RouteLink = defineComponent({
80
103
href : path . value ,
81
104
onClick : ( event : MouseEvent = { } as MouseEvent ) => {
82
105
if ( guardEvent ( event ) ) {
83
- router . push ( path . value ) . catch ( )
106
+ router . push ( props . to ) . catch ( )
84
107
}
85
108
} ,
86
109
} ,
You can’t perform that action at this time.
0 commit comments