选择城市

cyl/master-0804
wangxia 4 months ago
parent e2000c389e
commit c8bad587f4

@ -1,348 +1,352 @@
<script lang="ts">
import RootStore from '@xkit-yx/im-store-v2'
import V2NIM, { V2NIMConst } from 'nim-web-sdk-ng/dist/v2/NIM_UNIAPP_SDK'
import { getMsgContentTipByType } from './pages/NEUIKit/utils/msg'
import { STORAGE_KEY } from './pages/NEUIKit/utils/constants'
import { isWxApp } from './pages/NEUIKit/utils'
import { V2NIMMessage, V2NIMMessagePushConfig } from 'nim-web-sdk-ng/dist/v2/NIM_UNIAPP_SDK/V2NIMMessageService'
import { unix } from 'dayjs'
import RootStore from "@xkit-yx/im-store-v2";
import V2NIM, { V2NIMConst } from "nim-web-sdk-ng/dist/v2/NIM_UNIAPP_SDK";
import { getMsgContentTipByType } from "./pages/NEUIKit/utils/msg";
import { STORAGE_KEY } from "./pages/NEUIKit/utils/constants";
import { isWxApp } from "./pages/NEUIKit/utils";
import { V2NIMMessage, V2NIMMessagePushConfig } from "nim-web-sdk-ng/dist/v2/NIM_UNIAPP_SDK/V2NIMMessageService";
import { unix } from "dayjs";
export default {
globalData: {
timer: null, //
themeColor: '#00b666',
themeBackgroundColor: '#00b66621',
},
onShow: function (options) {
let that = this
console.log('show 项目init', options, decodeURIComponent(options.query.scene))
// id
uni.removeStorageSync('scene')
uni.removeStorageSync('user_scene')
uni.removeStorageSync('user_options', options)
globalData: {
timer: null, //
themeColor: "#00b666",
themeBackgroundColor: "#00b66621",
},
onLaunch() {
let that = this;
uni.removeStorageSync("selectedCity");
},
onShow: function (options) {
let that = this;
console.log("show 项目init", options, decodeURIComponent(options.query.scene));
// id
uni.removeStorageSync("scene");
uni.removeStorageSync("user_scene");
uni.removeStorageSync("user_options", options);
if (options.query.id) {
uni.setStorageSync('apply-jobdetail-id', options.query.id)
} else {
uni.setStorageSync('apply-jobdetail-id', 0)
}
if (options.query.id) {
uni.setStorageSync("apply-jobdetail-id", options.query.id);
} else {
uni.setStorageSync("apply-jobdetail-id", 0);
}
if (options.query.scene) {
let str = decodeURIComponent(options.query.scene)
uni.setStorageSync(
'apply-invite-code',
JSON.stringify({
key: str.split('=')[0],
value: str.split('=')[1],
})
)
} else {
uni.setStorageSync('apply-invite-code', '')
}
if (uni.getStorageSync('apply-token')) {
this.G.checkToken()
}
if (!that.globalData.timer) {
if (uni.getStorageSync('apply-token')) {
that.checkNum()
}
that.globalData.timer = setInterval(() => {
console.log('inner++++++++++++++++++++ +++++++++++++++++++++++++++')
if (uni.getStorageSync('apply-token')) {
that.checkNum()
}
}, 1 * 30 * 1000)
}
if (options.query.scene) {
let str = decodeURIComponent(options.query.scene);
uni.setStorageSync(
"apply-invite-code",
JSON.stringify({
key: str.split("=")[0],
value: str.split("=")[1],
})
);
} else {
uni.setStorageSync("apply-invite-code", "");
}
if (uni.getStorageSync("apply-token")) {
this.G.checkToken();
}
if (!that.globalData.timer) {
if (uni.getStorageSync("apply-token")) {
that.checkNum();
}
that.globalData.timer = setInterval(() => {
console.log("inner++++++++++++++++++++ +++++++++++++++++++++++++++");
if (uni.getStorageSync("apply-token")) {
that.checkNum();
}
}, 1 * 30 * 1000);
}
uni.$on('isGlogin', function (data) {
console.log('app.vue 接收', data)
if (uni.getStorageSync('apply-uid')) {
// that.initWyyx()
}
})
if (uni.getStorageSync('apply-token')) {
console.log('app.vue 是否调用')
// that.initWyyx()
}
},
onHide: function () {},
methods: {
initWyyx() {
let that = this
uni.$on("isGlogin", function (data) {
console.log("app.vue 接收", data);
if (uni.getStorageSync("apply-uid")) {
// that.initWyyx()
}
});
if (uni.getStorageSync("apply-token")) {
console.log("app.vue 是否调用");
// that.initWyyx()
}
},
onHide: function () {},
methods: {
initWyyx() {
let that = this;
that.F.wyyxPost(
that.api.wyyx_getConfig,
{
userId: uni.getStorageSync('apply-uid'),
},
(res) => {
console.log('wyyx_getConfig', res)
let resData = {
appkey: res.appKey,
accid: res.accid,
token: res.token,
}
const imOptions = {
appkey: resData.appkey, // appkey
account: resData.accid, // account
token: resData.token, // token
// appkey: "7e19d679085266aa872a8de12f0c1ae5", // appkey
// account: "9", // account
// token: "2d4ca36cca6293cf3a81d6ca1b8026f7", // token
}
if (imOptions) {
this.initNim(imOptions)
} else {
// ,
}
}
)
},
async initNim(opts) {
let that = this
// nim sdk
const nim = (uni.$UIKitNIM = V2NIM.getInstance(
{
appkey: opts.appkey,
needReconnect: true,
// "reconnectionAttempts": 5,
debugLevel: 'debug',
apiVersion: 'v2',
enableV2CloudConversation: true,
},
{
V2NIMLoginServiceConfig: {
lbsUrls: isWxApp ? ['https://lbs.netease.im/lbs/wxwebconf.jsp'] : ['https://lbs.netease.im/lbs/webconf.jsp'],
linkUrl: isWxApp ? 'wlnimsc0.netease.im' : 'weblink.netease.im',
/**
* 使用固定设备 ID
*/
isFixedDeviceId: true,
},
}
))
that.F.wyyxPost(
that.api.wyyx_getConfig,
{
userId: uni.getStorageSync("apply-uid"),
},
(res) => {
console.log("wyyx_getConfig", res);
let resData = {
appkey: res.appKey,
accid: res.accid,
token: res.token,
};
const imOptions = {
appkey: resData.appkey, // appkey
account: resData.accid, // account
token: resData.token, // token
// appkey: "7e19d679085266aa872a8de12f0c1ae5", // appkey
// account: "9", // account
// token: "2d4ca36cca6293cf3a81d6ca1b8026f7", // token
};
if (imOptions) {
this.initNim(imOptions);
} else {
// ,
}
}
);
},
async initNim(opts) {
let that = this;
// nim sdk
const nim = (uni.$UIKitNIM = V2NIM.getInstance(
{
appkey: opts.appkey,
needReconnect: true,
// "reconnectionAttempts": 5,
debugLevel: "debug",
apiVersion: "v2",
enableV2CloudConversation: true,
},
{
V2NIMLoginServiceConfig: {
lbsUrls: isWxApp ? ["https://lbs.netease.im/lbs/wxwebconf.jsp"] : ["https://lbs.netease.im/lbs/webconf.jsp"],
linkUrl: isWxApp ? "wlnimsc0.netease.im" : "weblink.netease.im",
/**
* 使用固定设备 ID
*/
isFixedDeviceId: true,
},
}
));
that.globalData.nim = nim
that.globalData.nim = nim;
// store
const store = (uni.$UIKitStore = new RootStore(
nim,
{
addFriendNeedVerify: false,
// p2p p2p false
p2pMsgReceiptVisible: true,
// false
teamMsgReceiptVisible: true,
teamAgreeMode: V2NIMConst.V2NIMTeamAgreeMode.V2NIM_TEAM_AGREE_MODE_NO_AUTH,
sendMsgBefore: async (options: { msg: V2NIMMessage; conversationId: string; serverExtension?: Record<string, unknown> }) => {
const pushContent = getMsgContentTipByType({
text: options.msg.text,
messageType: options.msg.messageType,
})
const yxAitMsg = options.serverExtension ? options.serverExtension.yxAitMsg : { forcePushIDsList: '[]', needForcePush: false }
// store
const store = (uni.$UIKitStore = new RootStore(
nim,
{
addFriendNeedVerify: false,
// p2p p2p false
p2pMsgReceiptVisible: true,
// false
teamMsgReceiptVisible: true,
teamAgreeMode: V2NIMConst.V2NIMTeamAgreeMode.V2NIM_TEAM_AGREE_MODE_NO_AUTH,
sendMsgBefore: async (options: { msg: V2NIMMessage; conversationId: string; serverExtension?: Record<string, unknown> }) => {
const pushContent = getMsgContentTipByType({
text: options.msg.text,
messageType: options.msg.messageType,
});
const yxAitMsg = options.serverExtension ? options.serverExtension.yxAitMsg : { forcePushIDsList: "[]", needForcePush: false };
// at 线
// at 线
const { forcePushIDsList, needForcePush } = yxAitMsg
? // @ts-ignore
store.msgStore._formatExtAitToPushInfo(yxAitMsg, options.msg.text)
: { forcePushIDsList: '[]', needForcePush: false }
const { forcePushIDsList, needForcePush } = yxAitMsg
? // @ts-ignore
store.msgStore._formatExtAitToPushInfo(yxAitMsg, options.msg.text)
: { forcePushIDsList: "[]", needForcePush: false };
console.log('forcePushIDsList: ', forcePushIDsList)
console.log("forcePushIDsList: ", forcePushIDsList);
const { conversationId } = options
const conversationType = nim.V2NIMConversationIdUtil.parseConversationType(conversationId)
const targetId = nim.V2NIMConversationIdUtil.parseConversationTargetId(conversationId)
const { conversationId } = options;
const conversationType = nim.V2NIMConversationIdUtil.parseConversationType(conversationId);
const targetId = nim.V2NIMConversationIdUtil.parseConversationTargetId(conversationId);
const pushPayload = JSON.stringify({
// oppo
oppoField: {
click_action_type: 4, // oppo
click_action_activity: '', // TODO
action_parameters: {
sessionId: targetId,
sessionType: conversationType,
}, //
},
const pushPayload = JSON.stringify({
// oppo
oppoField: {
click_action_type: 4, // oppo
click_action_activity: "", // TODO
action_parameters: {
sessionId: targetId,
sessionType: conversationType,
}, //
},
// vivo
vivoField: {
pushMode: 0, //0 1 0
},
// vivo
vivoField: {
pushMode: 0, //0 1 0
},
// huawei
hwField: {
click_action: {
type: 1,
action: '', // TODO
},
androidConfig: {
category: 'IM',
data: JSON.stringify({
sessionId: targetId,
sessionType: conversationType,
}),
},
},
// huawei
hwField: {
click_action: {
type: 1,
action: "", // TODO
},
androidConfig: {
category: "IM",
data: JSON.stringify({
sessionId: targetId,
sessionType: conversationType,
}),
},
},
//
sessionId: targetId,
sessionType: conversationType,
})
//
sessionId: targetId,
sessionType: conversationType,
});
const pushConfig: V2NIMMessagePushConfig = {
pushEnabled: true,
pushNickEnabled: true,
forcePush: needForcePush,
forcePushContent: pushContent,
forcePushAccountIds: forcePushIDsList,
pushPayload: '{}',
pushContent,
}
const pushConfig: V2NIMMessagePushConfig = {
pushEnabled: true,
pushNickEnabled: true,
forcePush: needForcePush,
forcePushContent: pushContent,
forcePushAccountIds: forcePushIDsList,
pushPayload: "{}",
pushContent,
};
return { ...options, pushConfig }
},
},
'UniApp'
))
return { ...options, pushConfig };
},
},
"UniApp"
));
// #ifdef APP-PLUS
const nimPushPlugin = uni.requireNativePlugin('NIMUniPlugin-PluginModule')
nim.V2NIMSettingService.setOfflinePushConfig(nimPushPlugin, {
miPush: {
appId: '2882303761520397320',
appKey: '5102039734320',
certificateName: 'xiaomiCertificateName',
},
vivoPush: {
certificateName: 'vivoCertificateName',
},
oppoPush: {
appId: '32967155',
appKey: 'b98618cb272944dea324af6421d42a79',
secret: '0b7ce705a2304a17b78f20011c18890c',
certificateName: 'opopCertificateName',
},
honorPush: {
certificateName: 'rongyaoCertificateName',
},
apns: {
// certificateName: 'AuthKey_98P8URRXUD_test', //:
certificateName: 'AuthKey_98P8URRXUD', //
},
})
console.log('是否执行 推送')
// #endif
// #ifdef APP-PLUS
const nimPushPlugin = uni.requireNativePlugin("NIMUniPlugin-PluginModule");
nim.V2NIMSettingService.setOfflinePushConfig(nimPushPlugin, {
miPush: {
appId: "2882303761520397320",
appKey: "5102039734320",
certificateName: "xiaomiCertificateName",
},
vivoPush: {
certificateName: "vivoCertificateName",
},
oppoPush: {
appId: "32967155",
appKey: "b98618cb272944dea324af6421d42a79",
secret: "0b7ce705a2304a17b78f20011c18890c",
certificateName: "opopCertificateName",
},
honorPush: {
certificateName: "rongyaoCertificateName",
},
apns: {
// certificateName: 'AuthKey_98P8URRXUD_test', //:
certificateName: "AuthKey_98P8URRXUD", //
},
});
console.log("是否执行 推送");
// #endif
nim.V2NIMLoginService.login(opts.account, opts.token).then(() => {})
nim.V2NIMLoginService.login(opts.account, opts.token).then(() => {});
nim.V2NIMConversationService.on('onConversationChanged', function (conversationList: V2NIMConversation[]) {
console.log('初始化监听会话:', conversationList)
let _bool = conversationList.filter((item) => {
return Number(item.unreadCount) > 0
})
console.log('初始化监听会话bool:', _bool)
if (_bool && _bool.length > 0) {
that.playAudio() //
}
})
},
playAudio() {
let that = this
const innerAudioContext = uni.createInnerAudioContext()
innerAudioContext.autoplay = true
innerAudioContext.src = 'https://matripe-cms.oss-cn-beijing.aliyuncs.com/ibocai/tip.mp3'
innerAudioContext.onPlay(() => {
console.log('开始播放')
})
uni.vibrateShort()
nim.V2NIMConversationService.on("onConversationChanged", function (conversationList: V2NIMConversation[]) {
console.log("初始化监听会话:", conversationList);
let _bool = conversationList.filter((item) => {
return Number(item.unreadCount) > 0;
});
console.log("初始化监听会话bool:", _bool);
if (_bool && _bool.length > 0) {
that.playAudio(); //
}
});
},
playAudio() {
let that = this;
const innerAudioContext = uni.createInnerAudioContext();
innerAudioContext.autoplay = true;
innerAudioContext.src = "https://matripe-cms.oss-cn-beijing.aliyuncs.com/ibocai/tip.mp3";
innerAudioContext.onPlay(() => {
console.log("开始播放");
});
uni.vibrateShort();
innerAudioContext.onError((res) => {
console.log(res.errMsg)
console.log(res.errCode)
})
},
checkNum() {
let that = this
if (uni.getStorageSync('apply-token')) {
that.G.Get(that.api.bind_getApplyNum, {}, (res) => {
console.log('获取待处理数量:', res)
if (res.approvePassHasNotRed > 0) {
uni.setTabBarBadge({
index: 2,
text: String(res.approvePassHasNotRed),
})
} else {
uni.removeTabBarBadge({
index: 2,
})
}
})
}
},
},
}
innerAudioContext.onError((res) => {
console.log(res.errMsg);
console.log(res.errCode);
});
},
checkNum() {
let that = this;
if (uni.getStorageSync("apply-token")) {
that.G.Get(that.api.bind_getApplyNum, {}, (res) => {
console.log("获取待处理数量:", res);
if (res.approvePassHasNotRed > 0) {
uni.setTabBarBadge({
index: 2,
text: String(res.approvePassHasNotRed),
});
} else {
uni.removeTabBarBadge({
index: 2,
});
}
});
}
},
},
};
</script>
<style lang="scss">
@import './static/css/iconfont.css';
@import './uni_modules/vk-uview-ui/index.scss';
@import './static/css/base.scss';
@import './static/font/iconfont-weapp-icon.css';
@import "./static/css/iconfont.css";
@import "./uni_modules/vk-uview-ui/index.scss";
@import "./static/css/base.scss";
@import "./static/font/iconfont-weapp-icon.css";
// #ifdef MP-WEIXIN
page {
width: 100vw;
height: 100vh;
width: 100vw;
height: 100vh;
}
// #endif
// #ifdef H5 || APP-PLUS || MP-TOUTIAO || MP-KUAISHOU
page {
width: 100vw;
height: calc(100% - 0px);
--color-ysd: #ff4400;
--color-hover: #ff4400cc;
--color-be: #ff4400;
--color-027: #ff4400;
--color-href: #576b95;
width: 100vw;
height: calc(100% - 0px);
--color-ysd: #ff4400;
--color-hover: #ff4400cc;
--color-be: #ff4400;
--color-027: #ff4400;
--color-href: #576b95;
}
// #endif
// uview
.u-badge-mini {
top: 22rpx !important;
right: 102rpx !important;
color: transparent !important;
width: 10px !important;
height: 10px !important;
border-radius: 50% !important;
top: 22rpx !important;
right: 102rpx !important;
color: transparent !important;
width: 10px !important;
height: 10px !important;
border-radius: 50% !important;
}
.u-radio {
&:last-child {
.u-radio__label {
margin-right: 0;
}
}
&:last-child {
.u-radio__label {
margin-right: 0;
}
}
}
.g-apply-tab {
.u-tab-bar {
bottom: -2px !important;
}
.u-tab-bar {
bottom: -2px !important;
}
}
.g_bg_f_5 {
background-color: #ededed !important;
background-color: #ededed !important;
}
.g_mt_30 {
margin-top: 30px;
margin-top: 30px;
}
.g_mt_84 {
margin-top: 84px;
margin-top: 84px;
}
.g_pt_90 {
padding-top: 90px;
padding-top: 90px;
}
</style>

