mirror of
https://github.com/supabase/supabase.git
synced 2026-10-05 17:35:10 +03:00
remove comments
This commit is contained in:
1 parent
df8daa4b4e
commit
b3208dee64
4 files changed
+23
-6
No files matched your search
@@ -8,8 +8,6 @@ import { REFERENCES } from './Navigation.constants'
|
||||
|
||||
import { getPageType } from '~/lib/helpers'
|
||||
|
||||
// import SearchButton from '../Search/SearchButton'
|
||||
|
||||
const NavBar: FC = () => {
|
||||
const { isDarkMode, toggleTheme } = useTheme()
|
||||
const [mounted, setMounted] = useState(false)
|
||||
|
||||
@@ -17,8 +17,6 @@ import { REFERENCES } from '~/components/Navigation/Navigation.constants'
|
||||
|
||||
import { getPageType } from '~/lib/helpers'
|
||||
|
||||
// import SearchButton from './../../Search/SearchButton'
|
||||
|
||||
const TopNavBar: FC = () => {
|
||||
const { isDarkMode, toggleTheme } = useTheme()
|
||||
const [mounted, setMounted] = useState(false)
|
||||
|
||||
@@ -8,8 +8,6 @@ import { REFERENCES } from '~/components/Navigation/Navigation.constants'
|
||||
|
||||
import { getPageType } from '~/lib/helpers'
|
||||
|
||||
// import SearchButton from '~/components/Search/SearchButton'
|
||||
|
||||
const TopNavBarRef: FC = () => {
|
||||
const { isDarkMode, toggleTheme } = useTheme()
|
||||
const [mounted, setMounted] = useState(false)
|
||||
|
||||
@@ -141,6 +141,29 @@ const AiCommand = () => {
|
||||
setHasClippyError(false)
|
||||
setIsLoading(true)
|
||||
|
||||
let queryToSend = query
|
||||
|
||||
switch (currentPage) {
|
||||
case COMMAND_ROUTES.AI:
|
||||
queryToSend = query
|
||||
break
|
||||
case COMMAND_ROUTES.AI_ASK_ANYTHING:
|
||||
queryToSend = query
|
||||
break
|
||||
|
||||
case COMMAND_ROUTES.AI_RLS_POLICY:
|
||||
queryToSend = `Given this table schema:
|
||||
|
||||
Schema STRIPE has tables:
|
||||
CHARGE with columns [ID, AMOUNT, CREATED, CURRENCY, CUSTOMER_ID]
|
||||
CUSTOMER with columns [ID, NAME, CREATED, SHIPPING_ADDRESS_STATE]
|
||||
|
||||
\n\nAnswer with only an RLS policy in SQL, no other text: ${query}`
|
||||
break
|
||||
default:
|
||||
break
|
||||
}
|
||||
|
||||
const eventSource = new SSE(`${edgeFunctionUrl}/clippy-search`, {
|
||||
headers: {
|
||||
apikey: process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY ?? '',
|
||||
|
||||
Reference in new issue
Block a user