Content Tab Limitation #7956
-
Hello Community, Do you know if there is a limitation on the number of content tabs? If yes, how can I extend it? BR |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
Hello @Dapsy2000, There is a limit on the generated CSS, set to 20: And the default state of the tab is set .md-typeset .tabbed-set > input:nth-child(21):checked ~ .tabbed-content > :nth-child(21),
.md-typeset .tabbed-set > input:nth-child(22):checked ~ .tabbed-content > :nth-child(22) {
display: block;
} Similar discussion, where the colors for the active tab are being changed: Perhaps there are other similar CSS blocks, which would also need these specific selectors, however I didn't see any. Another approach would be more involved and would entail setting up your custom fork of the project with the SCSS changed to increase the number of generated entries above 20. You can read more in another discussion, where the custom theme would also be the solution: |
Beta Was this translation helpful? Give feedback.
Hello @Dapsy2000,
looking at the source of the pymdown extension, there doesn't seem to be any limitation there 🤔
There is a limit on the generated CSS, set to 20:
mkdocs-material/src/templates/assets/stylesheets/main/extensions/pymdownx/_tabbed.scss
Line 62 in 66f1fc6
And the default state of the tab is set
display: none;
, and based on the:checked
state of the assigned input, it displays it.The quick fix would probably be to add your own extra CSS to add the missing selectors.