@codecademy/gamut-tests 4.0.20-alpha.df5381.0 → 4.0.21-alpha.a0fbe3.0

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.
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import { setupEnzyme as setupEnzymeBase, setupRtl as setupRtlBase } from 'component-test-setup';
2
- import React from 'react';
2
+ import * as React from 'react';
3
3
  export declare const MockGamutProvider: React.FC<{
4
4
  children?: React.ReactNode;
5
5
  }>;
package/dist/index.js CHANGED
@@ -1,20 +1,30 @@
1
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
2
+
3
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
4
+
5
+ function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
6
+
1
7
  import { GamutProvider, theme } from '@codecademy/gamut-styles';
2
8
  import { setupEnzyme as setupEnzymeBase, setupRtl as setupRtlBase } from 'component-test-setup';
3
9
  import { overArgs } from 'lodash';
4
- import React from 'react'; // See https://www.notion.so/codecademy/Frontend-Unit-Tests-1cbf4e078a6647559b4583dfb6d3cb18
10
+ import * as React from 'react'; // See https://www.notion.so/codecademy/Frontend-Unit-Tests-1cbf4e078a6647559b4583dfb6d3cb18
5
11
 
12
+ import { jsx as _jsx } from "react/jsx-runtime";
6
13
  export var MockGamutProvider = function MockGamutProvider(_ref) {
7
14
  var children = _ref.children;
8
- return /*#__PURE__*/React.createElement(GamutProvider, {
15
+ return /*#__PURE__*/_jsx(GamutProvider, {
9
16
  useGlobals: false,
10
17
  useCache: false,
11
- theme: theme
12
- }, children);
18
+ theme: theme,
19
+ children: children
20
+ });
13
21
  };
14
22
 
15
23
  function withMockGamutProvider(WrappedComponent) {
16
24
  var WithBoundaryComponent = function WithBoundaryComponent(props) {
17
- return /*#__PURE__*/React.createElement(MockGamutProvider, null, /*#__PURE__*/React.createElement(WrappedComponent, props));
25
+ return /*#__PURE__*/_jsx(MockGamutProvider, {
26
+ children: /*#__PURE__*/_jsx(WrappedComponent, _objectSpread({}, props))
27
+ });
18
28
  };
19
29
 
20
30
  return WithBoundaryComponent;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "author": "Codecademy Engineering <dev@codecademy.com>",
3
3
  "dependencies": {
4
- "@codecademy/gamut-styles": "14.2.3-alpha.df5381.0",
4
+ "@codecademy/gamut-styles": "14.2.4-alpha.a0fbe3.0",
5
5
  "component-test-setup": "*",
6
6
  "lodash": "^4.17.5"
7
7
  },
@@ -14,7 +14,7 @@
14
14
  "rtl"
15
15
  ],
16
16
  "name": "@codecademy/gamut-tests",
17
- "version": "4.0.20-alpha.df5381.0",
17
+ "version": "4.0.21-alpha.a0fbe3.0",
18
18
  "license": "MIT",
19
19
  "main": "dist/index.js",
20
20
  "module": "dist/index.js",
@@ -22,7 +22,7 @@
22
22
  "dist"
23
23
  ],
24
24
  "peerDependencies": {
25
- "react": ">=18.2.0"
25
+ "react": "^17.0.2 || ^18.2.0"
26
26
  },
27
27
  "publishConfig": {
28
28
  "access": "public"
@@ -36,5 +36,5 @@
36
36
  "build": "nx build @codecademy/gamut-tests"
37
37
  },
38
38
  "types": "./dist/index.d.ts",
39
- "gitHead": "a9db4fc3727fad0ca1d6300825656000a86bde57"
39
+ "gitHead": "f5227a5f071031631be52b2f30856bfe7d388b51"
40
40
  }