@bpmn-io/form-js-editor 0.10.0-alpha.3 → 0.10.1

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.
Files changed (96) hide show
  1. package/LICENSE +22 -22
  2. package/README.md +119 -118
  3. package/dist/assets/form-js-editor.css +295 -287
  4. package/dist/index.cjs +682 -516
  5. package/dist/index.cjs.map +1 -1
  6. package/dist/index.es.js +668 -502
  7. package/dist/index.es.js.map +1 -1
  8. package/dist/types/FormEditor.d.ts +155 -155
  9. package/dist/types/core/Debounce.d.ts +10 -10
  10. package/dist/types/core/EventBus.d.ts +1 -1
  11. package/dist/types/core/FieldFactory.d.ts +18 -18
  12. package/dist/types/core/FormFieldRegistry.d.ts +19 -19
  13. package/dist/types/core/index.d.ts +17 -17
  14. package/dist/types/features/editor-actions/FormEditorActions.d.ts +8 -8
  15. package/dist/types/features/editor-actions/index.d.ts +6 -6
  16. package/dist/types/features/keyboard/FormEditorKeyboardBindings.d.ts +8 -8
  17. package/dist/types/features/keyboard/index.d.ts +7 -7
  18. package/dist/types/features/modeling/Modeling.d.ts +34 -34
  19. package/dist/types/features/modeling/behavior/IdBehavior.d.ts +7 -7
  20. package/dist/types/features/modeling/behavior/KeyBehavior.d.ts +7 -7
  21. package/dist/types/features/modeling/behavior/index.d.ts +8 -8
  22. package/dist/types/features/modeling/cmd/AddFormFieldHandler.d.ts +16 -16
  23. package/dist/types/features/modeling/cmd/EditFormFieldHandler.d.ts +16 -16
  24. package/dist/types/features/modeling/cmd/MoveFormFieldHandler.d.ts +17 -17
  25. package/dist/types/features/modeling/cmd/RemoveFormFieldHandler.d.ts +16 -16
  26. package/dist/types/features/modeling/cmd/UpdateIdClaimHandler.d.ts +14 -14
  27. package/dist/types/features/modeling/cmd/UpdateKeyClaimHandler.d.ts +14 -14
  28. package/dist/types/features/modeling/cmd/Util.d.ts +4 -4
  29. package/dist/types/features/modeling/index.d.ts +7 -7
  30. package/dist/types/features/palette/PaletteRenderer.d.ts +33 -33
  31. package/dist/types/features/palette/components/Palette.d.ts +1 -1
  32. package/dist/types/features/palette/index.d.ts +5 -5
  33. package/dist/types/features/properties-panel/PropertiesPanel.d.ts +1 -1
  34. package/dist/types/features/properties-panel/PropertiesPanelHeaderProvider.d.ts +5 -5
  35. package/dist/types/features/properties-panel/PropertiesPanelPlaceholderProvider.d.ts +8 -8
  36. package/dist/types/features/properties-panel/PropertiesPanelRenderer.d.ts +37 -37
  37. package/dist/types/features/properties-panel/Util.d.ts +9 -9
  38. package/dist/types/features/properties-panel/context/FormPropertiesPanelContext.d.ts +11 -11
  39. package/dist/types/features/properties-panel/context/index.d.ts +1 -1
  40. package/dist/types/features/properties-panel/entries/ActionEntry.d.ts +9 -9
  41. package/dist/types/features/properties-panel/entries/AdornerEntry.d.ts +11 -0
  42. package/dist/types/features/properties-panel/entries/AltTextEntry.d.ts +9 -9
  43. package/dist/types/features/properties-panel/entries/ColumnsEntry.d.ts +9 -9
  44. package/dist/types/features/properties-panel/entries/ConditionEntry.d.ts +9 -9
  45. package/dist/types/features/properties-panel/entries/CustomValueEntry.d.ts +11 -11
  46. package/dist/types/features/properties-panel/entries/DateTimeConstraintsEntry.d.ts +9 -0
  47. package/dist/types/features/properties-panel/entries/DateTimeEntry.d.ts +9 -0
  48. package/dist/types/features/properties-panel/entries/DateTimeSerializationEntry.d.ts +9 -0
  49. package/dist/types/features/properties-panel/entries/DefaultValueEntry.d.ts +1 -1
  50. package/dist/types/features/properties-panel/entries/DescriptionEntry.d.ts +9 -9
  51. package/dist/types/features/properties-panel/entries/DisabledEntry.d.ts +9 -9
  52. package/dist/types/features/properties-panel/entries/IdEntry.d.ts +9 -9
  53. package/dist/types/features/properties-panel/entries/ImageSourceEntry.d.ts +9 -9
  54. package/dist/types/features/properties-panel/entries/InputKeyValuesSourceEntry.d.ts +11 -11
  55. package/dist/types/features/properties-panel/entries/KeyEntry.d.ts +9 -9
  56. package/dist/types/features/properties-panel/entries/LabelEntry.d.ts +9 -9
  57. package/dist/types/features/properties-panel/entries/NumberEntries.d.ts +9 -9
  58. package/dist/types/features/properties-panel/entries/NumberSerializationEntry.d.ts +9 -9
  59. package/dist/types/features/properties-panel/entries/StaticValuesSourceEntry.d.ts +5 -5
  60. package/dist/types/features/properties-panel/entries/TextEntry.d.ts +9 -9
  61. package/dist/types/features/properties-panel/entries/ValueEntry.d.ts +11 -11
  62. package/dist/types/features/properties-panel/entries/ValuesSourceSelectEntry.d.ts +9 -9
  63. package/dist/types/features/properties-panel/entries/factories/index.d.ts +1 -0
  64. package/dist/types/features/properties-panel/entries/factories/simpleStringEntryFactory.d.ts +9 -0
  65. package/dist/types/features/properties-panel/entries/index.d.ts +23 -19
  66. package/dist/types/features/properties-panel/groups/AppearanceGroup.d.ts +13 -0
  67. package/dist/types/features/properties-panel/groups/ConditionGroup.d.ts +11 -11
  68. package/dist/types/features/properties-panel/groups/ConstraintsGroup.d.ts +11 -0
  69. package/dist/types/features/properties-panel/groups/CustomValuesGroup.d.ts +31 -31
  70. package/dist/types/features/properties-panel/groups/GeneralGroup.d.ts +5 -5
  71. package/dist/types/features/properties-panel/groups/SerializationGroup.d.ts +11 -11
  72. package/dist/types/features/properties-panel/groups/ValidationGroup.d.ts +14 -14
  73. package/dist/types/features/properties-panel/groups/ValuesGroups.d.ts +1 -1
  74. package/dist/types/features/properties-panel/groups/index.d.ts +8 -6
  75. package/dist/types/features/properties-panel/hooks/index.d.ts +2 -2
  76. package/dist/types/features/properties-panel/hooks/usePropertiesPanelService.d.ts +1 -1
  77. package/dist/types/features/properties-panel/hooks/useVariables.d.ts +6 -6
  78. package/dist/types/features/properties-panel/icons/index.d.ts +1 -1
  79. package/dist/types/features/properties-panel/index.d.ts +6 -6
  80. package/dist/types/features/selection/Selection.d.ts +14 -14
  81. package/dist/types/features/selection/SelectionBehavior.d.ts +7 -7
  82. package/dist/types/features/selection/index.d.ts +8 -8
  83. package/dist/types/import/Importer.d.ts +51 -51
  84. package/dist/types/import/index.d.ts +5 -5
  85. package/dist/types/index.d.ts +15 -15
  86. package/dist/types/render/Renderer.d.ts +26 -26
  87. package/dist/types/render/components/FormEditor.d.ts +1 -1
  88. package/dist/types/render/components/icons/index.d.ts +1 -15
  89. package/dist/types/render/context/DragAndDropContext.d.ts +4 -4
  90. package/dist/types/render/context/FormEditorContext.d.ts +11 -11
  91. package/dist/types/render/context/index.d.ts +2 -2
  92. package/dist/types/render/hooks/useService.d.ts +1 -1
  93. package/dist/types/render/index.d.ts +8 -8
  94. package/dist/types/src/types.d.ts +28 -28
  95. package/package.json +3 -3
  96. package/dist/types/features/properties-panel/entries/ValuesSourceUtil.d.ts +0 -15
