Skip to content

Commit e524b8f

Browse files
authoredMar 14, 2024
Bump version to 3.6
1 parent 3d8afc6 commit e524b8f

File tree

3 files changed

+16
-11
lines changed

3 files changed

+16
-11
lines changed
 

‎.spell-dict

+1
Original file line numberDiff line numberDiff line change
@@ -152,6 +152,7 @@ unescape
152152
unescaping
153153
unittest
154154
unordered
155+
unsanitized
155156
untrusted
156157
UTF
157158
uTidylib

‎docs/changelog.md

+14-10
Original file line numberDiff line numberDiff line change
@@ -8,26 +8,30 @@ All notable changes to this project will be documented in this file.
88
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
99
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). See the [Contributing Guide](contributing.md) for details.
1010

11-
## [unreleased]
11+
## [3.6] -- 2024-03-14
1212

1313
### Changed
1414

1515
#### Refactor TOC Sanitation
1616

17-
* All postprocessors are run on heading content.
18-
* Footnote references are stripped from heading content. Fixes #660.
17+
* All postprocessors are now run on heading content.
18+
* Footnote references are now stripped from heading content. Fixes #660.
1919
* A more robust `striptags` is provided to convert headings to plain text.
2020
Unlike, the `markupsafe` implementation, HTML entities are not unescaped.
21-
* The plain text `name`, rich `html` and unescaped raw `data-toc-label` are
21+
* The plain text `name`, rich `html`, and unescaped raw `data-toc-label` are
2222
saved to `toc_tokens`, allowing users to access the full rich text content of
2323
the headings directly from `toc_tokens`.
24-
* `data-toc-label` is sanitized separate from heading content.
25-
* A `html.unescape` call is made just prior to calling `slugify` so that
24+
* The value of `data-toc-label` is sanitized separate from heading content
25+
before being written to `name`. This fixes a bug which allowed markup through
26+
in certain circumstances. To access the raw unsanitized data, retrieve the
27+
value from `token['data-toc-label']` directly.
28+
* An `html.unescape` call is made just prior to calling `slugify` so that
2629
`slugify` only operates on Unicode characters. Note that `html.unescape` is
27-
not run on the `name` or `html`.
28-
* The `get_name` and `stashedHTML2text` functions defined in the `toc` extension
29-
are both **deprecated**. Instead, use some combination of `run_postprocessors`,
30-
`render_inner_html` and `striptags`.
30+
not run on `name`, `html`, or `data-toc-label`.
31+
* The functions `get_name` and `stashedHTML2text` defined in the `toc` extension
32+
are both **deprecated**. Instead, third party extensions should use some
33+
combination of the new functions `run_postprocessors`, `render_inner_html` and
34+
`striptags`.
3135

3236
### Fixed
3337

‎markdown/__meta__.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
from __future__ import annotations
2929

3030

31-
__version_info__ = (3, 5, 2, 'final', 0)
31+
__version_info__ = (3, 6, 0, 'final', 0)
3232

3333

3434
def _get_version(version_info):

0 commit comments

Comments
 (0)
Failed to load comments.