Initial commit: add FastAPI MVP (모프) and existing web app
Includes FastAPI+Jinja2+HTMX+SQLite implementation with seed categories, plus deployment templates. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
59
templates/base.html
Normal file
59
templates/base.html
Normal file
@@ -0,0 +1,59 @@
|
||||
<!doctype html>
|
||||
<html lang="ko">
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
<title>{{ app_ko_name }} · {{ app_name }}</title>
|
||||
<!-- Tailwind CDN (빌드 없음) -->
|
||||
<script src="https://cdn.tailwindcss.com"></script>
|
||||
<!-- HTMX -->
|
||||
<script src="https://unpkg.com/htmx.org@1.9.12"></script>
|
||||
</head>
|
||||
<body class="bg-gray-50 text-gray-900">
|
||||
<div class="min-h-screen">
|
||||
<header class="sticky top-0 z-10 bg-white/90 backdrop-blur border-b">
|
||||
<div class="max-w-3xl mx-auto px-4 py-3 flex items-center gap-3">
|
||||
<a href="/" class="font-bold tracking-tight">
|
||||
{{ app_ko_name }}
|
||||
<span class="text-gray-400 font-normal text-sm">({{ app_name }})</span>
|
||||
</a>
|
||||
<div class="ml-auto flex items-center gap-2">
|
||||
<form action="/search" method="get" class="flex items-center gap-2">
|
||||
<input
|
||||
name="q"
|
||||
value="{{ q|default('') }}"
|
||||
placeholder="제목/내용 검색"
|
||||
class="w-40 sm:w-56 px-3 py-2 text-sm rounded border bg-white focus:outline-none focus:ring"
|
||||
/>
|
||||
{% if category_id %}
|
||||
<input type="hidden" name="category" value="{{ category_id }}" />
|
||||
{% endif %}
|
||||
<button class="px-3 py-2 text-sm rounded bg-gray-900 text-white hover:bg-gray-800">
|
||||
검색
|
||||
</button>
|
||||
</form>
|
||||
<a href="/new" class="px-3 py-2 text-sm rounded border bg-white hover:bg-gray-50">
|
||||
+ 등록
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="max-w-3xl mx-auto px-4 pb-3 text-xs text-gray-500">
|
||||
{% if nickname %}
|
||||
현재 닉네임: <span class="font-semibold text-gray-700">{{ nickname }}</span>
|
||||
{% else %}
|
||||
닉네임은 프롬프트 등록 시 자동 저장됩니다.
|
||||
{% endif %}
|
||||
</div>
|
||||
</header>
|
||||
|
||||
<main class="max-w-3xl mx-auto px-4 py-6">
|
||||
{% block content %}{% endblock %}
|
||||
</main>
|
||||
|
||||
<footer class="max-w-3xl mx-auto px-4 py-10 text-xs text-gray-400">
|
||||
초경량 프롬프트 커뮤니티 · 모프
|
||||
</footer>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user