Skip to content

Commit

Permalink
Address PR comments
Browse files Browse the repository at this point in the history
  • Loading branch information
JasonMHasperhoven committed Dec 23, 2024
1 parent c8e97b6 commit 96f45a2
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 3 deletions.
2 changes: 1 addition & 1 deletion packages/ui/src/Button/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ export const Button = forwardRef<HTMLButtonElement, ButtonProps>(

'relative',
'text-neutral-contrast',
'inline-flex items-center justify-center',
'flex items-center justify-center',
density === 'sparse' ? 'gap-2' : 'gap-1',
)}
>
Expand Down
6 changes: 6 additions & 0 deletions packages/ui/src/Text/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@ import {
tableHeading,
tableHeadingMedium,
tableHeadingSmall,
tableItem,
tableItemSmall,
tableItemMedium,
} from '../utils/typography';
import { ElementType, ReactNode } from 'react';
import { ThemeColor } from '../utils/color';
Expand Down Expand Up @@ -141,6 +144,9 @@ const VARIANT_MAP: Record<TextVariant, { element: ElementType; classes: string }
tableHeading: { element: 'span', classes: tableHeading },
tableHeadingMedium: { element: 'span', classes: tableHeadingMedium },
tableHeadingSmall: { element: 'span', classes: tableHeadingSmall },
tableItem: { element: 'span', classes: tableItem },
tableItemMedium: { element: 'span', classes: tableItemMedium },
tableItemSmall: { element: 'span', classes: tableItemSmall },
};

/**
Expand Down
5 changes: 4 additions & 1 deletion packages/ui/src/Text/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,10 @@ export type TextVariant =
| 'body'
| 'tableHeading'
| 'tableHeadingMedium'
| 'tableHeadingSmall';
| 'tableHeadingSmall'
| 'tableItem'
| 'tableItemMedium'
| 'tableItemSmall';

type TextType = {
[K in TextVariant]: Record<K, true> & Partial<Record<Exclude<TextVariant, K>, never>>;
Expand Down
2 changes: 1 addition & 1 deletion packages/ui/src/utils/typography.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,4 +61,4 @@ export const button = cn('font-default text-textBase font-medium leading-textBas

export const buttonMedium = cn('font-default text-textBase font-medium leading-textBase');

export const buttonSmall = cn('font-default text-textXs font-medium leading-textBase');
export const buttonSmall = cn('font-default text-textSm font-medium leading-textBase');

0 comments on commit 96f45a2

Please sign in to comment.