commit e8189aa62bd516569e5da1cd4e1ef4fd7d016341
parent 7b524abcaaaca79f72f09128611a6a63a18e4497
Author: Eli Barzilay <eli@racket-lang.org>
Date: Mon, 26 May 2008 16:18:33 +0000
move noscript hack to scribble-common.js
svn: r9961
original commit: 11973e16dfcee9bb4aac2620d19f5082bc580e84
Diffstat:
2 files changed, 4 insertions(+), 6 deletions(-)
diff --git a/collects/scribble/html-render.ss b/collects/scribble/html-render.ss
@@ -106,11 +106,6 @@
#reader scribble/reader (begin ; easier to format
-(define mynoscript-setup
- @inlined-script{
- document.write('<style>mynoscript { display:none }</style>');
- })
-
(define search-script
@inlined-script{
var search_nodes = null;
@@ -528,7 +523,6 @@
(meta ([http-equiv "content-type"]
[content "text-html; charset=utf-8"]))
,title
- ,mynoscript-setup
,(scribble-css-contents style-file css-path)
,(scribble-js-contents script-file script-path))
(body () ,@(render-toc-view d ri)
diff --git a/collects/scribble/scribble-common.js b/collects/scribble/scribble-common.js
@@ -39,3 +39,7 @@ function DoSearchKey(event, field) {
location = u + "?q=" + escape(val);
}
}
+
+// `noscript' is problematic in some browsers (always renders as a
+// block), use this hack instead
+document.write("<style>mynoscript { display:none; }</style>");