cabloy 5.1.176 → 5.1.177

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/.cabloy-version CHANGED
@@ -1 +1 @@
1
- 5.1.176
1
+ 5.1.177
package/CHANGELOG.md CHANGED
@@ -1,5 +1,12 @@
1
1
  # Changelog
2
2
 
3
+ ## 5.1.177
4
+
5
+ ### Improvements
6
+
7
+ - Update the menu guide documentation.
8
+ - Refresh the pnpm lockfile.
9
+
3
10
  ## 5.1.176
4
11
 
5
12
  ### Improvements
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cabloy",
3
- "version": "5.1.176",
3
+ "version": "5.1.177",
4
4
  "gitHead": "2c5c19284bab738e492856189acb6fad74b8a7b7",
5
5
  "description": "A Node.js fullstack framework",
6
6
  "keywords": [
@@ -55,9 +55,11 @@ This makes menu retrieval part of the broader backend contract surface.
55
55
 
56
56
  In the current repo implementation, the out-of-the-box menu controller is public and delegates directly to `this.scope.service.menu.retrieveMenus(publicPath)`.
57
57
 
58
- ## Static menu visibility
58
+ ## SSR Site targeting
59
59
 
60
- `@SsrMenu(...)` items can declare static role visibility without changing the public menu DTO:
60
+ `@SsrMenu(...)` and `@SsrMenuGroup(...)` use `site` to select the SSR Site onion(s) that receive the declaration. It is a navigation-composition filter, not a site-admission, role-visibility, or backend-authorization decision.
61
+
62
+ Use `site` for navigation owned by one SSR Site or deliberately exclusive to a known subset of sites:
61
63
 
62
64
  ```typescript
63
65
  @SsrMenu({
@@ -66,10 +68,41 @@ In the current repo implementation, the out-of-the-box menu controller is public
66
68
  link: 'presetResource',
67
69
  roles: ['systemAdmin'],
68
70
  },
69
- site: 'basic-siteadmin:admin',
71
+ // This Basic Admin-owned entry intentionally targets one SSR Site.
72
+ site: ['basic-siteadmin:admin'],
73
+ })
74
+ ```
75
+
76
+ For a shared module declaration intended for every compatible SSR Admin site, omit `site`:
77
+
78
+ ```typescript
79
+ @SsrMenu({
80
+ item: {
81
+ title: $locale('SharedOperations'),
82
+ link: 'presetResource',
83
+ roles: ['systemAdmin'],
84
+ },
85
+ // No `site`: the shared declaration is available to compatible SSR Admin sites.
70
86
  })
71
87
  ```
72
88
 
89
+ Do not bind a shared Admin menu or menu group to the current/default Admin site merely to keep a new independent site's navigation narrow. Isolate an independent site through its enabled module composition and site-owned menus/groups. When a shared capability needs genuinely different navigation contracts per site, use an explicit, approved site-specific composition or owner instead of narrowing the shared declaration by default.
90
+
91
+ `site` is distinct from a role's `siteIds`, menu `roles` or role-menu associations, and Passport/RBAC authorization:
92
+
93
+ ```text
94
+ site -> which SSR Site receives a menu/group declaration
95
+ siteIds -> which frontend Site a subject may enter
96
+ roles / role-menu -> which admitted subject may discover a menu leaf
97
+ Passport / RBAC -> which backend actions or data the subject may use
98
+ ```
99
+
100
+ See [Menu Authorization](/backend/menu-authorization) for the site-admission, navigation-disclosure, and backend-authority boundaries.
101
+
102
+ ## Static menu visibility
103
+
104
+ `@SsrMenu(...)` items can declare static role visibility without changing the public menu DTO:
105
+
73
106
  - Omit `roles` to make an item visible to anonymous and authenticated callers.
74
107
  - Use `roles: []` when an item has no static role visibility and is intended to be disclosed only through dynamic Role-menu configuration.
75
108
  - A nonempty `roles` array is visible when the current Passport has at least one matching role name; it can also be disclosed through dynamic Role-menu configuration.
@@ -107,5 +140,6 @@ When editing SSR menu behavior, ask:
107
140
  2. is there a default fallback menu that should remain available?
108
141
  3. does the menu contract belong in backend API design, frontend route design, or both?
109
142
  4. does the active edition affect the menu structure or public path assumptions?
143
+ 5. is this declaration site-owned or deliberately site-exclusive (specify `site`), or shared across compatible SSR Admin sites (omit `site`)?
110
144
 
111
145
  That helps AI keep menu behavior aligned with Cabloy’s shared SSR architecture.
@@ -1019,7 +1019,7 @@ importers:
1019
1019
  src/suite-vendor/a-pay:
1020
1020
  dependencies:
1021
1021
  zova-module-a-pay:
1022
- specifier: ^5.0.8
1022
+ specifier: ^5.0.9
1023
1023
  version: link:modules/a-pay
1024
1024
  zova-module-pay-mock:
1025
1025
  specifier: ^5.0.5