Skip to content

:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.

feat(data-warehouse): add copy view name to sql editor view menu (#61933)

Annika 🦔db829e4e33ef
diff --git a/frontend/src/scenes/data-warehouse/editor/sidebar/QueryDatabase.tsx b/frontend/src/scenes/data-warehouse/editor/sidebar/QueryDatabase.tsx
index 9aaad348e7f7..196bb5316bb1 100644
--- a/frontend/src/scenes/data-warehouse/editor/sidebar/QueryDatabase.tsx
+++ b/frontend/src/scenes/data-warehouse/editor/sidebar/QueryDatabase.tsx
@@ -785,6 +785,17 @@ export const QueryDatabase = ({
</ButtonPrimitive>
</DropdownMenuItem>
) : null}
+ {item.record.type !== 'endpoint' ? (
+ <DropdownMenuItem
+ asChild
+ onClick={(e) => {
+ e.stopPropagation()
+ void copyToClipboard(item.name)
+ }}
+ >
+ <ButtonPrimitive menuItem>Copy view name</ButtonPrimitive>
+ </DropdownMenuItem>
+ ) : null}
</DropdownMenuGroup>
)
}