@jsenv/core 23.8.2 → 23.8.7

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 (133) hide show
  1. package/dist/jsenv_browser_system.js +46 -39
  2. package/dist/jsenv_browser_system.js.map +14 -14
  3. package/dist/jsenv_compile_proxy.js.map +6 -6
  4. package/dist/jsenv_exploring_index.js.map +5 -5
  5. package/dist/jsenv_exploring_redirector.js.map +12 -12
  6. package/dist/jsenv_toolbar.js.map +7 -7
  7. package/dist/jsenv_toolbar_injector.js.map +5 -5
  8. package/helpers/babel/.eslintrc.cjs +24 -24
  9. package/helpers/babel/AsyncGenerator/AsyncGenerator.js +81 -81
  10. package/helpers/babel/AwaitValue/AwaitValue.js +3 -3
  11. package/helpers/babel/applyDecoratorDescriptor/applyDecoratorDescriptor.js +33 -33
  12. package/helpers/babel/arrayLikeToArray/arrayLikeToArray.js +7 -7
  13. package/helpers/babel/arrayWithHoles/arrayWithHoles.js +4 -4
  14. package/helpers/babel/arrayWithoutHoles/arrayWithoutHoles.js +6 -6
  15. package/helpers/babel/assertThisInitialized/assertThisInitialized.js +7 -7
  16. package/helpers/babel/asyncGeneratorDelegate/asyncGeneratorDelegate.js +40 -40
  17. package/helpers/babel/asyncIterator/asyncIterator.js +12 -12
  18. package/helpers/babel/asyncToGenerator/asyncToGenerator.js +34 -34
  19. package/helpers/babel/awaitAsyncGenerator/awaitAsyncGenerator.js +5 -5
  20. package/helpers/babel/classApplyDescriptorDestructureSet/classApplyDescriptorDestructureSet.js +20 -20
  21. package/helpers/babel/classApplyDescriptorGet/classApplyDescriptorGet.js +6 -6
  22. package/helpers/babel/classApplyDescriptorSet/classApplyDescriptorSet.js +13 -13
  23. package/helpers/babel/classCallCheck/classCallCheck.js +5 -5
  24. package/helpers/babel/classCheckPrivateStaticAccess/classCheckPrivateStaticAccess.js +5 -5
  25. package/helpers/babel/classCheckPrivateStaticFieldDescriptor/classCheckPrivateStaticFieldDescriptor.js +6 -6
  26. package/helpers/babel/classExtractFieldDescriptor/classExtractFieldDescriptor.js +7 -7
  27. package/helpers/babel/classNameTDZError/classNameTDZError.js +4 -4
  28. package/helpers/babel/classPrivateFieldDestructureSet/classPrivateFieldDestructureSet.js +7 -7
  29. package/helpers/babel/classPrivateFieldGet/classPrivateFieldGet.js +7 -7
  30. package/helpers/babel/classPrivateFieldLooseBase/classPrivateFieldLooseBase.js +6 -6
  31. package/helpers/babel/classPrivateFieldLooseKey/classPrivateFieldLooseKey.js +5 -5
  32. package/helpers/babel/classPrivateFieldSet/classPrivateFieldSet.js +8 -8
  33. package/helpers/babel/classPrivateMethodGet/classPrivateMethodGet.js +6 -6
  34. package/helpers/babel/classPrivateMethodSet/classPrivateMethodSet.js +3 -3
  35. package/helpers/babel/classStaticPrivateFieldSpecGet/classStaticPrivateFieldSpecGet.js +9 -9
  36. package/helpers/babel/classStaticPrivateFieldSpecSet/classStaticPrivateFieldSpecSet.js +15 -15
  37. package/helpers/babel/classStaticPrivateMethodGet/classStaticPrivateMethodGet.js +6 -6
  38. package/helpers/babel/classStaticPrivateMethodSet/classStaticPrivateMethodSet.js +3 -3
  39. package/helpers/babel/construct/construct.js +16 -16
  40. package/helpers/babel/createClass/createClass.js +15 -15
  41. package/helpers/babel/createForOfIteratorHelper/createForOfIteratorHelper.js +60 -60
  42. package/helpers/babel/createForOfIteratorHelperLoose/createForOfIteratorHelperLoose.js +23 -23
  43. package/helpers/babel/createRawReactElement/createRawReactElement.js +50 -50
  44. package/helpers/babel/createSuper/createSuper.js +22 -22
  45. package/helpers/babel/decorate/decorate.js +403 -403
  46. package/helpers/babel/defaults/defaults.js +11 -11
  47. package/helpers/babel/defineEnumerableProperties/defineEnumerableProperties.js +23 -23
  48. package/helpers/babel/defineProperty/defineProperty.js +18 -18
  49. package/helpers/babel/extends/extends.js +14 -14
  50. package/helpers/babel/get/get.js +13 -13
  51. package/helpers/babel/getPrototypeOf/getPrototypeOf.js +4 -4
  52. package/helpers/babel/inherits/inherits.js +15 -15
  53. package/helpers/babel/inheritsLoose/inheritsLoose.js +7 -7
  54. package/helpers/babel/initializerDefineProperty/initializerDefineProperty.js +10 -10
  55. package/helpers/babel/initializerWarningHelper/initializerWarningHelper.js +6 -6
  56. package/helpers/babel/instanceof/instanceof.js +6 -6
  57. package/helpers/babel/interopRequireDefault/interopRequireDefault.js +3 -3
  58. package/helpers/babel/interopRequireWildcard/interopRequireWildcard.js +37 -37
  59. package/helpers/babel/isNativeFunction/isNativeFunction.js +4 -4
  60. package/helpers/babel/isNativeReflectConstruct/isNativeReflectConstruct.js +21 -21
  61. package/helpers/babel/iterableToArray/iterableToArray.js +7 -7
  62. package/helpers/babel/iterableToArrayLimit/iterableToArrayLimit.js +36 -36
  63. package/helpers/babel/iterableToArrayLimitLoose/iterableToArrayLimitLoose.js +10 -10
  64. package/helpers/babel/jsx/jsx.js +45 -45
  65. package/helpers/babel/maybeArrayLike/maybeArrayLike.js +10 -10
  66. package/helpers/babel/newArrowCheck/newArrowCheck.js +5 -5
  67. package/helpers/babel/nonIterableRest/nonIterableRest.js +5 -5
  68. package/helpers/babel/nonIterableSpread/nonIterableSpread.js +5 -5
  69. package/helpers/babel/objectDestructuringEmpty/objectDestructuringEmpty.js +3 -3
  70. package/helpers/babel/objectSpread/objectSpread.js +23 -23
  71. package/helpers/babel/objectSpread2/objectSpread2.js +33 -33
  72. package/helpers/babel/objectWithoutProperties/objectWithoutProperties.js +19 -19
  73. package/helpers/babel/objectWithoutPropertiesLoose/objectWithoutPropertiesLoose.js +13 -13
  74. package/helpers/babel/possibleConstructorReturn/possibleConstructorReturn.js +10 -10
  75. package/helpers/babel/readOnlyError/readOnlyError.js +4 -4
  76. package/helpers/babel/readme.md +9 -9
  77. package/helpers/babel/set/set.js +44 -44
  78. package/helpers/babel/setPrototypeOf/setPrototypeOf.js +6 -6
  79. package/helpers/babel/skipFirstGeneratorNext/skipFirstGeneratorNext.js +8 -8
  80. package/helpers/babel/slicedToArray/slicedToArray.js +10 -10
  81. package/helpers/babel/slicedToArrayLoose/slicedToArrayLoose.js +13 -13
  82. package/helpers/babel/superPropBase/superPropBase.js +10 -10
  83. package/helpers/babel/taggedTemplateLiteral/taggedTemplateLiteral.js +10 -10
  84. package/helpers/babel/taggedTemplateLiteralLoose/taggedTemplateLiteralLoose.js +7 -7
  85. package/helpers/babel/tdz/tdz.js +4 -4
  86. package/helpers/babel/temporalRef/temporalRef.js +6 -6
  87. package/helpers/babel/temporalUndefined/temporalUndefined.js +3 -3
  88. package/helpers/babel/toArray/toArray.js +10 -10
  89. package/helpers/babel/toConsumableArray/toConsumableArray.js +10 -10
  90. package/helpers/babel/toPrimitive/toPrimitive.js +10 -10
  91. package/helpers/babel/toPropertyKey/toPropertyKey.js +6 -6
  92. package/helpers/babel/typeof/typeof.js +14 -14
  93. package/helpers/babel/unsupportedIterableToArray/unsupportedIterableToArray.js +12 -12
  94. package/helpers/babel/wrapAsyncGenerator/wrapAsyncGenerator.js +8 -8
  95. package/helpers/babel/wrapNativeSuper/wrapNativeSuper.js +30 -30
  96. package/helpers/babel/wrapRegExp/wrapRegExp.js +63 -63
  97. package/helpers/babel/writeOnlyError/writeOnlyError.js +4 -4
  98. package/helpers/regenerator-runtime/regenerator-runtime.js +748 -748
  99. package/{LICENSE → license} +21 -21
  100. package/package.json +2 -2
  101. package/src/buildProject.js +300 -300
  102. package/src/execute.js +184 -184
  103. package/src/internal/browser-launcher/jsenv-browser-system.js +203 -199
  104. package/src/internal/building/buildUsingRollup.js +2 -10
  105. package/src/internal/compiling/babel_plugin_import_assertions.js +121 -121
  106. package/src/internal/compiling/babel_plugin_import_metadata.js +22 -22
  107. package/src/internal/compiling/babel_plugin_import_visitor.js +84 -84
  108. package/src/internal/compiling/compile-directory/getOrGenerateCompiledFile.js +268 -268
  109. package/src/internal/compiling/compile-directory/updateMeta.js +154 -154
  110. package/src/internal/compiling/compile-directory/validateCache.js +265 -265
  111. package/src/internal/compiling/compileFile.js +233 -224
  112. package/src/internal/compiling/compileHtml.js +550 -550
  113. package/src/internal/compiling/createCompiledFileService.js +291 -291
  114. package/src/internal/compiling/html_source_file_service.js +403 -404
  115. package/src/internal/compiling/js-compilation-service/jsenvTransform.js +272 -270
  116. package/src/internal/compiling/jsenvCompilerForHtml.js +374 -308
  117. package/src/internal/compiling/jsenvCompilerForJavaScript.js +2 -0
  118. package/src/internal/compiling/startCompileServer.js +1086 -1048
  119. package/src/internal/compiling/transformResultToCompilationResult.js +220 -220
  120. package/src/internal/executing/coverage/babel_plugin_instrument.js +90 -90
  121. package/src/internal/executing/coverage/reportToCoverage.js +193 -187
  122. package/src/internal/executing/executePlan.js +183 -183
  123. package/src/internal/executing/launchAndExecute.js +458 -458
  124. package/src/internal/generateGroupMap/featuresCompatMap.js +29 -0
  125. package/src/internal/generateGroupMap/jsenvBabelPluginCompatMap.js +1 -8
  126. package/src/internal/runtime/createBrowserRuntime/scanBrowserRuntimeFeatures.js +246 -246
  127. package/src/internal/runtime/createNodeRuntime/scanNodeRuntimeFeatures.js +112 -112
  128. package/src/internal/runtime/s.js +727 -727
  129. package/src/internal/toolbar/jsenv-logo.svg +144 -144
  130. package/src/internal/toolbar/toolbar.main.css +196 -196
  131. package/src/internal/toolbar/toolbar.main.js +227 -227
  132. package/src/internal/url_conversion.js +317 -317
  133. package/src/startExploring.js +309 -309
