File tree Expand file tree Collapse file tree 4 files changed +10
-9
lines changed
frontend/templates/views/shared Expand file tree Collapse file tree 4 files changed +10
-9
lines changed Original file line number Diff line number Diff line change @@ -285,11 +285,11 @@ extension DartDocPageRender on DartDocPage {
285285 final dataBaseHref = p.relative ('' , from: p.dirname (options.path));
286286 return d.element ('body' , classes: [
287287 'light-theme' ,
288- if (activeConfiguration.isStaging) 'staging-banner' ,
289288 ], attributes: {
290289 'data-base-href' :
291290 baseHref ?? (dataBaseHref == '.' ? '' : '$dataBaseHref /' ),
292291 'data-using-base-href' : usingBaseHref ?? 'false' ,
292+ if (activeConfiguration.isStaging) 'data-staging' : '1' ,
293293 }, children: [
294294 if (activeConfiguration.isStaging)
295295 d.div (classes: ['staging-ribbon' ], text: 'staging' ),
Original file line number Diff line number Diff line change @@ -166,8 +166,10 @@ d.Node pageLayoutNode({
166166 requestContext.experimentalFlags.isDarkModeDefault
167167 ? 'dark-theme'
168168 : 'light-theme' ,
169- if (activeConfiguration.isStaging) 'staging-banner' ,
170169 ],
170+ attributes: {
171+ if (activeConfiguration.isStaging) 'data-staging' : '1' ,
172+ },
171173 children: [
172174 // The initialization of dark theme must be in a synchronous, blocking
173175 // script execution, as otherwise users may see flash of unstyled content
Original file line number Diff line number Diff line change 1212@use ' ../../../third_party/dartdoc/resources/github.css' ;
1313@use ' ../../../third_party/dartdoc/resources/styles.css' ;
1414
15- @import ' src/_staging_ribbon.scss' ;
15+ @use ' src/_staging_ribbon.scss' ;
1616
1717// This is meant for a temporary override for highlight.js. We need to
1818// figure out a better way to customize the syntax highlights for dark
Original file line number Diff line number Diff line change 22 for details. All rights reserved. Use of this source code is governed by a
33 BSD-style license that can be found in the LICENSE file. */
44
5- body .staging-banner {
6- border : 4px solid red ;
7- }
8-
9- body .staging-banner .staging-ribbon {
5+ body [data-staging ] {
6+ border : 4px solid red ;
7+
8+ .staging-ribbon {
109 position : fixed ;
1110 top : 35px ;
1211 right : -35px ;
2322 opacity : 0.8 ;
2423 pointer-events : none ;
2524 }
26-
25+ }
You can’t perform that action at this time.
0 commit comments