mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-17 12:03:31 +01:00
feat(website): use dropdowns for overloads (#8630)
Co-authored-by: Almeida <almeidx@pm.me> Co-authored-by: iCrawl <buechler.noel@outlook.com>
This commit is contained in:
@@ -193,7 +193,9 @@ export const getStaticProps: GetStaticProps = async ({ params }) => {
|
||||
packageName,
|
||||
branchName,
|
||||
data: {
|
||||
members: pkg ? getMembers(pkg, branchName) : [],
|
||||
members: pkg
|
||||
? getMembers(pkg, branchName).filter((item) => item.overloadIndex === null || item.overloadIndex <= 1)
|
||||
: [],
|
||||
member:
|
||||
memberName && containerKey ? findMemberByKey(model, packageName, containerKey, branchName) ?? null : null,
|
||||
source: mdxSource,
|
||||
@@ -219,7 +221,7 @@ const member = (props?: ApiItemJSON | undefined) => {
|
||||
case 'Class':
|
||||
return <Class data={props as ApiClassJSON} />;
|
||||
case 'Function':
|
||||
return <Function data={props as ApiFunctionJSON} />;
|
||||
return <Function key={props.containerKey} data={props as ApiFunctionJSON} />;
|
||||
case 'Interface':
|
||||
return <Interface data={props as ApiInterfaceJSON} />;
|
||||
case 'TypeAlias':
|
||||
|
||||
Reference in New Issue
Block a user