chore: seal Design Vision v1 and monorepo scaffold

Archive the differentiated YuXinGu product docs, AI engineering system,
design contract, and Go/Vue scaffold. Next execution prioritizes Cece-parity
over early innovation (see .ai/product/STRATEGY.md).

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
jackyu66git
2026-08-02 16:00:44 +08:00
co-authored by Cursor
parent 2686866376
commit 2fb1dfee14
193 changed files with 8854 additions and 1851 deletions
+115
View File
@@ -0,0 +1,115 @@
<template>
<main class="home">
<header class="brand">
<div class="word"><span></span></div>
<p class="tag">愈见自己 · 遇见更好</p>
</header>
<section class="decode-card">
<h2>愈心解码</h2>
<p class="sub">一个生日读懂你的身与心</p>
<div class="row">
<input v-model="year" type="number" placeholder="1990" />
<span></span>
<input v-model="month" type="number" placeholder="1" />
<span></span>
<input v-model="day" type="number" placeholder="1" />
<span></span>
<button type="button" @click="goDecode">生成</button>
</div>
<p v-if="err" class="err">{{ err }}</p>
</section>
<section class="block">
<div class="head"><h3>认识自己</h3><router-link to="/explore">全部</router-link></div>
<div class="grid">
<router-link v-for="t in tests" :key="t.to" :to="t.to" class="cell">
<div class="icon" :style="{ background: t.bg, color: t.fg }">{{ t.icon }}</div>
<span>{{ t.label }}</span>
</router-link>
</div>
</section>
<section class="block">
<div class="head"><h3>服务状态</h3></div>
<p class="api">API{{ apiStatus }}</p>
</section>
</main>
</template>
<script setup lang="ts">
import { onMounted, ref } from 'vue'
import { useRouter } from 'vue-router'
import { validateBirth } from '@yuxingu/utils'
import { api } from '../api/client'
const router = useRouter()
const year = ref('')
const month = ref('')
const day = ref('')
const err = ref('')
const apiStatus = ref('检测中…')
const tests = [
{ to: '/decode', icon: '△', label: '愈心解码', bg: '#FFF3D6', fg: '#C8923A' },
{ to: '/explore', icon: '◆', label: '性格测评', bg: '#E3EEFF', fg: '#4A90E2' },
{ to: '/ask', icon: '问', label: '愈心问答', bg: '#FFE4E4', fg: '#E54D42' },
{ to: '/companion', icon: '☯', label: '节气陪伴', bg: '#E0F6E4', fg: '#5CB85C' },
]
function goDecode() {
const y = Number(year.value)
const m = Number(month.value)
const d = Number(day.value)
const msg = validateBirth(y, m, d)
if (msg) {
err.value = msg
return
}
err.value = ''
router.push({ path: '/decode', query: { y: String(y), m: String(m), d: String(d) } })
}
onMounted(async () => {
try {
const data = await api.healthz()
apiStatus.value = data.status === 'ok' ? '已连接' : '异常'
} catch {
apiStatus.value = '未连接(请启动 apps/api'
}
})
</script>
<style scoped>
.home{padding:18px 16px 8px}
.brand{text-align:center;margin-bottom:14px}
.word{font-size:28px;font-weight:700;letter-spacing:.18em}
.word span{color:var(--yxg-pri)}
.tag{font-size:12px;color:rgba(0,0,0,.38);margin-top:6px;letter-spacing:.12em}
.decode-card{
background:#fff;border-radius:20px;padding:18px 14px;text-align:center;
box-shadow:0 8px 28px rgba(229,77,66,.12);
}
.decode-card h2{font-size:17px;color:var(--yxg-gold);letter-spacing:.1em}
.sub{font-size:12px;color:#aaa;margin:4px 0 14px}
.row{display:flex;gap:6px;align-items:center;justify-content:center;flex-wrap:wrap}
.row input{
width:56px;padding:10px 4px;border:1.5px solid #eee;border-radius:12px;
text-align:center;font-size:15px;outline:none;
}
.row button{
padding:10px 16px;border:none;border-radius:22px;color:#fff;font-weight:600;
background:linear-gradient(135deg,#ff7a6e,var(--yxg-pri));
}
.err{color:var(--yxg-pri);font-size:12px;margin-top:8px}
.block{margin-top:22px;background:#fff;border-radius:18px;padding:16px;box-shadow:0 2px 10px rgba(0,0,0,.04)}
.head{display:flex;justify-content:space-between;align-items:center;margin-bottom:12px}
.head h3{font-size:16px}
.head a{font-size:12px;color:#bbb}
.grid{display:grid;grid-template-columns:repeat(4,1fr);gap:12px 8px}
.cell{display:flex;flex-direction:column;align-items:center;gap:8px;font-size:11px;color:#555}
.icon{
width:52px;height:52px;border-radius:18px;display:flex;align-items:center;justify-content:center;font-size:20px;
}
.api{font-size:13px;color:var(--yxg-sub)}
</style>