Skip to content

Commit

Permalink
Feat 6.0.0 (#323)
Browse files Browse the repository at this point in the history
Put makeup on the pig
  • Loading branch information
bjarneo authored Oct 29, 2024
1 parent c7924bd commit 0bb041b
Show file tree
Hide file tree
Showing 44 changed files with 8,815 additions and 12,516 deletions.
6 changes: 0 additions & 6 deletions .github/workflows/deploy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,6 @@ jobs:
- name: Setup deploy file
run: echo ${{ secrets.KAMAL_DEPLOY_YAML }} | base64 -d > config/deploy.yml

- name: Setup Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: 3.3.0
bundler-cache: true

- name: Install Kamal
run: gem install kamal

Expand Down
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,8 @@ Hemmelig strongly advice you to ue the tagged docker images as the main branch w
Supported docker platforms: `amd/64`, `arm/64`.

- hemmeligapp/hemmelig:latest (Is created on each version release)
- hemmeligapp/hemmelig:v5.19.4 see [tags](https://github.com/HemmeligOrg/Hemmelig.app/tags) for all version
- hemmeligapp/hemmelig:v5 (Is created on each version release for the major version)
- hemmeligapp/hemmelig:v5.19.28 see [tags](https://github.com/HemmeligOrg/Hemmelig.app/tags) for all version
- hemmeligapp/hemmelig:weekly (pushed every week on Friday)
- hemmeligapp/hemmelig:daily

Expand Down
129 changes: 83 additions & 46 deletions client/admin-shell.jsx
Original file line number Diff line number Diff line change
@@ -1,61 +1,98 @@
import { Anchor, AppShell, Group, Header, Navbar, useMantineTheme } from '@mantine/core';
import { IconMenu2 } from '@tabler/icons';
import { useState } from 'react';
import { Link, Outlet } from 'react-router-dom';

import Logo from './components/header/logo';
import Nav from './components/header/nav';
import logoStyles from './components/header/style.module.css';
import MainLinks from './components/settings/main-links';
import SecondaryLinks from './components/settings/secondary-links';

const AdminShell = () => {
const theme = useMantineTheme();
const [isSidebarOpen, setIsSidebarOpen] = useState(false);

return (
<AppShell
padding="md"
fixed={false}
navbar={
<Navbar
width={{ base: 300 }}
height={500}
p="xs"
sx={(theme) => ({
backgroundColor: theme.colors.dark[8],
})}
>
<Navbar.Section grow mt="xs">
<MainLinks />
</Navbar.Section>
<Navbar.Section grow mt="xs">
<SecondaryLinks />
</Navbar.Section>
</Navbar>
}
header={
<Header
height={75}
style={{ zIndex: 1100 }}
sx={(theme) => ({
backgroundColor: theme.colors.dark[8],
})}
>
<Group sx={{ height: '100%', paddingTop: '5px' }} px={20} position="apart">
<Anchor component={Link} to="/">
<Logo className={logoStyles.logo} />
</Anchor>
<div className="min-h-screen bg-gray-900">
{/* Header */}
<header
className="fixed top-0 left-0 right-0 h-[75px] bg-gray-800/95 backdrop-blur-sm
border-b border-gray-700/50 z-50"
>
<div className="h-full px-5 flex items-center justify-between">
{/* Logo */}
<Link to="/" className="flex items-center">
<Logo className="w-10 h-10 [&>g]:fill-gray-100" />
</Link>

{/* Mobile Menu Button */}
<button
onClick={() => setIsSidebarOpen(!isSidebarOpen)}
className="lg:hidden p-2 rounded-md text-gray-400 hover:text-white
hover:bg-gray-700 focus:outline-none focus:ring-2
focus:ring-gray-600 transition-colors"
>
<IconMenu2 size={24} />
</button>

{/* Desktop Navigation */}
<div className="hidden lg:block">
<Nav />
</Group>
</Header>
}
styles={{
main: {
background: theme.colors.dark[8],
},
}}
>
<Outlet />
</AppShell>
</div>
</div>
</header>

{/* Sidebar */}
<aside
className={`fixed top-[75px] left-0 h-[calc(100vh-75px)] w-[280px] bg-gray-800/95
backdrop-blur-sm border-r border-gray-700/50 transform transition-transform
duration-300 ease-in-out lg:translate-x-0 z-40
${isSidebarOpen ? 'translate-x-0' : '-translate-x-full'}`}
>
<div className="h-full flex flex-col p-4">
{/* Scrollable area for links */}
<div
className="flex-1 overflow-y-auto space-y-6 scrollbar-thin
scrollbar-thumb-gray-700 scrollbar-track-transparent"
>
{/* Main Links Section */}
<div>
<h2 className="px-3 mb-2 text-xs font-semibold text-gray-400 uppercase tracking-wider">
Main Navigation
</h2>
<MainLinks />
</div>

{/* Secondary Links Section */}
<div>
<h2 className="px-3 mb-2 text-xs font-semibold text-gray-400 uppercase tracking-wider">
Other Links
</h2>
<SecondaryLinks />
</div>
</div>

{/* Version or Additional Info (optional) */}
<div className="pt-4 mt-4 border-t border-gray-700/50">
<div className="px-3 text-xs text-gray-500">Hemmelig</div>
</div>
</div>
</aside>

{/* Main Content */}
<main
className={`min-h-[calc(100vh-75px)] transition-all duration-300 ease-in-out
lg:ml-[280px] mt-[75px] p-6`}
>
<Outlet />
</main>

{/* Overlay for mobile sidebar */}
{isSidebarOpen && (
<div
className="fixed inset-0 bg-black/50 backdrop-blur-sm z-30 lg:hidden"
onClick={() => setIsSidebarOpen(false)}
/>
)}
</div>
);
};

Expand Down
166 changes: 69 additions & 97 deletions client/app-shell.jsx
Original file line number Diff line number Diff line change
@@ -1,109 +1,81 @@
import { Anchor, AppShell, Footer, Group, Header, Text, useMantineTheme } from '@mantine/core';
import { Link, Outlet } from 'react-router-dom';

import { useMediaQuery } from '@mantine/hooks';
import { useTranslation } from 'react-i18next';

import { Link, Outlet } from 'react-router-dom';
import HeaderContent from './components/header';

const ApplicationShell = () => {
const { t } = useTranslation();
const isMobile = useMediaQuery('(max-width: 768px)');
const theme = useMantineTheme();

return (
<AppShell
styles={{
main: {
background: theme.colors.dark[8],
},
}}
navbarOffsetBreakpoint="sm"
footer={
<Footer
height={45}
p="xs"
sx={(theme) => ({
backgroundColor: theme.colors.dark[8],
})}
>
<Group position="center" spacing="xs">
{!isMobile && (
<>
<Anchor
component={Link}
to="/account"
color="dimmed"
size="xs"
transform="uppercase"
>
{t('account.home.title')}
</Anchor>
|
<Anchor
component={Link}
to="/privacy"
color="dimmed"
size="xs"
transform="uppercase"
>
{t('privacy.title')}
</Anchor>
|
<Anchor
component={Link}
to="/terms"
color="dimmed"
size="xs"
transform="uppercase"
>
{t('terms.title')}
</Anchor>
|
</>
)}
<Anchor
rel="noreferrer"
href="https://lite.hemmelig.app"
color="dimmed"
size="xs"
transform="uppercase"
<div className="min-h-screen flex flex-col bg-gray-900">
{/* Header */}
<header className="h-[75px] z-50 bg-gray-900 border-b border-gray-800">
<HeaderContent />
</header>

{/* Main Content */}
<main className="flex-grow">
<Outlet />
</main>

{/* Footer */}
<footer className="h-[45px] bg-gray-900 border-t border-gray-800">
<div className="h-full flex items-center justify-center gap-2">
{/* Desktop-only links */}
<div className="hidden md:flex md:items-center md:gap-2">
<Link
to="/account"
className="text-xs text-gray-400 hover:text-gray-200 uppercase transition-colors"
>
Lite version
</Anchor>
|
<Anchor
rel="noreferrer"
href="https://github.com/HemmeligOrg/Hemmelig.app"
color="dimmed"
size="xs"
transform="uppercase"
{t('account.home.title')}
</Link>

<span className="text-gray-600">|</span>

<Link
to="/privacy"
className="text-xs text-gray-400 hover:text-gray-200 uppercase transition-colors"
>
<Text size="xs">
<span role="img" aria-label="a heart">
❤️
</span>{' '}
By Hemmelig
</Text>
</Anchor>
</Group>
</Footer>
}
header={
<Header
height={75}
style={{ zIndex: 100 }}
p="xs"
sx={(theme) => ({
backgroundColor: theme.colors.dark[8],
})}
>
<HeaderContent />
</Header>
}
>
<Outlet />
</AppShell>
{t('privacy.title')}
</Link>

<span className="text-gray-600">|</span>

<Link
to="/terms"
className="text-xs text-gray-400 hover:text-gray-200 uppercase transition-colors"
>
{t('terms.title')}
</Link>

<span className="text-gray-600">|</span>
</div>

{/* Always visible links */}
<a
href="https://lite.hemmelig.app"
rel="noreferrer"
className="text-xs text-gray-400 hover:text-gray-200 uppercase transition-colors"
>
Lite version
</a>

<span className="text-gray-600">|</span>

<a
href="https://github.com/HemmeligOrg/Hemmelig.app"
rel="noreferrer"
className="text-xs text-gray-400 hover:text-gray-200 uppercase transition-colors"
>
<span className="text-xs">
<span role="img" aria-label="a heart">
❤️
</span>{' '}
By Hemmelig
</span>
</a>
</div>
</footer>
</div>
);
};

Expand Down
Loading

0 comments on commit 0bb041b

Please sign in to comment.