1
zzzz
2024-03-21 50298673b5146454bf81e642ebadb9697400d13a
1
{"ast":null,"code":"//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n\nimport { mapGetters } from \"vuex\";\nimport { getStorage } from \"@/utils/utis\";\nexport default {\n  props: {\n    isActive: {\n      type: Boolean,\n      default: true\n    }\n  },\n  components: {},\n  computed: {\n    ...mapGetters({\n      theme: \"home/theme\"\n    })\n  },\n  data() {\n    return {\n      getStorage,\n      active: \"home\",\n      home: {},\n      qoutes: {},\n      trade: {},\n      contract: {},\n      funds: {}\n    };\n  },\n  mounted() {\n    this.home = {\n      active: require(`../../assets/theme/${this.theme}/image/footer/home1.png`),\n      inactive: require(`../../assets/theme/${this.theme}/image/footer/home2.png`)\n    };\n    this.qoutes = {\n      active: require(`../../assets/theme/${this.theme}/image/footer/quotes1.png`),\n      inactive: require(`../../assets/theme/${this.theme}/image/footer/quotes2.png`)\n    };\n    this.trade = {\n      active: require(`../../assets/theme/${this.theme}/image/footer/trade1.png`),\n      inactive: require(`../../assets/theme/${this.theme}/image/footer/trade2.png`)\n    };\n    this.contract = {\n      active: require(`../../assets/theme/${this.theme}/image/footer/contract1.png`),\n      inactive: require(`../../assets/theme/${this.theme}/image/footer/contract2.png`)\n    };\n    this.funds = {\n      active: require(`../../assets/theme/${this.theme}/image/footer/funds1.png`),\n      inactive: require(`../../assets/theme/${this.theme}/image/footer/funds2.png`)\n    };\n  }\n};","map":{"version":3,"names":["mapGetters","getStorage","props","isActive","type","Boolean","default","components","computed","theme","data","active","home","qoutes","trade","contract","funds","mounted","require","inactive"],"sources":["src/components/footer/index.vue"],"sourcesContent":["<template>\n  <div class=\"tabbar-footer\">\n    <van-tabbar\n      route\n      v-model=\"active\"\n      active-color=\"#1D91FF\"\n      fixed\n      inactive-color=\"#868D9A\"\n      safe-area-inset-bottom\n      class=\"bgFooter\"\n    >\n      <div class=\"bgc\"></div>\n      <van-tabbar-item name=\"home\" to=\"/home\">\n        <span>{{ $t(\"首页\") }}</span>\n        <template #icon=\"props\">\n          <img :src=\"props.active ? home.active : home.inactive\" alt=\"home\" />\n        </template>\n      </van-tabbar-item>\n      <van-tabbar-item\n        name=\"quotes\"\n        :to=\"{ name: 'Quotes', query: { active: 2 } }\"\n      >\n        <span>{{ $t(\"市场\") }}</span>\n        <template #icon=\"props\">\n          <img\n            :src=\"props.active ? qoutes.active : qoutes.inactive\"\n            alt=\"Quotes\"\n          />\n        </template>\n      </van-tabbar-item>\n      <van-tabbar-item\n        name=\"/trade/btc\"\n        :to=\"{\n          name: 'Trade',\n          params: { symbol: getStorage('tradeSymbol') || 'btc' },\n        }\"\n      >\n        <span>{{ $t(\"交易\") }}</span>\n        <template #icon=\"props\">\n          <img\n            :src=\"props.active ? trade.active : trade.inactive\"\n            alt=\"trade\"\n          />\n        </template>\n      </van-tabbar-item>\n      <van-tabbar-item\n        name=\"perpetualContract/btc\"\n        :to=\"{\n          name: 'perpetualContract',\n          params: { symbol: getStorage('symbol') || 'btc' },\n        }\"\n      >\n        <span>{{ $t(\"合约\") }}</span>\n        <template #icon=\"props\">\n          <img\n            :src=\"props.active ? contract.active : contract.inactive\"\n            alt=\"perpetualContract\"\n          />\n        </template>\n      </van-tabbar-item>\n      <van-tabbar-item name=\"funds\" to=\"/funds\">\n        <span>{{ $t(\"资金\") }}</span>\n        <template #icon=\"props\">\n          <img\n            :src=\"props.active ? funds.active : funds.inactive\"\n            alt=\"funds\"\n          />\n        </template>\n      </van-tabbar-item>\n      <van-tabbar-item\n        name=\"profile\"\n        :to=\"{\n          name: 'profile',\n        }\"\n      >\n        <span>{{ $t(\"Profile\") }}</span>\n        <template #icon=\"props\">\n          <img\n            :src=\"props.active ? contract.active : contract.inactive\"\n            alt=\"perpetualContract\"\n          />\n        </template>\n      </van-tabbar-item>\n    </van-tabbar>\n  </div>\n</template>\n\n<script>\nimport { mapGetters } from \"vuex\";\nimport { getStorage } from \"@/utils/utis\";\nexport default {\n  props: {\n    isActive: {\n      type: Boolean,\n      default: true,\n    },\n  },\n  components: {},\n  computed: {\n    ...mapGetters({\n      theme: \"home/theme\",\n    }),\n  },\n  data() {\n    return {\n      getStorage,\n      active: \"home\",\n      home: {},\n      qoutes: {},\n      trade: {},\n      contract: {},\n      funds: {},\n    };\n  },\n  mounted() {\n    this.home = {\n      active: require(`../../assets/theme/${this.theme}/image/footer/home1.png`),\n      inactive: require(`../../assets/theme/${this.theme}/image/footer/home2.png`),\n    };\n    this.qoutes = {\n      active: require(`../../assets/theme/${this.theme}/image/footer/quotes1.png`),\n      inactive: require(`../../assets/theme/${this.theme}/image/footer/quotes2.png`),\n    };\n    this.trade = {\n      active: require(`../../assets/theme/${this.theme}/image/footer/trade1.png`),\n      inactive: require(`../../assets/theme/${this.theme}/image/footer/trade2.png`),\n    };\n    this.contract = {\n      active: require(`../../assets/theme/${this.theme}/image/footer/contract1.png`),\n      inactive: require(`../../assets/theme/${this.theme}/image/footer/contract2.png`),\n    };\n    this.funds = {\n      active: require(`../../assets/theme/${this.theme}/image/footer/funds1.png`),\n      inactive: require(`../../assets/theme/${this.theme}/image/footer/funds2.png`),\n    };\n  },\n};\n</script>\n\n<style lang=\"scss\" scoped>\n@import \"../../assets/init.scss\";\n\n.van-tabbar--fixed {\n  z-index: 10;\n  padding-bottom: constant(safe-area-inset-bottom);\n  padding-bottom: env(safe-area-inset-bottom);\n}\n\n.van-tabbar {\n  height: 108px;\n  font-size: 22px;\n}\n\n.van-tabbar-item__icon img {\n  height: 56px;\n  width: 56px;\n}\n\n::v-deep .van-tabbar-item__icon {\n  margin-bottom: 9px;\n}\n\n::v-deep .van-tabbar-item__text {\n  text-align: center;\n}\n\n.bgFooter {\n  // ::v-deep .van-tabbar-item--active {\n  //   @include themify() {\n  //     background: themed(\"footer_background\");\n  //   }\n  // }\n\n  // ::v-deep .van-tabbar-item--active {\n  //   @include themify() {\n  //     color: themed(\"color_main\") !important;\n  //   }\n  // }\n}\n\n// .bg-night {\n//   ::v-deep .van-tabbar-item--active {\n//     background: $night;\n//   }\n// }\n\n.tabbar-footer {\n  position: relative;\n  .bgc {\n    position: absolute;\n    left: 0;\n    top: 6px;\n    background-color: #f5f5f8;\n    width: calc(100% - 60px);\n    height: 60px;\n    border-radius: 30px;\n    margin: 0 30px;\n  }\n}\n::v-deep .van-tabbar-item__text {\n  position: relative;\n  z-index: 99;\n  // color: #d2d2dc;\n}\n::v-deep .van-tabbar-item {\n  color: #d2d2dc;\n}\n::v-deep .van-tabbar-item--active {\n  color: #9691fa !important;\n}\n</style>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAwFA,SAAAA,UAAA;AACA,SAAAC,UAAA;AACA;EACAC,KAAA;IACAC,QAAA;MACAC,IAAA,EAAAC,OAAA;MACAC,OAAA;IACA;EACA;EACAC,UAAA;EACAC,QAAA;IACA,GAAAR,UAAA;MACAS,KAAA;IACA;EACA;EACAC,KAAA;IACA;MACAT,UAAA;MACAU,MAAA;MACAC,IAAA;MACAC,MAAA;MACAC,KAAA;MACAC,QAAA;MACAC,KAAA;IACA;EACA;EACAC,QAAA;IACA,KAAAL,IAAA;MACAD,MAAA,EAAAO,OAAA,4BAAAT,KAAA;MACAU,QAAA,EAAAD,OAAA,4BAAAT,KAAA;IACA;IACA,KAAAI,MAAA;MACAF,MAAA,EAAAO,OAAA,4BAAAT,KAAA;MACAU,QAAA,EAAAD,OAAA,4BAAAT,KAAA;IACA;IACA,KAAAK,KAAA;MACAH,MAAA,EAAAO,OAAA,4BAAAT,KAAA;MACAU,QAAA,EAAAD,OAAA,4BAAAT,KAAA;IACA;IACA,KAAAM,QAAA;MACAJ,MAAA,EAAAO,OAAA,4BAAAT,KAAA;MACAU,QAAA,EAAAD,OAAA,4BAAAT,KAAA;IACA;IACA,KAAAO,KAAA;MACAL,MAAA,EAAAO,OAAA,4BAAAT,KAAA;MACAU,QAAA,EAAAD,OAAA,4BAAAT,KAAA;IACA;EACA;AACA","ignoreList":[]},"metadata":{},"sourceType":"module","externalDependencies":[]}