#
vincentlu
2025-12-17 e10544b0d56e228e7ba23b5704ca46ebe299467f
#
1个文件已修改
19 ■■■■ 已修改文件
zy-acs-flow/src/map/tool.js 19 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
zy-acs-flow/src/map/tool.js
@@ -911,11 +911,22 @@
const addAreaLabel = (draft, text, from, to) => {
    const centerX = (from.x + to.x) / 2;
    const centerY = (from.y + to.y) / 2;
    const label = new PIXI.Text(text, {
        fill: themeMode === 'dark' ? '#f1f2f6' : '#535353ff',
        fontSize: 20 / Math.abs(mapContainer.scale.x || 1),
        fontWeight: 'bold',
    const currentScale = Math.abs(mapContainer.scale.x || 1);
    const labelStyle = new PIXI.TextStyle({
        fontFamily: 'Inter, "Segoe UI", sans-serif',
        fill: themeMode === 'dark' ? '#f1f2f6' : '#1e272e',
        fontSize: Math.max(16, 22 / currentScale),
        fontWeight: 600,
        letterSpacing: 0.5,
        stroke: themeMode === 'dark' ? '#1e272e' : '#ffffff',
        strokeThickness: Math.max(1, 2 / currentScale),
        dropShadow: true,
        dropShadowColor: themeMode === 'dark' ? '#00000066' : '#95a5a6',
        dropShadowBlur: 1.5,
        dropShadowAngle: Math.PI / 4,
        dropShadowDistance: 2,
    });
    const label = new PIXI.Text(text ?? '', labelStyle);
    label.anchor.set(0.5);
    label.position.set(centerX, centerY);
    label.rotation = rotationParseNum(MAP_DEFAULT_ROTATION);