• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

clippingkk / web / #1022

10 Jan 2025 05:30PM UTC coverage: 0.769% (+0.004%) from 0.765%
#1022

push

AnnatarHe
fix(lint): fix lint issue

31 of 355 branches covered (8.73%)

Branch coverage included in aggregate %.

11 of 1012 new or added lines in 117 files covered. (1.09%)

5 existing lines in 5 files now uncovered.

156 of 23962 relevant lines covered (0.65%)

12.11 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/app/auth/github/content.tsx
1
'use client'
×
2
import React, { useEffect } from 'react'
×
NEW
3
import { useAuthSuccessed } from '@/hooks/hooks'
×
NEW
4
import { useGithubLoginLazyQuery } from '@/schema/generated'
×
NEW
5
import LoadingIcon from '@/components/icons/loading.svg'
×
6

×
7
type GithubOAuthContentProps = {
×
8
  code: string
×
9
}
×
10

×
11
function GithubOAuthContent(props: GithubOAuthContentProps) {
×
12
  const { code } = props
×
13
  const [exec, resp] = useGithubLoginLazyQuery()
×
14

×
15
  useAuthSuccessed(resp.called, resp.loading, resp.error, resp.data?.githubAuth)
×
16
  useEffect(() => {
×
17
    if (!code) {
×
18
      console.log('no code')
×
19
      // TODO: redirect
×
20
      return
×
21
    }
×
22

×
23
    exec({
×
24
      variables: {
×
25
        code
×
26
      }
×
27
    })
×
28
  }, [code])
×
29

×
30
  return (
×
31
    <div className='p-10 bg-gray-300 bg-opacity-40 rounded text-4xl backdrop-blur-lg'>
×
32
      {resp.loading && (
×
33
        <LoadingIcon className='animate-spin' />
×
34
      )}
×
35
      {resp.error && (
×
36
        <div className='max-w-sm h-96 overflow-y-auto'>{resp.error.message}</div>
×
37
      )}
×
38
    </div>
×
39
  )
×
40
}
×
41

×
42
export default GithubOAuthContent
×
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc