mirror of
https://github.com/supabase/supabase.git
synced 2026-10-05 17:35:10 +03:00
move auth server into accordian
This commit is contained in:
1 parent
2e77376de1
commit
dfa1aba1b9
3 files changed
+119
-97
No files matched your search
@@ -96,6 +96,10 @@ const NavigationMenuRefList: React.FC<INavigationMenuRefList> = ({
|
||||
? find(sections, { title: 'Database' }).items
|
||||
: []
|
||||
|
||||
const authFunctions = find(sections, { title: 'Auth' })
|
||||
? find(sections, { title: 'Auth' }).items
|
||||
: []
|
||||
|
||||
// console.log('databaseFunctions', databaseFunctions)
|
||||
|
||||
const filterIds =
|
||||
@@ -118,6 +122,16 @@ const NavigationMenuRefList: React.FC<INavigationMenuRefList> = ({
|
||||
}).items.map((x) => x.id)
|
||||
: []
|
||||
|
||||
const authServerIds =
|
||||
databaseFunctions.length > 0
|
||||
? find(authFunctions, {
|
||||
id: 'admin-api',
|
||||
}) &&
|
||||
find(authFunctions, {
|
||||
id: 'admin-api',
|
||||
}).items.map((x) => x.id)
|
||||
: []
|
||||
|
||||
// console.log(filterIds)
|
||||
// console.log(modifierIds)
|
||||
|
||||
@@ -204,12 +218,16 @@ const NavigationMenuRefList: React.FC<INavigationMenuRefList> = ({
|
||||
filterIds && filterIds.length > 0 && filterIds.includes(activeAccordianItem)
|
||||
const isModifier =
|
||||
modifierIds && modifierIds.length > 0 && modifierIds.includes(activeAccordianItem)
|
||||
const isAuthServer =
|
||||
authServerIds &&
|
||||
authServerIds.length > 0 &&
|
||||
authServerIds.includes(activeAccordianItem)
|
||||
|
||||
// console.log('isFilter', props.id, isFilter)
|
||||
// console.log('isModifier', props.id, isModifier)
|
||||
|
||||
if (
|
||||
(isFilter && !isModifier && props.id === 'using-filters') ||
|
||||
(isFilter && !isModifier && !isAuthServer && props.id === 'using-filters') ||
|
||||
(activeAccordianItem === 'using-filters' &&
|
||||
!isModifier &&
|
||||
!isFilter &&
|
||||
@@ -217,13 +235,22 @@ const NavigationMenuRefList: React.FC<INavigationMenuRefList> = ({
|
||||
) {
|
||||
active = true
|
||||
} else if (
|
||||
(isModifier && !isFilter && props.id === 'using-modifiers') ||
|
||||
(isModifier && !isFilter && !isAuthServer && props.id === 'using-modifiers') ||
|
||||
(activeAccordianItem === 'using-modifiers' &&
|
||||
!isFilter &&
|
||||
!isModifier &&
|
||||
props.id === 'using-modifiers')
|
||||
) {
|
||||
active = true
|
||||
} else if (
|
||||
(isAuthServer && !isFilter && !isModifier && props.id === 'admin-api') ||
|
||||
(activeAccordianItem === 'admin-api' &&
|
||||
!isFilter &&
|
||||
!isModifier &&
|
||||
!isAuthServer &&
|
||||
props.id === 'admin-api')
|
||||
) {
|
||||
active = true
|
||||
} else {
|
||||
active = false
|
||||
}
|
||||
|
||||
@@ -19,16 +19,17 @@ export async function getStaticProps({ params }: { params: { slug: string[] } })
|
||||
|
||||
export function getStaticPaths() {
|
||||
return handleRefGetStaticPaths()
|
||||
}
|
||||
|
||||
export const config = {
|
||||
// test - force again
|
||||
unstable_includeFiles: [
|
||||
'node_modules/.pnpm/**/shiki/**/*.json',
|
||||
'node_modules/**/shiki/**/*.json',
|
||||
'node_modules/.npm/shiki/**/*.json',
|
||||
'/var/task/node_modules/shiki/languages/abap.tmLanguage.json',
|
||||
'node_modules/shiki/languages/abap.tmLanguage.json',
|
||||
'node_modules/shiki/**/*.json',
|
||||
],
|
||||
let docs = getAllDocs()
|
||||
|
||||
return {
|
||||
paths: docs.map(() => {
|
||||
return {
|
||||
params: {
|
||||
slug: docs.map((d) => d.slug),
|
||||
},
|
||||
}
|
||||
}),
|
||||
fallback: 'blocking',
|
||||
}
|
||||
}
|
||||
@@ -577,93 +577,87 @@
|
||||
"product": "auth",
|
||||
"type": "function",
|
||||
"libs": ["js", "js_v1", "dart", "dart_v0"]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"title": "Auth (server-only)",
|
||||
"libs": ["js", "js_v1"],
|
||||
"items": [
|
||||
},
|
||||
{
|
||||
"id": "admin-api",
|
||||
"isFunc": false,
|
||||
"title": "Overview",
|
||||
"slug": "supabase-auth-admin-api",
|
||||
"product": "auth-admin",
|
||||
"title": "Auth (server-only)",
|
||||
"slug": "admin-api",
|
||||
"libs": ["js", "js_v1"],
|
||||
"type": "function",
|
||||
"libs": ["js"]
|
||||
},
|
||||
{
|
||||
"id": "get-user-by-id",
|
||||
"title": "Retrieve a user",
|
||||
"slug": "auth-admin-getuserbyid",
|
||||
"product": "auth-admin",
|
||||
"type": "function",
|
||||
"libs": ["js"]
|
||||
},
|
||||
{
|
||||
"id": "list-users",
|
||||
"title": "List all users",
|
||||
"slug": "auth-admin-listusers",
|
||||
"product": "auth-admin",
|
||||
"type": "function",
|
||||
"libs": ["js", "js_v1"]
|
||||
},
|
||||
{
|
||||
"id": "create-user",
|
||||
"title": "Create a user",
|
||||
"slug": "auth-admin-createuser",
|
||||
"product": "auth-admin",
|
||||
"type": "function",
|
||||
"libs": ["js", "js_v1"]
|
||||
},
|
||||
{
|
||||
"id": "delete-user",
|
||||
"title": "Delete a user",
|
||||
"slug": "auth-admin-deleteuser",
|
||||
"product": "auth-admin",
|
||||
"type": "function",
|
||||
"libs": ["js", "js_v1"]
|
||||
},
|
||||
{
|
||||
"id": "invite-user-by-email",
|
||||
"title": "Send an email invite link",
|
||||
"slug": "auth-admin-inviteuserbyemail",
|
||||
"product": "auth-admin",
|
||||
"type": "function",
|
||||
"libs": ["js", "js_v1"]
|
||||
},
|
||||
{
|
||||
"id": "reset-password-for-email",
|
||||
"title": "Send a password reset request",
|
||||
"slug": "auth-admin-resetpasswordforemail",
|
||||
"product": "auth-admin",
|
||||
"type": "function",
|
||||
"libs": ["js"]
|
||||
},
|
||||
{
|
||||
"id": "generate-link",
|
||||
"title": "Generate an email link",
|
||||
"slug": "auth-admin-generatelink",
|
||||
"product": "auth-admin",
|
||||
"type": "function",
|
||||
"libs": ["js"]
|
||||
},
|
||||
{
|
||||
"id": "send-mobile-otp",
|
||||
"title": "Send a one-time passcode",
|
||||
"slug": "auth-api-sendmobileotp",
|
||||
"product": "auth-server",
|
||||
"type": "function",
|
||||
"libs": ["js_v1"]
|
||||
},
|
||||
{
|
||||
"id": "update-user-by-id",
|
||||
"title": "Update a user",
|
||||
"slug": "auth-admin-updateuserbyid",
|
||||
"product": "auth-admin",
|
||||
"type": "function",
|
||||
"libs": ["js", "js_v1"]
|
||||
"items": [
|
||||
{
|
||||
"id": "get-user-by-id",
|
||||
"title": "Retrieve a user",
|
||||
"slug": "auth-admin-getuserbyid",
|
||||
"product": "auth-admin",
|
||||
"type": "function",
|
||||
"libs": ["js"]
|
||||
},
|
||||
{
|
||||
"id": "list-users",
|
||||
"title": "List all users",
|
||||
"slug": "auth-admin-listusers",
|
||||
"product": "auth-admin",
|
||||
"type": "function",
|
||||
"libs": ["js", "js_v1"]
|
||||
},
|
||||
{
|
||||
"id": "create-user",
|
||||
"title": "Create a user",
|
||||
"slug": "auth-admin-createuser",
|
||||
"product": "auth-admin",
|
||||
"type": "function",
|
||||
"libs": ["js", "js_v1"]
|
||||
},
|
||||
{
|
||||
"id": "delete-user",
|
||||
"title": "Delete a user",
|
||||
"slug": "auth-admin-deleteuser",
|
||||
"product": "auth-admin",
|
||||
"type": "function",
|
||||
"libs": ["js", "js_v1"]
|
||||
},
|
||||
{
|
||||
"id": "invite-user-by-email",
|
||||
"title": "Send an email invite link",
|
||||
"slug": "auth-admin-inviteuserbyemail",
|
||||
"product": "auth-admin",
|
||||
"type": "function",
|
||||
"libs": ["js", "js_v1"]
|
||||
},
|
||||
{
|
||||
"id": "reset-password-for-email",
|
||||
"title": "Send a password reset request",
|
||||
"slug": "auth-admin-resetpasswordforemail",
|
||||
"product": "auth-admin",
|
||||
"type": "function",
|
||||
"libs": ["js"]
|
||||
},
|
||||
{
|
||||
"id": "generate-link",
|
||||
"title": "Generate an email link",
|
||||
"slug": "auth-admin-generatelink",
|
||||
"product": "auth-admin",
|
||||
"type": "function",
|
||||
"libs": ["js"]
|
||||
},
|
||||
{
|
||||
"id": "send-mobile-otp",
|
||||
"title": "Send a one-time passcode",
|
||||
"slug": "auth-api-sendmobileotp",
|
||||
"product": "auth-server",
|
||||
"type": "function",
|
||||
"libs": ["js_v1"]
|
||||
},
|
||||
{
|
||||
"id": "update-user-by-id",
|
||||
"title": "Update a user",
|
||||
"slug": "auth-admin-updateuserbyid",
|
||||
"product": "auth-admin",
|
||||
"type": "function",
|
||||
"libs": ["js", "js_v1"]
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
|
||||
Reference in new issue
Block a user