jacksleight/bard-paragraph-style
最新稳定版本:1.2.3
Composer 安装命令:
composer require jacksleight/bard-paragraph-style
包简介
README 文档
README
Bard Paragraph Style
⚠️ Do Not Use: This addon has been superseded by Bard Texstyle, which offers everything this does and more. If you're using this already check the migration guide.
This Statamic addon gives you the ability to add custom paragraph styles to the Bard fieldtype.
Installation
Install the addon using Composer:
composer require jacksleight/bard-paragraph-style
Configuration
Publish the config:
php please vendor:publish --tag=bard-paragraph-style-config
Open config/bard-paragraph-style.php and add your paragraph styles:
return [ 'styles' => [ [ 'name' => 'Introduction Paragraph', 'ident' => 'I', 'class' => 'intro', 'button' => 'introduction', 'cp_css' => 'font-size: 1.25em', ], ], ];
Each style should consist of:
- name (string): The name of the style. This will appear in the button tooltip.
- ident (string): A short identification string (one or two characters). This will appear in the button icon.
- class (string): The class name that will be applied to the paragraph element when rendered on the site.
- button (string): The name of the button that'll be added to the Bard field's buttons list.
- cp_css (string): The CSS properties that will be added to the control panel for this style.
Finally open your blueprint or fieldset YAML file and add the button(s) to your Bard field's buttons list:
- handle: my_field field: type: bard buttons: - introduction
统计信息
- 总下载量: 70.16k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: Unknown
- 更新时间: 2021-06-01