diff --git a/.changeset/brave-shoes-search.md b/.changeset/brave-shoes-search.md new file mode 100644 index 00000000000..c93c1002fca --- /dev/null +++ b/.changeset/brave-shoes-search.md @@ -0,0 +1,5 @@ +--- +'@primer/react': patch +--- + +Update exports for UnderlinePanels component diff --git a/packages/react/src/__tests__/__snapshots__/exports.test.ts.snap b/packages/react/src/__tests__/__snapshots__/exports.test.ts.snap index bab6c95313f..015068cc21d 100644 --- a/packages/react/src/__tests__/__snapshots__/exports.test.ts.snap +++ b/packages/react/src/__tests__/__snapshots__/exports.test.ts.snap @@ -263,7 +263,6 @@ exports[`@primer/react/drafts should not update exports without a semver change "default", "default", "default", - "default", "Dialog", "type DialogButtonProps", "type DialogHeaderProps", @@ -297,7 +296,6 @@ exports[`@primer/react/drafts should not update exports without a semver change "type NavListTrailingVisualProps", "PageHeader", "type PageHeaderProps", - "type PanelProps", "type ParentLinkProps", "type Reference", "type SavedReply", @@ -331,7 +329,6 @@ exports[`@primer/react/drafts should not update exports without a semver change "type TabPanelsPanelProps", "type TabPanelsProps", "type TabPanelsTabProps", - "type TabProps", "type TitleProps", "Tooltip", "TooltipContext", @@ -339,7 +336,10 @@ exports[`@primer/react/drafts should not update exports without a semver change "type TooltipProps", "type Trigger", "type TriggerPropsType", + "UnderlinePanels", + "type UnderlinePanelsPanelProps", "type UnderlinePanelsProps", + "type UnderlinePanelsTabProps", "useCombobox", "useDynamicTextareaHeight", "useIgnoreKeyboardActionsWhileComposing", @@ -374,7 +374,6 @@ exports[`@primer/react/experimental should not update exports without a semver c "default", "default", "default", - "default", "Dialog", "type DialogButtonProps", "type DialogHeaderProps", @@ -410,7 +409,6 @@ exports[`@primer/react/experimental should not update exports without a semver c "type NavListTrailingVisualProps", "PageHeader", "type PageHeaderProps", - "type PanelProps", "type ParentLinkProps", "type Reference", "type SavedReply", @@ -444,7 +442,6 @@ exports[`@primer/react/experimental should not update exports without a semver c "type TabPanelsPanelProps", "type TabPanelsProps", "type TabPanelsTabProps", - "type TabProps", "type TitleProps", "Tooltip", "TooltipContext", @@ -452,7 +449,10 @@ exports[`@primer/react/experimental should not update exports without a semver c "type TooltipProps", "type Trigger", "type TriggerPropsType", + "UnderlinePanels", + "type UnderlinePanelsPanelProps", "type UnderlinePanelsProps", + "type UnderlinePanelsTabProps", "useCombobox", "useDynamicTextareaHeight", "useIgnoreKeyboardActionsWhileComposing", diff --git a/packages/react/src/drafts/UnderlinePanels/UnderlinePanels.test.tsx b/packages/react/src/drafts/UnderlinePanels/UnderlinePanels.test.tsx index 9a63ac4bec3..22b18e74358 100644 --- a/packages/react/src/drafts/UnderlinePanels/UnderlinePanels.test.tsx +++ b/packages/react/src/drafts/UnderlinePanels/UnderlinePanels.test.tsx @@ -3,7 +3,7 @@ import React from 'react' import {render, screen} from '@testing-library/react' import UnderlinePanels from './UnderlinePanels' -import {behavesAsComponent, checkExports} from '../../utils/testing' +import {behavesAsComponent} from '../../utils/testing' import TabContainerElement from '@github/tab-container-element' TabContainerElement.prototype.selectTab = jest.fn() @@ -24,10 +24,6 @@ describe('UnderlinePanels', () => { jest.restoreAllMocks() }) - checkExports('drafts/UnderlinePanels', { - default: UnderlinePanels, - }) - behavesAsComponent({Component: UnderlinePanels, options: {skipAs: true}}) behavesAsComponent({Component: UnderlinePanels.Tab}) diff --git a/packages/react/src/drafts/UnderlinePanels/index.ts b/packages/react/src/drafts/UnderlinePanels/index.ts index 1d485a75b2e..c0d96334213 100644 --- a/packages/react/src/drafts/UnderlinePanels/index.ts +++ b/packages/react/src/drafts/UnderlinePanels/index.ts @@ -1,2 +1,8 @@ -export {default} from './UnderlinePanels' -export type {UnderlinePanelsProps, TabProps, PanelProps} from './UnderlinePanels' +import UnderlinePanels from './UnderlinePanels' + +export {UnderlinePanels} +export type { + UnderlinePanelsProps, + TabProps as UnderlinePanelsTabProps, + PanelProps as UnderlinePanelsPanelProps, +} from './UnderlinePanels' diff --git a/packages/react/src/drafts/index.ts b/packages/react/src/drafts/index.ts index fca323ac256..dcc43646db4 100644 --- a/packages/react/src/drafts/index.ts +++ b/packages/react/src/drafts/index.ts @@ -78,6 +78,7 @@ export type {StackProps, StackItemProps} from '../Stack' export {Announce, AriaStatus, AriaAlert} from '../live-region' export type {AnnounceProps, AriaStatusProps, AriaAlertProps} from '../live-region' -export * from './UnderlinePanels' +export {UnderlinePanels} from './UnderlinePanels' +export type {UnderlinePanelsProps, UnderlinePanelsTabProps, UnderlinePanelsPanelProps} from './UnderlinePanels' export {SkeletonBox, SkeletonText, SkeletonAvatar} from './Skeleton'