Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions apps/docs/spec/api_v1_openapi.json
Original file line number Diff line number Diff line change
Expand Up @@ -6927,7 +6927,7 @@
},
"UpdateCustomHostnameBody": {
"type": "object",
"properties": { "custom_hostname": { "type": "string", "minLength": 1 } },
"properties": { "custom_hostname": { "type": "string", "maxLength": 253, "minLength": 1 } },
"required": ["custom_hostname"]
},
"NetworkBanResponse": {
Expand Down Expand Up @@ -7195,7 +7195,7 @@
},
"VanitySubdomainBody": {
"type": "object",
"properties": { "vanity_subdomain": { "type": "string" } },
"properties": { "vanity_subdomain": { "type": "string", "maxLength": 63 } },
"required": ["vanity_subdomain"]
},
"SubdomainAvailabilityResponse": {
Expand Down
6,114 changes: 3,057 additions & 3,057 deletions apps/docs/spec/enrichments/tsdoc_v2/combined.json

Large diffs are not rendered by default.

116 changes: 58 additions & 58 deletions apps/docs/spec/enrichments/tsdoc_v2/functions.json

Large diffs are not rendered by default.

116 changes: 58 additions & 58 deletions apps/docs/spec/enrichments/tsdoc_v2/functions_dereferenced.json

Large diffs are not rendered by default.

2,398 changes: 1,199 additions & 1,199 deletions apps/docs/spec/enrichments/tsdoc_v2/gotrue.json

Large diffs are not rendered by default.

2,398 changes: 1,199 additions & 1,199 deletions apps/docs/spec/enrichments/tsdoc_v2/gotrue_dereferenced.json

Large diffs are not rendered by default.

1,012 changes: 506 additions & 506 deletions apps/docs/spec/enrichments/tsdoc_v2/postgrest.json

Large diffs are not rendered by default.

1,012 changes: 506 additions & 506 deletions apps/docs/spec/enrichments/tsdoc_v2/postgrest_dereferenced.json

Large diffs are not rendered by default.

928 changes: 464 additions & 464 deletions apps/docs/spec/enrichments/tsdoc_v2/realtime.json

Large diffs are not rendered by default.

928 changes: 464 additions & 464 deletions apps/docs/spec/enrichments/tsdoc_v2/realtime_dereferenced.json

Large diffs are not rendered by default.

1,450 changes: 725 additions & 725 deletions apps/docs/spec/enrichments/tsdoc_v2/storage.json

Large diffs are not rendered by default.

1,450 changes: 725 additions & 725 deletions apps/docs/spec/enrichments/tsdoc_v2/storage_dereferenced.json

Large diffs are not rendered by default.

210 changes: 105 additions & 105 deletions apps/docs/spec/enrichments/tsdoc_v2/supabase.json

Large diffs are not rendered by default.

210 changes: 105 additions & 105 deletions apps/docs/spec/enrichments/tsdoc_v2/supabase_dereferenced.json

Large diffs are not rendered by default.

11 changes: 8 additions & 3 deletions apps/docs/spec/transforms/api_v1_openapi_deparsed.json
Original file line number Diff line number Diff line change
Expand Up @@ -4517,6 +4517,7 @@
"properties": {
"custom_hostname": {
"type": "string",
"maxLength": 253,
"minLength": 1
}
},
Expand Down Expand Up @@ -6969,7 +6970,8 @@
"type": "object",
"properties": {
"vanity_subdomain": {
"type": "string"
"type": "string",
"maxLength": 63
}
},
"required": ["vanity_subdomain"]
Expand Down Expand Up @@ -7052,7 +7054,8 @@
"type": "object",
"properties": {
"vanity_subdomain": {
"type": "string"
"type": "string",
"maxLength": 63
}
},
"required": ["vanity_subdomain"]
Expand Down Expand Up @@ -22263,6 +22266,7 @@
"properties": {
"custom_hostname": {
"type": "string",
"maxLength": 253,
"minLength": 1
}
},
Expand Down Expand Up @@ -22714,7 +22718,8 @@
"type": "object",
"properties": {
"vanity_subdomain": {
"type": "string"
"type": "string",
"maxLength": 63
}
},
"required": ["vanity_subdomain"]
Expand Down
40 changes: 9 additions & 31 deletions apps/studio/.github/eslint-rule-baselines.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
{
"rules": {
"react-hooks/exhaustive-deps": 219,
"import/no-anonymous-default-export": 62,
"@tanstack/query/exhaustive-deps": 18,
"@typescript-eslint/no-explicit-any": 1316
"react-hooks/exhaustive-deps": 216,
"import/no-anonymous-default-export": 57,
"@tanstack/query/exhaustive-deps": 14,
"@typescript-eslint/no-explicit-any": 1294
},
"ruleFiles": {
"react-hooks/exhaustive-deps": {
Expand All @@ -20,7 +20,6 @@
"components/interfaces/Auth/AuthProvidersForm/FormField.tsx": 2,
"components/interfaces/Auth/BasicAuthSettingsForm.tsx": 1,
"components/interfaces/Auth/MfaAuthSettingsForm/MfaAuthSettingsForm.tsx": 1,
"components/interfaces/Auth/OAuthApps/OAuthAppsList.tsx": 1,
"components/interfaces/Auth/OAuthApps/OAuthServerSettingsForm.tsx": 1,
"components/interfaces/Auth/PerformanceSettingsForm.tsx": 1,
"components/interfaces/Auth/Policies/PolicyEditor/PolicyDefinition.tsx": 1,
Expand All @@ -44,7 +43,6 @@
"components/interfaces/Database/Backups/PITR/TimeInput.tsx": 4,
"components/interfaces/Database/EnumeratedTypes/CreateEnumeratedTypeSidePanel.tsx": 1,
"components/interfaces/Database/Extensions/EnableExtensionModal.tsx": 1,
"components/interfaces/Database/Functions/CreateFunction/index.tsx": 1,
"components/interfaces/Database/Indexes/Indexes.tsx": 2,
"components/interfaces/Database/Schemas/SchemaGraph.tsx": 1,
"components/interfaces/DiskManagement/DiskManagementForm.tsx": 1,
Expand All @@ -54,7 +52,6 @@
"components/interfaces/Integrations/Queues/QueuesSettings.tsx": 1,
"components/interfaces/Integrations/Queues/SingleQueue/QueueSettings.tsx": 1,
"components/interfaces/Integrations/Queues/SingleQueue/SendMessageModal.tsx": 1,
"components/interfaces/Integrations/Wrappers/EditWrapperSheet.tsx": 1,
"components/interfaces/Integrations/Wrappers/WrapperDynamicColumns.tsx": 1,
"components/interfaces/Integrations/templates/StripeSyncEngine/InstallationOverview.tsx": 1,
"components/interfaces/Organization/BillingSettings/BillingCustomerData/useBillingCustomerDataForm.ts": 1,
Expand Down Expand Up @@ -92,6 +89,7 @@
"components/interfaces/Settings/Infrastructure/InfrastructureConfiguration/InstanceConfiguration.tsx": 1,
"components/interfaces/Settings/Logs/LogTable.tsx": 2,
"components/interfaces/Settings/Logs/LogsPreviewer.tsx": 2,
"components/interfaces/Settings/Logs/LogsQueryPanel.tsx": 1,
"components/interfaces/Settings/Logs/PreviewFilterPanel.tsx": 1,
"components/interfaces/SignIn/SignInPartner.tsx": 1,
"components/interfaces/Storage/AnalyticsBuckets/AnalyticsBucketDetails/CopyEnvButton.tsx": 1,
Expand Down Expand Up @@ -158,7 +156,6 @@
"pages/project/[ref]/building.tsx": 1,
"pages/project/[ref]/editor/[id].tsx": 1,
"pages/project/[ref]/integrations/index.tsx": 1,
"pages/project/[ref]/logs/explorer/index.tsx": 1,
"pages/project/[ref]/settings/jwt/legacy.tsx": 1,
"pages/project/[ref]/sql/quickstarts.tsx": 1,
"pages/project/[ref]/sql/templates.tsx": 1,
Expand Down Expand Up @@ -204,11 +201,6 @@
"pages/api/platform/projects/[ref]/billing/addons.ts": 1,
"pages/api/platform/projects/[ref]/config/index.ts": 1,
"pages/api/platform/projects/[ref]/config/postgrest.ts": 1,
"pages/api/platform/projects/[ref]/content/count.ts": 1,
"pages/api/platform/projects/[ref]/content/folders/[id].ts": 1,
"pages/api/platform/projects/[ref]/content/folders/index.ts": 1,
"pages/api/platform/projects/[ref]/content/index.ts": 1,
"pages/api/platform/projects/[ref]/content/item/[id].ts": 1,
"pages/api/platform/projects/[ref]/databases.ts": 1,
"pages/api/platform/projects/[ref]/index.ts": 1,
"pages/api/platform/projects/[ref]/infra-monitoring.ts": 1,
Expand Down Expand Up @@ -244,8 +236,6 @@
"data/table-rows/table-rows-query.ts": 1,
"data/tables/tables-query.ts": 2,
"hooks/analytics/useDbQuery.tsx": 1,
"hooks/analytics/useLogsPreview.tsx": 3,
"hooks/analytics/useProjectUsageStats.tsx": 1,
"hooks/analytics/useSingleLog.tsx": 1
},
"@typescript-eslint/no-explicit-any": {
Expand Down Expand Up @@ -277,7 +267,7 @@
"components/interfaces/Auth/AuthProvidersForm/AuthProvidersForm.types.ts": 1,
"components/interfaces/Auth/AuthProvidersForm/FormField.tsx": 4,
"components/interfaces/Auth/AuthProvidersForm/ProviderForm.tsx": 6,
"components/interfaces/Auth/AuthProvidersForm/index.tsx": 5,
"components/interfaces/Auth/AuthProvidersForm/index.tsx": 7,
"components/interfaces/Auth/AuthProvidersFormValidation.tsx": 2,
"components/interfaces/Auth/BasicAuthSettingsForm.tsx": 1,
"components/interfaces/Auth/EmailTemplates/EmailTemplates.tsx": 1,
Expand Down Expand Up @@ -333,7 +323,6 @@
"components/interfaces/Database/Publications/PublicationsTableItem.tsx": 5,
"components/interfaces/Database/Replication/DestinationPanel/DestinationForm/PublicationsComboBox.tsx": 1,
"components/interfaces/Database/Replication/ReplicationPipelineStatus/ReplicationPipelineStatus.utils.tsx": 1,
"components/interfaces/Database/Replication/RetryOptionsDropdown.tsx": 1,
"components/interfaces/Database/Replication/RowMenu.tsx": 2,
"components/interfaces/Database/Replication/UpdateVersionModal.tsx": 2,
"components/interfaces/Database/RestoreToNewProject/RestoreToNewProject.tsx": 1,
Expand All @@ -348,12 +337,10 @@
"components/interfaces/Docs/ResourceContent.tsx": 1,
"components/interfaces/Docs/RpcContent.tsx": 4,
"components/interfaces/Docs/Snippets.ts": 1,
"components/interfaces/ExplainVisualizer/ExplainVisualizer.utils.ts": 1,
"components/interfaces/Functions/CommandRender.tsx": 4,
"components/interfaces/Functions/EdgeFunctionDetails/EdgeFunctionDetails.tsx": 1,
"components/interfaces/Functions/EdgeFunctionDetails/EdgeFunctionDetails.utils.tsx": 3,
"components/interfaces/Functions/EdgeFunctionDetails/EdgeFunctionTesterSheet.tsx": 1,
"components/interfaces/Functions/EdgeFunctionSecrets/EdgeFunctionSecrets.tsx": 1,
"components/interfaces/Functions/EdgeFunctionsListItem.tsx": 2,
"components/interfaces/Functions/FunctionsNav.tsx": 1,
"components/interfaces/Home/Home.tsx": 6,
Expand All @@ -376,7 +363,6 @@
"components/interfaces/Integrations/Vault/Secrets/SecretsManagement.tsx": 1,
"components/interfaces/Integrations/Wrappers/CreateIcebergWrapperSheet.tsx": 3,
"components/interfaces/Integrations/Wrappers/CreateWrapperSheet.tsx": 6,
"components/interfaces/Integrations/Wrappers/EditWrapperSheet.tsx": 7,
"components/interfaces/Integrations/Wrappers/InputField.tsx": 1,
"components/interfaces/Integrations/Wrappers/WrapperDynamicColumns.tsx": 1,
"components/interfaces/Integrations/Wrappers/WrapperTableEditor.tsx": 7,
Expand All @@ -394,8 +380,6 @@
"components/interfaces/Organization/BillingSettings/Subscription/PlanUpdateSidePanel.tsx": 1,
"components/interfaces/Organization/BillingSettings/Subscription/SubscriptionPlanUpdateDialog.tsx": 6,
"components/interfaces/Organization/BillingSettings/Subscription/UpgradeModal.tsx": 3,
"components/interfaces/Organization/Documents/SOC2.tsx": 1,
"components/interfaces/Organization/Documents/SecurityQuestionnaire.tsx": 1,
"components/interfaces/Organization/GeneralSettings/DeleteOrganizationButton.tsx": 3,
"components/interfaces/Organization/IntegrationSettings/IntegrationSettings.tsx": 1,
"components/interfaces/Organization/IntegrationSettings/SidePanelVercelProjectLinker.tsx": 1,
Expand All @@ -413,7 +397,6 @@
"components/interfaces/ProjectAPIDocs/Content/RPC.tsx": 1,
"components/interfaces/ProjectAPIDocs/ProjectAPIDocs.constants.ts": 2,
"components/interfaces/ProjectAPIDocs/ResourceContent.tsx": 1,
"components/interfaces/ProjectCreation/DatabasePasswordInput.tsx": 1,
"components/interfaces/ProjectCreation/PostgresVersionSelector.tsx": 2,
"components/interfaces/ProjectCreation/SchemaGenerator.tsx": 1,
"components/interfaces/QueryPerformance/IndexAdvisor/EnableIndexAdvisorButton.tsx": 1,
Expand Down Expand Up @@ -466,7 +449,6 @@
"components/interfaces/Settings/General/TransferProjectPanel/TransferProjectButton.tsx": 1,
"components/interfaces/Settings/Infrastructure/InfrastructureActivity.tsx": 1,
"components/interfaces/Settings/Infrastructure/InfrastructureConfiguration/InstanceNode.tsx": 1,
"components/interfaces/Settings/Infrastructure/InfrastructureConfiguration/RestartReplicaConfirmationModal.tsx": 1,
"components/interfaces/Settings/Integrations/AWSPrivateLink/AWSPrivateLinkSection.tsx": 3,
"components/interfaces/Settings/Logs/LogSelectionRenderers/DefaultPreviewSelectionRenderer.tsx": 1,
"components/interfaces/Settings/Logs/LogTable.tsx": 3,
Expand Down Expand Up @@ -623,7 +605,6 @@
"components/ui/FilterPopover.tsx": 1,
"components/ui/Forms/Form.constants.ts": 1,
"components/ui/Logs/LogsExplorerHeader.tsx": 2,
"components/ui/PasswordStrengthBar.tsx": 4,
"components/ui/ProductMenu/ProductMenu.types.ts": 1,
"components/ui/ProjectSettings/DisplayApiSettings.tsx": 1,
"components/ui/QueryBlock/QueryBlock.tsx": 4,
Expand Down Expand Up @@ -692,8 +673,7 @@
"data/projects/project-create-mutation.ts": 1,
"data/projects/project-detail-query.ts": 2,
"data/replication/restart-pipeline-helper.ts": 2,
"data/replication/rollback-table-mutation.ts": 1,
"data/replication/use-table-reset.ts": 1,
"data/replication/rollback-tables-mutation.ts": 2,
"data/reports/database-charts.ts": 5,
"data/reports/v2/auth.config.ts": 16,
"data/reports/v2/edge-functions.config.ts": 9,
Expand All @@ -714,7 +694,6 @@
"data/table-rows/table-row-update-mutation.ts": 2,
"data/table-rows/table-rows-query.ts": 5,
"data/tables/tables-query.ts": 1,
"data/vault/vault-secret-decrypted-value-query.ts": 2,
"data/views/views-query.ts": 1,
"hooks/analytics/useDbQuery.tsx": 1,
"hooks/analytics/useFillTimeseriesSorted.ts": 3,
Expand All @@ -730,6 +709,7 @@
"hooks/ui/useHotKey.ts": 1,
"hooks/useStaticEffectEvent.ts": 1,
"instrumentation-client.ts": 5,
"lib/ai/generate-assistant-response.ts": 2,
"lib/ai/model.ts": 2,
"lib/ai/model.utils.ts": 4,
"lib/ai/test-fixtures.ts": 1,
Expand All @@ -747,16 +727,15 @@
"pages/_app.tsx": 1,
"pages/account/tokens.tsx": 1,
"pages/api/ai/feedback/rate.ts": 2,
"pages/api/ai/sql/generate-v4.ts": 3,
"pages/api/check-cname.ts": 1,
"pages/api/edge-functions/test.ts": 1,
"pages/api/integrations/stripe-sync.ts": 1,
"pages/api/platform/auth/[ref]/users/[id]/factors.ts": 1,
"pages/api/platform/database/[ref]/pooling.ts": 1,
"pages/api/platform/integrations/github/authorization.ts": 1,
"pages/api/platform/projects/[ref]/analytics/log-drains.ts": 1,
"pages/api/platform/projects/[ref]/content/count.ts": 1,
"pages/api/platform/projects/[ref]/content/index.ts": 1,
"pages/api/platform/projects/[ref]/content/item/[id].ts": 1,
"pages/api/platform/projects/[ref]/databases.ts": 1,
"pages/cli/login.tsx": 1,
"pages/integrations/vercel/[slug]/deploy-button/new-project.tsx": 1,
Expand All @@ -765,7 +744,6 @@
"pages/project/[ref]/api/index.tsx": 3,
"pages/project/[ref]/auth/templates/[templateId].tsx": 1,
"pages/project/[ref]/functions/[functionSlug]/index.tsx": 3,
"pages/project/[ref]/logs/explorer/index.tsx": 3,
"pages/project/[ref]/merge.tsx": 1,
"pages/project/[ref]/settings/log-drains.tsx": 1,
"pages/project/[ref]/storage/files/buckets/[bucketId].tsx": 1,
Expand Down
22 changes: 16 additions & 6 deletions apps/studio/components/grid/components/grid/ColumnHeader.tsx
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
import type { XYCoord } from 'dnd-core'
import { ArrowRight, Key, Link, Lock, Lightbulb } from 'lucide-react'
import { ArrowRight, Key, Lightbulb, Link, Lock } from 'lucide-react'
import { useEffect, useRef } from 'react'
import { useDrag, useDrop } from 'react-dnd'

import { getForeignKeyCascadeAction } from 'components/interfaces/TableGridEditor/SidePanelEditor/ColumnEditor/ColumnEditor.utils'
import { FOREIGN_KEY_CASCADE_ACTION } from 'data/database/database-query-constants'
import { useTableEditorTableStateSnapshot } from 'state/table-editor-table'
import { Tooltip, TooltipContent, TooltipTrigger } from 'ui'
import {
useColumnHasIndexSuggestion,
useTableIndexAdvisor,
} from '../../context/TableIndexAdvisorContext'
import { useTableEditorTableStateSnapshot } from 'state/table-editor-table'
import { Tooltip, TooltipContent, TooltipTrigger } from 'ui'
import type { ColumnHeaderProps, ColumnType, DragItem, GridForeignKey } from '../../types'
import { ColumnMenu } from '../menu/ColumnMenu'

Expand All @@ -21,6 +21,7 @@ export function ColumnHeader<R>({
isEncrypted,
format,
foreignKey,
comment,
}: ColumnHeaderProps<R>) {
const ref = useRef<HTMLDivElement>(null)
const columnIdx = column.idx
Expand Down Expand Up @@ -133,9 +134,18 @@ export function ColumnHeader<R>({
</TooltipContent>
</Tooltip>
)}
<span className="sb-grid-column-header__inner__name" title={hoverValue}>
{column.name}
</span>

<Tooltip>
<TooltipTrigger>
<span className="sb-grid-column-header__inner__name">{column.name}</span>
</TooltipTrigger>
{!!comment && (
<TooltipContent side="bottom" className="max-w-xs text-center">
{comment}
</TooltipContent>
)}
</Tooltip>

<span className="sb-grid-column-header__inner__format">
{columnFormat}
{columnFormat === 'bytea' ? ` (hex)` : ''}
Expand Down
1 change: 1 addition & 0 deletions apps/studio/components/grid/types/base.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,5 @@ export interface ColumnHeaderProps<R> extends RenderHeaderCellProps<R> {
isEncrypted: boolean | undefined
format: string
foreignKey?: GridForeignKey
comment?: string | null
}
1 change: 1 addition & 0 deletions apps/studio/components/grid/utils/gridColumns.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ export function getGridColumns(
isEncrypted={x.isEncrypted}
format={x.format}
foreignKey={x.foreignKey}
comment={x.comment}
/>
),
renderEditCell: options
Expand Down
Loading
Loading