style: normalize frontend formatting and line endings
Lint / Lint (push) Successful in 1m2s
Security / Secrets (gitleaks) (push) Successful in 1m15s
Security / Dependencies (Trivy) (push) Successful in 1m14s
Security / Code (Semgrep) (push) Successful in 2m6s
Tests / Dashboard checks (push) Failing after 1m10s
Tests / Go backend (push) Successful in 3m14s
Docker / Docker Build & Push (push) Successful in 9m55s
Lint / Lint (push) Successful in 1m2s
Security / Secrets (gitleaks) (push) Successful in 1m15s
Security / Dependencies (Trivy) (push) Successful in 1m14s
Security / Code (Semgrep) (push) Successful in 2m6s
Tests / Dashboard checks (push) Failing after 1m10s
Tests / Go backend (push) Successful in 3m14s
Docker / Docker Build & Push (push) Successful in 9m55s
This commit is contained in:
1 parent
cf468ed833
commit
a8b79ffd1b
5 files changed
+186
-194
No files matched your search
+124
-124
@@ -1,127 +1,127 @@
|
|||||||
@import 'tailwindcss';
|
@import 'tailwindcss';
|
||||||
@import 'tw-animate-css';
|
@import 'tw-animate-css';
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Semantic color tokens, one block per theme. Components should only ever
|
* Semantic color tokens, one block per theme. Components should only ever
|
||||||
* use the Tailwind utilities mapped below (bg-bg, text-fg, bg-surface, etc.),
|
* use the Tailwind utilities mapped below (bg-bg, text-fg, bg-surface, etc.),
|
||||||
* never the raw values, so switching theme/data-attribute is all it takes.
|
* never the raw values, so switching theme/data-attribute is all it takes.
|
||||||
*/
|
*/
|
||||||
:root,
|
:root,
|
||||||
[data-theme='dark'] {
|
[data-theme='dark'] {
|
||||||
--color-bg: var(--sc-bg);
|
--color-bg: var(--sc-bg);
|
||||||
--color-surface: var(--sc-surface);
|
--color-surface: var(--sc-surface);
|
||||||
--color-surface-hover: var(--sc-surface-hover);
|
--color-surface-hover: var(--sc-surface-hover);
|
||||||
--color-border: var(--sc-border);
|
--color-border: var(--sc-border);
|
||||||
--color-fg: var(--sc-fg);
|
--color-fg: var(--sc-fg);
|
||||||
--color-muted-fg: var(--sc-muted-fg);
|
--color-muted-fg: var(--sc-muted-fg);
|
||||||
--color-primary: #3b82f6;
|
--color-primary: #3b82f6;
|
||||||
--color-primary-fg: #04122e;
|
--color-primary-fg: #04122e;
|
||||||
--color-secondary: var(--sc-secondary);
|
--color-secondary: var(--sc-secondary);
|
||||||
--color-secondary-fg: var(--sc-secondary-fg);
|
--color-secondary-fg: var(--sc-secondary-fg);
|
||||||
--color-accent: #3b82f6;
|
--color-accent: #3b82f6;
|
||||||
--color-accent-fg: #04122e;
|
--color-accent-fg: #04122e;
|
||||||
--color-danger: var(--sc-danger);
|
--color-danger: var(--sc-danger);
|
||||||
--color-danger-fg: var(--sc-danger-fg);
|
--color-danger-fg: var(--sc-danger-fg);
|
||||||
--color-success: var(--sc-success);
|
--color-success: var(--sc-success);
|
||||||
--color-success-fg: var(--sc-success-fg);
|
--color-success-fg: var(--sc-success-fg);
|
||||||
--color-warning: var(--sc-warning);
|
--color-warning: var(--sc-warning);
|
||||||
--color-warning-fg: var(--sc-warning-fg);
|
--color-warning-fg: var(--sc-warning-fg);
|
||||||
--color-ring: #60a5fa;
|
--color-ring: #60a5fa;
|
||||||
color-scheme: dark;
|
color-scheme: dark;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Bridge onto the shared component library's own --sc-* tokens so parts of the app built from
|
/* Bridge onto the shared component library's own --sc-* tokens so parts of the app built from
|
||||||
@gabriel20xx/web-ui components outside AppShell's .collabtable-shell scope (AuthPage, the
|
@gabriel20xx/web-ui components outside AppShell's .collabtable-shell scope (AuthPage, the
|
||||||
Settings/Profile dialogs) carry this project's brand color too, instead of falling back to the
|
Settings/Profile dialogs) carry this project's brand color too, instead of falling back to the
|
||||||
shared library's generic default blue. `html` raises specificity above shared-styles.css's
|
shared library's generic default blue. `html` raises specificity above shared-styles.css's
|
||||||
plain `:root`/`[data-theme]` rules so this wins regardless of stylesheet import order. */
|
plain `:root`/`[data-theme]` rules so this wins regardless of stylesheet import order. */
|
||||||
html:root,
|
html:root,
|
||||||
html[data-theme='dark'] {
|
html[data-theme='dark'] {
|
||||||
--sc-primary: var(--color-primary);
|
--sc-primary: var(--color-primary);
|
||||||
--sc-primary-hover: var(--color-secondary);
|
--sc-primary-hover: var(--color-secondary);
|
||||||
--sc-primary-fg: var(--color-primary-fg);
|
--sc-primary-fg: var(--color-primary-fg);
|
||||||
--sc-accent: var(--color-accent);
|
--sc-accent: var(--color-accent);
|
||||||
--sc-accent-fg: var(--color-accent-fg);
|
--sc-accent-fg: var(--color-accent-fg);
|
||||||
--sc-ring: var(--color-ring);
|
--sc-ring: var(--color-ring);
|
||||||
}
|
}
|
||||||
|
|
||||||
[data-theme='light'] {
|
[data-theme='light'] {
|
||||||
--color-bg: var(--sc-bg);
|
--color-bg: var(--sc-bg);
|
||||||
--color-surface: var(--sc-surface);
|
--color-surface: var(--sc-surface);
|
||||||
--color-surface-hover: var(--sc-surface-hover);
|
--color-surface-hover: var(--sc-surface-hover);
|
||||||
--color-border: var(--sc-border);
|
--color-border: var(--sc-border);
|
||||||
--color-fg: var(--sc-fg);
|
--color-fg: var(--sc-fg);
|
||||||
--color-muted-fg: var(--sc-muted-fg);
|
--color-muted-fg: var(--sc-muted-fg);
|
||||||
--color-primary: #2563eb;
|
--color-primary: #2563eb;
|
||||||
--color-primary-fg: #ffffff;
|
--color-primary-fg: #ffffff;
|
||||||
--color-secondary: var(--sc-secondary);
|
--color-secondary: var(--sc-secondary);
|
||||||
--color-secondary-fg: var(--sc-secondary-fg);
|
--color-secondary-fg: var(--sc-secondary-fg);
|
||||||
--color-accent: #2563eb;
|
--color-accent: #2563eb;
|
||||||
--color-accent-fg: #ffffff;
|
--color-accent-fg: #ffffff;
|
||||||
--color-danger: var(--sc-danger);
|
--color-danger: var(--sc-danger);
|
||||||
--color-danger-fg: var(--sc-danger-fg);
|
--color-danger-fg: var(--sc-danger-fg);
|
||||||
--color-success: var(--sc-success);
|
--color-success: var(--sc-success);
|
||||||
--color-success-fg: var(--sc-success-fg);
|
--color-success-fg: var(--sc-success-fg);
|
||||||
--color-warning: var(--sc-warning);
|
--color-warning: var(--sc-warning);
|
||||||
--color-warning-fg: var(--sc-warning-fg);
|
--color-warning-fg: var(--sc-warning-fg);
|
||||||
--color-ring: #2563eb;
|
--color-ring: #2563eb;
|
||||||
color-scheme: light;
|
color-scheme: light;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* See the dark-theme bridge above for why this exists and why `html` is needed. */
|
/* See the dark-theme bridge above for why this exists and why `html` is needed. */
|
||||||
html[data-theme='light'] {
|
html[data-theme='light'] {
|
||||||
--sc-primary: var(--color-primary);
|
--sc-primary: var(--color-primary);
|
||||||
--sc-primary-hover: var(--color-secondary);
|
--sc-primary-hover: var(--color-secondary);
|
||||||
--sc-primary-fg: var(--color-primary-fg);
|
--sc-primary-fg: var(--color-primary-fg);
|
||||||
--sc-accent: var(--color-accent);
|
--sc-accent: var(--color-accent);
|
||||||
--sc-accent-fg: var(--color-accent-fg);
|
--sc-accent-fg: var(--color-accent-fg);
|
||||||
--sc-ring: var(--color-ring);
|
--sc-ring: var(--color-ring);
|
||||||
}
|
}
|
||||||
|
|
||||||
@theme inline {
|
@theme inline {
|
||||||
--color-bg: var(--color-bg);
|
--color-bg: var(--color-bg);
|
||||||
--color-surface: var(--color-surface);
|
--color-surface: var(--color-surface);
|
||||||
--color-surface-hover: var(--color-surface-hover);
|
--color-surface-hover: var(--color-surface-hover);
|
||||||
--color-border: var(--color-border);
|
--color-border: var(--color-border);
|
||||||
--color-fg: var(--color-fg);
|
--color-fg: var(--color-fg);
|
||||||
--color-muted-fg: var(--color-muted-fg);
|
--color-muted-fg: var(--color-muted-fg);
|
||||||
--color-primary: var(--color-primary);
|
--color-primary: var(--color-primary);
|
||||||
--color-primary-fg: var(--color-primary-fg);
|
--color-primary-fg: var(--color-primary-fg);
|
||||||
--color-secondary: var(--color-secondary);
|
--color-secondary: var(--color-secondary);
|
||||||
--color-secondary-fg: var(--color-secondary-fg);
|
--color-secondary-fg: var(--color-secondary-fg);
|
||||||
--color-accent: var(--color-accent);
|
--color-accent: var(--color-accent);
|
||||||
--color-accent-fg: var(--color-accent-fg);
|
--color-accent-fg: var(--color-accent-fg);
|
||||||
--color-danger: var(--color-danger);
|
--color-danger: var(--color-danger);
|
||||||
--color-danger-fg: var(--color-danger-fg);
|
--color-danger-fg: var(--color-danger-fg);
|
||||||
--color-success: var(--color-success);
|
--color-success: var(--color-success);
|
||||||
--color-success-fg: var(--color-success-fg);
|
--color-success-fg: var(--color-success-fg);
|
||||||
--color-warning: var(--color-warning);
|
--color-warning: var(--color-warning);
|
||||||
--color-warning-fg: var(--color-warning-fg);
|
--color-warning-fg: var(--color-warning-fg);
|
||||||
--color-ring: var(--color-ring);
|
--color-ring: var(--color-ring);
|
||||||
--font-sans: 'Inter', ui-sans-serif, system-ui, -apple-system, sans-serif;
|
--font-sans: 'Inter', ui-sans-serif, system-ui, -apple-system, sans-serif;
|
||||||
}
|
}
|
||||||
|
|
||||||
html,
|
html,
|
||||||
body {
|
body {
|
||||||
height: 100%;
|
height: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
body {
|
body {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
background-color: var(--color-bg);
|
background-color: var(--color-bg);
|
||||||
color: var(--color-fg);
|
color: var(--color-fg);
|
||||||
font-family: var(--font-sans);
|
font-family: var(--font-sans);
|
||||||
transition:
|
transition:
|
||||||
background-color 150ms ease,
|
background-color 150ms ease,
|
||||||
color 150ms ease;
|
color 150ms ease;
|
||||||
}
|
}
|
||||||
|
|
||||||
::selection {
|
::selection {
|
||||||
background-color: var(--color-primary);
|
background-color: var(--color-primary);
|
||||||
color: var(--color-primary-fg);
|
color: var(--color-primary-fg);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Wide-page setting: lifts the shared shell's default max-width cap on the main content area. */
|
/* Wide-page setting: lifts the shared shell's default max-width cap on the main content area. */
|
||||||
[data-wide-layout='true'] .sc-main {
|
[data-wide-layout='true'] .sc-main {
|
||||||
width: calc(100% - 2rem);
|
width: calc(100% - 2rem);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2,14 +2,7 @@
|
|||||||
import { DropdownMenu } from 'bits-ui';
|
import { DropdownMenu } from 'bits-ui';
|
||||||
import { cn } from '$lib/utils/cn.js';
|
import { cn } from '$lib/utils/cn.js';
|
||||||
|
|
||||||
let {
|
let { ref = $bindable(null), class: className, sideOffset = 6, align = 'end', children, ...restProps } = $props();
|
||||||
ref = $bindable(null),
|
|
||||||
class: className,
|
|
||||||
sideOffset = 6,
|
|
||||||
align = 'end',
|
|
||||||
children,
|
|
||||||
...restProps
|
|
||||||
} = $props();
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<DropdownMenu.Portal>
|
<DropdownMenu.Portal>
|
||||||
|
|||||||
@@ -68,7 +68,6 @@
|
|||||||
type="checkbox"
|
type="checkbox"
|
||||||
checked={layoutState.wide}
|
checked={layoutState.wide}
|
||||||
onchange={(event) => layoutState.setWide(event.currentTarget.checked)}
|
onchange={(event) => layoutState.setWide(event.currentTarget.checked)}
|
||||||
|
|
||||||
/>
|
/>
|
||||||
</label>
|
</label>
|
||||||
<div class="sc-form-actions">
|
<div class="sc-form-actions">
|
||||||
|
|||||||
@@ -1,16 +1,16 @@
|
|||||||
<script>
|
<script>
|
||||||
import '../app.css';
|
import '../app.css';
|
||||||
import '@gabriel20xx/web-ui/styles.css';
|
import '@gabriel20xx/web-ui/styles.css';
|
||||||
import '$lib/theme.svelte.js';
|
import '$lib/theme.svelte.js';
|
||||||
import { QueryClientProvider } from '@tanstack/svelte-query';
|
import { QueryClientProvider } from '@tanstack/svelte-query';
|
||||||
import { queryClient } from '$lib/query/queryClient.js';
|
import { queryClient } from '$lib/query/queryClient.js';
|
||||||
import AppShell from '$lib/features/layout/AppShell.svelte';
|
import AppShell from '$lib/features/layout/AppShell.svelte';
|
||||||
|
|
||||||
let { children } = $props();
|
let { children } = $props();
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<QueryClientProvider client={queryClient}>
|
<QueryClientProvider client={queryClient}>
|
||||||
<AppShell>
|
<AppShell>
|
||||||
{@render children()}
|
{@render children()}
|
||||||
</AppShell>
|
</AppShell>
|
||||||
</QueryClientProvider>
|
</QueryClientProvider>
|
||||||
+47
-47
@@ -1,35 +1,35 @@
|
|||||||
import fs from 'node:fs';
|
import fs from 'node:fs';
|
||||||
import path from 'node:path';
|
import path from 'node:path';
|
||||||
import tailwindcss from '@tailwindcss/vite';
|
import tailwindcss from '@tailwindcss/vite';
|
||||||
import { sveltekit } from '@sveltejs/kit/vite';
|
import { sveltekit } from '@sveltejs/kit/vite';
|
||||||
import { defineConfig } from 'vite';
|
import { defineConfig } from 'vite';
|
||||||
import adapter from '@sveltejs/adapter-static';
|
import adapter from '@sveltejs/adapter-static';
|
||||||
|
|
||||||
// Real installed frontend dependency versions for the About page, resolved from
|
// Real installed frontend dependency versions for the About page, resolved from
|
||||||
// node_modules (not the package.json semver range) so it can't drift from what's bundled.
|
// node_modules (not the package.json semver range) so it can't drift from what's bundled.
|
||||||
const FRONTEND_TECH_STACK_PACKAGES = [
|
const FRONTEND_TECH_STACK_PACKAGES = [
|
||||||
{ name: 'Svelte', pkg: 'svelte' },
|
{ name: 'Svelte', pkg: 'svelte' },
|
||||||
{ name: 'SvelteKit', pkg: '@sveltejs/kit' },
|
{ name: 'SvelteKit', pkg: '@sveltejs/kit' },
|
||||||
{ name: 'TanStack Query', pkg: '@tanstack/svelte-query' },
|
{ name: 'TanStack Query', pkg: '@tanstack/svelte-query' },
|
||||||
{ name: 'Tailwind CSS', pkg: 'tailwindcss' },
|
{ name: 'Tailwind CSS', pkg: 'tailwindcss' },
|
||||||
{ name: 'Vite', pkg: 'vite' },
|
{ name: 'Vite', pkg: 'vite' },
|
||||||
];
|
];
|
||||||
|
|
||||||
function readInstalledVersion(pkg) {
|
function readInstalledVersion(pkg) {
|
||||||
try {
|
try {
|
||||||
const pkgJsonPath = path.resolve(import.meta.dirname, 'node_modules', pkg, 'package.json');
|
const pkgJsonPath = path.resolve(import.meta.dirname, 'node_modules', pkg, 'package.json');
|
||||||
return JSON.parse(fs.readFileSync(pkgJsonPath, 'utf-8')).version ?? null;
|
return JSON.parse(fs.readFileSync(pkgJsonPath, 'utf-8')).version ?? null;
|
||||||
} catch {
|
} catch {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const frontendTechStack = FRONTEND_TECH_STACK_PACKAGES.flatMap(({ name, pkg }) => {
|
const frontendTechStack = FRONTEND_TECH_STACK_PACKAGES.flatMap(({ name, pkg }) => {
|
||||||
const version = readInstalledVersion(pkg);
|
const version = readInstalledVersion(pkg);
|
||||||
return version ? [{ name, version }] : [];
|
return version ? [{ name, version }] : [];
|
||||||
});
|
});
|
||||||
|
|
||||||
export default defineConfig({
|
export default defineConfig({
|
||||||
plugins: [
|
plugins: [
|
||||||
tailwindcss(),
|
tailwindcss(),
|
||||||
sveltekit({
|
sveltekit({
|
||||||
@@ -41,19 +41,19 @@ export default defineConfig({
|
|||||||
fallback: 'index.html',
|
fallback: 'index.html',
|
||||||
}),
|
}),
|
||||||
}),
|
}),
|
||||||
],
|
],
|
||||||
resolve: {
|
resolve: {
|
||||||
preserveSymlinks: true,
|
preserveSymlinks: true,
|
||||||
},
|
},
|
||||||
define: {
|
define: {
|
||||||
__FRONTEND_TECH_STACK__: JSON.stringify(frontendTechStack),
|
__FRONTEND_TECH_STACK__: JSON.stringify(frontendTechStack),
|
||||||
},
|
},
|
||||||
server: {
|
server: {
|
||||||
port: 5173,
|
port: 5173,
|
||||||
proxy: {
|
proxy: {
|
||||||
'/web': 'http://localhost:8080',
|
'/web': 'http://localhost:8080',
|
||||||
'/health': 'http://localhost:8080',
|
'/health': 'http://localhost:8080',
|
||||||
'/api': 'http://localhost:8080',
|
'/api': 'http://localhost:8080',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
Reference in new issue
Block a user