Skip to content

Commit

Permalink
Table stories fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Foxhoundn committed Jul 18, 2024
1 parent 669082d commit 5c00565
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 3 deletions.
17 changes: 15 additions & 2 deletions src/components/Paragraph/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ export interface IReqoreParagraphProps
IWithReqoreEffect,
IReqoreIntent {
size?: TSizes | string;
block?: boolean;
inline?: boolean;
}

export const StyledParagraph = styled(StyledTextEffect)`
Expand All @@ -24,7 +26,18 @@ export const StyledParagraph = styled(StyledTextEffect)`

export const ReqoreP = memo(
forwardRef(
({ size, children, customTheme, intent, className, ...props }: IReqoreParagraphProps, ref) => {
(
{
size,
children,
customTheme,
intent,
className,
block = true,
...props
}: IReqoreParagraphProps,
ref
) => {
const theme = useReqoreTheme('main', customTheme, intent);

return (
Expand All @@ -34,7 +47,7 @@ export const ReqoreP = memo(
theme={theme}
color={theme.text.color}
intent={intent}
block
block={block}
{...props}
_size={size}
className={`${className || ''} reqore-paragraph`}
Expand Down
6 changes: 5 additions & 1 deletion src/stories/Table/Table.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -555,7 +555,11 @@ const CustomHeaderCell = (props: IReqoreCustomHeaderCellProps) => {
};

const CustomCell = (props: IReqoreCustomTableBodyCellProps) => {
return <ReqoreP style={{ width: props.width, flexGrow: props.grow }}>{props.children}</ReqoreP>;
return (
<ReqoreP style={{ width: props.width, flexGrow: props.grow }} block={false}>
{props.children}
</ReqoreP>
);
};

const CustomRow = (props: IReqoreCustomTableRowProps) => {
Expand Down

0 comments on commit 5c00565

Please sign in to comment.