パスフィールドでアセットのドラッグ&ドロップ機能を有効にする方法

Adobe Experience Manager 6.5.10 の更新後、アセットブラウザーからページエディター上のパスフィールドにアセットをドラッグ&ドロップできるようになりました。 この機能を有効にするには、droppable プロパティを PathField のノードに追加します。

説明 description

環境

Adobe Experience Manager

問題/症状

AEM 6.5.10 以降では、アセットブラウザーからページエディター上のパスフィールドにアセットをドラッグ&ドロップできます。 この機能は、AEM 6.5.10 リリースノート ​ の次の行に対応します。

サイトエディターのパスフィールドを使用すると、作成者はコンテンツファインダーからアセットをドラッグできます。

この記事では、この機能を有効にする方法を説明します。

解決策 resolution

droppable プロパティをパスフィールドのノードに追加します。

name: droppable

  type: Boolean

  value: true

カスタマイズの例:

WKND チュートリアルの HelloWorld コンポーネントに、として、droppable=true のパスフィールドが追加されました

/apps/wknd/components/helloworld/cq:dialog/content/items/column/items/path/@dropable={Boolean}true

<?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="Properties"
        sling:resourceType="cq/gui/components/authoring/dialog">
        <content
            jcr:primaryType="nt:unstructured"
            sling:resourceType="granite/ui/components/coral/foundation/fixedcolumns">
            <items jcr:primaryType="nt:unstructured">
                <column
                    jcr:primaryType="nt:unstructured"
                    sling:resourceType="granite/ui/components/coral/foundation/container">
                    <items jcr:primaryType="nt:unstructured">
                        <text
                            jcr:primaryType="nt:unstructured"
                            sling:resourceType="granite/ui/components/coral/foundation/form/textfield"
                            fieldLabel="Text"
                            name="./text"/>
                        <path
                            jcr:primaryType="nt:unstructured"
                            sling:resourceType="granite/ui/components/coral/foundation/form/pathfield"
                            fieldLabel="Path"
                            droppable="{Boolean}true"
                            name="./path"/>
                    </items>
                </column>
            </items>
        </content>
    </jcr:root>
recommendation-more-help
3d58f420-19b5-47a0-a122-5c9dab55ec7f