uikit 3.11.2-dev.4c11be04b → 3.11.2-dev.72dbb9a19

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (171) hide show
  1. package/.eslintrc.json +4 -49
  2. package/.prettierignore +14 -0
  3. package/.prettierrc.json +13 -0
  4. package/.webstorm.js +3 -3
  5. package/CHANGELOG.md +21 -0
  6. package/build/.eslintrc.json +1 -3
  7. package/build/build.js +26 -28
  8. package/build/icons.js +7 -11
  9. package/build/less.js +48 -36
  10. package/build/package.json +2 -2
  11. package/build/prefix.js +21 -18
  12. package/build/publishDev.js +6 -8
  13. package/build/release.js +20 -17
  14. package/build/scope.js +21 -11
  15. package/build/scss.js +72 -39
  16. package/build/util.js +71 -62
  17. package/build/wrapper/icons.js +0 -2
  18. package/dist/css/uikit-core-rtl.css +42 -32
  19. package/dist/css/uikit-core-rtl.min.css +1 -1
  20. package/dist/css/uikit-core.css +42 -32
  21. package/dist/css/uikit-core.min.css +1 -1
  22. package/dist/css/uikit-rtl.css +42 -32
  23. package/dist/css/uikit-rtl.min.css +1 -1
  24. package/dist/css/uikit.css +42 -32
  25. package/dist/css/uikit.min.css +1 -1
  26. package/dist/js/components/countdown.js +88 -133
  27. package/dist/js/components/countdown.min.js +1 -1
  28. package/dist/js/components/filter.js +408 -439
  29. package/dist/js/components/filter.min.js +1 -1
  30. package/dist/js/components/lightbox-panel.js +1098 -1316
  31. package/dist/js/components/lightbox-panel.min.js +1 -1
  32. package/dist/js/components/lightbox.js +1144 -1393
  33. package/dist/js/components/lightbox.min.js +1 -1
  34. package/dist/js/components/notification.js +94 -114
  35. package/dist/js/components/notification.min.js +1 -1
  36. package/dist/js/components/parallax.js +294 -356
  37. package/dist/js/components/parallax.min.js +1 -1
  38. package/dist/js/components/slider-parallax.js +292 -344
  39. package/dist/js/components/slider-parallax.min.js +1 -1
  40. package/dist/js/components/slider.js +722 -852
  41. package/dist/js/components/slider.min.js +1 -1
  42. package/dist/js/components/slideshow-parallax.js +292 -344
  43. package/dist/js/components/slideshow-parallax.min.js +1 -1
  44. package/dist/js/components/slideshow.js +612 -802
  45. package/dist/js/components/slideshow.min.js +1 -1
  46. package/dist/js/components/sortable.js +587 -621
  47. package/dist/js/components/sortable.min.js +1 -1
  48. package/dist/js/components/tooltip.js +324 -356
  49. package/dist/js/components/tooltip.min.js +1 -1
  50. package/dist/js/components/upload.js +155 -167
  51. package/dist/js/components/upload.min.js +1 -1
  52. package/dist/js/uikit-core.js +5370 -6659
  53. package/dist/js/uikit-core.min.js +1 -1
  54. package/dist/js/uikit-icons.js +7 -9
  55. package/dist/js/uikit-icons.min.js +1 -1
  56. package/dist/js/uikit.js +8056 -9832
  57. package/dist/js/uikit.min.js +1 -1
  58. package/jsconfig.json +1 -1
  59. package/package.json +64 -60
  60. package/src/js/api/boot.js +25 -32
  61. package/src/js/api/component.js +15 -28
  62. package/src/js/api/global.js +6 -12
  63. package/src/js/api/hooks.js +14 -33
  64. package/src/js/api/instance.js +7 -15
  65. package/src/js/api/state.js +79 -100
  66. package/src/js/components/countdown.js +24 -50
  67. package/src/js/components/filter.js +70 -66
  68. package/src/js/components/index.js +13 -13
  69. package/src/js/components/internal/lightbox-animations.js +14 -25
  70. package/src/js/components/internal/slider-transitioner.js +66 -45
  71. package/src/js/components/internal/slideshow-animations.js +46 -64
  72. package/src/js/components/lightbox-panel.js +107 -105
  73. package/src/js/components/lightbox.js +17 -39
  74. package/src/js/components/notification.js +49 -43
  75. package/src/js/components/parallax.js +21 -46
  76. package/src/js/components/slider-parallax.js +13 -23
  77. package/src/js/components/slider.js +75 -64
  78. package/src/js/components/slideshow-parallax.js +1 -1
  79. package/src/js/components/slideshow.js +8 -13
  80. package/src/js/components/sortable.js +126 -108
  81. package/src/js/components/tooltip.js +41 -31
  82. package/src/js/components/upload.js +52 -63
  83. package/src/js/core/accordion.js +53 -48
  84. package/src/js/core/alert.js +9 -17
  85. package/src/js/core/core.js +74 -53
  86. package/src/js/core/cover.js +11 -15
  87. package/src/js/core/drop.js +107 -93
  88. package/src/js/core/form-custom.js +20 -25
  89. package/src/js/core/gif.js +3 -7
  90. package/src/js/core/grid.js +57 -58
  91. package/src/js/core/height-match.js +16 -29
  92. package/src/js/core/height-viewport.js +29 -36
  93. package/src/js/core/icon.js +38 -50
  94. package/src/js/core/img.js +59 -58
  95. package/src/js/core/index.js +39 -39
  96. package/src/js/core/leader.js +9 -18
  97. package/src/js/core/margin.js +21 -37
  98. package/src/js/core/modal.js +49 -36
  99. package/src/js/core/nav.js +2 -4
  100. package/src/js/core/navbar.js +113 -85
  101. package/src/js/core/offcanvas.js +49 -53
  102. package/src/js/core/overflow-auto.js +13 -17
  103. package/src/js/core/responsive.js +14 -12
  104. package/src/js/core/scroll.js +10 -20
  105. package/src/js/core/scrollspy-nav.js +34 -31
  106. package/src/js/core/scrollspy.js +37 -54
  107. package/src/js/core/sticky.js +187 -116
  108. package/src/js/core/svg.js +60 -79
  109. package/src/js/core/switcher.js +47 -46
  110. package/src/js/core/tab.js +7 -10
  111. package/src/js/core/toggle.js +64 -66
  112. package/src/js/core/video.js +11 -22
  113. package/src/js/mixin/animate.js +19 -20
  114. package/src/js/mixin/class.js +2 -4
  115. package/src/js/mixin/container.js +7 -11
  116. package/src/js/mixin/internal/animate-fade.js +73 -30
  117. package/src/js/mixin/internal/animate-slide.js +58 -41
  118. package/src/js/mixin/internal/slideshow-animations.js +7 -14
  119. package/src/js/mixin/internal/slideshow-transitioner.js +10 -17
  120. package/src/js/mixin/media.js +5 -10
  121. package/src/js/mixin/modal.js +89 -66
  122. package/src/js/mixin/parallax.js +53 -48
  123. package/src/js/mixin/position.js +26 -20
  124. package/src/js/mixin/slider-autoplay.js +12 -21
  125. package/src/js/mixin/slider-drag.js +64 -65
  126. package/src/js/mixin/slider-nav.js +26 -35
  127. package/src/js/mixin/slider-reactive.js +2 -8
  128. package/src/js/mixin/slider.js +48 -55
  129. package/src/js/mixin/slideshow.js +13 -19
  130. package/src/js/mixin/togglable.js +89 -63
  131. package/src/js/uikit-core.js +2 -4
  132. package/src/js/uikit.js +2 -4
  133. package/src/js/util/ajax.js +20 -39
  134. package/src/js/util/animation.js +77 -75
  135. package/src/js/util/attr.js +17 -21
  136. package/src/js/util/class.js +14 -52
  137. package/src/js/util/dimensions.js +76 -47
  138. package/src/js/util/dom.js +40 -73
  139. package/src/js/util/env.js +7 -12
  140. package/src/js/util/event.js +60 -59
  141. package/src/js/util/fastdom.js +3 -8
  142. package/src/js/util/filter.js +17 -34
  143. package/src/js/util/index.js +0 -1
  144. package/src/js/util/lang.js +81 -121
  145. package/src/js/util/mouse.js +19 -17
  146. package/src/js/util/options.js +35 -49
  147. package/src/js/util/player.js +40 -36
  148. package/src/js/util/position.js +54 -46
  149. package/src/js/util/selector.js +43 -58
  150. package/src/js/util/style.js +36 -46
  151. package/src/js/util/viewport.js +81 -66
  152. package/src/less/components/base.less +0 -5
  153. package/src/less/components/flex.less +0 -9
  154. package/src/less/components/leader.less +0 -1
  155. package/src/less/components/navbar.less +0 -7
  156. package/src/less/components/utility.less +22 -0
  157. package/src/scss/components/base.scss +0 -5
  158. package/src/scss/components/flex.scss +0 -9
  159. package/src/scss/components/form.scss +3 -3
  160. package/src/scss/components/icon.scss +2 -2
  161. package/src/scss/components/leader.scss +0 -1
  162. package/src/scss/components/navbar.scss +0 -7
  163. package/src/scss/components/search.scss +1 -1
  164. package/src/scss/components/utility.scss +22 -0
  165. package/src/scss/variables-theme.scss +6 -6
  166. package/src/scss/variables.scss +6 -6
  167. package/tests/js/index.js +114 -85
  168. package/tests/sticky-parallax.html +44 -41
  169. package/tests/sticky.html +56 -24
  170. package/src/js/mixin/flex-bug.js +0 -56
  171. package/src/js/util/promise.js +0 -191
