No Description

style-inject.es-7ed2769c.js 6.5KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253
  1. var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
  2. function unwrapExports (x) {
  3. return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
  4. }
  5. function createCommonjsModule(fn, module) {
  6. return module = { exports: {} }, fn(module, module.exports), module.exports;
  7. }
  8. function getCjsExportFromNamespace (n) {
  9. return n && n['default'] || n;
  10. }
  11. function _classCallCheck(instance, Constructor) {
  12. if (!(instance instanceof Constructor)) {
  13. throw new TypeError("Cannot call a class as a function");
  14. }
  15. }
  16. function _defineProperties(target, props) {
  17. for (var i = 0; i < props.length; i++) {
  18. var descriptor = props[i];
  19. descriptor.enumerable = descriptor.enumerable || false;
  20. descriptor.configurable = true;
  21. if ("value" in descriptor) descriptor.writable = true;
  22. Object.defineProperty(target, descriptor.key, descriptor);
  23. }
  24. }
  25. function _createClass(Constructor, protoProps, staticProps) {
  26. if (protoProps) _defineProperties(Constructor.prototype, protoProps);
  27. if (staticProps) _defineProperties(Constructor, staticProps);
  28. return Constructor;
  29. }
  30. function _defineProperty(obj, key, value) {
  31. if (key in obj) {
  32. Object.defineProperty(obj, key, {
  33. value: value,
  34. enumerable: true,
  35. configurable: true,
  36. writable: true
  37. });
  38. } else {
  39. obj[key] = value;
  40. }
  41. return obj;
  42. }
  43. function ownKeys(object, enumerableOnly) {
  44. var keys = Object.keys(object);
  45. if (Object.getOwnPropertySymbols) {
  46. var symbols = Object.getOwnPropertySymbols(object);
  47. if (enumerableOnly) symbols = symbols.filter(function (sym) {
  48. return Object.getOwnPropertyDescriptor(object, sym).enumerable;
  49. });
  50. keys.push.apply(keys, symbols);
  51. }
  52. return keys;
  53. }
  54. function _objectSpread2(target) {
  55. for (var i = 1; i < arguments.length; i++) {
  56. var source = arguments[i] != null ? arguments[i] : {};
  57. if (i % 2) {
  58. ownKeys(Object(source), true).forEach(function (key) {
  59. _defineProperty(target, key, source[key]);
  60. });
  61. } else if (Object.getOwnPropertyDescriptors) {
  62. Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
  63. } else {
  64. ownKeys(Object(source)).forEach(function (key) {
  65. Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
  66. });
  67. }
  68. }
  69. return target;
  70. }
  71. function _inherits(subClass, superClass) {
  72. if (typeof superClass !== "function" && superClass !== null) {
  73. throw new TypeError("Super expression must either be null or a function");
  74. }
  75. subClass.prototype = Object.create(superClass && superClass.prototype, {
  76. constructor: {
  77. value: subClass,
  78. writable: true,
  79. configurable: true
  80. }
  81. });
  82. if (superClass) _setPrototypeOf(subClass, superClass);
  83. }
  84. function _getPrototypeOf(o) {
  85. _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) {
  86. return o.__proto__ || Object.getPrototypeOf(o);
  87. };
  88. return _getPrototypeOf(o);
  89. }
  90. function _setPrototypeOf(o, p) {
  91. _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {
  92. o.__proto__ = p;
  93. return o;
  94. };
  95. return _setPrototypeOf(o, p);
  96. }
  97. function _assertThisInitialized(self) {
  98. if (self === void 0) {
  99. throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
  100. }
  101. return self;
  102. }
  103. function _possibleConstructorReturn(self, call) {
  104. if (call && (typeof call === "object" || typeof call === "function")) {
  105. return call;
  106. }
  107. return _assertThisInitialized(self);
  108. }
  109. function _slicedToArray(arr, i) {
  110. return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest();
  111. }
  112. function _arrayWithHoles(arr) {
  113. if (Array.isArray(arr)) return arr;
  114. }
  115. function _iterableToArrayLimit(arr, i) {
  116. if (!(Symbol.iterator in Object(arr) || Object.prototype.toString.call(arr) === "[object Arguments]")) {
  117. return;
  118. }
  119. var _arr = [];
  120. var _n = true;
  121. var _d = false;
  122. var _e = undefined;
  123. try {
  124. for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) {
  125. _arr.push(_s.value);
  126. if (i && _arr.length === i) break;
  127. }
  128. } catch (err) {
  129. _d = true;
  130. _e = err;
  131. } finally {
  132. try {
  133. if (!_n && _i["return"] != null) _i["return"]();
  134. } finally {
  135. if (_d) throw _e;
  136. }
  137. }
  138. return _arr;
  139. }
  140. function _nonIterableRest() {
  141. throw new TypeError("Invalid attempt to destructure non-iterable instance");
  142. }
  143. var classnames = createCommonjsModule(function (module) {
  144. /*!
  145. Copyright (c) 2017 Jed Watson.
  146. Licensed under the MIT License (MIT), see
  147. http://jedwatson.github.io/classnames
  148. */
  149. /* global define */
  150. (function () {
  151. var hasOwn = {}.hasOwnProperty;
  152. function classNames () {
  153. var classes = [];
  154. for (var i = 0; i < arguments.length; i++) {
  155. var arg = arguments[i];
  156. if (!arg) continue;
  157. var argType = typeof arg;
  158. if (argType === 'string' || argType === 'number') {
  159. classes.push(arg);
  160. } else if (Array.isArray(arg) && arg.length) {
  161. var inner = classNames.apply(null, arg);
  162. if (inner) {
  163. classes.push(inner);
  164. }
  165. } else if (argType === 'object') {
  166. for (var key in arg) {
  167. if (hasOwn.call(arg, key) && arg[key]) {
  168. classes.push(key);
  169. }
  170. }
  171. }
  172. }
  173. return classes.join(' ');
  174. }
  175. if ( module.exports) {
  176. classNames.default = classNames;
  177. module.exports = classNames;
  178. } else {
  179. window.classNames = classNames;
  180. }
  181. }());
  182. });
  183. function styleInject(css, ref) {
  184. if ( ref === void 0 ) ref = {};
  185. var insertAt = ref.insertAt;
  186. if (!css || typeof document === 'undefined') { return; }
  187. var head = document.head || document.getElementsByTagName('head')[0];
  188. var style = document.createElement('style');
  189. style.type = 'text/css';
  190. if (insertAt === 'top') {
  191. if (head.firstChild) {
  192. head.insertBefore(style, head.firstChild);
  193. } else {
  194. head.appendChild(style);
  195. }
  196. } else {
  197. head.appendChild(style);
  198. }
  199. if (style.styleSheet) {
  200. style.styleSheet.cssText = css;
  201. } else {
  202. style.appendChild(document.createTextNode(css));
  203. }
  204. }
  205. export { _defineProperty as _, commonjsGlobal as a, _inherits as b, createCommonjsModule as c, _createClass as d, _classCallCheck as e, _possibleConstructorReturn as f, getCjsExportFromNamespace as g, _getPrototypeOf as h, classnames as i, _objectSpread2 as j, _slicedToArray as k, styleInject as s, unwrapExports as u };
  206. //# sourceMappingURL=style-inject.es-7ed2769c.js.map