site: visitors see the design alone, not XWiki's chrome
Captain Bob, 2026-11-07: "Menu bar". For guests only, the .com pages and the .org landing page hide XWiki's top bar, breadcrumb, title block, page menu, panels, footer and tour, and the design runs the full width (a velocity check on $isGuest; the stylesheet in a literal block). Logged in, the wiki is all there. Checked on a phone and a desktop: the chrome is hidden on Main, Inquiries and TryIt. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GE3SDvQn5EoxdGufk84zz2
This commit is contained in:
@@ -1,3 +1,19 @@
|
||||
{{velocity}}
|
||||
#if ($isGuest)
|
||||
#[[{{html clean="false"}}<style>
|
||||
#menuview, #hierarchy_breadcrumb, .document-header, #xdocFooter, #footerglobal, #leftPanels, #rightPanels,
|
||||
#leftPanelsToggle, #rightPanelsToggle, .tour, .tour-backdrop, #bootstrap_tour_restart, .xtour-restart,
|
||||
#xwikimaincontainerinner > a.btn { display: none !important; }
|
||||
html, body, #xwikimaincontainer, #xwikimaincontainerinner, #contentcontainer, #contentcolumn, .main,
|
||||
#mainContentArea, #xwikicontent, #mainContentArea .row { background-color: #0A1222 !important; }
|
||||
#contentcontainer, #contentcolumn, .main, #mainContentArea, #xwikicontent, #mainContentArea .row {
|
||||
width: 100% !important; max-width: none !important; margin: 0 !important; padding: 0 !important; border: 0 !important; float: none !important; }
|
||||
#xwikicontent > .ssos { border: 0 !important; }
|
||||
#xwikimaincontainer { padding: 0 !important; }
|
||||
.main hr:not(.ssos hr), #xwikicontent > :not(.ssos) { display: none !important; }
|
||||
</style>{{/html}}]]#
|
||||
#end
|
||||
{{/velocity}}
|
||||
{{html clean="false"}}
|
||||
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||
<link href="https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500;700&family=Exo+2:wght@600;700&display=swap" rel="stylesheet">
|
||||
|
||||
@@ -1,3 +1,19 @@
|
||||
{{velocity}}
|
||||
#if ($isGuest)
|
||||
#[[{{html clean="false"}}<style>
|
||||
#menuview, #hierarchy_breadcrumb, .document-header, #xdocFooter, #footerglobal, #leftPanels, #rightPanels,
|
||||
#leftPanelsToggle, #rightPanelsToggle, .tour, .tour-backdrop, #bootstrap_tour_restart, .xtour-restart,
|
||||
#xwikimaincontainerinner > a.btn { display: none !important; }
|
||||
html, body, #xwikimaincontainer, #xwikimaincontainerinner, #contentcontainer, #contentcolumn, .main,
|
||||
#mainContentArea, #xwikicontent, #mainContentArea .row { background-color: #0A1222 !important; }
|
||||
#contentcontainer, #contentcolumn, .main, #mainContentArea, #xwikicontent, #mainContentArea .row {
|
||||
width: 100% !important; max-width: none !important; margin: 0 !important; padding: 0 !important; border: 0 !important; float: none !important; }
|
||||
#xwikicontent > .ssos { border: 0 !important; }
|
||||
#xwikimaincontainer { padding: 0 !important; }
|
||||
.main hr:not(.ssos hr), #xwikicontent > :not(.ssos) { display: none !important; }
|
||||
</style>{{/html}}]]#
|
||||
#end
|
||||
{{/velocity}}
|
||||
{{html clean="false"}}
|
||||
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||
<link href="https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500;700&family=Exo+2:wght@600;700&display=swap" rel="stylesheet">
|
||||
|
||||
@@ -1,3 +1,19 @@
|
||||
{{velocity}}
|
||||
#if ($isGuest)
|
||||
#[[{{html clean="false"}}<style>
|
||||
#menuview, #hierarchy_breadcrumb, .document-header, #xdocFooter, #footerglobal, #leftPanels, #rightPanels,
|
||||
#leftPanelsToggle, #rightPanelsToggle, .tour, .tour-backdrop, #bootstrap_tour_restart, .xtour-restart,
|
||||
#xwikimaincontainerinner > a.btn { display: none !important; }
|
||||
html, body, #xwikimaincontainer, #xwikimaincontainerinner, #contentcontainer, #contentcolumn, .main,
|
||||
#mainContentArea, #xwikicontent, #mainContentArea .row { background-color: #0A1222 !important; }
|
||||
#contentcontainer, #contentcolumn, .main, #mainContentArea, #xwikicontent, #mainContentArea .row {
|
||||
width: 100% !important; max-width: none !important; margin: 0 !important; padding: 0 !important; border: 0 !important; float: none !important; }
|
||||
#xwikicontent > .ssos { border: 0 !important; }
|
||||
#xwikimaincontainer { padding: 0 !important; }
|
||||
.main hr:not(.ssos hr), #xwikicontent > :not(.ssos) { display: none !important; }
|
||||
</style>{{/html}}]]#
|
||||
#end
|
||||
{{/velocity}}
|
||||
{{html clean="false"}}
|
||||
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||
<link href="https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500;700&family=Exo+2:wght@600;700&display=swap" rel="stylesheet">
|
||||
|
||||
+1
-1
@@ -99,5 +99,5 @@ if __name__ == "__main__":
|
||||
html = colorlock.lock(html, '<div style="background: #0A1222')
|
||||
assert "{{" not in html.replace(colorlock.STYLE, "") and "[SSRN" not in html and ".dc.html" not in html and "_blob" not in html, p
|
||||
with open("%s.WebHome.xwiki" % p, "w") as f:
|
||||
f.write('{{html clean="false"}}\n%s\n%s\n{{/html}}\n' % (FONTS, html))
|
||||
f.write(colorlock.GUEST_CHROME + '{{html clean="false"}}\n%s\n%s\n{{/html}}\n' % (FONTS, html))
|
||||
print("wrote", ", ".join("%s.WebHome.xwiki" % p for p in PAGES))
|
||||
|
||||
Reference in New Issue
Block a user