Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
- run: bun install
- run: bun run build
env:
VITE_PUBLIC_GIT_SHA: ${{ steps.vars.outputs.sha_short }}
ASTRO_PUBLIC_GIT_SHA: ${{ steps.vars.outputs.sha_short }}

- uses: actions/upload-pages-artifact@v3
with:
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -41,3 +41,6 @@ yarn-error.log*
# typescript
*.tsbuildinfo
next-env.d.ts

# generated types
.astro/
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,6 @@ bun install
bun dev
```

Open [http://localhost:5173](http://localhost:5173) with your browser to see the result.
Open [http://localhost:4321](http://localhost:4321) with your browser to see the result.

You can start editing the page by modifying `src/app/index.jsx`. The page auto-updates as you edit the file.
You can start editing the page by modifying `src/pages/index.astro`. The page auto-updates as you edit the file.
34 changes: 34 additions & 0 deletions astro.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
// @ts-check
import { defineConfig, fontProviders } from 'astro/config';

import preact from '@astrojs/preact';
import tailwind from '@astrojs/tailwind';

export default defineConfig({
integrations: [preact(), tailwind()],
vite: {
build: {
minify: true,
sourcemap: false,
cssCodeSplit: false,
rollupOptions: {
output: {
manualChunks: () => 'app',
entryFileNames: 'assets/app.[hash].js',
chunkFileNames: 'assets/app.[hash].js',
},
},
},
},
experimental: {
fonts: [{
provider: fontProviders.fontsource(),
name: "Inter",
cssVariable: "--font-inter",
weights: ["100 900"],
styles: ["normal"],
subsets: ["latin"],
display: "swap"
}]
},
});
Binary file modified bun.lockb
Binary file not shown.
29 changes: 11 additions & 18 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,40 +4,33 @@
"private": true,
"type": "module",
"scripts": {
"dev": "vite",
"build": "vite build",
"start": "vite preview",
"dev": "astro dev",
"build": "astro build",
"start": "astro preview",
"astro": "astro",
"test": "vitest"
},
"engines": {
"node": ">=20.11.0"
},
"dependencies": {
"@astrojs/preact": "^4.1.0",
"@astrojs/tailwind": "^6.0.2",
"@commaai/qdl": "git+https://github.com/commaai/qdl.js.git#52021f0b1ace58673ebca1fae740f6900ebff707",
"@fontsource-variable/inter": "^5.2.5",
"@fontsource-variable/jetbrains-mono": "^5.2.5",
"react": "^18.3.1",
"react-dom": "^18.3.1",
"@tailwindcss/typography": "^0.5.16",
"astro": "^5.8.0",
"preact": "^10.26.6",
"tailwindcss": "3",
"xz-decompress": "^0.2.2"
},
"devDependencies": {
"@tailwindcss/typography": "^0.5.16",
"@testing-library/jest-dom": "^6.6.3",
"@testing-library/react": "^16.3.0",
"@types/react": "^18.3.20",
"@types/react-dom": "^18.3.6",
"@vitejs/plugin-react": "^4.3.4",
"autoprefixer": "10.4.21",
"jsdom": "^26.0.0",
"postcss": "^8.5.3",
"tailwindcss": "^3.4.17",
"vite": "^6.2.6",
"vite-svg-loader": "^5.1.0",
"vitest": "^3.1.1"
},
"trustedDependencies": [
"@commaai/qdl",
"esbuild",
"usb"
]
}
}
6 changes: 0 additions & 6 deletions postcss.config.js

This file was deleted.

File renamed without changes
10 changes: 0 additions & 10 deletions src/app/App.test.jsx

This file was deleted.

Binary file removed src/app/favicon.ico
Binary file not shown.
Binary file removed src/app/icon.png
Binary file not shown.
174 changes: 0 additions & 174 deletions src/app/index.jsx

This file was deleted.

13 changes: 13 additions & 0 deletions src/components/copy-text.astro
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
---
const { text } = Astro.props;
---

<div class="relative text-sm">
<pre class="font-mono pt-12">{text}</pre>
<button
class="absolute top-2 right-2 bg-blue-600 hover:bg-blue-500 active:bg-blue-300 transition-colors text-white p-1 rounded-md"
onclick={`navigator.clipboard.writeText("${text.replace(/"/g, '\\"')}")`}
>
Copy
</button>
</div>
Loading