- Introduced `puzzleResidences.ts` to define puzzle residence configurations including properties like display name, position, and puzzle availability. - Added `reflectionProgress.ts` to manage badge unlocking logic based on place completion, including functions to determine unlocked badges and video sources for scenes.
133 lines
4.1 KiB
TypeScript
133 lines
4.1 KiB
TypeScript
import LetterTemplate, { type LetterFieldConfig } from './LetterTemplate'
|
|
|
|
export interface LetterToLuxunProps {
|
|
visible?: boolean
|
|
onClose?: () => void
|
|
onSubmit?: (values: string[]) => void
|
|
onAnimationEnd?: () => void
|
|
audioSrc?: string
|
|
showVideo?: boolean
|
|
videoSrc?: string
|
|
replyImageSrc?: string
|
|
replyVideoSrc?: string
|
|
}
|
|
|
|
const commonSelectField: LetterFieldConfig = {
|
|
type: 'select',
|
|
placeholder: '请选择',
|
|
fitContent: false,
|
|
className: '!w-[120px] !min-w-[120px] shrink-0 px-0',
|
|
options: [
|
|
{ value: '首在立人', label: '首在立人' },
|
|
{ value: '批判求真', label: '批判求真' },
|
|
],
|
|
}
|
|
|
|
const letterContent = `敬爱的鲁迅先生:
|
|
|
|
您好!
|
|
|
|
今天,我怀着崇敬的心情走进大陆新村 9 号,看着您亲手撰写的《呐喊》《且介亭杂文》《故事新编》等作品,您编辑的《萌芽》《前哨》等杂志,您翻译的《艺术论》《死魂灵》等译文,仿佛能看到您“吾将上下而求索”的身影。在这场跨越时空的对话中,我终于明白您坚守的“____”,不是抽象的理念,而是我们安身立命的根本;您秉持的“____”,不是无谓的锋芒,而是我们直面现实的勇气。
|
|
|
|
我是____专业的学生,今后,我会以您“____千夫指”的骨气,在是非面前坚守立场,不随波逐流;我会以您“俯首甘为____”的热忱,参与____活动,用微光温暖他人;我更会记住您“____,走的人多了,也便成了路”的箴言,在专业领域勇于探索,努力用____为民族复兴、文化繁荣添砖加瓦。
|
|
|
|
请您放心,您播下的“立人”火种,我们会让它在新时代燎原;您毕生追求的“人国”愿景,我们会用青春和奋斗去守护!`
|
|
|
|
const fields: Record<number, LetterFieldConfig> = {
|
|
0: {
|
|
...commonSelectField,
|
|
correctValue: '首在立人',
|
|
hints: {
|
|
error: '请你结合上下文和所学在想想吧!',
|
|
},
|
|
readOnlyFallback: '首在立人',
|
|
},
|
|
1: {
|
|
...commonSelectField,
|
|
correctValue: '批判求真',
|
|
hints: {
|
|
error: '请你结合上下文和所学在想想吧!',
|
|
},
|
|
readOnlyFallback: '批判求真',
|
|
},
|
|
2: {
|
|
type: 'input',
|
|
maxLength: 12,
|
|
widthClassName: 'w-[120px]',
|
|
readOnlyFallback: '中文',
|
|
},
|
|
3: {
|
|
type: 'input',
|
|
maxLength: 12,
|
|
widthClassName: 'w-[120px]',
|
|
correctValue: '横眉冷对',
|
|
readOnlyFallback: '横眉冷对',
|
|
hints: {
|
|
error: '“横眉冷对于夫指,俯首甘为孺子牛”出自鲁迅先生的《自嘲》一诗。',
|
|
},
|
|
},
|
|
4: {
|
|
type: 'input',
|
|
maxLength: 12,
|
|
widthClassName: 'w-[120px]',
|
|
correctValue: '孺子牛',
|
|
readOnlyFallback: '孺子牛',
|
|
hints: {
|
|
error: '“横眉冷对于夫指,俯首甘为孺子牛”出自鲁迅先生的《自嘲》一诗。',
|
|
},
|
|
},
|
|
5: {
|
|
type: 'input',
|
|
maxLength: 12,
|
|
widthClassName: 'w-[120px]',
|
|
readOnlyFallback: '志愿服务',
|
|
},
|
|
6: {
|
|
type: 'input',
|
|
maxLength: 16,
|
|
widthClassName: 'w-[120px]',
|
|
correctValue: '地上本没有路',
|
|
readOnlyFallback: '地上本没有路',
|
|
hints: {
|
|
error: '鲁迅在小说《故乡》中写道:“地上本没有路,走的人多了,也便成了路。”',
|
|
},
|
|
},
|
|
7: {
|
|
type: 'input',
|
|
maxLength: 12,
|
|
widthClassName: 'w-[120px]',
|
|
readOnlyFallback: '专业所长',
|
|
},
|
|
}
|
|
|
|
const LetterToLuxun = ({
|
|
visible = false,
|
|
onClose,
|
|
onSubmit,
|
|
onAnimationEnd,
|
|
audioSrc = 'audio/letter/3我和我的祖国.m4a',
|
|
showVideo = true,
|
|
videoSrc = 'video/letter/neihua_jixin.mp4',
|
|
replyImageSrc = 'components/letter/点击信详情-鲁迅',
|
|
replyVideoSrc = 'video/letter/luxun_gaizhang.mp4',
|
|
}: LetterToLuxunProps) => {
|
|
return (
|
|
<LetterTemplate
|
|
visible={visible}
|
|
onClose={onClose}
|
|
onSubmit={onSubmit}
|
|
onAnimationEnd={onAnimationEnd}
|
|
title="写给鲁迅先生的信"
|
|
letterContent={letterContent}
|
|
fields={fields}
|
|
audioSrc={audioSrc}
|
|
showVideo={showVideo}
|
|
videoSrc={videoSrc}
|
|
replyVideoSrc={replyVideoSrc}
|
|
replyImageSrc={replyImageSrc}
|
|
/>
|
|
)
|
|
}
|
|
|
|
export default LetterToLuxun
|