jupiter-dynamic-forms 1.0.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/LICENSE +21 -0
- package/README.md +384 -0
- package/dist/core/concept-tree.d.ts +19 -0
- package/dist/core/concept-tree.d.ts.map +1 -0
- package/dist/core/dynamic-form.d.ts +42 -0
- package/dist/core/dynamic-form.d.ts.map +1 -0
- package/dist/core/form-field.d.ts +23 -0
- package/dist/core/form-field.d.ts.map +1 -0
- package/dist/core/form-section.d.ts +20 -0
- package/dist/core/form-section.d.ts.map +1 -0
- package/dist/index.d.ts +8 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +784 -0
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +2082 -0
- package/dist/index.mjs.map +1 -0
- package/dist/schema/types.d.ts +151 -0
- package/dist/schema/types.d.ts.map +1 -0
- package/dist/schema/xbrl-types.d.ts +142 -0
- package/dist/schema/xbrl-types.d.ts.map +1 -0
- package/dist/utils/validation.d.ts +29 -0
- package/dist/utils/validation.d.ts.map +1 -0
- package/dist/utils/xbrl-form-builder.d.ts +52 -0
- package/dist/utils/xbrl-form-builder.d.ts.map +1 -0
- package/package.json +91 -0
- package/wrappers/angular/jupiter-dynamic-forms.module.ts +30 -0
- package/wrappers/angular/public-api.ts +13 -0
- package/wrappers/angular/types.ts +33 -0
package/package.json
ADDED
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "jupiter-dynamic-forms",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "Framework-agnostic dynamic form builder for XBRL entrypoints using Web Components. Supports Angular 18+, React, Vue, and vanilla HTML.",
|
|
5
|
+
"main": "dist/index.js",
|
|
6
|
+
"module": "dist/index.mjs",
|
|
7
|
+
"types": "dist/index.d.ts",
|
|
8
|
+
"files": [
|
|
9
|
+
"dist",
|
|
10
|
+
"README.md",
|
|
11
|
+
"LICENSE",
|
|
12
|
+
"wrappers"
|
|
13
|
+
],
|
|
14
|
+
"scripts": {
|
|
15
|
+
"dev": "vite",
|
|
16
|
+
"build": "tsc && vite build",
|
|
17
|
+
"build:types": "tsc --emitDeclarationOnly",
|
|
18
|
+
"preview": "vite preview",
|
|
19
|
+
"test": "vitest run",
|
|
20
|
+
"test:ui": "vitest --ui",
|
|
21
|
+
"test:coverage": "vitest --coverage",
|
|
22
|
+
"lint": "eslint src --ext ts,tsx --report-unused-disable-directives --max-warnings 100",
|
|
23
|
+
"lint:fix": "eslint src --ext ts,tsx --fix",
|
|
24
|
+
"format": "prettier --write \"src/**/*.{ts,tsx,json,css,md}\"",
|
|
25
|
+
"clean": "rimraf dist",
|
|
26
|
+
"prepublishOnly": "npm run clean && npm run build && npm run test"
|
|
27
|
+
},
|
|
28
|
+
"keywords": [
|
|
29
|
+
"xbrl",
|
|
30
|
+
"dynamic-forms",
|
|
31
|
+
"web-components",
|
|
32
|
+
"framework-agnostic",
|
|
33
|
+
"json-schema",
|
|
34
|
+
"forms",
|
|
35
|
+
"angular",
|
|
36
|
+
"angular18",
|
|
37
|
+
"react",
|
|
38
|
+
"vue",
|
|
39
|
+
"lit-element",
|
|
40
|
+
"typescript",
|
|
41
|
+
"financial-reporting",
|
|
42
|
+
"taxonomy"
|
|
43
|
+
],
|
|
44
|
+
"author": "Jupiter Forms Team",
|
|
45
|
+
"license": "MIT",
|
|
46
|
+
"repository": {
|
|
47
|
+
"type": "git",
|
|
48
|
+
"url": "https://github.com/jupiter-forms/dynamic-forms.git"
|
|
49
|
+
},
|
|
50
|
+
"bugs": {
|
|
51
|
+
"url": "https://github.com/jupiter-forms/dynamic-forms/issues"
|
|
52
|
+
},
|
|
53
|
+
"homepage": "https://github.com/jupiter-forms/dynamic-forms#readme",
|
|
54
|
+
"devDependencies": {
|
|
55
|
+
"@types/node": "^20.5.0",
|
|
56
|
+
"@typescript-eslint/eslint-plugin": "^6.4.0",
|
|
57
|
+
"@typescript-eslint/parser": "^6.4.0",
|
|
58
|
+
"@vitest/coverage-v8": "^0.34.0",
|
|
59
|
+
"@vitest/ui": "^0.34.0",
|
|
60
|
+
"eslint": "^8.47.0",
|
|
61
|
+
"jsdom": "^26.1.0",
|
|
62
|
+
"lit": "^3.0.0",
|
|
63
|
+
"prettier": "^3.0.0",
|
|
64
|
+
"rimraf": "^5.0.0",
|
|
65
|
+
"terser": "^5.43.1",
|
|
66
|
+
"typescript": "^5.1.0",
|
|
67
|
+
"vite": "^4.4.0",
|
|
68
|
+
"vite-plugin-dts": "^3.5.0",
|
|
69
|
+
"vitest": "^0.34.0"
|
|
70
|
+
},
|
|
71
|
+
"dependencies": {
|
|
72
|
+
"ajv": "^8.12.0",
|
|
73
|
+
"lit": "^2.0.0 || ^3.0.0"
|
|
74
|
+
},
|
|
75
|
+
"peerDependencies": {
|
|
76
|
+
"lit": "^2.0.0 || ^3.0.0"
|
|
77
|
+
},
|
|
78
|
+
"exports": {
|
|
79
|
+
".": {
|
|
80
|
+
"import": "./dist/index.mjs",
|
|
81
|
+
"require": "./dist/index.js",
|
|
82
|
+
"types": "./dist/index.d.ts"
|
|
83
|
+
},
|
|
84
|
+
"./angular": {
|
|
85
|
+
"import": "./wrappers/angular/public-api.js",
|
|
86
|
+
"require": "./wrappers/angular/public-api.js",
|
|
87
|
+
"types": "./wrappers/angular/public-api.d.ts"
|
|
88
|
+
}
|
|
89
|
+
},
|
|
90
|
+
"sideEffects": false
|
|
91
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
|
|
2
|
+
import '@jupiter/dynamic-forms';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Angular module for Jupiter Dynamic Forms
|
|
6
|
+
* Provides easy integration with Angular 18+ applications
|
|
7
|
+
*/
|
|
8
|
+
@NgModule({
|
|
9
|
+
imports: [],
|
|
10
|
+
exports: [],
|
|
11
|
+
schemas: [CUSTOM_ELEMENTS_SCHEMA]
|
|
12
|
+
})
|
|
13
|
+
export class JupiterDynamicFormsModule {
|
|
14
|
+
constructor() {
|
|
15
|
+
// Ensure the web components are loaded
|
|
16
|
+
import('@jupiter/dynamic-forms');
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* Helper function to load Jupiter Dynamic Forms
|
|
22
|
+
* Use this in standalone components or if not using the module
|
|
23
|
+
*/
|
|
24
|
+
export function loadJupiterDynamicForms(): Promise<void> {
|
|
25
|
+
return import('@jupiter/dynamic-forms').then(() => void 0);
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
// Re-export types for convenience
|
|
29
|
+
export * from '../../dist/schema/types';
|
|
30
|
+
export * from '../../dist/schema/xbrl-types';
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Public API for Jupiter Dynamic Forms Angular Integration
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
// Main module for easy Angular integration
|
|
6
|
+
export { JupiterDynamicFormsModule, loadJupiterDynamicForms } from './jupiter-dynamic-forms.module';
|
|
7
|
+
|
|
8
|
+
// Angular-specific utilities and types
|
|
9
|
+
export * from './types';
|
|
10
|
+
|
|
11
|
+
// Re-export core types
|
|
12
|
+
export * from '../../dist/schema/types';
|
|
13
|
+
export * from '../../dist/schema/xbrl-types';
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Angular-specific types and interfaces for Jupiter Dynamic Forms
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Angular event interface for form events
|
|
7
|
+
*/
|
|
8
|
+
export interface AngularFormEvent<T = any> extends CustomEvent<T> {
|
|
9
|
+
detail: T;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* Angular component property types
|
|
14
|
+
*/
|
|
15
|
+
export interface AngularJupiterFormProps {
|
|
16
|
+
xbrlInput?: any;
|
|
17
|
+
schema?: any;
|
|
18
|
+
config?: any;
|
|
19
|
+
initialData?: any;
|
|
20
|
+
disabled?: boolean;
|
|
21
|
+
readonly?: boolean;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* Angular form event handlers
|
|
26
|
+
*/
|
|
27
|
+
export interface AngularJupiterFormEvents {
|
|
28
|
+
formSubmit?: (event: AngularFormEvent) => void;
|
|
29
|
+
formChange?: (event: AngularFormEvent) => void;
|
|
30
|
+
formValidate?: (event: AngularFormEvent) => void;
|
|
31
|
+
sectionExpand?: (event: AngularFormEvent) => void;
|
|
32
|
+
conceptExpand?: (event: AngularFormEvent) => void;
|
|
33
|
+
}
|