max-width-patch.diff

Michael Gerz, 2017-07-27 17:41

Download (567 Bytes)

View differences:

redcloth3.rb 2017-07-26 14:39:39.975434819 +0200
514 514
        atts
515 515
    end
516 516

  
517
    STYLES_RE = /^(color|width|height|border|background|padding|margin|font|text|float)(-[a-z]+)*:\s*((\d+%?|\d+px|\d+(\.\d+)?em|#[0-9a-f]+|[a-z]+)\s*)+$/i
517
    STYLES_RE = /^(color|width|max-width|height|border|background|padding|margin|font|text|float)(-[a-z]+)*:\s*((\d+%?|\d+px|\d+(\.\d+)?em|#[0-9a-f]+|[a-z]+)\s*)+$/i
518 518

  
519 519
    def sanitize_styles(str)
520 520
      styles = str.split(";").map(&:strip)