Skip to content
Permalink
Browse files

Merge pull request #12942 from aeslaughter/MOOSEDocs-listing

Set default for code block heights
  • Loading branch information...
permcody committed Feb 21, 2019
2 parents d34132d + 9ca5855 commit 36bec2bfb1e843c0ea7d8cd99c88d0384b5844b8
Showing with 130 additions and 124 deletions.
  1. +4 −0 framework/doc/content/css/moose.css
  2. +2 −0 python/MooseDocs/extensions/core.py
  3. +1 −1 python/MooseDocs/test/gold/html/extensions/alert.html
  4. +6 −6 python/MooseDocs/test/gold/html/extensions/appsyntax.html
  5. +2 −2 python/MooseDocs/test/gold/html/extensions/autolink.html
  6. +3 −3 python/MooseDocs/test/gold/html/extensions/core.html
  7. +1 −1 python/MooseDocs/test/gold/html/extensions/devel.html
  8. +8 −8 python/MooseDocs/test/gold/html/extensions/listing.html
  9. +1 −1 python/MooseDocs/test/gold/html/extensions/listing_include.html
  10. +1 −1 python/MooseDocs/test/gold/html/extensions/package.html
  11. +37 −37 python/MooseDocs/test/gold/html/extensions/sqa.html
  12. +1 −1 python/MooseDocs/test/gold/materialize/extensions/alert.html
  13. +6 −6 python/MooseDocs/test/gold/materialize/extensions/appsyntax.html
  14. +2 −2 python/MooseDocs/test/gold/materialize/extensions/autolink.html
  15. +3 −3 python/MooseDocs/test/gold/materialize/extensions/core.html
  16. +1 −1 python/MooseDocs/test/gold/materialize/extensions/devel.html
  17. +3 −3 python/MooseDocs/test/gold/materialize/extensions/example.template.html
  18. +8 −8 python/MooseDocs/test/gold/materialize/extensions/listing.html
  19. +1 −1 python/MooseDocs/test/gold/materialize/extensions/listing_include.html
  20. +1 −1 python/MooseDocs/test/gold/materialize/extensions/package.html
  21. +37 −37 python/MooseDocs/test/gold/materialize/extensions/sqa.html
  22. +1 −1 python/MooseDocs/test/gold/materialize/extensions/template.html
@@ -168,6 +168,10 @@ pre[class*="language-"]
line-height: 1.15;
}

pre.moose-pre{
max-height:350px;
}

