The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.
TypeScript aialternativeauthdatabasedenoembeddingsexamplefirebasenextjsoauth2pgvectorpostgispostgrespostgresqlpostgrestrealtimesupabasevectorswebsockets
remove isCustomQuery usage
TzeYiing1b8837b30cbe
diff --git a/studio/components/interfaces/Settings/Logs/LogsPreviewer.tsx b/studio/components/interfaces/Settings/Logs/LogsPreviewer.tsxindex caa673097f5..bcfc5ce385e 100644--- a/studio/components/interfaces/Settings/Logs/LogsPreviewer.tsx+++ b/studio/components/interfaces/Settings/Logs/LogsPreviewer.tsx@@ -136,7 +136,6 @@ export const LogsPreviewer: React.FC<Props> = ({ projectRef, queryType, override<PreviewFilterPanelisShowingEventChart={showChart}onToggleEventChart={() => setShowChart(!showChart)}- isCustomQuery={false}isLoading={isLoading}newCount={newCount}templates={TEMPLATES.filter(diff --git a/studio/components/interfaces/Settings/Logs/PreviewFilterPanel.tsx b/studio/components/interfaces/Settings/Logs/PreviewFilterPanel.tsxindex 02fa7c7161f..f15ddeccaa8 100644--- a/studio/components/interfaces/Settings/Logs/PreviewFilterPanel.tsx+++ b/studio/components/interfaces/Settings/Logs/PreviewFilterPanel.tsx@@ -4,12 +4,8 @@ import {Input,Typography,IconRefreshCw,- IconX,IconSearch,- IconClock,- Popover,IconExternalLink,- Toggle,IconEye,IconEyeOff,} from '@supabase/ui'@@ -26,11 +22,10 @@ interface Props {defaultFromValue?: stringtemplates?: anyisLoading: boolean- isCustomQuery: booleannewCount: numberonRefresh?: () => voidonSearch?: LogSearchCallback- onCustomClick?: () => void+ onExploreClick?: () => voidonSelectTemplate: (template: LogTemplate) => voidisShowingEventChart: booleanonToggleEventChart: () => void@@ -47,14 +42,13 @@ dayjs.extend(utc)*/const PreviewFilterPanel: FC<Props> = ({isLoading,- isCustomQuery,newCount,onRefresh,onSearch = () => {},defaultSearchValue = '',defaultToValue = '',defaultFromValue = '',- onCustomClick,+ onExploreClick,dispatchWhereFilters,whereFilters: filters,table,@@ -83,38 +77,36 @@ const PreviewFilterPanel: FC<Props> = ({}}, [defaultToValue])- const RefreshButton = () => {- return !isCustomQuery ? (- <Button- type="default"- icon={- <div className="relative">- {newCount > 0 && (- <div- className={[- 'absolute flex items-center justify-center -top-3 right-3',- 'h-4 w-4 z-50',- ].join(' ')}- >- <div className="absolute z-20">- <Typography.Text style={{ fontSize: '0.6rem' }} className="opacity-80">- {newCount}- </Typography.Text>- </div>- <div className="bg-green-800 rounded-full w-full h-full animate-ping opacity-60"></div>- <div className="absolute z-60 top-0 right-0 bg-green-900 opacity-80 rounded-full w-full h-full"></div>+ const RefreshButton = () => (+ <Button+ type="default"+ icon={+ <div className="relative">+ {newCount > 0 && (+ <div+ className={[+ 'absolute flex items-center justify-center -top-3 right-3',+ 'h-4 w-4 z-50',+ ].join(' ')}+ >+ <div className="absolute z-20">+ <Typography.Text style={{ fontSize: '0.6rem' }} className="opacity-80">+ {newCount}+ </Typography.Text></div>- )}- <IconRefreshCw size={10} />- </div>- }- loading={isLoading}- onClick={onRefresh}- >- Refresh- </Button>- ) : null- }+ <div className="bg-green-800 rounded-full w-full h-full animate-ping opacity-60"></div>+ <div className="absolute z-60 top-0 right-0 bg-green-900 opacity-80 rounded-full w-full h-full"></div>+ </div>+ )}+ <IconRefreshCw size={10} />+ </div>+ }+ loading={isLoading}+ onClick={onRefresh}+ >+ Refresh+ </Button>+ )const handleToChange = (e: React.ChangeEvent<HTMLInputElement>) => {const value = e.target.value@@ -135,14 +127,6 @@ const PreviewFilterPanel: FC<Props> = ({}}- const handleReset = async () => {- setTo({ value: '', error: '' })- setFrom({ value: '', error: '' })- const value = dayjs().utc().toISOString()- setDefaultTimestamp(value)- onSearch({ query: search, to: '', from: '' })- }-const handleSearch = () => onSearch({ query: search, to: to.value, from: from.value })return (@@ -221,7 +205,7 @@ const PreviewFilterPanel: FC<Props> = ({</Button></div></div>- <Button type="secondary" onClick={onCustomClick} iconRight={<IconExternalLink size={10} />}>+ <Button type="secondary" onClick={onExploreClick} iconRight={<IconExternalLink size={10} />}>Explore via query</Button></div>