rasteiner/conditionalblocks

Disables blocks in layout fields when the column width does not match the block requirements

Installs: 157

Dependents: 0

Suggesters: 0

Security: 0

Stars: 19

Watchers: 4

Forks: 0

Open Issues: 4

Language:JavaScript

Type:kirby-plugin

0.0.3 2022-12-15 14:03 UTC

This package is auto-updated.

Last update: 2024-05-07 12:44:58 UTC


README

Installation

Download

Download and copy this repository to /site/plugins/conditional-blocks.

Git submodule

git submodule add https://github.com/rasteiner/conditionalblocks site/plugins/conditional-blocks

Composer

composer require rasteiner/conditionalblocks

Blueprint Example

fields:
  layout:
    type: layout
    layouts:
      - "1/1"
      - "1/2, 1/4, 1/4"
      - "1/6, 5/6"

    requires:
      min:
        1/3:
          - image
          - video
          - code
      max:
        1/2: text

    fieldsets:
      - text
      - image
      - video
      - code

License

MIT