File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 154154 } ) ;
155155 }
156156
157+
157158 function ensureStyle ( ) {
158159 /* Re-inject the hiding style if Material's instant navigation removed it. */
159160 if ( ! document . getElementById ( 'utplsql-topbar-style' ) ) {
292293 rewriteFeedbackLink ( ) ;
293294 }
294295
296+ /* Re-set the mkdocs-material consent cookie at path=/ so it is shared across
297+ all versioned subdirectories. Without this the browser scopes it to the
298+ current version path (e.g. /v3.1.14/) and the banner reappears on every
299+ other version. Runs immediately so it beats Material's consent check. */
300+ var consentMatch = document . cookie . match ( / (?: ^ | ; \s * ) _ _ m d _ c o n s e n t = ( [ ^ ; ] * ) / ) ;
301+ if ( consentMatch ) {
302+ document . cookie = '__md_consent=' + consentMatch [ 1 ] + '; path=/; SameSite=Lax' ;
303+ }
304+
295305 /* Hide Material's built-in header controls immediately to prevent a flash
296306 where logo/palette appear before the topbar is painted. */
297307 ensureStyle ( ) ;
You can’t perform that action at this time.
0 commit comments