@bpmn-io/form-js-viewer 0.11.0 → 0.12.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 (28) hide show
  1. package/dist/assets/form-js.css +146 -50
  2. package/dist/index.cjs +757 -484
  3. package/dist/index.cjs.map +1 -1
  4. package/dist/index.es.js +678 -396
  5. package/dist/index.es.js.map +1 -1
  6. package/dist/types/Form.d.ts +2 -2
  7. package/dist/types/index.d.ts +1 -1
  8. package/dist/types/render/components/form-fields/Button.d.ts +1 -0
  9. package/dist/types/render/components/form-fields/Checkbox.d.ts +1 -0
  10. package/dist/types/render/components/form-fields/Checklist.d.ts +7 -1
  11. package/dist/types/render/components/form-fields/Datetime.d.ts +2 -0
  12. package/dist/types/render/components/form-fields/Default.d.ts +2 -0
  13. package/dist/types/render/components/form-fields/Image.d.ts +2 -0
  14. package/dist/types/render/components/form-fields/Number.d.ts +1 -0
  15. package/dist/types/render/components/form-fields/Radio.d.ts +7 -1
  16. package/dist/types/render/components/form-fields/Select.d.ts +7 -1
  17. package/dist/types/render/components/form-fields/Taglist.d.ts +7 -1
  18. package/dist/types/render/components/form-fields/Text.d.ts +2 -0
  19. package/dist/types/render/components/form-fields/Textarea.d.ts +1 -0
  20. package/dist/types/render/components/form-fields/Textfield.d.ts +1 -0
  21. package/dist/types/render/components/form-fields/parts/SearchableSelect.d.ts +1 -0
  22. package/dist/types/render/components/form-fields/parts/SimpleSelect.d.ts +1 -0
  23. package/dist/types/render/components/icons/index.d.ts +1 -16
  24. package/dist/types/render/components/index.d.ts +1 -1
  25. package/dist/types/{src/types.d.ts → types.d.ts} +0 -0
  26. package/dist/types/util/constants/ValuesSourceConstants.d.ts +4 -1
  27. package/dist/types/util/index.d.ts +1 -0
  28. package/package.json +5 -5
@@ -139,6 +139,6 @@ export type State = {
139
139
  properties: FormProperties;
140
140
  schema: Schema;
141
141
  };
142
- export type OnEventWithPriority = OnEventWithPriority;
143
- export type OnEventWithOutPriority = OnEventWithOutPriority;
142
+ export type OnEventWithPriority = (type: FormEvent, priority: number, handler: Function) => void;
143
+ export type OnEventWithOutPriority = (type: FormEvent, handler: Function) => void;
144
144
  export type OnEventType = OnEventWithPriority & OnEventWithOutPriority;
@@ -14,5 +14,5 @@ export * from "./render";
14
14
  export * from "./util";
15
15
  export type CreateFormOptions = import('./types').CreateFormOptions;
16
16
  import Form from "./Form";
17
- export const schemaVersion: 6;
17
+ export const schemaVersion: 7;
18
18
  export { Form };
@@ -6,6 +6,7 @@ declare namespace Button {
6
6
  export { type };
7
7
  export const label: string;
8
8
  export const keyed: boolean;
9
+ export const group: string;
9
10
  }
10
11
  export default Button;
11
12
  declare const type: "button";
@@ -8,6 +8,7 @@ declare namespace Checkbox {
8
8
  export function sanitizeValue({ value }: {
9
9
  value: any;
10
10
  }): boolean;
11
+ export const group: string;
11
12
  }
12
13
  export default Checkbox;
13
14
  declare const type: "checkbox";
@@ -1,11 +1,17 @@
1
1
  declare function Checklist(props: any): import("preact").JSX.Element;
2
2
  declare namespace Checklist {
3
- export function create(options?: {}): {};
3
+ export function create(options?: {}): {
4
+ values: {
5
+ label: string;
6
+ value: string;
7
+ }[];
8
+ };
4
9
  export { type };
5
10
  export const label: string;
6
11
  export const keyed: boolean;
7
12
  export const emptyValue: any[];
8
13
  export { sanitizeMultiSelectValue as sanitizeValue };
14
+ export const group: string;
9
15
  }
10
16
  export default Checklist;
11
17
  declare const type: "checklist";
@@ -5,6 +5,8 @@ declare namespace Datetime {
5
5
  export const keyed: boolean;
6
6
  export const emptyValue: any;
7
7
  export { sanitizeDateTimePickerValue as sanitizeValue };
8
+ export const label: string;
9
+ export const group: string;
8
10
  }
9
11
  export default Datetime;
10
12
  declare const type: "datetime";
@@ -5,5 +5,7 @@ declare namespace Default {
5
5
  };
6
6
  const type: string;
7
7
  const keyed: boolean;
8
+ const label: any;
9
+ const group: any;
8
10
  }
9
11
  export default Default;
@@ -3,6 +3,8 @@ declare namespace Image {
3
3
  export function create(options?: {}): {};
4
4
  export { type };
5
5
  export const keyed: boolean;
6
+ export const label: string;
7
+ export const group: string;
6
8
  }
7
9
  export default Image;
8
10
  declare const type: "image";
@@ -9,6 +9,7 @@ declare namespace Numberfield {
9
9
  export const keyed: boolean;
10
10
  export const label: string;
11
11
  export const emptyValue: any;
12
+ export const group: string;
12
13
  }
13
14
  export default Numberfield;
14
15
  declare const type: "number";
@@ -1,11 +1,17 @@
1
1
  declare function Radio(props: any): import("preact").JSX.Element;
