HTML Wrap |
---|
tag | span |
---|
class | numbered-children |
---|
|
本教程有以下几个步骤: |
组件是编辑者能够整体编辑、删除、移动的最小的内容单元。将组件看作一个整体,这样当您打开一个典型的Magnolia CMS页面时,您可以凭这个感觉轻易的找到组件。最简单的组件可能是只有一个标题和相应内容组成的整体。
每个组件都可以用在几个页面和几个区域里。在区域里,编辑者可以从一个列表中选择组件。这个列表仅显示该区域可用的组件,这是在availableComponents
节点里定义的。
...
Advanced Tables - Table Plus |
---|
heading | 0 |
---|
enableHeadingAttributes | false |
---|
enableSorting | false |
---|
class | m5-configuration-tree |
---|
enableHighlighting | false |
---|
|
节点名 | 值 |
---|
modules | | templating | | templates | | components | | textBlock | | dialog | templating:textBlock | renderType | freemarker | templateScript | /templates/components/textBlock.ftl | title | Text Block |
|
创建组件脚本
组件脚本绘制组件内容。在我们的示例组件中,内容仅为简单的文字。脚本从内容库中读取文字并绘制出来。
...
Advanced Tables - Table Plus |
---|
heading | 0 |
---|
multiple | false |
---|
enableHeadingAttributes | false |
---|
enableSorting | false |
---|
class | m5-configuration-tree |
---|
enableHighlighting | false |
---|
|
节点名 | 值 |
---|
modules | | templating | | dialogs | | textBlock | | actions | | cancel | | class | info.magnolia.ui.admincentral.dialog.action.CancelDialogActionDefinition | label | Cancel | save | | class | info.magnolia.ui.admincentral.dialog.action.SaveDialogActionDefinition | label | Save changes | form | | tabs | | text | | fields | | text | | class | info.magnolia.ui.form.field.definition.TextFieldDefinition | label | Component text | rows | 5 | label | Text block |
|
为页面添加组件
现在您已经准备好了为页面添加组件所需的一切:定义好的组件,组件脚本,组件对话框,并且在main
区域内可用。
...