feat: 拼音字母选择
This commit is contained in:
@@ -0,0 +1,100 @@
|
||||
/**
|
||||
* 汉语拼音分类数据
|
||||
* 23 个声母 + 24 个韵母 + 16 个整体认读音节
|
||||
*/
|
||||
|
||||
export interface PinyinCategory {
|
||||
key: string;
|
||||
label: string;
|
||||
count: number;
|
||||
items: string[];
|
||||
}
|
||||
|
||||
export interface PinyinSubCategory {
|
||||
key: string;
|
||||
label: string;
|
||||
count: number;
|
||||
items: string[];
|
||||
}
|
||||
|
||||
export interface PinyinSection {
|
||||
key: string;
|
||||
title: string;
|
||||
count: number;
|
||||
items: string[];
|
||||
subCategories?: PinyinSubCategory[];
|
||||
}
|
||||
|
||||
// ─── 声母 (23个) ───
|
||||
|
||||
export const SHENGMU: string[] = [
|
||||
'b', 'p', 'm', 'f',
|
||||
'd', 't', 'n', 'l',
|
||||
'g', 'k', 'h',
|
||||
'j', 'q', 'x',
|
||||
'zh', 'ch', 'sh', 'r',
|
||||
'z', 'c', 's',
|
||||
'y', 'w',
|
||||
];
|
||||
|
||||
export const QIAOSHEYIN: string[] = ['zh', 'ch', 'sh', 'r'];
|
||||
export const PINGSHEYIN: string[] = ['z', 'c', 's'];
|
||||
|
||||
// ─── 韵母 (24个) ───
|
||||
|
||||
export const DAN_YUNMU: string[] = ['a', 'o', 'e', 'i', 'u', 'ü'];
|
||||
export const FU_YUNMU: string[] = ['ai', 'ei', 'ui', 'ao', 'ou', 'iu', 'ie', 'üe'];
|
||||
export const TESHU_YUNMU: string[] = ['er'];
|
||||
export const QIANBI_YUNMU: string[] = ['an', 'en', 'in', 'un', 'ün'];
|
||||
export const HOUBI_YUNMU: string[] = ['ang', 'eng', 'ing', 'ong'];
|
||||
|
||||
export const YUNMU: string[] = [
|
||||
...DAN_YUNMU,
|
||||
...FU_YUNMU,
|
||||
...TESHU_YUNMU,
|
||||
...QIANBI_YUNMU,
|
||||
...HOUBI_YUNMU,
|
||||
];
|
||||
|
||||
// ─── 整体认读音节 (16个) ───
|
||||
|
||||
export const ZHENGTI_RENDU: string[] = [
|
||||
'zhi', 'chi', 'shi', 'ri',
|
||||
'zi', 'ci', 'si', 'yi',
|
||||
'wu', 'yu', 'ye', 'yue',
|
||||
'yuan', 'yin', 'yun', 'ying',
|
||||
];
|
||||
|
||||
// ─── 结构化分类数据(用于绘制) ───
|
||||
|
||||
export const PINYIN_SECTIONS: PinyinSection[] = [
|
||||
{
|
||||
key: 'shengmu',
|
||||
title: '一、声母',
|
||||
count: 23,
|
||||
items: SHENGMU,
|
||||
subCategories: [
|
||||
{ key: 'qiaoshe', label: '翘舌音', count: 4, items: QIAOSHEYIN },
|
||||
{ key: 'pingshe', label: '平舌音', count: 3, items: PINGSHEYIN },
|
||||
],
|
||||
},
|
||||
{
|
||||
key: 'yunmu',
|
||||
title: '二、韵母',
|
||||
count: 24,
|
||||
items: YUNMU,
|
||||
subCategories: [
|
||||
{ key: 'dan', label: '单韵母', count: 6, items: DAN_YUNMU },
|
||||
{ key: 'fu', label: '复韵母', count: 8, items: FU_YUNMU },
|
||||
{ key: 'teshu', label: '特殊韵母', count: 1, items: TESHU_YUNMU },
|
||||
{ key: 'qianbi', label: '前鼻韵母', count: 5, items: QIANBI_YUNMU },
|
||||
{ key: 'houbi', label: '后鼻韵母', count: 4, items: HOUBI_YUNMU },
|
||||
],
|
||||
},
|
||||
{
|
||||
key: 'zhengti',
|
||||
title: '三、整体认读音节',
|
||||
count: 16,
|
||||
items: ZHENGTI_RENDU,
|
||||
},
|
||||
];
|
||||
@@ -0,0 +1,39 @@
|
||||
/**
|
||||
* 描红练习统一样式配置
|
||||
*
|
||||
* 适用范围:田字格(汉字)、四线三格(拼音/英文字母)的格子线条和描红字体颜色。
|
||||
* 所有绘制服务应统一引用此配置,避免各处硬编码颜色值。
|
||||
*
|
||||
* 设计原则:
|
||||
* - 格子线条使用护眼绿色系,打印清晰且长时间书写不疲劳
|
||||
* - 描红字体使用中性灰色,不带色彩偏向,打印友好
|
||||
*
|
||||
* @see docs/tracing-color-guide.md
|
||||
*/
|
||||
|
||||
// ─── 格子线条颜色(田字格 / 四线三格通用) ───
|
||||
|
||||
export const GRID_COLORS = {
|
||||
/** 外框、实线、垂直分隔线 — 中等绿色,清晰可见 */
|
||||
border: '#7fb069',
|
||||
/** 中线、虚线(田字格十字线 / 四线三格中间两线)— 浅绿色,柔和护眼 */
|
||||
middleLine: '#a8d5a8',
|
||||
/** 对角线 — 极淡绿色,辅助参考线(田字格专用) */
|
||||
diagonal: '#d4f0d4',
|
||||
} as const;
|
||||
|
||||
/** 四线三格默认虚线样式 */
|
||||
export const GRID_DASH = [3, 3] as const;
|
||||
|
||||
// ─── 描红/临摹字体颜色 ───
|
||||
|
||||
export const TRACING_COLORS = {
|
||||
/** 参照字/预览字 — 深灰色,完整展示供对照 */
|
||||
reference: '#555555',
|
||||
/** 描红引导字 — 中性灰色,跟着描写 */
|
||||
guide: '#d0d0d0',
|
||||
/** 极浅引导字 — 浅灰色,水印效果 */
|
||||
guideLight: '#e0e0e0',
|
||||
/** 首笔/强调 — 近黑色,用于首个参照格 */
|
||||
strong: '#1a1a1a',
|
||||
} as const;
|
||||
Reference in New Issue
Block a user