@nextsparkjs/core 0.1.0-beta.32 → 0.1.0-beta.34
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/dist/styles/classes.json
CHANGED
package/package.json
CHANGED
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Docs Registry Generator
|
|
3
|
+
*
|
|
4
|
+
* Generates docs-registry.ts with stub implementations.
|
|
5
|
+
* The actual docs content is generated separately by docs-registry.mjs
|
|
6
|
+
* when documentation exists. This stub ensures the build doesn't fail
|
|
7
|
+
* when no docs are present.
|
|
8
|
+
*
|
|
9
|
+
* @module core/scripts/build/registry/generators/docs-registry
|
|
10
|
+
*/
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* Generate the docs registry stub file
|
|
14
|
+
*
|
|
15
|
+
* @returns {string} Generated TypeScript content
|
|
16
|
+
*/
|
|
17
|
+
export function generateDocsRegistry() {
|
|
18
|
+
return `/**
|
|
19
|
+
* Auto-generated Docs Registry
|
|
20
|
+
*
|
|
21
|
+
* Generated at: ${new Date().toISOString()}
|
|
22
|
+
*
|
|
23
|
+
* This file provides stub implementations for the docs registry.
|
|
24
|
+
* When documentation exists, this is overwritten by the full docs-registry builder.
|
|
25
|
+
*
|
|
26
|
+
* DO NOT EDIT - This file is auto-generated
|
|
27
|
+
*/
|
|
28
|
+
|
|
29
|
+
// Type definitions
|
|
30
|
+
export interface DocPageMeta {
|
|
31
|
+
slug: string
|
|
32
|
+
title: string
|
|
33
|
+
description?: string
|
|
34
|
+
path: string
|
|
35
|
+
order: number
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export interface DocSectionMeta {
|
|
39
|
+
slug: string
|
|
40
|
+
title: string
|
|
41
|
+
description?: string
|
|
42
|
+
icon?: string
|
|
43
|
+
order: number
|
|
44
|
+
pages: DocPageMeta[]
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
export interface DocsRegistryStructure {
|
|
48
|
+
public: DocSectionMeta[]
|
|
49
|
+
superadmin: DocSectionMeta[]
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
// Registry Data
|
|
53
|
+
export const DOCS_REGISTRY: DocsRegistryStructure = {
|
|
54
|
+
public: [],
|
|
55
|
+
superadmin: []
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
// Registry Access Functions
|
|
59
|
+
export function getAllDocSections(): DocSectionMeta[] {
|
|
60
|
+
return [...DOCS_REGISTRY.public, ...DOCS_REGISTRY.superadmin]
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
export function getPublicDocSections(): DocSectionMeta[] {
|
|
64
|
+
return DOCS_REGISTRY.public
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
export function getSuperadminDocSections(): DocSectionMeta[] {
|
|
68
|
+
return DOCS_REGISTRY.superadmin
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
export function findDocSection(slug: string): DocSectionMeta | undefined {
|
|
72
|
+
return getAllDocSections().find(section => section.slug === slug)
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
export function findDocSectionInCategory(
|
|
76
|
+
slug: string,
|
|
77
|
+
category: 'public' | 'superadmin'
|
|
78
|
+
): DocSectionMeta | undefined {
|
|
79
|
+
return DOCS_REGISTRY[category].find(section => section.slug === slug)
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
export function findDocPage(
|
|
83
|
+
sectionSlug: string,
|
|
84
|
+
pageSlug: string
|
|
85
|
+
): DocPageMeta | undefined {
|
|
86
|
+
const section = findDocSection(sectionSlug)
|
|
87
|
+
return section?.pages.find(page => page.slug === pageSlug)
|
|
88
|
+
}
|
|
89
|
+
`
|
|
90
|
+
}
|
|
@@ -34,6 +34,7 @@ export * from './template-registry'
|
|
|
34
34
|
export * from './middleware-registry'
|
|
35
35
|
export * from './scope-registry'
|
|
36
36
|
export * from './namespace-registry'
|
|
37
|
+
export * from './docs-registry'
|
|
37
38
|
|
|
38
39
|
import { PLUGIN_REGISTRY, PLUGIN_METADATA, type PluginName } from './plugin-registry'
|
|
39
40
|
import { ENTITY_REGISTRY, ENTITY_METADATA, type EntityName } from './entity-registry'
|
|
@@ -70,6 +70,7 @@ import { generateFeatureRegistryFull } from './registry/generators/feature-regis
|
|
|
70
70
|
import { generateAuthRegistry } from './registry/generators/auth-registry.mjs'
|
|
71
71
|
import { generatePermissionsRegistry } from './registry/generators/permissions-registry.mjs'
|
|
72
72
|
import { generateScheduledActionsRegistry } from './registry/generators/scheduled-actions-registry.mjs'
|
|
73
|
+
import { generateDocsRegistry } from './registry/generators/docs-registry.mjs'
|
|
73
74
|
import {
|
|
74
75
|
generateMissingPages,
|
|
75
76
|
displayTreeStructure,
|
|
@@ -111,6 +112,7 @@ async function generateRegistryFiles(CONFIG, plugins, entities, themes, template
|
|
|
111
112
|
{ name: 'namespace-registry.ts', content: generateNamespaceRegistry(entities, CONFIG) },
|
|
112
113
|
{ name: 'permissions-registry.ts', content: await generatePermissionsRegistry(permissionsConfig, entities, CONFIG) },
|
|
113
114
|
{ name: 'scheduled-actions-registry.ts', content: generateScheduledActionsRegistry(themes, CONFIG) },
|
|
115
|
+
{ name: 'docs-registry.ts', content: generateDocsRegistry() },
|
|
114
116
|
{ name: 'index.ts', content: generateUnifiedRegistry(plugins, entities, themes, templates, middlewares, CONFIG) }
|
|
115
117
|
]
|
|
116
118
|
|