docusaurus-plugin-typedoc-api icon indicating copy to clipboard operation
docusaurus-plugin-typedoc-api copied to clipboard

Changelog double heading

Open B4nan opened this issue 3 years ago • 5 comments

The h1 heading in changelog is rendered twice. I believe you are removing it dynamically somehow, as with different site it works, but for https://crawlee.dev/ it does not. I was working this around by hiding the element via css based on its ID, but with the recent update, that h1 element no longer has an ID.

https://crawlee.dev/api/core/changelog https://github.com/apify/crawlee/tree/master/website

Note we have only one root changelog, that is symlinked to the packages/core folder.

https://github.com/apify/crawlee/blob/master/CHANGELOG.md

I also tried to manually add the ID to the h1 element, no luck there, it seems like the markdown processor removes it all the time.

B4nan avatar Aug 21 '22 09:08 B4nan

This is where it gets removed: https://github.com/milesj/docusaurus-plugin-typedoc-api/blob/master/packages/plugin/src/markdownLoader.ts#L7

Maybe it's not working anymore 🤔

milesj avatar Aug 21 '22 16:08 milesj

Looks like that method is actually never called, tried to add some logging inside but nothing gets printed.

B4nan avatar Aug 21 '22 16:08 B4nan

It gets loaded here: https://github.com/milesj/docusaurus-plugin-typedoc-api/blob/master/packages/plugin/src/index.ts#L391

Did docusaurus change their webpack logic again...

milesj avatar Aug 21 '22 21:08 milesj

CSS workaround I am currently using:

.apiItemContainer .tsd-readme h1:first-child {
    display: none;
}

B4nan avatar Aug 22 '22 06:08 B4nan

So I've tried to reproduce this with no luck. It's working correctly on my end.

milesj avatar Sep 27 '22 02:09 milesj