@@ -1,11 +1,11 @@
1
- export default function (obj, defaults) {
2
- var keys = Object.getOwnPropertyNames(defaults)
3
- for (var i = 0; i < keys.length; i++) {
4
- var key = keys[i]
5
- var value = Object.getOwnPropertyDescriptor(defaults, key)
6
- if (value && value.configurable && obj[key] === undefined) {
7
- Object.defineProperty(obj, key, value)
8
- }
9
- }
10
- return obj
11
- }
1
+ export default function (obj, defaults) {
2
+ var keys = Object.getOwnPropertyNames(defaults)
3
+ for (var i = 0; i < keys.length; i++) {
4
+ var key = keys[i]
5
+ var value = Object.getOwnPropertyDescriptor(defaults, key)
6
+ if (value && value.configurable && obj[key] === undefined) {
7
+ Object.defineProperty(obj, key, value)
8
+ }
9
+ }
10
+ return obj
11
+ }
@@ -1,23 +1,23 @@
1
- export default function (obj, descs) {
2
- // eslint-disable-next-line guard-for-in
3
- for (var key in descs) {
4
- var desc = descs[key]
5
- desc.configurable = desc.enumerable = true
6
- if ("value" in desc) desc.writable = true
7
- Object.defineProperty(obj, key, desc)
8
- }
9
- // Symbols are not enumerated over by for-in loops. If native
10
- // Symbols are available, fetch all of the descs object's own
11
- // symbol properties and define them on our target object too.
12
- if (Object.getOwnPropertySymbols) {
13
- var objectSymbols = Object.getOwnPropertySymbols(descs)
14
- for (var i = 0; i < objectSymbols.length; i++) {
15
- var sym = objectSymbols[i]
16
- var symbDesc = descs[sym]
17
- symbDesc.configurable = symbDesc.enumerable = true
18
- if ("value" in symbDesc) symbDesc.writable = true
19
- Object.defineProperty(obj, sym, symbDesc)
20
- }
21
- }
22
- return obj
23
- }
1
+ export default function (obj, descs) {
2
+ // eslint-disable-next-line guard-for-in
3
+ for (var key in descs) {
4
+ var desc = descs[key]
5
+ desc.configurable = desc.enumerable = true
6
+ if ("value" in desc) desc.writable = true
7
+ Object.defineProperty(obj, key, desc)
8
+ }
9
+ // Symbols are not enumerated over by for-in loops. If native
10
+ // Symbols are available, fetch all of the descs object's own
11
+ // symbol properties and define them on our target object too.
12
+ if (Object.getOwnPropertySymbols) {
13
+ var objectSymbols = Object.getOwnPropertySymbols(descs)
14
+ for (var i = 0; i < objectSymbols.length; i++) {
15
+ var sym = objectSymbols[i]
16
+ var symbDesc = descs[sym]
17
+ symbDesc.configurable = symbDesc.enumerable = true
18
+ if ("value" in symbDesc) symbDesc.writable = true
19
+ Object.defineProperty(obj, sym, symbDesc)
20
+ }
21
+ }
22
+ return obj
23
+ }
@@ -1,18 +1,18 @@
1
- export default (obj, key, value) => {
2
- // Shortcircuit the slow defineProperty path when possible.
3
- // We are trying to avoid issues where setters defined on the
4
- // prototype cause side effects under the fast path of simple
5
- // assignment. By checking for existence of the property with
6
- // the in operator, we can optimize most of this overhead away.
7
- if (key in obj) {
8
- Object.defineProperty(obj, key, {
9
- value,
10
- enumerable: true,
11
- configurable: true,
12
- writable: true,
13
- })
14
- } else {
15
- obj[key] = value
16
- }
17
- return obj
18
- }
1
+ export default (obj, key, value) => {
2
+ // Shortcircuit the slow defineProperty path when possible.
3
+ // We are trying to avoid issues where setters defined on the
4
+ // prototype cause side effects under the fast path of simple
5
+ // assignment. By checking for existence of the property with
6
+ // the in operator, we can optimize most of this overhead away.
7
+ if (key in obj) {
8
+ Object.defineProperty(obj, key, {
9
+ value,
10
+ enumerable: true,
11
+ configurable: true,
12
+ writable: true,
13
+ })
14
+ } else {
15
+ obj[key] = value
16
+ }
17
+ return obj
18
+ }
@@ -1,14 +1,14 @@
1
- function assign(target) {
2
- for (var i = 1; i < arguments.length; i++) {
3
- // eslint-disable-next-line prefer-rest-params
4
- var source = arguments[i]
5
- for (var key in source) {
6
- if (Object.prototype.hasOwnProperty.call(source, key)) {
7
- target[key] = source[key]
8
- }
9
- }
10
- }
11
- return target
12
- }
13
-
14
- export default Object.assign || assign
1
+ function assign(target) {
2
+ for (var i = 1; i < arguments.length; i++) {
3
+ // eslint-disable-next-line prefer-rest-params
4
+ var source = arguments[i]
5
+ for (var key in source) {
6
+ if (Object.prototype.hasOwnProperty.call(source, key)) {
7
+ target[key] = source[key]
8
+ }
9
+ }
10
+ }
11
+ return target
12
+ }
13
+
14
+ export default Object.assign || assign
@@ -1,13 +1,13 @@
1
- import superPropBase from "../superPropBase/superPropBase.js"
2
-
3
- function reflectGet(target, property, receiver) {
4
- var base = superPropBase(target, property)
5
- if (!base) return undefined
6
- var desc = Object.getOwnPropertyDescriptor(base, property)
7
- if (desc.get) {
8
- return desc.get.call(receiver)
9
- }
10
- return desc.value
11
- }
12
-
13
- export default typeof Reflect !== "undefined" && Reflect.get ? Reflect.get : reflectGet
1
+ import superPropBase from "../superPropBase/superPropBase.js"
2
+
3
+ function reflectGet(target, property, receiver) {
4
+ var base = superPropBase(target, property)
5
+ if (!base) return undefined
6
+ var desc = Object.getOwnPropertyDescriptor(base, property)
7
+ if (desc.get) {
8
+ return desc.get.call(receiver)
9
+ }
10
+ return desc.value
11
+ }
12
+
13
+ export default typeof Reflect !== "undefined" && Reflect.get ? Reflect.get : reflectGet
@@ -1,4 +1,4 @@
1
- export default Object.setPrototypeOf
2
- ? Object.getPrototypeOf
3
- : // eslint-disable-next-line no-proto
4
- (o) => o.__proto__ || Object.getPrototypeOf(o)
1
+ export default Object.setPrototypeOf
2
+ ? Object.getPrototypeOf
3
+ : // eslint-disable-next-line no-proto
4
+ (o) => o.__proto__ || Object.getPrototypeOf(o)
@@ -1,15 +1,15 @@
1
- import setPrototypeOf from "../setPrototypeOf/setPrototypeOf.js"
2
-
3
- export default function _inherits(subClass, superClass) {
4
- if (typeof superClass !== "function" && superClass !== null) {
5
- throw new TypeError("Super expression must either be null or a function")
6
- }
7
- subClass.prototype = Object.create(superClass && superClass.prototype, {
8
- constructor: {
9
- value: subClass,
10
- writable: true,
11
- configurable: true,
12
- },
13
- })
14
- if (superClass) setPrototypeOf(subClass, superClass)
15
- }
1
+ import setPrototypeOf from "../setPrototypeOf/setPrototypeOf.js"
2
+
3
+ export default function _inherits(subClass, superClass) {
4
+ if (typeof superClass !== "function" && superClass !== null) {
5
+ throw new TypeError("Super expression must either be null or a function")
6
+ }
7
+ subClass.prototype = Object.create(superClass && superClass.prototype, {
8
+ constructor: {
9
+ value: subClass,
10
+ writable: true,
11
+ configurable: true,
12
+ },
13
+ })
14
+ if (superClass) setPrototypeOf(subClass, superClass)
15
+ }
@@ -1,7 +1,7 @@
1
- import setPrototypeOf from "../setPrototypeOf/setPrototypeOf.js"
2
-
3
- export default function (subClass, superClass) {
4
- subClass.prototype = Object.create(superClass.prototype)
5
- subClass.prototype.constructor = subClass
6
- setPrototypeOf(subClass, superClass)
7
- }
1
+ import setPrototypeOf from "../setPrototypeOf/setPrototypeOf.js"
2
+
3
+ export default function (subClass, superClass) {
4
+ subClass.prototype = Object.create(superClass.prototype)
5
+ subClass.prototype.constructor = subClass
6
+ setPrototypeOf(subClass, superClass)
7
+ }
@@ -1,10 +1,10 @@
1
- export default function (target, property, descriptor, context) {
2
- if (!descriptor) return
3
- Object.defineProperty(target, property, {
4
- enumerable: descriptor.enumerable,
5
- configurable: descriptor.configurable,
6
- writable: descriptor.writable,
7
- // eslint-disable-next-line no-void
8
- value: descriptor.initializer ? descriptor.initializer.call(context) : void 0,
9
- })
10
- }
1
+ export default function (target, property, descriptor, context) {
2
+ if (!descriptor) return
3
+ Object.defineProperty(target, property, {
4
+ enumerable: descriptor.enumerable,
5
+ configurable: descriptor.configurable,
6
+ writable: descriptor.writable,
7
+ // eslint-disable-next-line no-void
8
+ value: descriptor.initializer ? descriptor.initializer.call(context) : void 0,
9
+ })
10
+ }
@@ -1,6 +1,6 @@
1
- export default function () {
2
- throw new Error(
3
- "Decorating class property failed. Please ensure that " +
4
- "proposal-class-properties is enabled and runs after the decorators transform.",
5
- )
6
- }
1
+ export default function () {
2
+ throw new Error(
3
+ "Decorating class property failed. Please ensure that " +
4
+ "proposal-class-properties is enabled and runs after the decorators transform.",
5
+ )
6
+ }
@@ -1,6 +1,6 @@
1
- export default function (left, right) {
2
- if (right !== null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
3
- return Boolean(right[Symbol.hasInstance](left))
4
- }
5
- return left instanceof right
6
- }
1
+ export default function (left, right) {
2
+ if (right !== null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
3
+ return Boolean(right[Symbol.hasInstance](left))
4
+ }
5
+ return left instanceof right
6
+ }
@@ -1,3 +1,3 @@
1
- export default function (obj) {
2
- return obj && obj.__esModule ? obj : { default: obj }
3
- }
1
+ export default function (obj) {
2
+ return obj && obj.__esModule ? obj : { default: obj }
3
+ }
@@ -1,37 +1,37 @@
1
- function _getRequireWildcardCache(nodeInterop) {
2
- if (typeof WeakMap !== "function") return null
3
- var cacheBabelInterop = new WeakMap()
4
- var cacheNodeInterop = new WeakMap()
5
- return (_getRequireWildcardCache = function (nodeInterop) {
6
- return nodeInterop ? cacheNodeInterop : cacheBabelInterop
7
- })(nodeInterop)
8
- }
9
- export default function _interopRequireWildcard(obj, nodeInterop) {
10
- if (!nodeInterop && obj && obj.__esModule) {
11
- return obj
12
- }
13
- if (obj === null || (typeof obj !== "object" && typeof obj !== "function")) {
14
- return { default: obj }
15
- }
16
- var cache = _getRequireWildcardCache(nodeInterop)
17
- if (cache && cache.has(obj)) {
18
- return cache.get(obj)
19
- }
20
- var newObj = {}
21
- var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor
22
- for (var key in obj) {
23
- if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) {
24
- var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null
25
- if (desc && (desc.get || desc.set)) {
26
- Object.defineProperty(newObj, key, desc)
27
- } else {
28
- newObj[key] = obj[key]
29
- }
30
- }
31
- }
32
- newObj.default = obj
33
- if (cache) {
34
- cache.set(obj, newObj)
35
- }
36
- return newObj
37
- }
1
+ function _getRequireWildcardCache(nodeInterop) {
2
+ if (typeof WeakMap !== "function") return null
3
+ var cacheBabelInterop = new WeakMap()
4
+ var cacheNodeInterop = new WeakMap()
5
+ return (_getRequireWildcardCache = function (nodeInterop) {
6
+ return nodeInterop ? cacheNodeInterop : cacheBabelInterop
7
+ })(nodeInterop)
8
+ }
9
+ export default function _interopRequireWildcard(obj, nodeInterop) {
10
+ if (!nodeInterop && obj && obj.__esModule) {
11
+ return obj
12
+ }
13
+ if (obj === null || (typeof obj !== "object" && typeof obj !== "function")) {
14
+ return { default: obj }
15
+ }
16
+ var cache = _getRequireWildcardCache(nodeInterop)
17
+ if (cache && cache.has(obj)) {
18
+ return cache.get(obj)
19
+ }
20
+ var newObj = {}
21
+ var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor
22
+ for (var key in obj) {
23
+ if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) {
24
+ var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null
25
+ if (desc && (desc.get || desc.set)) {
26
+ Object.defineProperty(newObj, key, desc)
27
+ } else {
28
+ newObj[key] = obj[key]
29
+ }
30
+ }
31
+ }
32
+ newObj.default = obj
33
+ if (cache) {
34
+ cache.set(obj, newObj)
35
+ }
36
+ return newObj
37
+ }
@@ -1,4 +1,4 @@
1
- // Note: This function returns "true" for core-js functions.
2
- export default function (fn) {
3
- return Function.toString.call(fn).indexOf("[native code]") !== -1
4
- }
1
+ // Note: This function returns "true" for core-js functions.
2
+ export default function (fn) {
3
+ return Function.toString.call(fn).indexOf("[native code]") !== -1
4
+ }
@@ -1,21 +1,21 @@
1
- export default function isNativeReflectConstruct() {
2
- if (typeof Reflect === "undefined" || !Reflect.construct) return false
3
- // core-js@3
4
- if (Reflect.construct.sham) return false
5
- // Proxy can't be polyfilled. Every browser implemented
6
- // proxies before or at the same time as Reflect.construct,
7
- // so if they support Proxy they also support Reflect.construct.
8
- if (typeof Proxy === "function") return true
9
- // Since Reflect.construct can't be properly polyfilled, some
10
- // implementations (e.g. core-js@2) don't set the correct internal slots.
11
- // Those polyfills don't allow us to subclass built-ins, so we need to
12
- // use our fallback implementation.
13
- try {
14
- // If the internal slots aren't set, this throws an error similar to
15
- // TypeError: this is not a Boolean object.
16
- Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}))
17
- return true
18
- } catch (e) {
19
- return false
20
- }
21
- }
1
+ export default function isNativeReflectConstruct() {
2
+ if (typeof Reflect === "undefined" || !Reflect.construct) return false
3
+ // core-js@3
4
+ if (Reflect.construct.sham) return false
5
+ // Proxy can't be polyfilled. Every browser implemented
6
+ // proxies before or at the same time as Reflect.construct,
7
+ // so if they support Proxy they also support Reflect.construct.
8
+ if (typeof Proxy === "function") return true
9
+ // Since Reflect.construct can't be properly polyfilled, some
10
+ // implementations (e.g. core-js@2) don't set the correct internal slots.
11
+ // Those polyfills don't allow us to subclass built-ins, so we need to
12
+ // use our fallback implementation.
13
+ try {
14
+ // If the internal slots aren't set, this throws an error similar to
15
+ // TypeError: this is not a Boolean object.
16
+ Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}))
17
+ return true
18
+ } catch (e) {
19
+ return false
20
+ }
21
+ }
@@ -1,7 +1,7 @@
1
- export default function _iterableToArray(iter) {
2
- if (
3
- (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null) ||
4
- iter["@@iterator"] != null
5
- )
6
- return Array.from(iter)
7
- }
1
+ export default function _iterableToArray(iter) {
2
+ if (
3
+ (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null) ||
4
+ iter["@@iterator"] != null
5
+ )
6
+ return Array.from(iter)
7
+ }
@@ -1,36 +1,36 @@
1
- export default function _iterableToArrayLimit(arr, i) {
2
- // this is an expanded form of \`for...of\` that properly supports abrupt completions of
3
- // iterators etc. variable names have been minimised to reduce the size of this massive
4
- // helper. sometimes spec compliance is annoying :(
5
- //
6
- // _n = _iteratorNormalCompletion
7
- // _d = _didIteratorError
8
- // _e = _iteratorError
9
- // _i = _iterator
10
- // _s = _step
11
- var _i =
12
- arr == null
13
- ? null
14
- : (typeof Symbol !== "undefined" && arr[Symbol.iterator]) || arr["@@iterator"]
15
- if (_i == null) return
16
- var _arr = []
17
- var _n = true
18
- var _d = false
19
- var _s, _e
20
- try {
21
- for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) {
22
- _arr.push(_s.value)
23
- if (i && _arr.length === i) break
24
- }
25
- } catch (err) {
26
- _d = true
27
- _e = err
28
- } finally {
29
- try {
30
- if (!_n && _i["return"] != null) _i["return"]()
31
- } finally {
32
- if (_d) throw _e
33
- }
34
- }
35
- return _arr
36
- }
1
+ export default function _iterableToArrayLimit(arr, i) {
2
+ // this is an expanded form of \`for...of\` that properly supports abrupt completions of
3
+ // iterators etc. variable names have been minimised to reduce the size of this massive
4
+ // helper. sometimes spec compliance is annoying :(
5
+ //
6
+ // _n = _iteratorNormalCompletion
7
+ // _d = _didIteratorError
8
+ // _e = _iteratorError
9
+ // _i = _iterator
10
+ // _s = _step
11
+ var _i =
12
+ arr == null
13
+ ? null
14
+ : (typeof Symbol !== "undefined" && arr[Symbol.iterator]) || arr["@@iterator"]
15
+ if (_i == null) return
16
+ var _arr = []
17
+ var _n = true
18
+ var _d = false
19
+ var _s, _e
20
+ try {
21
+ for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) {
22
+ _arr.push(_s.value)
23
+ if (i && _arr.length === i) break
24
+ }
25
+ } catch (err) {
26
+ _d = true
27
+ _e = err
28
+ } finally {
29
+ try {
30
+ if (!_n && _i["return"] != null) _i["return"]()
31
+ } finally {
32
+ if (_d) throw _e
33
+ }
34
+ }
35
+ return _arr
36
+ }
@@ -1,10 +1,10 @@
1
- export default function (arr, i) {
2
- if (typeof Symbol === "undefined" || !(Symbol.iterator in Object(arr))) return
3
- var _arr = []
4
- for (var _iterator = arr[Symbol.iterator](), _step; !(_step = _iterator.next()).done; ) {
5
- _arr.push(_step.value)
6
- if (i && _arr.length === i) break
7
- }
8
- // eslint-disable-next-line consistent-return
9
- return _arr
10
- }
1
+ export default function (arr, i) {
2
+ if (typeof Symbol === "undefined" || !(Symbol.iterator in Object(arr))) return
3
+ var _arr = []
4
+ for (var _iterator = arr[Symbol.iterator](), _step; !(_step = _iterator.next()).done; ) {
5
+ _arr.push(_step.value)
6
+ if (i && _arr.length === i) break
7
+ }
8
+ // eslint-disable-next-line consistent-return
9
+ return _arr
10
+ }
@@ -1,45 +1,45 @@
1
- var REACT_ELEMENT_TYPE
2
- export default function (type, props, key, children) {
3
- if (!REACT_ELEMENT_TYPE) {
4
- REACT_ELEMENT_TYPE =
5
- (typeof Symbol === "function" && Symbol.for && Symbol.for("react.element")) || 0xeac7
6
- }
7
- var defaultProps = type && type.defaultProps
8
- var childrenLength = arguments.length - 3
9
- if (!props && childrenLength !== 0) {
10
- // If we're going to assign props.children, we create a new object now
11
- // to avoid mutating defaultProps.
12
- props = {
13
- // eslint-disable-next-line no-void
14
- children: void 0,
15
- }
16
- }
17
- if (childrenLength === 1) {
18
- props.children = children
19
- } else if (childrenLength > 1) {
20
- var childArray = new Array(childrenLength)
21
- for (var i = 0; i < childrenLength; i++) {
22
- // eslint-disable-next-line prefer-rest-params
23
- childArray[i] = arguments[i + 3]
24
- }
25
- props.children = childArray
26
- }
27
- if (props && defaultProps) {
28
- for (var propName in defaultProps) {
29
- // eslint-disable-next-line no-void
30
- if (props[propName] === void 0) {
31
- props[propName] = defaultProps[propName]
32
- }
33
- }
34
- } else if (!props) {
35
- props = defaultProps || {}
36
- }
37
- return {
38
- $$typeof: REACT_ELEMENT_TYPE,
39
- type,
40
- key: key === undefined ? null : `${key}`,
41
- ref: null,
42
- props,
43
- _owner: null,
44
- }
45
- }
1
+ var REACT_ELEMENT_TYPE
2
+ export default function (type, props, key, children) {
3
+ if (!REACT_ELEMENT_TYPE) {
4
+ REACT_ELEMENT_TYPE =
5
+ (typeof Symbol === "function" && Symbol.for && Symbol.for("react.element")) || 0xeac7
6
+ }
7
+ var defaultProps = type && type.defaultProps
8
+ var childrenLength = arguments.length - 3
9
+ if (!props && childrenLength !== 0) {
10
+ // If we're going to assign props.children, we create a new object now
11
+ // to avoid mutating defaultProps.
12
+ props = {
13
+ // eslint-disable-next-line no-void
14
+ children: void 0,
15
+ }
16
+ }
17
+ if (childrenLength === 1) {
18
+ props.children = children
19
+ } else if (childrenLength > 1) {
20
+ var childArray = new Array(childrenLength)
21
+ for (var i = 0; i < childrenLength; i++) {
22
+ // eslint-disable-next-line prefer-rest-params
23
+ childArray[i] = arguments[i + 3]
24
+ }
25
+ props.children = childArray
26
+ }
27
+ if (props && defaultProps) {
28
+ for (var propName in defaultProps) {
29
+ // eslint-disable-next-line no-void
30
+ if (props[propName] === void 0) {
31
+ props[propName] = defaultProps[propName]
32
+ }
33
+ }
34
+ } else if (!props) {
35
+ props = defaultProps || {}
36
+ }
37
+ return {
38
+ $$typeof: REACT_ELEMENT_TYPE,
39
+ type,
40
+ key: key === undefined ? null : `${key}`,
41
+ ref: null,
42
+ props,
43
+ _owner: null,
44
+ }
45
+ }
@@ -1,10 +1,10 @@
1
- import arrayLikeToArray from "../arrayLikeToArray/arrayLikeToArray.js"
2
-
3
- export default function _maybeArrayLike(next, arr, i) {
4
- if (arr && !Array.isArray(arr) && typeof arr.length === "number") {
5
- var len = arr.length
6
- // eslint-disable-next-line no-void
7
- return arrayLikeToArray(arr, i !== void 0 && i < len ? i : len)
8
- }
9
- return next(arr, i)
10
- }
1
+ import arrayLikeToArray from "../arrayLikeToArray/arrayLikeToArray.js"
2
+
3
+ export default function _maybeArrayLike(next, arr, i) {
4
+ if (arr && !Array.isArray(arr) && typeof arr.length === "number") {
5
+ var len = arr.length
6
+ // eslint-disable-next-line no-void
7
+ return arrayLikeToArray(arr, i !== void 0 && i < len ? i : len)
8
+ }
9
+ return next(arr, i)
10
+ }
@@ -1,5 +1,5 @@
1
- export default function _newArrowCheck(innerThis, boundThis) {
2
- if (innerThis !== boundThis) {
3
- throw new TypeError("Cannot instantiate an arrow function")
4
- }
5
- }
1
+ export default function _newArrowCheck(innerThis, boundThis) {
2
+ if (innerThis !== boundThis) {
3
+ throw new TypeError("Cannot instantiate an arrow function")
4
+ }
5
+ }