Files
fini-ui/src/views/IPO/components/IpoNav.vue
T

56 lines
1.4 KiB
Vue
Raw Normal View History

2023-04-12 14:40:19 +08:00
<template>
<div class="item">
<a @click="scrollto(index)" v-for="(item, index) in list" :key="index">{{ item }}</a>
</div>
</template>
<script lang="ts">
export default {
name: "IpoNav",
};
</script>
<script lang="ts" setup>
import { ref, defineProps } from "vue"
import i18n from '@/locales'
import { getCurrentInstance } from 'vue'
const { proxy } = (getCurrentInstance() as any)
const props = defineProps<{ scroll: Function }>()
const scrollto = (index: number) => {
const ref11 = "i" + index + "TOP"
console.log(ref11)
props.scroll(ref11)
}
const list = ref([proxy.$t('ipo.CompanyInformation'), proxy.$t('ipo.TypeofListing.TypeofListing'), proxy.$t('ipo.Offering.Offering'), proxy.$t('ipo.advisers.Adviser'), proxy.$t('ipo.Timetable.Timetable'), proxy.$t('ipo.Documents.Documents'), proxy.$t('ipo.TransactionCosts.TransactionCosts')])
</script>
<style lang="scss" scoped>
.item {
margin-top: 18px;
display: flex;
2023-04-16 20:51:53 +08:00
@media screen and (max-width: 768px) {
margin-top: 0px;
width: 100vw;
overflow-x: scroll;
}
2023-04-12 14:40:19 +08:00
a {
// margin-left: 5px;
padding: 5px 10px;
font-size: 20px;
color: #738B9B;
font-weight: 700;
border-radius: 30px;
text-decoration: none;
2023-04-16 20:51:53 +08:00
width: fit-content;
white-space: nowrap;
2023-04-12 14:40:19 +08:00
&:hover {
background-color: #1C3F56;
color: #fff;
cursor: pointer;
}
}
}
</style>