robobyte-front-builder 1.0.14 → 1.0.17

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "robobyte-front-builder",
3
- "version": "1.0.14",
3
+ "version": "1.0.17",
4
4
  "description": "RoboByte low-code UI builder, Report builder, and navigation extension system",
5
5
  "main": "src/lib/index.js",
6
6
  "files": [
package/src/lib/index.js CHANGED
@@ -76,6 +76,11 @@ export { default as NavigatorBuilderPage } from '../pages/navigatorBuilder/index
76
76
  // ViewerPage renders a saved UI Builder view (read-only production mode).
77
77
  // Create a host page at e.g. pages/viewer/[id].jsx and re-export this component.
78
78
  export { default as ViewerPage } from '../pages/viewer/[id]/index'
79
+ // Internal list / viewer pages — use these to embed the browse/list experience
80
+ // inside the host app with its own layout.
81
+ export { default as ViewsList } from '../pages/viewBuilder/views/index'
82
+ export { default as ReportsList } from '../pages/reportModule/reportBuilder/reports/index'
83
+ export { default as ReportViewer } from '../pages/reportModule/reportBuilder/reportViewer/index'
79
84
 
80
85
  // ── Core Contexts & Hooks (advanced use) ─────────────────────────────────────
81
86
  // Useful when you need to read or drive builder state from the host app.
@@ -44,20 +44,24 @@
44
44
  */
45
45
 
46
46
  import { useMemo } from 'react'
47
+ import { ModuleRegistry } from 'ag-grid-community'
48
+ import { AllEnterpriseModule, LicenseManager } from 'ag-grid-enterprise'
47
49
  import { NavigationExtensionProvider } from '../navigation/NavigationExtensionContext'
48
50
  import { configureRoboByte } from '../../services/config'
49
51
  import { AuthContext } from '../../context/AuthContext'
50
52
 
51
53
  /**
52
- * @param {string} [baseURL] Root API server URL (with trailing slash)
53
- * @param {string} [apiURL] /api prefix URL (with trailing slash)
54
- * @param {object} [user] Current user from the host auth context
55
- * @param {string} [accessToken] Current Bearer token from the host auth context
56
- * @param {Object[]} [navExtensions] Static nav items to inject into the sidebar
57
- * @param {Object} [endpoints] Full-URL overrides for each endpoint group+name.
58
- * Shape: { [group]: { [name]: fullURL } }
59
- * e.g. { ReportBuilder: { GenericGet: 'https://api.example.com/api/ReportBuilder/GenericGet' } }
60
- * When provided, the package uses these URLs instead of its own defaults.
54
+ * @param {string} [baseURL] Root API server URL (with trailing slash)
55
+ * @param {string} [apiURL] /api prefix URL (with trailing slash)
56
+ * @param {object} [user] Current user from the host auth context
57
+ * @param {string} [accessToken] Current Bearer token from the host auth context
58
+ * @param {Object[]} [navExtensions] Static nav items to inject into the sidebar
59
+ * @param {Object} [endpoints] Full-URL overrides for each endpoint group+name.
60
+ * Shape: { [group]: { [name]: fullURL } }
61
+ * @param {string} [agGridLicenseKey] AG Grid Enterprise license key.
62
+ * Pass your key here the provider calls
63
+ * LicenseManager.setLicenseKey() and registers
64
+ * AllEnterpriseModule automatically.
61
65
  * @param {ReactNode} children
62
66
  */
63
67
  const RoboByteFrontBuilderProvider = ({
@@ -68,6 +72,7 @@ const RoboByteFrontBuilderProvider = ({
68
72
  accessToken = null,
69
73
  navExtensions = [],
70
74
  endpoints = null,
75
+ agGridLicenseKey = null,
71
76
  }) => {
72
77
  // Apply URL + endpoint config synchronously before any child renders.
73
78
  useMemo(() => {
@@ -76,6 +81,14 @@ const RoboByteFrontBuilderProvider = ({
76
81
  }
77
82
  }, [baseURL, apiURL, endpoints])
78
83
 
84
+ // Set up AG Grid Enterprise once — safe to call multiple times (idempotent).
85
+ useMemo(() => {
86
+ if (agGridLicenseKey) {
87
+ LicenseManager.setLicenseKey(agGridLicenseKey)
88
+ }
89
+ ModuleRegistry.registerModules([AllEnterpriseModule])
90
+ }, [agGridLicenseKey])
91
+
79
92
  // Auth context value — comes entirely from the host. No logic here.
80
93
  const authValue = useMemo(
81
94
  () => ({ user, accessToken }),
package/src/pages/_app.js CHANGED
@@ -46,14 +46,6 @@ import {useContext, useEffect} from "react";
46
46
  import { NavigationExtensionProvider } from 'src/lib/navigation/NavigationExtensionContext'
47
47
 
48
48
  const clientSideEmotionCache = createEmotionCache()
49
- import { AllEnterpriseModule, LicenseManager} from "ag-grid-enterprise";
50
-
51
- LicenseManager.setLicenseKey("Using_this_{AG_Grid}_Enterprise_key_{AG-064521}_in_excess_of_the_licence_granted_is_not_permitted___Please_report_misuse_to_legal@ag-grid.com___For_help_with_changing_this_key_please_contact_info@ag-grid.com___{RoboByte}_is_granted_a_{Multiple_Applications}_Developer_License_for_{1}_Front-End_JavaScript_developer___All_Front-End_JavaScript_developers_need_to_be_licensed_in_addition_to_the_ones_working_with_{AG_Grid}_Enterprise___This_key_has_not_been_granted_a_Deployment_License_Add-on___This_key_works_with_{AG_Grid}_Enterprise_versions_released_before_{4_August_2025}____[v3]_[01]_MTc1NDI2MjAwMDAwMA==3b122b26308a216244f31e0932146fec");
52
- import {ModuleRegistry} from "ag-grid-community";
53
-
54
- ModuleRegistry. registerModules([
55
- AllEnterpriseModule,
56
- ]);
57
49
  // ** Pace Loader
58
50
  if (themeConfig.routingLoader) {
59
51
  Router.events.on('routeChangeStart', () => {
@@ -140,7 +140,7 @@ const ViewsList = () => {
140
140
 
141
141
  ViewsList.acl = {
142
142
  action: 'view',
143
- subject: PermissionsSubjects.ReportBuilder
143
+ subject: PermissionsSubjects.UiBuilder
144
144
  }
145
145
 
146
146
  export default ViewsList
@@ -3,23 +3,27 @@ import { ContentTypes, DataTypes } from '../ContentTypes'
3
3
  export const ViewPermissionEndpoints = {
4
4
  Post: {
5
5
  GetAllPagedByFilter: {
6
+ group: 'ViewPermission', name: 'GetAllPagedByFilter',
6
7
  URL: 'ViewPermission/GetAllPagedByFilter',
7
8
  ContentType: ContentTypes.Json,
8
9
  DataType: DataTypes.Body
9
10
  },
10
11
  GetAllByFilter: {
12
+ group: 'ViewPermission', name: 'GetAllByFilter',
11
13
  URL: 'ViewPermission/GetAllByFilter',
12
14
  ContentType: ContentTypes.Json,
13
15
  DataType: DataTypes.Body
14
16
  },
15
- AddPermission : {
17
+ AddPermission: {
18
+ group: 'ViewPermission', name: 'AddPermission',
16
19
  URL: 'ViewPermission',
17
20
  ContentType: ContentTypes.Json,
18
21
  DataType: DataTypes.Body
19
22
  }
20
23
  },
21
24
  Put: {
22
- UpdatePermission : {
25
+ UpdatePermission: {
26
+ group: 'ViewPermission', name: 'UpdatePermission',
23
27
  URL: 'ViewPermission',
24
28
  ContentType: ContentTypes.Json,
25
29
  DataType: DataTypes.Body
@@ -29,6 +33,7 @@ export const ViewPermissionEndpoints = {
29
33
  Get: {},
30
34
  Delete: {
31
35
  DeletePermission: {
36
+ group: 'ViewPermission', name: 'DeletePermission',
32
37
  URL: 'ViewPermission',
33
38
  ContentType: ContentTypes.Json,
34
39
  DataType: DataTypes.Params
@@ -3,18 +3,21 @@ import { ContentTypes, DataTypes } from '../ContentTypes'
3
3
  export const ViewPermissionRoleEndpoints = {
4
4
  Post: {
5
5
  GetViewPermissionRolePaged: {
6
+ group: 'ViewPermissionRole', name: 'GetViewPermissionRolePaged',
6
7
  URL: 'ViewPermissionRole/GetAllPagedByFilter',
7
8
  ContentType: ContentTypes.Json,
8
9
  DataType: DataTypes.Body
9
10
  },
10
- AddViewPermissionRole : {
11
+ AddViewPermissionRole: {
12
+ group: 'ViewPermissionRole', name: 'AddViewPermissionRole',
11
13
  URL: 'ViewPermissionRole',
12
14
  ContentType: ContentTypes.Json,
13
15
  DataType: DataTypes.Body
14
16
  }
15
17
  },
16
18
  Put: {
17
- UpdateViewPermissionRole : {
19
+ UpdateViewPermissionRole: {
20
+ group: 'ViewPermissionRole', name: 'UpdateViewPermissionRole',
18
21
  URL: 'ViewPermissionRole',
19
22
  ContentType: ContentTypes.Json,
20
23
  DataType: DataTypes.Body
@@ -22,15 +25,16 @@ export const ViewPermissionRoleEndpoints = {
22
25
  },
23
26
  Patch: {},
24
27
  Get: {
25
- GetRoleById: {
26
- URL: 'ViewPermissionRole/GetById',
27
- ContentType: ContentTypes.Json,
28
- DataType: DataTypes.Body
29
- },
28
+ GetRoleById: {
29
+ group: 'ViewPermissionRole', name: 'GetRoleById',
30
+ URL: 'ViewPermissionRole/GetById',
31
+ ContentType: ContentTypes.Json,
32
+ DataType: DataTypes.Body
30
33
  },
31
-
34
+ },
32
35
  Delete: {
33
36
  DeleteViewPermissionRole: {
37
+ group: 'ViewPermissionRole', name: 'DeleteViewPermissionRole',
34
38
  URL: 'ViewPermissionRole',
35
39
  ContentType: ContentTypes.Json,
36
40
  DataType: DataTypes.Params
@@ -3,18 +3,21 @@ import { ContentTypes, DataTypes } from '../ContentTypes'
3
3
  export const ViewPermissionRoleItemsEndpoints = {
4
4
  Post: {
5
5
  GetViewPermissionRoleItems: {
6
+ group: 'ViewPermissionRoleItems', name: 'GetViewPermissionRoleItems',
6
7
  URL: 'ViewPermissionRoleItems/GetRolePermissions',
7
8
  ContentType: ContentTypes.Json,
8
9
  DataType: DataTypes.Body
9
10
  },
10
- UpdateViewPermissionRoleItems : {
11
+ UpdateViewPermissionRoleItems: {
12
+ group: 'ViewPermissionRoleItems', name: 'UpdateViewPermissionRoleItems',
11
13
  URL: 'ViewPermissionRoleItems/UpdatePermissions',
12
14
  ContentType: ContentTypes.Json,
13
15
  DataType: DataTypes.Body
14
16
  }
15
17
  },
16
18
  Put: {
17
- UpdateViewPermissionRole : {
19
+ UpdateViewPermissionRole: {
20
+ group: 'ViewPermissionRoleItems', name: 'UpdateViewPermissionRole',
18
21
  URL: 'ViewPermissionRole',
19
22
  ContentType: ContentTypes.Json,
20
23
  DataType: DataTypes.Body
@@ -24,6 +27,7 @@ export const ViewPermissionRoleItemsEndpoints = {
24
27
  Get: {},
25
28
  Delete: {
26
29
  DeleteViewPermissionRole: {
30
+ group: 'ViewPermissionRoleItems', name: 'DeleteViewPermissionRole',
27
31
  URL: 'ViewPermissionRole',
28
32
  ContentType: ContentTypes.Json,
29
33
  DataType: DataTypes.Params
@@ -3,23 +3,24 @@ import { ContentTypes, DataTypes } from '../ContentTypes'
3
3
  export const ViewPermissionRoleUsersEndpoints = {
4
4
  Post: {
5
5
  GetViewPermissionRoleUsers: {
6
+ group: 'ViewPermissionRoleUsers', name: 'GetViewPermissionRoleUsers',
6
7
  URL: 'ViewPermissionRoleUser/GetAllPagedByFilter',
7
8
  ContentType: ContentTypes.Json,
8
9
  DataType: DataTypes.Body
9
10
  },
10
- AddUserForRole : {
11
+ AddUserForRole: {
12
+ group: 'ViewPermissionRoleUsers', name: 'AddUserForRole',
11
13
  URL: 'ViewPermissionRoleUser',
12
14
  ContentType: ContentTypes.Json,
13
15
  DataType: DataTypes.Body
14
16
  }
15
17
  },
16
- Put: {
17
-
18
- },
18
+ Put: {},
19
19
  Patch: {},
20
20
  Get: {},
21
21
  Delete: {
22
22
  DeleteUserViewPermissionRole: {
23
+ group: 'ViewPermissionRoleUsers', name: 'DeleteUserViewPermissionRole',
23
24
  URL: 'ViewPermissionRoleUser',
24
25
  ContentType: ContentTypes.Json,
25
26
  DataType: DataTypes.Params
@@ -42,10 +42,13 @@ export const Endpoints = {
42
42
  FilterEndpoints: { ...FilterEndpoints },
43
43
  UserTableTemplates: { ...UserTableTemplateEndpoints },
44
44
  Buuny: { ...BunnyEndpoints },
45
- // ReportBuilder: { ...ReportBuilderEndpoints },
46
45
  View: { ...ViewEndpoints },
47
46
  ReportBuilder: { ...ReportBuilderEndpoints },
48
47
  UiBuilder: { ...UiBuilderEndpoints },
49
48
  Navigator: { ...NavigatorEndpoints },
50
49
  Widget: { ...WidgetEndpoints },
50
+ ViewPermission: { ...ViewPermissionEndpoints },
51
+ ViewPermissionRole: { ...ViewPermissionRoleEndpoints },
52
+ ViewPermissionRoleItems: { ...ViewPermissionRoleItemsEndpoints },
53
+ ViewPermissionRoleUsers: { ...ViewPermissionRoleUsersEndpoints },
51
54
  }