feat: revamped spotlight (#3171)
Co-authored-by: Liyas Thomas <liyascthomas@gmail.com>
This commit is contained in:
@@ -17,7 +17,10 @@
|
||||
import { usePageHead } from "@composables/head"
|
||||
import { useI18n } from "@composables/i18n"
|
||||
import { GQLConnection } from "@helpers/GQLConnection"
|
||||
import { cloneDeep } from "lodash-es"
|
||||
import { computed, onBeforeUnmount } from "vue"
|
||||
import { defineActionHandler } from "~/helpers/actions"
|
||||
import { getGQLSession, setGQLSession } from "~/newstore/GQLSession"
|
||||
|
||||
const t = useI18n()
|
||||
|
||||
@@ -32,4 +35,14 @@ onBeforeUnmount(() => {
|
||||
gqlConn.disconnect()
|
||||
}
|
||||
})
|
||||
|
||||
defineActionHandler("gql.request.open", ({ request }) => {
|
||||
const session = getGQLSession()
|
||||
|
||||
setGQLSession({
|
||||
request: cloneDeep(request),
|
||||
schema: session.schema,
|
||||
response: session.response,
|
||||
})
|
||||
})
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user