@pismo/marola 2.1.2 → 2.1.4

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 (31) hide show
  1. package/dist/Group-DJz1rK2n.js +39 -0
  2. package/dist/{Toggle-DeMSbC0N.js → Toggle-Dp20f7qn.js} +1 -1
  3. package/dist/assets/Group.css +1 -1
  4. package/dist/assets/TransactionRow.css +1 -1
  5. package/dist/components/Chip/Chip.js +2 -2
  6. package/dist/components/Chip/Chip.stories.d.ts +1 -1
  7. package/dist/components/ConfirmationDialog/ConfirmationDialog.stories.d.ts +1 -1
  8. package/dist/components/DatePicker/DatePicker.stories.d.ts +1 -1
  9. package/dist/components/Dialog/Dialog.stories.d.ts +1 -1
  10. package/dist/components/EllipsisTooltip/EllipsisTooltip.stories.d.ts +1 -1
  11. package/dist/components/LoadingSpinner/LoadingSpinner.stories.d.ts +1 -1
  12. package/dist/components/Popover/Popover.stories.d.ts +1 -1
  13. package/dist/components/RadioButton/RadioButton.js +2 -2
  14. package/dist/components/RadioButton/RadioOption.js +2 -2
  15. package/dist/components/ResultWithChips/ResultWithChips.js +1 -1
  16. package/dist/components/RowItem/RowItem.js +2 -2
  17. package/dist/components/Snackbar/Snackbar.stories.d.ts +1 -1
  18. package/dist/components/ToggleGroup/Group.js +1 -1
  19. package/dist/components/ToggleGroup/Toggle.d.ts +1 -1
  20. package/dist/components/ToggleGroup/Toggle.js +2 -2
  21. package/dist/components/ToggleGroup/ToggleGroup.js +2 -2
  22. package/dist/components/ToggleGroup/ToggleGroup.stories.d.ts +2 -1
  23. package/dist/components/Tooltip/Tooltip.stories.d.ts +1 -1
  24. package/dist/components/TransactionRow/TransactionRow.d.ts +4 -1
  25. package/dist/components/TransactionRow/TransactionRow.js +41 -36
  26. package/dist/components/TransactionRow/TransactionRow.stories.d.ts +7 -1
  27. package/dist/components/Typography/Typography.stories.d.ts +1 -1
  28. package/dist/contexts/SnackbarProvider/SnackbarProvider.stories.d.ts +1 -1
  29. package/dist/main.js +2 -2
  30. package/package.json +1 -1
  31. package/dist/Group-Cyc1W1kV.js +0 -39
@@ -0,0 +1,39 @@
1
+ import { jsxs as g, jsx as o } from "react/jsx-runtime";
2
+ import { forwardRef as n } from "react";
3
+ import { c } from "./clsx-OuTLNxxd.js";
4
+ import { Icon as p } from "./components/Icon/Icon.js";
5
+ import { Typography as m } from "./components/Typography/Typography.js";
6
+ import './assets/Group.css';const u = "_toggle__input_1jlyx_1", x = "_toggle__label_1jlyx_11", t = {
7
+ toggle__input: u,
8
+ toggle__label: x,
9
+ "toggle__label--selected": "_toggle__label--selected_1jlyx_24",
10
+ "toggle__label--disabled": "_toggle__label--disabled_1jlyx_24",
11
+ "toggle-group__fieldset": "_toggle-group__fieldset_1jlyx_38",
12
+ "toggle-group__options": "_toggle-group__options_1jlyx_43",
13
+ "toggle-group__options-same-width": "_toggle-group__options-same-width_1jlyx_47",
14
+ "toggle-group__error": "_toggle-group__error_1jlyx_50"
15
+ }, w = n((e, r) => {
16
+ const { children: s, legend: l, error: _, equalWidth: a } = e, i = e["data-testid"] ? `${e["data-testid"]}-legend` : void 0, d = e["data-testid"] ? `${e["data-testid"]}-error` : void 0;
17
+ return /* @__PURE__ */ g("fieldset", { ref: r, "data-testid": e["data-testid"], className: t["toggle-group__fieldset"], children: [
18
+ l && /* @__PURE__ */ o("legend", { "data-testid": i, children: l }),
19
+ /* @__PURE__ */ o(
20
+ "div",
21
+ {
22
+ className: c(
23
+ t["toggle-group__options"],
24
+ a && t["toggle-group__options-same-width"],
25
+ e.classNameForOptions
26
+ ),
27
+ children: s
28
+ }
29
+ ),
30
+ _ && /* @__PURE__ */ g(m, { className: t["toggle-group__error"], "data-testid": d, children: [
31
+ /* @__PURE__ */ o(p, { icon: "circle-exclamation" }),
32
+ _
33
+ ] })
34
+ ] });
35
+ });
36
+ export {
37
+ w as G,
38
+ t as s
39
+ };
@@ -16,7 +16,7 @@ import "./components/Select/Select.js";
16
16
  import "./components/Popover/Popover.js";
