tag:support.markedapp.com,2011-09-11:/discussions/problems/135571-json-code-block-with-single-property-breaks-layoutMarked: Discussion 2019-02-26T17:37:01Ztag:support.markedapp.com,2011-09-11:Comment/419725332017-02-16T20:17:58Z2017-02-16T20:17:58ZJson code block with single property breaks layout<div><p>// Please enter a detailed description of the issue //
Description of the issue:</p>
<p>Layout gets corrupted when using json block with a single
property</p>
<p>// Please enter a list of steps required to reproduce the issue
// Steps to reproduce:</p>
<ol>
<li>Create the following block</li>
</ol>
<pre>
<code class="json">{
"sourceMap": true
}
<pre><code>
2. All the text below the block is now rendered as json
3.
// If applicable please attach a sample document that causes the issue for you.
// Configuration (do not edit)
Marked 2 930 (Mac App Store)
OS X Version: 10.12.3
---
additionalMathJaxConfig:
allowPageBreakInCode: 1
bookTxtIsLeanpub: 1
summaryMdIsGitBook: 0
codeIsPoetry: 0
collapsibleHeadlines: 0
convertGithubCheckboxes: 1
convertYAMLToMMD: 0
defaultMathJaxConfig: TeX-AMS-MML_HTMLorMML
defaultPreviewStyle: 3
defaultProcessor: Discount (GFM)
enableMiniMap: 0
excludeBlockQuotesFromCounts: 0
excludeFootnotesFromCounts: 0
excludeVerbatimFromCounts: 0
excludeCaptionsFromCounts: 0
folderPreviewExtensionsArray: md, markdown, txt, mdown, html, opml
githubNewlines: 0
h1IsPageBreak: 0
h2IsPageBreak: 0
hrIsPageBreak: 0
includeMathJax: 1
limitTextWidth: 0
minimalJavaScript: 0
outlineModeExtensions:
permissionGranted: 0
printHeaderBottomLeft:
printHeaderBottomRight:
printHeaderFooterFirstPage: 0
printHeaderTopLeft:
printHeaderTopRight:
processHTMLFiles: 1
removeMetadataForPreview: 0
removeYAMLHeaders: 0
scrollToEdit: 1
shouldDetectCritic: 1
shouldHighlightMarkupErrors: 1
shouldLoadCritic: 0
syntaxHighlight: 1</code>
</pre></code>
</pre></div>Denys Vuikatag:support.markedapp.com,2011-09-11:Comment/419725332017-02-16T20:27:43Z2017-02-16T20:27:43ZJson code block with single property breaks layout<div><p>That's a strange one, but I am able to replicate. Noting that
adding one<br>
newline before the closing curly bracket fixes it, and escaping
the<br>
first one ({) renders properly (though the slash is visible).
Even<br>
putting a single space before either one works… so I'm going
to have<br>
to look into the regular expressions that handle the code blocks
and see<br>
what I can figure out. Thanks for the report.</p>
<p>-Brett</p></div>Bretttag:support.markedapp.com,2011-09-11:Comment/419725332019-02-26T17:36:59Z2019-02-26T17:36:59ZJson code block with single property breaks layout<div><p>I believe this is fixed (cleaning up old tickets here). Let me know if you're still seeing it at all.</p></div>Brett