Changeset 14395
- Timestamp:
- 02/20/2025 02:11:57 AM (16 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/trac.wordpress.org/templates/ticket_change.html
r14392 r14395 16 16 def wporg_wiki_to_html(context, wikidom, escape_newlines=None): 17 17 18 # Syntax highlight HTML blocks 18 # Syntax highlight HTML blocks. 19 19 wikidom = re.sub( r'{{{\s*#!html', '{{{#!xml \n HTML', wikidom, flags=re.IGNORECASE ) 20 20 21 21 # Unsupported code types get converted to plaintext. 22 22 wikidom = re.sub( r'{{{\s*#!(?!CommitTicketReference|xml|php|js|javascript|sql|sh|table|tr|th|td|diff)(\S+)\s', '{{{#!default \n \\1', wikidom, flags=re.IGNORECASE ) 23 24 # Long code blocks (20k+) should be truncated to 10k characters. 25 wikidom = re.sub( r'{{{(.{10000}?).{10000,}?(}}}|$)', '{{{\\1 \n\nWordPress.org: Please note that this content has been truncated for display.\n }}}', wikidom, flags=re.DOTALL ) 23 26 24 27 # Convert WikiMarkup.
Note: See TracChangeset
for help on using the changeset viewer.