diff --git a/packages/co-design-core/src/components/Badge/Badge.tsx b/packages/co-design-core/src/components/Badge/Badge.tsx index 1442916..18d4814 100644 --- a/packages/co-design-core/src/components/Badge/Badge.tsx +++ b/packages/co-design-core/src/components/Badge/Badge.tsx @@ -21,7 +21,7 @@ export type BadgeProps = PolymorphicComponentProps< type BadgeComponent = (props: BadgeProps) => React.ReactNode; -const Badge: BadgeComponent & { displayName?: string } = forwardRef( +export const Badge: BadgeComponent & { displayName?: string } = forwardRef( ( { children, @@ -88,5 +88,3 @@ const Badge: BadgeComponent & { displayName?: string } = forwardRef( ); Badge.displayName = '@co-design/core/Badge'; - -export default Badge; diff --git a/packages/co-design-core/src/components/Badge/Shield.tsx b/packages/co-design-core/src/components/Badge/Shield.tsx index 245eebb..02d6652 100644 --- a/packages/co-design-core/src/components/Badge/Shield.tsx +++ b/packages/co-design-core/src/components/Badge/Shield.tsx @@ -28,7 +28,7 @@ export type ShieldBadgeProps = PolymorphicComponent type ShieldBadgeComponent = (props: ShieldBadgeProps) => React.ReactNode; -const ShieldBadge: ShieldBadgeComponent & { displayName?: string } = forwardRef( +export const ShieldBadge: ShieldBadgeComponent & { displayName?: string } = forwardRef( ( { title, message, component, className, co, overrideStyles, ...props }: ShieldBadgeProps, ref: PolymorphicRef, @@ -66,5 +66,3 @@ const ShieldBadge: ShieldBadgeComponent & { displayName?: string } = forwardRef( ); ShieldBadge.displayName = '@co-design/core/ShieldBadge'; - -export default ShieldBadge; diff --git a/packages/co-design-core/src/components/Badge/index.ts b/packages/co-design-core/src/components/Badge/index.ts index 6e568c4..43aadcf 100644 --- a/packages/co-design-core/src/components/Badge/index.ts +++ b/packages/co-design-core/src/components/Badge/index.ts @@ -1,2 +1,4 @@ -export { default as Badge } from './Badge'; -export { default as ShieldBadge } from './Shield'; +export { Badge } from './Badge'; +export { ShieldBadge } from './Shield'; +export type { BadgeProps } from './Badge'; +export type { ShieldBadgeProps } from './Shield'; diff --git a/packages/co-design-core/src/components/Progress2/index.ts b/packages/co-design-core/src/components/Progress2/index.ts index 6474262..90637fa 100644 --- a/packages/co-design-core/src/components/Progress2/index.ts +++ b/packages/co-design-core/src/components/Progress2/index.ts @@ -1,2 +1,2 @@ export { Progress2 } from './Progress2'; -export type { ProgressProps } from './Progress2'; +export type { Progress2Props } from './Progress2'; diff --git a/packages/co-design-core/src/components/Stepper/Step.style.ts b/packages/co-design-core/src/components/Stepper/Step.style.ts index 8660135..38f8973 100644 --- a/packages/co-design-core/src/components/Stepper/Step.style.ts +++ b/packages/co-design-core/src/components/Stepper/Step.style.ts @@ -1,12 +1,12 @@ import { createStyles } from '@co-design/styles'; import { getFieldValue } from '../../utils'; -interface StackStyles { +interface StepStyles { variant?: 'wait' | 'current' | 'finished' | 'error'; labelPosition?: 'right' | 'bottom'; } -export default createStyles((theme, { variant, labelPosition }: StackStyles) => { +export default createStyles((theme, { variant, labelPosition }: StepStyles) => { const backgroundColor = { wait: theme.foundations.tokens.color.bg.bg_base_light_active, current: theme.foundations.tokens.color.bg.bg_primary, diff --git a/packages/co-design-core/src/components/Stepper/Stepper.style.ts b/packages/co-design-core/src/components/Stepper/Stepper.style.ts index 9af362b..8db579d 100644 --- a/packages/co-design-core/src/components/Stepper/Stepper.style.ts +++ b/packages/co-design-core/src/components/Stepper/Stepper.style.ts @@ -1,11 +1,11 @@ import { createStyles } from '@co-design/styles'; -interface StackStyles { +interface StepperStyles { orientation?: 'horizontal' | 'vertical'; isNeedGap?: boolean; } -export default createStyles((theme, { orientation, isNeedGap }: StackStyles) => { +export default createStyles((theme, { orientation, isNeedGap }: StepperStyles) => { const stepSize = theme.foundations.tokens.size.size_09; const stepsGap = theme.foundations.tokens.size.size_04; return { diff --git a/packages/co-design-core/src/components/Stepper/index.ts b/packages/co-design-core/src/components/Stepper/index.ts index 3cfbfb3..b9034e8 100644 --- a/packages/co-design-core/src/components/Stepper/index.ts +++ b/packages/co-design-core/src/components/Stepper/index.ts @@ -1,2 +1,4 @@ export { Stepper } from './Stepper'; +export { Step } from './Step'; export type { StepperProps } from './Stepper'; +export type { StepProps } from './Step';