Files
lupin-demo/src/index.ts
2026-01-23 23:20:39 +08:00

59 lines
1.3 KiB
TypeScript

/**
* 罗盘组件库入口文件
*/
// 类型导出
export type {
Example,
LuopanConfig,
LuopanConfigInput,
ThemeConfig,
ThemeItem,
ThemesConfig,
CenterIconConfig,
DegreeRingConfig,
DegreeRingData,
DegreeLabel,
CenterIconData,
LayerConfig,
SectorConfig,
TextUnit,
TickMark,
Sector,
PolarPoint,
AnnularSectorParams,
CentroidResult,
} from './types';
// 组件导出
export { default as Luopan } from './Luopan.vue';
// 工具函数导出
export {
polarToXY,
normalizeDeg,
annularSectorCentroid,
annularSectorPath,
annularSectorInsetPath,
generateTextPath,
generateVerticalTextPath,
getTextColorForBackground,
} from './utils';
// 组合式函数导出
export { useLuopan } from './composables/useLuopan';
export type { UseLuopanReturn } from './composables/useLuopan';
// 常量导出
export { EXAMPLES, DEFAULT_SIZE, SECTOR_INSET_DISTANCE } from './constants';
// 配置解析导出
export { parseConfig, stripJsonComments } from './configParser';
// 解析工具导出
export { ColorResolver, applyPatternColoring } from './colorResolver';
export { splitMultiTextUnits } from './multiTextParser';
export { SectorBuilder } from './sectorBuilder';
export { buildDegreeRing } from './degreeRing';
export { loadCenterIcon } from './centerIcon';