You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add additional description on how to cancel the submit. Changed the return value in the example to 'false' to make it less misleading that 'true' is the default value to continue submitting.
@@ -38,7 +38,7 @@ The `DynamicForm` can be configured with the following properties:
38
38
| contentTypeId | string | no | content type ID |
39
39
| disabled | boolean | no | Allows form to be disabled. Default value is `false`|
40
40
| disabledFields | string[]| no | InternalName of fields that should be disabled. Default value is `false`|
41
-
| onBeforeSubmit | (listItemData: any) => Promise<boolean>| no | Before submit handler. Allows to modify the object to be submitted or cancel the submission. |
41
+
| onBeforeSubmit | (listItemData: any) => Promise<boolean>| no | Before submit handler. Allows to modify the object to be submitted or cancel the submission. To cancel, return `true`.|
42
42
| onSubmitted | (listItemData: any, listItem?: IItem) => void | no | Method that returns listItem data JSON object and PnPJS list item instance (`IItem`). |
43
43
| onSubmitError | (listItemData: any, error: Error) => void | no | Handler of submission error. |
44
44
| onCancelled | () => void | no | Handler when form has been cancelled. |
0 commit comments