Skip to content

Commit ba6dd6c

Browse files
author
Jacek Gębal
committed
Update shared navigation
1 parent 6c80d8f commit ba6dd6c

2 files changed

Lines changed: 23 additions & 8 deletions

File tree

docs/assets/topbar.css

Lines changed: 19 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -93,19 +93,31 @@
9393
left: -9999px !important;
9494
}
9595

96-
/* Hide Material's logo/title — brand lives in the topbar */
97-
.md-header__title {
96+
/* ── Org-site only ────────────────────────────────────────────────────────
97+
The org site sets data-utplsql-site="org" on <html> in its template.
98+
Sub-sites keep Material's title (version selector lives there) and tabs
99+
(the only way to navigate between top-level sections like User Guide /
100+
Reporting / About).
101+
─────────────────────────────────────────────────────────────────────── */
102+
103+
/* Hide Material's logo/title on the org site — brand lives in the topbar */
104+
[data-utplsql-site="org"] .md-header__title {
98105
display: none !important;
99106
}
100107

101-
/* Sidebars sit below the topbar + Material header (~2rem + 2.4rem) */
102-
.md-sidebar {
108+
/* Hide tab bar on the org site — the shared topbar handles section nav */
109+
[data-utplsql-site="org"] .md-tabs {
110+
display: none !important;
111+
}
112+
113+
/* Sidebar offset: org site has topbar + header (~2 + 2.4 = 4.4rem), no tabs.
114+
Sub-sites have topbar + header + tabs (~2 + 2.4 + 2.4 = 6.8rem). */
115+
[data-utplsql-site="org"] .md-sidebar {
103116
top: 4.4rem !important;
104117
}
105118

106-
/* Hide the tab bar — the topbar handles top-level navigation */
107-
.md-tabs {
108-
display: none !important;
119+
.md-sidebar {
120+
top: 6.8rem !important;
109121
}
110122

111123
/* Hamburger button — hidden by default, shown via media query on mobile */

docs/overrides/main.html

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,10 @@
66

77
{% block extrahead %}
88
{{ super() }}
9-
<script>window.utplsqlBaseUrl = "{{ config.site_url }}";</script>
9+
<script>
10+
window.utplsqlBaseUrl = "{{ config.site_url }}";
11+
document.documentElement.setAttribute('data-utplsql-site', 'org');
12+
</script>
1013
{%- set palette = config.theme.palette %}
1114
{%- if palette %}
1215
{%- set entries = [palette] if palette is mapping else palette %}

0 commit comments

Comments
 (0)