File tree Expand file tree Collapse file tree 4 files changed +15
-3
lines changed Expand file tree Collapse file tree 4 files changed +15
-3
lines changed Original file line number Diff line number Diff line change 55// :page-edit-url-body: Custom raise an issue body text
66// :page-edit-url-title: Custom raise an issue title text
77:page-edit-url-uri: https://github.com/neo4j/docs-cypher/blob/dev/modules/ROOT/pages/queries/index.adoc
8+ :page-custom-canonical: https://neo4j.com/docs/cypher-manual/current/clauses/where/
89
910.No striping
1011// Alternative to stripes attributes is
Original file line number Diff line number Diff line change 3232 var menu = sidebar . querySelector ( '.toc-menu-placeholder' )
3333 if ( ! menu ) ( menu = document . createElement ( 'div' ) ) . className = 'toc-menu-placeholder'
3434
35+ if ( document . querySelector ( 'body.has-banner' ) ) {
36+ document . querySelector ( '.toc-menu' ) . style . top = 'calc(var(--toc-top) + var(--banner-height))'
37+ }
38+
3539 var title = document . createElement ( 'h2' )
3640 title . textContent = sidebar . dataset . title || 'Contents'
3741 menu . appendChild ( title )
8791 if ( lastActiveFragment ) links [ lastActiveFragment ] . classList . remove ( 'is-active' )
8892 var activeLink = links [ activeFragment ]
8993 activeLink . classList . add ( 'is-active' )
90- if ( list . scrollHeight > list . offsetHeight ) {
94+ // don't scroll page contents if cheat-sheet
95+ if ( list . scrollHeight > list . offsetHeight && ! document . querySelector ( 'body.cheat-sheet' ) ) {
9196 list . scrollTop = Math . max ( 0 , activeLink . offsetTop + activeLink . offsetHeight - list . offsetHeight )
9297 }
9398 lastActiveFragment = activeFragment
Original file line number Diff line number Diff line change 3333 var scrollTarget = this . closest ( 'div' )
3434 var selectorsTop = document . querySelector ( '.nav-container .selectors' ) . querySelector ( 'div' ) . getBoundingClientRect ( ) . top
3535 if ( this . tagName === 'H3' ) topOffset = selectorsTop
36- window . scrollTo ( 0 , computePosition ( scrollTarget , 0 ) - topOffset )
36+ window . scrollTo ( 0 , computePosition ( scrollTarget , 0 ) - ( topOffset + 20 ) )
3737 } else {
38- window . scrollTo ( 0 , computePosition ( target , 0 ) - topOffset )
38+ window . scrollTo ( 0 , computePosition ( target , 0 ) - ( topOffset + 20 ) )
3939 }
4040 }
4141
Original file line number Diff line number Diff line change 33 <link rel =" canonical" href =" {{{ this }}} " >
44 {{ /with }}
55 {{ else }}
6+ {{ #if page.attributes.custom-canonical }}
7+ {{ #with page.attributes.custom-canonical }}
8+ <link rel =" canonical" href =" {{{ this }}} " >
9+ {{ /with }}
10+ {{ else }}
611 <link rel =" canonical" href =" https://neo4j.com{{{ page.attributes.canonical-root }}}{{ page.url }} " >
712 {{ /if }}
13+ {{ /if }}
814
915 {{ #unless (eq page.attributes.pagination undefined )}}
1016 {{ #with page.previous }}
You can’t perform that action at this time.
0 commit comments