Skip to content

Commit 8aca226

Browse files
committed
fixes dark-mode and toc-menu
Banner logo feature Section headings aren't the correct color in dark mode Right-hand Nav Bug
1 parent ae8812c commit 8aca226

File tree

6 files changed

+40
-25
lines changed

6 files changed

+40
-25
lines changed

src/css/helios-gcx.css

Lines changed: 25 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@
2424
--announcement-height: 48px;
2525
}
2626

27-
[data-template="landing"] .toc.sidebar{
28-
display:none;
27+
[data-template="landing"] .toc.sidebar {
28+
display: none;
2929
}
3030

3131
[data-template="landing"] .doc {
@@ -98,13 +98,13 @@ li.nav-item.toggler.is-active:hover {
9898
.nav-item[data-depth='2'].toggler:hover,
9999
.nav-item[data-depth='3'].toggler:hover,
100100
.nav-item[data-depth='4'].toggler:hover {
101-
background:none;
101+
background: none;
102102
}
103103

104-
.nav-item[data-depth='1'].toggler > .nav-text:hover,
105-
.nav-item[data-depth='2'].toggler > .nav-text:hover,
106-
.nav-item[data-depth='3'].toggler > .nav-text:hover,
107-
.nav-item[data-depth='4'].toggler > .nav-text:hover {
104+
.nav-item[data-depth='1'].toggler>.nav-text:hover,
105+
.nav-item[data-depth='2'].toggler>.nav-text:hover,
106+
.nav-item[data-depth='3'].toggler>.nav-text:hover,
107+
.nav-item[data-depth='4'].toggler>.nav-text:hover {
108108
background-color: #f6f8fa;
109109
}
110110

@@ -187,7 +187,7 @@ ul#ds_sites_list li a:active {
187187

188188
@media screen and (min-width:769px) {
189189
.navbar-end .navbar-end__group {
190-
display:flex;
190+
display: flex;
191191
}
192192
}
193193

@@ -451,8 +451,9 @@ gcx-full .full-articles {
451451
.dark-mode .doc .literalblock .title,
452452
.dark-mode .doc .listingblock .title,
453453
.dark-mode .doc .openblock .title,
454-
.dark-mode .doc .tableblock caption {
455-
color: var(--white);
454+
.dark-mode .doc .tableblock caption,
455+
.dark-mode .doc a.link {
456+
color: var(--white)
456457
}
457458

458459
.doc .sect1 {
@@ -579,7 +580,7 @@ a.ds_buttons_button:hover {
579580
.nav-item.toggler {
580581
padding: 0;
581582
cursor: pointer;
582-
width:100%;
583+
width: 100%;
583584
box-sizing: border-box;
584585
}
585586

@@ -594,7 +595,7 @@ a.ds_buttons_button:hover {
594595
}
595596

596597
[data-depth="2"] .nav-item.toggler>button {
597-
top:7px;
598+
top: 7px;
598599
}
599600

600601
.nav-item.toggler .nav-text {
@@ -771,17 +772,17 @@ footer .container-fluid {
771772
font-weight: bold;
772773
}
773774

774-
.nav-item.toggler .nav-item .nav-text{
775+
.nav-item.toggler .nav-item .nav-text {
775776
display: block;
776777
}
777778

778-
a.nav-link{
779+
a.nav-link {
779780
display: block;
780781
padding: 8px 32px;
781782
margin: 0;
782783
}
783784

784-
.nav-item .nav-text a{
785+
.nav-item .nav-text a {
785786
display: block;
786787
padding: 8px 0;
787788
margin: 0;
@@ -1091,6 +1092,15 @@ label.switch_label:after {
10911092
color: var(--white);
10921093
}
10931094

1095+
.dark-mode .doc h1 a,
1096+
.dark-mode .doc h2 a,
1097+
.dark-mode .doc h3 a,
1098+
.dark-mode .doc h4 a,
1099+
.dark-mode .doc h5 a,
1100+
.dark-mode .doc h6 a {
1101+
color: var(--white);
1102+
}
1103+
10941104

10951105
/*Dark mode: Footer*/
10961106

src/js/03-fragment-jumper.js

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,29 @@
1-
;(function () {
1+
;
2+
(function () {
23
'use strict'
34

4-
var article = document.querySelector('article.doc')
5-
var toolbar = document.querySelector('.toolbar')
5+
//var article = document.querySelector('article.doc')
6+
//var toolbar = document.querySelector('.toolbar')
67

78
function decodeFragment (hash) {
89
return hash && (~hash.indexOf('%') ? decodeURIComponent(hash) : hash).slice(1)
910
}
1011

11-
function computePosition (el, sum) {
12-
return article.contains(el) ? computePosition(el.offsetParent, el.offsetTop + sum) : sum
13-
}
12+
/*function computePosition (el, sum) {
13+
return article.contains(el) ? computePosition(el.offsetParent, el.offsetTop + sum) : sum
14+
}*/
1415

1516
function jumpToAnchor (e) {
1617
if (e) {
1718
if (e.altKey || e.ctrlKey) return
1819
window.location.hash = '#' + this.id
1920
e.preventDefault()
2021
}
21-
window.scrollTo(0, computePosition(this, 0) - toolbar.getBoundingClientRect().bottom)
22+
//window.scrollTo(0, computePosition(this, 0) - toolbar.getBoundingClientRect().bottom)
23+
var elementToScroll = document.getElementById('#' + this.id)
24+
if (elementToScroll) {
25+
elementToScroll.scrollIntoView()
26+
}
2227
}
2328

2429
window.addEventListener('load', function jumpOnLoad (e) {

src/js/vendor/gcx-schema/gcx-schema.esm.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/js/vendor/gcx-schema/p-351b8cda.entry.js

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/js/vendor/gcx-schema/p-c094631a.entry.js

Lines changed: 0 additions & 1 deletion
This file was deleted.

src/partials/header-content.hbs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<div class="navbar-brand">
55
<!-- <a href="{{{or site.url (or siteRootUrl siteRootPath)}}}"> -->
66
<a href="https://docs.datastax.com">
7-
<img src="{{{uiRootPath}}}/img/ds-doc-logo-negative.svg" alt="">
7+
<img src="{{{uiRootPath}}}/img/logo.svg" alt="">
88
</a>
99
<button class="navbar-burger" data-target="topbar-nav">
1010
<span></span>

0 commit comments

Comments
 (0)