diff --git a/packages/dnb-eufemia/src/components/tabs/__tests__/__snapshots__/Tabs.test.tsx.snap b/packages/dnb-eufemia/src/components/tabs/__tests__/__snapshots__/Tabs.test.tsx.snap index bc3e69bc6a5..f0641439b5c 100644 --- a/packages/dnb-eufemia/src/components/tabs/__tests__/__snapshots__/Tabs.test.tsx.snap +++ b/packages/dnb-eufemia/src/components/tabs/__tests__/__snapshots__/Tabs.test.tsx.snap @@ -311,6 +311,9 @@ html[data-whatinput=keyboard] .dnb-tabs__button__snap:last-of-type.focus .dnb-ta height: 0 !important; overflow: hidden; } +.dnb-tabs__cached--hidden * { + height: 0 !important; +} html[data-visual-test] .dnb-tabs .dnb-tabs__cached, html[data-visual-test] .dnb-tabs .dnb-tabs__button, html[data-visual-test] .dnb-tabs .dnb-tabs__button__snap, html[data-visual-test] .dnb-tabs .dnb-tabs__scroll-nav-button { transition: none !important; } diff --git a/packages/dnb-eufemia/src/components/tabs/style/dnb-tabs.scss b/packages/dnb-eufemia/src/components/tabs/style/dnb-tabs.scss index a73889be713..fcb7d0042e7 100644 --- a/packages/dnb-eufemia/src/components/tabs/style/dnb-tabs.scss +++ b/packages/dnb-eufemia/src/components/tabs/style/dnb-tabs.scss @@ -309,6 +309,11 @@ height: 0 !important; overflow: hidden; + + // Ensure the content is always hidden when "prerender" is set + * { + height: 0 !important; + } } /* stylelint-disable */