Defect #38073

CommonMark Markdown formatter does not support min-width, max-width, min-height, and max-height CSS properties

Added by Go MAEDA about 1 month ago. Updated 18 days ago.

Status:ClosedStart date:
Priority:NormalDue date:
Assignee:Go MAEDA% Done:

0%

Category:Text formatting
Target version:5.0.5
Resolution:Fixed Affected version:

Description

The new CommonMark Markdown formatter should also support min-width, max-width, min-height, and max-height. These properties are already supported by Textile formatter (#26552).

diff --git a/lib/redmine/wiki_formatting/common_mark/sanitization_filter.rb b/lib/redmine/wiki_formatting/common_mark/sanitization_filter.rb
index b1f1cfe01..eca4859be 100644
--- a/lib/redmine/wiki_formatting/common_mark/sanitization_filter.rb
+++ b/lib/redmine/wiki_formatting/common_mark/sanitization_filter.rb
@@ -29,8 +29,8 @@ module Redmine

         ALLOWED_CSS_PROPERTIES = %w[
           color background-color
-          width
-          height
+          width min-width max-width
+          height min-height max-height
           padding padding-left padding-right padding-top padding-bottom
           margin margin-left margin-right margin-top margin-bottom
           border border-left border-right border-top border-bottom border-radius border-style border-collapse border-spacing

38073.patch Magnifier (2.01 KB) Go MAEDA, 2023-01-09 09:21


Related issues

Related to Redmine - Defect #37237: Common Markdown Formatter does not render all properties ... Closed
Related to Redmine - Feature #26552: Allow "max-height", "max-width", "min-height" and "min-wi... Closed

Associated revisions

Revision 22025
Added by Go MAEDA 23 days ago

CommonMark Markdown formatter does not support min-width, max-width, min-height, and max-height CSS properties (#38073).

Patch by Go MAEDA.

Revision 22048
Added by Go MAEDA 18 days ago

Merged r22025 from trunk to 5.0-stable (#38073).

History

#1 Updated by Go MAEDA 25 days ago

  • Related to Defect #37237: Common Markdown Formatter does not render all properties on HTML elements added

#2 Updated by Go MAEDA 25 days ago

  • Related to Feature #26552: Allow "max-height", "max-width", "min-height" and "min-width" CSS properties in Textile added

#3 Updated by Go MAEDA 25 days ago

Setting the target version to 5.0.5.

#4 Updated by Go MAEDA 23 days ago

  • Subject changed from CommonMark markdown formatter does not support min-width, max-width, min-height, and max-height CSS properties to CommonMark Markdown formatter does not support min-width, max-width, min-height, and max-height CSS properties
  • Status changed from New to Resolved
  • Assignee set to Go MAEDA
  • Resolution set to Fixed

Committed the patch.

#5 Updated by Go MAEDA 18 days ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF