Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
GeekLearnMathWeapp
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
frontend
GeekLearnMathWeapp
Commits
ea53d2ed
Commit
ea53d2ed
authored
Apr 06, 2023
by
m
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: update
parent
a6f9870c
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
39 additions
and
32 deletions
+39
-32
members.module.scss
src/pages/group/components/members.module.scss
+6
-2
members.tsx
src/pages/group/components/members.tsx
+2
-2
top-header.module.scss
src/pages/group/components/top-header.module.scss
+13
-17
top-header.tsx
src/pages/group/components/top-header.tsx
+13
-6
index.tsx
src/pages/group/index.tsx
+1
-1
use-show-share-modal.ts
src/pages/main/use-show-share-modal.ts
+1
-1
top-bar.tsx
src/pages/prepare/components/top-bar.tsx
+2
-2
index.tsx
src/pages/prepare/index.tsx
+1
-1
No files found.
src/pages/group/components/members.module.scss
View file @
ea53d2ed
@import
'@/styles/mixins.scss'
;
.members
{
@include
flexLayout
(
column
);
padding
:
0
32px
;
.thead
{
padding
:
0
32px
;
position
:
relative
;
top
:
-60px
;
display
:
flex
;
...
...
@@ -36,9 +36,13 @@
.item
{
display
:
flex
;
padding
:
28px
0
26px
;
padding
:
28px
32px
26px
;
align-items
:
center
;
&
.active
{
background-color
:
#E4F1FF
;
}
&
_rank
{
&
_icon
{
width
:
60px
;
...
...
src/pages/group/components/members.tsx
View file @
ea53d2ed
import
{
View
,
Image
,
Text
}
from
'@tarojs/components'
import
classNames
from
'classnames'
import
{
type
MemberItem
}
from
'@/api/group'
import
{
useStoreState
}
from
'@/store/hooks'
...
...
@@ -14,7 +14,7 @@ const Members = () => {
const
renderItem
=
(
item
:
MemberItem
,
index
:
number
)
=>
{
const
isCurrent
=
userInfo
.
userId
===
item
.
memberId
return
(
<
View
key=
{
item
.
memberId
}
className=
{
styles
.
item
}
>
<
View
key=
{
item
.
memberId
}
className=
{
classNames
(
styles
.
item
,
{
[
styles
.
active
]:
isCurrent
})
}
>
<
View
className=
{
styles
.
item_rank
}
>
{
[
1
,
2
,
3
].
includes
(
index
+
1
)
?
<
Image
className=
{
styles
.
item_rank_icon
}
src=
{
assets
[
`rank-${index + 1}.png`
].
u
}
/>
...
...
src/pages/group/components/top-header.module.scss
View file @
ea53d2ed
@import
'@/styles/mixins.scss'
;
.header
{
background-color
:
#2B3347
;
color
:
#fff
;
...
...
@@ -22,32 +20,30 @@
font-weight
:
500
;
color
:
#FFFFFF
;
line-height
:
19
PX
;
gap
:
26
PX
;
}
.nickname
{
width
:
84
PX
;
.avatar
{
flex
:
1
;
min-width
:
0
;
.name
{
overflow
:
hidden
;
text-overflow
:
ellipsis
;
white-space
:
nowrap
;
font-size
:
14
PX
;
font-weight
:
500
;
margin-left
:
16
PX
;
@include
ellipsis
();
color
:
#FFFFFF
;
}
}
.score
{
display
:
flex
;
align-items
:
center
;
flex
:
1
;
.icon
{
width
:
32
PX
;
height
:
32
PX
;
margin-right
:
6
PX
;
}
}
.ph
{
display
:
flex
;
align-items
:
center
;
.icon
{
width
:
32
PX
;
height
:
32
PX
;
margin-right
:
6
PX
;
margin-right
:
4
PX
;
}
}
src/pages/group/components/top-header.tsx
View file @
ea53d2ed
import
{
View
,
Text
,
Image
}
from
'@tarojs/components'
import
{
getMenuButtonBoundingClientRect
,
getSystemInfoSync
}
from
'@tarojs/taro'
import
{
getMenuButtonBoundingClientRect
,
getSystemInfoSync
,
navigateTo
}
from
'@tarojs/taro'
import
{
useMemo
,
useState
}
from
'react'
import
{
useStoreState
}
from
'@/store/hooks'
import
styles
from
'./top-header.module.scss'
const
goStore
=
()
=>
{
navigateTo
({
url
:
'/pages/market/index'
})
}
const
TopHeader
=
()
=>
{
const
[
nav
]
=
useState
(
getMenuButtonBoundingClientRect
())
const
[
sys
]
=
useState
(
getSystemInfoSync
())
...
...
@@ -17,6 +23,7 @@ const TopHeader = () => {
const
cardNum
=
useStoreState
(
state
=>
state
.
userModel
.
cardNum
)
const
point
=
useStoreState
(
state
=>
state
.
userModel
.
point
)
const
userInfo
=
useStoreState
(
state
=>
state
.
userModel
.
userInfo
)
return
(
<
View
className=
{
styles
.
header
}
>
...
...
@@ -28,14 +35,14 @@ const TopHeader = () => {
}
}
>
<
View
className=
{
styles
.
inner
}
style=
{
innerStyle
}
>
<
Text
className=
{
styles
.
nickname
}
>
昵称昵称昵昵称昵称昵昵称昵称
</
Text
>
<
View
className=
{
styles
.
score
}
>
<
View
className=
{
styles
.
avatar
}
>
<
Text
className=
{
styles
.
name
}
>
{
userInfo
?.
nickName
??
''
}
</
Text
>
</
View
>
<
View
className=
{
styles
.
score
}
onClick=
{
goStore
}
>
<
Image
src=
{
require
(
'@/pages/main/assets/score.png'
)
}
className=
{
styles
.
icon
}
/>
<
Text
>
{
point
}
</
Text
>
</
View
>
<
View
className=
{
styles
.
ph
}
>
<
View
className=
{
styles
.
score
}
onClick=
{
goStore
}
>
<
Image
src=
{
require
(
'@/pages/main/assets/ph.png'
)
}
className=
{
styles
.
icon
}
/>
<
Text
>
{
cardNum
}
</
Text
>
</
View
>
...
...
src/pages/group/index.tsx
View file @
ea53d2ed
...
...
@@ -70,7 +70,7 @@ const Group = () => {
toggle()
await Promise.all([fetchTribeInfo(), queryTribePoint()])
} finally {
setTimeout(() => toggle(),
6
00)
setTimeout(() => toggle(),
3
00)
}
}
...
...
src/pages/main/use-show-share-modal.ts
View file @
ea53d2ed
...
...
@@ -26,7 +26,7 @@ export default function useShowShareModal () {
const
{
run
}
=
useRequest
(
joinTribe
,
{
immediate
:
false
,
onSuccess
:
()
=>
{
showToast
({
title
:
'加入成功'
,
icon
:
'none'
})
showToast
({
title
:
'加入成功'
})
fetchTribeInfo
()
}
})
...
...
src/pages/prepare/components/top-bar.tsx
View file @
ea53d2ed
...
...
@@ -5,8 +5,8 @@ import { getMenuButtonBoundingClientRect, navigateBack, getSystemInfoSync } from
import
styles
from
'./top-bar.module.scss'
export
default
()
=>
{
const
nav
=
getMenuButtonBoundingClientRect
(
)
const
sys
=
getSystemInfoSync
(
)
const
nav
=
useMemo
(
getMenuButtonBoundingClientRect
,
[]
)
const
sys
=
useMemo
(
getSystemInfoSync
,
[]
)
const
topBarStyle
=
useMemo
(()
=>
{
return
{
...
...
src/pages/prepare/index.tsx
View file @
ea53d2ed
...
...
@@ -21,7 +21,7 @@ import { renderList, renderTribePage } from './render'
import
styles
from
'./index.module.scss'
const
Prepare
=
()
=>
{
const
nav
=
getMenuButtonBoundingClientRect
(
)
const
nav
=
useMemo
(
getMenuButtonBoundingClientRect
,
[]
)
const
router
=
useRouter
<
{
id
:
string
}
>
()
const
[
currentTab
,
setCurrentTab
]
=
useState
(
0
)
const
[
isVisible
,
{
setTrue
,
setFalse
}]
=
useBoolean
(
false
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment