Skip to content
Snippets Groups Projects
Commit 7c2ad90b authored by Ivica Puljic's avatar Ivica Puljic Committed by Ivica Puljic
Browse files

Issue #3320887 by pivica: Drop support for IE11

parent 460438a6
No related branches found
No related tags found
No related merge requests found
# Browsers that we support
# > 0.5%, last 2 versions, Firefox ESR, not dead
defaults
ie >= 11
......@@ -10,23 +10,6 @@
Drupal.behaviors.floatingLabels = {
attach: function attach(context) {
// For IE11 and old Edge we will fallback to placeholders - labels are
// hidden in CSS and here we will apply labels values to placeholders.
if (/Trident/.test(navigator.userAgent) || /Edge/.test(navigator.userAgent)) {
var controls = once('floating-label', '.form-group--floating-label:not(.form-no-label) .form-control', context);
controls.forEach(function (el, i) {
var label = el.parentNode.querySelector('label').innerText;
if (el.required) {
label += ' *';
}
el.setAttribute('placeholder', label);
});
// There is no point executing the rest of behavior for IE/Edge
// browsers.
return;
}
// Fixes the width of the form controls if the label is wider than the
// form control.
var elements = once('floating-label', '.form-group--floating-label:not(.form-no-label)', context);
......
......@@ -157,15 +157,6 @@
@if $floating-label-transition {
transition: top, $floating-label-transition, font-size $floating-label-transition, line-height $floating-label-transition;
}
// Fallback for IE11 and old Edge - we hide label and in JS we will put
// label value as a placeholder.
@media all and (-ms-high-contrast: none), (-ms-high-contrast: active) {
display: none;
}
@supports (-ms-ime-align: auto) {
display: none;
}
}
}
// Top we do not apply to form-select because it is in active state label
......
......@@ -164,81 +164,17 @@ label {
// Various details HTML5 element tweaks because IE/Edge does not support it.
details {
// Block display will stop summary wrapping in a new line in IE/Edge.
display: block;
margin-bottom: $form-group-margin-bottom;
border: $border-width solid $border-color;
summary {
// Override display `list-item` which will show list item bullets on
// IE/Edge.
display: block;
padding: $spacer/2 $spacer;
cursor: pointer;
}
// For IE/Edge JS will inject a.details-title element and we need to style
// it then as a regular text and not a link so look is consistent with other
// browsers.
.details-title {
color: $body-color;
@include hover() {
color: $body-color;
text-decoration: none;
}
}
> .details-wrapper {
padding: $spacer;
}
// Because IE/Edge does not support summary/details HTML element we are
// missing details marker image. Because of this we will manually create
// new details marker image.
// @todo RTL support is not tested.
& > summary {
&::-webkit-details-marker {
// Remove default browser details marker.
display: none;
}
&::before {
content: "";
float: left; // LTR
height: 0;
width: 0;
border-top: 6px solid transparent;
border-bottom: 6px solid transparent;
border-left: 10px solid $body-color;
margin-top: $font-size-base/2;
margin-right: $spacer/2;
@if $enable-transitions {
transition: $transition-base;
}
[dir="rtl"] & {
float: right;
transform: rotate(180deg);
}
}
}
&[open] {
& > summary {
&::before {
transform: rotate(90deg);
}
}
[dir="rtl"] & {
& > summary {
&::before {
transform: rotate(-90deg);
}
}
}
}
}
.dropbutton {
......
......@@ -260,8 +260,6 @@ body.toolbar-fixed .toolbar-oriented .toolbar-bar {
svg {
// SVG logo should respect parent width and not overflow it.
// We do not apply height: auto here because it is causing problems in IE11
// and also it seems that this rule is not needed for other browsers.
max-width: 100%;
}
......
......@@ -129,7 +129,7 @@
display: block;
// Control logo dimensions, prevent taking full width (so we have
// site-name on the same line), prevent overflow and set well defined
// basic dimensions because of IE11 problems.
// basic dimensions.
flex: 0 0 auto;
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment