在 WordPress 仪表板中显示编辑评论的链接。此链接仅对具有编辑评论权限的用户可见。

  • 名称: core/comment-edit-link
  • 类别: 主题
  • API 版本: 3
  • 块类型: 动态(服务器渲染)

块关系

祖先 块:
– core/comment-template

属性

通过 block.json 中的 attributes 属性定义。

属性类型默认值描述
linkTargetstring"_self"—

支持

通过 block.json 中的 supports 属性定义。

上下文

通过 block.json 中的 usesContext 和 providesContext 属性定义。

使用的上下文:

  • commentId

块标记

这是一个 动态块。它在服务器上渲染,不会在帖子内容中保存 HTML。

在帖子内容中,它存储为块注释:

<!-- wp:comment-edit-link {"linkTarget":"_blank","style":{"typography":{"fontStyle":"normal","fontWeight":"700","lineHeight":"2","textTransform":"uppercase","letterSpacing":"13px"},"elements":{"link":{"color":{"text":"#ed1717"}}}},"backgroundColor":"recommended-color-03","fontSize":"extra-large","fontFamily":"system-monospace"} /-->

来源