Project

General

Profile

Actions

Defect #38073

closed

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

Added by Go MAEDA over 1 year ago. Updated about 1 year ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Text formatting
Target version:
Start date:
Due date:
% Done:

0%

Estimated time:
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

Files

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

Related issues

Related to Redmine - Defect #37237: Common Markdown Formatter does not render all properties on HTML elementsClosedMarius BÄ‚LTEANU

Actions
Related to Redmine - Feature #26552: Allow "max-height", "max-width", "min-height" and "min-width" CSS properties in TextileClosedGo MAEDA

Actions
Actions #1

Updated by Go MAEDA about 1 year ago

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

Updated by Go MAEDA about 1 year ago

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

Updated by Go MAEDA about 1 year ago

Setting the target version to 5.0.5.

Actions #4

Updated by Go MAEDA about 1 year 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.

Actions #5

Updated by Go MAEDA about 1 year ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF