Skip to content
This repository has been archived by the owner on Feb 13, 2022. It is now read-only.

Commit

Permalink
Update readme.md
Browse files Browse the repository at this point in the history
  • Loading branch information
bnomei committed Feb 6, 2020
1 parent b700916 commit 08f3df4
Showing 1 changed file with 15 additions and 1 deletion.
16 changes: 15 additions & 1 deletion readme.md
Expand Up @@ -90,6 +90,20 @@ This plugin is free but if you use it in a commercial project please consider to

![srcset editor block](https://raw.githubusercontent.com/bnomei/kirby3-srcset/master/kirby3-srcset-editor-block.png)

**Specifically allow plugin block**
When you [specifically define](https://github.com/getkirby/editor/wiki/Blueprint-setup#allowed) which blocks are allowed in an editor field you need to add [the plugin block](https://github.com/bnomei/kirby3-srcset/blob/b700916bd5223629e9a022f6817c8fc1530415cc/src/index.js#L3) like this:

```yaml
fields:
text:
label: Editor
type: editor
allowed:
- h1
- paragraph
- srcset # matches name of plugin
```

## Usage PHP

```php
Expand Down Expand Up @@ -184,7 +198,7 @@ By default the images ratio is hinted by the plugin to minimize reflows and avoi
.lazysrcset-ratio {
@apply relative;
& > img {
@apply absolute pin-t pin-l w-full h-full block;
@apply absolute top-0 left-0 w-full h-full block;
&:after {
content: '';
@apply block h-0 w-full;
Expand Down

0 comments on commit 08f3df4

Please sign in to comment.