← 提示词库 Anthropic/claude-design/skills/maps-geography/SKILL.md 原文 md
🌐 中英双语对照

name: maps-geography
description: "Accurate maps from real geo data — use for any map, or whenever geography would make a good graphic for a deliverable"
user-invocable: true

Maps & geography / 地图与地理

Geographic maps are data problems, not drawings: never freehand country outlines, coastlines, or street layouts — hand-drawn geography is reliably wrong, and users notice. Load real geometry and render it.

地理地图是数据问题,而不是绘画问题:绝不要徒手勾勒国家轮廓、海岸线或街道布局——手绘的地理形状必然是错的,而且用户看得出来。应当加载真实几何数据并进行渲染。

Build every map page as plain HTML — a .html file with ordinary

Inline SVG from d3 also exports cleanly to PNG and PDF, which live map tiles do not — so exported deliverables always get d3 geometry, never an embedded tile map.

由 d3 生成的内联 SVG 还能干净地导出为 PNG 和 PDF,而实时地图瓦片做不到这一点——因此导出的交付物一律使用 d3 几何数据,绝不内嵌瓦片地图。

For street-level interactive maps — prototypes, websites, anything the user pans and zooms — use Leaflet with OpenStreetMap tiles, loaded ONLY through these exact tags (the stylesheet is required: without leaflet.css the tiles render scrambled):

对于街道级交互地图——原型、网站、任何需要用户平移和缩放的东西——使用 Leaflet 配 OpenStreetMap 瓦片,且只能通过下面这些精确的标签加载(样式表必不可少:没有 leaflet.css,瓦片会渲染错乱):

Create the map with L.map(...) and L.tileLayer('https://tile.openstreetmap.org/{z}/{x}/{y}.png', { attribution: '© OpenStreetMap contributors' }). The attribution string is OpenStreetMap's license requirement — never omit it.

用 L.map(...) 和 L.tileLayer('https://tile.openstreetmap.org/{z}/{x}/{y}.png', { attribution: '© OpenStreetMap contributors' }) 创建地图。该署名字符串是 OpenStreetMap 的许可证要求——绝不可省略。