Skip to content

Commit

Permalink
#14: safari iframe resize bug fix stylus
Browse files Browse the repository at this point in the history
  • Loading branch information
MartijnCuppens committed Jul 16, 2018
1 parent 5a26f52 commit a87301b
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions stylus/rfs.styl
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@ $rfs-classes = false
// 1 rem = $rfs-rem-value px
$rfs-rem-value = 16

// Safari iframe resize bug: https://github.com/project-rfs/rfs/issues/14
$rfs-safari-iframe-resize-bug-fix = false

// Disable RFS by setting $enable-responsive-font-sizes to false
$enable-responsive-font-sizes = true

Expand Down Expand Up @@ -144,6 +147,10 @@ rfs($fs, $important = false)
font-size: $rfs-fluid
else
font-size: $rfs-fluid

if $rfs-safari-iframe-resize-bug-fix
// stylelint-disable-next-line length-zero-no-unit
min-width: 0vw
else
@media (max-width: $mq-value)
if $rfs-classes == "enable"
Expand All @@ -153,6 +160,10 @@ rfs($fs, $important = false)
else
font-size: $rfs-fluid

if $rfs-safari-iframe-resize-bug-fix
// stylelint-disable-next-line length-zero-no-unit
min-width: 0vw

// The responsive-font-size mixin uses RFS to rescale font sizes
responsive-font-size($fs, $important = false)
rfs($fs, $important)

0 comments on commit a87301b

Please sign in to comment.