Replace deprecated iFrame frameborder with border: 0

pull/33331/head
Nick Schonning 2 months ago
parent 6b519cfefa
commit f68ffc7179
No known key found for this signature in database
GPG Key ID: 5DDAAD9C9AAFFD9F

@ -101,9 +101,9 @@ const EmbedModal: React.FC<{
/> />
<iframe <iframe
frameBorder='0'
ref={iframeRef} ref={iframeRef}
sandbox='allow-scripts allow-same-origin' sandbox='allow-scripts allow-same-origin'
style={{ border: 0 }}
title='Preview' title='Preview'
/> />
</div> </div>

@ -145,7 +145,7 @@ class LinkDetailsExtractor
end end
def html def html
player_url.present? ? content_tag(:iframe, nil, src: player_url, width: width, height: height, allowfullscreen: 'true', allowtransparency: 'true', scrolling: 'no', frameborder: '0') : nil player_url.present? ? content_tag(:iframe, nil, src: player_url, width: width, height: height, allowfullscreen: 'true', allowtransparency: 'true', scrolling: 'no', style: 'border: 0') : nil
end end
def width def width

@ -135,7 +135,7 @@ class Sanitize
attributes: { attributes: {
'audio' => %w(controls), 'audio' => %w(controls),
'iframe' => %w(allowfullscreen frameborder height scrolling src width), 'iframe' => %w(allowfullscreen frameborder height scrolling src style width),
'source' => %w(src type), 'source' => %w(src type),
'video' => %w(controls height loop width), 'video' => %w(controls height loop width),
}, },

Loading…
Cancel
Save