@objectql/types 1.6.1 → 1.7.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/package.json CHANGED
@@ -1,11 +1,18 @@
1
1
  {
2
2
  "name": "@objectql/types",
3
- "version": "1.6.1",
3
+ "version": "1.7.0",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
- "dependencies": {},
6
+ "files": [
7
+ "dist",
8
+ "schemas"
9
+ ],
10
+ "devDependencies": {
11
+ "ts-json-schema-generator": "^2.4.0"
12
+ },
7
13
  "scripts": {
8
- "build": "tsc",
14
+ "build": "tsc && npm run generate:schemas",
15
+ "generate:schemas": "node scripts/generate-schemas.js",
9
16
  "test": "jest --passWithNoTests"
10
17
  }
11
18
  }
@@ -0,0 +1,50 @@
1
+ {
2
+ "$ref": "#/definitions/AppConfig",
3
+ "$schema": "http://json-schema.org/draft-07/schema#",
4
+ "definitions": {
5
+ "AppConfig": {
6
+ "additionalProperties": {
7
+ "description": "Custom metadata/settings"
8
+ },
9
+ "properties": {
10
+ "description": {
11
+ "description": "Description of what this application does",
12
+ "type": "string"
13
+ },
14
+ "homepage": {
15
+ "description": "Default path to redirect when opening the app",
16
+ "type": "string"
17
+ },
18
+ "icon": {
19
+ "description": "Icon name/class for the application",
20
+ "type": "string"
21
+ },
22
+ "is_active": {
23
+ "description": "Whether the application is enabled",
24
+ "type": "boolean"
25
+ },
26
+ "label": {
27
+ "description": "Display label for the application",
28
+ "type": "string"
29
+ },
30
+ "logo": {
31
+ "description": "URL to the application logo",
32
+ "type": "string"
33
+ },
34
+ "name": {
35
+ "description": "Unique identifier for the application",
36
+ "type": "string"
37
+ },
38
+ "sort_no": {
39
+ "description": "Sort order for display",
40
+ "type": "number"
41
+ }
42
+ },
43
+ "required": [
44
+ "name",
45
+ "label"
46
+ ],
47
+ "type": "object"
48
+ }
49
+ }
50
+ }
@@ -0,0 +1,129 @@
1
+ {
2
+ "$ref": "#/definitions/MenuConfig",
3
+ "$schema": "http://json-schema.org/draft-07/schema#",
4
+ "definitions": {
5
+ "MenuConfig": {
6
+ "additionalProperties": {
7
+ "description": "Custom properties"
8
+ },
9
+ "properties": {
10
+ "app": {
11
+ "description": "The application this menu belongs to",
12
+ "type": "string"
13
+ },
14
+ "is_active": {
15
+ "description": "Whether the menu is active",
16
+ "type": "boolean"
17
+ },
18
+ "items": {
19
+ "description": "Menu items",
20
+ "items": {
21
+ "$ref": "#/definitions/MenuItem"
22
+ },
23
+ "type": "array"
24
+ },
25
+ "label": {
26
+ "description": "Display label",
27
+ "type": "string"
28
+ },
29
+ "name": {
30
+ "description": "Unique identifier for the menu",
31
+ "type": "string"
32
+ },
33
+ "type": {
34
+ "$ref": "#/definitions/MenuType",
35
+ "description": "Menu type/location"
36
+ }
37
+ },
38
+ "required": [
39
+ "name",
40
+ "label",
41
+ "items"
42
+ ],
43
+ "type": "object"
44
+ },
45
+ "MenuItem": {
46
+ "additionalProperties": {
47
+ "description": "Custom properties"
48
+ },
49
+ "properties": {
50
+ "badge": {
51
+ "description": "Badge value or expression",
52
+ "type": "string"
53
+ },
54
+ "hidden": {
55
+ "description": "Visibility condition",
56
+ "type": [
57
+ "boolean",
58
+ "string"
59
+ ]
60
+ },
61
+ "icon": {
62
+ "description": "Icon name",
63
+ "type": "string"
64
+ },
65
+ "items": {
66
+ "description": "Nested menu items",
67
+ "items": {
68
+ "$ref": "#/definitions/MenuItem"
69
+ },
70
+ "type": "array"
71
+ },
72
+ "label": {
73
+ "description": "Display label",
74
+ "type": "string"
75
+ },
76
+ "name": {
77
+ "description": "Unique identifier for the menu item",
78
+ "type": "string"
79
+ },
80
+ "object": {
81
+ "description": "Associated Object name (for type: object)",
82
+ "type": "string"
83
+ },
84
+ "path": {
85
+ "description": "Navigation path (for type: page/url)",
86
+ "type": "string"
87
+ },
88
+ "target": {
89
+ "description": "Link target (e.g. _blank)",
90
+ "type": "string"
91
+ },
92
+ "type": {
93
+ "$ref": "#/definitions/MenuItemType",
94
+ "description": "Item type"
95
+ },
96
+ "view": {
97
+ "description": "Object View name (for type: object)",
98
+ "type": "string"
99
+ }
100
+ },
101
+ "required": [
102
+ "name",
103
+ "label"
104
+ ],
105
+ "type": "object"
106
+ },
107
+ "MenuItemType": {
108
+ "enum": [
109
+ "page",
110
+ "section",
111
+ "url",
112
+ "folder",
113
+ "object",
114
+ "action"
115
+ ],
116
+ "type": "string"
117
+ },
118
+ "MenuType": {
119
+ "enum": [
120
+ "sidebar",
121
+ "topnav",
122
+ "context",
123
+ "mobile",
124
+ "admin"
125
+ ],
126
+ "type": "string"
127
+ }
128
+ }
129
+ }