- 怎么还没有审核通过啊?
怎么还没有审核通过啊?
04-30 - 用户地理位置授权弹窗如何监听用户点击了允许或者拒绝?
用户地理位置授权弹窗如何监听用户点击了允许或者拒绝? 场景是首页需要要根据用户当前位置信息设置当前所在城市,但是我点了下面的允许后其实我已经获取过用户的地理位置信息了 这个时候就会让用户很懵逼 我怎么监听用户这个允许或者拒绝的操作 我好在用户操作后在获取位置信息 [图片]
04-27 - getBackgroundAudioManager如何销毁?
getBackgroundAudioManager播放器如何销毁?播放器设置的监听方法如:onTimeUpdate onStop onEnded这些事件如何关闭监听?有没有offTimeUpdate?我打印getBackgroundAudioManage没有发现有销毁播放器和关闭监听的方法!
04-10 - createInnerAudioContext播放音频列表会中断?
我有一个音频列表 比如1,2,3,4,5,6, 每个项是不同的src 当前项播放完毕 自动切换到下一段的时候 这个时候会出现没有声音了 也没有触发任何error或者end事件 证明音频其实还在播放 就是没有声音了 其它手机没有问题 只有在ios手机上 并且微信版本8.0.57会出现这个问题 莫名其妙啊!
04-09 - 前后台背景播放器兼容性问题?
使用前后台背景播放器播放音频 在ios手机上和部分安卓手机上没有问题,但是在小米手机和三星手机上 会无意中断 小米手机熄屏的时候音频会中断,什么原因啊?
03-24 - 如何查看小程序cpu使用率?
如何查看小程序运行期间cpu使用率? https://developers.weixin.qq.com/miniprogram/dev/framework/performance/panel.html 官方说的这个根本无效 cpu一直都是0。 perfDog也无效 安装了 开发版根本没有这个东西
03-17 - 小米手机getBackgroundAudioManager熄屏后音频被暂停?
小米手机getBackgroundAudioManager播放器正在播放的的时候熄屏音频会被暂停,ios手机没有问题,其它安卓手机也没发现这个问题。
03-06 - 全局自定义组件和页面局部自定义组件的区别?
比如我有两个自定义组件A和B a组件是在全局声明usingComponents,的b组件是在页面局部声明usingComponents 为什么b组件无法接受到数据? 但是我要是把b组件也声明在全局就可以拿到数据? <A> <B :node="data"></B> </A>
02-26 - 如何实现视频整屏滑动切换?
<template> <div :class="$style['content-box']"> <swiper :class="$style['swiper-box']" :vertical="true" :circular="false" @change="handleSwiperChange" @animationFinish="handleAnimationFinish" > <swiper-item :item-id="item.id" v-for="item in sliceList" :key="item.id" :class="$style['swiper-item']" > <div :style="{background:item.color}" :class="$style['item-block']"> {{ item.id }} <p></p> 当前是第几个:{{ item.index }} </div> </swiper-item> </swiper> <p :class="$style['bottom-tips']">数据加载中</p> </div> </template> <script setup> import {ref,onMounted,computed} from "vue"; import {uuid} from "@/utils/util"; const swiperList = ref([]); const startIndex = ref(0); const endIndex = ref(2); const sliceList = ref([]); const isFetchLoading = ref(false); onMounted(()=>{ swiperList.value.push(...mockList()); sliceList.value = swiperList.value.slice(startIndex.value,endIndex.value+1); }) function handleSwiperChange($event){ } function handleAnimationFinish($event){ console.log($event,'$event') let {current,currentItemId} = $event.detail; let currentIndex = swiperList.value.findIndex((item)=>item.id == currentItemId); console.log(currentIndex,'修正') let diffAfter = swiperList.value.length - 1 - currentIndex; startIndex.value = currentIndex - 1<0?0:currentIndex - 1; endIndex.value = currentIndex+1<2?2:currentIndex+1; sliceList.value = swiperList.value.slice(startIndex.value,endIndex.value+1); console.log(startIndex.value,endIndex.value,'diffAfter',sliceList.value); // 当尾部数据小于1条的时候 从服务端请求数据 if(diffAfter <= 1&&!isFetchLoading.value){ isFetchLoading.value = true; setTimeout(()=>{ swiperList.value.push(...mockList()); isFetchLoading.value = false; },2000); } } // 模拟请求数据 3 012 345 function mockList(){ let list = []; for(let i = 0;i<3;i++){ list.push({ id:uuid(), color:color16(), index:swiperList.value.length+i, }) } return list; } // 随机生成颜色值 function color16(){ let r = Math.floor(Math.random()*256); let g = Math.floor(Math.random()*256); let b = Math.floor(Math.random()*256); let color = '#'+r.toString(16)+g.toString(16)+b.toString(16); return color; } </script> <style module lang="scss"> .content-box{ height: 100vh; } .swiper-box,.swiper-item,.swiper-item-box{ height: 100%; position: relative; } .item-block{ color: #fff; height: 100%; padding-top: 600px; box-sizing: border-box; text-align: center; } .bottom-tips{ position: fixed; z-index: -1; left: 0; bottom: 0; right: 0; height: 100px; line-height: 100px; background: rgb(73, 73, 196); text-align: center; color: #fff; } </style> 1:大概简单实现了一下视频上下滑动效果; 2:简单实现了滑动到尾部的时候加载更多数据; 3:简单实现了虚拟列表;
2024-12-12 - 商户如何申请连续包月服务?类似购买爱奇艺会员-连续包月
商户如何申请连续包月服务?类似购买爱奇艺会员-连续包月
2024-11-27