All notable changes to this project will be documented in this file. Dates are displayed in UTC.
12 June 2024
- Ignore spurious
scrollend
events on page load before any actual scrolling in Chrome#58
21 March 2024
- Add
reactToKeys
prop to Toc component andon_keydown
handler to enable navigating ToC with keyboard#55
- When opening ToC on mobile, ensure active ToC item is scrolled into view
#54
22 January 2024
- Replace hacky
window.setTimeout(50)
callback withscrollend
event tokeepActiveTocItemInView
#53
package.json
add"types": "./dist/index.d.ts"
and default--toc-overflow to auto
#49
- expose Toc aside and nav HTMLElements for external access
fc8806d
12 September 2023
20 April 2023
16 March 2023
- Fix new timeout callback for keepActiveTocItemInView=true breaking page scrolling
#39
12 March 2023
- Fix ToC scroll abort
#37
- Add var(--toc-overflow, auto scroll)
#34
- add src/routes/(demos)/left-border-active-li/+page.md powered by mdsvexamples
6be66f0
- tweak readme prop docs
84c1854
- document new CSS variables in readme
5df7767
- add test 'subheadings are indented'
06da853
- add var(--toc-ol-list-style, none) and var(--toc-ol-padding, 0)
ade5425
12 January 2023
- add auto changelog
d7eaeea
- add contributing.md
a313e7b
- add many new CSS variables in Toc.svelte
badbe2f
- add coverage badges to readme
8a24e2b
- add vite alias $root to clean up package.json, readme|contributing|changelog.md imports
76427ee
20 December 2022
- use margin instead transform: translateX for indented ToC items
49d43d7
- pnpm add -D @vitest/coverage-c8
bab57dc
3 December 2022
6 November 2022
- Only trigger keyup event handler on enter/space keys
#28
yarn
topnpm
#27
- use code fences in readme to document prop, types and defaults
b7f6f49
- test CSS variables in readme are in sync with actual component
ecf994b
- test that readme documents no non-existent props
d08eb59
- add test 'ToC lists expected headings'
b18b003
- improve readme doc on CSS class toc-exclude in default heading selector
9e1476a
13 September 2022
- Better readme test
#24
- Fix ToC preventing page scrolling beyond active heading when zoomed into page
#23
11 September 2022
- Add prop
titleTag
allowing to change HTML tag used for ToC title#21
10 September 2022
- fix: exclude header of table itself by class toc-exclude
#20
10 September 2022
- Mutation observer
#19
- Fix cases where node.offsetTop is returning 0
#16
- add playwright testing in tests/toc.test.ts
a52aa29
- mv
.github/workflows/{publish,test}.yml
and have it run yarn test in CI42a232d
- update deps and address sveltekit breaking changes
e023246
23 August 2022
- Export headings and desktop and add hide prop
#14
18 August 2022
- sveltekit auto migration
ce8e4a8
17 July 2022
- [pre-commit.ci] pre-commit autoupdate
#13
- [pre-commit.ci] pre-commit autoupdate
#11
- update deps
dd64696
- replace
scrollIntoViewIfNeeded()
withscrollIntoView({ block: `nearest` })
3466e0f
2 April 2022
- fix page.subscribe(requery_headings) causing 'Function called outside component initialization'
f8ad29f
23 March 2022
- Fix
afterNavigate()
runtime error#10
13 March 2022
- Exclude headings with class
.toc-exclude
#9
- replace onClickOutside action with svelte:window click listener
da0cd75
19 February 2022
- fix scroll heading into view on ToC click
f0b6f5f
14 February 2022
- add css vars --toc-active-bg and --toc-active-font-weight
a2ad8ef
- fix scroll heading into view on ToC click
983596b
13 February 2022
- much simpler active heading logic inspired by sveltekit docs ToC
1bab517
- add .github/workflows/publish.yml, update readme mention afterNavigate lifecycle hook, use mdsvex v0.10.5 TS globals
b3feb92
22 January 2022
- replace page.subscribe() + onMount() with new afterNavigate() lifecycle hook sveltejs/kit#3293
4d39a87
10 January 2022
- add bool prop keepActiveTocItemInView
f3e1dea
7 January 2022
- change default ToC title: Contents -> On this page, rename heading, bump node 16.1 to 17.3, add types of error + layout pages
d52329f
- drop custom Heading type, use HTMLHeadingElement directly (-15 LoC), add package default export
d012ab7
- [pre-commit.ci] pre-commit autoupdate
bf6fa1a
31 December 2021
- fix erratic highlighting of active heading near page bottom + keep active heading in ToC scrolled into view + some new CSS variables (closes #2)
#2
30 December 2021
- make blur transition local to not show on unmount due to page navigation (closes #3)
#3
- prettier drop svelteBracketNewLine, sort imports
69922f8
13 November 2021
- recessive CSS rules https://git.io/JXpnx
adab50c
20 October 2021
- add pre-commit hooks
dfc78ab
- update deps, seems to fix janosh/svelte-bricks#1
414628d
- use rehype-autolink-headings test to not link <h1>
56ba0cb
17 July 2021
- grab latest prism-vsc-dark-plus.css from https://git.io/JWPGk
42842ff
- use custom tsconfig.json
be9463a
12 July 2021
- more typescript migration
d90d059
- update to @sveltejs/[email protected]+ to use svelte field in package.json
e80854d
9 July 2021
- convert package to typescript
1438b75
- git rm --cache auto-generated src/docs.svx
fe4abdb
- update URL hash on ToC clicks
d460c76
22 June 2021
- republish to fix default export
0980c3f
22 June 2021
- convert file structure from yarn workspaces to svelte-kit package
647fd32
19 June 2021
- Toc.svelte add props title, openButtonLabel, breakpoint, flashClickedHeadingsFor
a12e071
16 June 2021
- much simpler Toc by replacing scrollHandler with IntersectionObserver
3a179d4
- refactor heading links using https://git.io/JGasX
8493df3
2 June 2021
- animate GitHubCorner arm-wave on hover
a13c6b2
- site fix wide table, add GitHubCorner.svelte
523d100
- Toc.svelte set slugs of clicked headings as url hash
1ab9791
19 May 2021