@modelmenu/navigation 1.0.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.
- package/README.MD +66 -0
- package/dist/index.es.js +4430 -0
- package/dist/index.umd.js +568 -0
- package/menu/MenuPlate.vue +523 -0
- package/menu/components/menu-item.vue +226 -0
- package/menu/components/sub-menu-items.vue +123 -0
- package/menu/components/top-menu-items/top-menu-item.vue +142 -0
- package/menu/components/top-menu-items/top-sub-menu-items.vue +113 -0
- package/menu/index.d.ts +2 -0
- package/menu/index.ts +2 -0
- package/menu/models/menu-models.ts +49 -0
- package/menu/resources/theme.ts +42 -0
- package/menu/routing/routing.ts +43 -0
- package/package.json +50 -0
- package/tsconfig.json +55 -0
- package/vite.config.ts +25 -0
- package/vue.config.js +30 -0
package/README.MD
ADDED
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
@modelmenu/navigation
|
|
2
|
+
|
|
3
|
+
#Install
|
|
4
|
+
|
|
5
|
+
```bash
|
|
6
|
+
pnpm add @modelmenu/navigation
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
#Quick start
|
|
10
|
+
|
|
11
|
+
1. Create Your MenuNavigation
|
|
12
|
+
|
|
13
|
+
```ts
|
|
14
|
+
import { LeftMenuModel, MenuItemModel, ThemeModel } from '@modelmenu/navigation';
|
|
15
|
+
|
|
16
|
+
const leftItems = [
|
|
17
|
+
[
|
|
18
|
+
name: "Home",
|
|
19
|
+
route: "/",
|
|
20
|
+
items: [
|
|
21
|
+
{
|
|
22
|
+
"Products",
|
|
23
|
+
route: "/products"
|
|
24
|
+
}
|
|
25
|
+
]
|
|
26
|
+
]
|
|
27
|
+
]
|
|
28
|
+
|
|
29
|
+
let topItems = new MenuModel();
|
|
30
|
+
topItems.push({
|
|
31
|
+
name: "Test",
|
|
32
|
+
route: "/test"
|
|
33
|
+
})
|
|
34
|
+
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
2. Import menu plate
|
|
38
|
+
|
|
39
|
+
```ts
|
|
40
|
+
<script setup lang="ts">
|
|
41
|
+
import { MenuPlate } from '@modelmenu/navigation'
|
|
42
|
+
|
|
43
|
+
</script>
|
|
44
|
+
|
|
45
|
+
<template>
|
|
46
|
+
<MenuPlate :leftItems="leftItems" :Router="router" :topItems="topItems">
|
|
47
|
+
<template #handler>
|
|
48
|
+
<RouterView></RouterView>
|
|
49
|
+
</template>
|
|
50
|
+
</MenuPlate>
|
|
51
|
+
</template>
|
|
52
|
+
```
|
|
53
|
+
Documentation
|
|
54
|
+
|
|
55
|
+
MenuNavigation is divided in two sections main items from left side and top items at upper section of component template.
|
|
56
|
+
Main Event is changeTheme from our collection.
|
|
57
|
+
-primary
|
|
58
|
+
-secondary
|
|
59
|
+
-basic
|
|
60
|
+
-light
|
|
61
|
+
-dark
|
|
62
|
+
|
|
63
|
+
License
|
|
64
|
+
MIT
|
|
65
|
+
|
|
66
|
+
|