Skip to content

Commit

Permalink
fix(css): Added new styles to fix issues in IE11 and display captions…
Browse files Browse the repository at this point in the history
… on iOS properly when not using `playsinline` attribute
  • Loading branch information
rafa8626 committed Jan 3, 2019
1 parent b0d5a17 commit b48baba
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 9 deletions.
19 changes: 15 additions & 4 deletions dist/openplayer.css
Original file line number Diff line number Diff line change
Expand Up @@ -249,9 +249,6 @@
-ms-touch-action: manipulation;
touch-action: manipulation;
}
.op-controls input[type=range]::-ms-tooltip {
display: none;
}

/* === Time =================== */
.op-controls > time {
Expand Down Expand Up @@ -396,6 +393,7 @@
}
.op-controls input[type='range'] {
background: transparent;
padding: 0;
-webkit-tap-highlight-color: transparent;
z-index: 3;
}
Expand Down Expand Up @@ -430,7 +428,6 @@
-ms-user-select: none;
user-select: none;
}

.op-controls input[type='range']::-webkit-slider-thumb {
-webkit-appearance: none;
appearance: none;
Expand Down Expand Up @@ -467,6 +464,13 @@
position: relative;
width: 12px;
}
.op-controls input[type='range']::-ms-tooltip {
display: none;
}
.op-controls input[type='range']::-ms-ticks-before,
.op-controls input[type='range']::-ms-ticks-after {
background: transparent;
}
.op-controls--hidden .op-controls .op-controls__progress--seek::-webkit-slider-thumb {
background: transparent;
}
Expand All @@ -491,6 +495,10 @@
-ms-flex-positive: 2;
flex-grow: 2;
}
.op-controls > .op-controls__progress,
.op-controls > .op-controls__progress:hover {
cursor: pointer;
}
.op-controls__progress,
.op-controls__volume {
display: inline-block;
Expand Down Expand Up @@ -668,6 +676,9 @@
.op-player video::-webkit-media-text-track-container {
display: none !important;
}
.op-player.op-player__ios--iphone video::-webkit-media-text-track-container {
display: block !important;
}

/* == Captions =============== */
.op-captions {
Expand Down
2 changes: 1 addition & 1 deletion dist/openplayer.min.css

Large diffs are not rendered by default.

19 changes: 15 additions & 4 deletions src/css/player.css
Original file line number Diff line number Diff line change
Expand Up @@ -213,9 +213,6 @@
.op-controls > button {
touch-action: manipulation;
}
.op-controls input[type=range]::-ms-tooltip {
display: none;
}

/* === Time =================== */
.op-controls > time {
Expand Down Expand Up @@ -350,6 +347,7 @@
}
.op-controls input[type='range'] {
background: transparent;
padding: 0;
-webkit-tap-highlight-color: transparent;
z-index: 3;
}
Expand Down Expand Up @@ -381,7 +379,6 @@
height: 8px;
user-select: none;
}

.op-controls input[type='range']::-webkit-slider-thumb {
appearance: none;
background: #fff;
Expand Down Expand Up @@ -415,6 +412,13 @@
position: relative;
width: 12px;
}
.op-controls input[type='range']::-ms-tooltip {
display: none;
}
.op-controls input[type='range']::-ms-ticks-before,
.op-controls input[type='range']::-ms-ticks-after {
background: transparent;
}
.op-controls--hidden .op-controls .op-controls__progress--seek::-webkit-slider-thumb {
background: transparent;
}
Expand All @@ -437,6 +441,10 @@
.op-controls > .op-controls__progress {
flex-grow: 2;
}
.op-controls > .op-controls__progress,
.op-controls > .op-controls__progress:hover {
cursor: pointer;
}
.op-controls__progress,
.op-controls__volume {
display: inline-block;
Expand Down Expand Up @@ -598,6 +606,9 @@
.op-player video::-webkit-media-text-track-container {
display: none !important;
}
.op-player.op-player__ios--iphone video::-webkit-media-text-track-container {
display: block !important;
}

/* == Captions =============== */
.op-captions {
Expand Down

0 comments on commit b48baba

Please sign in to comment.