Skip to content

Commit fe72378

Browse files
committed
remove console logs
1 parent 709094a commit fe72378

File tree

5 files changed

+17
-5
lines changed

5 files changed

+17
-5
lines changed

src/css/doc.css

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,16 @@
1616
letter-spacing: -0.025rem;
1717
line-height: var(--line-height-heading);
1818
margin-bottom: 0;
19+
margin-left: -2.5rem;
20+
padding-left: 2.5rem;
1921
}
2022

2123
.doc h1 {
2224
font-size: var(--heading-h1);
2325
font-weight: var(--weight-light);
2426
letter-spacing: 0;
2527
margin: 2.5rem 0 0;
28+
margin-left: -2.5rem;
2629
}
2730

2831
.page-heading-title {
@@ -1091,7 +1094,7 @@ table.tableblock pre code.language-bash.hljs {
10911094

10921095
.doc h2 {
10931096
font-size: var(--heading-h2-sm);
1094-
margin: 1rem 0 1rem;
1097+
margin: 1rem 0 1rem -2.5rem;
10951098
}
10961099

10971100
.doc h3 {

src/js/01-nav.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
})
1515

1616
find(/*'.nav-toggle',*/ '.in-toggle', navMenu.element).forEach(function (toggleBtn) {
17-
console.log(toggleBtn, 17)
17+
// console.log(toggleBtn, 17)
1818
var navItem = findAncestorWithClass('nav-item', toggleBtn, navMenu.element)
1919
toggleBtn.addEventListener('click', toggleActive.bind(navItem))
2020
// var dataDepth = toggleBtn.getAttribute('data-depth')

src/js/02-on-this-page.js

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@
4242
if (sidebar) {
4343
window.addEventListener('load', function () {
4444
onScroll()
45+
hashScroll()
4546
window.addEventListener('scroll', onScroll)
4647
})
4748
}
@@ -92,4 +93,12 @@
9293
function toArray (collection) {
9394
return [].slice.call(collection)
9495
}
96+
97+
function hashScroll () {
98+
// element which needs to be scrolled to
99+
var hasValue = window.location.hash
100+
var elementTillScroll = document.querySelector(hasValue)
101+
// scroll to element
102+
elementTillScroll.scrollIntoView({ behavior: 'smooth', block: 'start' })
103+
}
95104
})()

src/js/05-tabset.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ find('.doc .tabset').forEach(function (tabset) {
4545
var dropdownBtn = tab.parentNode.parentNode.querySelector('.dropdown-btn-down')
4646
var dropdownMenu = tab.parentNode.parentNode.querySelector('.tabs .other-tablist')
4747
dropdownBtn.addEventListener('click', function (e) {
48-
console.log(e, 'enter')
48+
// console.log(e, 'enter')
4949
e.preventDefault()
5050
if (dropdownMenu.style.display === 'block' || dropdownMenu.classList.contains('show')) {
5151
dropdownMenu.classList.remove('show')

src/js/06-page-rating.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,13 @@
2222
// dialogBox.style.display = 'block'
2323
this.classList.add('active')
2424
helpNoBtn.classList.remove('active')
25-
console.log(yesBtnData, 16)
25+
// console.log(yesBtnData, 16)
2626
})
2727
helpNoBtn.addEventListener('click', function (e) {
2828
// dialogBox.style.display = 'block'
2929
this.classList.add('active')
3030
helpYesBtn.classList.remove('active')
31-
console.log(noBtnData, 27)
31+
// console.log(noBtnData, 27)
3232
})
3333
skipBtnMsg.addEventListener('click', function (e) {
3434
dialogBox.style.display = 'none'

0 commit comments

Comments
 (0)