macros.api.ts 1.7 KB

123456789101112131415161718192021222324
  1. import * as Types from '#shared/graphql/types.ts';
  2. import gql from 'graphql-tag';
  3. import * as VueApolloComposable from '@vue/apollo-composable';
  4. import * as VueCompositionApi from 'vue';
  5. export type ReactiveFunction<TParam> = () => TParam;
  6. export const MacrosDocument = gql`
  7. query macros($groupId: ID!) {
  8. macros(groupId: $groupId) {
  9. id
  10. active
  11. name
  12. uxFlowNextUp
  13. }
  14. }
  15. `;
  16. export function useMacrosQuery(variables: Types.MacrosQueryVariables | VueCompositionApi.Ref<Types.MacrosQueryVariables> | ReactiveFunction<Types.MacrosQueryVariables>, options: VueApolloComposable.UseQueryOptions<Types.MacrosQuery, Types.MacrosQueryVariables> | VueCompositionApi.Ref<VueApolloComposable.UseQueryOptions<Types.MacrosQuery, Types.MacrosQueryVariables>> | ReactiveFunction<VueApolloComposable.UseQueryOptions<Types.MacrosQuery, Types.MacrosQueryVariables>> = {}) {
  17. return VueApolloComposable.useQuery<Types.MacrosQuery, Types.MacrosQueryVariables>(MacrosDocument, variables, options);
  18. }
  19. export function useMacrosLazyQuery(variables?: Types.MacrosQueryVariables | VueCompositionApi.Ref<Types.MacrosQueryVariables> | ReactiveFunction<Types.MacrosQueryVariables>, options: VueApolloComposable.UseQueryOptions<Types.MacrosQuery, Types.MacrosQueryVariables> | VueCompositionApi.Ref<VueApolloComposable.UseQueryOptions<Types.MacrosQuery, Types.MacrosQueryVariables>> | ReactiveFunction<VueApolloComposable.UseQueryOptions<Types.MacrosQuery, Types.MacrosQueryVariables>> = {}) {
  20. return VueApolloComposable.useLazyQuery<Types.MacrosQuery, Types.MacrosQueryVariables>(MacrosDocument, variables, options);
  21. }
  22. export type MacrosQueryCompositionFunctionResult = VueApolloComposable.UseQueryReturn<Types.MacrosQuery, Types.MacrosQueryVariables>;