feat: initial MVP - FastAPI backend + Vue3 frontend + docker-compose

- backend: FastAPI + SQLAlchemy 2.0(async) + asyncpg + Alembic
- 7 API routes: auth/me/articles/sources/bookmarks/subscriptions/admin
- models: User/Source/Article/Bookmark/Subscription/ApiToken
- services: RSS fetcher (feedparser) + Tencent TMT translator with quota + cache + local NLLB fallback
- workers: APScheduler + asyncio pipeline (fetch -> dedupe -> insert -> translate)
- seed scripts: create_user, seed_sources (5 RSS: Reuters/BBC/Al Jazeera/NHK/DW)
- frontend: Vue 3 + Vite + Naive UI + Pinia + vue-router
- pages: Login, Feed (24h), ArticleDetail, Sources, Bookmarks, AdminSources
- deploy: docker-compose (postgres/redis/api/worker/frontend/caddy)
- docs: README, DEPLOY, architecture, acceptance
This commit is contained in:
Mavis
2026-06-07 21:51:01 +08:00
commit 60b062daf2
81 changed files with 5540 additions and 0 deletions

29
frontend/src/style.css Normal file
View File

@@ -0,0 +1,29 @@
:root {
--max-width: 1200px;
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue',
Arial, 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
line-height: 1.6;
color: #1f2328;
background: #fafbfc;
}
* { box-sizing: border-box; }
html, body, #app {
margin: 0;
padding: 0;
min-height: 100vh;
}
a { color: inherit; text-decoration: none; }
a:hover { color: #2080f0; }
img { max-width: 100%; }
.n-card.article-card {
margin-bottom: 16px;
transition: box-shadow 0.15s;
}
.n-card.article-card:hover {
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}