2
2
  declare namespace Radio {
3
- export function create(options?: {}): {};
3
+ export function create(options?: {}): {
4
+ values: {
5
+ label: string;
6
+ value: string;
7
+ }[];
8
+ };
4
9
  export { type };
5
10
  export const label: string;
6
11
  export const keyed: boolean;
7
12
  export const emptyValue: any;
8
13
  export { sanitizeSingleSelectValue as sanitizeValue };
14
+ export const group: string;
9
15
  }
10
16
  export default Radio;
11
17
  declare const type: "radio";
@@ -1,11 +1,17 @@
1
1
  declare function Select(props: any): import("preact").JSX.Element;
2
2
  declare namespace Select {
3
- export function create(options?: {}): {};
3
+ export function create(options?: {}): {
4
+ values: {
5
+ label: string;
6
+ value: string;
7
+ }[];
8
+ };
4
9
  export { type };
5
10
  export const label: string;
6
11
  export const keyed: boolean;
7
12
  export const emptyValue: any;
8
13
  export { sanitizeSingleSelectValue as sanitizeValue };
14
+ export const group: string;
9
15
  }
10
16
  export default Select;
11
17
  declare const type: "select";
@@ -1,11 +1,17 @@
1
1
  declare function Taglist(props: any): import("preact").JSX.Element;
2
2
  declare namespace Taglist {
3
- export function create(options?: {}): {};
3
+ export function create(options?: {}): {
4
+ values: {
5
+ label: string;
6
+ value: string;
7
+ }[];
8
+ };
4
9
  export { type };
5
10
  export const label: string;
6
11
  export const keyed: boolean;
7
12
  export const emptyValue: any[];
8
13
  export { sanitizeMultiSelectValue as sanitizeValue };
14
+ export const group: string;
9
15
  }
10
16
  export default Taglist;
11
17
  declare const type: "taglist";
@@ -5,6 +5,8 @@ declare namespace Text {
5
5
  };
6
6
  export { type };
7
7
  export const keyed: boolean;
8
+ export const group: string;
9
+ export const label: string;
8
10
  }
9
11
  export default Text;
10
12
  declare const type: "text";
@@ -8,6 +8,7 @@ declare namespace Textarea {
8
8
  export function sanitizeValue({ value }: {
9
9
  value: any;
10
10
  }): string;
11
+ export const group: string;
11
12
  }
12
13
  export default Textarea;
13
14
  declare const type: "textarea";
@@ -8,6 +8,7 @@ declare namespace Textfield {
8
8
  export function sanitizeValue({ value }: {
9
9
  value: any;
10
10
  }): string;
11
+ export const group: string;
11
12
  }
12
13
  export default Textfield;
13
14
  declare const type: "textfield";
@@ -0,0 +1 @@
1
+ export default function SearchableSelect(props: any): import("preact").JSX.Element;
@@ -0,0 +1 @@
1
+ export default function SimpleSelect(props: any): import("preact").JSX.Element;
@@ -1,16 +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 { DatetimeIcon as datetime };
7
- export { ImageIcon as image };
8
- export { NumberIcon as number };
9
- export { RadioIcon as radio };
10
- export { SelectIcon as select };
11
- export { TaglistIcon as taglist };
12
- export { TextIcon as text };
13
- export { TextfieldIcon as textfield };
14
- export { TextareaIcon as textarea };
15
- export { FormIcon as default };
16
- }
1
+ export function iconsByType(type: any): any;
@@ -1,4 +1,4 @@
1
- export const formFields: (typeof Image)[];
1
+ export const formFields: (typeof Default | typeof Image)[];
2
2
  export * from "./icons";
3
3
  import Button from "./form-fields/Button";
4
4
  import Checkbox from "./form-fields/Checkbox";
File without changes
@@ -11,5 +11,8 @@ export const VALUES_SOURCES_PATHS: {
11
11
  [x: string]: string[];
12
12
  };
13
13
  export const VALUES_SOURCES_DEFAULTS: {
14
- [x: string]: string | any[];
14
+ [x: string]: string | {
15
+ label: string;
16
+ value: string;
17
+ }[];
15
18
  };
@@ -23,3 +23,4 @@ export function getSchemaVariables(schema: any): string[];
23
23
  export * from "./constants";
24
24
  export * from "./injector";
25
25
  export * from "./form";
26
+ export * from "./feel";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bpmn-io/form-js-viewer",
3
- "version": "0.11.0",
3
+ "version": "0.12.1",
4
4
  "description": "View forms - powered by bpmn.io",
5
5
  "exports": {
6
6
  ".": {
@@ -21,10 +21,10 @@
21
21
  "all": "run-s test build",
22
22
  "build": "run-p bundle generate-types",
23
23
  "start": "SINGLE_START=basic npm run dev",
24
- "bundle": "rollup -c --failAfterWarnings",
25
- "bundle:watch": "rollup -c -w",
24
+ "bundle": "rollup -c --failAfterWarnings --bundleConfigAsCjs",
25
+ "bundle:watch": "rollup -c -w --bundleConfigAsCjs",
26
26
  "dev": "npm test -- --auto-watch --no-single-run",
27
- "generate-types": "tsc --allowJs --skipLibCheck --declaration --emitDeclarationOnly --outDir dist/types src/index.js && copyfiles src/*.d.ts dist/types",
27
+ "generate-types": "tsc --allowJs --skipLibCheck --declaration --emitDeclarationOnly --outDir dist/types src/index.js && copyfiles --flat src/*.d.ts dist/types",
28
28
  "test": "karma start",
29
29
  "prepublishOnly": "npm run build"
30
30
  },
@@ -56,5 +56,5 @@
56
56
  "files": [
57
57
  "dist"
58
58
  ],
59
- "gitHead": "52306e35cfe570e29df0c416b6ba2445a70a01fe"
59
+ "gitHead": "e4a01e3215209858258b2fb83dfc09b86fccc0db"
60
60
  }