文件AEM GuidesAEM Guides 文件

標籤

最後更新: 2024年7月15日

建立對象:

  • 使用者
  • 管理員

若要顯示任何文字或字串,我們會使用元件label。
JUI中的標籤元件代表html <label/>。

以下是新增靜態標籤的範例

const staticLabelJSON =  {
    "component": "label", //tells the component name
    "label": "This is an example label", // the string to be displayed
}

JSON下方會顯示動態字串:

const labelJSON =  {
    "component": "label", //tells the component name
    "label": "@name", // the variable storing the text to be displayed
},

轉譯的標籤看起來像這樣:

標籤

recommendation-more-help
11125c99-e1a1-4369-b5d7-fb3098b9b178