feat: 完成全部接口替换为新后端接口
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
import { publicAssetUrl } from '../../config/assets';
|
||||
|
||||
/**
|
||||
* 字体渲染配置(Font Profile)
|
||||
*
|
||||
@@ -12,10 +14,7 @@
|
||||
|
||||
/** 字母分类 */
|
||||
export type LetterCategory =
|
||||
| 'uppercase'
|
||||
| 'tallLower'
|
||||
| 'descender'
|
||||
| 'lowercase';
|
||||
'uppercase' | 'tallLower' | 'descender' | 'lowercase';
|
||||
|
||||
/** 单个分类的渲染参数 */
|
||||
export interface CategoryMetrics {
|
||||
@@ -48,9 +47,6 @@ export function fontFamilyOf(profile: FontProfile): string {
|
||||
return `${profile.name}, Roboto, sans-serif`;
|
||||
}
|
||||
|
||||
const CLOUD_PREFIX =
|
||||
'cloud://cloud1-9gifs7a2756e2c87.636c-cloud1-9gifs7a2756e2c87-1351593184/';
|
||||
|
||||
// ── 字母分类集合 ──
|
||||
const TALL_LOWERCASE = new Set(['b', 'd', 'h', 'k', 'l']);
|
||||
const DESCENDERS = new Set(['g', 'p', 'q', 'y']);
|
||||
@@ -213,7 +209,7 @@ export const PRINT_CLEARLY_DASHED: FontProfile = {
|
||||
/** ToneOZ Pinyin 拼音字体(含声调字母、ü 变体等专用字形) */
|
||||
export const TONEOZ_PINYIN: FontProfile = {
|
||||
name: 'ToneOZPinyin',
|
||||
url: `${CLOUD_PREFIX}assets/fonts/ToneOZ-Pinyin-Regular.ttf`,
|
||||
url: publicAssetUrl('assets/fonts/ToneOZ-Pinyin-Regular.ttf'),
|
||||
categories: {
|
||||
uppercase: { scale: 1, baselineOffset: 0 },
|
||||
tallLower: { scale: 1, baselineOffset: 0 },
|
||||
|
||||
Reference in New Issue
Block a user