mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
core&ui: drop graphql apis
This commit is contained in:
1 parent
0f7961d675
commit
6e16d03f67
52 files changed
+485
-583
No files matched your search
@@ -4,7 +4,7 @@ import ReactDOM from 'react-dom/client';
|
||||
import { STATUS_CODES } from 'vj/constant/record';
|
||||
import { AutoloadPage } from 'vj/misc/Page';
|
||||
import {
|
||||
api, gql, i18n, request,
|
||||
api, i18n, request,
|
||||
} from 'vj/utils';
|
||||
|
||||
export default new AutoloadPage('omnibar', () => {
|
||||
@@ -92,14 +92,7 @@ export default new AutoloadPage('omnibar', () => {
|
||||
setSearching?.(true);
|
||||
[{ pdocs, psdict }, udocs] = await Promise.all([
|
||||
request.get(`/d/${UiContext.domainId}/p`, { q: query, limit: 10 }),
|
||||
api(gql`
|
||||
users(search: ${query}) {
|
||||
_id
|
||||
uname
|
||||
displayName
|
||||
avatarUrl
|
||||
}
|
||||
`, ['data', 'users']),
|
||||
api('users', { search: query }, ['_id', 'uname', 'displayName', 'avatarUrl']),
|
||||
]);
|
||||
setSearching?.(false);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user