v0.0.4
This commit is contained in:
8
.gitignore
vendored
Normal file
8
.gitignore
vendored
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
node_modules/
|
||||||
|
.DS_Store
|
||||||
|
npm-debug.log*
|
||||||
|
yarn-debug.log*
|
||||||
|
yarn-error.log*
|
||||||
|
.env
|
||||||
|
.env.*
|
||||||
|
|
||||||
Binary file not shown.
52
README.md
Normal file
52
README.md
Normal file
@@ -0,0 +1,52 @@
|
|||||||
|
# 汪圈 Taro 微信小程序
|
||||||
|
|
||||||
|
本项目已从 `refrence_html/` 的静态 HTML 参考稿迁移为 Taro + React + TypeScript 微信小程序,并按微信云开发模式保留云函数目录。
|
||||||
|
|
||||||
|
## 运行
|
||||||
|
|
||||||
|
```bash
|
||||||
|
npm install
|
||||||
|
npm run dev:weapp
|
||||||
|
```
|
||||||
|
|
||||||
|
构建:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
npm run build:weapp
|
||||||
|
```
|
||||||
|
|
||||||
|
类型检查:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
npm run typecheck
|
||||||
|
```
|
||||||
|
|
||||||
|
## 微信开发者工具
|
||||||
|
|
||||||
|
1. 打开微信开发者工具。
|
||||||
|
2. 导入当前项目根目录。
|
||||||
|
3. `miniprogramRoot` 已配置为 `dist/`。
|
||||||
|
4. `cloudfunctionRoot` 已配置为 `cloudfunctions/`。
|
||||||
|
5. `project.config.json` 当前使用 `touristappid`,正式开发时替换为你的小程序 AppID。
|
||||||
|
|
||||||
|
## 云开发环境
|
||||||
|
|
||||||
|
客户端通过 `TARO_APP_CLOUD_ENV` 初始化云环境:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
$env:TARO_APP_CLOUD_ENV="你的云环境ID"
|
||||||
|
npm run dev:weapp
|
||||||
|
```
|
||||||
|
|
||||||
|
未配置云环境时,页面会自动使用本地 mock 数据,方便先验收视觉和交互。
|
||||||
|
|
||||||
|
## 页面
|
||||||
|
|
||||||
|
- `src/pages/plaza`:广场信息流
|
||||||
|
- `src/pages/nearby`:附近地图与可拖拽底部列表
|
||||||
|
- `src/pages/publish`:发布动态
|
||||||
|
- `src/pages/messages`:消息列表
|
||||||
|
- `src/pages/profile`:我的主页
|
||||||
|
|
||||||
|
设计与架构说明见 [docs/taro-miniapp-design.md](docs/taro-miniapp-design.md)。
|
||||||
|
|
||||||
12
babel.config.js
Normal file
12
babel.config.js
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
module.exports = {
|
||||||
|
presets: [
|
||||||
|
[
|
||||||
|
'taro',
|
||||||
|
{
|
||||||
|
framework: 'react',
|
||||||
|
ts: true
|
||||||
|
}
|
||||||
|
]
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
29
cloudbaserc.json
Normal file
29
cloudbaserc.json
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
{
|
||||||
|
"$schema": "https://static.cloudbase.net/cli/cloudbaserc.schema.json",
|
||||||
|
"envId": "cloud1-d4g697lte499543d8",
|
||||||
|
"functionRoot": "cloudfunctions",
|
||||||
|
"functions": [
|
||||||
|
{ "name": "login", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 },
|
||||||
|
{ "name": "feedList", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 },
|
||||||
|
{ "name": "postCreate", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 },
|
||||||
|
{ "name": "postLike", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 },
|
||||||
|
{ "name": "postFavorite", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 },
|
||||||
|
{ "name": "draftSave", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 },
|
||||||
|
{ "name": "draftGet", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 },
|
||||||
|
{ "name": "nearbyPets", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 },
|
||||||
|
{ "name": "locationUpdate", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 },
|
||||||
|
{ "name": "matchLike", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 },
|
||||||
|
{ "name": "messageList", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 },
|
||||||
|
{ "name": "messageSend", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 },
|
||||||
|
{ "name": "messageThread", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 },
|
||||||
|
{ "name": "conversationRead", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 },
|
||||||
|
{ "name": "followToggle", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 },
|
||||||
|
{ "name": "followList", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 },
|
||||||
|
{ "name": "userList", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 },
|
||||||
|
{ "name": "profileGet", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 },
|
||||||
|
{ "name": "profileUpdate", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 },
|
||||||
|
{ "name": "petList", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 },
|
||||||
|
{ "name": "petSave", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 },
|
||||||
|
{ "name": "petDelete", "runtime": "Nodejs16.13", "handler": "index.main", "timeout": 10, "memorySize": 128 }
|
||||||
|
]
|
||||||
|
}
|
||||||
19
cloudfunctions/conversationRead/index.js
Normal file
19
cloudfunctions/conversationRead/index.js
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
const _ = db.command
|
||||||
|
|
||||||
|
exports.main = async event => {
|
||||||
|
const { OPENID } = cloud.getWXContext()
|
||||||
|
if (!event.conversationId) throw new Error('conversationId is required')
|
||||||
|
|
||||||
|
await db.collection('conversations').doc(event.conversationId).update({
|
||||||
|
data: {
|
||||||
|
unreadOpenids: _.pull(OPENID),
|
||||||
|
[`unreadCounts.${OPENID}`]: 0
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
return { unreadCount: 0 }
|
||||||
|
}
|
||||||
9
cloudfunctions/conversationRead/package.json
Normal file
9
cloudfunctions/conversationRead/package.json
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
"name": "conversationRead",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
13
cloudfunctions/draftGet/index.js
Normal file
13
cloudfunctions/draftGet/index.js
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
|
||||||
|
exports.main = async () => {
|
||||||
|
const { OPENID } = cloud.getWXContext()
|
||||||
|
if (!OPENID) throw new Error('no openid in wx context')
|
||||||
|
const res = await db.collection('drafts').where({ openid: OPENID }).limit(1).get()
|
||||||
|
if (!res.data.length) return { draft: null }
|
||||||
|
const record = res.data[0]
|
||||||
|
return { draft: record.draft || null, updatedAt: record.updatedAt }
|
||||||
|
}
|
||||||
8
cloudfunctions/draftGet/package.json
Normal file
8
cloudfunctions/draftGet/package.json
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
{
|
||||||
|
"name": "draftGet",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
24
cloudfunctions/draftSave/index.js
Normal file
24
cloudfunctions/draftSave/index.js
Normal file
@@ -0,0 +1,24 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
|
||||||
|
exports.main = async event => {
|
||||||
|
const { OPENID } = cloud.getWXContext()
|
||||||
|
const now = Date.now()
|
||||||
|
const data = {
|
||||||
|
openid: OPENID,
|
||||||
|
draft: event.draft || {},
|
||||||
|
updatedAt: now
|
||||||
|
}
|
||||||
|
const existed = await db.collection('drafts').where({ openid: OPENID }).limit(1).get()
|
||||||
|
|
||||||
|
if (existed.data.length) {
|
||||||
|
await db.collection('drafts').doc(existed.data[0]._id).update({ data })
|
||||||
|
return { draftId: existed.data[0]._id, updatedAt: now }
|
||||||
|
}
|
||||||
|
|
||||||
|
const result = await db.collection('drafts').add({ data })
|
||||||
|
return { draftId: result._id, updatedAt: now }
|
||||||
|
}
|
||||||
|
|
||||||
9
cloudfunctions/draftSave/package.json
Normal file
9
cloudfunctions/draftSave/package.json
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
"name": "draftSave",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
105
cloudfunctions/feedList/index.js
Normal file
105
cloudfunctions/feedList/index.js
Normal file
@@ -0,0 +1,105 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
const _ = db.command
|
||||||
|
|
||||||
|
// Query a collection that may not exist yet (created lazily on first write).
|
||||||
|
// Returns an empty result instead of throwing "collection not exists".
|
||||||
|
async function safeGet(collection, where, limit = 200) {
|
||||||
|
try {
|
||||||
|
return await db.collection(collection).where(where).limit(limit).get()
|
||||||
|
} catch (e) {
|
||||||
|
return { data: [] }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function formatTimeText(ts) {
|
||||||
|
const diff = Date.now() - ts
|
||||||
|
const mins = Math.floor(diff / 60000)
|
||||||
|
if (mins < 1) return '刚刚'
|
||||||
|
if (mins < 60) return `${mins} 分钟前`
|
||||||
|
const hours = Math.floor(mins / 60)
|
||||||
|
if (hours < 24) return `${hours} 小时前`
|
||||||
|
const days = Math.floor(hours / 24)
|
||||||
|
if (days === 1) return '昨天'
|
||||||
|
if (days < 7) return `${days} 天前`
|
||||||
|
const d = new Date(ts)
|
||||||
|
return `${d.getMonth() + 1}月${d.getDate()}日`
|
||||||
|
}
|
||||||
|
|
||||||
|
exports.main = async event => {
|
||||||
|
const { OPENID } = cloud.getWXContext()
|
||||||
|
const pageSize = Math.min(event.pageSize || 20, 50)
|
||||||
|
const query = { visibility: 'public' }
|
||||||
|
|
||||||
|
if (event.topic) query.topics = event.topic
|
||||||
|
|
||||||
|
// Follow channel: only posts from users I follow (plus my own).
|
||||||
|
if (event.channel === 'follow') {
|
||||||
|
if (!OPENID) return { list: [], nextCursor: '' }
|
||||||
|
const meRes = await db.collection('users').where({ openid: OPENID }).limit(1).get()
|
||||||
|
if (!meRes.data.length) return { list: [], nextCursor: '' }
|
||||||
|
const meId = meRes.data[0]._id
|
||||||
|
const followRes = await safeGet('follows', { followerId: meId }, 500)
|
||||||
|
const authorOpenids = followRes.data.map(f => f.followeeOpenid).filter(Boolean)
|
||||||
|
authorOpenids.push(OPENID)
|
||||||
|
query.authorOpenid = _.in(authorOpenids)
|
||||||
|
query.visibility = _.in(['public', 'friends'])
|
||||||
|
}
|
||||||
|
|
||||||
|
if (event.cursor) {
|
||||||
|
query.createdAt = _.lt(Number(event.cursor))
|
||||||
|
}
|
||||||
|
|
||||||
|
const res = await db.collection('posts')
|
||||||
|
.where(query)
|
||||||
|
.orderBy('createdAt', 'desc')
|
||||||
|
.limit(pageSize)
|
||||||
|
.get()
|
||||||
|
|
||||||
|
if (!res.data.length) return { list: [], nextCursor: '' }
|
||||||
|
|
||||||
|
const postIds = res.data.map(p => p._id)
|
||||||
|
|
||||||
|
// Batch-check liked/favorited status — skip if no valid OPENID (non-WeChat context)
|
||||||
|
let likedSet = new Set()
|
||||||
|
let favSet = new Set()
|
||||||
|
if (OPENID) {
|
||||||
|
const [likedRes, favRes] = await Promise.all([
|
||||||
|
safeGet('postLikes', { openid: OPENID, postId: _.in(postIds) }),
|
||||||
|
safeGet('postFavorites', { openid: OPENID, postId: _.in(postIds) })
|
||||||
|
])
|
||||||
|
likedSet = new Set(likedRes.data.map(l => l.postId))
|
||||||
|
favSet = new Set(favRes.data.map(f => f.postId))
|
||||||
|
}
|
||||||
|
|
||||||
|
const list = res.data.map(post => ({
|
||||||
|
_id: post._id,
|
||||||
|
author: {
|
||||||
|
id: post.authorId || '',
|
||||||
|
name: post.authorSnapshot?.name || '用户',
|
||||||
|
avatarKey: post.authorSnapshot?.avatarKey || 'gradient-avatar-1'
|
||||||
|
},
|
||||||
|
pet: post.petSnapshot || { name: '', breed: '' },
|
||||||
|
body: post.content || '',
|
||||||
|
topics: post.topics || [],
|
||||||
|
media: Array.isArray(post.media)
|
||||||
|
? post.media.map(m => (typeof m === 'string' ? m : m && (m.url || m.fileId))).filter(Boolean)
|
||||||
|
: [],
|
||||||
|
mediaTone: post.mediaTone || 'pet-1',
|
||||||
|
sticker: post.sticker || undefined,
|
||||||
|
locationText: post.locationText || '',
|
||||||
|
timeText: formatTimeText(post.createdAt || Date.now()),
|
||||||
|
counts: {
|
||||||
|
likes: post.counts?.likes || 0,
|
||||||
|
comments: post.counts?.comments || 0,
|
||||||
|
favorites: post.counts?.favorites || 0
|
||||||
|
},
|
||||||
|
likedByMe: likedSet.has(post._id),
|
||||||
|
favoritedByMe: favSet.has(post._id)
|
||||||
|
}))
|
||||||
|
|
||||||
|
const last = res.data[res.data.length - 1]
|
||||||
|
return { list, nextCursor: last ? String(last.createdAt) : '' }
|
||||||
|
}
|
||||||
9
cloudfunctions/feedList/package.json
Normal file
9
cloudfunctions/feedList/package.json
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
"name": "feedList",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
63
cloudfunctions/followList/index.js
Normal file
63
cloudfunctions/followList/index.js
Normal file
@@ -0,0 +1,63 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
const _ = db.command
|
||||||
|
|
||||||
|
async function fetchUsers(ids) {
|
||||||
|
if (!ids.length) return []
|
||||||
|
const out = []
|
||||||
|
// _.in supports up to ~100 values; chunk to be safe
|
||||||
|
for (let i = 0; i < ids.length; i += 100) {
|
||||||
|
const chunk = ids.slice(i, i + 100)
|
||||||
|
const res = await db.collection('users').where({ _id: _.in(chunk) }).limit(100).get()
|
||||||
|
out.push(...res.data)
|
||||||
|
}
|
||||||
|
return out
|
||||||
|
}
|
||||||
|
|
||||||
|
exports.main = async event => {
|
||||||
|
const { OPENID } = cloud.getWXContext()
|
||||||
|
if (!OPENID) throw new Error('no openid in wx context')
|
||||||
|
const meRes = await db.collection('users').where({ openid: OPENID }).limit(1).get()
|
||||||
|
if (!meRes.data.length) throw new Error('user not found')
|
||||||
|
const meId = meRes.data[0]._id
|
||||||
|
const type = event.type || 'friends'
|
||||||
|
|
||||||
|
const safeFollows = where =>
|
||||||
|
db.collection('follows').where(where).limit(500).get().catch(() => ({ data: [] }))
|
||||||
|
const [followingRes, followerRes] = await Promise.all([
|
||||||
|
safeFollows({ followerId: meId }),
|
||||||
|
safeFollows({ followeeId: meId })
|
||||||
|
])
|
||||||
|
const followingIds = followingRes.data.map(f => f.followeeId)
|
||||||
|
const followerIds = followerRes.data.map(f => f.followerId)
|
||||||
|
const followingSet = new Set(followingIds)
|
||||||
|
const followerSet = new Set(followerIds)
|
||||||
|
const friendIds = followingIds.filter(id => followerSet.has(id))
|
||||||
|
|
||||||
|
let ids = friendIds
|
||||||
|
if (type === 'following') ids = followingIds
|
||||||
|
else if (type === 'followers') ids = followerIds
|
||||||
|
|
||||||
|
const users = await fetchUsers(ids)
|
||||||
|
const list = users.map(u => ({
|
||||||
|
id: u._id,
|
||||||
|
name: u.nickname || '用户',
|
||||||
|
handle: u.handle || '',
|
||||||
|
avatarKey: u.avatarKey || 'gradient-avatar-1',
|
||||||
|
avatarUrl: u.avatarUrl || '',
|
||||||
|
bio: u.bio || '',
|
||||||
|
isFollowing: followingSet.has(u._id),
|
||||||
|
isFriend: followingSet.has(u._id) && followerSet.has(u._id)
|
||||||
|
}))
|
||||||
|
|
||||||
|
return {
|
||||||
|
list,
|
||||||
|
counts: {
|
||||||
|
following: followingIds.length,
|
||||||
|
followers: followerIds.length,
|
||||||
|
friends: friendIds.length
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
8
cloudfunctions/followList/package.json
Normal file
8
cloudfunctions/followList/package.json
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
{
|
||||||
|
"name": "followList",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
47
cloudfunctions/followToggle/index.js
Normal file
47
cloudfunctions/followToggle/index.js
Normal file
@@ -0,0 +1,47 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
|
||||||
|
exports.main = async event => {
|
||||||
|
const { OPENID } = cloud.getWXContext()
|
||||||
|
if (!OPENID) throw new Error('no openid in wx context')
|
||||||
|
const { targetUserId, follow } = event
|
||||||
|
if (!targetUserId) throw new Error('targetUserId is required')
|
||||||
|
|
||||||
|
const meRes = await db.collection('users').where({ openid: OPENID }).limit(1).get()
|
||||||
|
if (!meRes.data.length) throw new Error('user not found')
|
||||||
|
const meId = meRes.data[0]._id
|
||||||
|
if (meId === targetUserId) throw new Error('cannot follow yourself')
|
||||||
|
|
||||||
|
const targetRes = await db.collection('users').doc(targetUserId).get().catch(() => null)
|
||||||
|
const target = targetRes && targetRes.data
|
||||||
|
if (!target) throw new Error('target user not found')
|
||||||
|
|
||||||
|
const existing = await db.collection('follows')
|
||||||
|
.where({ followerId: meId, followeeId: targetUserId })
|
||||||
|
.limit(1)
|
||||||
|
.get()
|
||||||
|
|
||||||
|
if (follow && !existing.data.length) {
|
||||||
|
await db.collection('follows').add({
|
||||||
|
data: {
|
||||||
|
followerId: meId,
|
||||||
|
followerOpenid: OPENID,
|
||||||
|
followeeId: targetUserId,
|
||||||
|
followeeOpenid: target.openid,
|
||||||
|
createdAt: Date.now()
|
||||||
|
}
|
||||||
|
})
|
||||||
|
} else if (!follow && existing.data.length) {
|
||||||
|
await db.collection('follows').doc(existing.data[0]._id).remove()
|
||||||
|
}
|
||||||
|
|
||||||
|
// A friendship (汪友) is a mutual follow.
|
||||||
|
const back = await db.collection('follows')
|
||||||
|
.where({ followerId: targetUserId, followeeId: meId })
|
||||||
|
.limit(1)
|
||||||
|
.get()
|
||||||
|
|
||||||
|
return { following: Boolean(follow), mutual: Boolean(follow) && back.data.length > 0 }
|
||||||
|
}
|
||||||
8
cloudfunctions/followToggle/package.json
Normal file
8
cloudfunctions/followToggle/package.json
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
{
|
||||||
|
"name": "followToggle",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
21
cloudfunctions/locationUpdate/index.js
Normal file
21
cloudfunctions/locationUpdate/index.js
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
|
||||||
|
exports.main = async event => {
|
||||||
|
const { OPENID } = cloud.getWXContext()
|
||||||
|
const now = Date.now()
|
||||||
|
const data = {
|
||||||
|
openid: OPENID,
|
||||||
|
location: event.location || null,
|
||||||
|
visible: Boolean(event.visible),
|
||||||
|
updatedAt: now
|
||||||
|
}
|
||||||
|
const existed = await db.collection('locations').where({ openid: OPENID }).limit(1).get()
|
||||||
|
if (existed.data.length) await db.collection('locations').doc(existed.data[0]._id).update({ data })
|
||||||
|
else await db.collection('locations').add({ data })
|
||||||
|
|
||||||
|
return { ok: true }
|
||||||
|
}
|
||||||
|
|
||||||
9
cloudfunctions/locationUpdate/package.json
Normal file
9
cloudfunctions/locationUpdate/package.json
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
"name": "locationUpdate",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
59
cloudfunctions/login/index.js
Normal file
59
cloudfunctions/login/index.js
Normal file
@@ -0,0 +1,59 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
|
||||||
|
// Generate a unique handle from openid
|
||||||
|
function makeHandle(openid) {
|
||||||
|
const suffix = openid.slice(-6).toLowerCase()
|
||||||
|
return `@user_${suffix}`
|
||||||
|
}
|
||||||
|
|
||||||
|
// Default avatar pool to randomise new user avatars
|
||||||
|
const AVATAR_KEYS = [
|
||||||
|
'gradient-avatar-1', 'gradient-avatar-2', 'gradient-avatar-3',
|
||||||
|
'gradient-avatar-4', 'gradient-avatar-5', 'gradient-avatar-6'
|
||||||
|
]
|
||||||
|
|
||||||
|
exports.main = async event => {
|
||||||
|
const { OPENID } = cloud.getWXContext()
|
||||||
|
if (!OPENID) throw new Error('no openid in wx context')
|
||||||
|
|
||||||
|
const now = Date.now()
|
||||||
|
const existed = await db.collection('users').where({ openid: OPENID }).limit(1).get()
|
||||||
|
|
||||||
|
if (existed.data.length) {
|
||||||
|
const user = existed.data[0]
|
||||||
|
await db.collection('users').doc(user._id).update({
|
||||||
|
data: { lastLoginAt: now }
|
||||||
|
})
|
||||||
|
return {
|
||||||
|
openid: OPENID,
|
||||||
|
user: { ...user, lastLoginAt: now },
|
||||||
|
isNew: false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// New user — create with sensible defaults
|
||||||
|
const avatarKey = AVATAR_KEYS[Math.floor(Math.random() * AVATAR_KEYS.length)]
|
||||||
|
const user = {
|
||||||
|
openid: OPENID,
|
||||||
|
nickname: event.userInfo?.nickname || '宠物达人',
|
||||||
|
handle: makeHandle(OPENID),
|
||||||
|
avatarKey,
|
||||||
|
avatarUrl: '',
|
||||||
|
profileCompleted: false,
|
||||||
|
location: '',
|
||||||
|
yearsWithPets: 0,
|
||||||
|
level: 1,
|
||||||
|
bio: '',
|
||||||
|
verified: false,
|
||||||
|
stats: { posts: 0, following: 0, followers: 0, favorites: 0 },
|
||||||
|
preferences: { notifications: true, nearbyVisible: true },
|
||||||
|
createdAt: now,
|
||||||
|
lastLoginAt: now
|
||||||
|
}
|
||||||
|
|
||||||
|
const result = await db.collection('users').add({ data: user })
|
||||||
|
return { openid: OPENID, user: { _id: result._id, ...user }, isNew: true }
|
||||||
|
}
|
||||||
9
cloudfunctions/login/package.json
Normal file
9
cloudfunctions/login/package.json
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
"name": "login",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
46
cloudfunctions/matchLike/index.js
Normal file
46
cloudfunctions/matchLike/index.js
Normal file
@@ -0,0 +1,46 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
const _ = db.command
|
||||||
|
|
||||||
|
exports.main = async event => {
|
||||||
|
const { OPENID } = cloud.getWXContext()
|
||||||
|
const { petId } = event
|
||||||
|
if (!petId) throw new Error('petId is required')
|
||||||
|
|
||||||
|
// Get current user and their pets
|
||||||
|
const userRes = await db.collection('users').where({ openid: OPENID }).limit(1).get()
|
||||||
|
if (!userRes.data.length) throw new Error('user not found')
|
||||||
|
const userId = userRes.data[0]._id
|
||||||
|
|
||||||
|
// Record this like (idempotent)
|
||||||
|
const existed = await db.collection('matches').where({ fromOpenid: OPENID, petId }).limit(1).get()
|
||||||
|
if (!existed.data.length) {
|
||||||
|
await db.collection('matches').add({ data: { fromOpenid: OPENID, userId, petId, createdAt: Date.now() } })
|
||||||
|
}
|
||||||
|
|
||||||
|
// Check mutual match: does the target pet's owner like any of current user's pets?
|
||||||
|
let matched = false
|
||||||
|
try {
|
||||||
|
const targetPetRes = await db.collection('pets').doc(petId).get()
|
||||||
|
const targetOwnerId = targetPetRes.data?.ownerId
|
||||||
|
if (targetOwnerId && targetOwnerId !== userId) {
|
||||||
|
const targetOwnerRes = await db.collection('users').doc(targetOwnerId).get()
|
||||||
|
const targetOpenid = targetOwnerRes.data?.openid
|
||||||
|
if (targetOpenid) {
|
||||||
|
const myPetsRes = await db.collection('pets').where({ ownerId: userId }).limit(20).get()
|
||||||
|
const myPetIds = myPetsRes.data.map(p => p._id)
|
||||||
|
if (myPetIds.length) {
|
||||||
|
const reverseRes = await db.collection('matches')
|
||||||
|
.where({ fromOpenid: targetOpenid, petId: _.in(myPetIds) })
|
||||||
|
.limit(1)
|
||||||
|
.get()
|
||||||
|
matched = reverseRes.data.length > 0
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} catch (_) {}
|
||||||
|
|
||||||
|
return { matched }
|
||||||
|
}
|
||||||
9
cloudfunctions/matchLike/package.json
Normal file
9
cloudfunctions/matchLike/package.json
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
"name": "matchLike",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
101
cloudfunctions/messageList/index.js
Normal file
101
cloudfunctions/messageList/index.js
Normal file
@@ -0,0 +1,101 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
const _ = db.command
|
||||||
|
|
||||||
|
function formatTimeText(ts) {
|
||||||
|
if (!ts) return ''
|
||||||
|
const diff = Date.now() - ts
|
||||||
|
const mins = Math.floor(diff / 60000)
|
||||||
|
if (mins < 1) return '现在'
|
||||||
|
if (mins < 60) return `${mins} 分钟前`
|
||||||
|
const hours = Math.floor(mins / 60)
|
||||||
|
if (hours < 24) return `${hours} 小时前`
|
||||||
|
const days = Math.floor(hours / 24)
|
||||||
|
if (days === 1) return '昨天'
|
||||||
|
const weekdays = ['周日', '周一', '周二', '周三', '周四', '周五', '周六']
|
||||||
|
if (days < 7) return weekdays[new Date(ts).getDay()]
|
||||||
|
const d = new Date(ts)
|
||||||
|
return `${d.getMonth() + 1}/${d.getDate()}`
|
||||||
|
}
|
||||||
|
|
||||||
|
// Query a collection that may not exist yet (created lazily on first write).
|
||||||
|
async function safeGet(collection, where, limit = 200) {
|
||||||
|
try {
|
||||||
|
return await db.collection(collection).where(where).limit(limit).get()
|
||||||
|
} catch (e) {
|
||||||
|
return { data: [] }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
async function fetchUsers(ids) {
|
||||||
|
if (!ids.length) return []
|
||||||
|
const out = []
|
||||||
|
for (let i = 0; i < ids.length; i += 100) {
|
||||||
|
const chunk = ids.slice(i, i + 100)
|
||||||
|
const res = await db.collection('users').where({ _id: _.in(chunk) }).limit(100).get()
|
||||||
|
out.push(...res.data)
|
||||||
|
}
|
||||||
|
return out
|
||||||
|
}
|
||||||
|
|
||||||
|
exports.main = async event => {
|
||||||
|
const { OPENID } = cloud.getWXContext()
|
||||||
|
if (!OPENID) throw new Error('no openid in wx context')
|
||||||
|
const tab = event.tab || 'all'
|
||||||
|
const query = { memberOpenids: OPENID }
|
||||||
|
if (tab === 'groups') query.type = 'group'
|
||||||
|
if (tab === 'unread') query.unreadOpenids = OPENID
|
||||||
|
|
||||||
|
const meRes = await db.collection('users').where({ openid: OPENID }).limit(1).get()
|
||||||
|
const meId = meRes.data[0] && meRes.data[0]._id
|
||||||
|
|
||||||
|
// Active row = my 汪友 (mutual follows)
|
||||||
|
let friendUsers = []
|
||||||
|
if (meId) {
|
||||||
|
const [followingRes, followerRes] = await Promise.all([
|
||||||
|
safeGet('follows', { followerId: meId }, 500),
|
||||||
|
safeGet('follows', { followeeId: meId }, 500)
|
||||||
|
])
|
||||||
|
const followerSet = new Set(followerRes.data.map(f => f.followerId))
|
||||||
|
const friendIds = followingRes.data.map(f => f.followeeId).filter(id => followerSet.has(id))
|
||||||
|
friendUsers = await fetchUsers(friendIds)
|
||||||
|
}
|
||||||
|
|
||||||
|
let convRes
|
||||||
|
try {
|
||||||
|
convRes = await db.collection('conversations').where(query).orderBy('updatedAt', 'desc').limit(50).get()
|
||||||
|
} catch (e) {
|
||||||
|
convRes = { data: [] }
|
||||||
|
}
|
||||||
|
|
||||||
|
const conversations = convRes.data.map(c => {
|
||||||
|
const unreadOpenids = c.unreadOpenids || []
|
||||||
|
const unreadCounts = c.unreadCounts || {}
|
||||||
|
const unreadCount = unreadCounts[OPENID] || (unreadOpenids.includes(OPENID) ? 1 : 0)
|
||||||
|
return {
|
||||||
|
_id: c._id,
|
||||||
|
type: c.type || 'single',
|
||||||
|
title: c.title || '未知用户',
|
||||||
|
petName: c.petName || undefined,
|
||||||
|
avatarKey: c.avatarKey || 'gradient-avatar-1',
|
||||||
|
preview: c.lastMessage?.content || c.preview || '',
|
||||||
|
timeText: formatTimeText(c.updatedAt || c.createdAt),
|
||||||
|
unreadCount,
|
||||||
|
pinned: Boolean(c.pinned),
|
||||||
|
muted: Boolean(c.muted),
|
||||||
|
online: Boolean(c.online)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
const activeUsers = friendUsers.map(u => ({
|
||||||
|
id: u._id,
|
||||||
|
name: u.nickname || '汪友',
|
||||||
|
avatarKey: u.avatarKey || 'gradient-avatar-1',
|
||||||
|
avatarUrl: u.avatarUrl || '',
|
||||||
|
live: Boolean(u.online)
|
||||||
|
}))
|
||||||
|
|
||||||
|
return { activeUsers, conversations }
|
||||||
|
}
|
||||||
9
cloudfunctions/messageList/package.json
Normal file
9
cloudfunctions/messageList/package.json
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
"name": "messageList",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
88
cloudfunctions/messageSend/index.js
Normal file
88
cloudfunctions/messageSend/index.js
Normal file
@@ -0,0 +1,88 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
const _ = db.command
|
||||||
|
|
||||||
|
exports.main = async event => {
|
||||||
|
const { OPENID } = cloud.getWXContext()
|
||||||
|
const content = String(event.content || '').trim()
|
||||||
|
if (!content) throw new Error('content is required')
|
||||||
|
|
||||||
|
const now = Date.now()
|
||||||
|
let convId = event.conversationId
|
||||||
|
|
||||||
|
// Create a 1:1 conversation if not provided
|
||||||
|
if (!convId) {
|
||||||
|
let { toOpenid } = event
|
||||||
|
// Allow opening by user id without exposing openids to the client.
|
||||||
|
if (!toOpenid && event.toUserId) {
|
||||||
|
const toUserById = await db.collection('users').doc(event.toUserId).get().catch(() => null)
|
||||||
|
if (toUserById && toUserById.data) toOpenid = toUserById.data.openid
|
||||||
|
}
|
||||||
|
if (!toOpenid) throw new Error('conversationId or toOpenid/toUserId is required')
|
||||||
|
|
||||||
|
// Look for existing conversation between these two users
|
||||||
|
const existing = await db.collection('conversations')
|
||||||
|
.where({ type: 'single', memberOpenids: _.all([OPENID, toOpenid]) })
|
||||||
|
.limit(1)
|
||||||
|
.get()
|
||||||
|
|
||||||
|
if (existing.data.length) {
|
||||||
|
convId = existing.data[0]._id
|
||||||
|
} else {
|
||||||
|
const toUserRes = await db.collection('users').where({ openid: toOpenid }).limit(1).get()
|
||||||
|
const toUser = toUserRes.data[0] || { nickname: '用户', avatarKey: 'gradient-avatar-1' }
|
||||||
|
const newConv = await db.collection('conversations').add({
|
||||||
|
data: {
|
||||||
|
type: 'single',
|
||||||
|
memberOpenids: [OPENID, toOpenid],
|
||||||
|
unreadOpenids: [toOpenid],
|
||||||
|
unreadCounts: { [toOpenid]: 1 },
|
||||||
|
title: toUser.nickname,
|
||||||
|
avatarKey: toUser.avatarKey,
|
||||||
|
lastMessage: { content: content.slice(0, 50), createdAt: now },
|
||||||
|
pinned: false,
|
||||||
|
muted: false,
|
||||||
|
createdAt: now,
|
||||||
|
updatedAt: now
|
||||||
|
}
|
||||||
|
})
|
||||||
|
convId = newConv._id
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Add message to messages collection
|
||||||
|
const msgResult = await db.collection('messages').add({
|
||||||
|
data: {
|
||||||
|
conversationId: convId,
|
||||||
|
fromOpenid: OPENID,
|
||||||
|
content: content.slice(0, 1000),
|
||||||
|
type: event.msgType || 'text',
|
||||||
|
createdAt: now
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
// Update conversation: last message + unread counts for all recipients
|
||||||
|
const convRes = await db.collection('conversations').doc(convId).get()
|
||||||
|
const members = convRes.data.memberOpenids || []
|
||||||
|
const recipients = members.filter(id => id !== OPENID)
|
||||||
|
|
||||||
|
const updateData = {
|
||||||
|
lastMessage: { content: content.slice(0, 50), createdAt: now },
|
||||||
|
updatedAt: now
|
||||||
|
}
|
||||||
|
// Add recipients to unreadOpenids and increment their unread counts
|
||||||
|
recipients.forEach(r => {
|
||||||
|
updateData[`unreadCounts.${r}`] = _.inc(1)
|
||||||
|
})
|
||||||
|
|
||||||
|
// Rebuild unreadOpenids to include all recipients (remove duplicates)
|
||||||
|
const existingUnread = convRes.data.unreadOpenids || []
|
||||||
|
const newUnread = [...new Set([...existingUnread, ...recipients])]
|
||||||
|
updateData.unreadOpenids = newUnread
|
||||||
|
|
||||||
|
await db.collection('conversations').doc(convId).update({ data: updateData })
|
||||||
|
|
||||||
|
return { messageId: msgResult._id, conversationId: convId }
|
||||||
|
}
|
||||||
8
cloudfunctions/messageSend/package.json
Normal file
8
cloudfunctions/messageSend/package.json
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
{
|
||||||
|
"name": "messageSend",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
82
cloudfunctions/messageThread/index.js
Normal file
82
cloudfunctions/messageThread/index.js
Normal file
@@ -0,0 +1,82 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
const _ = db.command
|
||||||
|
|
||||||
|
function timeText(ts) {
|
||||||
|
if (!ts) return ''
|
||||||
|
const d = new Date(ts)
|
||||||
|
const hh = String(d.getHours()).padStart(2, '0')
|
||||||
|
const mm = String(d.getMinutes()).padStart(2, '0')
|
||||||
|
const sameDay = new Date().toDateString() === d.toDateString()
|
||||||
|
if (sameDay) return `${hh}:${mm}`
|
||||||
|
return `${d.getMonth() + 1}/${d.getDate()} ${hh}:${mm}`
|
||||||
|
}
|
||||||
|
|
||||||
|
async function userToPeer(u) {
|
||||||
|
return { id: u._id, name: u.nickname || '用户', avatarKey: u.avatarKey || 'gradient-avatar-1', avatarUrl: u.avatarUrl || '' }
|
||||||
|
}
|
||||||
|
|
||||||
|
exports.main = async event => {
|
||||||
|
const { OPENID } = cloud.getWXContext()
|
||||||
|
if (!OPENID) throw new Error('no openid in wx context')
|
||||||
|
|
||||||
|
let convId = event.conversationId || ''
|
||||||
|
let peer = null
|
||||||
|
|
||||||
|
// Open by target user — resolve peer and find an existing conversation.
|
||||||
|
if (!convId && event.targetUserId) {
|
||||||
|
const tRes = await db.collection('users').doc(event.targetUserId).get().catch(() => null)
|
||||||
|
const t = tRes && tRes.data
|
||||||
|
if (t) {
|
||||||
|
peer = await userToPeer(t)
|
||||||
|
const ex = await db.collection('conversations')
|
||||||
|
.where({ type: 'single', memberOpenids: _.all([OPENID, t.openid]) })
|
||||||
|
.limit(1)
|
||||||
|
.get()
|
||||||
|
.catch(() => ({ data: [] }))
|
||||||
|
if (ex.data.length) convId = ex.data[0]._id
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Open by conversation — resolve the other member as peer.
|
||||||
|
if (convId && !peer) {
|
||||||
|
const c = await db.collection('conversations').doc(convId).get().catch(() => null)
|
||||||
|
if (c && c.data) {
|
||||||
|
const otherOpenid = (c.data.memberOpenids || []).find(o => o !== OPENID)
|
||||||
|
if (otherOpenid) {
|
||||||
|
const oRes = await db.collection('users').where({ openid: otherOpenid }).limit(1).get()
|
||||||
|
if (oRes.data[0]) peer = await userToPeer(oRes.data[0])
|
||||||
|
}
|
||||||
|
if (!peer) {
|
||||||
|
peer = { id: '', name: c.data.title || '对话', avatarKey: c.data.avatarKey || 'gradient-avatar-1', avatarUrl: '' }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
let messages = []
|
||||||
|
if (convId) {
|
||||||
|
const res = await db.collection('messages')
|
||||||
|
.where({ conversationId: convId })
|
||||||
|
.orderBy('createdAt', 'desc')
|
||||||
|
.limit(50)
|
||||||
|
.get()
|
||||||
|
.catch(() => ({ data: [] }))
|
||||||
|
messages = res.data.reverse().map(m => ({
|
||||||
|
_id: m._id,
|
||||||
|
fromMe: m.fromOpenid === OPENID,
|
||||||
|
content: m.content,
|
||||||
|
type: m.type || 'text',
|
||||||
|
createdAt: m.createdAt,
|
||||||
|
timeText: timeText(m.createdAt)
|
||||||
|
}))
|
||||||
|
|
||||||
|
// Mark this conversation read for me.
|
||||||
|
await db.collection('conversations').doc(convId).update({
|
||||||
|
data: { unreadOpenids: _.pull(OPENID), [`unreadCounts.${OPENID}`]: 0 }
|
||||||
|
}).catch(() => {})
|
||||||
|
}
|
||||||
|
|
||||||
|
return { conversationId: convId, peer, messages }
|
||||||
|
}
|
||||||
8
cloudfunctions/messageThread/package.json
Normal file
8
cloudfunctions/messageThread/package.json
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
{
|
||||||
|
"name": "messageThread",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
70
cloudfunctions/nearbyPets/index.js
Normal file
70
cloudfunctions/nearbyPets/index.js
Normal file
@@ -0,0 +1,70 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
|
||||||
|
function hashId(id) {
|
||||||
|
let h = 5381
|
||||||
|
for (let i = 0; i < id.length; i++) {
|
||||||
|
h = ((h << 5) + h) ^ id.charCodeAt(i)
|
||||||
|
h = h >>> 0 // keep as unsigned 32-bit
|
||||||
|
}
|
||||||
|
return h
|
||||||
|
}
|
||||||
|
|
||||||
|
// Generate a stable map pin position from pet id (fallback abstract layer)
|
||||||
|
function stablePin(id) {
|
||||||
|
const h = hashId(id)
|
||||||
|
const left = 10 + (h % 70)
|
||||||
|
const top = 15 + ((h >> 8) % 55)
|
||||||
|
return { left, top }
|
||||||
|
}
|
||||||
|
|
||||||
|
// Scatter a pet deterministically within roughly ±0.9km of the user, so on a
|
||||||
|
// real map markers cluster nearby (stable per pet id across requests).
|
||||||
|
function syntheticCoord(id, userLoc) {
|
||||||
|
const h = hashId(id)
|
||||||
|
const dLat = ((h % 1600) - 800) / 100000 // ±0.008° ≈ ±0.9km
|
||||||
|
const dLng = (((h >> 8) % 1600) - 800) / 100000
|
||||||
|
return { latitude: userLoc.latitude + dLat, longitude: userLoc.longitude + dLng }
|
||||||
|
}
|
||||||
|
|
||||||
|
// Rough distance text from coordinate delta (fallback when no real distance)
|
||||||
|
function distanceText(petLoc, userLoc) {
|
||||||
|
if (!petLoc || !userLoc) return null
|
||||||
|
const R = 6371000
|
||||||
|
const dLat = ((petLoc.latitude - userLoc.latitude) * Math.PI) / 180
|
||||||
|
const dLon = ((petLoc.longitude - userLoc.longitude) * Math.PI) / 180
|
||||||
|
const a =
|
||||||
|
Math.sin(dLat / 2) ** 2 +
|
||||||
|
Math.cos((userLoc.latitude * Math.PI) / 180) *
|
||||||
|
Math.cos((petLoc.latitude * Math.PI) / 180) *
|
||||||
|
Math.sin(dLon / 2) ** 2
|
||||||
|
const meters = Math.round(R * 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a)))
|
||||||
|
if (meters < 1000) return `${meters}m`
|
||||||
|
return `${(meters / 1000).toFixed(1)}km`
|
||||||
|
}
|
||||||
|
|
||||||
|
exports.main = async event => {
|
||||||
|
const filter = event.filters?.type || 'all'
|
||||||
|
const userLoc = event.location || null
|
||||||
|
const query = {}
|
||||||
|
if (filter === 'dog' || filter === 'cat') query.species = filter
|
||||||
|
if (filter === 'online') query.online = true
|
||||||
|
|
||||||
|
const res = await db.collection('pets').where(query).limit(50).get()
|
||||||
|
|
||||||
|
const list = res.data.map(pet => {
|
||||||
|
const realCoord = pet.location && typeof pet.location.latitude === 'number' ? pet.location : null
|
||||||
|
const coord = realCoord || (userLoc ? syntheticCoord(pet._id, userLoc) : null)
|
||||||
|
return {
|
||||||
|
...pet,
|
||||||
|
latitude: coord ? coord.latitude : undefined,
|
||||||
|
longitude: coord ? coord.longitude : undefined,
|
||||||
|
distanceText: distanceText(coord, userLoc) || pet.distanceText || null,
|
||||||
|
pin: stablePin(pet._id)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
return { list }
|
||||||
|
}
|
||||||
9
cloudfunctions/nearbyPets/package.json
Normal file
9
cloudfunctions/nearbyPets/package.json
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
"name": "nearbyPets",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
26
cloudfunctions/petDelete/index.js
Normal file
26
cloudfunctions/petDelete/index.js
Normal file
@@ -0,0 +1,26 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
|
||||||
|
exports.main = async event => {
|
||||||
|
const { OPENID } = cloud.getWXContext()
|
||||||
|
if (!OPENID) throw new Error('no openid in wx context')
|
||||||
|
if (!event.petId) throw new Error('petId is required')
|
||||||
|
|
||||||
|
const users = await db.collection('users').where({ openid: OPENID }).limit(1).get()
|
||||||
|
if (!users.data.length) throw new Error('user not found')
|
||||||
|
const ownerId = users.data[0]._id
|
||||||
|
|
||||||
|
let pet
|
||||||
|
try {
|
||||||
|
pet = await db.collection('pets').doc(event.petId).get()
|
||||||
|
} catch (_) {
|
||||||
|
return { ok: true } // already gone
|
||||||
|
}
|
||||||
|
if (!pet.data) return { ok: true }
|
||||||
|
if (pet.data.ownerId !== ownerId) throw new Error('not allowed')
|
||||||
|
|
||||||
|
await db.collection('pets').doc(event.petId).remove()
|
||||||
|
return { ok: true }
|
||||||
|
}
|
||||||
8
cloudfunctions/petDelete/package.json
Normal file
8
cloudfunctions/petDelete/package.json
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
{
|
||||||
|
"name": "petDelete",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
17
cloudfunctions/petList/index.js
Normal file
17
cloudfunctions/petList/index.js
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
|
||||||
|
exports.main = async event => {
|
||||||
|
const { OPENID } = cloud.getWXContext()
|
||||||
|
let ownerId = event.ownerId
|
||||||
|
if (!ownerId) {
|
||||||
|
const user = await db.collection('users').where({ openid: OPENID }).limit(1).get()
|
||||||
|
ownerId = user.data[0]?._id
|
||||||
|
}
|
||||||
|
|
||||||
|
const res = ownerId ? await db.collection('pets').where({ ownerId }).limit(20).get() : { data: [] }
|
||||||
|
return { list: res.data }
|
||||||
|
}
|
||||||
|
|
||||||
9
cloudfunctions/petList/package.json
Normal file
9
cloudfunctions/petList/package.json
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
"name": "petList",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
27
cloudfunctions/petSave/index.js
Normal file
27
cloudfunctions/petSave/index.js
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
|
||||||
|
exports.main = async event => {
|
||||||
|
const { OPENID } = cloud.getWXContext()
|
||||||
|
const users = await db.collection('users').where({ openid: OPENID }).limit(1).get()
|
||||||
|
if (!users.data.length) throw new Error('user not found')
|
||||||
|
|
||||||
|
const pet = {
|
||||||
|
...(event.pet || {}),
|
||||||
|
ownerId: users.data[0]._id,
|
||||||
|
updatedAt: Date.now()
|
||||||
|
}
|
||||||
|
delete pet._id
|
||||||
|
|
||||||
|
if (event.pet?._id) {
|
||||||
|
await db.collection('pets').doc(event.pet._id).update({ data: pet })
|
||||||
|
return { petId: event.pet._id }
|
||||||
|
}
|
||||||
|
|
||||||
|
pet.createdAt = Date.now()
|
||||||
|
const result = await db.collection('pets').add({ data: pet })
|
||||||
|
return { petId: result._id }
|
||||||
|
}
|
||||||
|
|
||||||
9
cloudfunctions/petSave/package.json
Normal file
9
cloudfunctions/petSave/package.json
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
"name": "petSave",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
65
cloudfunctions/postCreate/index.js
Normal file
65
cloudfunctions/postCreate/index.js
Normal file
@@ -0,0 +1,65 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
const _ = db.command
|
||||||
|
|
||||||
|
const MEDIA_TONES = ['pet-1', 'pet-2', 'pet-3']
|
||||||
|
const PET_TONES = { dog: 'gold', cat: 'purple', other: 'green' }
|
||||||
|
|
||||||
|
exports.main = async event => {
|
||||||
|
const { OPENID } = cloud.getWXContext()
|
||||||
|
const now = Date.now()
|
||||||
|
const content = String(event.content || '').trim()
|
||||||
|
if (!content) throw new Error('content is required')
|
||||||
|
|
||||||
|
// Get author info first (required for snapshot)
|
||||||
|
const userRes = await db.collection('users').where({ openid: OPENID }).limit(1).get()
|
||||||
|
if (!userRes.data.length) throw new Error('user not found')
|
||||||
|
const user = userRes.data[0]
|
||||||
|
|
||||||
|
// Get pet snapshot if petId provided
|
||||||
|
let petSnapshot = null
|
||||||
|
if (event.petId) {
|
||||||
|
try {
|
||||||
|
const petRes = await db.collection('pets').doc(event.petId).get()
|
||||||
|
if (petRes.data) {
|
||||||
|
const p = petRes.data
|
||||||
|
petSnapshot = { name: p.name, breed: p.breed, tone: PET_TONES[p.species] || 'green' }
|
||||||
|
}
|
||||||
|
} catch (_) {}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Derive mediaTone from media count so similar posts look varied
|
||||||
|
const mediaCount = Array.isArray(event.media) ? event.media.length : 0
|
||||||
|
const mediaTone = event.mediaTone || MEDIA_TONES[(mediaCount + now) % 3]
|
||||||
|
|
||||||
|
const post = {
|
||||||
|
authorOpenid: OPENID,
|
||||||
|
authorId: user._id,
|
||||||
|
authorSnapshot: { name: user.nickname, avatarKey: user.avatarKey },
|
||||||
|
petId: event.petId || '',
|
||||||
|
petSnapshot,
|
||||||
|
content: content.slice(0, 2000),
|
||||||
|
topics: Array.isArray(event.topics) ? event.topics : [],
|
||||||
|
media: Array.isArray(event.media) ? event.media : [],
|
||||||
|
mediaTone,
|
||||||
|
sticker: event.sticker || null,
|
||||||
|
locationText: event.locationText || '',
|
||||||
|
location: (typeof event.latitude === 'number' && typeof event.longitude === 'number')
|
||||||
|
? { latitude: event.latitude, longitude: event.longitude }
|
||||||
|
: null,
|
||||||
|
visibility: event.visibility || 'public',
|
||||||
|
counts: { likes: 0, comments: 0, shares: 0, favorites: 0 },
|
||||||
|
createdAt: now,
|
||||||
|
updatedAt: now
|
||||||
|
}
|
||||||
|
|
||||||
|
const result = await db.collection('posts').add({ data: post })
|
||||||
|
|
||||||
|
await db.collection('users').doc(user._id).update({
|
||||||
|
data: { 'stats.posts': _.inc(1) }
|
||||||
|
})
|
||||||
|
|
||||||
|
return { postId: result._id }
|
||||||
|
}
|
||||||
9
cloudfunctions/postCreate/package.json
Normal file
9
cloudfunctions/postCreate/package.json
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
"name": "postCreate",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
32
cloudfunctions/postFavorite/index.js
Normal file
32
cloudfunctions/postFavorite/index.js
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
const _ = db.command
|
||||||
|
|
||||||
|
exports.main = async event => {
|
||||||
|
const { OPENID } = cloud.getWXContext()
|
||||||
|
const { postId, favorited } = event
|
||||||
|
if (!postId) throw new Error('postId is required')
|
||||||
|
|
||||||
|
const existed = await db.collection('postFavorites').where({ postId, openid: OPENID }).limit(1).get()
|
||||||
|
let delta = 0
|
||||||
|
|
||||||
|
if (favorited && !existed.data.length) {
|
||||||
|
await db.collection('postFavorites').add({ data: { postId, openid: OPENID, createdAt: Date.now() } })
|
||||||
|
delta = 1
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!favorited && existed.data.length) {
|
||||||
|
await db.collection('postFavorites').doc(existed.data[0]._id).remove()
|
||||||
|
delta = -1
|
||||||
|
}
|
||||||
|
|
||||||
|
if (delta) {
|
||||||
|
await db.collection('posts').doc(postId).update({ data: { 'counts.favorites': _.inc(delta) } })
|
||||||
|
}
|
||||||
|
|
||||||
|
const post = await db.collection('posts').doc(postId).get()
|
||||||
|
return { favorited: Boolean(favorited), favorites: post.data.counts?.favorites || 0 }
|
||||||
|
}
|
||||||
|
|
||||||
9
cloudfunctions/postFavorite/package.json
Normal file
9
cloudfunctions/postFavorite/package.json
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
"name": "postFavorite",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
32
cloudfunctions/postLike/index.js
Normal file
32
cloudfunctions/postLike/index.js
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
const _ = db.command
|
||||||
|
|
||||||
|
exports.main = async event => {
|
||||||
|
const { OPENID } = cloud.getWXContext()
|
||||||
|
const { postId, liked } = event
|
||||||
|
if (!postId) throw new Error('postId is required')
|
||||||
|
|
||||||
|
const existed = await db.collection('postLikes').where({ postId, openid: OPENID }).limit(1).get()
|
||||||
|
let delta = 0
|
||||||
|
|
||||||
|
if (liked && !existed.data.length) {
|
||||||
|
await db.collection('postLikes').add({ data: { postId, openid: OPENID, createdAt: Date.now() } })
|
||||||
|
delta = 1
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!liked && existed.data.length) {
|
||||||
|
await db.collection('postLikes').doc(existed.data[0]._id).remove()
|
||||||
|
delta = -1
|
||||||
|
}
|
||||||
|
|
||||||
|
if (delta) {
|
||||||
|
await db.collection('posts').doc(postId).update({ data: { 'counts.likes': _.inc(delta) } })
|
||||||
|
}
|
||||||
|
|
||||||
|
const post = await db.collection('posts').doc(postId).get()
|
||||||
|
return { liked: Boolean(liked), likes: post.data.counts?.likes || 0 }
|
||||||
|
}
|
||||||
|
|
||||||
9
cloudfunctions/postLike/package.json
Normal file
9
cloudfunctions/postLike/package.json
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
"name": "postLike",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
40
cloudfunctions/profileGet/index.js
Normal file
40
cloudfunctions/profileGet/index.js
Normal file
@@ -0,0 +1,40 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
|
||||||
|
// Count a collection safely — returns 0 if the collection does not exist yet.
|
||||||
|
async function safeCount(collection, where) {
|
||||||
|
try {
|
||||||
|
const res = await db.collection(collection).where(where).count()
|
||||||
|
return res.total || 0
|
||||||
|
} catch (e) {
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Derive live stats from the source collections so the displayed numbers are
|
||||||
|
// always accurate instead of relying on a stored field that can drift.
|
||||||
|
async function computeStats(user) {
|
||||||
|
const [posts, favorites, following, followers] = await Promise.all([
|
||||||
|
safeCount('posts', { authorId: user._id }),
|
||||||
|
safeCount('postFavorites', { openid: user.openid }),
|
||||||
|
safeCount('follows', { followerId: user._id }),
|
||||||
|
safeCount('follows', { followeeId: user._id })
|
||||||
|
])
|
||||||
|
return { posts, following, followers, favorites }
|
||||||
|
}
|
||||||
|
|
||||||
|
exports.main = async event => {
|
||||||
|
const { OPENID } = cloud.getWXContext()
|
||||||
|
if (!event.userId && !OPENID) throw new Error('no openid in wx context')
|
||||||
|
const query = event.userId ? { _id: event.userId } : { openid: OPENID }
|
||||||
|
const users = await db.collection('users').where(query).limit(1).get()
|
||||||
|
const user = users.data[0] || null
|
||||||
|
if (!user) return { user: null, pets: [] }
|
||||||
|
|
||||||
|
const pets = await db.collection('pets').where({ ownerId: user._id }).limit(20).get()
|
||||||
|
user.stats = await computeStats(user)
|
||||||
|
|
||||||
|
return { user, pets: pets.data }
|
||||||
|
}
|
||||||
9
cloudfunctions/profileGet/package.json
Normal file
9
cloudfunctions/profileGet/package.json
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
"name": "profileGet",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
28
cloudfunctions/profileUpdate/index.js
Normal file
28
cloudfunctions/profileUpdate/index.js
Normal file
@@ -0,0 +1,28 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
|
||||||
|
exports.main = async event => {
|
||||||
|
const { OPENID } = cloud.getWXContext()
|
||||||
|
if (!OPENID) throw new Error('no openid in wx context')
|
||||||
|
const patch = event.patch || {}
|
||||||
|
delete patch.openid
|
||||||
|
delete patch._id
|
||||||
|
|
||||||
|
const users = await db.collection('users').where({ openid: OPENID }).limit(1).get()
|
||||||
|
if (!users.data.length) throw new Error('user not found')
|
||||||
|
|
||||||
|
// Setting a real avatar means the user has completed WeChat profile authorization
|
||||||
|
if (patch.avatarUrl) patch.profileCompleted = true
|
||||||
|
|
||||||
|
await db.collection('users').doc(users.data[0]._id).update({
|
||||||
|
data: {
|
||||||
|
...patch,
|
||||||
|
updatedAt: Date.now()
|
||||||
|
}
|
||||||
|
})
|
||||||
|
const user = await db.collection('users').doc(users.data[0]._id).get()
|
||||||
|
return { user: user.data }
|
||||||
|
}
|
||||||
|
|
||||||
9
cloudfunctions/profileUpdate/package.json
Normal file
9
cloudfunctions/profileUpdate/package.json
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
"name": "profileUpdate",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
46
cloudfunctions/userList/index.js
Normal file
46
cloudfunctions/userList/index.js
Normal file
@@ -0,0 +1,46 @@
|
|||||||
|
const cloud = require('wx-server-sdk')
|
||||||
|
|
||||||
|
cloud.init({ env: cloud.DYNAMIC_CURRENT_ENV })
|
||||||
|
const db = cloud.database()
|
||||||
|
const _ = db.command
|
||||||
|
|
||||||
|
// Discover other users to follow. Optional keyword filters by nickname.
|
||||||
|
exports.main = async event => {
|
||||||
|
const { OPENID } = cloud.getWXContext()
|
||||||
|
if (!OPENID) throw new Error('no openid in wx context')
|
||||||
|
const meRes = await db.collection('users').where({ openid: OPENID }).limit(1).get()
|
||||||
|
if (!meRes.data.length) throw new Error('user not found')
|
||||||
|
const meId = meRes.data[0]._id
|
||||||
|
const keyword = String(event.keyword || '').trim()
|
||||||
|
|
||||||
|
const where = { _id: _.neq(meId) }
|
||||||
|
if (keyword) where.nickname = db.RegExp({ regexp: keyword, options: 'i' })
|
||||||
|
|
||||||
|
const usersRes = await db.collection('users')
|
||||||
|
.where(where)
|
||||||
|
.orderBy('lastLoginAt', 'desc')
|
||||||
|
.limit(30)
|
||||||
|
.get()
|
||||||
|
|
||||||
|
const safeFollows = where2 =>
|
||||||
|
db.collection('follows').where(where2).limit(500).get().catch(() => ({ data: [] }))
|
||||||
|
const [followingRes, followerRes] = await Promise.all([
|
||||||
|
safeFollows({ followerId: meId }),
|
||||||
|
safeFollows({ followeeId: meId })
|
||||||
|
])
|
||||||
|
const followingSet = new Set(followingRes.data.map(f => f.followeeId))
|
||||||
|
const followerSet = new Set(followerRes.data.map(f => f.followerId))
|
||||||
|
|
||||||
|
const list = usersRes.data.map(u => ({
|
||||||
|
id: u._id,
|
||||||
|
name: u.nickname || '用户',
|
||||||
|
handle: u.handle || '',
|
||||||
|
avatarKey: u.avatarKey || 'gradient-avatar-1',
|
||||||
|
avatarUrl: u.avatarUrl || '',
|
||||||
|
bio: u.bio || '',
|
||||||
|
isFollowing: followingSet.has(u._id),
|
||||||
|
isFriend: followingSet.has(u._id) && followerSet.has(u._id)
|
||||||
|
}))
|
||||||
|
|
||||||
|
return { list }
|
||||||
|
}
|
||||||
8
cloudfunctions/userList/package.json
Normal file
8
cloudfunctions/userList/package.json
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
{
|
||||||
|
"name": "userList",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"main": "index.js",
|
||||||
|
"dependencies": {
|
||||||
|
"wx-server-sdk": "latest"
|
||||||
|
}
|
||||||
|
}
|
||||||
7
config/dev.ts
Normal file
7
config/dev.ts
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
export default {
|
||||||
|
env: {
|
||||||
|
TARO_APP_CLOUD_ENV: JSON.stringify(process.env.TARO_APP_CLOUD_ENV || 'cloud1-d4g697lte499543d8')
|
||||||
|
},
|
||||||
|
defineConstants: {}
|
||||||
|
}
|
||||||
|
|
||||||
57
config/index.ts
Normal file
57
config/index.ts
Normal file
@@ -0,0 +1,57 @@
|
|||||||
|
import path from 'path'
|
||||||
|
import { defineConfig, type UserConfigExport } from '@tarojs/cli'
|
||||||
|
|
||||||
|
export default defineConfig<'webpack5'>(async (merge, { command }) => {
|
||||||
|
const baseConfig: UserConfigExport<'webpack5'> = {
|
||||||
|
projectName: 'wangquan-miniapp',
|
||||||
|
date: '2026-06-16',
|
||||||
|
designWidth: 390,
|
||||||
|
deviceRatio: {
|
||||||
|
390: 2,
|
||||||
|
640: 2.34,
|
||||||
|
750: 1,
|
||||||
|
828: 1.81
|
||||||
|
},
|
||||||
|
sourceRoot: 'src',
|
||||||
|
outputRoot: 'dist',
|
||||||
|
plugins: ['@tarojs/plugin-framework-react'],
|
||||||
|
defineConstants: {},
|
||||||
|
copy: {
|
||||||
|
patterns: [{ from: 'src/custom-tab-bar', to: 'dist/custom-tab-bar' }],
|
||||||
|
options: {}
|
||||||
|
},
|
||||||
|
framework: 'react',
|
||||||
|
compiler: 'webpack5',
|
||||||
|
cache: {
|
||||||
|
enable: false
|
||||||
|
},
|
||||||
|
alias: {
|
||||||
|
'@': path.resolve(__dirname, '..', 'src')
|
||||||
|
},
|
||||||
|
sass: {
|
||||||
|
data: '@use "@/styles/tokens.scss" as *;'
|
||||||
|
},
|
||||||
|
mini: {
|
||||||
|
postcss: {
|
||||||
|
pxtransform: {
|
||||||
|
enable: true,
|
||||||
|
config: {}
|
||||||
|
},
|
||||||
|
cssModules: {
|
||||||
|
enable: false,
|
||||||
|
config: {
|
||||||
|
namingPattern: 'module',
|
||||||
|
generateScopedName: '[name]__[local]___[hash:base64:5]'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
h5: {}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (command === 'build') {
|
||||||
|
return merge({}, baseConfig, (await import('./prod')).default)
|
||||||
|
}
|
||||||
|
|
||||||
|
return merge({}, baseConfig, (await import('./dev')).default)
|
||||||
|
})
|
||||||
7
config/prod.ts
Normal file
7
config/prod.ts
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
export default {
|
||||||
|
env: {
|
||||||
|
TARO_APP_CLOUD_ENV: JSON.stringify(process.env.TARO_APP_CLOUD_ENV || 'cloud1-d4g697lte499543d8')
|
||||||
|
},
|
||||||
|
defineConstants: {}
|
||||||
|
}
|
||||||
|
|
||||||
1
dist/app-origin.wxss
vendored
Normal file
1
dist/app-origin.wxss
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
@-webkit-keyframes slideUp{from{-webkit-transform:translateY(100%);transform:translateY(100%)}to{-webkit-transform:translateY(0);transform:translateY(0)}}@keyframes slideUp{from{-webkit-transform:translateY(100%);transform:translateY(100%)}to{-webkit-transform:translateY(0);transform:translateY(0)}}@-webkit-keyframes pulse{0%{opacity:.9;-webkit-transform:scale(.2);transform:scale(.2)}80%{opacity:0;-webkit-transform:scale(2.2);transform:scale(2.2)}100%{opacity:0;-webkit-transform:scale(2.2);transform:scale(2.2)}}@keyframes pulse{0%{opacity:.9;-webkit-transform:scale(.2);transform:scale(.2)}80%{opacity:0;-webkit-transform:scale(2.2);transform:scale(2.2)}100%{opacity:0;-webkit-transform:scale(2.2);transform:scale(2.2)}}@-webkit-keyframes softAppear{from{opacity:0;-webkit-transform:translateY(16rpx);transform:translateY(16rpx)}to{opacity:1;-webkit-transform:translateY(0);transform:translateY(0)}}@keyframes softAppear{from{opacity:0;-webkit-transform:translateY(16rpx);transform:translateY(16rpx)}to{opacity:1;-webkit-transform:translateY(0);transform:translateY(0)}}.wx-icon-text{font-family:Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;line-height:1}.no-scrollbar{scrollbar-width:none}.no-scrollbar::-webkit-scrollbar{display:none}.gradient-avatar-1{background:linear-gradient(135deg,#ffb3c8,#ffd9a8)}.gradient-avatar-2{background:linear-gradient(135deg,#d8b4ff,#a4d4ff)}.gradient-avatar-3{background:linear-gradient(135deg,#8fe5b5,#d8b4ff)}.gradient-avatar-4{background:linear-gradient(135deg,#ffd9a8,#ffb3c8)}.gradient-avatar-5{background:linear-gradient(135deg,#a4d4ff,#ffd9a8)}.gradient-avatar-6{background:linear-gradient(135deg,#ffb3c8,#d8b4ff)}page{background:#14102b;color:#f0e9ff;font-family:Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;min-height:100%}button{background:transparent;border:0;color:inherit;line-height:inherit;padding:0}button::after{border:0}scroll-view{-webkit-box-sizing:border-box;box-sizing:border-box}
|
||||||
2
dist/app.js
vendored
Normal file
2
dist/app.js
vendored
Normal file
File diff suppressed because one or more lines are too long
29
dist/app.js.LICENSE.txt
vendored
Normal file
29
dist/app.js.LICENSE.txt
vendored
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
/**
|
||||||
|
* @license React
|
||||||
|
* react-reconciler-constants.production.min.js
|
||||||
|
*
|
||||||
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
||||||
|
*
|
||||||
|
* This source code is licensed under the MIT license found in the
|
||||||
|
* LICENSE file in the root directory of this source tree.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @license React
|
||||||
|
* react-reconciler.production.min.js
|
||||||
|
*
|
||||||
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
||||||
|
*
|
||||||
|
* This source code is licensed under the MIT license found in the
|
||||||
|
* LICENSE file in the root directory of this source tree.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @license React
|
||||||
|
* scheduler.production.min.js
|
||||||
|
*
|
||||||
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
||||||
|
*
|
||||||
|
* This source code is licensed under the MIT license found in the
|
||||||
|
* LICENSE file in the root directory of this source tree.
|
||||||
|
*/
|
||||||
1
dist/app.json
vendored
Normal file
1
dist/app.json
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
{"pages":["pages/plaza/index","pages/nearby/index","pages/publish/index","pages/messages/index","pages/profile/index","pages/profile-edit/index","pages/pet-edit/index","pages/chat/index","pages/contacts/index"],"window":{"navigationStyle":"custom","backgroundColor":"#14102b","backgroundTextStyle":"dark"},"tabBar":{"custom":true,"color":"#8a7aab","selectedColor":"#d8b4ff","backgroundColor":"#14102b","borderStyle":"black","list":[{"pagePath":"pages/plaza/index","text":"广场"},{"pagePath":"pages/nearby/index","text":"附近"},{"pagePath":"pages/messages/index","text":"消息"},{"pagePath":"pages/profile/index","text":"我的"}]},"permission":{"scope.userLocation":{"desc":"用于发现附近的毛孩子,以及在发布动态时标记位置"}},"requiredPrivateInfos":["chooseLocation","getLocation"],"lazyCodeLoading":"requiredComponents"}
|
||||||
1
dist/app.wxss
vendored
Normal file
1
dist/app.wxss
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
@import "./app-origin.wxss";@import "./common.wxss";
|
||||||
671
dist/base.wxml
vendored
Normal file
671
dist/base.wxml
vendored
Normal file
@@ -0,0 +1,671 @@
|
|||||||
|
<wxs module="xs" src="./utils.wxs" />
|
||||||
|
<template name="taro_tmpl">
|
||||||
|
<template is="{{xs.a(0, item.nn, '')}}" data="{{i:item,c:1,l:xs.f('',item.nn)}}" wx:for="{{root.cn}}" wx:key="sid" />
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_0_0">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" catchtouchmove="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_0_6">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" animation="{{i.p0}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_0_3">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_0_1">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_0_8">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_0_5">
|
||||||
|
<text selectable="{{xs.b(i.p3,!1)}}" space="{{i.p4}}" decode="{{xs.b(i.p0,!1)}}" user-select="{{xs.b(i.p5,false)}}" overflow="{{i.p2||visible}}" max-lines="{{i.p1}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</text>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_0_7">
|
||||||
|
<text selectable="{{xs.b(i.p3,!1)}}" space="{{i.p4}}" decode="{{xs.b(i.p0,!1)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" user-select="{{xs.b(i.p5,false)}}" overflow="{{i.p2||visible}}" max-lines="{{i.p1}}" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</text>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_0_14">
|
||||||
|
<button size="{{i.p18||'default'}}" type="{{i.p19}}" plain="{{xs.b(i.p12,!1)}}" disabled="{{i.p2}}" loading="{{xs.b(i.p9,!1)}}" form-type="{{i.p3}}" open-type="{{i.p11}}" hover-class="{{i.p4||'button-hover'}}" hover-stop-propagation="{{xs.b(i.p7,!1)}}" hover-start-time="{{xs.b(i.p5,20)}}" hover-stay-time="{{xs.b(i.p6,70)}}" name="{{i.p10}}" bindagreeprivacyauthorization="eh" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" lang="{{i.p8||en}}" session-from="{{i.p16}}" send-message-title="{{i.p15}}" send-message-path="{{i.p14}}" send-message-img="{{i.p13}}" app-parameter="{{i.p0}}" show-message-card="{{xs.b(i.p17,false)}}" business-id="{{i.p1}}" bindgetuserinfo="eh" bindcontact="eh" bindgetphonenumber="eh" bindgetrealtimephonenumber="eh" bindchooseavatar="eh" binderror="eh" bindopensetting="eh" bindlaunchapp="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</button>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_0_33">
|
||||||
|
<template is="{{xs.c(i, 'tmpl_0_')}}" data="{{i:i,c:c}}" />
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_0_33_focus">
|
||||||
|
<input value="{{i.p25}}" type="{{i.p24||''}}" password="{{xs.b(i.p12,!1)}}" placeholder="{{i.p13}}" placeholder-style="{{i.p15}}" placeholder-class="{{i.p14||'input-placeholder'}}" disabled="{{i.p8}}" maxlength="{{xs.b(i.p10,140)}}" cursor-spacing="{{xs.b(i.p7,0)}}" focus="{{xs.b(i.focus,!1)}}" confirm-type="{{i.p4||'done'}}" confirm-hold="{{xs.b(i.p3,!1)}}" cursor="{{xs.b(i.p5,-1)}}" selection-start="{{xs.b(i.p23,-1)}}" selection-end="{{xs.b(i.p22,-1)}}" bindinput="eh" bindfocus="eh" bindblur="eh" bindconfirm="eh" name="{{i.p11}}" always-embed="{{xs.b(i.p1,false)}}" adjust-position="{{xs.b(i.p0,true)}}" hold-keyboard="{{xs.b(i.p9,false)}}" safe-password-cert-path="{{i.p16}}" safe-password-length="{{i.p18}}" safe-password-time-stamp="{{i.p21}}" safe-password-nonce="{{i.p19}}" safe-password-salt="{{i.p20}}" safe-password-custom-hash="{{i.p17}}" auto-fill="{{i.p2}}" cursor-color="{{i.p6}}" bindkeyboardheightchange="eh" bindnicknamereview="eh" bindselectionchange="eh" bindkeyboardcompositionstart="eh" bindkeyboardcompositionupdate="eh" bindkeyboardcompositionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}"></input>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_0_33_blur">
|
||||||
|
<input value="{{i.p25}}" type="{{i.p24||''}}" password="{{xs.b(i.p12,!1)}}" placeholder="{{i.p13}}" placeholder-style="{{i.p15}}" placeholder-class="{{i.p14||'input-placeholder'}}" disabled="{{i.p8}}" maxlength="{{xs.b(i.p10,140)}}" cursor-spacing="{{xs.b(i.p7,0)}}" confirm-type="{{i.p4||'done'}}" confirm-hold="{{xs.b(i.p3,!1)}}" cursor="{{xs.b(i.p5,-1)}}" selection-start="{{xs.b(i.p23,-1)}}" selection-end="{{xs.b(i.p22,-1)}}" bindinput="eh" bindfocus="eh" bindblur="eh" bindconfirm="eh" name="{{i.p11}}" always-embed="{{xs.b(i.p1,false)}}" adjust-position="{{xs.b(i.p0,true)}}" hold-keyboard="{{xs.b(i.p9,false)}}" safe-password-cert-path="{{i.p16}}" safe-password-length="{{i.p18}}" safe-password-time-stamp="{{i.p21}}" safe-password-nonce="{{i.p19}}" safe-password-salt="{{i.p20}}" safe-password-custom-hash="{{i.p17}}" auto-fill="{{i.p2}}" cursor-color="{{i.p6}}" bindkeyboardheightchange="eh" bindnicknamereview="eh" bindselectionchange="eh" bindkeyboardcompositionstart="eh" bindkeyboardcompositionupdate="eh" bindkeyboardcompositionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}"></input>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_0_56">
|
||||||
|
<picker mode="{{i.p6||'selector'}}" disabled="{{i.p1}}" range="{{i.p8}}" range-key="{{i.p9}}" value="{{i.p11}}" start="{{i.p10}}" end="{{i.p2}}" fields="{{i.p3||'day'}}" custom-item="{{i.p0}}" name="{{i.p7}}" bindcancel="eh" bindchange="eh" bindcolumnchange="eh" header-text="{{i.p4}}" level="{{i.p5||region}}" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</picker>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_0_79">
|
||||||
|
<template is="{{xs.c(i, 'tmpl_0_')}}" data="{{i:i,c:c}}" />
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_0_79_focus">
|
||||||
|
<textarea value="{{i.p20}}" placeholder="{{i.p14}}" placeholder-style="{{i.p16}}" placeholder-class="{{i.p15||'textarea-placeholder'}}" disabled="{{i.p9}}" maxlength="{{xs.b(i.p12,140)}}" auto-focus="{{xs.b(i.p2,!1)}}" focus="{{xs.b(i.focus,!1)}}" auto-height="{{xs.b(i.p3,!1)}}" fixed="{{xs.b(i.p10,!1)}}" cursor-spacing="{{xs.b(i.p7,0)}}" cursor="{{xs.b(i.p6,-1)}}" selection-start="{{xs.b(i.p18,-1)}}" selection-end="{{xs.b(i.p17,-1)}}" bindfocus="eh" bindblur="eh" bindlinechange="eh" bindinput="eh" bindconfirm="eh" name="{{i.p13}}" show-confirm-bar="{{xs.b(i.p19,true)}}" adjust-position="{{xs.b(i.p1,true)}}" hold-keyboard="{{xs.b(i.p11,false)}}" disable-default-padding="{{xs.b(i.p8,false)}}" confirm-type="{{i.p5||'return'}}" confirm-hold="{{xs.b(i.p4,false)}}" adjust-keyboard-to="{{i.p0||'cursor'}}" bindkeyboardheightchange="eh" bindselectionchange="eh" bindkeyboardcompositionstart="eh" bindkeyboardcompositionupdate="eh" bindkeyboardcompositionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}"></textarea>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_0_79_blur">
|
||||||
|
<textarea value="{{i.p20}}" placeholder="{{i.p14}}" placeholder-style="{{i.p16}}" placeholder-class="{{i.p15||'textarea-placeholder'}}" disabled="{{i.p9}}" maxlength="{{xs.b(i.p12,140)}}" auto-focus="{{xs.b(i.p2,!1)}}" auto-height="{{xs.b(i.p3,!1)}}" fixed="{{xs.b(i.p10,!1)}}" cursor-spacing="{{xs.b(i.p7,0)}}" cursor="{{xs.b(i.p6,-1)}}" selection-start="{{xs.b(i.p18,-1)}}" selection-end="{{xs.b(i.p17,-1)}}" bindfocus="eh" bindblur="eh" bindlinechange="eh" bindinput="eh" bindconfirm="eh" name="{{i.p13}}" show-confirm-bar="{{xs.b(i.p19,true)}}" adjust-position="{{xs.b(i.p1,true)}}" hold-keyboard="{{xs.b(i.p11,false)}}" disable-default-padding="{{xs.b(i.p8,false)}}" confirm-type="{{i.p5||'return'}}" confirm-hold="{{xs.b(i.p4,false)}}" adjust-keyboard-to="{{i.p0||'cursor'}}" bindkeyboardheightchange="eh" bindselectionchange="eh" bindkeyboardcompositionstart="eh" bindkeyboardcompositionupdate="eh" bindkeyboardcompositionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}"></textarea>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_0_66">
|
||||||
|
<scroll-view scroll-x="{{xs.b(i.p34,!1)}}" scroll-y="{{xs.b(i.p35,!1)}}" upper-threshold="{{xs.b(i.p38,50)}}" lower-threshold="{{xs.b(i.p10,50)}}" scroll-top="{{i.p32}}" scroll-left="{{i.p31}}" scroll-into-view="{{i.p28}}" scroll-with-animation="{{xs.b(i.p33,!1)}}" enable-back-to-top="{{xs.b(i.p5,false)}}" bindscrolltoupper="eh" bindscrolltolower="eh" bindscroll="eh" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" enable-flex="{{xs.b(i.p6,false)}}" scroll-anchoring="{{xs.b(i.p27,false)}}" enhanced="{{xs.b(i.p8,false)}}" using-sticky="{{xs.b(i.p39,false)}}" paging-enabled="{{xs.b(i.p13,false)}}" enable-passive="{{xs.b(i.p7,false)}}" refresher-enabled="{{xs.b(i.p17,false)}}" refresher-threshold="{{xs.b(i.p18,45)}}" refresher-default-style="{{i.p16||'black'}}" refresher-background="{{i.p14||'#FFF'}}" refresher-triggered="{{xs.b(i.p19,false)}}" bounces="{{xs.b(i.p2,true)}}" show-scrollbar="{{xs.b(i.p36,true)}}" fast-deceleration="{{xs.b(i.p9,false)}}" type="{{i.p37||'list'}}" associative-container="{{i.p1||''}}" reverse="{{xs.b(i.p26,false)}}" clip="{{xs.b(i.p4,true)}}" cache-extent="{{i.p3}}" min-drag-distance="{{xs.b(i.p11,18)}}" scroll-into-view-within-extent="{{xs.b(i.p30,false)}}" scroll-into-view-alignment="{{i.p29||'start'}}" padding="{{i.p12||[0,0,0,0]}}" refresher-two-level-enabled="{{xs.b(i.p21,false)}}" refresher-two-level-triggered="{{xs.b(i.p25,false)}}" refresher-two-level-threshold="{{xs.b(i.p24,150)}}" refresher-two-level-close-threshold="{{xs.b(i.p20,80)}}" refresher-two-level-scroll-enabled="{{xs.b(i.p23,false)}}" refresher-ballistic-refresh-enabled="{{xs.b(i.p15,false)}}" refresher-two-level-pinned="{{xs.b(i.p22,false)}}" binddragstart="eh" binddragging="eh" binddragend="eh" bindrefresherpulling="eh" bindrefresherrefresh="eh" bindrefresherrestore="eh" bindrefresherabort="eh" bindscrollstart="eh" bindscrollend="eh" bindrefresherwillrefresh="eh" bindrefresherstatuschange="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</scroll-view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_0_4">
|
||||||
|
<image src="{{i.p4}}" mode="{{i.p2||'scaleToFill'}}" lazy-load="{{xs.b(i.p1,!1)}}" webp="{{xs.b(i.p5,false)}}" show-menu-by-longpress="{{xs.b(i.p3,false)}}" fade-in="{{xs.b(i.p0,false)}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</image>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_0_2">
|
||||||
|
<image src="{{i.p4}}" mode="{{i.p2||'scaleToFill'}}" lazy-load="{{xs.b(i.p1,!1)}}" binderror="eh" bindload="eh" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" webp="{{xs.b(i.p5,false)}}" show-menu-by-longpress="{{xs.b(i.p3,false)}}" fade-in="{{xs.b(i.p0,false)}}" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</image>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_0_41">
|
||||||
|
<map longitude="{{i.p16}}" latitude="{{i.p14}}" scale="{{xs.b(i.p23,16)}}" markers="{{i.p17||[]}}" covers="{{i.p2}}" polyline="{{i.p21||[]}}" circles="{{i.p0||[]}}" controls="{{i.p1||[]}}" include-points="{{i.p13||[]}}" show-location="{{i.p26}}" layer-style="{{xs.b(i.p15,1)}}" bindmarkertap="eh" bindcontroltap="eh" bindcallouttap="eh" bindupdated="eh" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" polygons="{{i.p20||[]}}" subkey="{{i.p29}}" rotate="{{xs.b(i.p22,0)}}" skew="{{xs.b(i.p28,0)}}" max-scale="{{xs.b(i.p18,20)}}" min-scale="{{xs.b(i.p19,3)}}" enable-3D="{{xs.b(i.p3,false)}}" show-compass="{{xs.b(i.p25,false)}}" show-scale="{{xs.b(i.p27,false)}}" enable-overlooking="{{xs.b(i.p6,false)}}" enable-auto-max-overlooking="{{xs.b(i.p4,false)}}" enable-zoom="{{xs.b(i.p12,true)}}" enable-scroll="{{xs.b(i.p10,true)}}" enable-rotate="{{xs.b(i.p8,false)}}" enable-satellite="{{xs.b(i.p9,false)}}" enable-traffic="{{xs.b(i.p11,false)}}" enable-poi="{{xs.b(i.p7,true)}}" enable-building="{{xs.b(i.p5,true)}}" setting="{{xs.d(i.p24)}}" bindlabeltap="eh" bindregionchange="eh" bindpoitap="eh" bindpolylinetap="eh" bindabilitysuccess="eh" bindabilityfailed="eh" bindauthsuccess="eh" bindinterpolatepoint="eh" binderror="eh" bindanchorpointtap="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</map>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_0_9">
|
||||||
|
<block>{{i.v}}</block>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_1_0">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" catchtouchmove="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_1_6">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" animation="{{i.p0}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_1_3">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_1_1">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_1_8">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_1_5">
|
||||||
|
<text selectable="{{xs.b(i.p3,!1)}}" space="{{i.p4}}" decode="{{xs.b(i.p0,!1)}}" user-select="{{xs.b(i.p5,false)}}" overflow="{{i.p2||visible}}" max-lines="{{i.p1}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</text>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_1_7">
|
||||||
|
<text selectable="{{xs.b(i.p3,!1)}}" space="{{i.p4}}" decode="{{xs.b(i.p0,!1)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" user-select="{{xs.b(i.p5,false)}}" overflow="{{i.p2||visible}}" max-lines="{{i.p1}}" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</text>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_1_66">
|
||||||
|
<scroll-view scroll-x="{{xs.b(i.p34,!1)}}" scroll-y="{{xs.b(i.p35,!1)}}" upper-threshold="{{xs.b(i.p38,50)}}" lower-threshold="{{xs.b(i.p10,50)}}" scroll-top="{{i.p32}}" scroll-left="{{i.p31}}" scroll-into-view="{{i.p28}}" scroll-with-animation="{{xs.b(i.p33,!1)}}" enable-back-to-top="{{xs.b(i.p5,false)}}" bindscrolltoupper="eh" bindscrolltolower="eh" bindscroll="eh" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" enable-flex="{{xs.b(i.p6,false)}}" scroll-anchoring="{{xs.b(i.p27,false)}}" enhanced="{{xs.b(i.p8,false)}}" using-sticky="{{xs.b(i.p39,false)}}" paging-enabled="{{xs.b(i.p13,false)}}" enable-passive="{{xs.b(i.p7,false)}}" refresher-enabled="{{xs.b(i.p17,false)}}" refresher-threshold="{{xs.b(i.p18,45)}}" refresher-default-style="{{i.p16||'black'}}" refresher-background="{{i.p14||'#FFF'}}" refresher-triggered="{{xs.b(i.p19,false)}}" bounces="{{xs.b(i.p2,true)}}" show-scrollbar="{{xs.b(i.p36,true)}}" fast-deceleration="{{xs.b(i.p9,false)}}" type="{{i.p37||'list'}}" associative-container="{{i.p1||''}}" reverse="{{xs.b(i.p26,false)}}" clip="{{xs.b(i.p4,true)}}" cache-extent="{{i.p3}}" min-drag-distance="{{xs.b(i.p11,18)}}" scroll-into-view-within-extent="{{xs.b(i.p30,false)}}" scroll-into-view-alignment="{{i.p29||'start'}}" padding="{{i.p12||[0,0,0,0]}}" refresher-two-level-enabled="{{xs.b(i.p21,false)}}" refresher-two-level-triggered="{{xs.b(i.p25,false)}}" refresher-two-level-threshold="{{xs.b(i.p24,150)}}" refresher-two-level-close-threshold="{{xs.b(i.p20,80)}}" refresher-two-level-scroll-enabled="{{xs.b(i.p23,false)}}" refresher-ballistic-refresh-enabled="{{xs.b(i.p15,false)}}" refresher-two-level-pinned="{{xs.b(i.p22,false)}}" binddragstart="eh" binddragging="eh" binddragend="eh" bindrefresherpulling="eh" bindrefresherrefresh="eh" bindrefresherrestore="eh" bindrefresherabort="eh" bindscrollstart="eh" bindscrollend="eh" bindrefresherwillrefresh="eh" bindrefresherstatuschange="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</scroll-view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_2_0">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" catchtouchmove="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_2_6">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" animation="{{i.p0}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_2_3">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_2_1">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_2_8">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_2_5">
|
||||||
|
<text selectable="{{xs.b(i.p3,!1)}}" space="{{i.p4}}" decode="{{xs.b(i.p0,!1)}}" user-select="{{xs.b(i.p5,false)}}" overflow="{{i.p2||visible}}" max-lines="{{i.p1}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</text>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_2_7">
|
||||||
|
<text selectable="{{xs.b(i.p3,!1)}}" space="{{i.p4}}" decode="{{xs.b(i.p0,!1)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" user-select="{{xs.b(i.p5,false)}}" overflow="{{i.p2||visible}}" max-lines="{{i.p1}}" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</text>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_2_66">
|
||||||
|
<scroll-view scroll-x="{{xs.b(i.p34,!1)}}" scroll-y="{{xs.b(i.p35,!1)}}" upper-threshold="{{xs.b(i.p38,50)}}" lower-threshold="{{xs.b(i.p10,50)}}" scroll-top="{{i.p32}}" scroll-left="{{i.p31}}" scroll-into-view="{{i.p28}}" scroll-with-animation="{{xs.b(i.p33,!1)}}" enable-back-to-top="{{xs.b(i.p5,false)}}" bindscrolltoupper="eh" bindscrolltolower="eh" bindscroll="eh" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" enable-flex="{{xs.b(i.p6,false)}}" scroll-anchoring="{{xs.b(i.p27,false)}}" enhanced="{{xs.b(i.p8,false)}}" using-sticky="{{xs.b(i.p39,false)}}" paging-enabled="{{xs.b(i.p13,false)}}" enable-passive="{{xs.b(i.p7,false)}}" refresher-enabled="{{xs.b(i.p17,false)}}" refresher-threshold="{{xs.b(i.p18,45)}}" refresher-default-style="{{i.p16||'black'}}" refresher-background="{{i.p14||'#FFF'}}" refresher-triggered="{{xs.b(i.p19,false)}}" bounces="{{xs.b(i.p2,true)}}" show-scrollbar="{{xs.b(i.p36,true)}}" fast-deceleration="{{xs.b(i.p9,false)}}" type="{{i.p37||'list'}}" associative-container="{{i.p1||''}}" reverse="{{xs.b(i.p26,false)}}" clip="{{xs.b(i.p4,true)}}" cache-extent="{{i.p3}}" min-drag-distance="{{xs.b(i.p11,18)}}" scroll-into-view-within-extent="{{xs.b(i.p30,false)}}" scroll-into-view-alignment="{{i.p29||'start'}}" padding="{{i.p12||[0,0,0,0]}}" refresher-two-level-enabled="{{xs.b(i.p21,false)}}" refresher-two-level-triggered="{{xs.b(i.p25,false)}}" refresher-two-level-threshold="{{xs.b(i.p24,150)}}" refresher-two-level-close-threshold="{{xs.b(i.p20,80)}}" refresher-two-level-scroll-enabled="{{xs.b(i.p23,false)}}" refresher-ballistic-refresh-enabled="{{xs.b(i.p15,false)}}" refresher-two-level-pinned="{{xs.b(i.p22,false)}}" binddragstart="eh" binddragging="eh" binddragend="eh" bindrefresherpulling="eh" bindrefresherrefresh="eh" bindrefresherrestore="eh" bindrefresherabort="eh" bindscrollstart="eh" bindscrollend="eh" bindrefresherwillrefresh="eh" bindrefresherstatuschange="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</scroll-view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_3_0">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" catchtouchmove="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_3_6">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" animation="{{i.p0}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_3_3">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_3_1">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_3_8">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_3_5">
|
||||||
|
<text selectable="{{xs.b(i.p3,!1)}}" space="{{i.p4}}" decode="{{xs.b(i.p0,!1)}}" user-select="{{xs.b(i.p5,false)}}" overflow="{{i.p2||visible}}" max-lines="{{i.p1}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</text>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_3_7">
|
||||||
|
<text selectable="{{xs.b(i.p3,!1)}}" space="{{i.p4}}" decode="{{xs.b(i.p0,!1)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" user-select="{{xs.b(i.p5,false)}}" overflow="{{i.p2||visible}}" max-lines="{{i.p1}}" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</text>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_3_66">
|
||||||
|
<scroll-view scroll-x="{{xs.b(i.p34,!1)}}" scroll-y="{{xs.b(i.p35,!1)}}" upper-threshold="{{xs.b(i.p38,50)}}" lower-threshold="{{xs.b(i.p10,50)}}" scroll-top="{{i.p32}}" scroll-left="{{i.p31}}" scroll-into-view="{{i.p28}}" scroll-with-animation="{{xs.b(i.p33,!1)}}" enable-back-to-top="{{xs.b(i.p5,false)}}" bindscrolltoupper="eh" bindscrolltolower="eh" bindscroll="eh" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" enable-flex="{{xs.b(i.p6,false)}}" scroll-anchoring="{{xs.b(i.p27,false)}}" enhanced="{{xs.b(i.p8,false)}}" using-sticky="{{xs.b(i.p39,false)}}" paging-enabled="{{xs.b(i.p13,false)}}" enable-passive="{{xs.b(i.p7,false)}}" refresher-enabled="{{xs.b(i.p17,false)}}" refresher-threshold="{{xs.b(i.p18,45)}}" refresher-default-style="{{i.p16||'black'}}" refresher-background="{{i.p14||'#FFF'}}" refresher-triggered="{{xs.b(i.p19,false)}}" bounces="{{xs.b(i.p2,true)}}" show-scrollbar="{{xs.b(i.p36,true)}}" fast-deceleration="{{xs.b(i.p9,false)}}" type="{{i.p37||'list'}}" associative-container="{{i.p1||''}}" reverse="{{xs.b(i.p26,false)}}" clip="{{xs.b(i.p4,true)}}" cache-extent="{{i.p3}}" min-drag-distance="{{xs.b(i.p11,18)}}" scroll-into-view-within-extent="{{xs.b(i.p30,false)}}" scroll-into-view-alignment="{{i.p29||'start'}}" padding="{{i.p12||[0,0,0,0]}}" refresher-two-level-enabled="{{xs.b(i.p21,false)}}" refresher-two-level-triggered="{{xs.b(i.p25,false)}}" refresher-two-level-threshold="{{xs.b(i.p24,150)}}" refresher-two-level-close-threshold="{{xs.b(i.p20,80)}}" refresher-two-level-scroll-enabled="{{xs.b(i.p23,false)}}" refresher-ballistic-refresh-enabled="{{xs.b(i.p15,false)}}" refresher-two-level-pinned="{{xs.b(i.p22,false)}}" binddragstart="eh" binddragging="eh" binddragend="eh" bindrefresherpulling="eh" bindrefresherrefresh="eh" bindrefresherrestore="eh" bindrefresherabort="eh" bindscrollstart="eh" bindscrollend="eh" bindrefresherwillrefresh="eh" bindrefresherstatuschange="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</scroll-view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_4_0">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" catchtouchmove="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_4_6">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" animation="{{i.p0}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_4_3">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_4_1">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_4_8">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_4_5">
|
||||||
|
<text selectable="{{xs.b(i.p3,!1)}}" space="{{i.p4}}" decode="{{xs.b(i.p0,!1)}}" user-select="{{xs.b(i.p5,false)}}" overflow="{{i.p2||visible}}" max-lines="{{i.p1}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</text>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_4_7">
|
||||||
|
<text selectable="{{xs.b(i.p3,!1)}}" space="{{i.p4}}" decode="{{xs.b(i.p0,!1)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" user-select="{{xs.b(i.p5,false)}}" overflow="{{i.p2||visible}}" max-lines="{{i.p1}}" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</text>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_5_0">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" catchtouchmove="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_5_6">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" animation="{{i.p0}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_5_3">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_5_1">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_5_8">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_5_5">
|
||||||
|
<text selectable="{{xs.b(i.p3,!1)}}" space="{{i.p4}}" decode="{{xs.b(i.p0,!1)}}" user-select="{{xs.b(i.p5,false)}}" overflow="{{i.p2||visible}}" max-lines="{{i.p1}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</text>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_5_7">
|
||||||
|
<text selectable="{{xs.b(i.p3,!1)}}" space="{{i.p4}}" decode="{{xs.b(i.p0,!1)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" user-select="{{xs.b(i.p5,false)}}" overflow="{{i.p2||visible}}" max-lines="{{i.p1}}" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</text>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_6_0">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" catchtouchmove="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_6_6">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" animation="{{i.p0}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_6_3">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_6_1">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_6_8">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_6_7">
|
||||||
|
<text selectable="{{xs.b(i.p3,!1)}}" space="{{i.p4}}" decode="{{xs.b(i.p0,!1)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" user-select="{{xs.b(i.p5,false)}}" overflow="{{i.p2||visible}}" max-lines="{{i.p1}}" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</text>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_7_0">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" catchtouchmove="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_7_6">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" animation="{{i.p0}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_7_3">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_7_1">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_7_8">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_7_7">
|
||||||
|
<text selectable="{{xs.b(i.p3,!1)}}" space="{{i.p4}}" decode="{{xs.b(i.p0,!1)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" user-select="{{xs.b(i.p5,false)}}" overflow="{{i.p2||visible}}" max-lines="{{i.p1}}" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</text>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_8_0">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" catchtouchmove="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_8_6">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" animation="{{i.p0}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_8_3">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_8_1">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_8_8">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_8_7">
|
||||||
|
<text selectable="{{xs.b(i.p3,!1)}}" space="{{i.p4}}" decode="{{xs.b(i.p0,!1)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" user-select="{{xs.b(i.p5,false)}}" overflow="{{i.p2||visible}}" max-lines="{{i.p1}}" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</text>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_9_0">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" catchtouchmove="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_9_6">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" animation="{{i.p0}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_9_3">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_9_1">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_9_8">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_9_7">
|
||||||
|
<text selectable="{{xs.b(i.p3,!1)}}" space="{{i.p4}}" decode="{{xs.b(i.p0,!1)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" user-select="{{xs.b(i.p5,false)}}" overflow="{{i.p2||visible}}" max-lines="{{i.p1}}" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</text>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_10_0">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" catchtouchmove="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_10_6">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" animation="{{i.p0}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_10_3">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_10_1">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_10_8">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_10_7">
|
||||||
|
<text selectable="{{xs.b(i.p3,!1)}}" space="{{i.p4}}" decode="{{xs.b(i.p0,!1)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" user-select="{{xs.b(i.p5,false)}}" overflow="{{i.p2||visible}}" max-lines="{{i.p1}}" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</text>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_11_0">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" catchtouchmove="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_11_6">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" animation="{{i.p0}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_11_3">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_11_1">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_11_8">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_11_7">
|
||||||
|
<text selectable="{{xs.b(i.p3,!1)}}" space="{{i.p4}}" decode="{{xs.b(i.p0,!1)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" user-select="{{xs.b(i.p5,false)}}" overflow="{{i.p2||visible}}" max-lines="{{i.p1}}" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</text>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_12_0">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" catchtouchmove="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_12_6">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" animation="{{i.p0}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_12_3">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_12_1">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_12_8">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_12_7">
|
||||||
|
<text selectable="{{xs.b(i.p3,!1)}}" space="{{i.p4}}" decode="{{xs.b(i.p0,!1)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" user-select="{{xs.b(i.p5,false)}}" overflow="{{i.p2||visible}}" max-lines="{{i.p1}}" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</text>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_13_0">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" catchtouchmove="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_13_6">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" animation="{{i.p0}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_13_3">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_13_1">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_13_8">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_13_7">
|
||||||
|
<text selectable="{{xs.b(i.p3,!1)}}" space="{{i.p4}}" decode="{{xs.b(i.p0,!1)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" user-select="{{xs.b(i.p5,false)}}" overflow="{{i.p2||visible}}" max-lines="{{i.p1}}" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.a(c, item.nn, l)}}" data="{{i:item,c:c+1,l:xs.f(l,item.nn)}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</text>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_14_0">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" catchtouchmove="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.e(15)}}" data="{{i:item,c:c,l:l}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_14_6">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" animation="{{i.p0}}" style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.e(15)}}" data="{{i:item,c:c,l:l}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_14_3">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.e(15)}}" data="{{i:item,c:c,l:l}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_14_1">
|
||||||
|
<view style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.e(15)}}" data="{{i:item,c:c,l:l}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_14_8">
|
||||||
|
<view hover-class="{{i.p1||'none'}}" hover-stop-propagation="{{xs.b(i.p4,!1)}}" hover-start-time="{{xs.b(i.p2,50)}}" hover-stay-time="{{xs.b(i.p3,400)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" animation="{{i.p0}}" bindanimationstart="eh" bindanimationiteration="eh" bindanimationend="eh" bindtransitionend="eh" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.e(15)}}" data="{{i:item,c:c,l:l}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_14_7">
|
||||||
|
<text selectable="{{xs.b(i.p3,!1)}}" space="{{i.p4}}" decode="{{xs.b(i.p0,!1)}}" bindtouchstart="eh" bindtouchmove="eh" bindtouchend="eh" bindtouchcancel="eh" bindlongpress="eh" user-select="{{xs.b(i.p5,false)}}" overflow="{{i.p2||visible}}" max-lines="{{i.p1}}" style="{{i.st}}" class="{{i.cl}}" bindtap="eh" id="{{i.uid||i.sid}}" data-sid="{{i.sid}}">
|
||||||
|
<template is="{{xs.e(15)}}" data="{{i:item,c:c,l:l}}" wx:for="{{i.cn}}" wx:key="sid" />
|
||||||
|
</text>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<template name="tmpl_15_container">
|
||||||
|
<block wx:if="{{i.nn === '9'}}">
|
||||||
|
<template is="tmpl_0_9" data="{{i:i}}" />
|
||||||
|
</block>
|
||||||
|
<block wx:else>
|
||||||
|
<comp i="{{i}}" l="{{l}}" />
|
||||||
|
</block>
|
||||||
|
</template>
|
||||||
1
dist/common.js
vendored
Normal file
1
dist/common.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1
dist/common.wxss
vendored
Normal file
1
dist/common.wxss
vendored
Normal file
File diff suppressed because one or more lines are too long
1
dist/comp.js
vendored
Normal file
1
dist/comp.js
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
"use strict";(wx["webpackJsonp"]=wx["webpackJsonp"]||[]).push([[862],{},function(n){var t=function(t){return n(n.s=t)};n.O(0,[907,96],function(){return t(5838)});n.O()}]);
|
||||||
1
dist/comp.json
vendored
Normal file
1
dist/comp.json
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
{"component":true,"styleIsolation":"apply-shared","usingComponents":{"comp":"./comp"}}
|
||||||
3
dist/comp.wxml
vendored
Normal file
3
dist/comp.wxml
vendored
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
<import src="./base.wxml" />
|
||||||
|
<wxs module="xs" src="./utils.wxs" />
|
||||||
|
<template is="{{'tmpl_0_' + i.nn}}" data="{{i:i,c:1,l:xs.f('',i.nn)}}" />
|
||||||
1
dist/custom-tab-bar/index.js
vendored
Normal file
1
dist/custom-tab-bar/index.js
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
(wx["webpackJsonp"]=wx["webpackJsonp"]||[]).push([[777],{3241:function(){Component({})}},function(n){var o=function(o){return n(n.s=o)};o(3241)}]);
|
||||||
1
dist/custom-tab-bar/index.json
vendored
Normal file
1
dist/custom-tab-bar/index.json
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
{"component":true}
|
||||||
1
dist/custom-tab-bar/index.wxml
vendored
Normal file
1
dist/custom-tab-bar/index.wxml
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
<view class="native-tabbar-placeholder"></view>
|
||||||
1
dist/custom-tab-bar/index.wxss
vendored
Normal file
1
dist/custom-tab-bar/index.wxss
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
.native-tabbar-placeholder{display:none}
|
||||||
1
dist/pages/chat/index.js
vendored
Normal file
1
dist/pages/chat/index.js
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
"use strict";(wx["webpackJsonp"]=wx["webpackJsonp"]||[]).push([[947],{5053:function(e,a,n){var t=n(8870),s=n(1212),c=n(467),r=n(5544),o=n(6540),i=n(758),l=n.n(i),u=n(118),h=n(374),d=n(3401),v=n(7745),m=n(9672),_=n(4848);function p(){var e=(0,h.v)(),a=e.statusBarHeight,n=e.safeBottom,t=(0,i.useRouter)(),p=t.params.conversationId||"",f=t.params.targetUserId||"",x=decodeURIComponent(t.params.title||"\u804a\u5929"),b=(0,o.useState)(p),S=(0,r.A)(b,2),j=S[0],w=S[1],N=(0,o.useState)(null),I=(0,r.A)(N,2),A=I[0],g=I[1],k=(0,o.useState)([]),y=(0,r.A)(k,2),U=y[0],B=y[1],C=(0,o.useState)(""),E=(0,r.A)(C,2),M=E[0],T=E[1],Y=(0,o.useState)(!1),z=(0,r.A)(Y,2),R=z[0],D=z[1],H=(0,o.useState)(0),J=(0,r.A)(H,2),K=J[0],O=J[1],G=(0,o.useRef)(null),P=function(){var e=(0,c.A)((0,s.A)().m(function e(){var a;return(0,s.A)().w(function(e){while(1)switch(e.n){case 0:return e.n=1,(0,m.fG)({conversationId:j||void 0,targetUserId:j?void 0:f||void 0});case 1:a=e.v,a.conversationId&&a.conversationId!==j&&w(a.conversationId),a.peer&&g(a.peer),B(a.messages),O(function(e){return e+1e5});case 2:return e.a(2)}},e)}));return function(){return e.apply(this,arguments)}}();(0,o.useEffect)(function(){P()},[]),(0,i.useDidShow)(function(){G.current=setInterval(P,5e3)}),(0,i.useDidHide)(function(){G.current&&clearInterval(G.current)}),(0,o.useEffect)(function(){return function(){G.current&&clearInterval(G.current)}},[]);var W=function(){var e=(0,c.A)((0,s.A)().m(function e(){var a,n;return(0,s.A)().w(function(e){while(1)switch(e.p=e.n){case 0:if(a=M.trim(),a&&!R){e.n=1;break}return e.a(2);case 1:return D(!0),T(""),e.p=2,e.n=3,(0,m._z)(a,{conversationId:j||void 0,toUserId:j?void 0:f||void 0});case 3:return n=e.v,n.conversationId&&w(n.conversationId),e.n=4,P();case 4:e.n=6;break;case 5:e.p=5,e.v,l().showToast({title:"\u53d1\u9001\u5931\u8d25",icon:"none"}),T(a);case 6:return e.p=6,D(!1),e.f(6);case 7:return e.a(2)}},e,null,[[2,5,6,7]])}));return function(){return e.apply(this,arguments)}}(),q=(null===A||void 0===A?void 0:A.name)||x;return(0,_.jsxs)(u.Ss,{className:"chat",children:[(0,_.jsx)(u.Ss,{className:"chat__nav",style:{paddingTop:"".concat(a,"px")},children:(0,_.jsxs)(u.Ss,{className:"chat__nav-row",children:[(0,_.jsx)(u.Ss,{className:"chat__back",onClick:function(){return l().navigateBack()},children:(0,_.jsx)(d.A,{name:"chev",size:22,className:"chat__back-icon"})}),(0,_.jsx)(u.EY,{className:"chat__title",children:q}),(0,_.jsx)(u.Ss,{className:"chat__nav-spacer"})]})}),(0,_.jsx)(u.BM,{scrollY:!0,className:"chat__scroll",scrollTop:K,scrollWithAnimation:!0,enhanced:!0,showScrollbar:!1,children:(0,_.jsx)(u.Ss,{className:"chat__list",children:0===U.length?(0,_.jsx)(u.EY,{className:"chat__empty",children:"\u8fd8\u6ca1\u6709\u6d88\u606f\uff0c\u6253\u4e2a\u62db\u547c\u5427 \ud83d\udc4b"}):U.map(function(e){return(0,_.jsxs)(u.Ss,{className:"chat__row ".concat(e.fromMe?"chat__row--me":""),children:[e.fromMe?null:(0,_.jsx)(v.A,{avatarKey:null===A||void 0===A?void 0:A.avatarKey,avatarUrl:null===A||void 0===A?void 0:A.avatarUrl,size:"sm"}),(0,_.jsxs)(u.Ss,{className:"chat__bubble-wrap",children:[(0,_.jsx)(u.Ss,{className:"chat__bubble ".concat(e.fromMe?"chat__bubble--me":""),children:e.content}),(0,_.jsx)(u.EY,{className:"chat__time",children:e.timeText})]})]},e._id)})})}),(0,_.jsxs)(u.Ss,{className:"chat__input-bar",style:{paddingBottom:"".concat(Math.max(12,n),"px")},children:[(0,_.jsx)(u.pd,{className:"chat__input",value:M,placeholder:"\u53d1\u6d88\u606f\u2026",placeholderClass:"chat__input-ph",confirmType:"send",onInput:function(e){return T(e.detail.value)},onConfirm:W}),(0,_.jsx)(u.Ss,{className:"chat__send ".concat(M.trim()?"":"chat__send--disabled"),onClick:W,children:"\u53d1\u9001"})]})]})}var f={},x=(0,t.eU)(p,"pages/chat/index",{root:{cn:[]}},f||{});p&&p.behaviors&&(x.behaviors=(x.behaviors||[]).concat(p.behaviors));Page(x)}},function(e){var a=function(a){return e(e.s=a)};e.O(0,[907,96,76],function(){return a(5053)});e.O()}]);
|
||||||
1
dist/pages/chat/index.json
vendored
Normal file
1
dist/pages/chat/index.json
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
{"usingComponents":{"comp":"../../comp"}}
|
||||||
2
dist/pages/chat/index.wxml
vendored
Normal file
2
dist/pages/chat/index.wxml
vendored
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
<import src="../../base.wxml"/>
|
||||||
|
<template is="taro_tmpl" data="{{root:root}}" />
|
||||||
1
dist/pages/chat/index.wxss
vendored
Normal file
1
dist/pages/chat/index.wxss
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
.chat{background:#14102b;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;height:100vh}.chat__nav{-ms-flex-negative:0;background:#14102b;border-bottom:2rpx solid rgba(216,180,255,.06);flex-shrink:0}.chat__nav-row{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;height:100rpx;padding:0 24rpx}.chat__back{display:-ms-flexbox;display:flex;height:72rpx;width:72rpx;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;color:#f0e9ff;justify-content:center}.chat__back-icon{-webkit-transform:rotate(180deg);-ms-transform:rotate(180deg);transform:rotate(180deg)}.chat__title{color:#f0e9ff;-ms-flex:1;flex:1;font:700 32rpx/1 Space Grotesk,Inter,system-ui,sans-serif;text-align:center}.chat__nav-spacer{width:72rpx}.chat__scroll{-ms-flex:1;flex:1;min-height:0}.chat__list{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;gap:28rpx;padding:32rpx}.chat__empty{color:#8a7aab;font:400 26rpx/1.6 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;padding:80rpx 0;text-align:center}.chat__row{display:-ms-flexbox;display:flex;-ms-flex-align:end;align-items:flex-end;gap:16rpx;max-width:80%}.chat__row--me{-ms-flex-item-align:end;align-self:flex-end;-ms-flex-direction:row-reverse;flex-direction:row-reverse}.chat__bubble-wrap{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;gap:8rpx}.chat__bubble{background:rgba(45,34,85,.6);border:2rpx solid rgba(216,180,255,.1);border-radius:28rpx;color:#f0e9ff;font:400 28rpx/1.5 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;padding:20rpx 26rpx;word-break:break-word}.chat__bubble--me{background:linear-gradient(135deg,#d8b4ff,#ffb3c8);border-color:transparent;color:#2a1d10}.chat__time{color:#8a7aab;font:400 20rpx/1 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;padding:0 8rpx}.chat__row--me .chat__time{text-align:right}.chat__input-bar{-ms-flex-negative:0;display:-ms-flexbox;display:flex;flex-shrink:0;-ms-flex-align:center;align-items:center;background:#14102b;border-top:2rpx solid rgba(216,180,255,.08);gap:20rpx;padding:20rpx 32rpx 24rpx}.chat__input{background:rgba(31,23,66,.68);border:2rpx solid rgba(216,180,255,.1);border-radius:19998rpx;-webkit-box-sizing:border-box;box-sizing:border-box;color:#f0e9ff;-ms-flex:1;flex:1;font:400 28rpx/80rpx Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;height:80rpx;padding:0 28rpx}.chat__input-ph{color:#8a7aab}.chat__send{-ms-flex-negative:0;background:linear-gradient(135deg,#d8b4ff,#ffb3c8);border-radius:19998rpx;color:#2a1d10;flex-shrink:0;font:700 28rpx/80rpx Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;height:80rpx;padding:0 36rpx}.chat__send--disabled{opacity:.5}
|
||||||
1
dist/pages/contacts/index.js
vendored
Normal file
1
dist/pages/contacts/index.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1
dist/pages/contacts/index.json
vendored
Normal file
1
dist/pages/contacts/index.json
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
{"usingComponents":{"comp":"../../comp"}}
|
||||||
2
dist/pages/contacts/index.wxml
vendored
Normal file
2
dist/pages/contacts/index.wxml
vendored
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
<import src="../../base.wxml"/>
|
||||||
|
<template is="taro_tmpl" data="{{root:root}}" />
|
||||||
1
dist/pages/contacts/index.wxss
vendored
Normal file
1
dist/pages/contacts/index.wxss
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
.contacts{background:#14102b;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;height:100vh}.contacts__nav{-ms-flex-negative:0;background:#14102b;flex-shrink:0}.contacts__nav-row{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;height:100rpx;padding:0 24rpx}.contacts__back{display:-ms-flexbox;display:flex;height:72rpx;width:72rpx;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;color:#f0e9ff;justify-content:center}.contacts__back-icon{-webkit-transform:rotate(180deg);-ms-transform:rotate(180deg);transform:rotate(180deg)}.contacts__title{color:#f0e9ff;-ms-flex:1;flex:1;font:700 32rpx/1 Space Grotesk,Inter,system-ui,sans-serif;text-align:center}.contacts__nav-spacer{width:72rpx}.contacts__search{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;background:rgba(31,23,66,.68);border:2rpx solid rgba(216,180,255,.1);border-radius:19998rpx;gap:16rpx;height:80rpx;margin:24rpx 40rpx 8rpx;padding:0 28rpx}.contacts__search-icon{color:#8a7aab}.contacts__search-input{color:#f0e9ff;-ms-flex:1;flex:1;font:400 28rpx/80rpx Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;height:80rpx}.contacts__search-ph{color:#8a7aab}.contacts__scroll{-ms-flex:1;flex:1;min-height:0}.contacts__list{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;padding:16rpx 40rpx 48rpx}.contacts__item{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;border-bottom:2rpx solid rgba(216,180,255,.05);gap:24rpx;padding:24rpx 0}.contacts__left{display:-ms-flexbox;display:flex;-ms-flex:1;flex:1;min-width:0;-ms-flex-align:center;align-items:center;gap:24rpx}.contacts__meta{-ms-flex:1;flex:1;min-width:0}.contacts__name{color:#f0e9ff;display:block;font:600 30rpx/1.3 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif}.contacts__bio{color:#8a7aab;display:block;font:400 24rpx/1.3 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;margin-top:4rpx;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.contacts__actions{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;gap:16rpx;-ms-flex-negative:0;flex-shrink:0}.contacts__friend-tag{background:rgba(216,180,255,.14);border-radius:19998rpx;color:#d8b4ff;font:600 20rpx/1 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;padding:6rpx 16rpx}.contacts__follow{background:linear-gradient(135deg,#d8b4ff,#ffb3c8);border-radius:19998rpx;color:#2a1d10;font:600 24rpx/1 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;padding:14rpx 32rpx}.contacts__follow--on{background:transparent;border:2rpx solid rgba(216,180,255,.3);color:#8a7aab}.contacts__empty{color:#8a7aab;font:400 26rpx/1.6 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;padding:96rpx 40rpx;text-align:center}
|
||||||
1
dist/pages/messages/index.js
vendored
Normal file
1
dist/pages/messages/index.js
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
"use strict";(wx["webpackJsonp"]=wx["webpackJsonp"]||[]).push([[781],{6430:function(e,s,a){var n=a(8870),t=a(1212),r=a(9379),i=a(467),c=a(5544),o=a(6540),l=a(758),u=a.n(l),m=a(118),v=a(7797),d=a(8324),_=a(6503),x=a(7377),h=a(326),p=a(7745),j=a(3401),f=a(4848);function g(e){var s=e.users,a=e.onSelect,n=e.onDiscover;return(0,f.jsx)(m.BM,{scrollX:!0,className:"active-user-row",showScrollbar:!1,children:(0,f.jsxs)(m.Ss,{className:"active-user-row__inner",children:[(0,f.jsxs)(m.Ss,{className:"active-user-row__item",onClick:n,children:[(0,f.jsx)(m.Ss,{className:"active-user-row__avatar-wrap active-user-row__add",children:(0,f.jsx)(j.A,{name:"plus",size:22})}),(0,f.jsx)(m.EY,{className:"active-user-row__name",children:"\u53d1\u73b0"})]}),s.map(function(e){return(0,f.jsxs)(m.Ss,{className:"active-user-row__item",onClick:function(){return null===a||void 0===a?void 0:a(e)},children:[(0,f.jsxs)(m.Ss,{className:"active-user-row__avatar-wrap",children:[(0,f.jsx)(p.A,{avatarKey:e.avatarKey,avatarUrl:e.avatarUrl,size:"lg",label:e.name}),e.live?(0,f.jsx)(m.EY,{className:"active-user-row__live",children:"LIVE"}):null]}),(0,f.jsx)(m.EY,{className:"active-user-row__name",children:e.name})]},e.id)})]})})}var w=g;function N(e){var s=e.conversation,a=e.onClick;return(0,f.jsxs)(m.Ss,{className:"conversation-item",onClick:a,children:[(0,f.jsx)(p.A,{avatarKey:s.avatarKey,avatarUrl:s.avatarUrl,size:"lg",online:s.online,petTag:"single"===s.type?"\ud83d\udc3e":void 0}),(0,f.jsxs)(m.Ss,{className:"conversation-item__main",children:[(0,f.jsxs)(m.Ss,{className:"conversation-item__top",children:[(0,f.jsxs)(m.Ss,{className:"conversation-item__name-row",children:[(0,f.jsx)(m.EY,{className:"conversation-item__name",children:s.title}),s.petName?(0,f.jsx)(m.EY,{className:"conversation-item__pet",children:s.petName}):null]}),(0,f.jsx)(m.EY,{className:"conversation-item__time",children:s.timeText})]}),(0,f.jsxs)(m.Ss,{className:"conversation-item__bottom",children:[(0,f.jsx)(m.EY,{className:"conversation-item__preview",children:s.preview}),s.pinned?(0,f.jsx)(m.Ss,{className:"conversation-item__pin",children:(0,f.jsx)(j.A,{name:"bookmark",size:12})}):s.unreadCount>0?(0,f.jsx)(m.EY,{className:"conversation-item__badge",children:s.unreadCount}):s.muted?(0,f.jsx)(m.Ss,{className:"conversation-item__muted"}):null]})]})]})}var S=N,A=a(9672),b=[{key:"all",label:"\u5168\u90e8"},{key:"unread",label:"\u672a\u8bfb"}];function C(){var e=(0,o.useState)("all"),s=(0,c.A)(e,2),a=s[0],n=s[1],p=(0,o.useState)([]),j=(0,c.A)(p,2),g=j[0],N=j[1],C=(0,o.useState)([]),E=(0,c.A)(C,2),k=E[0],y=E[1],Y=(0,o.useState)(""),U=(0,c.A)(Y,2),T=U[0],I=U[1],L=(0,o.useRef)(!0),z=function(){(0,A.VL)(a).then(function(e){N(e.activeUsers),y(e.conversations)})};(0,o.useEffect)(function(){z()},[a]),(0,l.useDidShow)(function(){L.current?L.current=!1:z()});var K=function(){var e=(0,i.A)((0,t.A)().m(function e(s){return(0,t.A)().w(function(e){while(1)switch(e.n){case 0:y(function(e){return e.map(function(e){return e._id===s._id?(0,r.A)((0,r.A)({},e),{},{unreadCount:0}):e})}),(0,A.vs)(s._id),u().navigateTo({url:"/pages/chat/index?conversationId=".concat(s._id,"&title=").concat(encodeURIComponent(s.title))});case 1:return e.a(2)}},e)}));return function(s){return e.apply(this,arguments)}}(),D=function(e){u().navigateTo({url:"/pages/chat/index?targetUserId=".concat(e.id,"&title=").concat(encodeURIComponent(e.name))})},R=function(){return u().navigateTo({url:"/pages/contacts/index"})},B=T.trim().toLowerCase(),J=B?k.filter(function(e){return e.title.toLowerCase().includes(B)||(e.preview||"").toLowerCase().includes(B)}):k;return(0,f.jsxs)(d.A,{className:"messages-page",children:[(0,f.jsx)(v.A,{title:"\u6d88\u606f"}),(0,f.jsx)(x.A,{placeholder:"\u641c\u7d22\u804a\u5929\u6216\u901a\u77e5",value:T,onInput:I}),(0,f.jsx)(h.A,{items:b,value:a,onChange:n}),B?null:(0,f.jsx)(w,{users:g,onSelect:D,onDiscover:R}),(0,f.jsx)(m.Ss,{className:"messages-page__divider",children:(0,f.jsx)(m.EY,{children:B?"\u641c\u7d22\u7ed3\u679c":"\u6700\u8fd1\u804a\u5929"})}),(0,f.jsxs)(m.Ss,{className:"messages-page__list",children:[J.map(function(e){return(0,f.jsx)(S,{conversation:e,onClick:function(){return K(e)}},e._id)}),0===J.length?(0,f.jsx)(m.EY,{className:"messages-page__empty",children:B?"\u6ca1\u6709\u5339\u914d\u7684\u804a\u5929":"unread"===a?"\u6ca1\u6709\u672a\u8bfb\u6d88\u606f":"\u8fd8\u6ca1\u6709\u804a\u5929\uff0c\u53bb\u300c\u53d1\u73b0\u300d\u627e\u6c6a\u53cb\u804a\u804a\u5427"}):null]}),(0,f.jsx)(_.A,{active:"messages"})]})}var E={navigationBarTitleText:"\u6d88\u606f",navigationStyle:"custom",disableScroll:!0},k=(0,n.eU)(C,"pages/messages/index",{root:{cn:[]}},E||{});C&&C.behaviors&&(k.behaviors=(k.behaviors||[]).concat(C.behaviors));Page(k)}},function(e){var s=function(s){return e(e.s=s)};e.O(0,[907,96,76],function(){return s(6430)});e.O()}]);
|
||||||
1
dist/pages/messages/index.json
vendored
Normal file
1
dist/pages/messages/index.json
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
{"navigationBarTitleText":"消息","navigationStyle":"custom","disableScroll":true,"usingComponents":{"comp":"../../comp"}}
|
||||||
2
dist/pages/messages/index.wxml
vendored
Normal file
2
dist/pages/messages/index.wxml
vendored
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
<import src="../../base.wxml"/>
|
||||||
|
<template is="taro_tmpl" data="{{root:root}}" />
|
||||||
1
dist/pages/messages/index.wxss
vendored
Normal file
1
dist/pages/messages/index.wxss
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
.active-user-row{-webkit-box-sizing:border-box;box-sizing:border-box;padding:24rpx 0 16rpx;width:100%}.active-user-row__inner{display:-ms-flexbox;display:flex;gap:24rpx;padding:0 40rpx}.active-user-row__item{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-align:center;align-items:center;gap:12rpx}.active-user-row__avatar-wrap{position:relative}.active-user-row__add{border-radius:50%;display:-ms-flexbox;display:flex;height:108rpx;width:108rpx;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;background:rgba(216,180,255,.08);border:2rpx dashed rgba(216,180,255,.35);color:#d8b4ff;justify-content:center}.active-user-row__live{background:-webkit-gradient(linear,left top,right top,from(#d8b4ff),to(#ffb3c8));background:linear-gradient(90deg,#d8b4ff,#ffb3c8);border:3rpx solid #14102b;border-radius:12rpx;bottom:-4rpx;color:#2a1d10;font:700 18rpx/1.2 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;padding:4rpx 12rpx;position:absolute;right:-8rpx}.active-user-row__name{color:#c7b9e0;font:500 22rpx/1.2 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;max-width:120rpx;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.conversation-item{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;gap:24rpx;padding:24rpx 40rpx;-webkit-transition:background .2s;transition:background .2s}.conversation-item:active{background:rgba(216,180,255,.06)}.conversation-item__main{-ms-flex:1;flex:1;min-width:0}.conversation-item__bottom,.conversation-item__name-row,.conversation-item__top{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}.conversation-item__top{-ms-flex-pack:justify;justify-content:space-between}.conversation-item__name-row{gap:8rpx;min-width:0}.conversation-item__name{color:#f0e9ff;font:600 28rpx/1.2 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.conversation-item__pet{color:#d8b4ff;font:500 22rpx/1 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif}.conversation-item__time{color:#8a7aab;font:400 22rpx/1 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif}.conversation-item__bottom{-ms-flex-pack:justify;gap:16rpx;justify-content:space-between;margin-top:12rpx}.conversation-item__preview{color:#c7b9e0;-ms-flex:1;flex:1;font:400 24rpx/1.3 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.conversation-item__badge{background:#ffb3c8;border-radius:18rpx;-webkit-box-sizing:border-box;box-sizing:border-box;color:#2a1d10;font:700 20rpx/36rpx Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;height:36rpx;min-width:36rpx;padding:0 12rpx;text-align:center}.conversation-item__muted{background:#8a7aab;border-radius:50%;height:16rpx;opacity:.4;width:16rpx}.conversation-item__pin{color:#ffd9a8}.messages-page__divider{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;color:#8a7aab;font:500 20rpx/1 Space Grotesk,Inter,system-ui,sans-serif;gap:20rpx;letter-spacing:.18em;padding:24rpx 40rpx 12rpx}.messages-page__divider::after{background:rgba(216,180,255,.08);content:"";-ms-flex:1;flex:1;height:2rpx}.messages-page__list{padding-bottom:24rpx}.messages-page__empty{color:#8a7aab;display:block;font:400 26rpx/1.6 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;padding:80rpx 48rpx;text-align:center}
|
||||||
1
dist/pages/nearby/index.js
vendored
Normal file
1
dist/pages/nearby/index.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1
dist/pages/nearby/index.json
vendored
Normal file
1
dist/pages/nearby/index.json
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
{"navigationBarTitleText":"附近","navigationStyle":"custom","disableScroll":true,"usingComponents":{"comp":"../../comp"}}
|
||||||
2
dist/pages/nearby/index.wxml
vendored
Normal file
2
dist/pages/nearby/index.wxml
vendored
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
<import src="../../base.wxml"/>
|
||||||
|
<template is="taro_tmpl" data="{{root:root}}" />
|
||||||
1
dist/pages/nearby/index.wxss
vendored
Normal file
1
dist/pages/nearby/index.wxss
vendored
Normal file
File diff suppressed because one or more lines are too long
1
dist/pages/pet-edit/index.js
vendored
Normal file
1
dist/pages/pet-edit/index.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1
dist/pages/pet-edit/index.json
vendored
Normal file
1
dist/pages/pet-edit/index.json
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
{"navigationBarTitleText":"编辑毛孩子","navigationStyle":"custom","disableScroll":true,"usingComponents":{"comp":"../../comp"}}
|
||||||
2
dist/pages/pet-edit/index.wxml
vendored
Normal file
2
dist/pages/pet-edit/index.wxml
vendored
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
<import src="../../base.wxml"/>
|
||||||
|
<template is="taro_tmpl" data="{{root:root}}" />
|
||||||
1
dist/pages/pet-edit/index.wxss
vendored
Normal file
1
dist/pages/pet-edit/index.wxss
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
.pet-edit{background:#14102b;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;height:100vh}.pet-edit__nav{-ms-flex-negative:0;background:#14102b;flex-shrink:0}.pet-edit__nav-row{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;height:108rpx;padding:0 32rpx}.pet-edit__close{display:-ms-flexbox;display:flex;height:72rpx;width:72rpx;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;color:#f0e9ff;justify-content:center}.pet-edit__nav-title{color:#f0e9ff;-ms-flex:1;flex:1;font:700 34rpx/1 Space Grotesk,Inter,system-ui,sans-serif;text-align:center}.pet-edit__nav-spacer{width:72rpx}.pet-edit__scroll{-webkit-box-sizing:border-box;box-sizing:border-box;-ms-flex:1;flex:1;min-height:0;padding:16rpx 40rpx 24rpx}.pet-edit__photo-row{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;margin:16rpx 0 48rpx}.pet-edit__photo{border-radius:40rpx;display:-ms-flexbox;display:flex;height:240rpx;overflow:hidden;width:240rpx;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;border:2rpx dashed rgba(216,180,255,.3);justify-content:center}.pet-edit__photo-img{border-radius:40rpx;height:240rpx;width:240rpx}.pet-edit__photo-empty{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-align:center;align-items:center;color:#8a7aab;gap:12rpx}.pet-edit__photo-hint{font:500 24rpx/1 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif}.pet-edit__picker{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:justify;background:rgba(31,23,66,.68);border:2rpx solid rgba(216,180,255,.1);border-radius:24rpx;-webkit-box-sizing:border-box;box-sizing:border-box;height:92rpx;justify-content:space-between;padding:0 28rpx}.pet-edit__picker-value{color:#f0e9ff;font:400 28rpx/1 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif}.pet-edit__picker-ph{color:#8a7aab;font:400 28rpx/1 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif}.pet-edit__picker-arrow{color:#8a7aab;-webkit-transform:rotate(90deg);-ms-transform:rotate(90deg);transform:rotate(90deg)}.pet-edit__field{margin-bottom:36rpx}.pet-edit__label{color:#c7b9e0;display:block;font:600 26rpx/1 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;margin-bottom:16rpx}.pet-edit__input{background:rgba(31,23,66,.68);border:2rpx solid rgba(216,180,255,.1);border-radius:24rpx;-webkit-box-sizing:border-box;box-sizing:border-box;color:#f0e9ff;font:400 28rpx/92rpx Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;height:92rpx;padding:0 28rpx;width:100%}.pet-edit__placeholder{color:#8a7aab}.pet-edit__input--mt{margin-top:20rpx}.pet-edit__tags{display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;gap:16rpx}.pet-edit__tag{background:rgba(45,34,85,.4);border:2rpx solid rgba(216,180,255,.1);border-radius:19998rpx;color:#c7b9e0;font:500 24rpx/1 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;padding:16rpx 24rpx}.pet-edit__tag--active{background:-webkit-gradient(linear,left top,right top,from(rgba(216,180,255,.22)),to(rgba(255,179,200,.22)));background:linear-gradient(90deg,rgba(216,180,255,.22),rgba(255,179,200,.22));border-color:rgba(216,180,255,.4);color:#f0e9ff}.pet-edit__tag--add{border-color:rgba(216,180,255,.4);border-style:dashed;color:#d8b4ff}.pet-edit__delete{background:rgba(255,138,155,.1);border:2rpx solid rgba(255,138,155,.2);border-radius:24rpx;color:#ff8a9b;font:600 28rpx/1 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;margin-top:24rpx;padding:26rpx;text-align:center}.pet-edit__footer{-ms-flex-negative:0;background:#14102b;border-top:2rpx solid rgba(216,180,255,.06);flex-shrink:0;padding:24rpx 40rpx 32rpx}.pet-edit__submit{background:-webkit-gradient(linear,left top,right top,from(#d8b4ff),to(#ffb3c8));background:linear-gradient(90deg,#d8b4ff,#ffb3c8);border-radius:19998rpx;-webkit-box-sizing:border-box;box-sizing:border-box;color:#2a1d10;font:700 30rpx/1 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;padding:30rpx;text-align:center;width:100%}.pet-edit__submit:active{opacity:.9}
|
||||||
1
dist/pages/plaza/index.js
vendored
Normal file
1
dist/pages/plaza/index.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1
dist/pages/plaza/index.json
vendored
Normal file
1
dist/pages/plaza/index.json
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
{"navigationBarTitleText":"广场","navigationStyle":"custom","disableScroll":true,"usingComponents":{"comp":"../../comp"}}
|
||||||
2
dist/pages/plaza/index.wxml
vendored
Normal file
2
dist/pages/plaza/index.wxml
vendored
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
<import src="../../base.wxml"/>
|
||||||
|
<template is="taro_tmpl" data="{{root:root}}" />
|
||||||
1
dist/pages/plaza/index.wxss
vendored
Normal file
1
dist/pages/plaza/index.wxss
vendored
Normal file
File diff suppressed because one or more lines are too long
1
dist/pages/profile-edit/index.js
vendored
Normal file
1
dist/pages/profile-edit/index.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1
dist/pages/profile-edit/index.json
vendored
Normal file
1
dist/pages/profile-edit/index.json
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
{"navigationBarTitleText":"编辑资料","navigationStyle":"custom","disableScroll":true,"usingComponents":{"comp":"../../comp"}}
|
||||||
2
dist/pages/profile-edit/index.wxml
vendored
Normal file
2
dist/pages/profile-edit/index.wxml
vendored
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
<import src="../../base.wxml"/>
|
||||||
|
<template is="taro_tmpl" data="{{root:root}}" />
|
||||||
1
dist/pages/profile-edit/index.wxss
vendored
Normal file
1
dist/pages/profile-edit/index.wxss
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
.profile-edit{background:#14102b;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;height:100vh}.profile-edit__nav{-ms-flex-negative:0;background:#14102b;flex-shrink:0}.profile-edit__nav-row{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;height:108rpx;padding:0 32rpx}.profile-edit__close{display:-ms-flexbox;display:flex;height:72rpx;width:72rpx;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;color:#f0e9ff;justify-content:center}.profile-edit__nav-title{color:#f0e9ff;-ms-flex:1;flex:1;font:700 34rpx/1 Space Grotesk,Inter,system-ui,sans-serif;text-align:center}.profile-edit__nav-spacer{width:72rpx}.profile-edit__scroll{-webkit-box-sizing:border-box;box-sizing:border-box;-ms-flex:1;flex:1;min-height:0;padding:16rpx 40rpx 80rpx}.profile-edit__avatar-row{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-align:center;align-items:center;margin:16rpx 0 48rpx}.profile-edit__avatar-btn{background:transparent;border-radius:50%;height:128rpx;line-height:normal;margin:0;padding:0;position:relative;width:128rpx}.profile-edit__avatar-btn::after{border:none}.profile-edit__avatar-img{border-radius:50%;height:128rpx;width:128rpx}.profile-edit__avatar-edit{background:#d8b4ff;border-radius:50%;bottom:-4rpx;color:#2a1d10;display:-ms-flexbox;display:flex;height:44rpx;position:absolute;right:-4rpx;width:44rpx;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;border:4rpx solid #14102b;justify-content:center}.profile-edit__avatar-hint{color:#8a7aab;font:400 24rpx/1 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;margin-top:20rpx}.profile-edit__field{margin-bottom:36rpx}.profile-edit__label{color:#c7b9e0;display:block;font:600 26rpx/1 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;margin-bottom:16rpx}.profile-edit__input{background:rgba(31,23,66,.68);border:2rpx solid rgba(216,180,255,.1);border-radius:24rpx;-webkit-box-sizing:border-box;box-sizing:border-box;color:#f0e9ff;font:400 28rpx/92rpx Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;height:92rpx;padding:0 28rpx;width:100%}.profile-edit__textarea{background:rgba(31,23,66,.68);border:2rpx solid rgba(216,180,255,.1);border-radius:24rpx;-webkit-box-sizing:border-box;box-sizing:border-box;color:#f0e9ff;font:400 28rpx/1.5 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;height:168rpx;padding:24rpx 28rpx;width:100%}.profile-edit__placeholder{color:#8a7aab}.profile-edit__picker{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:justify;background:rgba(31,23,66,.68);border:2rpx solid rgba(216,180,255,.1);border-radius:24rpx;-webkit-box-sizing:border-box;box-sizing:border-box;height:92rpx;justify-content:space-between;padding:0 28rpx}.profile-edit__picker-value{color:#f0e9ff;font:400 28rpx/1 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif}.profile-edit__picker-ph{color:#8a7aab;font:400 28rpx/1 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif}.profile-edit__picker-arrow{color:#8a7aab;-webkit-transform:rotate(90deg);-ms-transform:rotate(90deg);transform:rotate(90deg)}.profile-edit__footer{-ms-flex-negative:0;background:#14102b;border-top:2rpx solid rgba(216,180,255,.06);flex-shrink:0;padding:24rpx 40rpx 32rpx}.profile-edit__submit{background:-webkit-gradient(linear,left top,right top,from(#d8b4ff),to(#ffb3c8));background:linear-gradient(90deg,#d8b4ff,#ffb3c8);border-radius:19998rpx;-webkit-box-sizing:border-box;box-sizing:border-box;color:#2a1d10;font:700 30rpx/1 Inter,system-ui,-apple-system,PingFang SC,Microsoft YaHei,sans-serif;padding:30rpx;text-align:center;width:100%}.profile-edit__submit:active{opacity:.9}
|
||||||
1
dist/pages/profile/index.js
vendored
Normal file
1
dist/pages/profile/index.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1
dist/pages/profile/index.json
vendored
Normal file
1
dist/pages/profile/index.json
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
{"navigationBarTitleText":"我的","navigationStyle":"custom","disableScroll":true,"usingComponents":{"comp":"../../comp"}}
|
||||||
2
dist/pages/profile/index.wxml
vendored
Normal file
2
dist/pages/profile/index.wxml
vendored
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
<import src="../../base.wxml"/>
|
||||||
|
<template is="taro_tmpl" data="{{root:root}}" />
|
||||||
1
dist/pages/profile/index.wxss
vendored
Normal file
1
dist/pages/profile/index.wxss
vendored
Normal file
File diff suppressed because one or more lines are too long
1
dist/pages/publish/index.js
vendored
Normal file
1
dist/pages/publish/index.js
vendored
Normal file
File diff suppressed because one or more lines are too long
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user