|
@@ -1,5 +1,5 @@
|
|
|
<script setup>
|
|
|
-import { onMounted } from 'vue'
|
|
|
+import { onMounted, ref, computed } from 'vue'
|
|
|
import { useRouter } from 'vue-router'
|
|
|
import useSizeAdapt from "@/useFunctions/useSizeAdapt"
|
|
|
|
|
@@ -23,8 +23,8 @@ const reverseArray = (array) => {
|
|
|
return array.slice().reverse()
|
|
|
}
|
|
|
|
|
|
-const goPaintingDetail = () =>{
|
|
|
- router.push('/shuanggou-painting-detail?idx=0')
|
|
|
+const goPaintingDetail = () => {
|
|
|
+ router.push(`/shuanggou-painting-detail?idx=0&&m=${curIndex.value}`)
|
|
|
}
|
|
|
|
|
|
const x = window.innerWidth / window.innerHeight
|
|
@@ -34,24 +34,63 @@ onMounted(() => {
|
|
|
})
|
|
|
|
|
|
const text = [
|
|
|
- '设色,国画中晕染彩色的意思,',
|
|
|
- '画面中只要出现彩色就可以说是设色作品。',
|
|
|
- '与设色相反的是“水墨”,指画面中不出现彩色,',
|
|
|
- '或者极少出现彩色的,以墨色为主绘制的作品。',
|
|
|
- '双钩,中国画技法名。用线条钩描物象的轮廓,',
|
|
|
- '通称“勾勒”,因基本上是用左右或上下两笔钩描合拢,',
|
|
|
- '故亦称“双钩”。大部用于工笔花鸟画。',
|
|
|
- '又旧时摹搨法书。沿字的笔迹两边用细劲的墨线钩出轮廓,',
|
|
|
- '也叫“双钩”;双钩后填墨的称为“双钩廓填”。'
|
|
|
+ ['双钩,中国画技法名。用线条钩描',
|
|
|
+ '物象的轮廓,通称“勾勒”,因基本上',
|
|
|
+ '是用左右或上下两笔钩描合拢,故亦',
|
|
|
+ '称“双钩”。大部用于工笔花鸟画。又',
|
|
|
+ '旧时摹搨法书。沿字的笔迹两边用细',
|
|
|
+ '劲的墨线线钩出轮廓,也叫“双钩”;',
|
|
|
+ '双钩后填墨的称为“双钩”'],
|
|
|
+ ['设色,国画中晕染彩色的意思,“廓',
|
|
|
+ '填”。画面中只要出现彩色就可以说',
|
|
|
+ '是设色作品。与设色相反的是“水墨”,',
|
|
|
+ '指画面中不出现彩色,或者极少出现',
|
|
|
+ '彩色的,以墨色为主绘制的作品。', ]
|
|
|
]
|
|
|
+
|
|
|
+const curIndex = ref(0)
|
|
|
+
|
|
|
+const lastX = ref(0)
|
|
|
+// 开始滑动
|
|
|
+const handletouchstart = (event) => {
|
|
|
+ lastX.value = event.changedTouches[0].pageX
|
|
|
+}
|
|
|
+
|
|
|
+// 监听活动
|
|
|
+const touchEnd = (event) => {
|
|
|
+ let currentX = event.changedTouches[0].pageX
|
|
|
+ let tx = currentX - lastX.value
|
|
|
+ if (tx < 0) {
|
|
|
+ if (curIndex.value == 0) {
|
|
|
+ curIndex.value = 1
|
|
|
+ }
|
|
|
+ } else if (tx > 0) {
|
|
|
+ if (curIndex.value == 1) {
|
|
|
+ curIndex.value = 0
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+const goToSlide = (index) => {
|
|
|
+ curIndex.value = index
|
|
|
+}
|
|
|
+
|
|
|
+const curPercentage = computed(() => {
|
|
|
+ return curIndex.value
|
|
|
+}
|
|
|
+)
|
|
|
+
|
|
|
</script>
|
|
|
|
|
|
<template>
|
|
|
<div
|
|
|
class="home"
|
|
|
+ @touchstart="handletouchstart($event)"
|
|
|
+ @touchend="touchEnd($event)"
|
|
|
>
|
|
|
<div class="title">
|
|
|
- 双钩设色
|
|
|
+ <span :style="{ color: curIndex == 1 ? 'rgba(71, 71, 71, 0.50)' : '' }">双钩</span>
|
|
|
+ <span :style="{ color: curIndex == 0 ? 'rgba(71, 71, 71, 0.50)' : '' }">设色</span>
|
|
|
</div>
|
|
|
|
|
|
<div class="shuanggou-yezi">
|
|
@@ -73,16 +112,36 @@ const text = [
|
|
|
> -->
|
|
|
<div
|
|
|
class="text"
|
|
|
- :style="{top: x> 0.5 ?'auto':'',bottom: x > 0.5 ? '0vh':''}"
|
|
|
+ :style="{ top: x > 0.5 ? 'auto' : '', bottom: x > 0.5 ? '15vh' : 'auto' }"
|
|
|
>
|
|
|
<div
|
|
|
- v-for="(item,index) in reverseArray(text)"
|
|
|
+ v-for="(item, index) in reverseArray(text[curIndex])"
|
|
|
:key="index"
|
|
|
>
|
|
|
{{ item }}
|
|
|
</div>
|
|
|
+ <!-- <img
|
|
|
+ v-show="curIndex == 0"
|
|
|
+ src="@/assets/images/shuanggou-text.png"
|
|
|
+ alt=""
|
|
|
+ > -->
|
|
|
+ <!-- <img
|
|
|
+ v-show="curIndex == 1"
|
|
|
+ src="@/assets/images/shese-text.png"
|
|
|
+ alt=""
|
|
|
+ > -->
|
|
|
</div>
|
|
|
|
|
|
+ <ProgressBar
|
|
|
+ class="progress-bar"
|
|
|
+ :totle-unit="2"
|
|
|
+ :cur-percentage="curPercentage"
|
|
|
+ color-ac="#7B916B"
|
|
|
+ color="#7B916B60"
|
|
|
+ type="1"
|
|
|
+ @go-to-slide="goToSlide"
|
|
|
+ />
|
|
|
+
|
|
|
<img
|
|
|
class="right-bottom"
|
|
|
src="@/assets/images/right-bottom.png"
|
|
@@ -106,13 +165,16 @@ const text = [
|
|
|
</template>
|
|
|
|
|
|
<style lang='less' scoped>
|
|
|
-.home{
|
|
|
+*{
|
|
|
+ transition: all 1s ease;
|
|
|
+}
|
|
|
+.home {
|
|
|
width: 100%;
|
|
|
height: 100%;
|
|
|
position: relative;
|
|
|
background: #ffffff;
|
|
|
|
|
|
- .title{
|
|
|
+ .title {
|
|
|
color: #474747;
|
|
|
font-size: calc(48 / v-bind('windowSizeWhenDesignForRef') * v-bind('windowSizeInCssForRef'));
|
|
|
line-height: calc(48 / v-bind('windowSizeWhenDesignForRef') * v-bind('windowSizeInCssForRef'));
|
|
@@ -123,57 +185,77 @@ const text = [
|
|
|
top: 26%;
|
|
|
letter-spacing: 10px;
|
|
|
}
|
|
|
- .shuanggou-yezi{
|
|
|
+
|
|
|
+ .shuanggou-yezi {
|
|
|
width: 100%;
|
|
|
animation: fade-in 2s forwards;
|
|
|
position: relative;
|
|
|
- z-index:2;
|
|
|
+ z-index: 2;
|
|
|
|
|
|
@keyframes fade-in {
|
|
|
- 0%{
|
|
|
+ 0% {
|
|
|
opacity: 0;
|
|
|
}
|
|
|
- 100%{
|
|
|
+
|
|
|
+ 100% {
|
|
|
opacity: 1;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- >img{
|
|
|
+ >img {
|
|
|
width: 100%;
|
|
|
margin-top: -3%;
|
|
|
}
|
|
|
- >.hotspot-1{
|
|
|
+
|
|
|
+ >.hotspot-1 {
|
|
|
position: absolute;
|
|
|
bottom: 28%;
|
|
|
left: 17%;
|
|
|
pointer-events: initial;
|
|
|
- z-index:3;
|
|
|
+ z-index: 3;
|
|
|
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- .text{
|
|
|
+ .text {
|
|
|
display: flex;
|
|
|
position: absolute;
|
|
|
- left: 15vw;
|
|
|
- top: 60vh;
|
|
|
+ right: 30%;
|
|
|
+ top: 40vh;
|
|
|
// top: calc(50 /v-bind('windowSizeWhenDesignForRef')/v-bind('windowSizeInCssForRef'));
|
|
|
color: #707F48;
|
|
|
- font-size: calc(16 /v-bind('windowSizeWhenDesignForRef') * v-bind('windowSizeInCssForRef'));
|
|
|
+ font-size: calc(18 /v-bind('windowSizeWhenDesignForRef') * v-bind('windowSizeInCssForRef'));
|
|
|
line-height: calc(26 /v-bind('windowSizeWhenDesignForRef') * v-bind('windowSizeInCssForRef'));
|
|
|
font-family: 'KaiTi';
|
|
|
- >div{
|
|
|
+
|
|
|
+ >div {
|
|
|
writing-mode: vertical-rl;
|
|
|
letter-spacing: 2px;
|
|
|
+ text-align: justify;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- .right-bottom{
|
|
|
+ .right-bottom {
|
|
|
width: 100%;
|
|
|
position: absolute;
|
|
|
bottom: 0;
|
|
|
right: 0;
|
|
|
}
|
|
|
+
|
|
|
+ .progress-bar{
|
|
|
+ position: absolute;
|
|
|
+ left: 0;
|
|
|
+ bottom: 15px;
|
|
|
+ left: 50%;
|
|
|
+ transform: translateX(-50%);
|
|
|
+ width: 90%;
|
|
|
+ height: 15px;
|
|
|
+ z-index: 3;
|
|
|
+ color: #e1edd95d;
|
|
|
+ transition: all 1s;
|
|
|
+ z-index: 1;
|
|
|
+ }
|
|
|
+
|
|
|
.system-btns {
|
|
|
width: 100%;
|
|
|
padding: 0 calc(20 / v-bind(windowSizeWhenDesignForRef) * v-bind(windowSizeInCssForRef));
|