userUpdates.api.ts 1.5 KB

123456789101112131415161718192021
  1. import * as Types from '#shared/graphql/types.ts';
  2. import gql from 'graphql-tag';
  3. import { UserDetailAttributesFragmentDoc } from '../fragments/userDetailAttributes.api';
  4. import * as VueApolloComposable from '@vue/apollo-composable';
  5. import * as VueCompositionApi from 'vue';
  6. export type ReactiveFunction<TParam> = () => TParam;
  7. export const UserUpdatesDocument = gql`
  8. subscription userUpdates($userId: ID!, $secondaryOrganizationsCount: Int) {
  9. userUpdates(userId: $userId) {
  10. user {
  11. ...userDetailAttributes
  12. }
  13. }
  14. }
  15. ${UserDetailAttributesFragmentDoc}`;
  16. export function useUserUpdatesSubscription(variables: Types.UserUpdatesSubscriptionVariables | VueCompositionApi.Ref<Types.UserUpdatesSubscriptionVariables> | ReactiveFunction<Types.UserUpdatesSubscriptionVariables>, options: VueApolloComposable.UseSubscriptionOptions<Types.UserUpdatesSubscription, Types.UserUpdatesSubscriptionVariables> | VueCompositionApi.Ref<VueApolloComposable.UseSubscriptionOptions<Types.UserUpdatesSubscription, Types.UserUpdatesSubscriptionVariables>> | ReactiveFunction<VueApolloComposable.UseSubscriptionOptions<Types.UserUpdatesSubscription, Types.UserUpdatesSubscriptionVariables>> = {}) {
  17. return VueApolloComposable.useSubscription<Types.UserUpdatesSubscription, Types.UserUpdatesSubscriptionVariables>(UserUpdatesDocument, variables, options);
  18. }
  19. export type UserUpdatesSubscriptionCompositionFunctionResult = VueApolloComposable.UseSubscriptionReturn<Types.UserUpdatesSubscription, Types.UserUpdatesSubscriptionVariables>;