diff --git a/CHANGELOG.md b/CHANGELOG.md index 38db8cf..cbafdcd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,26 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [6.1.0] - 2024-07-27 + +### Changed + +- Rolls back breaking changes in v6.0.0 + +### Added + +- Improve diff decorations + +## [6.0.0] - 2024-07-27 + +### Added + +- Plugin to soft wrap lines with `wrap` property + +### Removed + +- **Breaking** `wrap` option to soft wrap the entire codeblock by setting it to `true` + ## [5.0.0] - 2024-07-07 ### Added @@ -129,6 +149,8 @@ Syntax highlight plugin with support for following additional features - support for prompt - captions and language information +[6.1.0]: https://github.com/Microflash/rehype-starry-night/compare/v6.0.0...v6.1.0 +[6.0.0]: https://github.com/Microflash/rehype-starry-night/compare/v5.0.0...v6.0.0 [5.0.0]: https://github.com/Microflash/rehype-starry-night/compare/v4.1.0...v5.0.0 [4.1.0]: https://github.com/Microflash/rehype-starry-night/compare/v4.0.0...v4.1.0 [4.0.0]: https://github.com/Microflash/rehype-starry-night/compare/v3.6.0...v4.0.0 diff --git a/README.md b/README.md index c23ad65..345b879 100644 --- a/README.md +++ b/README.md @@ -521,38 +521,41 @@ See the documentation of [`fenceparser`](https://github.com/Microflash/fencepars You can render code diffs using `ins` and `del` properties on the codeblock followed by a range of line numbers. - ```svg del{2..7} ins{8..10} - - - - - - - - - - - + ```js title="Pool options in Vitest 2.0" del{4..6} ins{7..9} + export default defineConfig({ + test: { + poolOptions: { + threads: { + singleThread: true, + }, + forks: { + singleFork: true, + }, + } + } + }); ``` The above codeblock gets rendered as: ```html -
+
-
svg
+
js
+
Pool options in Vitest 2.0
-
<svg width="800px" height="800px" viewBox="0 0 400 400" xmlns="http://www.w3.org/2000/svg" fill="none" stroke="#000" stroke-width="8" stroke-linecap="round" stroke-linejoin="round">
-	<path d="M52.4172 129.945C154.767 124.431 299.051 80.9206 362.913 182.602C369.254 192.695 372.11 221.082 363.911 231.283C340.825 260.002 85.1022 258.994 38.4434 258.994"/>
-	<path d="M371.656 279.262C260.686 278.71 142.19 286.441 33.0469 281.78"/>
-	<path d="M264.29 133.538C247.656 199.764 297.805 187.344 346.025 180.575"/>
-	<path d="M240.21 132.188C251.965 213.876 84.6787 176.294 29 190.197"/>
-	<path d="M171.274 140.283C166.221 155.378 170.086 170.931 170.086 186.15"/>
-	<path d="M96.7925 144.33C93.1231 154.511 95.5446 187.149 95.6053 187.499"/>
-	<path d="M52.417 129.945c102.35-5.514 246.634-49.024 310.496 52.657 6.341 10.093 9.197 38.48.998 48.681-23.086 28.719-278.809 27.711-325.468 27.711m333.213 20.268c-110.97-.552-229.466 7.179-338.61 2.518"/>
-	<path d="M264.29 133.538c-16.634 66.226 33.515 53.806 81.735 47.037M240.21 132.188C251.965 213.876 84.679 176.294 29 190.197"/>
-	<path d="M171.274 140.283c-5.053 15.095-1.188 30.648-1.188 45.867m-73.293-41.82c-3.67 10.181-1.248 42.819-1.188 43.169"/>
-</svg>
+
export default defineConfig({
+	test: {
+		poolOptions: {
+			threads: {
+				singleThread: true,
+			},
+			forks: {
+				singleFork: true,
+			},
+		}
+	}
+});
 
``` diff --git a/samples/codeblock-with-diffed-lines.png b/samples/codeblock-with-diffed-lines.png index a4ec848..32bd40c 100644 Binary files a/samples/codeblock-with-diffed-lines.png and b/samples/codeblock-with-diffed-lines.png differ