refactor(suite): Move CardList to components

This commit is contained in:
Jan Václavík
2026-02-17 15:44:04 +01:00
parent 0eb3041e1a
commit ea0e926363
5 changed files with 20 additions and 15 deletions

View File

@@ -1,12 +1,13 @@
import { Meta, StoryObj } from '@storybook/react';
import { Text, getFramePropsStory, getTextPropsStory } from '@trezor/components';
import {
CardList as CardListComponent,
allowedCardListFrameProps,
allowedCardListTextProps,
} from './CardList';
import { getFramePropsStory } from '../../utils/frameProps';
import { Text } from '../typography/Text/Text';
import { getTextPropsStory } from '../typography/utils';
const meta: Meta<typeof CardListComponent> = {
title: 'CardList',

View File

@@ -1,15 +1,9 @@
import {
Card,
type CardProps,
Column,
FrameProps,
FramePropsKeys,
Text,
type TextPropsKeys,
type TextStyleProps,
} from '@trezor/components';
import { CardListItem } from './CardListItem';
import { FrameProps, FramePropsKeys } from '../../utils/frameProps';
import { Card, type CardProps } from '../Card/Card';
import { Column } from '../Flex/Flex';
import { Text } from '../typography/Text/Text';
import type { TextPropsKeys, TextProps as TextStyleProps } from '../typography/utils';
export const allowedCardListFrameProps = [
'margin',

View File

@@ -1,4 +1,5 @@
import { GhostContainer, type GhostContainerProps, Row } from '@trezor/components';
import { Row } from '../Flex/Flex';
import { GhostContainer, type GhostContainerProps } from '../GhostContainer/GhostContainer';
export type CardListItemProps = Omit<GhostContainerProps, 'borderRadius' | 'padding'>;

View File

@@ -27,6 +27,15 @@ export {
type BulletListItemState,
} from './components/BulletList/BulletList';
export { Card, type CardProps } from './components/Card/Card';
export {
CardList,
allowedCardListFrameProps,
allowedCardListTextProps,
type CardListProps,
type AllowedCardListFrameProps,
type AllowedCardListTextProps,
} from './components/CardList/CardList';
export { CardListItem, type CardListItemProps } from './components/CardList/CardListItem';
export { Collapsible, type CollapsibleProps } from './components/Collapsible/Collapsible';
export {
CollapsibleBox,

View File

@@ -19,7 +19,7 @@ export { TokenTabs, type TokenTab } from './components/SelectAssetModal/TokenTab
export { NumberInput } from './components/NumberInput/NumberInput';
export { InputWithOptions } from './components/InputWithOptions/InputWithOptions';
export { EditableText, type EditableTextProps } from './components/EditableText/EditableText';
export { CardList, type CardListProps } from './components/CardList/CardList';
export { CardList, type CardListProps } from '@trezor/components';
export { FeeRate } from './components/FeeRate/FeeRate';
export {
DeviceAnimation,