feat: 优化文章详情与导航配置
This commit is contained in:
@@ -5,6 +5,13 @@ describe('siteDocumentSchema', () => {
|
||||
it('accepts the seeded phase-one website document', () => {
|
||||
expect(siteDocumentSchema.parse(defaultSiteDocument)).toEqual(defaultSiteDocument)
|
||||
expect(defaultSiteDocument.brand.name).toBe('慧遇书院')
|
||||
expect(defaultSiteDocument.brand.navFontSize).toBe(14)
|
||||
})
|
||||
|
||||
it('keeps the navigation font size within a readable range', () => {
|
||||
const invalid = structuredClone(defaultSiteDocument)
|
||||
invalid.brand.navFontSize = 36
|
||||
expect(siteDocumentSchema.safeParse(invalid).success).toBe(false)
|
||||
})
|
||||
|
||||
it('rejects unsafe oversized content', () => {
|
||||
|
||||
Reference in New Issue
Block a user