game-village-politics-frontend/app/components/icon/Building.vue

104 lines
3.4 KiB
Vue
Raw Permalink Normal View History

<script setup lang="ts">
import type { BuildingType } from '~/types/game'
defineProps<{ type: BuildingType }>()
</script>
<!-- Line glyphs in currentColor, one per building type. Sprites per level come in M7. -->
<template>
<svg
viewBox="0 0 24 24"
fill="none"
stroke="currentColor"
stroke-width="1.7"
stroke-linecap="round"
stroke-linejoin="round"
aria-hidden="true"
class="shrink-0"
>
<g v-if="type === 'headquarters'">
<path d="M3 21h18" />
<path d="M5 21V11h14v10" />
<path d="M3 11l9-6 9 6" />
<path d="M10 21v-5h4v5" />
<path d="M12 5V2l3 1-3 1" />
</g>
<g v-else-if="type === 'storage'">
<rect x="4" y="5" width="16" height="15" rx="1.5" />
<path d="M4 10h16M4 15h16" />
<path d="M8 5v15M16 5v15" />
</g>
<g v-else-if="type === 'farm'">
<path d="M12 21V8" />
<path d="M12 8c-3 0-4-2-4-4 2 0 4 1 4 4zM12 8c3 0 4-2 4-4-2 0-4 1-4 4z" />
<path d="M12 13c-3 0-4-2-4-4 2 0 4 1 4 4zM12 13c3 0 4-2 4-4-2 0-4 1-4 4z" />
<path d="M12 18c-3 0-4-2-4-4 2 0 4 1 4 4zM12 18c3 0 4-2 4-4-2 0-4 1-4 4z" />
</g>
<g v-else-if="type === 'timber_camp'">
<path d="M12 3l5.5 7H15l4 6H5l4-6H6.5z" />
<path d="M12 16v5" />
</g>
<g v-else-if="type === 'clay_pit'">
<rect x="3" y="14" width="8" height="5" rx="0.6" />
<rect x="13" y="14" width="8" height="5" rx="0.6" />
<rect x="8" y="8" width="8" height="5" rx="0.6" />
<path d="M2 21h20" />
</g>
<g v-else-if="type === 'iron_mine'">
<path d="M5 19L15 9" />
<path d="M10 5.5c3.5-1.5 7-.5 9 1.5 2 2 3 5.5 1.5 9-1-3-2.5-5-4.5-7S13 6.5 10 5.5z" />
</g>
<g v-else-if="type === 'hiding_place'">
<path d="M3 20c0-8 4-14 9-14s9 6 9 14" />
<path d="M8 20c0-4 1.8-7 4-7s4 3 4 7" />
<path d="M2 20h20" />
</g>
<g v-else-if="type === 'barracks'">
<path d="M5 4l10 10M4 5l1-1 3 0-3 3zM15 14l-2 2 3 3 2-2z" />
<path d="M19 4L9 14M20 5l-1-1-3 0 3 3zM9 14l2 2-3 3-2-2z" />
</g>
<g v-else-if="type === 'stable'">
<path d="M7 20V9a5 5 0 0 1 10 0v11" />
<path d="M5 20h4M15 20h4" />
<path d="M9.5 10h.01M14.5 10h.01M9.5 14h.01M14.5 14h.01" />
</g>
<g v-else-if="type === 'workshop'">
<path d="M4 20h16" />
<path d="M6 20v-3h12v3" />
<path d="M8 17v-3h8v3" />
<path d="M13 4l5 5-2 2-5-5zM11.5 8.5L5 15" />
</g>
<g v-else-if="type === 'academy'">
<path d="M4 18h16l1-10-5 4-4-7-4 7-5-4z" />
<path d="M4 21h16" />
</g>
<g v-else-if="type === 'wall'">
<path d="M3 20V8h3v3h3V8h3v3h3V8h3v3h3V8v12z" />
<path d="M3 15.5h18M9 15.5V20M15 15.5V20M6 11v4.5M12 11v4.5M18 11v4.5" />
</g>
<g v-else-if="type === 'hospital'">
<path d="M3 19V7M3 15h18v4" />
<path d="M5 12h4v3H5z" />
<path d="M10 15v-3h8a3 3 0 0 1 3 3" />
<path d="M15 4v5M12.5 6.5h5" />
</g>
<g v-else-if="type === 'market'">
<path d="M3 9l2-5h14l2 5" />
<path d="M3 9a3 3 0 0 0 6 0a3 3 0 0 0 6 0a3 3 0 0 0 6 0" />
<path d="M5 12v8M19 12v8M2.5 20h19" />
<path d="M8 20v-4h8v4" />
</g>
<g v-else-if="type === 'watchtower'">
<path d="M8 21l1.5-11h5L16 21" />
<path d="M6.5 10h11l-1.5-3h-8z" />
<path d="M8 7V4h8v3M10.5 4V2.5h3V4" />
<path d="M9 15h6M5 21h14" />
</g>
<g v-else>
<path d="M6 21V3" />
<path d="M6 4h11l-2.5 4L17 12H6" />
<path d="M3 21h6" />
</g>
</svg>
</template>