Merge remote-tracking branch 'origin/master'

# Conflicts:
#	src/app.tsx
#	src/pages/my/my.tsx
v2
king 1 year ago
commit be402c557b
  1. 3
      src/app.tsx
  2. 2
      src/components/loginView/index.module.scss
  3. 5
      src/components/loginView/index.tsx
  4. 4
      src/pages/index/index.config.ts
  5. 12
      src/pages/index/index.tsx
  6. 16
      src/pages/my/my.tsx

@ -50,7 +50,8 @@ function App(props) {
windowHeight, windowHeight,
safeArea, safeArea,
isIos, isIos,
textBarHeight textBarHeight,
menu: Taro.getMenuButtonBoundingClientRect(),
} }
} }
}) })

@ -23,7 +23,7 @@
margin-bottom: 40rpx; margin-bottom: 40rpx;
} }
.button{ .button{
width: 70%; width: 520rpx;
height: 76rpx; height: 76rpx;
background: #45D4A8; background: #45D4A8;
border-radius: 38rpx 38rpx 38rpx 38rpx; border-radius: 38rpx 38rpx 38rpx 38rpx;

@ -12,9 +12,10 @@ interface Props {
const LoginView: FC<Props> = (props) => { const LoginView: FC<Props> = (props) => {
const {empty} = Profile.useContainer() const {empty} = Profile.useContainer()
const text = props.tips ?? '登录后可查看更多内容' const text = props.tips ?? '登录后可查看更多内容'
const size: string = props.height? `${props.height}px`:'750rpx' const size: string = props.height? `${props.height}px`:'0rpx'
const sizeStyle: CSSProperties = { const sizeStyle: CSSProperties = {
height:size, height:'1000rpx',
paddingTop:size,
} }

@ -1,5 +1,3 @@
export default definePageConfig({ export default definePageConfig({
navigationBarTitleText: '学习课程', navigationStyle: 'custom'
navigationBarBackgroundColor: '#92ecc5',
navigationBarTextStyle: 'white',
}) })

@ -1,5 +1,5 @@
import {FC, useState} from "react"; import {FC, useState} from "react";
import {View} from "@tarojs/components"; import {View, Text} from "@tarojs/components";
import styles from './index.module.scss' import styles from './index.module.scss'
import {VideoList} from "@/pages/index/components/videoList"; import {VideoList} from "@/pages/index/components/videoList";
import Tabs, {OnChangOpt, TabList} from "@/components/tabs/tabs"; import Tabs, {OnChangOpt, TabList} from "@/components/tabs/tabs";
@ -25,19 +25,19 @@ const Index: FC = () => {
return ( return (
<> <View className={styles.content} style={`paddingTop:${globalData.statusBarHeight}px`}>
<View className={styles.content}>
{ !token ? { !token ?
<LoginView height={globalData.windowHeight-100}></LoginView> <LoginView></LoginView>
: :
<> <>
<View className="flex justify-center align-center" style={{height:`${(globalData.menu.top-globalData.statusBarHeight)*2+globalData.menu.height}px`}}>
<Text className="font-28 text-white"></Text>
</View>
<Tabs tabList={category} onChange={tabChange} current={categoryKey}/> <Tabs tabList={category} onChange={tabChange} current={categoryKey}/>
<VideoList categoryKey={categoryKey} setCategoryKey={(categoryKey) => setCategoryKey(categoryKey)}/> <VideoList categoryKey={categoryKey} setCategoryKey={(categoryKey) => setCategoryKey(categoryKey)}/>
</> </>
} }
</View> </View>
</>
) )
} }

@ -27,13 +27,15 @@ const My: FC = () => {
return ( return (
<View className={styles.content} style={`paddingTop:${globalData.statusBarHeight}px`}> <View className={styles.content} style={`paddingTop:${globalData.statusBarHeight}px`}>
{ { !token ?
!token ? <LoginView height={globalData.windowHeight - 100}></LoginView> <LoginView></LoginView>
: <> :
<Header showCompany={() => setCompanyShow(true)}/> <>
<Time/> <Header showCompany={()=>{setCompanyShow(true)}}/>
<Service/> <Time/>
</> <Service/>
</>
} }
<PageContainer overlayStyle={'background:rgba(0,0,0,0.3)'} position={'bottom'} round={true} show={companyShow} <PageContainer overlayStyle={'background:rgba(0,0,0,0.3)'} position={'bottom'} round={true} show={companyShow}

Loading…
Cancel
Save