Skip to content
This repository was archived by the owner on Mar 25, 2025. It is now read-only.

Commit 7f77f10

Browse files
danielkaxisTigge
authored andcommitted
refactor: export interfaces for exported components
Exports the interface used for the component if the component is exported.
1 parent e6707c1 commit 7f77f10

File tree

29 files changed

+39
-37
lines changed

29 files changed

+39
-37
lines changed

packages/core/src/Card/CardTabs.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ interface TabItem<T> {
160160
readonly disabled?: boolean
161161
}
162162

163-
interface CardTabsProps<T> extends Omit<BaseProps, 'onChange'> {
163+
export interface CardTabsProps<T> extends Omit<BaseProps, 'onChange'> {
164164
/**
165165
* Current selected tab, matching a `value` from options
166166
*/

packages/core/src/Chip/index.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,8 @@ const ChipRemoveIcon = styled(ClickableIcon).attrs({
2828
margin-left: ${spacing.small};
2929
`
3030

31-
interface ChipProps extends Omit<BaseChipProps, 'component' | 'noPadding'> {
31+
export interface ChipProps
32+
extends Omit<BaseChipProps, 'component' | 'noPadding'> {
3233
/**
3334
* Changes the text of the label displayed on the chip.
3435
*/

packages/core/src/Content/index.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ const Caption = styled(Typography)`
4747
color: ${({ theme }) => theme.color.text03()};
4848
`
4949

50-
interface TextBlockProps extends BaseProps {
50+
export interface TextBlockProps extends BaseProps {
5151
/**
5252
* `class` to be passed to the component.
5353
*/
@@ -131,7 +131,7 @@ const GroupTitle: React.FC<{
131131
)
132132
}
133133

134-
interface FormSectionProps extends BaseProps {
134+
export interface FormSectionProps extends BaseProps {
135135
/**
136136
* `class` to be passed to the component.
137137
*/
@@ -183,7 +183,7 @@ export const ContentListItem = styled.div<{
183183
}
184184
`
185185

186-
interface ContentListItemWithHoverProps extends BaseProps {
186+
export interface ContentListItemWithHoverProps extends BaseProps {
187187
/**
188188
* `class` to be passed to the component.
189189
*/

packages/core/src/Dialog/AlertDialog.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ export interface AlertDialogAction {
2121
readonly onClick: ButtonClickHandler
2222
}
2323

24-
interface AlertDialogProps extends ModalProps {
24+
export interface AlertDialogProps extends ModalProps {
2525
/**
2626
* When `true` the dialog is rendered, `false` removes the dialog.
2727
*/

packages/core/src/Dialog/ConfirmDialog.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ export interface ConfirmDialogAction {
1010
readonly onClick: ButtonClickHandler
1111
}
1212

13-
interface ConfirmDialogProps extends ModalProps {
13+
export interface ConfirmDialogProps extends ModalProps {
1414
/**
1515
* When `true` the dialog is rendered, `false` removes the dialog.
1616
*/

packages/core/src/DraggableList/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ export const DraggableListItem = styled.div<{
5252
* rendered on the right side of the list items.
5353
*/
5454

55-
interface DraggableListProps extends Omit<BaseProps, 'onChange'> {
55+
export interface DraggableListProps extends Omit<BaseProps, 'onChange'> {
5656
/**
5757
* Function called when list order changes with list of re-ordered indices as argument
5858
*/

packages/core/src/Droppable/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ const InputLabel = styled(Typography)`
6161
word-wrap: break-word;
6262
`
6363

64-
interface DroppableProps extends BaseProps {
64+
export interface DroppableProps extends BaseProps {
6565
/**
6666
* `class` to be passed to the component.
6767
*/

packages/core/src/Expandable/ArrowIcon.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ const SvgIcon: IconType = () => (
1818
</svg>
1919
)
2020

21-
interface ArrowProps {
21+
export interface ArrowProps {
2222
readonly expanded: boolean
2323
readonly disabled: boolean
2424
}

packages/core/src/Expandable/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ const ExpandableHeader: React.FC<{
1717
return <Header onClick={onClick}>{children}</Header>
1818
}
1919

20-
interface ExpandableProps extends BaseProps {
20+
export interface ExpandableProps extends BaseProps {
2121
/**
2222
* `class` to be passed to the component.
2323
*/

packages/core/src/ExpandableList/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ export * from './ExpandableListItem'
1111
type BaseElement = HTMLDivElement
1212
type BaseProps = React.HTMLAttributes<BaseElement>
1313

14-
interface ExpandableListProps extends BaseProps {
14+
export interface ExpandableListProps extends BaseProps {
1515
/**
1616
* `class` to be passed to the component.
1717
*/

0 commit comments

Comments
 (0)