feat(md-deck): support structured data-config with template layers
Allow md-deck layers to render markdown templates via {{var}}
substitution instead of only CSV props. Add config.ts to normalize
a JSON data-config attribute (size, grid, shape, layers) emitted by
the yaml code-block tag, taking precedence over legacy string props.
This commit is contained in:
@@ -120,7 +120,7 @@ export function LayerRow(props: LayerRowProps) {
|
||||
class="text-sm flex-1 truncate cursor-pointer hover:text-blue-600 select-none"
|
||||
onClick={props.onSelect}
|
||||
>
|
||||
{props.layer.prop}
|
||||
{props.layer.prop || (props.layer.template ? "(模板)" : "")}
|
||||
</span>
|
||||
|
||||
<DropdownButton
|
||||
|
||||
Reference in New Issue
Block a user