-
Notifications
You must be signed in to change notification settings - Fork 89
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
d9cd70e
commit 463cbc6
Showing
19 changed files
with
263 additions
and
222 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import { useId } from "@salt-ds/core"; | ||
import { type ComponentPropsWithoutRef, forwardRef } from "react"; | ||
|
||
export interface TabNextPanelProps extends ComponentPropsWithoutRef<"div"> {} | ||
|
||
export const TabNextPanel = forwardRef<HTMLDivElement, TabNextPanelProps>( | ||
function TabNextPanel(props, ref) { | ||
const { children, id: idProp, ...rest } = props; | ||
const id = useId(idProp); | ||
|
||
return ( | ||
<div id={id} ref={ref} role="tabpanel" {...rest}> | ||
{children} | ||
</div> | ||
); | ||
}, | ||
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import type { ReactNode } from "react"; | ||
|
||
import { TabsNextContext } from "./TabsNextContext"; | ||
|
||
export interface TabsNextProps { | ||
children: ReactNode; | ||
} | ||
|
||
export function TabsNext({ children }: TabsNextProps) { | ||
return ( | ||
<TabsNextContext.Provider value={{}}>{children}</TabsNextContext.Provider> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import { createContext } from "@salt-ds/core"; | ||
import { useContext } from "react"; | ||
|
||
// biome-ignore lint/complexity/noBannedTypes: <explanation> | ||
export type TabsNextContextValue = {}; | ||
|
||
export const TabsNextContext = createContext<TabsNextContextValue>( | ||
"TabsNextContext", | ||
{}, | ||
); | ||
|
||
export function useTabsNext() { | ||
return useContext(TabsNextContext); | ||
} |
Oops, something went wrong.