package/src/js/uikit.js CHANGED
@@ -1,9 +1,7 @@
1
1
  import UIkit from './uikit-core';
2
2
  import * as components from './components/index';
3
- import {each} from 'uikit-util';
3
+ import { each } from 'uikit-util';
4
4
 
5
- each(components, (component, name) =>
6
- UIkit.component(name, component)
7
- );
5
+ each(components, (component, name) => UIkit.component(name, component));
8
6
 
9
7
  export default UIkit;
@@ -1,18 +1,16 @@
1
- import {on} from './event';
2
- import {Promise} from './promise';
3
- import {assign, isString, noop} from './lang';
1
+ import { on } from './event';
2
+ import { assign, noop } from './lang';
4
3
 
5
4
  export function ajax(url, options) {
6
-
7
- const env = assign({
5
+ const env = {
8
6
  data: null,
9
7
  method: 'GET',
10
8
  headers: {},
11
9
  xhr: new XMLHttpRequest(),
12
10
  beforeSend: noop,
13
- responseType: ''
14
- }, options);
15
-
11
+ responseType: '',
12
+ ...options,
13
+ };
16
14
  return Promise.resolve()
17
15
  .then(() => env.beforeSend(env))
18
16
  .then(() => send(url, env));
@@ -20,15 +18,15 @@ export function ajax(url, options) {
20
18
 
21
19
  function send(url, env) {
22
20
  return new Promise((resolve, reject) => {
23
- let {xhr} = env;
21
+ const { xhr } = env;
24
22
 
25
23
  for (const prop in env) {
26
24
  if (prop in xhr) {
27
25
  try {
28
-
29
26
  xhr[prop] = env[prop];
30
-
31
- } catch (e) {}
27
+ } catch (e) {
28
+ // noop
29
+ }
32
30
  }
33
31
  }
34
32
 
@@ -39,51 +37,34 @@ function send(url, env) {
39
37
  }
40
38
 
41
39
  on(xhr, 'load', () => {
42
-
43
- if (xhr.status === 0 || xhr.status >= 200 && xhr.status < 300 || xhr.status === 304) {
44
-
45
- // IE 11 does not support responseType 'json'
46
- if (env.responseType === 'json' && isString(xhr.response)) {
47
- xhr = assign(copyXhr(xhr), {response: JSON.parse(xhr.response)});
48
- }
49
-
40
+ if (xhr.status === 0 || (xhr.status >= 200 && xhr.status < 300) || xhr.status === 304) {
50
41
  resolve(xhr);
51
-
52
42
  } else {
53
- reject(assign(Error(xhr.statusText), {
54
- xhr,
55
- status: xhr.status
56
- }));
43
+ reject(
44
+ assign(Error(xhr.statusText), {
45
+ xhr,
46
+ status: xhr.status,
47
+ })
48
+ );
57
49
  }
58
-
59
50
  });
60
51
 
61
- on(xhr, 'error', () => reject(assign(Error('Network Error'), {xhr})));
62
- on(xhr, 'timeout', () => reject(assign(Error('Network Timeout'), {xhr})));
52
+ on(xhr, 'error', () => reject(assign(Error('Network Error'), { xhr })));
53
+ on(xhr, 'timeout', () => reject(assign(Error('Network Timeout'), { xhr })));
63
54
 
64
55
  xhr.send(env.data);
65
56
  });
66
57
  }
67
58
 
68
59
  export function getImage(src, srcset, sizes) {
69
-
70
60
  return new Promise((resolve, reject) => {
71
61
  const img = new Image();
72
62
 
73
- img.onerror = e => reject(e);
63
+ img.onerror = (e) => reject(e);
74
64
  img.onload = () => resolve(img);
75
65
 
76
66
  sizes && (img.sizes = sizes);
77
67
  srcset && (img.srcset = srcset);
78
68
  img.src = src;
79
69
  });
80
-
81
- }
82
-
83
- function copyXhr(source) {
84
- const target = {};
85
- for (const key in source) {
86
- target[key] = source[key];
87
- }
88
- return target;
89
70
  }
@@ -1,49 +1,52 @@
1
- import {attr} from './attr';
2
- import {Promise} from './promise';
3
- import {once, trigger} from './event';
4
- import {css, propName} from './style';
5
- import {assign, startsWith, toNodes} from './lang';
6
- import {addClass, hasClass, removeClass, removeClasses} from './class';
1
+ import { attr } from './attr';
2
+ import { once, trigger } from './event';
3
+ import { css, propName } from './style';
4
+ import { startsWith, toNodes } from './lang';
5
+ import { addClass, hasClass, removeClass, removeClasses } from './class';
7
6
 
8
7
  export function transition(element, props, duration = 400, timing = 'linear') {
9
-
10
- return Promise.all(toNodes(element).map(element =>
11
- new Promise((resolve, reject) => {
12
-
13
- for (const name in props) {
14
- const value = css(element, name);
15
- if (value === '') {
16
- css(element, name, value);
17
- }
18
- }
19
-
20
- const timer = setTimeout(() => trigger(element, 'transitionend'), duration);
21
-
22
- once(element, 'transitionend transitioncanceled', ({type}) => {
23
- clearTimeout(timer);
24
- removeClass(element, 'uk-transition');
25
- css(element, {
26
- transitionProperty: '',
27
- transitionDuration: '',
28
- transitionTimingFunction: ''
29
- });
30
- type === 'transitioncanceled' ? reject() : resolve(element);
31
- }, {self: true});
32
-
33
- addClass(element, 'uk-transition');
34
- css(element, assign({
35
- transitionProperty: Object.keys(props).map(propName).join(','),
36
- transitionDuration: `${duration}ms`,
37
- transitionTimingFunction: timing
38
- }, props));
39
-
40
- })
41
- ));
42
-
8
+ return Promise.all(
9
+ toNodes(element).map(
10
+ (element) =>
11
+ new Promise((resolve, reject) => {
12
+ for (const name in props) {
13
+ const value = css(element, name);
14
+ if (value === '') {
15
+ css(element, name, value);
16
+ }
17
+ }
18
+
19
+ const timer = setTimeout(() => trigger(element, 'transitionend'), duration);
20
+
21
+ once(
22
+ element,
23
+ 'transitionend transitioncanceled',
24
+ ({ type }) => {
25
+ clearTimeout(timer);
26
+ removeClass(element, 'uk-transition');
27
+ css(element, {
28
+ transitionProperty: '',
29
+ transitionDuration: '',
30
+ transitionTimingFunction: '',
31
+ });
32
+ type === 'transitioncanceled' ? reject() : resolve(element);
33
+ },
34
+ { self: true }
35
+ );
36
+
37
+ addClass(element, 'uk-transition');
38
+ css(element, {
39
+ transitionProperty: Object.keys(props).map(propName).join(','),
40
+ transitionDuration: `${duration}ms`,
41
+ transitionTimingFunction: timing,
42
+ ...props,
43
+ });
44
+ })
45
+ )
46
+ );
43
47
  }
44
48
 
45
49
  export const Transition = {
46
-
47
50
  start: transition,
48
51
 
49
52
  stop(element) {
@@ -57,47 +60,47 @@ export const Transition = {
57
60
 
58
61
  inProgress(element) {
59
62
  return hasClass(element, 'uk-transition');
60
- }
61
-
63
+ },
62
64
  };
63
65
 
64
66
  const animationPrefix = 'uk-animation-';
65
67
 
66
68
  export function animate(element, animation, duration = 200, origin, out) {
67
-
68
- return Promise.all(toNodes(element).map(element =>
69
- new Promise((resolve, reject) => {
70
-
71
- trigger(element, 'animationcanceled');
72
- const timer = setTimeout(() => trigger(element, 'animationend'), duration);
73
-
74
- once(element, 'animationend animationcanceled', ({type}) => {
75
-
76
- clearTimeout(timer);
77
-
78
- type === 'animationcanceled' ? reject() : resolve(element);
79
-
80
- css(element, 'animationDuration', '');
81
- removeClasses(element, `${animationPrefix}\\S*`);
82
-
83
- }, {self: true});
84
-
85
- css(element, 'animationDuration', `${duration}ms`);
86
- addClass(element, animation, animationPrefix + (out ? 'leave' : 'enter'));
87
-
88
- if (startsWith(animation, animationPrefix)) {
89
- origin && addClass(element, `uk-transform-origin-${origin}`);
90
- out && addClass(element, `${animationPrefix}reverse`);
91
- }
92
-
93
- })
94
- ));
95
-
69
+ return Promise.all(
70
+ toNodes(element).map(
71
+ (element) =>
72
+ new Promise((resolve, reject) => {
73
+ trigger(element, 'animationcanceled');
74
+ const timer = setTimeout(() => trigger(element, 'animationend'), duration);
75
+
76
+ once(
77
+ element,
78
+ 'animationend animationcanceled',
79
+ ({ type }) => {
80
+ clearTimeout(timer);
81
+
82
+ type === 'animationcanceled' ? reject() : resolve(element);
83
+
84
+ css(element, 'animationDuration', '');
85
+ removeClasses(element, `${animationPrefix}\\S*`);
86
+ },
87
+ { self: true }
88
+ );
89
+
90
+ css(element, 'animationDuration', `${duration}ms`);
91
+ addClass(element, animation, animationPrefix + (out ? 'leave' : 'enter'));
92
+
93
+ if (startsWith(animation, animationPrefix)) {
94
+ origin && addClass(element, `uk-transform-origin-${origin}`);
95
+ out && addClass(element, `${animationPrefix}reverse`);
96
+ }
97
+ })
98
+ )
99
+ );
96
100
  }
97
101
 
98
102
  const inProgress = new RegExp(`${animationPrefix}(enter|leave)`);
99
103
  export const Animation = {
100
-
101
104
  in: animate,
102
105
 
103
106
  out(element, animation, duration, origin) {
@@ -110,6 +113,5 @@ export const Animation = {
110
113
 
111
114
  cancel(element) {
112
115
  trigger(element, 'animationcanceled');
113
- }
114
-
116
+ },
115
117
  };
@@ -1,7 +1,6 @@
1
- import {isFunction, isObject, isUndefined, toNode, toNodes} from './lang';
1
+ import { isFunction, isObject, isUndefined, toNode, toNodes } from './lang';
2
2
 
3
3
  export function attr(element, name, value) {
4
-
5
4
  if (isObject(name)) {
6
5
  for (const key in name) {
7
6
  attr(element, key, name[key]);
@@ -10,42 +9,39 @@ export function attr(element, name, value) {
10
9
  }
11
10
 
12
11
  if (isUndefined(value)) {
13
- element = toNode(element);
14
- return element && element.getAttribute(name);
12
+ return toNode(element)?.getAttribute(name);
15
13
  } else {
16
- toNodes(element).forEach(element => {
17
-
14
+ for (const el of toNodes(element)) {
18
15
  if (isFunction(value)) {
19
- value = value.call(element, attr(element, name));
16
+ value = value.call(el, attr(el, name));
20
17
  }
21
18
 
22
19
  if (value === null) {
23
- removeAttr(element, name);
20
+ removeAttr(el, name);
24
21
  } else {
25
- element.setAttribute(name, value);
22
+ el.setAttribute(name, value);
26
23
  }
27
- });
24
+ }
28
25
  }
29
-
30
26
  }
31
27
 
32
28
  export function hasAttr(element, name) {
33
- return toNodes(element).some(element => element.hasAttribute(name));
29
+ return toNodes(element).some((element) => element.hasAttribute(name));
34
30
  }
35
31
 
36
32
  export function removeAttr(element, name) {
37
- element = toNodes(element);
38
- name.split(' ').forEach(name =>
39
- element.forEach(element =>
40
- element.hasAttribute(name) && element.removeAttribute(name)
41
- )
42
- );
33
+ const elements = toNodes(element);
34
+ for (const attribute of name.split(' ')) {
35
+ for (const element of elements) {
36
+ element.removeAttribute(attribute);
37
+ }
38
+ }
43
39
  }
44
40
 
45
41
  export function data(element, attribute) {
46
- for (let i = 0, attrs = [attribute, `data-${attribute}`]; i < attrs.length; i++) {
47
- if (hasAttr(element, attrs[i])) {
48
- return attr(element, attrs[i]);
42
+ for (const name of [attribute, `data-${attribute}`]) {
43
+ if (hasAttr(element, name)) {
44
+ return attr(element, name);
49
45
  }
50
46
  }
51
47
  }
@@ -1,5 +1,5 @@
1
- import {attr} from './attr';
2
- import {isUndefined, toNodes} from './lang';
1
+ import { attr } from './attr';
2
+ import { isUndefined, toNodes } from './lang';
3
3
 
4
4
  export function addClass(element, ...args) {
5
5
  apply(element, args, 'add');
@@ -10,7 +10,7 @@ export function removeClass(element, ...args) {
10
10
  }
11
11
 
12
12
  export function removeClasses(element, cls) {
13
- attr(element, 'class', value => (value || '').replace(new RegExp(`\\b${cls}\\b`, 'g'), ''));
13
+ attr(element, 'class', (value) => (value || '').replace(new RegExp(`\\b${cls}\\b`, 'g'), ''));
14
14
  }
15
15
 
16
16
  export function replaceClass(element, ...args) {
@@ -20,9 +20,8 @@ export function replaceClass(element, ...args) {
20
20
 
21
21
  export function hasClass(element, cls) {
22
22
  [cls] = getClasses(cls);
23
- const nodes = toNodes(element);
24
- for (let n = 0; n < nodes.length; n++) {
25
- if (cls && nodes[n].classList.contains(cls)) {
23
+ for (const node of toNodes(element)) {
24
+ if (cls && node.classList.contains(cls)) {
26
25
  return true;
27
26
  }
28
27
  }
@@ -30,64 +29,27 @@ export function hasClass(element, cls) {
30
29
  }
31
30
 
32
31
  export function toggleClass(element, cls, force) {
32
+ const classes = getClasses(cls);
33
33
 
34
- cls = getClasses(cls);
34
+ if (!isUndefined(force)) {
35
+ force = !!force;
36
+ }
35
37
 
36
- const nodes = toNodes(element);
37
- for (let n = 0; n < nodes.length; n++) {
38
- const list = nodes[n].classList;
39
- for (let i = 0; i < cls.length; i++) {
40
- if (isUndefined(force)) {
41
- list.toggle(cls[i]);
42
- } else if (supports.Force) {
43
- list.toggle(cls[i], !!force);
44
- } else {
45
- list[force ? 'add' : 'remove'](cls[i]);
46
- }
38
+ for (const node of toNodes(element)) {
39
+ for (const cls of classes) {
40
+ node.classList.toggle(cls, force);
47
41
  }
48
42
  }
49
43
  }
50
44
 
51
45
  function apply(element, args, fn) {
52
-
53
46
  args = args.reduce((args, arg) => args.concat(getClasses(arg)), []);
54
47
 
55
- const nodes = toNodes(element);
56
- for (let n = 0; n < nodes.length; n++) {
57
- if (supports.Multiple) {
58
- nodes[n].classList[fn](...args);
59
- } else {
60
- args.forEach(cls => nodes[n].classList[fn](cls));
61
- }
48
+ for (const node of toNodes(element)) {
49
+ node.classList[fn](...args);
62
50
  }
63
51
  }
64
52
 
65
53
  function getClasses(str) {
66
54
  return String(str).split(/\s|,/).filter(Boolean);
67
55
  }
68
-
69
- // IE 11
70
- let supports = {
71
-
72
- get Multiple() {
73
- return this.get('Multiple');
74
- },
75
-
76
- get Force() {
77
- return this.get('Force');
78
- },
79
-
80
- get(key) {
81
-
82
- const {classList} = document.createElement('_');
83
- classList.add('a', 'b');
84
- classList.toggle('c', false);
85
- supports = {
86
- Multiple: classList.contains('b'),
87
- Force: !classList.contains('c')
88
- };
89
-
90
- return supports[key];
91
- }
92
-
93
- };