Adobe AEM 6.1将选项卡添加到触摸屏UI页面属性

Adobe AEM 6.1将选项卡添加到触摸屏UI页面属性,adobe,aem,Adobe,Aem,我正在尝试在页面属性中添加新选项卡和删除选项卡/项目 到目前为止,我已经阅读了这个类似的问题: 这让我找到了这些Adobe链接和github示例: 我已经为页面的页面属性复制了github的.context.xml示例,它没有隐藏任何内容 我还将cq:showncreate=“{Boolean}false”替换为cq:hideOnEdit=“{Boolean}true”,就像前面的adobe帮助论坛建议的那样,这也不起作用 如何隐藏和显示项目 此外,在过去的Classic UI中,我们

我正在尝试在页面属性中添加新选项卡和删除选项卡/项目

到目前为止,我已经阅读了这个类似的问题:

这让我找到了这些Adobe链接和github示例:

我已经为页面的页面属性复制了github的.context.xml示例,它没有隐藏任何内容

我还将cq:showncreate=“{Boolean}false”替换为cq:hideOnEdit=“{Boolean}true”,就像前面的adobe帮助论坛建议的那样,这也不起作用

如何隐藏和显示项目

此外,在过去的Classic UI中,我们可以这样做以包含更多选项卡:

<sample
jcr:primaryType="cq:Widget"
path="/apps/company/components/Pages/basePage/sample_tab.infinity.json"
xtype="cqinclude"/>


如何使用类似于infinity.json的东西在TouchUI中添加新选项卡?Granite include?

通过使用
路径
属性的
Granite/ui/components/foundation/include
,您可以在Touch中重复使用选项卡,就像在Classic中一样

在下面的示例中,我们有一个标题组件,它包含一个普通文本小部件,并拉入一个可重用组件设置选项卡。我已将共享选项卡放置在
/apps/mysite/dialogs/granite/tabs
下,但这不是一个要求,您只需更新
路径
属性即可

这是位于
/apps/mysite/components/heading/_cq_dialog.xml的组件对话框:

<?xml version="1.0" encoding="UTF-8"?>
<jcr:root xmlns:sling="http://sling.apache.org/jcr/sling/1.0" xmlns:cq="http://www.day.com/jcr/cq/1.0" xmlns:jcr="http://www.jcp.org/jcr/1.0" xmlns:nt="http://www.jcp.org/jcr/nt/1.0"
    jcr:primaryType="nt:unstructured"
    jcr:title="Heading"
    sling:resourceType="cq/gui/components/authoring/dialog"
    helpPath="en/cq/current/wcm/default_components.html#Carousel">
    <content
        jcr:primaryType="nt:unstructured"
        sling:resourceType="granite/ui/components/foundation/container">
        <layout
            jcr:primaryType="nt:unstructured"
            sling:resourceType="granite/ui/components/foundation/layouts/tabs"
            type="nav"/>
        <items jcr:primaryType="nt:unstructured">
            <generalSettings
                jcr:primaryType="nt:unstructured"
                jcr:title="General Settings"
                sling:resourceType="granite/ui/components/foundation/section">
                <layout
                    jcr:primaryType="nt:unstructured"
                    sling:resourceType="granite/ui/components/foundation/layouts/fixedcolumns"/>
                <items jcr:primaryType="nt:unstructured">
                    <column
                        jcr:primaryType="nt:unstructured"
                        sling:resourceType="granite/ui/components/foundation/container">
                        <items jcr:primaryType="nt:unstructured">
                            <headingText
                                jcr:primaryType="nt:unstructured"
                                sling:resourceType="granite/ui/components/foundation/form/textfield"
                                fieldLabel="Text"
                                name="./text"/>
                        </items>
                    </column>
                </items>
            </generalSettings>
            <componentSettings
                jcr:title="Component Settings"
                jcr:primaryType="nt:unstructured"
                sling:resourceType="granite/ui/components/foundation/include"
                path="mysite/dialogs/granite/tabs/componentSettings"/>
        </items>
    </content>
</jcr:root>
<?xml version="1.0" encoding="UTF-8"?>
<jcr:root xmlns:sling="http://sling.apache.org/jcr/sling/1.0" xmlns:jcr="http://www.jcp.org/jcr/1.0" xmlns:nt="http://www.jcp.org/jcr/nt/1.0"
    jcr:primaryType="nt:unstructured"
    jcr:title="Settings"
    sling:resourceType="granite/ui/components/foundation/section">
    <layout
        jcr:primaryType="nt:unstructured"
        sling:resourceType="granite/ui/components/foundation/layouts/fixedcolumns"
        margin="{Boolean}false"/>
    <items jcr:primaryType="nt:unstructured">
        <column
            jcr:primaryType="nt:unstructured"
            sling:resourceType="granite/ui/components/foundation/container">
            <items jcr:primaryType="nt:unstructured">
                <componentId
                    jcr:primaryType="nt:unstructured"
                    sling:resourceType="granite/ui/components/foundation/form/textfield"
                    fieldLabel="Component Id"
                    name="./componentId"/>
            </items>
        </column>
    </items>
</jcr:root>