|
@@ -1,21 +1,42 @@
|
|
|
-import { defineComponent } from 'vue'
|
|
|
+import { defineComponent, onMounted, ref } from 'vue'
|
|
|
import styles from './member-active.module.less'
|
|
|
import p1 from './images/active/1.png'
|
|
|
import p2 from './images/active/2.png'
|
|
|
import p3 from './images/active/3.png'
|
|
|
import btn from './images/active/btn.png'
|
|
|
import { useRouter } from 'vue-router'
|
|
|
+import { postMessage } from '@/helpers/native-message'
|
|
|
+import { Icon } from 'vant'
|
|
|
|
|
|
export default defineComponent({
|
|
|
setup() {
|
|
|
const router = useRouter()
|
|
|
+ const navBarHeight = ref(0)
|
|
|
|
|
|
const onDetail = () => {
|
|
|
router.push('/memberCenter')
|
|
|
}
|
|
|
|
|
|
+ onMounted(() => {
|
|
|
+ postMessage({ api: 'getNavHeight' }, res => {
|
|
|
+ const { content } = res as any
|
|
|
+ const dpi = content.dpi || 2
|
|
|
+ if (content.navHeight) {
|
|
|
+ const navHeight = content.navHeight / dpi``
|
|
|
+ navBarHeight.value = navHeight
|
|
|
+ }
|
|
|
+ })
|
|
|
+ })
|
|
|
return () => (
|
|
|
<div class={styles.memberActive}>
|
|
|
+ <Icon
|
|
|
+ name="arrow-left"
|
|
|
+ class={styles.backIcon}
|
|
|
+ style={{
|
|
|
+ top: `calc(${navBarHeight.value}px + 16px)`
|
|
|
+ }}
|
|
|
+ />
|
|
|
+
|
|
|
<img src={p1} />
|
|
|
<img src={p2} />
|
|
|
<img src={p3} />
|