import { jsx, jsxs } from "react/jsx-runtime";
import React from "react";
import { render } from "@testing-library/react";
import { Building } from "@gympass/yoga-icons";
import { ThemeProvider, Tag, v3theme } from "../..";
describe("<Tag />", () => {
  it("should match snapshot when v3Theme is settled", () => {
    const { container } = render(
      /* @__PURE__ */ jsx(ThemeProvider, { theme: v3theme, children: /* @__PURE__ */ jsx(Tag, { children: "v3Theme" }) })
    );
    expect(container).toMatchSnapshot();
  });
  it("should match snapshot", () => {
    const { container } = render(
      /* @__PURE__ */ jsx(ThemeProvider, { children: /* @__PURE__ */ jsx(Tag, { children: "default" }) })
    );
    expect(container).toMatchSnapshot();
  });
  it("should match snapshot with custom icon and informative type", () => {
    const { container } = render(
      /* @__PURE__ */ jsx(ThemeProvider, { children: /* @__PURE__ */ jsx(Tag.Informative, { variant: "success", icon: Building, children: "success with custom icon" }) })
    );
    expect(container).toMatchSnapshot();
  });
  it("should match snapshot with without icon and informative type", () => {
    const { container } = render(
      /* @__PURE__ */ jsx(ThemeProvider, { children: /* @__PURE__ */ jsx(Tag.Informative, { variant: "success", children: "success without icon" }) })
    );
    expect(container).toMatchSnapshot();
  });
  it("should match snapshot with variant prop", () => {
    const { container } = render(
      /* @__PURE__ */ jsxs(ThemeProvider, { children: [
        /* @__PURE__ */ jsx(Tag, { variant: "success", children: "success" }),
        /* @__PURE__ */ jsx(Tag, { variant: "informative", children: "informative" }),
        /* @__PURE__ */ jsx(Tag, { variant: "attention", children: "attention" })
      ] })
    );
    expect(container).toMatchSnapshot();
  });
  it("should match snapshot with variant prop and informative type", () => {
    const { container } = render(
      /* @__PURE__ */ jsxs(ThemeProvider, { children: [
        /* @__PURE__ */ jsx(Tag.Informative, { variant: "success", children: "success" }),
        /* @__PURE__ */ jsx(Tag.Informative, { variant: "informative", children: "informative" }),
        /* @__PURE__ */ jsx(Tag.Informative, { variant: "attention", children: "attention" })
      ] })
    );
    expect(container).toMatchSnapshot();
  });
  it("should match snapshot with variant and margin prop ", () => {
    const { container } = render(
      /* @__PURE__ */ jsxs(ThemeProvider, { children: [
        /* @__PURE__ */ jsx(Tag, { variant: "success", children: "success" }),
        /* @__PURE__ */ jsx(Tag, { mv: "medium", variant: "informative", children: "informative" }),
        /* @__PURE__ */ jsx(Tag, { variant: "attention", children: "attention" })
      ] })
    );
    expect(container).toMatchSnapshot();
  });
  it("should match snapshot with variant prop and informative type with margin prop", () => {
    const { container } = render(
      /* @__PURE__ */ jsxs(ThemeProvider, { children: [
        /* @__PURE__ */ jsx(Tag.Informative, { variant: "success", children: "success" }),
        /* @__PURE__ */ jsx(Tag.Informative, { mv: "medium", variant: "informative", children: "informative" }),
        /* @__PURE__ */ jsx(Tag.Informative, { variant: "attention", children: "attention" })
      ] })
    );
    expect(container).toMatchSnapshot();
  });
  it("should match snapshot with ellipsis prop", () => {
    const { container } = render(
      /* @__PURE__ */ jsx(ThemeProvider, { children: /* @__PURE__ */ jsx(Tag, { maxWidth: "10px", ellipsis: true, children: "Default with ellipsis" }) })
    );
    expect(container).toMatchSnapshot();
  });
  it("should match snapshot with variant, informative type and ellipsis prop", () => {
    const { container } = render(
      /* @__PURE__ */ jsxs(ThemeProvider, { children: [
        /* @__PURE__ */ jsx(Tag.Informative, { variant: "success", maxWidth: "10px", ellipsis: true, children: "Success with ellipsis" }),
        /* @__PURE__ */ jsx(Tag.Informative, { variant: "attention", maxWidth: "10px", ellipsis: true, children: "Attention with ellipsis" }),
        /* @__PURE__ */ jsx(Tag.Informative, { variant: "informative", maxWidth: "10px", ellipsis: true, children: "Informative with ellipsis" })
      ] })
    );
    expect(container).toMatchSnapshot();
  });
});
