@uva-glass/component-library 3.1.1 → 3.2.1
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/assets/FeedbackBar.css +1 -1
- package/dist/assets/StatusBage.css +1 -0
- package/dist/components/Accordion/Accordion.test.js +2 -2
- package/dist/components/AccordionCard/AccordionCard.test.js +2 -2
- package/dist/components/ActionList/ActionList.test.js +2 -2
- package/dist/components/AppStatusBar/AppStatusBar.test.js +1 -1
- package/dist/components/Attention/Attention.test.js +1 -1
- package/dist/components/Backdrop/Backdrop.test.js +1 -1
- package/dist/components/Buttons/Button.stories.js +1 -1
- package/dist/components/Buttons/Button.test.js +1 -1
- package/dist/components/Buttons/LinkButton.stories.js +1 -1
- package/dist/components/Buttons/LinkButton.test.js +1 -1
- package/dist/components/Buttons/MenuButton.stories.js +1 -1
- package/dist/components/Buttons/MenuButton.test.js +1 -1
- package/dist/components/Card/Card.test.js +1 -1
- package/dist/components/Checkbox/Checkbox.stories.js +1 -1
- package/dist/components/Checkbox/Checkbox.test.js +1 -1
- package/dist/components/CheckboxButton/CheckboxButton.stories.js +1 -1
- package/dist/components/CheckboxButton/CheckboxButton.test.js +1 -1
- package/dist/components/CheckboxButton/CheckboxButton.test.js.map +1 -1
- package/dist/components/CheckboxButtonBar/CheckboxButtonBar.stories.js +1 -1
- package/dist/components/CheckboxButtonBar/CheckboxButtonBar.test.js +1 -1
- package/dist/components/CheckboxButtonBar/CheckboxButtonBar.test.js.map +1 -1
- package/dist/components/CheckboxTree/CheckboxTree.stories.js +1 -1
- package/dist/components/Chip/Chip.stories.js +1 -1
- package/dist/components/Drawer/Drawer.stories.js +1 -1
- package/dist/components/FeedbackBar/FeedbackBar.js +17 -17
- package/dist/components/FeedbackBar/FeedbackBar.test.js +1 -1
- package/dist/components/FormInput/FormInput.stories.js +1 -1
- package/dist/components/IconButton/IconButton.stories.js +1 -1
- package/dist/components/InputField/InputField.stories.js +1 -1
- package/dist/components/Label/Label.test.js +1 -1
- package/dist/components/ModalDialog/ModalDialog.stories.js +1 -1
- package/dist/components/MultiSelect/MultiSelect.stories.js +1 -1
- package/dist/components/OverlayCloseButton/OverlayCloseButton.stories.js +1 -1
- package/dist/components/PeriodSelector/PeriodSelector.stories.js +1 -1
- package/dist/components/ProgrammeCard/ProgrammeCard.stories.js +1 -1
- package/dist/components/RteEditor/Plugins/PasteHandlerPlugin/PasteHandlerPlugin.js.map +1 -1
- package/dist/components/SelectListbox/SelectListBox.stories.js +1 -1
- package/dist/components/Sortable/Sortable.stories.js +1 -1
- package/dist/components/StatusBadge/StatusBadge.stories.d.ts +5 -0
- package/dist/components/StatusBadge/StatusBadge.stories.js +21 -0
- package/dist/components/StatusBadge/StatusBadge.stories.js.map +1 -0
- package/dist/components/StatusBadge/StatusBadge.test.d.ts +0 -0
- package/dist/components/StatusBadge/StatusBadge.test.js +12 -0
- package/dist/components/StatusBadge/StatusBadge.test.js.map +1 -0
- package/dist/components/StatusBadge/StatusBage.d.ts +7 -0
- package/dist/components/StatusBadge/StatusBage.js +10 -0
- package/dist/components/StatusBadge/StatusBage.js.map +1 -0
- package/dist/components/StatusBadge/index.d.ts +1 -0
- package/dist/components/StatusBadge/index.js +5 -0
- package/dist/components/StatusBadge/index.js.map +1 -0
- package/dist/components/Timeline/Timeline.test.js +1 -1
- package/dist/components/ToggleSwitch/ToggleSwitch.stories.js +1 -1
- package/dist/components/VarIndicator/VarIndicator.stories.js +1 -1
- package/dist/components/VarIndicator/VarIndicator.test.js +2 -2
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.js +20 -18
- package/dist/components/index.js.map +1 -1
- package/dist/{index-DMVXQIB9.js → index-COab4Oy9.js} +2 -2
- package/dist/{index-DMVXQIB9.js.map → index-COab4Oy9.js.map} +1 -1
- package/dist/{index-C7jFUWYs.js → index-DXR-TB1d.js} +2155 -2135
- package/dist/index-DXR-TB1d.js.map +1 -0
- package/dist/index.js +20 -18
- package/dist/index.js.map +1 -1
- package/dist/{react.esm-BOUd0cvD.js → react.esm-B8teOYlo.js} +2 -2
- package/dist/{react.esm-BOUd0cvD.js.map → react.esm-B8teOYlo.js.map} +1 -1
- package/dist/storybook__react.d.js +641 -637
- package/dist/storybook__react.d.js.map +1 -1
- package/dist/{test-utils-uaSbIYda.js → test-utils-Brqoydie.js} +279 -259
- package/dist/{test-utils-uaSbIYda.js.map → test-utils-Brqoydie.js.map} +1 -1
- package/package.json +19 -19
- package/dist/index-C7jFUWYs.js.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
._feedback-
|
|
1
|
+
._feedback-bar_aoc1x_1{background-color:var(--color-green-50);border:1px solid var(--color-green-500);border-radius:.5rem;display:flex;font-weight:var(--semibold);gap:.5rem;justify-content:space-between;max-height:0;opacity:0;padding:0 1rem;transition:all .5s}._feedback-bar--visible_aoc1x_15{max-height:6.625rem;opacity:1;padding:1rem}._feedback-bar__icon_aoc1x_21{color:var(--color-green-500)}._feedback-bar__close-button_aoc1x_25{align-items:center;background-color:transparent;border:1px solid transparent;border-radius:.25rem;color:var(--color-black);display:inline-flex;height:1.5rem;justify-content:center;transition:var(--transition-colors);width:1.5rem}._feedback-bar__close-button_aoc1x_25:focus-visible{outline:.125rem dotted var(--color-cobalt);outline-offset:.125rem}._feedback-bar__close-button_aoc1x_25:hover{background-color:var(--color-green-100);cursor:pointer;outline:0}._feedback-bar__close-button_aoc1x_25:after{content:" ";height:2.625rem;position:absolute;width:2.625rem}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
._statusbadge_6tmbw_1{align-items:center;background-color:var(--color-ghost-white);color:var(--color-grey-500);display:flex;font-family:inherit;font-size:var(--font-size-text-non-essential);height:1.5rem;padding:0 .5rem;white-space:nowrap;width:fit-content}._statusbadge--high-contrast_6tmbw_14{background-color:var(--color-white)}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as o } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-Z7qwJmRM.js";
|
|
3
|
-
import { r as n, s as a } from "../../react.esm-
|
|
4
|
-
import { u as e } from "../../index-
|
|
3
|
+
import { r as n, s as a } from "../../react.esm-B8teOYlo.js";
|
|
4
|
+
import { u as e } from "../../index-COab4Oy9.js";
|
|
5
5
|
import { Accordion as i } from "./Accordion.js";
|
|
6
6
|
describe("Accordion", () => {
|
|
7
7
|
it("should render", () => {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as n } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-Z7qwJmRM.js";
|
|
3
|
-
import { r as c, s as e, f as s, w as d } from "../../react.esm-
|
|
4
|
-
import { u as r } from "../../index-
|
|
3
|
+
import { r as c, s as e, f as s, w as d } from "../../react.esm-B8teOYlo.js";
|
|
4
|
+
import { u as r } from "../../index-COab4Oy9.js";
|
|
5
5
|
import { AccordionCard as a } from "./AccordionCard.js";
|
|
6
6
|
describe("AccordionCard", () => {
|
|
7
7
|
it("should render", () => {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as i } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-Z7qwJmRM.js";
|
|
3
|
-
import { r as n, s as t, w as a } from "../../react.esm-
|
|
4
|
-
import { u as l } from "../../index-
|
|
3
|
+
import { r as n, s as t, w as a } from "../../react.esm-B8teOYlo.js";
|
|
4
|
+
import { u as l } from "../../index-COab4Oy9.js";
|
|
5
5
|
import { ActionList as o } from "./ActionList.js";
|
|
6
6
|
const T = jest.fn(), c = [
|
|
7
7
|
/* @__PURE__ */ i("button", { type: "button", onClick: T, children: "Test Action 1" }, "1"),
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-Z7qwJmRM.js";
|
|
3
|
-
import { r, s as t } from "../../react.esm-
|
|
3
|
+
import { r, s as t } from "../../react.esm-B8teOYlo.js";
|
|
4
4
|
import { AppStatusBar as s } from "./AppStatusBar.js";
|
|
5
5
|
describe("AppStatusBar", () => {
|
|
6
6
|
it("should render", () => {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-Z7qwJmRM.js";
|
|
3
|
-
import { r as t, s as r } from "../../react.esm-
|
|
3
|
+
import { r as t, s as r } from "../../react.esm-B8teOYlo.js";
|
|
4
4
|
import { Attention as n } from "./Attention.js";
|
|
5
5
|
describe("Attention", () => {
|
|
6
6
|
it("should render (variant primary)", () => {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as r } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-Z7qwJmRM.js";
|
|
3
|
-
import { r as e, s as o } from "../../react.esm-
|
|
3
|
+
import { r as e, s as o } from "../../react.esm-B8teOYlo.js";
|
|
4
4
|
import { Backdrop as t } from "./Backdrop.js";
|
|
5
5
|
describe("Backdrop", () => {
|
|
6
6
|
it("should render", () => {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as t, jsxs as a, Fragment as s } from "react/jsx-runtime";
|
|
2
|
-
import { fn as l } from "../../index-
|
|
2
|
+
import { fn as l } from "../../index-DXR-TB1d.js";
|
|
3
3
|
import { Button as n } from "./Button.js";
|
|
4
4
|
const c = "<Button variant={variant} onClick={onClictFunction}>{children}</Button>", h = {
|
|
5
5
|
title: "Atoms/Buttons/Button",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-Z7qwJmRM.js";
|
|
3
|
-
import { r as n, s as t, f as c } from "../../react.esm-
|
|
3
|
+
import { r as n, s as t, f as c } from "../../react.esm-B8teOYlo.js";
|
|
4
4
|
import { Button as o } from "./Button.js";
|
|
5
5
|
const s = jest.fn();
|
|
6
6
|
describe("Button", () => {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as t, jsxs as a, Fragment as l } from "react/jsx-runtime";
|
|
2
|
-
import { fn as s } from "../../index-
|
|
2
|
+
import { fn as s } from "../../index-DXR-TB1d.js";
|
|
3
3
|
import { BrowserRouter as c } from "react-router";
|
|
4
4
|
import { LinkButton as n } from "./LinkButton.js";
|
|
5
5
|
const d = `
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsxs as s, jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-Z7qwJmRM.js";
|
|
3
|
-
import { r as n, s as t, f as c } from "../../react.esm-
|
|
3
|
+
import { r as n, s as t, f as c } from "../../react.esm-B8teOYlo.js";
|
|
4
4
|
import { BrowserRouter as u, Routes as a, Route as d } from "react-router";
|
|
5
5
|
import { LinkButton as o } from "./LinkButton.js";
|
|
6
6
|
const r = ({ children: i }) => /* @__PURE__ */ s(u, { children: [
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as n, jsxs as s, Fragment as l } from "react/jsx-runtime";
|
|
2
|
-
import { fn as c } from "../../index-
|
|
2
|
+
import { fn as c } from "../../index-DXR-TB1d.js";
|
|
3
3
|
import { MenuButton as t } from "./MenuButton.js";
|
|
4
4
|
const d = `
|
|
5
5
|
// Has all LabelHTMLAttributes props available except "className" and "style"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as o } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-Z7qwJmRM.js";
|
|
3
|
-
import { r as u, s as e, f as c } from "../../react.esm-
|
|
3
|
+
import { r as u, s as e, f as c } from "../../react.esm-B8teOYlo.js";
|
|
4
4
|
import { createRef as s } from "react";
|
|
5
5
|
import { MenuButton as r } from "./MenuButton.js";
|
|
6
6
|
const n = jest.fn();
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-Z7qwJmRM.js";
|
|
3
|
-
import { r, s as d } from "../../react.esm-
|
|
3
|
+
import { r, s as d } from "../../react.esm-B8teOYlo.js";
|
|
4
4
|
import { Card as o } from "./Card.js";
|
|
5
5
|
describe("Card", () => {
|
|
6
6
|
it("should render", () => {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsxs as g, jsx as o } from "react/jsx-runtime";
|
|
2
|
-
import { fn as e } from "../../index-
|
|
2
|
+
import { fn as e } from "../../index-DXR-TB1d.js";
|
|
3
3
|
import { Checkbox as n } from "./Checkbox.js";
|
|
4
4
|
import { FormField as t } from "../FormField/FormField.js";
|
|
5
5
|
import { Label as i } from "../Label/Label.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as c } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-Z7qwJmRM.js";
|
|
3
|
-
import { r as o, s as t } from "../../react.esm-
|
|
3
|
+
import { r as o, s as t } from "../../react.esm-B8teOYlo.js";
|
|
4
4
|
import { Checkbox as h } from "./Checkbox.js";
|
|
5
5
|
describe("Checkbox", () => {
|
|
6
6
|
it("should render", () => {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
-
import { fn as n } from "../../index-
|
|
2
|
+
import { fn as n } from "../../index-DXR-TB1d.js";
|
|
3
3
|
import { CheckboxButton as o } from "./CheckboxButton.js";
|
|
4
4
|
const a = "<CheckboxButton label={} value={} isChecked={} variant={} disabled={} notValid={} onSetValue={} key={} />", b = {
|
|
5
5
|
title: "Atoms/CheckboxButton",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as l } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-Z7qwJmRM.js";
|
|
3
|
-
import { r as n, s as t } from "../../react.esm-
|
|
3
|
+
import { r as n, s as t } from "../../react.esm-B8teOYlo.js";
|
|
4
4
|
import { CheckboxButton as a } from "./CheckboxButton.js";
|
|
5
5
|
const c = jest.fn();
|
|
6
6
|
describe("CheckboxButton", () => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CheckboxButton.test.js","sources":["../../../src/components/CheckboxButton/CheckboxButton.test.tsx"],"sourcesContent":["import '@testing-library/jest-dom';\
|
|
1
|
+
{"version":3,"file":"CheckboxButton.test.js","sources":["../../../src/components/CheckboxButton/CheckboxButton.test.tsx"],"sourcesContent":["import '@testing-library/jest-dom';\nimport { render, screen } from '@testing-library/react';\n\nimport { CheckboxButton } from './CheckboxButton';\n\nconst onClickSpy = jest.fn();\n\ndescribe('CheckboxButton', () => {\n it('should render', () => {\n render(<CheckboxButton label=\"2.1\" value=\"4\" onSetValue={onClickSpy} />);\n const checkbox = screen.getByRole('checkbox');\n expect(checkbox).toBeInTheDocument();\n });\n\n it('should be checked if clicked', () => {\n render(<CheckboxButton label=\"2.1\" value=\"4\" onSetValue={onClickSpy} />);\n const checkbox = screen.getByRole('checkbox');\n expect(checkbox).toBeInTheDocument();\n checkbox.click();\n expect(checkbox).toBeChecked();\n expect(onClickSpy).toHaveBeenCalledTimes(1);\n });\n\n it('should be disabled', () => {\n render(<CheckboxButton label=\"2.1\" value=\"4\" onSetValue={onClickSpy} disabled={true} />);\n const checkbox = screen.getByRole('checkbox');\n expect(checkbox).toBeInTheDocument();\n expect(checkbox).toBeDisabled();\n });\n\n it('should show noValid', () => {\n render(<CheckboxButton label=\"2.1\" value=\"4\" onSetValue={onClickSpy} notValid={true} />);\n const checkbox = screen.getByRole('checkbox');\n expect(checkbox).toBeInTheDocument();\n const label = screen.getByText('2.1');\n expect(label).toHaveClass('checkbox-button--not-valid');\n });\n\n it('should render single variant', () => {\n render(<CheckboxButton label=\"2.1\" value=\"4\" onSetValue={onClickSpy} notValid={true} />);\n const checkbox = screen.getByRole('checkbox');\n expect(checkbox).toBeInTheDocument();\n const label = screen.getByText('2.1');\n expect(label).toHaveClass('checkbox-button--single');\n });\n\n it('should render start variant', () => {\n render(<CheckboxButton label=\"2.1\" value=\"4\" onSetValue={onClickSpy} notValid={true} variant=\"start\" />);\n const checkbox = screen.getByRole('checkbox');\n expect(checkbox).toBeInTheDocument();\n const label = screen.getByText('2.1');\n expect(label).toHaveClass('checkbox-button--start');\n });\n\n it('should render middle variant', () => {\n render(<CheckboxButton label=\"2.1\" value=\"4\" onSetValue={onClickSpy} notValid={true} variant=\"middle\" />);\n const checkbox = screen.getByRole('checkbox');\n expect(checkbox).toBeInTheDocument();\n const label = screen.getByText('2.1');\n expect(label).toHaveClass('checkbox-button--middle');\n });\n\n it('should render end variant', () => {\n render(<CheckboxButton label=\"2.1\" value=\"4\" onSetValue={onClickSpy} notValid={true} variant=\"end\" />);\n const checkbox = screen.getByRole('checkbox');\n expect(checkbox).toBeInTheDocument();\n const label = screen.getByText('2.1');\n expect(label).toHaveClass('checkbox-button--end');\n });\n});\n"],"names":["onClickSpy","render","jsx","CheckboxButton","checkbox","screen","label"],"mappings":"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"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as t } from "react/jsx-runtime";
|
|
2
|
-
import { fn as l } from "../../index-
|
|
2
|
+
import { fn as l } from "../../index-DXR-TB1d.js";
|
|
3
3
|
import { CheckboxButtonBar as e } from "./CheckboxButtonBar.js";
|
|
4
4
|
const a = "<CheckboxButtonBar checkboxes={} defaultValues={} label={} labelPosition={} required={} notValidatedText={} disableGroup={} onSetValues={} />", i = {
|
|
5
5
|
title: "Molecules/CheckboxButtonBar",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as l } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-Z7qwJmRM.js";
|
|
3
|
-
import { r as c, s as e } from "../../react.esm-
|
|
3
|
+
import { r as c, s as e } from "../../react.esm-B8teOYlo.js";
|
|
4
4
|
import { CheckboxButtonBar as a } from "./CheckboxButtonBar.js";
|
|
5
5
|
const n = jest.fn(), x = [
|
|
6
6
|
{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CheckboxButtonBar.test.js","sources":["../../../src/components/CheckboxButtonBar/CheckboxButtonBar.test.tsx"],"sourcesContent":["/* eslint-disable @typescript-eslint/no-magic-numbers */\
|
|
1
|
+
{"version":3,"file":"CheckboxButtonBar.test.js","sources":["../../../src/components/CheckboxButtonBar/CheckboxButtonBar.test.tsx"],"sourcesContent":["/* eslint-disable @typescript-eslint/no-magic-numbers */\nimport '@testing-library/jest-dom';\nimport { render, screen } from '@testing-library/react';\n\nimport { CheckboxButtonBar } from './CheckboxButtonBar';\n\nconst onClickSpy = jest.fn();\n\nconst MOCK_CHECKBOXES = [\n {\n label: '1.1',\n value: '1',\n },\n {\n label: '1.2',\n value: '2',\n },\n {\n label: '1.3',\n value: '3',\n },\n];\n\ndescribe('CheckboxButton', () => {\n it('should render', () => {\n render(\n <CheckboxButtonBar\n label=\"Periode\"\n checkboxes={MOCK_CHECKBOXES}\n defaultValues={['1', '2']}\n labelPosition=\"top\"\n onSetValues={onClickSpy}\n />\n );\n expect(screen.getByText('Periode')).toBeInTheDocument();\n const checkbox = screen.getAllByRole('checkbox');\n expect(checkbox).toHaveLength(3);\n });\n\n it('should render required', () => {\n render(\n <CheckboxButtonBar\n label=\"Periode\"\n required={true}\n checkboxes={MOCK_CHECKBOXES}\n defaultValues={['1', '2']}\n labelPosition=\"top\"\n onSetValues={onClickSpy}\n />\n );\n const label = screen.getByText('Periode');\n expect(label).toHaveTextContent('Periode');\n expect(label).toHaveClass('label--required');\n const checkbox = screen.getAllByRole('checkbox');\n expect(checkbox).toHaveLength(3);\n });\n\n it('should render default checked', () => {\n render(\n <CheckboxButtonBar\n label=\"Periode\"\n checkboxes={MOCK_CHECKBOXES}\n defaultValues={['1', '2']}\n labelPosition=\"top\"\n onSetValues={onClickSpy}\n />\n );\n const label = screen.getByText('Periode');\n expect(label).toHaveTextContent('Periode');\n const checkbox = screen.getAllByRole('checkbox');\n expect(checkbox).toHaveLength(3);\n expect(checkbox[0]).toBeChecked();\n expect(checkbox[1]).toBeChecked();\n expect(checkbox[2]).not.toBeChecked();\n });\n\n it('should render notValidatedText and notValid style', () => {\n render(\n <CheckboxButtonBar\n label=\"Periode\"\n notValidatedText=\"Not Valid\"\n checkboxes={MOCK_CHECKBOXES}\n defaultValues={['1', '2']}\n labelPosition=\"top\"\n onSetValues={onClickSpy}\n />\n );\n const label = screen.getByText('Periode');\n expect(label).toHaveTextContent('Periode');\n expect(screen.getByText('Not Valid')).toBeInTheDocument();\n const checkbox = screen.getAllByRole('checkbox');\n expect(checkbox).toHaveLength(3);\n expect(screen.getByText('1.1')).toHaveClass('checkbox-button--not-valid');\n expect(screen.getByText('1.2')).toHaveClass('checkbox-button--not-valid');\n expect(screen.getByText('1.3')).toHaveClass('checkbox-button--not-valid');\n });\n});\n"],"names":["onClickSpy","MOCK_CHECKBOXES","render","jsx","CheckboxButtonBar","screen","checkbox","label"],"mappings":";;;;AAMA,MAAMA,IAAa,KAAK,GAAG,GAErBC,IAAkB;AAAA,EACtB;AAAA,IACE,OAAO;AAAA,IACP,OAAO;AAAA,EACT;AAAA,EACA;AAAA,IACE,OAAO;AAAA,IACP,OAAO;AAAA,EACT;AAAA,EACA;AAAA,IACE,OAAO;AAAA,IACP,OAAO;AAAA,EAAA;AAEX;AAEA,SAAS,kBAAkB,MAAM;AAC/B,KAAG,iBAAiB,MAAM;AACxB,IAAAC;AAAA,MACE,gBAAAC;AAAA,QAACC;AAAA,QAAA;AAAA,UACC,OAAM;AAAA,UACN,YAAYH;AAAA,UACZ,eAAe,CAAC,KAAK,GAAG;AAAA,UACxB,eAAc;AAAA,UACd,aAAaD;AAAA,QAAA;AAAA,MAAA;AAAA,IAEjB,GACA,OAAOK,EAAO,UAAU,SAAS,CAAC,EAAE,kBAAkB;AAChD,UAAAC,IAAWD,EAAO,aAAa,UAAU;AACxC,WAAAC,CAAQ,EAAE,aAAa,CAAC;AAAA,EAAA,CAChC,GAED,GAAG,0BAA0B,MAAM;AACjC,IAAAJ;AAAA,MACE,gBAAAC;AAAA,QAACC;AAAA,QAAA;AAAA,UACC,OAAM;AAAA,UACN,UAAU;AAAA,UACV,YAAYH;AAAA,UACZ,eAAe,CAAC,KAAK,GAAG;AAAA,UACxB,eAAc;AAAA,UACd,aAAaD;AAAA,QAAA;AAAA,MAAA;AAAA,IAEjB;AACM,UAAAO,IAAQF,EAAO,UAAU,SAAS;AACjC,WAAAE,CAAK,EAAE,kBAAkB,SAAS,GAClC,OAAAA,CAAK,EAAE,YAAY,iBAAiB;AACrC,UAAAD,IAAWD,EAAO,aAAa,UAAU;AACxC,WAAAC,CAAQ,EAAE,aAAa,CAAC;AAAA,EAAA,CAChC,GAED,GAAG,iCAAiC,MAAM;AACxC,IAAAJ;AAAA,MACE,gBAAAC;AAAA,QAACC;AAAA,QAAA;AAAA,UACC,OAAM;AAAA,UACN,YAAYH;AAAA,UACZ,eAAe,CAAC,KAAK,GAAG;AAAA,UACxB,eAAc;AAAA,UACd,aAAaD;AAAA,QAAA;AAAA,MAAA;AAAA,IAEjB;AACM,UAAAO,IAAQF,EAAO,UAAU,SAAS;AACjC,WAAAE,CAAK,EAAE,kBAAkB,SAAS;AACnC,UAAAD,IAAWD,EAAO,aAAa,UAAU;AACxC,WAAAC,CAAQ,EAAE,aAAa,CAAC,GAC/B,OAAOA,EAAS,CAAC,CAAC,EAAE,YAAY,GAChC,OAAOA,EAAS,CAAC,CAAC,EAAE,YAAY,GAChC,OAAOA,EAAS,CAAC,CAAC,EAAE,IAAI,YAAY;AAAA,EAAA,CACrC,GAED,GAAG,qDAAqD,MAAM;AAC5D,IAAAJ;AAAA,MACE,gBAAAC;AAAA,QAACC;AAAA,QAAA;AAAA,UACC,OAAM;AAAA,UACN,kBAAiB;AAAA,UACjB,YAAYH;AAAA,UACZ,eAAe,CAAC,KAAK,GAAG;AAAA,UACxB,eAAc;AAAA,UACd,aAAaD;AAAA,QAAA;AAAA,MAAA;AAAA,IAEjB;AACM,UAAAO,IAAQF,EAAO,UAAU,SAAS;AACjC,WAAAE,CAAK,EAAE,kBAAkB,SAAS,GACzC,OAAOF,EAAO,UAAU,WAAW,CAAC,EAAE,kBAAkB;AAClD,UAAAC,IAAWD,EAAO,aAAa,UAAU;AACxC,WAAAC,CAAQ,EAAE,aAAa,CAAC,GAC/B,OAAOD,EAAO,UAAU,KAAK,CAAC,EAAE,YAAY,4BAA4B,GACxE,OAAOA,EAAO,UAAU,KAAK,CAAC,EAAE,YAAY,4BAA4B,GACxE,OAAOA,EAAO,UAAU,KAAK,CAAC,EAAE,YAAY,4BAA4B;AAAA,EAAA,CACzE;AACH,CAAC;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _, jsxs as A } from "react/jsx-runtime";
|
|
2
|
-
import { fn as w } from "../../index-
|
|
2
|
+
import { fn as w } from "../../index-DXR-TB1d.js";
|
|
3
3
|
import { s as g, j as V, V as j } from "../../index-DH9Vbk37.js";
|
|
4
4
|
import { useState as D } from "react";
|
|
5
5
|
import { CheckboxTree as O } from "./CheckboxTree.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as l } from "react/jsx-runtime";
|
|
2
|
-
import { fn as t } from "../../index-
|
|
2
|
+
import { fn as t } from "../../index-DXR-TB1d.js";
|
|
3
3
|
import { Chip as e } from "./Chip.js";
|
|
4
4
|
const s = "<Chip label={string} onDelete={onDeleteFunction(label)}/>", b = {
|
|
5
5
|
title: "Atoms/Chip",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsxs as a, jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import { OverlayProvider as p } from "@react-aria/overlays";
|
|
3
|
-
import { fn as m } from "../../index-
|
|
3
|
+
import { fn as m } from "../../index-DXR-TB1d.js";
|
|
4
4
|
import { useState as c } from "react";
|
|
5
5
|
import { Drawer as r } from "./Drawer.js";
|
|
6
6
|
import { Button as o } from "../Buttons/Button.js";
|
|
@@ -1,30 +1,30 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { c
|
|
1
|
+
import { jsxs as r, jsx as a } from "react/jsx-runtime";
|
|
2
|
+
import { c } from "../../clsx-OuTLNxxd.js";
|
|
3
3
|
import { useState as l, useEffect as _ } from "react";
|
|
4
|
-
import { Icon as
|
|
4
|
+
import { Icon as s } from "../Icon/Icon.js";
|
|
5
5
|
import { Repeater as f } from "../Repeater/Repeater.js";
|
|
6
6
|
import '../../assets/FeedbackBar.css';const e = {
|
|
7
|
-
"feedback-bar": "_feedback-
|
|
8
|
-
"feedback-bar--visible": "_feedback-bar--
|
|
9
|
-
"feedback-bar__icon": "_feedback-
|
|
10
|
-
"feedback-bar__close-button": "_feedback-bar__close-
|
|
11
|
-
},
|
|
12
|
-
const [t,
|
|
7
|
+
"feedback-bar": "_feedback-bar_aoc1x_1",
|
|
8
|
+
"feedback-bar--visible": "_feedback-bar--visible_aoc1x_15",
|
|
9
|
+
"feedback-bar__icon": "_feedback-bar__icon_aoc1x_21",
|
|
10
|
+
"feedback-bar__close-button": "_feedback-bar__close-button_aoc1x_25"
|
|
11
|
+
}, x = ({ children: b }) => {
|
|
12
|
+
const [t, o] = l(!1);
|
|
13
13
|
_(() => {
|
|
14
|
-
|
|
14
|
+
o(!0);
|
|
15
15
|
}, []);
|
|
16
16
|
const i = () => {
|
|
17
|
-
|
|
17
|
+
o(!1);
|
|
18
18
|
};
|
|
19
|
-
return /* @__PURE__ */
|
|
20
|
-
/* @__PURE__ */
|
|
21
|
-
/* @__PURE__ */
|
|
22
|
-
|
|
19
|
+
return /* @__PURE__ */ r("div", { className: c(e["feedback-bar"], { [e["feedback-bar--visible"]]: t }), role: "alert", children: [
|
|
20
|
+
/* @__PURE__ */ r(f, { flexDirection: "row", children: [
|
|
21
|
+
/* @__PURE__ */ a(s, { className: c(e["feedback-bar__icon"]), name: "CheckCircle" }),
|
|
22
|
+
b
|
|
23
23
|
] }),
|
|
24
|
-
/* @__PURE__ */
|
|
24
|
+
/* @__PURE__ */ a("button", { className: c(e["feedback-bar__close-button"]), type: "button", onClick: i, children: /* @__PURE__ */ a(s, { name: "Cross", size: 24 }) })
|
|
25
25
|
] });
|
|
26
26
|
};
|
|
27
27
|
export {
|
|
28
|
-
|
|
28
|
+
x as FeedbackBar
|
|
29
29
|
};
|
|
30
30
|
//# sourceMappingURL=FeedbackBar.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as t } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-Z7qwJmRM.js";
|
|
3
|
-
import { r as s, s as e, f as r } from "../../react.esm-
|
|
3
|
+
import { r as s, s as e, f as r } from "../../react.esm-B8teOYlo.js";
|
|
4
4
|
import { FeedbackBar as c } from "./FeedbackBar.js";
|
|
5
5
|
describe("FeedbackBar", () => {
|
|
6
6
|
it("should render with children text", () => {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as t } from "react/jsx-runtime";
|
|
2
|
-
import { fn as i } from "../../index-
|
|
2
|
+
import { fn as i } from "../../index-DXR-TB1d.js";
|
|
3
3
|
import { FormInput as a } from "./FormInput.js";
|
|
4
4
|
import { SelectListbox as o } from "../SelectListbox/SelectListbox.js";
|
|
5
5
|
const m = `
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as n } from "react/jsx-runtime";
|
|
2
|
-
import { fn as r } from "../../index-
|
|
2
|
+
import { fn as r } from "../../index-DXR-TB1d.js";
|
|
3
3
|
import { IconButton as t } from "./IconButton.js";
|
|
4
4
|
import { Icon as i } from "../Icon/Icon.js";
|
|
5
5
|
const l = `<IconButton variant={variant} aria-label={aria-label} onClick={onClickFunction}>
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import { useState as d, useRef as g } from "react";
|
|
3
|
-
import { fn as p } from "../../index-
|
|
3
|
+
import { fn as p } from "../../index-DXR-TB1d.js";
|
|
4
4
|
import { InputField as o } from "./InputField.js";
|
|
5
5
|
import { Container as u } from "../../storyComponents/Container/Container.js";
|
|
6
6
|
import { Icon as f } from "../Icon/Icon.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-Z7qwJmRM.js";
|
|
3
|
-
import { r as t, s as l } from "../../react.esm-
|
|
3
|
+
import { r as t, s as l } from "../../react.esm-B8teOYlo.js";
|
|
4
4
|
import { Label as r } from "./Label.js";
|
|
5
5
|
describe("Label", () => {
|
|
6
6
|
it("should render", () => {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsxs as a, jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import { ModalProvider as l } from "@react-aria/overlays";
|
|
3
|
-
import { fn as i } from "../../index-
|
|
3
|
+
import { fn as i } from "../../index-DXR-TB1d.js";
|
|
4
4
|
import { ModalDialog as t } from "./ModalDialog.js";
|
|
5
5
|
import { Button as n } from "../Buttons/Button.js";
|
|
6
6
|
import "../Buttons/LinkButton.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsxs as S, jsx as r } from "react/jsx-runtime";
|
|
2
|
-
import { fn as d } from "../../index-
|
|
2
|
+
import { fn as d } from "../../index-DXR-TB1d.js";
|
|
3
3
|
import { useState as p } from "react";
|
|
4
4
|
import { M as e } from "../../TablePlugin-DKzssVbg.js";
|
|
5
5
|
import { Container as M } from "../../storyComponents/Container/Container.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
-
import { fn as a } from "../../index-
|
|
2
|
+
import { fn as a } from "../../index-DXR-TB1d.js";
|
|
3
3
|
import { OverlayCloseButton as o } from "./OverlayCloseButton.js";
|
|
4
4
|
import { Container as l } from "../../storyComponents/Container/Container.js";
|
|
5
5
|
const n = "<OverlayCloseButton aria-label={aria-label} onClick={onClickFunction} />", c = {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as r } from "react/jsx-runtime";
|
|
2
|
-
import { fn as t } from "../../index-
|
|
2
|
+
import { fn as t } from "../../index-DXR-TB1d.js";
|
|
3
3
|
import { PeriodSelector as e } from "./PeriodSelector.js";
|
|
4
4
|
const i = "<PeriodSelector maxPeriods={} defaultValues={} label={} labelPosition={} required={} onChange={} />", m = {
|
|
5
5
|
title: "Organisms/PeriodSelector",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as r, jsxs as e } from "react/jsx-runtime";
|
|
2
|
-
import { fn as a } from "../../index-
|
|
2
|
+
import { fn as a } from "../../index-DXR-TB1d.js";
|
|
3
3
|
import { ProgrammeCard as o } from "./ProgrammeCard.js";
|
|
4
4
|
import { Container as n } from "../../storyComponents/Container/Container.js";
|
|
5
5
|
import "react";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PasteHandlerPlugin.js","sources":["../../../../../src/components/RteEditor/Plugins/PasteHandlerPlugin/PasteHandlerPlugin.tsx"],"sourcesContent":["import { useLexicalComposerContext } from '@lexical/react/LexicalComposerContext';\nimport { useEffect } from 'react';\nimport { $getSelection, COMMAND_PRIORITY_CRITICAL, type CommandPayloadType, PASTE_COMMAND } from 'lexical';\nimport { objectKlassEquals } from '@lexical/utils';\nimport { $insertDataTransferForRichText } from '@lexical/clipboard';\nimport { MSWordNormalizer } from '@staartwind.nl/lexical-paste-from-word';\n\nexport const PasteHandlerPlugin = () => {\n const [editor] = useLexicalComposerContext();\n\n const handlePaste = (event: CommandPayloadType<typeof PASTE_COMMAND>) => {\n event.preventDefault();\n editor.update(() => {\n const selection = $getSelection();\n const clipboardData =\n objectKlassEquals(event, InputEvent) || objectKlassEquals(event, KeyboardEvent)
|
|
1
|
+
{"version":3,"file":"PasteHandlerPlugin.js","sources":["../../../../../src/components/RteEditor/Plugins/PasteHandlerPlugin/PasteHandlerPlugin.tsx"],"sourcesContent":["import { useLexicalComposerContext } from '@lexical/react/LexicalComposerContext';\nimport { useEffect } from 'react';\nimport { $getSelection, COMMAND_PRIORITY_CRITICAL, type CommandPayloadType, PASTE_COMMAND } from 'lexical';\nimport { objectKlassEquals } from '@lexical/utils';\nimport { $insertDataTransferForRichText } from '@lexical/clipboard';\nimport { MSWordNormalizer } from '@staartwind.nl/lexical-paste-from-word';\n\nexport const PasteHandlerPlugin = () => {\n const [editor] = useLexicalComposerContext();\n\n const handlePaste = (event: CommandPayloadType<typeof PASTE_COMMAND>) => {\n event.preventDefault();\n editor.update(() => {\n const selection = $getSelection();\n const clipboardData =\n objectKlassEquals(event, InputEvent) || objectKlassEquals(event, KeyboardEvent) ? null : event.clipboardData;\n if (clipboardData != null && selection !== null) {\n const html = clipboardData.getData('text/html');\n const newData = new DataTransfer();\n const wordNormalizer = new MSWordNormalizer();\n newData.setData('text/html', html);\n if (wordNormalizer.isActive(html)) {\n newData.setData('text/html', wordNormalizer.normalize(html));\n }\n $insertDataTransferForRichText(newData, selection, editor);\n }\n });\n };\n\n useEffect(() => {\n const removePasteListener = editor.registerCommand(\n PASTE_COMMAND,\n (event) => {\n if (event instanceof ClipboardEvent) {\n handlePaste(event);\n return true;\n }\n return false;\n },\n COMMAND_PRIORITY_CRITICAL\n );\n\n return () => {\n removePasteListener();\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [editor]);\n\n return null;\n};\n"],"names":["PasteHandlerPlugin","editor","useLexicalComposerContext","handlePaste","event","selection","$getSelection","clipboardData","objectKlassEquals","html","newData","wordNormalizer","MSWordNormalizer","$insertDataTransferForRichText","useEffect","removePasteListener","PASTE_COMMAND","COMMAND_PRIORITY_CRITICAL"],"mappings":";;;;;;AAOO,MAAMA,IAAqB,MAAM;AAChC,QAAA,CAACC,CAAM,IAAIC,EAA0B,GAErCC,IAAc,CAACC,MAAoD;AACvE,IAAAA,EAAM,eAAe,GACrBH,EAAO,OAAO,MAAM;AAClB,YAAMI,IAAYC,EAAc,GAC1BC,IACJC,EAAkBJ,GAAO,UAAU,KAAKI,EAAkBJ,GAAO,aAAa,IAAI,OAAOA,EAAM;AAC7F,UAAAG,KAAiB,QAAQF,MAAc,MAAM;AACzC,cAAAI,IAAOF,EAAc,QAAQ,WAAW,GACxCG,IAAU,IAAI,aAAa,GAC3BC,IAAiB,IAAIC,mBAAiB;AACpC,QAAAF,EAAA,QAAQ,aAAaD,CAAI,GAC7BE,EAAe,SAASF,CAAI,KAC9BC,EAAQ,QAAQ,aAAaC,EAAe,UAAUF,CAAI,CAAC,GAE9BI,EAAAH,GAASL,GAAWJ,CAAM;AAAA,MAAA;AAAA,IAC3D,CACD;AAAA,EACH;AAEA,SAAAa,EAAU,MAAM;AACd,UAAMC,IAAsBd,EAAO;AAAA,MACjCe;AAAAA,MACA,CAACZ,MACKA,aAAiB,kBACnBD,EAAYC,CAAK,GACV,MAEF;AAAA,MAETa;AAAAA,IACF;AAEA,WAAO,MAAM;AACS,MAAAF,EAAA;AAAA,IACtB;AAAA,EAAA,GAEC,CAACd,CAAM,CAAC,GAEJ;AACT;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as e, jsxs as m, Fragment as i } from "react/jsx-runtime";
|
|
2
|
-
import { fn as s } from "../../index-
|
|
2
|
+
import { fn as s } from "../../index-DXR-TB1d.js";
|
|
3
3
|
import { Sortable as o } from "./Sortable.js";
|
|
4
4
|
import { InputField as c } from "../InputField/InputField.js";
|
|
5
5
|
import { Icon as d } from "../Icon/Icon.js";
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { Meta } from '@storybook/react';
|
|
2
|
+
import { StatusBadgeProps } from 'components/StatusBadge';
|
|
3
|
+
declare const _default: Meta<StatusBadgeProps>;
|
|
4
|
+
export default _default;
|
|
5
|
+
export declare const StatusBadgeExample: import('@storybook/core/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, StatusBadgeProps>;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { jsx as a } from "react/jsx-runtime";
|
|
2
|
+
import { StatusBadge as t } from "./StatusBage.js";
|
|
3
|
+
const o = "<InfoBadge highContrast=[boolean]>{label}</InfoBadge>", d = {
|
|
4
|
+
title: "Atoms/StatusBadge",
|
|
5
|
+
component: t,
|
|
6
|
+
parameters: {
|
|
7
|
+
inspectComponent: t,
|
|
8
|
+
codeString: o
|
|
9
|
+
}
|
|
10
|
+
}, s = (e) => /* @__PURE__ */ a(t, { ...e }), n = {
|
|
11
|
+
label: "This is example badge",
|
|
12
|
+
highContrast: !1
|
|
13
|
+
}, r = s.bind({});
|
|
14
|
+
r.args = {
|
|
15
|
+
...n
|
|
16
|
+
};
|
|
17
|
+
export {
|
|
18
|
+
r as StatusBadgeExample,
|
|
19
|
+
d as default
|
|
20
|
+
};
|
|
21
|
+
//# sourceMappingURL=StatusBadge.stories.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"StatusBadge.stories.js","sources":["../../../src/components/StatusBadge/StatusBadge.stories.tsx"],"sourcesContent":["import type { Meta, StoryFn } from '@storybook/react';\nimport type { StatusBadgeProps } from 'components/StatusBadge';\n\nimport { StatusBadge } from 'components/StatusBadge';\n\nconst codeString = '<InfoBadge highContrast=[boolean]>{label}</InfoBadge>';\n\n// eslint-disable-next-line import/no-default-export\nexport default {\n title: 'Atoms/StatusBadge',\n component: StatusBadge,\n parameters: {\n inspectComponent: StatusBadge,\n codeString: codeString,\n },\n} as Meta<StatusBadgeProps>;\n\nconst Template: StoryFn<StatusBadgeProps> = (args) => <StatusBadge {...args} />;\n\nconst defaultArgs: StatusBadgeProps = {\n label: 'This is example badge',\n highContrast: false,\n};\n\nexport const StatusBadgeExample = Template.bind({});\n\nStatusBadgeExample.args = {\n ...defaultArgs,\n};\n"],"names":["codeString","StatusBadge_stories","StatusBadge","Template","args","jsx","defaultArgs","StatusBadgeExample"],"mappings":";;AAKA,MAAMA,IAAa,yDAGJC,IAAA;AAAA,EACb,OAAO;AAAA,EACP,WAAWC;AAAA,EACX,YAAY;AAAA,IACV,kBAAkBA;AAAA,IAClB,YAAAF;AAAA,EAAA;AAEJ,GAEMG,IAAsC,CAACC,MAAU,gBAAAC,EAAAH,GAAA,EAAa,GAAGE,GAAM,GAEvEE,IAAgC;AAAA,EACpC,OAAO;AAAA,EACP,cAAc;AAChB,GAEaC,IAAqBJ,EAAS,KAAK,CAAE,CAAA;AAElDI,EAAmB,OAAO;AAAA,EACxB,GAAGD;AACL;"}
|
|
File without changes
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import "../../index-Z7qwJmRM.js";
|
|
3
|
+
import { r as t, s } from "../../react.esm-B8teOYlo.js";
|
|
4
|
+
import { StatusBadge as a } from "./StatusBage.js";
|
|
5
|
+
describe("StatusBadge", () => {
|
|
6
|
+
it("should render with message", () => {
|
|
7
|
+
t(/* @__PURE__ */ e(a, { label: "Status message" })), expect(s.getByText("Status message")).toBeInTheDocument();
|
|
8
|
+
}), it("should render with highContract", () => {
|
|
9
|
+
t(/* @__PURE__ */ e(a, { label: "Status message", highContrast: !0 })), expect(s.getByText("Status message")).toHaveClass("statusbadge--high-contrast");
|
|
10
|
+
});
|
|
11
|
+
});
|
|
12
|
+
//# sourceMappingURL=StatusBadge.test.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"StatusBadge.test.js","sources":["../../../src/components/StatusBadge/StatusBadge.test.tsx"],"sourcesContent":["import '@testing-library/jest-dom';\nimport { render, screen } from '@testing-library/react';\n\nimport { StatusBadge } from './StatusBage';\n\ndescribe('StatusBadge', () => {\n it('should render with message', () => {\n render(<StatusBadge label=\"Status message\" />);\n expect(screen.getByText('Status message')).toBeInTheDocument();\n });\n\n it('should render with highContract', () => {\n render(<StatusBadge label=\"Status message\" highContrast={true} />);\n expect(screen.getByText('Status message')).toHaveClass('statusbadge--high-contrast');\n });\n});\n"],"names":["render","jsx","StatusBadge","screen"],"mappings":";;;;AAKA,SAAS,eAAe,MAAM;AAC5B,KAAG,8BAA8B,MAAM;AACrC,IAAAA,EAAQ,gBAAAC,EAAAC,GAAA,EAAY,OAAM,iBAAiB,CAAA,CAAE,GAC7C,OAAOC,EAAO,UAAU,gBAAgB,CAAC,EAAE,kBAAkB;AAAA,EAAA,CAC9D,GAED,GAAG,mCAAmC,MAAM;AAC1C,IAAAH,oBAAQE,GAAY,EAAA,OAAM,kBAAiB,cAAc,IAAM,CAAE,GACjE,OAAOC,EAAO,UAAU,gBAAgB,CAAC,EAAE,YAAY,4BAA4B;AAAA,EAAA,CACpF;AACH,CAAC;"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export interface StatusBadgeProps {
|
|
2
|
+
/** Text on the badge */
|
|
3
|
+
label: string;
|
|
4
|
+
/** true to render the card with high contrast colors; otherwise, false. The default is false. */
|
|
5
|
+
highContrast?: boolean;
|
|
6
|
+
}
|
|
7
|
+
export declare const StatusBadge: ({ label, highContrast }: StatusBadgeProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import { c as g } from "../../clsx-OuTLNxxd.js";
|
|
3
|
+
import '../../assets/StatusBage.css';const o = "_statusbadge_6tmbw_1", t = {
|
|
4
|
+
statusbadge: o,
|
|
5
|
+
"statusbadge--high-contrast": "_statusbadge--high-contrast_6tmbw_14"
|
|
6
|
+
}, d = ({ label: s, highContrast: a = !1 }) => /* @__PURE__ */ e("div", { className: g(t.statusbadge, [a && t["statusbadge--high-contrast"]]), children: s });
|
|
7
|
+
export {
|
|
8
|
+
d as StatusBadge
|
|
9
|
+
};
|
|
10
|
+
//# sourceMappingURL=StatusBage.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"StatusBage.js","sources":["../../../src/components/StatusBadge/StatusBage.tsx"],"sourcesContent":["import clsx from 'clsx';\n\nimport styles from './StatusBadge.module.css';\n\nexport interface StatusBadgeProps {\n /** Text on the badge */\n label: string;\n /** true to render the card with high contrast colors; otherwise, false. The default is false. */\n highContrast?: boolean;\n}\n\nexport const StatusBadge = ({ label, highContrast = false }: StatusBadgeProps) => {\n return (\n <div className={clsx(styles['statusbadge'], [highContrast && styles['statusbadge--high-contrast']])}>{label}</div>\n );\n};\n"],"names":["StatusBadge","label","highContrast","jsx","clsx","styles"],"mappings":";;;;;GAWaA,IAAc,CAAC,EAAE,OAAAC,GAAO,cAAAC,IAAe,SAE/C,gBAAAC,EAAA,OAAA,EAAI,WAAWC,EAAKC,EAAO,aAAgB,CAACH,KAAgBG,EAAO,4BAA4B,CAAC,CAAC,GAAI,UAAMJ,GAAA;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './StatusBage';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as o } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-Z7qwJmRM.js";
|
|
3
|
-
import { r as n, s as e, f as i } from "../../react.esm-
|
|
3
|
+
import { r as n, s as e, f as i } from "../../react.esm-B8teOYlo.js";
|
|
4
4
|
import { MOCK_TIMELINE_ITEM as r } from "./mockTimelineItem.js";
|
|
5
5
|
import "react";
|
|
6
6
|
import "../Buttons/Button.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
-
import { fn as l } from "../../index-
|
|
2
|
+
import { fn as l } from "../../index-DXR-TB1d.js";
|
|
3
3
|
import { ToggleSwitch as e } from "./ToggleSwitch.js";
|
|
4
4
|
const n = `
|
|
5
5
|
// Has all InputHTMLAttributes props available except "className" and "style"
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as t } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-Z7qwJmRM.js";
|
|
3
|
-
import { r as l, s as e, w as a } from "../../react.esm-
|
|
4
|
-
import { u as i } from "../../index-
|
|
3
|
+
import { r as l, s as e, w as a } from "../../react.esm-B8teOYlo.js";
|
|
4
|
+
import { u as i } from "../../index-COab4Oy9.js";
|
|
5
5
|
import { useState as s } from "react";
|
|
6
6
|
import { VarIndicator as n } from "./VarIndicator.js";
|
|
7
7
|
const o = {
|
|
@@ -46,6 +46,7 @@ export * from './SelectListbox';
|
|
|
46
46
|
export * from './SelectListbox/SelectProvider';
|
|
47
47
|
export * from './Sortable';
|
|
48
48
|
export * from './Spinner';
|
|
49
|
+
export * from './StatusBadge';
|
|
49
50
|
export * from './StatusPill';
|
|
50
51
|
export * from './Timeline';
|
|
51
52
|
export * from './ToggleSwitch';
|