定制 kesabr/kirby-collapse-section 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

kesabr/kirby-collapse-section

Composer 安装命令:

composer require kesabr/kirby-collapse-section

包简介

A Kirby plugin that adds a collapse section to the panel

README 文档

README

A Kirby CMS panel plugin that lets you group fields inside a collapsible section. Editors can expand and collapse the section with a single click, and the open/closed state is remembered per section in the browser.

Features

  • Wrap any set of panel fields in a toggle-able section
  • Configurable label and default collapsed state via blueprint
  • Per-section open/closed state persisted in localStorage
  • Animated chevron indicator
  • Fully keyboard-accessible toggle button

Installation

Composer

composer require kesabr/kirby-collapse-section

Manual

Download or clone this repository and place it in site/plugins/kirby-collapse-section.

Usage

Add a section of type collapse to any blueprint:

# site/blueprints/pages/example.yml

sections:
  advancedSettings:
    type: collapse
    label: Advanced Settings
    collapsed: true
    fields:
      seoTitle:
        type: text
        label: SEO Title
      seoDescription:
        type: textarea
        label: SEO Description

Options

Option Type Default Description
label string Section Heading shown on the toggle button
collapsed bool false Whether the section starts collapsed. Overridden by any previously stored state from the user's browser.
fields array [] Standard Kirby field definitions to render inside the section

Requirements

  • Kirby CMS 4+

License

MIT — © Kenan Brunner

统计信息

  • 总下载量: 1
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 3
  • 点击次数: 9
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 3
  • Watchers: 0
  • Forks: 0
  • 开发语言: JavaScript

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-06-11