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

jcubic / 10xDevs / 18543950048

15 Oct 2025 10:05PM UTC coverage: 20.079% (-2.9%) from 23.014%
18543950048

push

github

jcubic
implement the rest of the MVP

66 of 101 branches covered (65.35%)

Branch coverage included in aggregate %.

3 of 345 new or added lines in 6 files covered. (0.87%)

2 existing lines in 1 file now uncovered.

440 of 2419 relevant lines covered (18.19%)

2.3 hits per line

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

2.13
/src/components/notes/TopNavigationBar.tsx
1
'use client';
1✔
2

3
import { Flex, Button, Text, Box } from '@chakra-ui/react';
×
NEW
4
import { FiSettings } from 'react-icons/fi';
×
NEW
5
import { useRouter } from 'next/navigation';
×
UNCOV
6
import { signOutAction } from '@/app/actions/auth';
×
7

8
interface TopNavigationBarProps {
9
  hasUnsavedChanges: boolean;
10
  onLogout: () => void;
11
}
12

13
export default function TopNavigationBar({
×
14
  hasUnsavedChanges,
×
15
  onLogout
×
16
}: TopNavigationBarProps) {
×
NEW
17
  const router = useRouter();
×
18

19
  const handleLogout = async () => {
×
20
    if (hasUnsavedChanges) {
×
21
      const confirm = window.confirm(
×
22
        'You have unsaved changes. Are you sure you want to logout?'
×
23
      );
×
24
      if (!confirm) return;
×
25
    }
×
26

27
    try {
×
28
      await signOutAction();
×
29
      onLogout();
×
30
    } catch (error) {
×
31
      console.error('Logout failed:', error);
×
32
    }
×
33
  };
×
34

35
  return (
×
36
    <Box as="header" borderBottom="1px solid" borderColor="border" bg="bg" px={4} py={2}>
×
37
      <Flex justify="space-between" align="center">
×
38
        <Text fontSize="lg" fontWeight="semibold">
×
39
          SNApp
40
        </Text>
×
41

42
        <Flex align="center" gap={4}>
×
43
          {hasUnsavedChanges && (
×
44
            <Text fontSize="sm" color="orange.500">
×
45
              Unsaved changes
46
            </Text>
×
47
          )}
48

NEW
49
          <Button
×
NEW
50
            p={3}
×
NEW
51
            size="sm"
×
NEW
52
            variant="ghost"
×
NEW
53
            onClick={() => router.push('/settings')}
×
NEW
54
            aria-label="Settings"
×
55
          >
NEW
56
            <FiSettings />
×
NEW
57
          </Button>
×
58

UNCOV
59
          <Button p={3} size="sm" variant="ghost" onClick={handleLogout}>
×
60
            Logout
61
          </Button>
×
62
        </Flex>
×
63
      </Flex>
×
64
    </Box>
×
65
  );
66
}
×
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