docs: further finesse nimbus toggles (#38954)

* Finesse toggles

* Prettier

* fix

---------

Co-authored-by: Charis Lam <26616127+charislam@users.noreply.github.com>
This commit is contained in:
Chris ChinchillaandCharis Lam authored and GitHub committed 2025-09-23 16:55:48 +00:00
1 parent 9d597d7b13
commit 765aac4f2f
6 files changed
+93 -21

No files matched your search

@@ -7,12 +7,17 @@ import type { GlobalMenuItems, NavMenuConstant, NavMenuSection } from '../Naviga
const {
authenticationShowProviders: allAuthProvidersEnabled,
billingAll: billingEnabled,
docsAuth: authEnabled,
docsAuthArchitecture: authArchitectureEnabled,
docsAuthConfiguration: authConfigurationEnabled,
docsAuthFlows: authFlowsEnabled,
docsAuthFullSecurity: authFullSecurityEnabled,
docsAuthTroubleshooting: authTroubleshootingEnabled,
docsCompliance: complianceEnabled,
docsContribution: contributionEnabled,
'docsSelf-hosting': selfHostingEnabled,
docsFrameworkQuickstarts: frameworkQuickstartsEnabled,
docsFullPlatform: fullPlatformEnabled,
docsLocalDevelopment: localDevelopmentEnabled,
docsMobileTutorials: mobileTutorialsEnabled,
docsPgtap: pgTapEnabled,
docsProductionChecklist: productionChecklistEnabled,
@@ -26,12 +31,17 @@ const {
} = isFeatureEnabled([
'authentication:show_providers',
'billing:all',
'docs:auth',
'docs:contribution',
'docs:auth_architecture',
'docs:auth_configuration',
'docs:auth_flows',
'docs:auth_full_security',
'docs:auth_troubleshooting',
'docs:compliance',
'docs:contribution',
'docs:self-hosting',
'docs:framework_quickstarts',
'docs:full_platform',
'docs:local_development',
'docs:mobile_tutorials',
'docs:pgtap',
'docs:production_checklist',
@@ -72,7 +82,6 @@ export const GLOBAL_MENU_ITEMS: GlobalMenuItems = [
icon: 'auth',
href: '/guides/auth' as `/${string}`,
level: 'auth',
enabled: authEnabled,
},
{
label: 'Storage',
@@ -127,6 +136,7 @@ export const GLOBAL_MENU_ITEMS: GlobalMenuItems = [
icon: 'dev-cli',
href: '/guides/local-development' as `/${string}`,
level: 'local_development',
enabled: localDevelopmentEnabled,
},
{
label: 'Deployment',
@@ -638,7 +648,6 @@ export const PhoneLoginsItems = [
export const auth: NavMenuConstant = {
icon: 'auth',
title: 'Auth',
enabled: authEnabled,
items: [
{
name: 'Overview',
@@ -647,9 +656,11 @@ export const auth: NavMenuConstant = {
{
name: 'Architecture',
url: '/guides/auth/architecture',
enabled: authArchitectureEnabled,
},
{
name: 'Getting Started',
enabled: frameworkQuickstartsEnabled,
items: [
{
name: 'Next.js',
@@ -684,6 +695,7 @@ export const auth: NavMenuConstant = {
},
{
name: 'Flows (How-tos)',
enabled: authFlowsEnabled,
items: [
{
name: 'Server-Side Rendering',
@@ -773,7 +785,11 @@ export const auth: NavMenuConstant = {
name: 'Debugging',
items: [
{ name: 'Error Codes', url: '/guides/auth/debugging/error-codes' },
{ name: 'Troubleshooting', url: '/guides/auth/troubleshooting' },
{
name: 'Troubleshooting',
url: '/guides/auth/troubleshooting',
enabled: authTroubleshootingEnabled,
},
],
},
{
@@ -790,6 +806,7 @@ export const auth: NavMenuConstant = {
},
{
name: 'Configuration',
enabled: authConfigurationEnabled,
items: [
{
name: 'General Configuration',
@@ -837,16 +854,29 @@ export const auth: NavMenuConstant = {
{
name: 'Security',
items: [
{ name: 'Password Security', url: '/guides/auth/password-security' },
{ name: 'Rate Limits', url: '/guides/auth/rate-limits' },
{ name: 'Bot Detection (CAPTCHA)', url: '/guides/auth/auth-captcha' },
{ name: 'Audit Logs', url: '/guides/auth/audit-logs' },
{
name: 'Password Security',
url: '/guides/auth/password-security',
enabled: authFullSecurityEnabled,
},
{ name: 'Rate Limits', url: '/guides/auth/rate-limits', enabled: authFullSecurityEnabled },
{
name: 'Bot Detection (CAPTCHA)',
url: '/guides/auth/auth-captcha',
enabled: authFullSecurityEnabled,
},
{ name: 'Audit Logs', url: '/guides/auth/audit-logs', enabled: authFullSecurityEnabled },
{
name: 'JSON Web Tokens (JWT)',
url: '/guides/auth/jwts',
enabled: authFullSecurityEnabled,
items: [{ name: 'Claims Reference', url: '/guides/auth/jwt-fields' }],
},
{ name: 'JWT Signing Keys', url: '/guides/auth/signing-keys' },
{
name: 'JWT Signing Keys',
url: '/guides/auth/signing-keys',
enabled: authFullSecurityEnabled,
},
{ name: 'Row Level Security', url: '/guides/database/postgres/row-level-security' },
{
name: 'Column Level Security',
@@ -2097,6 +2127,7 @@ export const ai: NavMenuConstant = {
export const local_development: NavMenuConstant = {
icon: 'dev-cli',
title: 'Local Dev / CLI',
enabled: localDevelopmentEnabled,
url: '/guides/local-development',
items: [
{ name: 'Overview', url: '/guides/local-development' },
+4
View File
@@ -31,6 +31,8 @@ Auth also enables access control to your database's automatically generated [RES
<$Partial path="providers.mdx" />
</$Show>
<$Show if="billing:all">
## Pricing
Charges apply to Monthly Active Users (MAU), Monthly Active Third-Party Users (Third-Party MAU), and Monthly Active SSO Users (SSO MAU) and Advanced MFA Add-ons. For a detailed breakdown of how these charges are calculated, refer to the following pages:
@@ -39,3 +41,5 @@ Charges apply to Monthly Active Users (MAU), Monthly Active Third-Party Users (T
- [Pricing Third-Party MAU](/docs/guides/platform/manage-your-usage/monthly-active-users-third-party)
- [Pricing SSO MAU](/docs/guides/platform/manage-your-usage/monthly-active-users-sso)
- [Advanced MFA - Phone](/docs/guides/platform/manage-your-usage/advanced-mfa-phone)
</$Show>
@@ -31,7 +31,7 @@ export async function ReferenceNavigation({
}: ReferenceNavigationProps) {
const navSections = await getReferenceSections(libraryId, version)
const filteredNavSections = navSections?.filter((section) => section.title !== 'Auth')
const displayedNavSections = isFeatureEnabled('docs:auth') ? navSections : filteredNavSections
const displayedNavSections = isFeatureEnabled('sdk:auth') ? navSections : filteredNavSections
const basePath = `/reference/${libPath}${isLatestVersion ? '' : `/${version}`}`
@@ -43,7 +43,7 @@ async function RefSections({ libraryId, version }: RefSectionsProps) {
flattenedSections = trimIntro(flattenedSections)
}
if (!isFeatureEnabled('docs:auth')) {
if (!isFeatureEnabled('sdk:auth')) {
flattenedSections = flattenedSections?.filter(
(section) =>
'product' in section && section.product !== 'auth' && section.product !== 'auth-admin'
@@ -33,7 +33,11 @@
"database:replication": true,
"database:roles": true,
"docs:auth": true,
"docs:auth_architecture": true,
"docs:auth_configuration": true,
"docs:auth_flows": true,
"docs:auth_full_security": true,
"docs:auth_troubleshooting": true,
"docs:compliance": true,
"docs:contribution": true,
"docs:self-hosting": true,
@@ -41,6 +45,7 @@
"docs:full_getting_started": true,
"docs:full_platform": true,
"docs:hide_cli_profiles": true,
"docs:local_development": true,
"docs:mobile_tutorials": true,
"docs:pgtap": true,
"docs:production_checklist": true,
@@ -85,6 +90,7 @@
"reports:all": true,
"sdk:auth": true,
"sdk:csharp": true,
"sdk:dart": true,
"sdk:kotlin": true,
@@ -116,21 +116,33 @@
"description": "Enable the database roles page"
},
"docs:auth": {
"docs:auth_architecture": {
"type": "boolean",
"description": "Enable auth docs"
"description": "Enable docs on Auth architecture"
},
"docs:contribution": {
"docs:auth_configuration": {
"type": "boolean",
"description": "Enable documentation on contribution"
"description": "Enable auth configuration docs"
},
"docs:auth_flows": {
"type": "boolean",
"description": "Enable docs on auth flows"
},
"docs:auth_full_security": {
"type": "boolean",
"description": "Full auth security docs enabled"
},
"docs:auth_troubleshooting": {
"type": "boolean",
"description": "Enable auth troubleshooting docs"
},
"docs:compliance": {
"type": "boolean",
"description": "Enable documentation on compliance"
},
"docs:self-hosting": {
"docs:contribution": {
"type": "boolean",
"description": "Enable documentation for self-hosting"
"description": "Enable documentation on contribution"
},
"docs:framework_quickstarts": {
"type": "boolean",
@@ -148,6 +160,10 @@
"type": "boolean",
"description": "Hide docs on CLI profiles"
},
"docs:local_development": {
"type": "boolean",
"description": "Enable local development documentation"
},
"docs:mobile_tutorials": {
"type": "boolean",
"description": "Enable mobile tutorials getting started documentation"
@@ -160,10 +176,15 @@
"type": "boolean",
"description": "Enable production checklist"
},
"docs:self-hosting": {
"type": "boolean",
"description": "Enable documentation for self-hosting"
},
"docs:web_apps": {
"type": "boolean",
"description": "Enable web apps getting started documentation"
},
"feedback:docs": {
"type": "boolean",
"description": "Enable feedback submission for docs site"
@@ -284,6 +305,10 @@
"description": "Enable the project reports page"
},
"sdk:auth": {
"type": "boolean",
"description": "Enable Auth SDK docs"
},
"sdk:csharp": {
"type": "boolean",
"description": "Enable the C# SDK"
@@ -336,13 +361,18 @@
"dashboard_auth:sign_in_with_email",
"database:replication",
"database:roles",
"docs:auth",
"docs:auth_architecture",
"docs:auth_configuration",
"docs:auth_flows",
"docs:auth_full_security",
"docs:auth_troubleshooting",
"docs:compliance",
"docs:contribution",
"docs:framework_quickstarts",
"docs:full_getting_started",
"docs:full_platform",
"docs:hide_cli_profiles",
"docs:local_development",
"docs:mobile_tutorials",
"docs:pgtap",
"docs:production_checklist",
@@ -375,6 +405,7 @@
"project_connection:show_orms",
"quickstarts:hide_nimbus",
"reports:all",
"sdk:auth",
"sdk:csharp",
"sdk:dart",
"sdk:kotlin",