create-middag-ui 0.15.1 → 0.15.3

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/lib/scaffold.js CHANGED
@@ -1011,10 +1011,12 @@ const sharedProps = {
1011
1011
 
1012
1012
  function buildNavigation(activeKey: string) {
1013
1013
  return {
1014
- sections: [
1015
- { key: "overview", label: "Overview", icon: "home", group: "main" as const, items: [{ key: "overview.dashboard", label: "Dashboard", href: "/", active: activeKey === "overview.dashboard", children: [] }] },
1016
- { key: "integration", label: "Integration", icon: "plug", group: "main" as const, items: [{ key: "integration.connectors", label: "Connectors", href: "/connectors", active: activeKey === "integration.connectors", children: [] }] },
1017
- { key: "system", label: "System", icon: "settings", group: "system" as const, items: [{ key: "system.settings", label: "Settings", href: "/settings", active: activeKey === "system.settings", children: [] }] },
1014
+ tree: [
1015
+ { key: "overview.dashboard", label: "Dashboard", icon: "home", href: "/", children: [] },
1016
+ { key: "integration.connectors", label: "Connectors", icon: "plug", href: "/connectors", children: [] },
1017
+ ],
1018
+ footer: [
1019
+ { key: "system.settings", label: "Settings", icon: "settings", href: "/settings", children: [] },
1018
1020
  ],
1019
1021
  activeKey,
1020
1022
  };
@@ -1258,10 +1260,12 @@ const sharedProps = {
1258
1260
 
1259
1261
  function buildNavigation(activeKey: string) {
1260
1262
  return {
1261
- sections: [
1262
- { key: "overview", label: "Overview", icon: "home", group: "main" as const, items: [{ key: "overview.dashboard", label: "Dashboard", href: "/", active: activeKey === "overview.dashboard", children: [] }] },
1263
- { key: "integration", label: "Integration", icon: "plug", group: "main" as const, items: [{ key: "integration.connectors", label: "Connectors", href: "/connectors", active: activeKey === "integration.connectors", children: [] }] },
1264
- { key: "system", label: "System", icon: "settings", group: "system" as const, items: [{ key: "system.settings", label: "Settings", href: "/settings", active: activeKey === "system.settings", children: [] }] },
1263
+ tree: [
1264
+ { key: "overview.dashboard", label: "Dashboard", icon: "home", href: "/", children: [] },
1265
+ { key: "integration.connectors", label: "Connectors", icon: "plug", href: "/connectors", children: [] },
1266
+ ],
1267
+ footer: [
1268
+ { key: "system.settings", label: "Settings", icon: "settings", href: "/settings", children: [] },
1265
1269
  ],
1266
1270
  activeKey,
1267
1271
  };
@@ -7,51 +7,29 @@
7
7
 
8
8
  export function buildNavigation(activeKey: string) {
9
9
  return {
10
- sections: [
10
+ tree: [
11
11
  {
12
- key: "overview",
13
- label: "Overview",
12
+ key: "overview.dashboard",
13
+ label: "Dashboard",
14
14
  icon: "home",
15
- group: "main" as const,
16
- items: [
17
- {
18
- key: "overview.dashboard",
19
- label: "Dashboard",
20
- href: "/",
21
- active: activeKey === "overview.dashboard",
22
- children: [],
23
- },
24
- ],
15
+ href: "/",
16
+ children: [],
25
17
  },
26
18
  {
27
- key: "integration",
28
- label: "Integration",
19
+ key: "integration.connectors",
20
+ label: "Connectors",
29
21
  icon: "plug",
30
- group: "main" as const,
31
- items: [
32
- {
33
- key: "integration.connectors",
34
- label: "Connectors",
35
- href: "/connectors",
36
- active: activeKey === "integration.connectors",
37
- children: [],
38
- },
39
- ],
22
+ href: "/connectors",
23
+ children: [],
40
24
  },
25
+ ],
26
+ footer: [
41
27
  {
42
- key: "system",
43
- label: "System",
28
+ key: "system.settings",
29
+ label: "Settings",
44
30
  icon: "settings",
45
- group: "system" as const,
46
- items: [
47
- {
48
- key: "system.settings",
49
- label: "Settings",
50
- href: "/settings",
51
- active: activeKey === "system.settings",
52
- children: [],
53
- },
54
- ],
31
+ href: "/settings",
32
+ children: [],
55
33
  },
56
34
  ],
57
35
  activeKey,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-middag-ui",
3
- "version": "0.15.1",
3
+ "version": "0.15.3",
4
4
  "type": "module",
5
5
  "description": "Bootstrap a MIDDAG React UI layer in your Moodle or WordPress plugin",
6
6
  "bin": {