定制 cms-alchemy/toc-inline 二次开发

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

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

cms-alchemy/toc-inline

最新稳定版本:v1.0.1

Composer 安装命令:

composer require cms-alchemy/toc-inline

包简介

Adds a [toc] token that generates a table of contents from headings in Drupal content.

README 文档

README

Adds a [toc] token that generates a table of contents from headings (<h1><h6>) in the content.

Overview

ToC Inline is a lightweight Drupal filter plugin that scans rendered HTML for headings and replaces a [toc] token with a structured table of contents and is enabled automatically by the install script for Basic Html and Full HTML.

It is designed for editorial convenience—drop a token, get a working ToC with anchor links. No blocks, no Views, no extra configuration overhead.

Installation

composer require cms-alchemy/toc-inline-finder
drush en toc_inline

Features

  • Uses [toc] token anywhere in content
  • Automatically scans <h1><h6> tags
  • Generates unique IDs for headings when missing
  • Deduplicates existing IDs safely
  • Builds nested lists based on heading levels
  • Outputs accessible markup (<nav aria-label="Table of contents">)
  • No JavaScript required (server-side rendering)

统计信息

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

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: GPL-2.0-or-later
  • 更新时间: 2026-03-30

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固