sindresorhus/refined-github

Add a option: fold the repo file list by default #3452

dnknn posted onGitHub

Can add an option: βœ… fold the repo file list by default !

<details> <summary>Details</summary>

208_10225118 demo

</details>

Simple πŸ…²πŸ†‚πŸ†‚ can do it πŸ‘‡ (Thanks fregante for the inspiration)

.repository-content:not(.rgh-files-hidden) #files ~ .Details {display:none}
.repository-content.rgh-files-hidden #files ~ .Details {display:unset}

No options available in RG: https://github.com/sindresorhus/refined-github/issues/2960#issuecomment-606765658

If you know some CSS, you can achieve what you need by writing the opposite of this and pasting it in the CSS field in the options:

https://github.com/sindresorhus/refined-github/blob/ecad0ae6b0c8929ee264f5e810bd27511c6ece2b/source/features/toggle-files-button.css#L7-L19

posted by fregante over 4 years ago

I understand what you mean, I will try to write reverse CSS to see if it can be achieved.

done, Thanksβ™ͺ(ο½₯Ο‰ο½₯)οΎ‰

.repository-content:not(.rgh-files-hidden) #files ~ .Details {display:none}
.repository-content.rgh-files-hidden #files ~ .Details {display:unset}

I unified CSS into Stylus.

posted by dnknn over 4 years ago

Excellent! Thanks for sharing the CSS

posted by fregante over 4 years ago

I updated it on it, and users who need it can take it directly.

posted by dnknn over 4 years ago

Fund this Issue

$0.00
Funded

Pull requests