@@ -1,51 +1,51 @@
1
- declare class Importer {
2
- /**
3
- * @constructor
4
- * @param { import('../core/FormFieldRegistry').default } formFieldRegistry
5
- * @param { import('../core/FieldFactory').default } fieldFactory
6
- */
7
- constructor(formFieldRegistry: import('../core/FormFieldRegistry').default, fieldFactory: import('../core/FieldFactory').default);
8
- _formFieldRegistry: import("../core/FormFieldRegistry").default;
9
- _fieldFactory: import("../core/FieldFactory").default;
10
- /**
11
- * Import schema creating fields, attaching additional
12
- * information to each field and adding fields to the
13
- * field registry.
14
- *
15
- * Additional information attached:
16
- *
17
- * * `id` (unless present)
18
- * * `_parent`
19
- * * `_path`
20
- *
21
- * @param {any} schema
22
- *
23
- * @typedef {{ warnings: Error[], schema: any }} ImportResult
24
- * @returns {ImportResult}
25
- */
26
- importSchema(schema: any): {
27
- warnings: Error[];
28
- schema: any;
29
- };
30
- /**
31
- * @param {{[x: string]: any}} fieldAttrs
32
- * @param {String} [parentId]
33
- * @param {number} [index]
34
- *
35
- * @return {any} field
36
- */
37
- importFormField(fieldAttrs: {
38
- [x: string]: any;
39
- }, parentId?: string, index?: number): any;
40
- /**
41
- * @param {Array<any>} components
42
- * @param {string} parentId
43
- *
44
- * @return {Array<any>} imported components
45
- */
46
- importFormFields(components: Array<any>, parentId: string): Array<any>;
47
- }
48
- declare namespace Importer {
49
- const $inject: string[];
50
- }
51
- export default Importer;
1
+ declare class Importer {
2
+ /**
3
+ * @constructor
4
+ * @param { import('../core/FormFieldRegistry').default } formFieldRegistry
5
+ * @param { import('../core/FieldFactory').default } fieldFactory
6
+ */
7
+ constructor(formFieldRegistry: import('../core/FormFieldRegistry').default, fieldFactory: import('../core/FieldFactory').default);
8
+ _formFieldRegistry: import("../core/FormFieldRegistry").default;
9
+ _fieldFactory: import("../core/FieldFactory").default;
10
+ /**
11
+ * Import schema creating fields, attaching additional
12
+ * information to each field and adding fields to the
13
+ * field registry.
14
+ *
15
+ * Additional information attached:
16
+ *
17
+ * * `id` (unless present)
18
+ * * `_parent`
19
+ * * `_path`
20
+ *
21
+ * @param {any} schema
22
+ *
23
+ * @typedef {{ warnings: Error[], schema: any }} ImportResult
24
+ * @returns {ImportResult}
25
+ */
26
+ importSchema(schema: any): {
27
+ warnings: Error[];
28
+ schema: any;
29
+ };
30
+ /**
31
+ * @param {{[x: string]: any}} fieldAttrs
32
+ * @param {String} [parentId]
33
+ * @param {number} [index]
34
+ *
35
+ * @return {any} field
36
+ */
37
+ importFormField(fieldAttrs: {
38
+ [x: string]: any;
39
+ }, parentId?: string, index?: number): any;
40
+ /**
41
+ * @param {Array<any>} components
42
+ * @param {string} parentId
43
+ *
44
+ * @return {Array<any>} imported components
45
+ */
46
+ importFormFields(components: Array<any>, parentId: string): Array<any>;
47
+ }
48
+ declare namespace Importer {
49
+ const $inject: string[];
50
+ }
51
+ export default Importer;
@@ -1,5 +1,5 @@
1
- declare namespace _default {
2
- const importer: (string | typeof Importer)[];
3
- }
4
- export default _default;
5
- import Importer from "./Importer";
1
+ declare namespace _default {
2
+ const importer: (string | typeof Importer)[];
3
+ }
4
+ export default _default;
5
+ import Importer from "./Importer";
@@ -1,15 +1,15 @@
1
- /**
2
- * @typedef { import('./types').CreateFormEditorOptions } CreateFormEditorOptions
3
- */
4
- /**
5
- * Create a form editor.
6
- *
7
- * @param {CreateFormEditorOptions} options
8
- *
9
- * @return {Promise<FormEditor>}
10
- */
11
- export function createFormEditor(options: CreateFormEditorOptions): Promise<FormEditor>;
12
- export type CreateFormEditorOptions = import('./types').CreateFormEditorOptions;
13
- import FormEditor from "./FormEditor";
14
- import { schemaVersion } from "@bpmn-io/form-js-viewer";
15
- export { FormEditor, schemaVersion };
1
+ /**
2
+ * @typedef { import('./types').CreateFormEditorOptions } CreateFormEditorOptions
3
+ */
4
+ /**
5
+ * Create a form editor.
6
+ *
7
+ * @param {CreateFormEditorOptions} options
8
+ *
9
+ * @return {Promise<FormEditor>}
10
+ */
11
+ export function createFormEditor(options: CreateFormEditorOptions): Promise<FormEditor>;
12
+ export type CreateFormEditorOptions = import('./types').CreateFormEditorOptions;
13
+ import FormEditor from "./FormEditor";
14
+ import { schemaVersion } from "@bpmn-io/form-js-viewer";
15
+ export { FormEditor, schemaVersion };
@@ -1,26 +1,26 @@
1
- /**
2
- * @typedef { { container: Element, compact?: boolean } } RenderConfig
3
- * @typedef { import('didi').Injector } Injector
4
- * @typedef { import('../core/EventBus').default } EventBus
5
- * @typedef { import('../FormEditor').default } FormEditor
6
- */
7
- /**
8
- * @param {RenderConfig} renderConfig
9
- * @param {EventBus} eventBus
10
- * @param {FormEditor} formEditor
11
- * @param {Injector} injector
12
- */
13
- declare class Renderer {
14
- constructor(renderConfig: any, eventBus: any, formEditor: any, injector: any);
15
- }
16
- declare namespace Renderer {
17
- const $inject: string[];
18
- }
19
- export default Renderer;
20
- export type RenderConfig = {
21
- container: Element;
22
- compact?: boolean;
23
- };
24
- export type Injector = import('didi').Injector;
25
- export type EventBus = any;
26
- export type FormEditor = import('../FormEditor').default;
1
+ /**
2
+ * @typedef { { container: Element, compact?: boolean } } RenderConfig
3
+ * @typedef { import('didi').Injector } Injector
4
+ * @typedef { import('../core/EventBus').default } EventBus
5
+ * @typedef { import('../FormEditor').default } FormEditor
6
+ */
7
+ /**
8
+ * @param {RenderConfig} renderConfig
9
+ * @param {EventBus} eventBus
10
+ * @param {FormEditor} formEditor
11
+ * @param {Injector} injector
12
+ */
13
+ declare class Renderer {
14
+ constructor(renderConfig: any, eventBus: any, formEditor: any, injector: any);
15
+ }
16
+ declare namespace Renderer {
17
+ const $inject: string[];
18
+ }
19
+ export default Renderer;
20
+ export type RenderConfig = {
21
+ container: Element;
22
+ compact?: boolean;
23
+ };
24
+ export type Injector = import('didi').Injector;
25
+ export type EventBus = any;
26
+ export type FormEditor = import('../FormEditor').default;
@@ -1 +1 @@
1
- export default function FormEditor(props: any): any;
1
+ export default function FormEditor(props: any): any;
@@ -1,15 +1 @@
1
- export namespace iconsByType {
2
- export { ButtonIcon as button };
3
- export { CheckboxIcon as checkbox };
4
- export { ChecklistIcon as checklist };
5
- export { ColumnsIcon as columns };
6
- export { ImageIcon as image };
7
- export { NumberIcon as number };
8
- export { RadioIcon as radio };
9
- export { SelectIcon as select };
10
- export { TaglistIcon as taglist };
11
- export { TextIcon as text };
12
- export { TextfieldIcon as textfield };
13
- export { TextareaIcon as textarea };
14
- export { FormIcon as default };
15
- }
1
+ export { iconsByType } from "@bpmn-io/form-js-viewer";
@@ -1,4 +1,4 @@
1
- export default DragAndDropContext;
2
- declare const DragAndDropContext: import("preact").Context<{
3
- drake: any;
4
- }>;
1
+ export default DragAndDropContext;
2
+ declare const DragAndDropContext: import("preact").Context<{
3
+ drake: any;
4
+ }>;
@@ -1,11 +1,11 @@
1
- export default FormEditorContext;
2
- declare const FormEditorContext: import("preact").Context<{
3
- getService: typeof getService;
4
- }>;
5
- /**
6
- * @param {string} type
7
- * @param {boolean} [strict]
8
- *
9
- * @returns {any}
10
- */
11
- declare function getService(type: string, strict?: boolean): any;
1
+ export default FormEditorContext;
2
+ declare const FormEditorContext: import("preact").Context<{
3
+ getService: typeof getService;
4
+ }>;
5
+ /**
6
+ * @param {string} type
7
+ * @param {boolean} [strict]
8
+ *
9
+ * @returns {any}
10
+ */
11
+ declare function getService(type: string, strict?: boolean): any;
@@ -1,2 +1,2 @@
1
- export { default as DragAndDropContext } from "./DragAndDropContext";
2
- export { default as FormEditorContext } from "./FormEditorContext";
1
+ export { default as DragAndDropContext } from "./DragAndDropContext";
2
+ export { default as FormEditorContext } from "./FormEditorContext";
@@ -1 +1 @@
1
- export default function _default(type: any, strict: any): any;
1
+ export default function _default(type: any, strict: any): any;
@@ -1,8 +1,8 @@
1
- declare namespace _default {
2
- const __init__: string[];
3
- const formFields: (string | typeof FormFields)[];
4
- const renderer: (string | typeof Renderer)[];
5
- }
6
- export default _default;
7
- import { FormFields } from "@bpmn-io/form-js-viewer/dist/types/render";
8
- import Renderer from "./Renderer";
1
+ declare namespace _default {
2
+ const __init__: string[];
3
+ const formFields: (string | typeof FormFields)[];
4
+ const renderer: (string | typeof Renderer)[];
5
+ }
6
+ export default _default;
7
+ import { FormFields } from "@bpmn-io/form-js-viewer/dist/types/render";
8
+ import Renderer from "./Renderer";
@@ -1,29 +1,29 @@
1
- import { Injector } from 'didi';
2
-
3
- export type Module = any;
4
- export type Schema = any;
5
-
6
- export interface FormEditorProperties {
7
- [x: string]: any
8
- }
9
-
10
- export interface FormEditorOptions {
11
- additionalModules?: Module[];
12
- container?: Element | null | string;
13
- exporter?: {
14
- name: string,
15
- version: string
16
- };
17
- injector?: Injector;
18
- modules?: Module[];
19
- properties?: FormEditorProperties;
20
- [x:string]: any;
21
- }
22
-
23
- export interface CreateFormEditorOptions extends FormEditorOptions {
24
- schema?: Schema
25
- }
26
-
27
- export {
28
- Injector
1
+ import { Injector } from 'didi';
2
+
3
+ export type Module = any;
4
+ export type Schema = any;
5
+
6
+ export interface FormEditorProperties {
7
+ [x: string]: any
8
+ }
9
+
10
+ export interface FormEditorOptions {
11
+ additionalModules?: Module[];
12
+ container?: Element | null | string;
13
+ exporter?: {
14
+ name: string,
15
+ version: string
16
+ };
17
+ injector?: Injector;
18
+ modules?: Module[];
19
+ properties?: FormEditorProperties;
20
+ [x:string]: any;
21
+ }
22
+
23
+ export interface CreateFormEditorOptions extends FormEditorOptions {
24
+ schema?: Schema
25
+ }
26
+
27
+ export {
28
+ Injector
29
29
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bpmn-io/form-js-editor",
3
- "version": "0.10.0-alpha.3",
3
+ "version": "0.10.1",
4
4
  "description": "Edit forms - powered by bpmn.io",
5
5
  "exports": {
6
6
  ".": {
@@ -42,7 +42,7 @@
42
42
  "url": "https://github.com/bpmn-io"
43
43
  },
44
44
  "dependencies": {
45
- "@bpmn-io/form-js-viewer": "^0.10.0-alpha.3",
45
+ "@bpmn-io/form-js-viewer": "^0.10.1",
46
46
  "@bpmn-io/properties-panel": "^1.0.0",
47
47
  "array-move": "^3.0.1",
48
48
  "big.js": "^6.2.1",
@@ -58,5 +58,5 @@
58
58
  "files": [
59
59
  "dist"
60
60
  ],
61
- "gitHead": "9ad2c7ba06cc208ba956e6db4bdfb71b510d38c7"
61
+ "gitHead": "96711a75acb05161aad171a8f19f52cd11d11ce4"
62
62
  }
@@ -1,15 +0,0 @@
1
- export function getValuesSource(field: any): string;
2
- export namespace VALUES_SOURCES {
3
- const STATIC: string;
4
- const INPUT: string;
5
- }
6
- export const VALUES_SOURCE_DEFAULT: string;
7
- export const VALUES_SOURCES_LABELS: {
8
- [x: string]: string;
9
- };
10
- export const VALUES_SOURCES_PATHS: {
11
- [x: string]: string[];
12
- };
13
- export const VALUES_SOURCES_DEFAULTS: {
14
- [x: string]: string | any[];
15
- };