"use strict";

var _react = _interopRequireDefault(require("react"));
var _reactNative = require("@testing-library/react-native");
var _stack = _interopRequireWildcard(require("./stack"));
var _themeContext = require("../../../theme/src/theme-context");
var _divider = _interopRequireDefault(require("../divider/divider"));
var _box = _interopRequireDefault(require("../box/box"));
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
jest.useFakeTimers();
describe("Atoms/Stack", () => {
  it("passes the snapshot test for horizontal direction", () => {
    const tree = (0, _reactNative.render)( /*#__PURE__*/_react.default.createElement(_themeContext.ThemeProvider, null, /*#__PURE__*/_react.default.createElement(_stack.default, {
      direction: "horizontal",
      spacing: "l",
      divider: /*#__PURE__*/_react.default.createElement(_divider.default, null)
    }, /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 20,
      h: 100,
      backgroundColor: "primary.500"
    }), /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 20,
      h: 20,
      backgroundColor: "primary.500"
    }), /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 20,
      h: 20,
      backgroundColor: "primary.500"
    }), /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 20,
      h: 20,
      backgroundColor: "primary.500"
    })))).toJSON();
    expect(tree).toMatchSnapshot();
  });
  it("passes the snapshot test for vertical direction", () => {
    const tree = (0, _reactNative.render)( /*#__PURE__*/_react.default.createElement(_themeContext.ThemeProvider, null, /*#__PURE__*/_react.default.createElement(_stack.default, {
      mt: "l",
      direction: "vertical",
      spacing: "l",
      divider: /*#__PURE__*/_react.default.createElement(_divider.default, null)
    }, /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 100,
      h: 20,
      backgroundColor: "primary.500"
    }), /*#__PURE__*/_react.default.createElement(_box.default, {
      w: "40%",
      h: 20,
      backgroundColor: "primary.500"
    }), /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 20,
      h: 20,
      backgroundColor: "primary.500"
    }), /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 20,
      h: 20,
      backgroundColor: "primary.500"
    })))).toJSON();
    expect(tree).toMatchSnapshot();
  });
});
describe("Atoms/HStack", () => {
  it("passes the snapshot test", () => {
    const tree = (0, _reactNative.render)( /*#__PURE__*/_react.default.createElement(_themeContext.ThemeProvider, null, /*#__PURE__*/_react.default.createElement(_stack.HStack, {
      spacing: "l",
      divider: /*#__PURE__*/_react.default.createElement(_divider.default, null)
    }, /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 20,
      h: 100,
      backgroundColor: "primary.500"
    }), /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 20,
      h: 20,
      backgroundColor: "primary.500"
    }), /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 20,
      h: 20,
      backgroundColor: "primary.500"
    }), /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 20,
      h: 20,
      backgroundColor: "primary.500"
    })))).toJSON();
    expect(tree).toMatchSnapshot();
  });
});
describe("Atoms/VStack", () => {
  it("passes the snapshot test", () => {
    const tree = (0, _reactNative.render)( /*#__PURE__*/_react.default.createElement(_themeContext.ThemeProvider, null, /*#__PURE__*/_react.default.createElement(_stack.VStack, {
      spacing: "l",
      divider: /*#__PURE__*/_react.default.createElement(_divider.default, null)
    }, /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 20,
      h: 100,
      backgroundColor: "primary.500"
    }), /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 20,
      h: 20,
      backgroundColor: "primary.500"
    }), /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 20,
      h: 20,
      backgroundColor: "primary.500"
    }), /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 20,
      h: 20,
      backgroundColor: "primary.500"
    })))).toJSON();
    expect(tree).toMatchSnapshot();
  });
});
describe("Atoms/ZStack", () => {
  it("passes the snapshot test", () => {
    const tree = (0, _reactNative.render)( /*#__PURE__*/_react.default.createElement(_themeContext.ThemeProvider, null, /*#__PURE__*/_react.default.createElement(_stack.ZStack, null, /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 100,
      h: 100,
      backgroundColor: "primary.500"
    }), /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 50,
      h: 50,
      backgroundColor: "neutral.500"
    }), /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 20,
      h: 20,
      backgroundColor: "danger.500"
    })), /*#__PURE__*/_react.default.createElement(_stack.ZStack, {
      mt: "8",
      reversed: true
    }, /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 100,
      h: 100,
      backgroundColor: "primary.500"
    }), /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 50,
      h: 50,
      backgroundColor: "neutral.500"
    }), /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 20,
      h: 20,
      backgroundColor: "danger.500"
    })), /*#__PURE__*/_react.default.createElement(_stack.ZStack, {
      mt: "8"
    }, /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 100,
      h: 100,
      backgroundColor: "primary.500"
    }), /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 50,
      h: 50,
      zIndex: "docked",
      backgroundColor: "neutral.500"
    }), /*#__PURE__*/_react.default.createElement(_box.default, {
      w: 20,
      h: 20,
      backgroundColor: "danger.500"
    })))).toJSON();
    expect(tree).toMatchSnapshot();
  });
});
//# sourceMappingURL=stack.spec.js.map