@ -17,6 +17,9 @@ let jobInfo = {
yi_job_class_new: "/labels/getListByTypeAndIndustry", // 新职位要求接口(新)
job_get_cus: "/yishoudan/job/customer/support/getJobCustomerSupportIM", // 获取客服ID
hasSee: "/yishoudan/job/view/record/addRecord",
getCityNameByLatLng: '/location/getCityNameByLatLng' ,// 根据经纬度获取城市
get_city_list: '/city/getAllCityLevel2', // 获取城市列表
}
export default jobInfo;

@ -457,6 +457,12 @@
"navigationBarTitleText": "搜索"
}
},
{
"path": "city",
"style": {
"navigationBarTitleText": "选择城市"
}
},
{
"path": "error",
"style": {

File diff suppressed because it is too large Load Diff

@ -0,0 +1,255 @@
<template>
<view class="g_pl_16 container" style="background-color: #f5f5f5">
<scroll-view class="cities-scroll" scroll-with-animation="true" style="box-sizing: border-box; height: calc(100vh - 87px)" :scroll-into-view="az" scroll-y ref="scrollViewRef">
<view class="">
<view class="headTxt">当前城市</view>
<view class="" hover-class="none" hover-stop-propagation="false">
<view @click="selectQuanGuo" class="itemCity" :class="{ active: selectedCity === '全国' }">全国</view>
<view class="g_flex_row_center itemCity" v-if="currentCity" @click="selectCity({ shortName: currentCity })" :class="{ active: selectedCity === currentCity }">
<i class="iconfont icon-dizhi1 g_mr_4"></i>
{{ currentCity }}
</view>
</view>
<view class="cities-list">
<block v-for="group in cities">
<view class="headTxt" :id="`letter-${group.name[0] == '热' ? 're' : group.name[0]}`">{{ group.name }}</view>
<block v-for="city in group.list">
<view @click="selectCity(city)" class="itemCity" :class="{ active: selectedCity === city.shortName }">{{ city.shortName }}</view>
</block>
</block>
</view>
</view>
<view class="" style="height: 120px"> </view>
</scroll-view>
<!-- 添加字母索引 -->
<view class="index-list" v-if="false">
<block v-for="(letter, index) in letters">
<!-- , activeIndex: currentIndex === index -->
<view :class="{ indexItem: true }" @click="scrollToLetter(letter)">
{{ letter }}
</view>
</block>
</view>
<g-panel-fixed>
<view class="g_flex_row_center">
<g-button btnText="重置" size="small" @clickBtn="back"></g-button>
<g-button btnText="确定" type="primary" class="g_ml_24" size="small" @clickBtn="setCity"></g-button>
</view>
</g-panel-fixed>
</view>
</template>
<script>
// import { cityList } from "../utils/city.js";
export default {
data() {
return {
cities: [],
cdnBaseImg: this.G.store().cdnBaseImg,
selectedCity: "全国",
currentIndex: 0,
letters: [],
az: "",
currentInfo: {}, //
currentCity: "",
};
},
onLoad() {
this.initializeCities();
this.getLocation().then((res) => {
console.log("res", res);
this.getCity();
});
// this.calculateLetters();
},
methods: {
setCity() {
uni.setStorageSync("selectedCity", this.selectedCity);
console.log(`城市 ${this.selectedCity} 已保存到缓存`);
uni.navigateBack({ delta: 1 });
},
getCity() {
let that = this;
this.G.Get(this.api.getCityNameByLatLng, { lng: this.currentInfo.longitude, lat: this.currentInfo.latitude }, (res) => {
if (res) {
that.currentCity = res.replace("市", "");
}
console.log("res");
});
},
getLocation() {
let that = this;
console.log("123123");
return new Promise((resolve, reject) => {
uni.authorize({
//
scope: "scope.userLocation",
success() {
console.log("用户成功授权位置信息");
uni.getLocation({
type: "wgs84",
success(res) {
that.currentInfo = {
latitude: res.latitude,
longitude: res.longitude,
timestamp: new Date().getTime(),
};
console.log("获取当前经纬度:", that.currentInfo);
resolve();
},
fail(err) {
console.log(err);
},
complete() {
resolve();
},
});
},
fail(err) {
console.log(err);
console.log("用户拒绝授权位置信息,再次提示用户授权");
uni.showToast({
title: "请开启定位权限以显示距职位距离",
icon: "none",
});
resolve();
// that.showRefuseLocationPermission();
},
});
});
},
back() {
this.selectedCity = "全国";
uni.setStorageSync("selectedCity", "全国");
// uni.navigateBack({ delta: 1 });
},
selectQuanGuo() {
this.selectedCity = "全国";
console.log("全国被选中");
},
selectCity(city) {
this.selectedCity = city.shortName;
console.log(`城市 ${city.shortName} 被选中`);
},
initializeCities() {
this.G.Get(this.api.get_city_list, {}, (res) => {
console.log(res);
this.letters.push("热");
res.forEach((item) => {
if (!this.letters.includes(item.name[0])) {
this.letters.push(item.name[0]);
}
});
this.cities = res;
const cachedSelectedCity = uni.getStorageSync("selectedCity");
if (cachedSelectedCity) {
this.selectedCity = cachedSelectedCity;
} else {
this.selectedCity = "全国";
}
});
// const hotCities = originalCities.find(group => group.name === '');
// if (hotCities) {
// hotCities.name = '';
// this.cities = originalCities.filter(group => group.name !== '');
// this.cities.unshift(hotCities);
// } else {
// this.cities = originalCities;
// }
},
// calculateLetters() {
// this.letters = [];
// this.cities.forEach((group) => {
// const firstLetter = group.name.charAt(0).toUpperCase();
// if (!this.letters.includes(firstLetter)) {
// this.letters.push(firstLetter);
// }
// });
// },
scrollToLetter(letter) {
var that = this;
if (letter == "热") {
letter = "re";
}
const id = `letter-${letter}`;
console.log(id);
this.az = id;
// console.log(that.$refs.scrollViewRef);
// this.$nextTick(() => {
// this.$refs.scrollViewRef.scrollIntoView(id, 300);
// });
},
},
};
</script>
<style lang="scss">
.container {
.itemCity {
width: calc(33.33% - 10px);
float: left;
margin-right: 10px;
background: #fff;
border-radius: 30px;
font-size: 16px;
font-weight: 400;
text-align: center;
padding: 8px 0;
color: #1d1d1d;
margin-bottom: 10px;
line-height: 20px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
&.active {
background: #00b666;
color: #ffffff;
}
}
.headTxt {
font-size: 18px;
font-weight: 400;
color: #999999;
line-height: 25px;
margin-top: 10px;
margin-left: 16px;
margin-bottom: 10px;
clear: both;
}
.cities-scroll {
// height: calc(100vh - 100px);
// overflow-y: auto;
}
.index-list {
position: fixed;
right: 10px;
top: 50%;
transform: translateY(-50%);
display: flex;
flex-direction: column;
align-items: center;
background-color: #f5f5f5;
.indexItem {
display: flex;
justify-content: center;
align-items: center;
border-radius: 50%;
margin: 2px;
&.activeIndex {
background: #00b666;
color: #ffffff;
}
}
}
}
</style>
Loading…
Cancel
Save