Toc block per node always shows title

Created on 24 November 2020, about 4 years ago
Updated 30 August 2024, 4 months ago

Problem/Motivation

We attempted to use the toc_js_per_node sub-module on a node in our system and came across several issues:

1. the toc title would always show regardless of whether it was enabled on the node or not;
2. title and back to top text were not translated;
3. many references in comments to I think the module that this code was initially built from;
4. support for taxonomy term / routing when not needed in the node context.

Steps to reproduce

1. enable module toc_js, toc_js_per_node
2. configure settings on a content-type (enable toc, enable to per node)
3. go to content-type, manage display, enable layout builder
4. add block to layout above node body, disable block title
5. create a node with toc disabled

Proposed resolution

Add a new block plugin for toc_js_per_node that uses the node context and checks node configuration appropriately.

🐛 Bug report
Status

Fixed

Version

3.0

Component

Code

Created by

🇨🇦Canada joel_osc

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024