code, kbd, pre, samp {
font-family: monospace, monospace;
font-size: 1em;
@@ -389,7 +389,9 @@ def createLatex(self, parent, token, page): #pylint: disable=no-self-use,unused-
class RenderCode(components.RenderComponent):
def createHTML(self, parent, token, page): #pylint: disable=no-self-use
language = 'language-{}'.format(token['language'])

pre = html.Tag(parent, 'pre', token)
pre.addClass('moose-pre')
code = html.Tag(pre, 'code', class_=language)
html.String(code, content=token['content'], escape=token['escape'])
return pre
@@ -1,3 +1,3 @@
<!DOCTYPE html><head><link href="../contrib/katex/katex.min.css" rel="stylesheet" type="text/css"></link><script src="../contrib/katex/katex.min.js" type="text/javascript"></script><script src="../contrib/plotly/plotly.min.js" type="text/javascript"></script></head><body><h1 id="alert-extension">Alert Extension</h1><div class="moose-alert moose-alert-note"><div class="moose-alert-content"><p></p><p><p>Note only.</p></p></div></div><div class="moose-alert moose-alert-note"><div class="moose-alert-content"><p>Title</p><p><p>Note with a title.</p></p></div></div><div class="moose-alert moose-alert-note"><div class="moose-alert-content"><p>Title</p><p><p>Note with a title but without prefix.</p></p></div></div><div class="moose-alert moose-alert-error"><div class="moose-alert-content"><p></p><p><p>An error.</p></p></div></div><div class="moose-alert moose-alert-warning"><div class="moose-alert-content"><p></p><p><p>A warning.</p></p></div></div><div class="moose-alert moose-alert-construction"><div class="moose-alert-content"><p></p><p><p>Under construction.</p></p></div></div><div class="moose-alert moose-alert-construction"><div class="moose-alert-content"><p></p><p><p>Under construction.</p></p></div></div><div class="moose-alert moose-alert-error"><div class="moose-alert-content"><p></p><p><p>An alert with some code.</p><pre><code class="language-c++">
<!DOCTYPE html><head><link href="../contrib/katex/katex.min.css" rel="stylesheet" type="text/css"></link><script src="../contrib/katex/katex.min.js" type="text/javascript"></script><script src="../contrib/plotly/plotly.min.js" type="text/javascript"></script></head><body><h1 id="alert-extension">Alert Extension</h1><div class="moose-alert moose-alert-note"><div class="moose-alert-content"><p></p><p><p>Note only.</p></p></div></div><div class="moose-alert moose-alert-note"><div class="moose-alert-content"><p>Title</p><p><p>Note with a title.</p></p></div></div><div class="moose-alert moose-alert-note"><div class="moose-alert-content"><p>Title</p><p><p>Note with a title but without prefix.</p></p></div></div><div class="moose-alert moose-alert-error"><div class="moose-alert-content"><p></p><p><p>An error.</p></p></div></div><div class="moose-alert moose-alert-warning"><div class="moose-alert-content"><p></p><p><p>A warning.</p></p></div></div><div class="moose-alert moose-alert-construction"><div class="moose-alert-content"><p></p><p><p>Under construction.</p></p></div></div><div class="moose-alert moose-alert-construction"><div class="moose-alert-content"><p></p><p><p>Under construction.</p></p></div></div><div class="moose-alert moose-alert-error"><div class="moose-alert-content"><p></p><p><p>An alert with some code.</p><pre class="moose-pre"><code class="language-c++">
int x;
</code></pre></p></div></div></body>
@@ -1,4 +1,4 @@
<!DOCTYPE html><head><link href="../contrib/katex/katex.min.css" rel="stylesheet" type="text/css"></link><script src="../contrib/katex/katex.min.js" type="text/javascript"></script><script src="../contrib/plotly/plotly.min.js" type="text/javascript"></script></head><body><h1 id="application-syntax-extension">Application Syntax Extension</h1><p>Sets the value of a 'Real' input parameters to the value of a provided function.</p><h2 id="input-parameters">Input Parameters</h2><h2 id="input-parameters">Input Parameters</h2><h2 id="available-objects-actions-and-subsystems">Available Objects, Actions, and Subsystems</h2><h2 id="input-files">Input Files</h2><ul class="moose-list-inputs"><li><a class="modal-trigger" href="#XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX">test/tests/controls/real_function_control/real_function_control.i</a></li><li><a class="modal-trigger" href="#XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX">modules/stochastic_tools/test/tests/transfers/sampler_transfer/errors/sub_wrong_control.i</a></li><li><a class="modal-trigger" href="#XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX">test/tests/controls/real_function_control/multi_real_function_control.i</a></li><li><a class="modal-trigger" href="#XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX">test/tests/controls/dependency/test.i</a></li><li><a class="modal-trigger" href="#XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX">modules/stochastic_tools/test/tests/transfers/errors/sub_wrong_control.i</a></li></ul>test/tests/controls/real_function_control/real_function_control.i<pre><code class="language-text">[Mesh]
<!DOCTYPE html><head><link href="../contrib/katex/katex.min.css" rel="stylesheet" type="text/css"></link><script src="../contrib/katex/katex.min.js" type="text/javascript"></script><script src="../contrib/plotly/plotly.min.js" type="text/javascript"></script></head><body><h1 id="application-syntax-extension">Application Syntax Extension</h1><p>Sets the value of a 'Real' input parameters to the value of a provided function.</p><h2 id="input-parameters">Input Parameters</h2><h2 id="input-parameters">Input Parameters</h2><h2 id="available-objects-actions-and-subsystems">Available Objects, Actions, and Subsystems</h2><h2 id="input-files">Input Files</h2><ul class="moose-list-inputs"><li><a class="modal-trigger" href="#XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX">test/tests/controls/real_function_control/real_function_control.i</a></li><li><a class="modal-trigger" href="#XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX">modules/stochastic_tools/test/tests/transfers/sampler_transfer/errors/sub_wrong_control.i</a></li><li><a class="modal-trigger" href="#XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX">test/tests/controls/real_function_control/multi_real_function_control.i</a></li><li><a class="modal-trigger" href="#XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX">test/tests/controls/dependency/test.i</a></li><li><a class="modal-trigger" href="#XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX">modules/stochastic_tools/test/tests/transfers/errors/sub_wrong_control.i</a></li></ul>test/tests/controls/real_function_control/real_function_control.i<pre class="moose-pre"><code class="language-text">[Mesh]
type = GeneratedMesh
dim = 2
nx = 10
@@ -73,7 +73,7 @@
execute_on = 'initial timestep_begin'
[../]
[]
</code></pre>modules/stochastic_tools/test/tests/transfers/sampler_transfer/errors/sub_wrong_control.i<pre><code class="language-text">[Mesh]
</code></pre>modules/stochastic_tools/test/tests/transfers/sampler_transfer/errors/sub_wrong_control.i<pre class="moose-pre"><code class="language-text">[Mesh]
type = GeneratedMesh
dim = 2
nx = 10
@@ -131,7 +131,7 @@
[Outputs]
exodus = true
[]
</code></pre>test/tests/controls/real_function_control/multi_real_function_control.i<pre><code class="language-text">###########################################################
</code></pre>test/tests/controls/real_function_control/multi_real_function_control.i<pre class="moose-pre"><code class="language-text">###########################################################
# This is a test of the Control Logic System. This test
# uses the RealFunctionControl to change a multiple Kernel
# coefficients based on an analytical function at the end
@@ -230,7 +230,7 @@
execute_on = 'timestep_begin'
[../]
[]
</code></pre>test/tests/controls/dependency/test.i<pre><code class="language-text">[Mesh]
</code></pre>test/tests/controls/dependency/test.i<pre class="moose-pre"><code class="language-text">[Mesh]
type = GeneratedMesh
dim = 2
nx = 10
@@ -316,7 +316,7 @@
execute_on = 'initial timestep_begin'
[../]
[]
</code></pre>modules/stochastic_tools/test/tests/transfers/errors/sub_wrong_control.i<pre><code class="language-text">[Mesh]
</code></pre>modules/stochastic_tools/test/tests/transfers/errors/sub_wrong_control.i<pre class="moose-pre"><code class="language-text">[Mesh]
type = GeneratedMesh
dim = 2
nx = 10
@@ -374,7 +374,7 @@
[Outputs]
exodus = true
[]
</code></pre><h2 id="child-objects">Child Objects</h2><ul class="moose-list-children"><li><a class="modal-trigger" href="#XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX">framework/include/kernels/UserForcingFunction.h</a></li></ul>framework/include/kernels/UserForcingFunction.h<pre><code class="language-cpp">// This file is part of the MOOSE framework
</code></pre><h2 id="child-objects">Child Objects</h2><ul class="moose-list-children"><li><a class="modal-trigger" href="#XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX">framework/include/kernels/UserForcingFunction.h</a></li></ul>framework/include/kernels/UserForcingFunction.h<pre class="moose-pre"><code class="language-cpp">// This file is part of the MOOSE framework
// https://www.mooseframework.org
//
// All rights reserved, see COPYRIGHT for full restrictions
@@ -1,4 +1,4 @@
<!DOCTYPE html><head><link href="../contrib/katex/katex.min.css" rel="stylesheet" type="text/css"></link><script src="../contrib/katex/katex.min.js" type="text/javascript"></script><script src="../contrib/plotly/plotly.min.js" type="text/javascript"></script></head><body><h1 id="autolink-extension">Autolink Extension</h1><p><a href="core.html">Core Extension</a></p><p><a href="core.html">this is local</a></p><h2 id="local-headings">Local Headings</h2><p><a href="autolink.html#local-headings">Local Headings</a></p><p><a href="autolink.html#local-headings">this is local</a></p><h2 id="non-local-headings-with-id">Non-local headings with ID</h2><p><a href="core.html#ordered-single-level-lists">Single level lists</a></p><p><a href="core.html#unordered-single-level-lists">this is local</a></p><h2 id="source-filename">Source Filename</h2><p><a class="modal-trigger" href="#XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX">RealFunctionControl.C</a></p>/framework/src/controls/RealFunctionControl.C<pre><code class="language-cpp">// This file is part of the MOOSE framework
<!DOCTYPE html><head><link href="../contrib/katex/katex.min.css" rel="stylesheet" type="text/css"></link><script src="../contrib/katex/katex.min.js" type="text/javascript"></script><script src="../contrib/plotly/plotly.min.js" type="text/javascript"></script></head><body><h1 id="autolink-extension">Autolink Extension</h1><p><a href="core.html">Core Extension</a></p><p><a href="core.html">this is local</a></p><h2 id="local-headings">Local Headings</h2><p><a href="autolink.html#local-headings">Local Headings</a></p><p><a href="autolink.html#local-headings">this is local</a></p><h2 id="non-local-headings-with-id">Non-local headings with ID</h2><p><a href="core.html#ordered-single-level-lists">Single level lists</a></p><p><a href="core.html#unordered-single-level-lists">this is local</a></p><h2 id="source-filename">Source Filename</h2><p><a class="modal-trigger" href="#XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX">RealFunctionControl.C</a></p>/framework/src/controls/RealFunctionControl.C<pre class="moose-pre"><code class="language-cpp">// This file is part of the MOOSE framework
// https://www.mooseframework.org
//
// All rights reserved, see COPYRIGHT for full restrictions
@@ -40,7 +40,7 @@
Real value = _function.value(_t, Point());
setControllableValue&lt;Real&gt;(&quot;parameter&quot;, value);
}
</code></pre><p><a class="modal-trigger" href="#XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX">Some Code</a></p>/framework/src/controls/RealFunctionControl.C<pre><code class="language-cpp">// This file is part of the MOOSE framework
</code></pre><p><a class="modal-trigger" href="#XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX">Some Code</a></p>/framework/src/controls/RealFunctionControl.C<pre class="moose-pre"><code class="language-cpp">// This file is part of the MOOSE framework
// https://www.mooseframework.org
//
// All rights reserved, see COPYRIGHT for full restrictions
@@ -1,8 +1,8 @@
<!DOCTYPE html><head><link href="../contrib/katex/katex.min.css" rel="stylesheet" type="text/css"></link><script src="../contrib/katex/katex.min.js" type="text/javascript"></script><script src="../contrib/plotly/plotly.min.js" type="text/javascript"></script></head><body><h1 id="core-extension">Core Extension</h1><h2 id="code-blocks">Code Blocks</h2><pre><code class="language-text">
<!DOCTYPE html><head><link href="../contrib/katex/katex.min.css" rel="stylesheet" type="text/css"></link><script src="../contrib/katex/katex.min.js" type="text/javascript"></script><script src="../contrib/plotly/plotly.min.js" type="text/javascript"></script></head><body><h1 id="core-extension">Core Extension</h1><h2 id="code-blocks">Code Blocks</h2><pre class="moose-pre"><code class="language-text">
text
</code></pre><pre><code class="language-cpp">
</code></pre><pre class="moose-pre"><code class="language-cpp">
int y;
</code></pre><pre><code class="language-python">
</code></pre><pre class="moose-pre"><code class="language-python">
for i in range(10):
print i
</code></pre><h2 id="quotations">Quotations</h2><h3 id="multiline-quotation">Multiline Quotation</h3><blockquote><p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. <strong>Duis</strong> aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p></blockquote><h3 id="nested-quotations-and-lists">Nested Quotations and Lists</h3><blockquote><p>This is a quotation that contains a quotation.</p><blockquote><p>This should be a nested quotation.</p></blockquote><ul><li><p>A list. </p></li><li><p>With two items</p><blockquote><p>The second contains a quote as well, which has a numbered list.</p><ol><li><p>one </p></li><li><p>two</p></li></ol></blockquote></li></ul></blockquote><h2 id="headings">Headings</h2><h1 id="one">One</h1><h2 id="two">Two</h2><h3 id="three">Three</h3><h4 id="four">Four</h4><h5 id="five">Five</h5><h6 id="six">Six</h6><h2 style="color:red;" id="heading-with-style">Heading with Style</h2><h2 id="unordered-lists">Unordered Lists</h2><h3 id="unordered-single-level-lists">Single level lists</h3><ul><li><p>Item 1 </p></li><li><p>Item 2 </p></li><li><p>Item 3 The third items has some content, this content contains paragraphs.</p><p>This is a second paragraph in the list.</p><p></p></li><li><p>Item 4 should be apart of the same list.</p></li></ul><ul><li><p>Item 1b: This should start a new list, because of the two blank lines. </p></li><li><p>Item 2b</p></li></ul><h3 id="unordered-nested-lists">Nested lists</h3><ul><li><p>Item 1</p><ul><li><p>Item 1.1 </p></li><li><p>Item 1.2</p></li></ul><p></p></li><li><p>Item 2</p><ul><li><p>Item 2.1</p><ul><li><p>Item 2.1.1 </p></li><li><p>Item 2.1.2</p><blockquote><p>A quotation.</p></blockquote></li></ul><p></p></li><li><p>Item 2.2</p></li></ul><p></p></li><li><p>Item 3</p></li></ul><h2 id="ordered-list">Ordered List</h2><h3 id="ordered-single-level-lists">Single level lists</h3><ol><li><p>One </p></li><li><p>Two </p></li><li><p>Three Just like above, this should contain two paragraphs.</p><p>This is a new paragraph.</p><p></p></li><li><p>Four</p></li></ol><h3 id="starting-number">Starting number</h3><ol><li><p>Two </p></li><li><p>Three</p></li></ol><ol><li><p>Forty-two </p></li><li><p>Forty-three</p></li></ol><ol><li><p>Twelve thousand <em>three</em> hundred and forty-five </p></li><li><p>Twelve thousand three hundred and forty-six</p><ol><li><p>A nested item within a <strong>huge</strong> number.</p></li></ol></li></ol><h3 id="ordered-nested-lists">Nested lists</h3><ol><li><p>One</p><ol><li><p>1.1 </p></li><li><p>1.2 </p></li><li><p>1.3</p></li></ol><p></p></li><li><p>Two</p><ol><li><p>2.1 </p></li><li><p>2.2</p><ol><li><p><strike>2.2.1</strike> </p></li><li><p>2.2.2 </p></li><li><p>2.2.3</p><blockquote><p>A quote.</p><blockquote><p>Go deeper.</p><ol><li><p>Fifty-four</p></li></ol></blockquote></blockquote></li></ol></li></ol></li></ol><h2 id="shortcuts-and-shortcut-links">Shortcuts and Shortcut links.</h2><p>A popular search engine is <a href="https://www.google.com">google</a>.</p><h2 id="inline-formatting">Inline formatting</h2><p>super<sup>script</sup> not super ^script^</p><p>sub<sub>script</sub> not sub @script@</p><p><u>underline</u> = not underlined=</p><p><em>emphasis</em> * not emphasized*</p><p><strong>bold</strong> + not bold+</p><p><strike>strike</strike> ~ not strike~</p><p><code>mono</code> ` not mono`</p><p>Yo, dawg I heard you like formatting, so I created <u>underline formatted text that contains text with <strike>stikethrough that contains <strong>bold formatting with <em>emphasis that has some<sup>superscript text with a<sub>subscript</sub></sup></em></strong></strike></u>, I hope you like it.</p><h2 id="links">Links</h2><p>This is a link to <a href="https://www.google.com">google</a>. </p></body>
Oops, something went wrong.

0 comments on commit 36bec2b

Please sign in to comment.
You can’t perform that action at this time.