17
17
  import "./components/Table/Table.js";
18
18
  import "./components/Tabs/Tabs.js";
19
- import { s as y } from "./Group-Cyc1W1kV.js";
19
+ import { s as y } from "./Group-DJz1rK2n.js";
20
20
  import "./contexts/SnackbarProvider/SnackbarProvider.js";
21
21
  import { B as x } from "./Button-Bh6rpTyY.js";
22
22
  import './assets/Toggle2.css';const I = "_chip_1wvod_61", P = "_chip__adornment_1wvod_116", z = "_chip__remove_1wvod_121", n = {
@@ -1 +1 @@
1
- ._toggle__input_1fdw4_1{position:absolute;top:0;left:0;width:100%;height:100%;margin:0;visibility:hidden;opacity:0}._toggle__label_1fdw4_11{position:relative;flex-grow:1;padding:.5rem 1rem;color:var(--accent);text-align:center;cursor:pointer;background-color:rgb(var(--accent-rgb),.1);border-radius:6px}._toggle__label_1fdw4_11:hover:not(._toggle__label--selected_1fdw4_21,._toggle__label--disabled_1fdw4_21){border-color:var(--gray-75);opacity:.9}._toggle__label--selected_1fdw4_21{color:var(--white-100);background-color:var(--accent)}._toggle__label--disabled_1fdw4_21{color:rgb(var(--black-100-rgb),.25);cursor:default;background-color:rgb(var(--black-100-rgb),.04)}._toggle-group__fieldset_1fdw4_35{padding:0;margin:0;border:none}._toggle-group__options_1fdw4_40{display:flex;gap:.5rem}._toggle-group__options-same-width_1fdw4_44>*{flex:1}._toggle-group__error_1fdw4_47{display:flex;gap:.375rem;align-items:center;margin-top:.3125rem;color:var(--alert)}._toggle-group__error_1fdw4_47 svg{min-width:1rem;min-height:1rem}
1
+ ._toggle__input_1jlyx_1{position:absolute;top:0;left:0;width:100%;height:100%;margin:0;visibility:hidden;opacity:0}._toggle__label_1jlyx_11{position:relative;display:flex;flex-grow:1;align-items:center;justify-content:center;padding:.5rem 1rem;color:var(--gray-90);text-align:center;cursor:pointer;border:solid 1px var(--gray-25);border-radius:6px}._toggle__label_1jlyx_11:hover:not(._toggle__label--selected_1jlyx_24,._toggle__label--disabled_1jlyx_24){border-color:var(--gray-75);opacity:.9}._toggle__label--selected_1jlyx_24{color:var(--accent);border-color:var(--accent)}._toggle__label--disabled_1jlyx_24{color:rgb(var(--black-100-rgb),.25);cursor:default;background-color:rgb(var(--black-100-rgb),.04)}._toggle-group__fieldset_1jlyx_38{padding:0;margin:0;border:none}._toggle-group__options_1jlyx_43{display:flex;gap:.5rem}._toggle-group__options-same-width_1jlyx_47>*{flex:1}._toggle-group__error_1jlyx_50{display:flex;gap:.375rem;align-items:center;margin-top:.3125rem;color:var(--alert)}._toggle-group__error_1jlyx_50 svg{min-width:1rem;min-height:1rem}
@@ -1 +1 @@
1
- ._container_1zn5j_1{width:100%;height:56px;border-top:1px solid var(--border-secondary)}._container-grid_1zn5j_6{display:grid;grid-template-columns:1fr 2fr .5fr 4fr 2fr 2fr;align-items:center;justify-content:space-between;padding:12px 16px}._container-pending_1zn5j_13{display:flex;align-items:center;justify-content:flex-start;padding:12px 16px}._container-pending--right_1zn5j_19{margin-left:auto}._container_1zn5j_1 :hover{background-color:var(--border-secondary)}._info-section_1zn5j_26{display:flex}._info-section--item_1zn5j_29{padding-left:8px}._info-section--item_1zn5j_29:not(:first-child){margin-left:8px;border-left:1px solid var(--border-secondary)}._info-section--right_1zn5j_36{display:flex;justify-content:flex-end}
1
+ ._container_1apn3_1{width:100%;height:56px;border-top:1px solid var(--border-secondary)}._container-grid_1apn3_6{display:grid;grid-template-columns:1fr 2fr .5fr 4fr 2fr 2fr;align-items:center;justify-content:space-between;padding:12px 16px}._container-pending_1apn3_13{display:flex;align-items:center;justify-content:flex-start;padding:12px 16px}._container-pending--right_1apn3_19{margin-left:auto}._container_1apn3_1 :hover{cursor:pointer;background-color:var(--border-secondary)}._info-section_1apn3_27{display:flex}._info-section--item_1apn3_30{padding-left:8px}._info-section--item_1apn3_30:not(:first-child){margin-left:8px;border-left:1px solid var(--border-secondary)}._info-section--right_1apn3_37{display:flex;justify-content:flex-end}
@@ -7,7 +7,7 @@ import "../Typography/Typography.js";
7
7
  import "../Input/Input.js";
8
8
  import "../Avatar/Avatar.js";
9
9
  import "../Button/Button.js";
10
- import { C as v } from "../../Toggle-DeMSbC0N.js";
10
+ import { C as v } from "../../Toggle-Dp20f7qn.js";
11
11
  import "../Dialog/Dialog.js";
12
12
  import "../DatePicker/DatePicker.js";
13
13
  import "../Skeleton/Skeleton.js";
@@ -17,7 +17,7 @@ import "../Select/Select.js";
17
17
  import "../Popover/Popover.js";
18
18
  import "../Table/Table.js";
19
19
  import "../Tabs/Tabs.js";
20
- import "../../Group-Cyc1W1kV.js";
20
+ import "../../Group-DJz1rK2n.js";
21
21
  import "../../contexts/SnackbarProvider/SnackbarProvider.js";
22
22
  import "../../Button-Bh6rpTyY.js";
23
23
  export {
@@ -3,7 +3,7 @@ declare const meta: {
3
3
  title: string;
4
4
  component: import('react').ForwardRefExoticComponent<import('./Chip').ChipProps & import('react').RefAttributes<unknown>>;
5
5
  tags: string[];
6
- decorators: ((Story: import('@storybook/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
6
+ decorators: ((Story: import('@storybook/core/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
7
7
  label: import('react').ReactNode;
8
8
  loading?: boolean | undefined;
9
9
  leftAdornment?: import('../Adornment/Adornment').AdornmentProps | undefined;
@@ -4,7 +4,7 @@ declare const meta: {
4
4
  title: string;
5
5
  component: ({ open, onClose, title, subtitle, content, cancelAction, confirmAction, confirmLabel, cancelLabel, }: ConfirmationDialogProps) => import("react/jsx-runtime").JSX.Element;
6
6
  tags: string[];
7
- decorators: ((Story: import('@storybook/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
7
+ decorators: ((Story: import('@storybook/core/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
8
8
  open: boolean;
9
9
  onClose: () => void;
10
10
  title?: import('react').ReactNode;
@@ -17,7 +17,7 @@ declare const meta: {
17
17
  navigatorInput?: boolean | undefined;
18
18
  }>;
19
19
  tags: string[];
20
- decorators: ((Story: import('@storybook/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
20
+ decorators: ((Story: import('@storybook/core/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
21
21
  mode: "range" | "single";
22
22
  viewMode: "month" | "day" | "year";
23
23
  locale?: string | undefined;
@@ -13,7 +13,7 @@ declare const meta: {
13
13
  Actions: import('react').FunctionComponent<import('./Actions').DialogActionProps>;
14
14
  };
15
15
  tags: string[];
16
- decorators: ((Story: import('@storybook/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
16
+ decorators: ((Story: import('@storybook/core/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
17
17
  color?: string | undefined;
18
18
  children: import('react').ReactElement<any, string | import('react').JSXElementConstructor<any>> & import('react').ReactElement<unknown, string | import('react').JSXElementConstructor<unknown>>;
19
19
  title?: string | undefined;
@@ -7,7 +7,7 @@ declare const meta: {
7
7
  parameters: {
8
8
  layout: string;
9
9
  };
10
- decorators: ((Story: import('@storybook/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
10
+ decorators: ((Story: import('@storybook/core/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
11
11
  children: import('react').ReactNode;
12
12
  title?: import('react').ReactNode;
13
13
  style?: import('react').CSSProperties | undefined;
@@ -3,7 +3,7 @@ declare const meta: {
3
3
  title: string;
4
4
  component: ({ invert, classNames }: import('./LoadingSpinner').LoadingSpinnerProps) => import("react/jsx-runtime").JSX.Element;
5
5
  tags: string[];
6
- decorators: ((Story: import('@storybook/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
6
+ decorators: ((Story: import('@storybook/core/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
7
7
  invert?: boolean | undefined;
8
8
  classNames?: string | undefined;
9
9
  }>) => import("react/jsx-runtime").JSX.Element)[];
@@ -24,7 +24,7 @@ declare const meta: {
24
24
  };
25
25
  };
26
26
  tags: string[];
27
- decorators: ((Story: import('@storybook/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
27
+ decorators: ((Story: import('@storybook/core/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
28
28
  [x: string]: any;
29
29
  }>) => import("react/jsx-runtime").JSX.Element)[];
30
30
  };
@@ -7,7 +7,7 @@ import { Typography as Me } from "../Typography/Typography.js";
7
7
  import "../Input/Input.js";
8
8
  import "../Avatar/Avatar.js";
9
9
  import "../Button/Button.js";
10
- import "../../Toggle-DeMSbC0N.js";
10
+ import "../../Toggle-Dp20f7qn.js";
11
11
  import "../Dialog/Dialog.js";
12
12
  import "../DatePicker/DatePicker.js";
13
13
  import "../IconButton/IconButton.js";
@@ -16,7 +16,7 @@ import "../Select/Select.js";
16
16
  import "../Popover/Popover.js";
17
17
  import "../Table/Table.js";
18
18
  import "../Tabs/Tabs.js";
19
- import "../../Group-Cyc1W1kV.js";
19
+ import "../../Group-DJz1rK2n.js";
20
20
  import "../../contexts/SnackbarProvider/SnackbarProvider.js";
21
21
  import { u as ne, C as Te, e as Y, b as oe, m as G, D as xe, c as _e, g as Ae, h as ce, j as Pe, r as ke, R as ve, i as He, s as P } from "../../RadioButton.module-VF7v9SuY.js";
22
22
  import { P as d } from "../../useSlotProps-C7dqSmdM.js";
@@ -6,7 +6,7 @@ import * as a from "react";
6
6
  import "../Input/Input.js";
7
7
  import "../Avatar/Avatar.js";
8
8
  import "../Button/Button.js";
9
- import "../../Toggle-DeMSbC0N.js";
9
+ import "../../Toggle-Dp20f7qn.js";
10
10
  import "../Dialog/Dialog.js";
11
11
  import "../DatePicker/DatePicker.js";
12
12
  import "../IconButton/IconButton.js";
@@ -16,7 +16,7 @@ import "../Popover/Popover.js";
16
16
  import { u as v, a as j, b as E, c as U, d as w, e as F, m as I, f as q, g as V, h as M, r as z, i as J, N as Q, s as N } from "../../RadioButton.module-VF7v9SuY.js";
17
17
  import "../Table/Table.js";
18
18
  import "../Tabs/Tabs.js";
19
- import "../../Group-Cyc1W1kV.js";
19
+ import "../../Group-DJz1rK2n.js";
20
20
  import "../../contexts/SnackbarProvider/SnackbarProvider.js";
21
21
  import { P as s } from "../../useSlotProps-C7dqSmdM.js";
22
22
  import { r as W } from "../../index-Bppuplgd.js";
@@ -1,5 +1,5 @@
1
1
  import { jsxs as i, jsx as e } from "react/jsx-runtime";
2
- import { C as t } from "../../Toggle-DeMSbC0N.js";
2
+ import { C as t } from "../../Toggle-Dp20f7qn.js";
3
3
  import '../../assets/ResultWithChips.css';const r = "_container_hgp0p_1", o = "_label_hgp0p_17", a = {
4
4
  container: r,
5
5
  "chip-item-wrapper": "_chip-item-wrapper_hgp0p_8",
@@ -7,7 +7,7 @@ import "../Typography/Typography.js";
7
7
  import "../Input/Input.js";
8
8
  import "../Avatar/Avatar.js";
9
9
  import "../Button/Button.js";
10
- import { R as j, R as k } from "../../Toggle-DeMSbC0N.js";
10
+ import { R as j, R as k } from "../../Toggle-Dp20f7qn.js";
11
11
  import "../Dialog/Dialog.js";
12
12
  import "../DatePicker/DatePicker.js";
13
13
  import "../IconButton/IconButton.js";
@@ -16,7 +16,7 @@ import "../Select/Select.js";
16
16
  import "../Popover/Popover.js";
17
17
  import "../Table/Table.js";
18
18
  import "../Tabs/Tabs.js";
19
- import "../../Group-Cyc1W1kV.js";
19
+ import "../../Group-DJz1rK2n.js";
20
20
  import "../../contexts/SnackbarProvider/SnackbarProvider.js";
21
21
  export {
22
22
  j as RowItem,
@@ -4,7 +4,7 @@ declare const meta: {
4
4
  title: string;
5
5
  component: ({ snackbarMessage, variant, autoHideDuration, open, onClose, onClosed, classNameWrapper, "data-testid": dataTestId, }: SnackbarProps) => import("react/jsx-runtime").JSX.Element;
6
6
  tags: string[];
7
- decorators: ((Story: import('@storybook/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
7
+ decorators: ((Story: import('@storybook/core/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
8
8
  accept?: string | undefined;
9
9
  alt?: string | undefined;
10
10
  autoComplete?: import('react').HTMLInputAutoCompleteAttribute | undefined;
@@ -3,7 +3,7 @@ import "react";
3
3
  import "../../clsx-OuTLNxxd.js";
4
4
  import "../Icon/Icon.js";
5
5
  import "../Typography/Typography.js";
6
- import { G as e } from "../../Group-Cyc1W1kV.js";
6
+ import { G as e } from "../../Group-DJz1rK2n.js";
7
7
  export {
8
8
  e as default
9
9
  };
@@ -1,7 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  export type ToggleGroupItemProps<T extends string | number> = {
3
3
  /** The display text to show for this option */
4
- text: string;
4
+ text: React.ReactNode;
5
5
  /** The underlining value of this option */
6
6
  value: T;
7
7
  /** Whether this radio button is selected */
@@ -6,7 +6,7 @@ import "../Typography/Typography.js";
6
6
  import "../Input/Input.js";
7
7
  import "../Avatar/Avatar.js";
8
8
  import "../Button/Button.js";
9
- import { T as k } from "../../Toggle-DeMSbC0N.js";
9
+ import { T as k } from "../../Toggle-Dp20f7qn.js";
10
10
  import "../Dialog/Dialog.js";
11
11
  import "../DatePicker/DatePicker.js";
12
12
  import "../IconButton/IconButton.js";
@@ -15,7 +15,7 @@ import "../Select/Select.js";
15
15
  import "../Popover/Popover.js";
16
16
  import "../Table/Table.js";
17
17
  import "../Tabs/Tabs.js";
18
- import "../../Group-Cyc1W1kV.js";
18
+ import "../../Group-DJz1rK2n.js";
19
19
  import "../../contexts/SnackbarProvider/SnackbarProvider.js";
20
20
  export {
21
21
  k as default
@@ -1,5 +1,5 @@
1
- import { T as e } from "../../Toggle-DeMSbC0N.js";
2
- import { G as p } from "../../Group-Cyc1W1kV.js";
1
+ import { T as e } from "../../Toggle-Dp20f7qn.js";
2
+ import { G as p } from "../../Group-DJz1rK2n.js";
3
3
  export {
4
4
  p as ToggleGroup,
5
5
  e as ToggleGroupItem
@@ -5,7 +5,7 @@ declare const meta: {
5
5
  title: string;
6
6
  component: import('react').ForwardRefExoticComponent<ToggleGroupProps & import('react').RefAttributes<HTMLFieldSetElement>>;
7
7
  tags: string[];
8
- decorators: ((Story: import('@storybook/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
8
+ decorators: ((Story: import('@storybook/core/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
9
9
  legend?: import('react').ReactNode;
10
10
  error?: import('react').ReactNode;
11
11
  children: import('react').ReactElement<import('./Toggle.tsx').ToggleGroupItemProps<string | number>, string | import('react').JSXElementConstructor<any>>[];
@@ -25,3 +25,4 @@ export declare const Simple: Story;
25
25
  export declare const NoLegend: Story;
26
26
  export declare const WithError: Story;
27
27
  export declare const ItemsWithEqualWidth: Story;
28
+ export declare const ItemsWithCustomText: Story;
@@ -7,7 +7,7 @@ declare const meta: {
7
7
  parameters: {
8
8
  layout: string;
9
9
  };
10
- decorators: ((Story: import('@storybook/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
10
+ decorators: ((Story: import('@storybook/core/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
11
11
  children: import('react').ReactNode;
12
12
  title?: import('react').ReactNode;
13
13
  content: import('react').ReactNode;
@@ -3,6 +3,7 @@ type TransactionRowProps = {
3
3
  dateTime?: React.ReactNode;
4
4
  month?: React.ReactNode;
5
5
  category?: React.ReactNode;
6
+ categoryType?: React.ReactNode;
6
7
  name: React.ReactNode;
7
8
  type?: React.ReactNode;
8
9
  icon?: IconName;
@@ -10,6 +11,8 @@ type TransactionRowProps = {
10
11
  installments?: React.ReactNode;
11
12
  onClick?: () => void;
12
13
  isPendingTransaction?: boolean;
14
+ isLoading?: boolean;
15
+ 'data-testid'?: string;
13
16
  };
14
- export declare const TransactionRow: ({ dateTime, category, name, type, installments, amount, month, icon, onClick, isPendingTransaction, }: TransactionRowProps) => import("react/jsx-runtime").JSX.Element;
17
+ export declare const TransactionRow: ({ dateTime, category, categoryType, name, type, installments, amount, month, icon, onClick, isPendingTransaction, isLoading, "data-testid": dataTestId, }: TransactionRowProps) => import("react/jsx-runtime").JSX.Element;
15
18
  export {};
@@ -1,43 +1,48 @@
1
- import { jsx as i, jsxs as a } from "react/jsx-runtime";
2
- import { Avatar as l } from "../Avatar/Avatar.js";
3
- import { Icon as h } from "../Icon/Icon.js";
4
- import { Typography as r } from "../Typography/Typography.js";
5
- import '../../assets/TransactionRow.css';const f = "_container_1zn5j_1", n = {
6
- container: f,
7
- "container-grid": "_container-grid_1zn5j_6",
8
- "container-pending": "_container-pending_1zn5j_13",
9
- "container-pending--right": "_container-pending--right_1zn5j_19",
10
- "info-section": "_info-section_1zn5j_26",
11
- "info-section--item": "_info-section--item_1zn5j_29",
12
- "info-section--right": "_info-section--right_1zn5j_36"
1
+ import { jsx as e, jsxs as c } from "react/jsx-runtime";
2
+ import { Avatar as p } from "../Avatar/Avatar.js";
3
+ import { Icon as y } from "../Icon/Icon.js";
4
+ import { SkeletonCircle as f, Skeleton as r } from "../Skeleton/Skeleton.js";
5
+ import { Typography as a } from "../Typography/Typography.js";
6
+ import '../../assets/TransactionRow.css';const $ = "_container_1apn3_1", i = {
7
+ container: $,
8
+ "container-grid": "_container-grid_1apn3_6",
9
+ "container-pending": "_container-pending_1apn3_13",
10
+ "container-pending--right": "_container-pending--right_1apn3_19",
11
+ "info-section": "_info-section_1apn3_27",
12
+ "info-section--item": "_info-section--item_1apn3_30",
13
+ "info-section--right": "_info-section--right_1apn3_37"
13
14
  }, j = ({
14
- dateTime: v,
15
- category: c,
16
- name: o,
17
- type: m,
18
- installments: t,
19
- amount: s,
15
+ dateTime: _,
16
+ category: s,
17
+ categoryType: l,
18
+ name: d,
19
+ type: N,
20
+ installments: h,
21
+ amount: v,
20
22
  month: g,
21
- icon: d,
22
- onClick: e,
23
- isPendingTransaction: _
24
- }) => _ ? /* @__PURE__ */ i("div", { className: n.container, children: /* @__PURE__ */ a("div", { className: n["container-pending"], onClick: () => e == null ? void 0 : e(), children: [
25
- /* @__PURE__ */ i(l, { type: "icon", children: /* @__PURE__ */ i(h, { icon: d || "clock" }) }),
26
- /* @__PURE__ */ i("div", { className: n["info-section"], children: /* @__PURE__ */ i("div", { className: n["info-section--item"], children: /* @__PURE__ */ i(r, { color: "var(--gray-95)", variant: "base", children: o }) }) }),
27
- /* @__PURE__ */ i("div", { className: n["container-pending--right"], children: /* @__PURE__ */ i(r, { bold: !0, color: "var(--gray-95)", variant: "base", children: s }) })
28
- ] }) }) : /* @__PURE__ */ i("div", { className: n.container, children: /* @__PURE__ */ a("div", { onClick: () => e == null ? void 0 : e(), className: n["container-grid"], children: [
29
- /* @__PURE__ */ i("div", { children: /* @__PURE__ */ i(r, { color: "var(--gray-95)", variant: "base", children: g }) }),
30
- /* @__PURE__ */ i("div", { children: /* @__PURE__ */ i(r, { color: "var(--gray-95)", variant: "base", children: v }) }),
31
- /* @__PURE__ */ i(l, { type: "icon", children: /* @__PURE__ */ i(h, { icon: d || "coin" }) }),
32
- /* @__PURE__ */ a("div", { className: n["info-section"], children: [
33
- /* @__PURE__ */ i("div", { className: n["info-section--item"], children: /* @__PURE__ */ i(r, { color: "var(--gray-95)", variant: "base", children: o }) }),
34
- c && /* @__PURE__ */ i("div", { className: n["info-section--item"], children: /* @__PURE__ */ i(r, { color: "var(--gray-95)", variant: "base", children: c }) })
23
+ icon: m,
24
+ onClick: o,
25
+ isPendingTransaction: b,
26
+ isLoading: n = !1,
27
+ "data-testid": t = "Description"
28
+ }) => b ? /* @__PURE__ */ e("div", { className: i.container, children: /* @__PURE__ */ c("div", { className: i["container-pending"], onClick: () => o == null ? void 0 : o(), children: [
29
+ n ? /* @__PURE__ */ e(f, { size: "32px", "data-testid": `${t}-skeletonIcon` }) : /* @__PURE__ */ e(p, { type: "icon", children: /* @__PURE__ */ e(y, { icon: m || "clock" }) }),
30
+ /* @__PURE__ */ e("div", { className: i["info-section"], children: /* @__PURE__ */ e("div", { className: i["info-section--item"], children: n ? /* @__PURE__ */ e(r, { style: { width: 140 }, "data-testid": `${t}-skeletonName` }) : /* @__PURE__ */ e(a, { color: "var(--gray-95)", variant: "base", children: d }) }) }),
31
+ /* @__PURE__ */ e("div", { className: i["container-pending--right"], children: n ? /* @__PURE__ */ e(r, { style: { width: 70 }, "data-testid": `${t}-skeletonAmount` }) : /* @__PURE__ */ e(a, { bold: !0, color: "var(--gray-95)", variant: "base", children: v }) })
32
+ ] }) }) : /* @__PURE__ */ e("div", { className: i.container, children: /* @__PURE__ */ c("div", { onClick: () => o == null ? void 0 : o(), className: i["container-grid"], children: [
33
+ /* @__PURE__ */ e("div", { children: n ? /* @__PURE__ */ e(r, { style: { width: 50 }, "data-testid": `${t}-skeletonMonth` }) : /* @__PURE__ */ e(a, { color: "var(--gray-95)", variant: "base", children: g }) }),
34
+ /* @__PURE__ */ e("div", { children: n ? /* @__PURE__ */ e(r, { style: { width: 90 }, "data-testid": `${t}-skeletonDate` }) : /* @__PURE__ */ e(a, { color: "var(--gray-95)", variant: "base", children: _ }) }),
35
+ n ? /* @__PURE__ */ e(f, { size: "32px", "data-testid": `${t}-skeletonIcon` }) : /* @__PURE__ */ e(p, { type: "icon", children: /* @__PURE__ */ e(y, { icon: m || "coin" }) }),
36
+ /* @__PURE__ */ c("div", { className: i["info-section"], children: [
37
+ /* @__PURE__ */ e("div", { className: i["info-section--item"], children: n ? /* @__PURE__ */ e(r, { style: { width: 70 }, "data-testid": `${t}-skeletonName` }) : /* @__PURE__ */ e(a, { color: "var(--gray-95)", variant: "base", children: d }) }),
38
+ s && /* @__PURE__ */ e("div", { className: i["info-section--item"], children: n ? /* @__PURE__ */ e(r, { style: { width: 70 }, "data-testid": `${t}-skeletonCategory` }) : /* @__PURE__ */ e(a, { color: "var(--gray-95)", variant: "base", children: s }) }),
39
+ l && /* @__PURE__ */ e("div", { className: i["info-section--item"], children: n ? /* @__PURE__ */ e(r, { style: { width: 70 }, "data-testid": `${t}-skeletonCategoryType` }) : /* @__PURE__ */ e(a, { color: "var(--gray-95)", variant: "base", children: l }) })
35
40
  ] }),
36
- /* @__PURE__ */ a("div", { className: n["info-section--right"], children: [
37
- t && /* @__PURE__ */ i("div", { className: n["info-section--item"], children: /* @__PURE__ */ i(r, { color: "var(--gray-95)", variant: "base", children: t }) }),
38
- /* @__PURE__ */ i("div", { className: n["info-section--item"], children: /* @__PURE__ */ i(r, { color: "var(--gray-95)", variant: "base", children: m }) })
41
+ /* @__PURE__ */ c("div", { className: i["info-section--right"], children: [
42
+ h && /* @__PURE__ */ e("div", { className: i["info-section--item"], children: n ? /* @__PURE__ */ e(r, { style: { width: 70 }, "data-testid": `${t}-skeletonInstallments` }) : /* @__PURE__ */ e(a, { color: "var(--gray-95)", variant: "base", children: h }) }),
43
+ /* @__PURE__ */ e("div", { className: i["info-section--item"], children: n ? /* @__PURE__ */ e(r, { style: { width: 70 }, "data-testid": `${t}-skeletonType` }) : /* @__PURE__ */ e(a, { color: "var(--gray-95)", variant: "base", children: N }) })
39
44
  ] }),
40
- /* @__PURE__ */ i("div", { className: n["info-section--right"], children: /* @__PURE__ */ i(r, { bold: !0, variant: "base", children: s }) })
45
+ /* @__PURE__ */ e("div", { className: i["info-section--right"], children: n ? /* @__PURE__ */ e(r, { style: { width: 140 }, "data-testid": `${t}-skeletonAmount` }) : /* @__PURE__ */ e(a, { bold: !0, variant: "base", children: v }) })
41
46
  ] }) });
42
47
  export {
43
48
  j as TransactionRow
@@ -1,10 +1,11 @@
1
1
  import { StoryObj } from '@storybook/react';
2
2
  declare const meta: {
3
3
  title: string;
4
- component: ({ dateTime, category, name, type, installments, amount, month, icon, onClick, isPendingTransaction, }: {
4
+ component: ({ dateTime, category, categoryType, name, type, installments, amount, month, icon, onClick, isPendingTransaction, isLoading, "data-testid": dataTestId, }: {
5
5
  dateTime?: import('react').ReactNode;
6
6
  month?: import('react').ReactNode;
7
7
  category?: import('react').ReactNode;
8
+ categoryType?: import('react').ReactNode;
8
9
  name: import('react').ReactNode;
9
10
  type?: import('react').ReactNode;
10
11
  icon?: import('../Icon/types').IconName | undefined;
@@ -12,6 +13,8 @@ declare const meta: {
12
13
  installments?: import('react').ReactNode;
13
14
  onClick?: (() => void) | undefined;
14
15
  isPendingTransaction?: boolean | undefined;
16
+ isLoading?: boolean | undefined;
17
+ 'data-testid'?: string | undefined;
15
18
  }) => import("react/jsx-runtime").JSX.Element;
16
19
  tags: string[];
17
20
  parameters: {
@@ -23,7 +26,10 @@ type Story = StoryObj<typeof meta>;
23
26
  export declare const Simple: Story;
24
27
  export declare const WithMonth: Story;
25
28
  export declare const WithInstallments: Story;
29
+ export declare const WithCategoryType: Story;
30
+ export declare const Loading: Story;
26
31
  export declare const WithoutCategory: Story;
27
32
  export declare const WithTwoCurrencies: Story;
28
33
  export declare const WithLargeAmount: Story;
29
34
  export declare const IsPending: Story;
35
+ export declare const IsPendingLoading: Story;
@@ -11,7 +11,7 @@ declare const meta: {
11
11
  };
12
12
  };
13
13
  };
14
- decorators: ((Story: import('@storybook/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
14
+ decorators: ((Story: import('@storybook/core/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
15
15
  children: import('react').ReactNode;
16
16
  element?: import('react').ElementType | undefined;
17
17
  variant?: import('./Typography').VariantType | undefined;
@@ -11,7 +11,7 @@ declare const meta: {
11
11
  };
12
12
  };
13
13
  tags: string[];
14
- decorators: ((Story: import('@storybook/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
14
+ decorators: ((Story: import('@storybook/core/csf').PartialStoryFn<import('@storybook/react').ReactRenderer, {
15
15
  [x: string]: any;
16
16
  }>) => import("react/jsx-runtime").JSX.Element)[];
17
17
  };
package/dist/main.js CHANGED
@@ -8,7 +8,7 @@ import { BankCard as g } from "./components/BankCard/BankCard.js";
8
8
  import { Button as u } from "./components/Button/Button.js";
9
9
  import { Calendar as C } from "./components/Calendar/Calendar.js";
10
10
  import { Checkbox as k } from "./components/Checkbox/Checkbox.js";
11
- import { C as D, R as A, T as B } from "./Toggle-DeMSbC0N.js";
11
+ import { C as D, R as A, T as B } from "./Toggle-Dp20f7qn.js";
12
12
  import { ConfirmationDialog as v } from "./components/ConfirmationDialog/ConfirmationDialog.js";
13
13
  import "./components/DatePicker/DatePicker.js";
14
14
  import { Description as R } from "./components/Description/Description.js";
@@ -36,7 +36,7 @@ import { Tag as yo } from "./components/Tag/Tag.js";
36
36
  import { TextDisplay as wo } from "./components/TextDisplay/TextDisplay.js";
37
37
  import { ToastCard as Eo } from "./components/ToastCard/ToastCard.js";
38
38
  import { Toggle as No } from "./components/Toggle/Toggle.js";
39
- import { G as Wo } from "./Group-Cyc1W1kV.js";
39
+ import { G as Wo } from "./Group-DJz1rK2n.js";
40
40
  import { Tooltip as qo } from "./components/Tooltip/Tooltip.js";
41
41
  import { TransactionRow as Fo } from "./components/TransactionRow/TransactionRow.js";
42
42
  import { Text as Ko, Typography as Mo } from "./components/Typography/Typography.js";
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@pismo/marola",
3
3
  "description": "CDX tribe component library",
4
- "version": "2.1.2",
4
+ "version": "2.1.4",
5
5
  "type": "module",
6
6
  "main": "dist/main.js",
7
7
  "types": "dist/main.d.ts",
@@ -1,39 +0,0 @@
1
- import { jsxs as l, jsx as o } from "react/jsx-runtime";
2
- import { forwardRef as n } from "react";
3
- import { c } from "./clsx-OuTLNxxd.js";
4
- import { Icon as f } from "./components/Icon/Icon.js";
5
- import { Typography as p } from "./components/Typography/Typography.js";
6
- import './assets/Group.css';const m = "_toggle__input_1fdw4_1", u = "_toggle__label_1fdw4_11", t = {
7
- toggle__input: m,
8
- toggle__label: u,
9
- "toggle__label--selected": "_toggle__label--selected_1fdw4_21",
10
- "toggle__label--disabled": "_toggle__label--disabled_1fdw4_21",
11
- "toggle-group__fieldset": "_toggle-group__fieldset_1fdw4_35",
12
- "toggle-group__options": "_toggle-group__options_1fdw4_40",
13
- "toggle-group__options-same-width": "_toggle-group__options-same-width_1fdw4_44",
14
- "toggle-group__error": "_toggle-group__error_1fdw4_47"
15
- }, v = n((e, d) => {
16
- const { children: r, legend: _, error: g, equalWidth: s } = e, a = e["data-testid"] ? `${e["data-testid"]}-legend` : void 0, i = e["data-testid"] ? `${e["data-testid"]}-error` : void 0;
17
- return /* @__PURE__ */ l("fieldset", { ref: d, "data-testid": e["data-testid"], className: t["toggle-group__fieldset"], children: [
18
- _ && /* @__PURE__ */ o("legend", { "data-testid": a, children: _ }),
19
- /* @__PURE__ */ o(
20
- "div",
21
- {
22
- className: c(
23
- t["toggle-group__options"],
24
- s && t["toggle-group__options-same-width"],
25
- e.classNameForOptions
26
- ),
27
- children: r
28
- }
29
- ),
30
- g && /* @__PURE__ */ l(p, { className: t["toggle-group__error"], "data-testid": i, children: [
31
- /* @__PURE__ */ o(f, { icon: "circle-exclamation" }),
32
- g
33
- ] })
34
- ] });
35
- });
36
- export {
37
- v as G,
38
- t as s
39
- };