Ga naar hoofdinhoud

CnWidgetFormRenderer

CnWidgetFormRenderer is the built-in v2 widget that exposes CnFormPage to the manifest layer. It's a transparent pass-through — register, schema, and all form-relevant props are forwarded.

Import​

import { CnWidgetFormRenderer } from '@conduction/nextcloud-vue'

Manifest usage​

Referenced via widgetKey: "form-renderer":

{
"id": "source-form",
"slot": "body",
"widgetKey": "form-renderer",
"gridWidth": 12,
"props": {
"register": "openconnector",
"schema": "source"
}
}

CnFormPage renders the full form surface (header, fields, submit button). Because it's embedded inside a grid cell here rather than mounted as a top-level page, consumer apps should set appropriate grid dimensions (typically gridWidth: 12 for a full-width form).

Props​

All props are forwarded to CnFormPage — see the CnFormPage docs for the full surface. The commonly used ones in manifest widgets are:

PropTypeDescription
registerStringRegister slug for form data submission.
schemaStringSchema slug for the form's field generation.
stepsArrayMulti-step wizard groups (manifest-form-logic), forwarded to CnFormPage. visibleWhen / validation travel inside fields and need no separate wiring.
itemObjectPre-fill the form with an existing object (edit mode).
disabledBooleanRender the form read-only.
submitHandlerFunctionOptional override that receives (formData) instead of the default save flow.
submitEndpointStringOverride the POST/PUT URL used by the default submit handler (overrides register/schema derivation).
submitMethodStringHTTP method for the submit (POST or PUT). Defaults to POST for create, PUT when item is set.
titleStringOptional form title rendered above the fields.
descriptionStringOptional descriptive text rendered under the title.
initialValueObjectInitial form values (alternative to item; merged with the schema's defaults).
documentation-urlStringDocumentation link for the overflow Actions menu (default '').
widget-idStringStable id forwarded to the widget chrome (default '').

Events​

Forwarded to CnFormPage. The widget surface keeps @save, @cancel, etc. usable from the manifest consumer.

Spec​

  • REQ-MVR-007 (manifest-v2-renderer) — built-in widget: form-renderer