- Notifications
You must be signed in to change notification settings - Fork927
feat: show version on login page#13033
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Changes fromall commits
File filter
Filter by extension
Conversations
Uh oh!
There was an error while loading.Please reload this page.
Jump to
Uh oh!
There was an error while loading.Please reload this page.
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,27 @@ | ||
import type { UseQueryOptions } from "react-query"; | ||
/** | ||
* cachedQuery allows the caller to only make a request a single time, and use | ||
* `initialData` if it is provided. This is particularly helpful for passing | ||
* values injected via metadata. We do this for the initial user fetch, | ||
* buildinfo, and a few others to reduce page load time. | ||
*/ | ||
export const cachedQuery = < | ||
TQueryOptions extends UseQueryOptions<TData>, | ||
TData, | ||
>( | ||
options: TQueryOptions, | ||
): TQueryOptions => | ||
// Only do this if there is initial data, otherwise it can conflict with tests. | ||
({ | ||
...(options.initialData | ||
? { | ||
cacheTime: Infinity, | ||
staleTime: Infinity, | ||
refetchOnMount: false, | ||
refetchOnReconnect: false, | ||
refetchOnWindowFocus: false, | ||
} | ||
: {}), | ||
...options, | ||
}); |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -24,7 +24,7 @@ export const AgentVersion: FC<AgentVersionProps> = ({ | ||
); | ||
if (status === agentVersionStatus.Updated) { | ||
returnnull; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others.Learn more. Just checking if we want to do this since this looks to be outside of the scope. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others.Learn more. sneaking in out of scope things is my favorite 😝 but yes, this was intentional | ||
} | ||
return ( | ||
Uh oh!
There was an error while loading.Please reload this page.