@starasia/admin 14.30.0 → 14.31.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.
@@ -63,3 +63,47 @@ export interface SidebarMenuGroup {
63
63
  slotKey?: string;
64
64
  }
65
65
  export type SidebarMenus = SidebarMenuGroup[];
66
+ /**
67
+ * Item di rail navigasi (kolom ikon paling kiri, di samping panel sidebar).
68
+ * Rail sengaja generik — DS tidak tahu "kategori"; consumer yang memetakan
69
+ * taksonominya sendiri ke `groupIds`.
70
+ */
71
+ export interface SidebarRailItem {
72
+ /** Id unik item rail. */
73
+ key: string;
74
+ icon: IconName;
75
+ /** Label di bawah ikon. Buat pendek (±8 karakter) — sisanya di-ellipsis + tooltip. */
76
+ label: string;
77
+ /**
78
+ * Group (`SidebarMenuGroup.id`) yang tampil di panel saat item ini aktif.
79
+ * Group anak (`parentGroupId` ada di sini) ikut tampil.
80
+ * Kosongkan untuk item "semua" (mis. Home) — panel menampilkan semua group.
81
+ */
82
+ groupIds?: number[];
83
+ badge?: SidebarBadge;
84
+ }
85
+ /** Item aksi di bagian bawah rail (mis. "Apps", "Help") — tidak memfilter panel. */
86
+ export interface SidebarRailAction {
87
+ key: string;
88
+ icon: IconName;
89
+ label: string;
90
+ /** Navigasi ke route ini saat diklik. Diabaikan kalau `onClick` diisi. */
91
+ to?: string;
92
+ onClick?: () => void;
93
+ badge?: SidebarBadge;
94
+ }
95
+ export interface SidebarRailConfig {
96
+ items: SidebarRailItem[];
97
+ bottomItems?: SidebarRailAction[];
98
+ /**
99
+ * Item aktif saat route tidak cocok dengan group mana pun di rail.
100
+ * @default items[0].key
101
+ */
102
+ defaultKey?: string;
103
+ /**
104
+ * Tampilkan label di bawah ikon. `false` = rail ikon saja (selebar header,
105
+ * 44px); label tetap muncul sebagai tooltip dan badge angka jadi dot.
106
+ * @default true
107
+ */
108
+ showLabels?: boolean;
109
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@starasia/admin",
3
- "version": "14.30.0",
3
+ "version": "14.31.0",
4
4
  "description": "Core Admin Dashboard for starasia UI",
5
5
  "author": "Rizki Izzul Haq",
6
6
  "main": "dist/index.umd.js",