Child pages
  • WebLayouts
Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

Layout containers enable the developers to easily structure responsive forms. Servoy provides by default a Bootstrap 12-grid layouts package, but component developers can also add their own layouts.

WebLayouts are similar to WebComponents in the sense that they can be dragged on forms, with the difference that they are not AngularJS directives and do not have any business logic. Their html markup is generated, so an html file is not needed either. A Web Layout Container is comprised of a spec file and a json file:

layout spec file definition
{
	"name": "String componentname",
	"displayName": "String more descriptive name that is shown in the designer",
	"version": the version, the same as for the components (integer),
	"definition": "A reference to the js file of this layout",
	"contains": ["Specifies an array of components/layouts which can be added to this layout container"],
	"topContainer": "Used to determine whether this layout container can be added directly into the root of the form",
	"tagType":"The tag type for HTML output. The default value is 'div'",
	"model": {
		 "propertyName": type description, optional default value - the model properties are generated on the tag as HTML attributes
	}
}
layouts json definition file
{
	"class":"The css class to be applied to the layout container"
}
  • No labels