Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1271)

Side by Side Diff: bower_components/google-code-prettify/styles/demo.html

Issue 786953007: npm_modules: Fork bower_components into Polymer 0.4.0 and 0.5.0 versions (Closed) Base URL: https://chromium.googlesource.com/infra/third_party/npm_modules.git@master
Patch Set: Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
2 <html><head>
3 <script src="../src/prettify.js"></script>
4 <script src="../src/lang-css.js"></script>
5 <style>
6 body { margin: 0; padding: 0 }
7 pre { margin: 0 }
8 </style>
9 </head>
10 <script>
11 // This page displays some code styled using a theme named in the
12 // query part of the URL.
13 var themeName = decodeURIComponent(document.location.search.replace(/^\?/, ''));
14
15 // Call out to the parent so that it can resize the iframe once this
16 // document's body is loaded.
17 function adjustHeightInParent() {
18 if (parent !== window) {
19 try {
20 var div = document.body.getElementsByTagName('div')[0];
21 parent.adjustChildIframeSize(
22 themeName, div.offsetWidth, div.offsetHeight);
23 } catch (ex) {
24 // Can happen when this page is opened in its own tab.
25 }
26 }
27 }
28
29 // Load the necessary CSS
30 (function () {
31 document.title = 'Theme ' + themeName;
32 // Load the stylesheet that we're demoing.
33 var link = document.createElement('link');
34 link.rel = 'stylesheet';
35 link.type = 'text/css';
36 link.href = themeName === 'default'
37 ? '../src/prettify.css' : themeName + '.css';
38 document.getElementsByTagName('head')[0].appendChild(link);
39 })();
40 </script>
41
42 <body onload="prettyPrint(); adjustHeightInParent()">
43 <div style="width: 40em; display: inline-block">
44 <pre class="prettyprint lang-html linenums">
45 &lt;script type="text/javascript"&gt;
46 // Say hello world until the user starts questioning
47 // the meaningfulness of their existence.
48 function helloWorld(world) {
49 for (var i = 42; --i &gt;= 0;) {
50 alert('Hello ' + String(world));
51 }
52 }
53 &lt;/script&gt;
54 &lt;style&gt;
55 p { color: pink }
56 b { color: blue }
57 u { color: "umber" }
58 &lt;/style&gt;
59 </pre>
60 </div>
61 </body></html>
OLDNEW
« no previous file with comments | « bower_components/google-code-prettify/src/run_prettify.js ('k') | bower_components/google-code-prettify/styles/desert.css » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698