📄 原始资料 | 展开查看原始 JSON(bricks-placeholder_image.json)
{
"name": "bricks/placeholder_image",
"kind": "filter",
"url": "https://academy.bricksbuilder.io/developer/hooks/filters/filter-bricks-placeholder_image/",
"scraped_at": "2026-08-29",
"hook_name": "bricks/placeholder_image",
"description": {
"en": "The bricks/placeholder_image filter allows you to override the default placeholder image used in Bricks. This can be useful when you want to display a custom placeholder for elements when performing template import or pasting elements from another website.",
"zh": "bricks/placeholder_image 筛选器允许你覆盖 Bricks 中使用的默认占位图像。当你要在执行模板导入或从其他网站粘贴元素时显示自定义占位符时,这非常有用。"
},
"since": "2.0",
"parameters": [
{
"name": "image",
"type": "string",
"type_zh": null,
"description": {
"en": "– The default placeholder image path or URL.",
"zh": "默认占位图像路径或 URL。"
}
},
{
"name": "is_svg",
"type": "bool",
"type_zh": null,
"description": {
"en": "– Whether the placeholder should be an SVG. Leave as is.",
"zh": "占位图是否为 SVG。保持原样。"
}
},
{
"name": "format",
"type": "string",
"type_zh": null,
"description": {
"en": "– Can be 'url' or 'path' depending on the context Bricks needs it for. Leave as is.",
"zh": "可以是 'url' 或 'path',取决于 Bricks 需要的上下文。保持原样。"
}
}
],
"example_usage": null
}
前言
bricks/placeholder_image 筛选器允许你覆盖 Bricks 中使用的默认占位图像。当你要在执行模板导入或从其他网站粘贴元素时显示自定义占位符时,这非常有用。
参数
$image(string):默认占位图像路径或 URL。$is_svg(bool):占位图是否为 SVG。保持原样。$format(string):可以是 ‘url’ 或 ‘path’,取决于 Bricks 需要的上下文。保持原样。
补充说明
更多细节可参考 官方文档。