Skip to content

Commit

Permalink
Allow custom components passed to Accordion header (#62)
Browse files Browse the repository at this point in the history
  • Loading branch information
ncovercash authored Sep 9, 2024
1 parent 2f63590 commit 0072719
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions components/lib/Accordion/Accordion.d.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Component, CSSProperties, ReactNode, RefObject } from 'react';
import { Component, ComponentType, CSSProperties, ReactNode, RefObject } from 'react';
import { HotKeysProps } from '../HotKeys';
import { DefaultAccordionHeaderProps } from './headers/DefaultAccordionHeader';

Expand All @@ -20,7 +20,7 @@ export type AccordionProps<HeaderProps = DefaultAccordionHeaderProps> = Partial<
/** If the accordion should be disabled */
disabled?: boolean;
/** Supplies a custom header */
header?: ReactNode;
header?: ReactNode | ComponentType<HeaderProps>;
/** Adds props to the header (additional props on the root `<Accordion>` will also be passed) */
headerProps?: Partial<HeaderProps>;
/** The id of the accordion */
Expand Down

0 comments on commit 0072719

Please sign in to comment.