// 船舶信息
<template>
  <div>
    <TitleLine
      style="margin-top: 30px"
      icon="info-dark"
      title="船舶信息"
      :type="2"
      :endText="shipInfo.shipName"
    ></TitleLine>
    <ShipOwnerInfo
      :name="shipInfo.shipOwnerName"
      :ownerId="shipInfo.shipOwnerId"
      class="mt20"
    ></ShipOwnerInfo>
    <IconInfo
      style="margin-top: 25px"
      :type="1"
      :info="[shipInfo.mmsi, shipInfo.length, shipInfo.width]"
    ></IconInfo>
  </div>
</template>

<script>
import { ref, onMounted } from "vue";
import { mapState } from "vuex";

export default {
  computed: mapState(["shipInfo"]),
  setup() {
    function init() {}
    function exchangeUrl(icon) {
      return `/${icon}.png`;
    }
    onMounted(() => {
      init();
    });
    return {
      init,
      exchangeUrl,
    };
  },
};
</script>
<style lang="scss" scoped>
</style>