2022-05-10 18:18:59 +08:00
|
|
|
|
<template>
|
2022-05-31 14:31:21 +08:00
|
|
|
|
<div class="photo" :class="[isHide ? 'home-active' : '']" @click="isHide = true" :style="{height: height + 'px'}">
|
2022-05-16 18:04:46 +08:00
|
|
|
|
<div class="photo-top" data-html2canvas-ignore>
|
2022-05-18 18:06:39 +08:00
|
|
|
|
<div class="photo-top__middle" @click="isShowAlbum = true">
|
2022-06-01 11:23:42 +08:00
|
|
|
|
<span>保存至:{{ albumName || '系统相册' }}</span>
|
2022-05-17 16:13:03 +08:00
|
|
|
|
<image src="./images/to-right.png" />
|
2022-05-16 18:04:46 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
2022-05-31 18:09:17 +08:00
|
|
|
|
<div class="photo-wrapper">
|
|
|
|
|
|
<div ref="waterMarker" class="waterMarker-wrapper" :style="{height: canvasHeight + 'px'}">
|
|
|
|
|
|
<img class="waterMarker-img" :src="img" mode="widthFix" @load="onImgLoad" />
|
|
|
|
|
|
<div
|
|
|
|
|
|
class="watermark"
|
|
|
|
|
|
v-if="currIndex > -1 && currWatermarkConfig.length"
|
2022-06-17 17:56:36 +08:00
|
|
|
|
:style="{left: x + 'px', top: y + 'px', transform: 'scale(' + watermarkScale + ')', transformOrigin: 'left' }"
|
2022-05-31 18:09:17 +08:00
|
|
|
|
@touchstart="onTouchstart"
|
|
|
|
|
|
@touchmove="onTouchmove">
|
2022-07-28 16:49:56 +08:00
|
|
|
|
<component ref="WatermarkItem" :addressInfo="address" :is="'Watermark' + (currIndex + 1)" :config="currWatermarkConfig"></component>
|
2022-05-31 18:09:17 +08:00
|
|
|
|
<div v-if="!isHide" @click.stop="currIndex = -1" class="watermark-close" data-html2canvas-ignore>
|
|
|
|
|
|
<image src="./images/close-b.png" />
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<span v-if="!isHide" class="watermark-edit" @click.stop="toEdit" data-html2canvas-ignore>编辑</span>
|
2022-05-31 14:31:21 +08:00
|
|
|
|
</div>
|
2022-05-25 10:49:43 +08:00
|
|
|
|
</div>
|
2022-05-16 18:04:46 +08:00
|
|
|
|
</div>
|
2022-05-17 18:00:35 +08:00
|
|
|
|
<div class="photo-bottom" data-html2canvas-ignore>
|
2022-05-16 18:04:46 +08:00
|
|
|
|
<div class="photo-bottom__top">
|
2022-05-31 12:10:13 +08:00
|
|
|
|
<span @click.stop="isHide = true">取消</span>
|
2022-05-16 18:04:46 +08:00
|
|
|
|
<h2>水印</h2>
|
2022-05-25 10:49:43 +08:00
|
|
|
|
<span @click.stop="isHide = true">确定</span>
|
2022-05-16 18:04:46 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
<div class="waterlist">
|
2022-05-27 14:20:33 +08:00
|
|
|
|
<div
|
|
|
|
|
|
class="water-item"
|
|
|
|
|
|
:class="[currIndex === -1 ? 'active' : '']"
|
|
|
|
|
|
key="-1"
|
|
|
|
|
|
@click.stop="currIndex = -1">
|
|
|
|
|
|
<image src="./images/clear.png" />
|
|
|
|
|
|
<image class="checked" v-if="currIndex === -1" src="./images/xuanzhong.png" />
|
|
|
|
|
|
<div class="water-item__bottom">不使用水印</div>
|
|
|
|
|
|
</div>
|
2022-05-16 18:04:46 +08:00
|
|
|
|
<div
|
|
|
|
|
|
class="water-item"
|
|
|
|
|
|
:class="[currIndex === index ? 'active' : '']"
|
2022-05-18 18:06:39 +08:00
|
|
|
|
v-for="(item, index) in watermarkList"
|
|
|
|
|
|
:key="item.id"
|
2022-05-25 10:49:43 +08:00
|
|
|
|
@click.stop="currIndex = index">
|
2022-05-25 15:21:24 +08:00
|
|
|
|
<image :src="item.thum" />
|
2022-05-31 14:08:05 +08:00
|
|
|
|
<span v-show="currIndex === index" @click.stop="toEdit">编辑</span>
|
2022-05-27 14:20:33 +08:00
|
|
|
|
<image class="checked" v-if="currIndex === index" src="./images/xuanzhong.png" />
|
2022-05-16 18:04:46 +08:00
|
|
|
|
<div class="water-item__bottom">{{ item.name }}</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
2022-05-31 16:24:13 +08:00
|
|
|
|
<div class="photo-tabbar" data-html2canvas-ignore>
|
2022-05-31 14:08:05 +08:00
|
|
|
|
<h2>编辑图片</h2>
|
|
|
|
|
|
<div class="tabbar-wrapper">
|
|
|
|
|
|
<div class="item" @click.stop="back">
|
|
|
|
|
|
<image src="./images/fanhui-black.png" />
|
|
|
|
|
|
<div>返回</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<div class="item" @click.stop="isHide = false">
|
|
|
|
|
|
<image src="./images/shuiyin-white.png" />
|
|
|
|
|
|
<div>水印</div>
|
|
|
|
|
|
</div>
|
2022-05-31 16:24:13 +08:00
|
|
|
|
<div class="item" @click.stop="toClipping">
|
2022-05-31 14:08:05 +08:00
|
|
|
|
<image src="./images/jiancai.png" />
|
|
|
|
|
|
<div>剪裁</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<div class="item" @click.stop="save">
|
|
|
|
|
|
<image src="./images/shangchuan-black.png" />
|
|
|
|
|
|
<div>上传</div>
|
|
|
|
|
|
</div>
|
2022-05-17 18:00:35 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
2022-05-27 09:59:46 +08:00
|
|
|
|
<u-popup v-model="isShowAlbum" :closeable="false" border-radius="32" height="70%" mode="bottom">
|
|
|
|
|
|
<div class="album">
|
|
|
|
|
|
<div class="top">
|
2022-05-30 15:55:24 +08:00
|
|
|
|
<span @click="isShowAlbum = false">取消</span>
|
2022-05-27 09:59:46 +08:00
|
|
|
|
<span @click="onConfirm">确定</span>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<scroll-view scroll-y class="album-list__wrapper">
|
|
|
|
|
|
<div
|
|
|
|
|
|
class="item"
|
2022-05-30 11:19:42 +08:00
|
|
|
|
@click="albumIndex = index"
|
2022-05-27 09:59:46 +08:00
|
|
|
|
v-for="(item, index) in albumList"
|
|
|
|
|
|
:key="index"
|
2022-05-30 11:19:42 +08:00
|
|
|
|
:class="[albumIndex === index ? 'active' : '']">
|
|
|
|
|
|
<image class="checked" v-if="albumIndex === index" src="./images/xuanzhong.png" />
|
2022-05-27 09:59:46 +08:00
|
|
|
|
<image class="icon" v-if="!item.lastPhotoUrl" src="./images/icon.png" />
|
|
|
|
|
|
<image class="img" v-if="item.lastPhotoUrl" :src="item.lastPhotoUrl" mode="aspectFill" />
|
|
|
|
|
|
<div class="item-bottom">
|
|
|
|
|
|
<h2>{{ item.albumName }}</h2>
|
|
|
|
|
|
<div class="item-bottom__info">
|
|
|
|
|
|
<div class="left">
|
|
|
|
|
|
<span>今日新增</span>
|
|
|
|
|
|
<i>{{ item.dayPhtoto }}</i>
|
|
|
|
|
|
<span>张</span>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<div class="right">
|
|
|
|
|
|
<image src="./images/zhaopianshuliang.png" />
|
|
|
|
|
|
<span>{{ item.photoTotal || 0 }}</span>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</scroll-view>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</u-popup>
|
2022-05-10 18:18:59 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
|
|
<script>
|
2022-05-16 18:04:46 +08:00
|
|
|
|
import Watermark1 from './components/watermark/Watermark1'
|
|
|
|
|
|
import Watermark2 from './components/watermark/Watermark2'
|
|
|
|
|
|
import Watermark3 from './components/watermark/Watermark3'
|
|
|
|
|
|
import Watermark4 from './components/watermark/Watermark4'
|
|
|
|
|
|
import Watermark5 from './components/watermark/Watermark5'
|
|
|
|
|
|
import Watermark6 from './components/watermark/Watermark6'
|
|
|
|
|
|
import Watermark7 from './components/watermark/Watermark7'
|
|
|
|
|
|
import Watermark8 from './components/watermark/Watermark8'
|
2022-07-28 16:23:32 +08:00
|
|
|
|
import { mapActions, mapState } from 'vuex'
|
2022-05-16 18:04:46 +08:00
|
|
|
|
|
2022-05-10 18:18:59 +08:00
|
|
|
|
export default {
|
|
|
|
|
|
name: 'Watermark',
|
|
|
|
|
|
|
|
|
|
|
|
appName: '水印相机',
|
|
|
|
|
|
|
2022-05-16 18:04:46 +08:00
|
|
|
|
components: {
|
|
|
|
|
|
Watermark1,
|
|
|
|
|
|
Watermark2,
|
|
|
|
|
|
Watermark3,
|
|
|
|
|
|
Watermark4,
|
|
|
|
|
|
Watermark5,
|
|
|
|
|
|
Watermark6,
|
|
|
|
|
|
Watermark7,
|
|
|
|
|
|
Watermark8
|
|
|
|
|
|
},
|
|
|
|
|
|
|
2022-05-10 18:18:59 +08:00
|
|
|
|
data () {
|
|
|
|
|
|
return {
|
2022-05-17 14:58:10 +08:00
|
|
|
|
img: '',
|
2022-06-17 17:56:36 +08:00
|
|
|
|
currIndex: 0,
|
2022-05-27 09:59:46 +08:00
|
|
|
|
isHide: true,
|
2022-05-16 18:04:46 +08:00
|
|
|
|
height: '100%',
|
2022-05-18 18:06:39 +08:00
|
|
|
|
waterSrc: '',
|
2022-06-01 11:23:42 +08:00
|
|
|
|
albumId: '',
|
2022-05-18 18:06:39 +08:00
|
|
|
|
albumName: '',
|
2022-05-30 11:19:42 +08:00
|
|
|
|
albumIndex: 0,
|
2022-05-18 18:06:39 +08:00
|
|
|
|
watermarkList: [],
|
|
|
|
|
|
isShowAlbum: false,
|
2022-05-24 13:49:03 +08:00
|
|
|
|
albumList: [],
|
2022-05-25 10:49:43 +08:00
|
|
|
|
address: {},
|
|
|
|
|
|
x: 32,
|
2022-06-01 16:53:30 +08:00
|
|
|
|
y: 24,
|
2022-05-25 10:49:43 +08:00
|
|
|
|
startX: 0,
|
2022-06-16 09:00:13 +08:00
|
|
|
|
watermarkScale: 1,
|
2022-05-25 10:49:43 +08:00
|
|
|
|
startY: 0,
|
|
|
|
|
|
canvasHeight: 0
|
2022-05-18 18:06:39 +08:00
|
|
|
|
}
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
computed: {
|
|
|
|
|
|
defaultValue () {
|
|
|
|
|
|
if (!this.albumList.length) {
|
|
|
|
|
|
return [0]
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
return [this.albumList.map(v => v.value).indexOf(this.albumId)]
|
2022-05-19 14:43:42 +08:00
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
currWatermarkConfig () {
|
|
|
|
|
|
if (this.currIndex < 0 || !this.watermarkList.length) return []
|
|
|
|
|
|
|
|
|
|
|
|
return this.watermarkList[this.currIndex].itemList
|
2022-07-28 16:23:32 +08:00
|
|
|
|
},
|
|
|
|
|
|
...mapState(['wxwork'])
|
2022-05-10 18:18:59 +08:00
|
|
|
|
},
|
|
|
|
|
|
|
2022-05-17 14:58:10 +08:00
|
|
|
|
onLoad (query) {
|
2022-05-18 18:06:39 +08:00
|
|
|
|
if (query.albumId) {
|
|
|
|
|
|
this.albumId = query.albumId
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2022-06-01 09:56:07 +08:00
|
|
|
|
this.img = decodeURIComponent(query.url)
|
2022-05-16 18:04:46 +08:00
|
|
|
|
this.height = uni.getSystemInfoSync().windowHeight
|
2022-05-18 18:06:39 +08:00
|
|
|
|
|
2022-07-29 09:22:57 +08:00
|
|
|
|
this.getLocation()
|
2022-05-25 15:21:24 +08:00
|
|
|
|
|
|
|
|
|
|
this.$nextTick(() => {
|
|
|
|
|
|
this.getWatermarkList()
|
|
|
|
|
|
})
|
2022-05-31 16:24:13 +08:00
|
|
|
|
uni.$on('cropper', e => {
|
|
|
|
|
|
this.img = e
|
|
|
|
|
|
this.x = 32
|
|
|
|
|
|
this.y = 200
|
|
|
|
|
|
})
|
|
|
|
|
|
},
|
|
|
|
|
|
|
2022-06-15 17:26:41 +08:00
|
|
|
|
mounted () {
|
2022-06-16 14:53:03 +08:00
|
|
|
|
// this.$nextTick(() => {
|
|
|
|
|
|
// document.body.addEventListener('touchmove', this.bindEvent, { passive: false })
|
|
|
|
|
|
// })
|
2022-06-15 17:26:41 +08:00
|
|
|
|
},
|
|
|
|
|
|
|
2022-05-31 16:24:13 +08:00
|
|
|
|
onUnload () {
|
|
|
|
|
|
uni.$off('cropper')
|
2022-05-10 18:18:59 +08:00
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
methods: {
|
2022-07-28 16:23:32 +08:00
|
|
|
|
...mapActions(['injectJWeixin', 'agentSign']),
|
2022-05-24 11:14:29 +08:00
|
|
|
|
|
2022-05-31 16:24:13 +08:00
|
|
|
|
toClipping () {
|
|
|
|
|
|
uni.navigateTo({
|
|
|
|
|
|
url: `./Clipping?url=${encodeURIComponent(this.img)}`
|
|
|
|
|
|
})
|
|
|
|
|
|
},
|
|
|
|
|
|
|
2022-06-15 17:26:41 +08:00
|
|
|
|
bindEvent (e) {
|
|
|
|
|
|
e.preventDefault()
|
|
|
|
|
|
},
|
|
|
|
|
|
|
2022-05-25 10:49:43 +08:00
|
|
|
|
onImgLoad () {
|
|
|
|
|
|
const img = document.querySelector('.waterMarker-img')
|
|
|
|
|
|
|
|
|
|
|
|
this.canvasHeight = img.clientHeight
|
2022-06-16 09:00:13 +08:00
|
|
|
|
this.watermarkScale = img.clientWidth / uni.getSystemInfoSync().windowWidth
|
2022-05-25 10:49:43 +08:00
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
onTouchstart (e) {
|
|
|
|
|
|
const isMobile = e.type !== 'mousemove'
|
|
|
|
|
|
const watermark = document.querySelector('.watermark')
|
|
|
|
|
|
if (isMobile) {
|
|
|
|
|
|
this.startX = e.touches[0].clientX - Number((watermark.style.left).replace('px', ''))
|
|
|
|
|
|
this.startY = e.touches[0].clientY - Number((watermark.style.top).replace('px', ''))
|
|
|
|
|
|
} else {
|
|
|
|
|
|
this.startX = e.clientX - Number((watermark.style.left).replace('px', ''))
|
|
|
|
|
|
this.startY = e.clientY -Number((watermark.style.top).replace('px', ''))
|
|
|
|
|
|
}
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
onTouchmove (e) {
|
|
|
|
|
|
const isMobile = e.type !== 'mousemove'
|
|
|
|
|
|
if (isMobile) {
|
|
|
|
|
|
this.x = e.touches[0].clientX - this.startX
|
|
|
|
|
|
this.y = e.touches[0].clientY - this.startY
|
|
|
|
|
|
} else {
|
|
|
|
|
|
this.x = e.clientX - this.startX
|
|
|
|
|
|
this.y = e.clientY - this.startY
|
|
|
|
|
|
}
|
|
|
|
|
|
},
|
|
|
|
|
|
|
2022-05-31 14:08:05 +08:00
|
|
|
|
toEdit () {
|
|
|
|
|
|
this.$refs.WatermarkItem.linkTo('./WatermarkConfig')
|
|
|
|
|
|
},
|
|
|
|
|
|
|
2022-05-16 18:04:46 +08:00
|
|
|
|
save () {
|
2022-05-19 14:43:42 +08:00
|
|
|
|
this.$loading()
|
2022-06-06 17:52:31 +08:00
|
|
|
|
this.isHide = true
|
2022-05-16 18:04:46 +08:00
|
|
|
|
this.$nextTick(() => {
|
2022-05-25 17:59:58 +08:00
|
|
|
|
html2canvas(this.$refs.waterMarker, {
|
2022-05-19 14:43:42 +08:00
|
|
|
|
allowTaint: true,
|
2022-06-01 09:56:07 +08:00
|
|
|
|
useCORS: true
|
2022-05-19 14:43:42 +08:00
|
|
|
|
}).then((canvas) => {
|
2022-06-01 10:54:22 +08:00
|
|
|
|
let dataURL = canvas.toDataURL('image/png')
|
|
|
|
|
|
const file = this.dataURLtoFile(dataURL, 'photo.png')
|
2022-05-19 14:43:42 +08:00
|
|
|
|
let formData = new FormData()
|
|
|
|
|
|
formData.append('file', file)
|
|
|
|
|
|
this.$http.post('/admin/file/add2?type=image', formData).then(res => {
|
|
|
|
|
|
if (res.code === 0) {
|
|
|
|
|
|
let info = {}
|
|
|
|
|
|
if (this.currIndex > -1) {
|
|
|
|
|
|
info = this.watermarkList[this.currIndex]
|
2022-05-18 18:06:39 +08:00
|
|
|
|
}
|
2022-05-19 14:43:42 +08:00
|
|
|
|
this.$http.post('/api/appalbumphoto/addOrUpdate', {
|
|
|
|
|
|
albumId: this.albumId,
|
|
|
|
|
|
photoUrl: res.data.url,
|
|
|
|
|
|
fileId: res.data.id,
|
|
|
|
|
|
watermarkType: this.currIndex > -1 ? info.watermarkType : '',
|
|
|
|
|
|
templateId: this.currIndex > -1 ? info.id : ''
|
|
|
|
|
|
}).then(res => {
|
|
|
|
|
|
if (res.code === 0) {
|
|
|
|
|
|
uni.$emit('update')
|
|
|
|
|
|
this.$u.toast('新增成功')
|
|
|
|
|
|
|
|
|
|
|
|
setTimeout(() => {
|
|
|
|
|
|
this.back()
|
|
|
|
|
|
}, 500)
|
2022-05-27 11:49:54 +08:00
|
|
|
|
} else {
|
|
|
|
|
|
this.$u.toast(res.msg)
|
2022-05-19 14:43:42 +08:00
|
|
|
|
}
|
|
|
|
|
|
})
|
|
|
|
|
|
}
|
2022-05-16 18:04:46 +08:00
|
|
|
|
})
|
2022-05-19 14:43:42 +08:00
|
|
|
|
}).catch(e => {
|
|
|
|
|
|
console.log(e)
|
|
|
|
|
|
})
|
2022-05-10 18:18:59 +08:00
|
|
|
|
})
|
2022-05-17 14:58:10 +08:00
|
|
|
|
},
|
|
|
|
|
|
|
2022-05-24 13:49:03 +08:00
|
|
|
|
getWeather (code) {
|
|
|
|
|
|
this.$http.post(`/api/bdweather/wdata?districtId=${code}`).then(res => {
|
|
|
|
|
|
if (res.code === 0) {
|
|
|
|
|
|
const data = res.data.result.now
|
|
|
|
|
|
|
|
|
|
|
|
uni.setStorageSync('address', {
|
|
|
|
|
|
...uni.getStorageSync('address'),
|
2022-06-01 15:24:07 +08:00
|
|
|
|
weather: `${data.text} ${data.temp}°` || ''
|
2022-05-24 13:49:03 +08:00
|
|
|
|
})
|
|
|
|
|
|
|
|
|
|
|
|
this.address = {
|
|
|
|
|
|
...uni.getStorageSync('address'),
|
2022-06-01 15:24:07 +08:00
|
|
|
|
weather: `${data.text} ${data.temp}°` || ''
|
2022-05-24 13:49:03 +08:00
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
})
|
|
|
|
|
|
},
|
|
|
|
|
|
|
2022-05-24 11:14:29 +08:00
|
|
|
|
getLocation () {
|
2022-07-28 16:23:32 +08:00
|
|
|
|
this.agentSign({
|
|
|
|
|
|
corpId: this.wxwork.config.corpId,
|
|
|
|
|
|
suiteId: this.wxwork.config.suiteId
|
|
|
|
|
|
}).then(() => {
|
|
|
|
|
|
this.injectJWeixin(['getLocation']).then(() => {
|
|
|
|
|
|
wx.getLocation({
|
|
|
|
|
|
type: 'wgs84',
|
|
|
|
|
|
success: res => {
|
|
|
|
|
|
var lat = res.latitude
|
|
|
|
|
|
var lng = res.longitude
|
|
|
|
|
|
this.$http.post('/api/appdvcpconfig/apiForward', `https://apis.map.qq.com/ws/geocoder/v1/?location=${lat},${lng}&key=3RZBZ-LZUCF-CT6J5-NWKZH-FCWOQ-UUFKY&get_poi=1`).then(res => {
|
|
|
|
|
|
if (res.code === 0) {
|
|
|
|
|
|
const data = res.data.result
|
|
|
|
|
|
uni.setStorageSync('address', {
|
|
|
|
|
|
lat,
|
|
|
|
|
|
lng,
|
|
|
|
|
|
address: data.address,
|
|
|
|
|
|
cityCode: `${data.ad_info.adcode}`
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
|
|
|
|
this.address = {
|
|
|
|
|
|
...uni.getStorageSync('address')
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
this.getWeather(`${data.ad_info.adcode}`)
|
2022-07-28 14:39:48 +08:00
|
|
|
|
}
|
2022-07-28 16:23:32 +08:00
|
|
|
|
})
|
|
|
|
|
|
},
|
|
|
|
|
|
error: res => {
|
|
|
|
|
|
console.log(res)
|
|
|
|
|
|
}
|
|
|
|
|
|
})
|
|
|
|
|
|
}).catch(e => {
|
2022-05-24 11:14:29 +08:00
|
|
|
|
})
|
|
|
|
|
|
})
|
|
|
|
|
|
},
|
|
|
|
|
|
|
2022-05-18 18:06:39 +08:00
|
|
|
|
dataURLtoFile (dataurl, filename) {
|
|
|
|
|
|
let arr = dataurl.split(',')
|
|
|
|
|
|
let mime = arr[0].match(/:(.*?);/)[1]
|
|
|
|
|
|
let bstr = atob(arr[1])
|
|
|
|
|
|
let n = bstr.length
|
|
|
|
|
|
let u8arr = new Uint8Array(n)
|
|
|
|
|
|
while (n--) {
|
|
|
|
|
|
u8arr[n] = bstr.charCodeAt(n)
|
|
|
|
|
|
}
|
|
|
|
|
|
return new File([u8arr], filename, { type: mime })
|
|
|
|
|
|
},
|
|
|
|
|
|
|
2022-05-27 09:59:46 +08:00
|
|
|
|
onConfirm () {
|
2022-05-30 14:46:56 +08:00
|
|
|
|
this.albumId = this.albumList[this.albumIndex].value
|
|
|
|
|
|
this.albumName = this.albumList[this.albumIndex].label
|
2022-05-27 09:59:46 +08:00
|
|
|
|
|
|
|
|
|
|
this.isShowAlbum = false
|
2022-05-18 18:06:39 +08:00
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
getWatermarkList () {
|
|
|
|
|
|
this.$http.post(`/api/appalbumtemplate/list?size=100&templateType=0`).then(res => {
|
|
|
|
|
|
if (res.code === 0) {
|
|
|
|
|
|
this.watermarkList = res.data.records
|
|
|
|
|
|
}
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
|
|
|
|
this.$http.post('/api/appalbum/list', null, {
|
2022-05-25 15:21:24 +08:00
|
|
|
|
params: {
|
2022-05-18 18:06:39 +08:00
|
|
|
|
size: 1000
|
|
|
|
|
|
}
|
|
|
|
|
|
}).then(res => {
|
|
|
|
|
|
if (res.code === 0) {
|
|
|
|
|
|
this.albumList = res.data.records.map(v => {
|
|
|
|
|
|
return {
|
2022-05-27 09:59:46 +08:00
|
|
|
|
...v,
|
2022-05-18 18:06:39 +08:00
|
|
|
|
label: v.albumName,
|
|
|
|
|
|
value: v.id
|
|
|
|
|
|
}
|
|
|
|
|
|
})
|
|
|
|
|
|
|
2022-06-01 11:23:42 +08:00
|
|
|
|
this.albumList.some((v, index) => {
|
|
|
|
|
|
if (this.albumId) {
|
|
|
|
|
|
if (v.value === this.albumId) {
|
|
|
|
|
|
this.albumIndex = index
|
|
|
|
|
|
this.albumName = v.label
|
|
|
|
|
|
|
|
|
|
|
|
return true
|
|
|
|
|
|
}
|
|
|
|
|
|
} else {
|
|
|
|
|
|
if (v.label === '系统相册') {
|
|
|
|
|
|
this.albumIndex = index
|
|
|
|
|
|
this.albumId = v.value
|
|
|
|
|
|
this.albumName = '系统相册'
|
|
|
|
|
|
|
|
|
|
|
|
return true
|
|
|
|
|
|
}
|
2022-05-30 11:22:39 +08:00
|
|
|
|
}
|
2022-06-01 11:23:42 +08:00
|
|
|
|
})
|
2022-05-18 18:06:39 +08:00
|
|
|
|
}
|
|
|
|
|
|
})
|
|
|
|
|
|
},
|
|
|
|
|
|
|
2022-05-17 14:58:10 +08:00
|
|
|
|
back () {
|
|
|
|
|
|
uni.navigateBack({
|
|
|
|
|
|
delta: 1
|
|
|
|
|
|
})
|
2022-05-10 18:18:59 +08:00
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
|
|
<style lang="scss" scoped>
|
|
|
|
|
|
.photo {
|
|
|
|
|
|
width: 100%;
|
2022-05-25 10:49:43 +08:00
|
|
|
|
background: #333;
|
2022-05-16 18:04:46 +08:00
|
|
|
|
overflow: hidden;
|
|
|
|
|
|
|
2022-05-31 18:09:17 +08:00
|
|
|
|
.photo-wrapper {
|
|
|
|
|
|
display: flex;
|
|
|
|
|
|
align-items: center;
|
|
|
|
|
|
justify-content: center;
|
|
|
|
|
|
position: absolute;
|
|
|
|
|
|
top: 128px;
|
|
|
|
|
|
left: 0;
|
|
|
|
|
|
width: 100%;
|
|
|
|
|
|
height: calc(100vh - 321px - 128px);
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2022-05-16 18:04:46 +08:00
|
|
|
|
.newImg {
|
|
|
|
|
|
position: fixed;
|
|
|
|
|
|
left: 0;
|
|
|
|
|
|
top: 0;
|
|
|
|
|
|
z-index: 11111;
|
|
|
|
|
|
width: 100%;
|
|
|
|
|
|
height: 100%;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2022-05-27 09:59:46 +08:00
|
|
|
|
.album {
|
|
|
|
|
|
height: 100%;
|
|
|
|
|
|
overflow: hidden;
|
|
|
|
|
|
|
|
|
|
|
|
.album-list__wrapper {
|
|
|
|
|
|
display: flex;
|
|
|
|
|
|
align-items: center;
|
|
|
|
|
|
flex-wrap: wrap;
|
|
|
|
|
|
justify-content: space-between;
|
|
|
|
|
|
|
|
|
|
|
|
.item {
|
|
|
|
|
|
display: inline-block;
|
|
|
|
|
|
position: relative;
|
|
|
|
|
|
width: 328px;
|
|
|
|
|
|
height: 328px;
|
|
|
|
|
|
margin-bottom: 32px;
|
|
|
|
|
|
box-shadow: 0px 4px 8px 0px rgba(17, 67, 110, 0.1);
|
|
|
|
|
|
border-radius: 16px;
|
|
|
|
|
|
overflow: hidden;
|
|
|
|
|
|
background: #EFF5FA;
|
|
|
|
|
|
|
|
|
|
|
|
&:nth-of-type(2n) {
|
|
|
|
|
|
margin-left: 30px;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
&.active {
|
|
|
|
|
|
border: 4px solid #2477F1;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
.img {
|
|
|
|
|
|
width: 100%;
|
|
|
|
|
|
height: 100%;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
.item-bottom {
|
|
|
|
|
|
position: absolute;
|
|
|
|
|
|
left: 0;
|
|
|
|
|
|
bottom: 0;
|
|
|
|
|
|
z-index: 1;
|
|
|
|
|
|
width: 100%;
|
|
|
|
|
|
padding: 20px 16px 16px;
|
|
|
|
|
|
background: linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.6) 100%);
|
|
|
|
|
|
box-shadow: 0px 4px 8px 0px rgba(17, 67, 110, 0.1);
|
|
|
|
|
|
|
|
|
|
|
|
& > h2 {
|
|
|
|
|
|
margin-bottom: 14px;
|
|
|
|
|
|
font-size: 32px;
|
|
|
|
|
|
color: #fff;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
.item-bottom__info {
|
|
|
|
|
|
display: flex;
|
|
|
|
|
|
align-items: center;
|
|
|
|
|
|
justify-content: space-between;
|
|
|
|
|
|
|
|
|
|
|
|
.right {
|
|
|
|
|
|
display: flex;
|
|
|
|
|
|
align-items: center;
|
|
|
|
|
|
justify-content: space-between;
|
|
|
|
|
|
width: 86px;
|
|
|
|
|
|
height: 48px;
|
|
|
|
|
|
padding: 0 8px;
|
|
|
|
|
|
color: #fff;
|
|
|
|
|
|
background: rgba(0, 0, 0, 0.5);
|
|
|
|
|
|
box-shadow: 0px 4px 8px 0px rgba(17, 67, 110, 0.1);
|
|
|
|
|
|
border-radius: 8px;
|
|
|
|
|
|
|
|
|
|
|
|
image {
|
|
|
|
|
|
width: 28px;
|
|
|
|
|
|
height: 28px;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
span {
|
|
|
|
|
|
font-size: 28px;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
.left {
|
|
|
|
|
|
span {
|
|
|
|
|
|
color: #c6c5c4;
|
|
|
|
|
|
font-size: 28px;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
i {
|
|
|
|
|
|
padding: 0 3px;
|
|
|
|
|
|
color: #fff;
|
|
|
|
|
|
font-size: 28px;
|
|
|
|
|
|
font-style: normal;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
& > span {
|
|
|
|
|
|
position: absolute;
|
|
|
|
|
|
left: 16px;
|
|
|
|
|
|
top: 16px;
|
|
|
|
|
|
z-index: 1;
|
|
|
|
|
|
width: 94px;
|
|
|
|
|
|
height: 40px;
|
|
|
|
|
|
line-height: 40px;
|
|
|
|
|
|
text-align: center;
|
|
|
|
|
|
color: #fff;
|
|
|
|
|
|
font-size: 28px;
|
|
|
|
|
|
background: #FF524F;
|
|
|
|
|
|
box-shadow: 0px 4px 8px 0px rgba(17, 67, 110, 0.1);
|
|
|
|
|
|
border-radius: 8px;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
.checked {
|
|
|
|
|
|
position: absolute;
|
|
|
|
|
|
top: 0;
|
|
|
|
|
|
right: 0;
|
|
|
|
|
|
z-index: 1;
|
|
|
|
|
|
width: 64px;
|
|
|
|
|
|
height: 64px;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
.icon {
|
|
|
|
|
|
position: absolute;
|
|
|
|
|
|
top: 50%;
|
|
|
|
|
|
left: 50%;
|
|
|
|
|
|
z-index: 1;
|
|
|
|
|
|
width: 80px;
|
|
|
|
|
|
height: 80px;
|
|
|
|
|
|
transform: translate(-50%, -50%);
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
scroll-view {
|
|
|
|
|
|
height: calc(100% - 96px);
|
|
|
|
|
|
padding: 0 32px;
|
|
|
|
|
|
font-size: 0;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
.top {
|
|
|
|
|
|
display: flex;
|
|
|
|
|
|
align-items: center;
|
|
|
|
|
|
justify-content: space-between;
|
|
|
|
|
|
height: 96px;
|
|
|
|
|
|
padding: 0 32px;
|
|
|
|
|
|
font-size: 32px;
|
|
|
|
|
|
color: #999;
|
|
|
|
|
|
font-weight: 600;
|
|
|
|
|
|
|
|
|
|
|
|
span:last-child {
|
|
|
|
|
|
color: #222;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2022-05-25 10:49:43 +08:00
|
|
|
|
.waterMarker-wrapper {
|
2022-05-31 18:09:17 +08:00
|
|
|
|
position: relative;
|
|
|
|
|
|
max-height: calc(100vh - 321px - 128px);
|
2022-05-25 10:49:43 +08:00
|
|
|
|
overflow: hidden;
|
|
|
|
|
|
|
|
|
|
|
|
.waterMarker-img {
|
2022-05-31 18:56:37 +08:00
|
|
|
|
max-width: 100%;
|
|
|
|
|
|
object-fit: cover;
|
2022-05-31 18:09:17 +08:00
|
|
|
|
max-height: calc(100vh - 321px - 128px);
|
2022-05-25 10:49:43 +08:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
.watermark {
|
|
|
|
|
|
position: absolute;
|
|
|
|
|
|
left: 32px;
|
2022-05-25 17:59:58 +08:00
|
|
|
|
z-index: 11;
|
2022-05-31 14:31:21 +08:00
|
|
|
|
padding: 8px;
|
2022-05-25 10:49:43 +08:00
|
|
|
|
color: #FFFFFF;
|
|
|
|
|
|
font-size: 28px;
|
2022-05-31 14:31:21 +08:00
|
|
|
|
border: 2px solid #FFFFFF;
|
|
|
|
|
|
|
|
|
|
|
|
.watermark-edit {
|
|
|
|
|
|
position: absolute;
|
|
|
|
|
|
right: 0;
|
|
|
|
|
|
top: 0;
|
|
|
|
|
|
z-index: 1;
|
|
|
|
|
|
width: 80px;
|
|
|
|
|
|
height: 48px;
|
|
|
|
|
|
line-height: 48px;
|
|
|
|
|
|
text-align: center;
|
|
|
|
|
|
background: #FFFFFF;
|
|
|
|
|
|
box-shadow: 0px 2px 4px 0px rgba(0, 0, 0, 0.5);
|
|
|
|
|
|
border-radius: 24px;
|
|
|
|
|
|
color: #222222;
|
|
|
|
|
|
font-size: 24px;
|
|
|
|
|
|
transform: translate(50%, -50%);
|
|
|
|
|
|
|
|
|
|
|
|
image {
|
|
|
|
|
|
width: 32px;
|
|
|
|
|
|
height: 32px;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
.watermark-close {
|
|
|
|
|
|
display: flex;
|
|
|
|
|
|
align-items: center;
|
|
|
|
|
|
justify-content: center;
|
|
|
|
|
|
position: absolute;
|
|
|
|
|
|
left: 0;
|
|
|
|
|
|
top: 0;
|
|
|
|
|
|
z-index: 1;
|
|
|
|
|
|
width: 48px;
|
|
|
|
|
|
height: 48px;
|
|
|
|
|
|
background: #FFFFFF;
|
|
|
|
|
|
border-radius: 50%;
|
|
|
|
|
|
box-shadow: 0px 2px 4px 0px rgba(0, 0, 0, 0.5);
|
|
|
|
|
|
transform: translate(-50%, -50%);
|
|
|
|
|
|
|
|
|
|
|
|
image {
|
|
|
|
|
|
width: 32px;
|
|
|
|
|
|
height: 32px;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
2022-05-25 10:49:43 +08:00
|
|
|
|
}
|
2022-05-16 18:04:46 +08:00
|
|
|
|
}
|
|
|
|
|
|
|
2022-05-25 10:49:43 +08:00
|
|
|
|
* {
|
|
|
|
|
|
box-sizing: border-box;
|
2022-05-16 18:04:46 +08:00
|
|
|
|
}
|
|
|
|
|
|
|
2022-05-17 18:00:35 +08:00
|
|
|
|
.photo-tabbar {
|
|
|
|
|
|
position: fixed;
|
|
|
|
|
|
bottom: 0;
|
|
|
|
|
|
left: 0;
|
|
|
|
|
|
z-index: 10;
|
|
|
|
|
|
width: 100%;
|
2022-05-31 18:09:17 +08:00
|
|
|
|
height: 321px;
|
2022-05-31 14:08:05 +08:00
|
|
|
|
background: #FFFFFF;
|
|
|
|
|
|
border-radius: 32px 32px 0px 0px;
|
|
|
|
|
|
border: 1px solid #DDDDDD;
|
|
|
|
|
|
overflow: hidden;
|
|
|
|
|
|
|
|
|
|
|
|
h2 {
|
|
|
|
|
|
width: 750px;
|
|
|
|
|
|
height: 96px;
|
|
|
|
|
|
line-height: 96px;
|
|
|
|
|
|
margin-bottom: 20px;
|
|
|
|
|
|
text-align: center;
|
|
|
|
|
|
color: #333333;
|
|
|
|
|
|
font-size: 28px;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
& > div {
|
|
|
|
|
|
align-items: center;
|
|
|
|
|
|
display: flex;
|
|
|
|
|
|
}
|
2022-05-17 18:00:35 +08:00
|
|
|
|
|
|
|
|
|
|
.item {
|
|
|
|
|
|
flex: 1;
|
|
|
|
|
|
text-align: center;
|
|
|
|
|
|
|
|
|
|
|
|
image {
|
|
|
|
|
|
width: 56px;
|
|
|
|
|
|
height: 56px;
|
2022-05-25 10:49:43 +08:00
|
|
|
|
margin-bottom: 6px;
|
2022-05-17 18:00:35 +08:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
div {
|
|
|
|
|
|
font-size: 28px;
|
2022-05-31 14:08:05 +08:00
|
|
|
|
color: #333;
|
2022-05-17 18:00:35 +08:00
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2022-05-16 18:04:46 +08:00
|
|
|
|
.photo-bottom {
|
|
|
|
|
|
position: fixed;
|
|
|
|
|
|
bottom: 0;
|
|
|
|
|
|
left: 0;
|
2022-05-25 17:59:58 +08:00
|
|
|
|
z-index: 111;
|
2022-05-16 18:04:46 +08:00
|
|
|
|
width: 100%;
|
|
|
|
|
|
height: 474px;
|
|
|
|
|
|
background: #FFFFFF;
|
|
|
|
|
|
border-radius: 32px 32px 0px 0px;
|
2022-05-25 10:49:43 +08:00
|
|
|
|
transition: all ease 0.3s;
|
2022-05-16 18:04:46 +08:00
|
|
|
|
|
|
|
|
|
|
.waterlist {
|
|
|
|
|
|
display: flex;
|
|
|
|
|
|
flex-wrap: wrap;
|
|
|
|
|
|
justify-content: space-between;
|
|
|
|
|
|
align-items: center;
|
|
|
|
|
|
height: calc(100% - 96px);
|
|
|
|
|
|
padding: 18px 16px;
|
|
|
|
|
|
overflow-y: auto;
|
|
|
|
|
|
|
|
|
|
|
|
.water-item {
|
|
|
|
|
|
display: flex;
|
|
|
|
|
|
position: relative;
|
|
|
|
|
|
align-items: center;
|
|
|
|
|
|
justify-content: center;
|
|
|
|
|
|
width: 352px;
|
|
|
|
|
|
height: 240px;
|
|
|
|
|
|
margin-bottom: 16px;
|
|
|
|
|
|
background: #2A3540;
|
|
|
|
|
|
border-radius: 8px;
|
|
|
|
|
|
overflow: hidden;
|
|
|
|
|
|
|
|
|
|
|
|
&.active {
|
|
|
|
|
|
border: 6px solid #408EF6;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
image {
|
2022-05-25 15:21:24 +08:00
|
|
|
|
width: 236px;
|
2022-05-16 18:04:46 +08:00
|
|
|
|
height: 200px;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2022-05-31 14:08:05 +08:00
|
|
|
|
span {
|
|
|
|
|
|
position: absolute;
|
|
|
|
|
|
left: 50%;
|
|
|
|
|
|
top: 50%;
|
|
|
|
|
|
z-index: 1;
|
|
|
|
|
|
width: 128px;
|
|
|
|
|
|
height: 56px;
|
|
|
|
|
|
line-height: 56px;
|
|
|
|
|
|
text-align: center;
|
|
|
|
|
|
background: rgba(0, 0, 0, 0.8);
|
|
|
|
|
|
border-radius: 8px;
|
|
|
|
|
|
color: #fff;
|
|
|
|
|
|
font-size: 32px;
|
|
|
|
|
|
transform: translate(-50%, -50%);
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2022-05-27 14:20:33 +08:00
|
|
|
|
&:first-child {
|
|
|
|
|
|
flex-direction: column;
|
|
|
|
|
|
background: #E4E7EB;
|
|
|
|
|
|
|
|
|
|
|
|
& > image {
|
|
|
|
|
|
width: 64px;
|
|
|
|
|
|
height: 64px;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
.water-item__bottom {
|
|
|
|
|
|
position: relative;
|
|
|
|
|
|
color: #8A93A4;
|
|
|
|
|
|
font-size: 28px;
|
|
|
|
|
|
background: transparent;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
.checked {
|
|
|
|
|
|
position: absolute;
|
|
|
|
|
|
top: 0;
|
|
|
|
|
|
right: 0;
|
|
|
|
|
|
z-index: 1;
|
|
|
|
|
|
width: 64px;
|
|
|
|
|
|
height: 64px;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2022-05-16 18:04:46 +08:00
|
|
|
|
.water-item__bottom {
|
|
|
|
|
|
position: absolute;
|
|
|
|
|
|
bottom: 0;
|
|
|
|
|
|
left: 0;
|
|
|
|
|
|
width: 100%;
|
|
|
|
|
|
height: 56px;
|
|
|
|
|
|
line-height: 56px;
|
|
|
|
|
|
color: #fff;
|
|
|
|
|
|
text-align: center;
|
|
|
|
|
|
font-size: 28px;
|
|
|
|
|
|
background: rgba(0, 0, 0, 0.7);
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
.photo-bottom__top {
|
|
|
|
|
|
display: flex;
|
|
|
|
|
|
align-items: center;
|
|
|
|
|
|
justify-content: space-between;
|
|
|
|
|
|
height: 96px;
|
|
|
|
|
|
padding: 0 32px;
|
|
|
|
|
|
|
|
|
|
|
|
image {
|
|
|
|
|
|
width: 40px;
|
|
|
|
|
|
height: 40px;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
h2 {
|
|
|
|
|
|
font-size: 28px;
|
|
|
|
|
|
color: #333;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
span {
|
|
|
|
|
|
font-size: 32px;
|
|
|
|
|
|
color: #222;
|
|
|
|
|
|
font-weight: 600;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
.photo-top {
|
|
|
|
|
|
display: flex;
|
|
|
|
|
|
position: fixed;
|
|
|
|
|
|
align-items: center;
|
2022-05-27 09:59:46 +08:00
|
|
|
|
justify-content: center;
|
2022-05-16 18:04:46 +08:00
|
|
|
|
top: 0;
|
|
|
|
|
|
left: 0;
|
|
|
|
|
|
z-index: 11;
|
|
|
|
|
|
width: 100%;
|
|
|
|
|
|
height: 128px;
|
|
|
|
|
|
padding: 0 32px;
|
|
|
|
|
|
background: rgba(0, 0, 0, 0.5);
|
|
|
|
|
|
|
|
|
|
|
|
& > image {
|
|
|
|
|
|
width: 28px;
|
|
|
|
|
|
height: 28px;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
& > span {
|
|
|
|
|
|
color: #cbcbcb;
|
|
|
|
|
|
font-size: 32px;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
.photo-top__middle {
|
|
|
|
|
|
display: flex;
|
|
|
|
|
|
align-items: center;
|
|
|
|
|
|
justify-content: center;
|
2022-05-24 16:31:10 +08:00
|
|
|
|
width: 400px;
|
2022-05-16 18:04:46 +08:00
|
|
|
|
height: 72px;
|
2022-05-17 16:13:03 +08:00
|
|
|
|
line-height: 1;
|
2022-05-16 18:04:46 +08:00
|
|
|
|
background: #0B111F;
|
|
|
|
|
|
border-radius: 40px;
|
|
|
|
|
|
font-size: 28px;
|
|
|
|
|
|
color: #cbcbcb;
|
|
|
|
|
|
|
2022-05-24 16:31:10 +08:00
|
|
|
|
span {
|
|
|
|
|
|
max-width: 70%;
|
|
|
|
|
|
white-space: nowrap;
|
|
|
|
|
|
overflow: hidden;
|
|
|
|
|
|
text-overflow: ellipsis;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2022-05-16 18:04:46 +08:00
|
|
|
|
image {
|
|
|
|
|
|
width: 32px;
|
|
|
|
|
|
height: 32px;
|
|
|
|
|
|
margin-left: 16px;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
&.home-active {
|
|
|
|
|
|
.photo-bottom {
|
|
|
|
|
|
transform: translateY(100%);
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
.watermark {
|
2022-05-31 14:31:21 +08:00
|
|
|
|
border-color: transparent;
|
2022-05-24 18:40:56 +08:00
|
|
|
|
// bottom: 38px;
|
2022-05-16 18:04:46 +08:00
|
|
|
|
}
|
|
|
|
|
|
}
|
2022-05-10 18:18:59 +08:00
|
|
|
|
}
|
|
|
|
|
|
</style>
|