Skip to content

Commit

Permalink
根据模块类型, 对页面进行了分组
Browse files Browse the repository at this point in the history
  • Loading branch information
czy0729 committed Sep 5, 2019
1 parent 0f1639e commit db5fc63
Show file tree
Hide file tree
Showing 137 changed files with 209 additions and 687 deletions.
8 changes: 7 additions & 1 deletion constants/api.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* @Author: czy0729
* @Date: 2019-02-21 21:30:44
* @Last Modified by: czy0729
* @Last Modified time: 2019-09-03 22:15:34
* @Last Modified time: 2019-09-04 21:35:13
*/
import { HOST_NAME } from './index'

Expand Down Expand Up @@ -212,3 +212,9 @@ export const API_TINYGRAIL_CHARA = (monoId = 0) =>
*/
export const API_TINYGRAIL_DEPTH = monoId =>
`${API_HOST_TINYGRAIL}/api/chara/depth/${monoId}`

/**
* 资产信息
*/
export const API_TINYGRAIL_ASSETS = () =>
`${API_HOST_TINYGRAIL}/api/chara/user/assets`
52 changes: 27 additions & 25 deletions constants/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,49 +3,50 @@
* @Author: czy0729
* @Date: 2019-02-22 01:25:31
* @Last Modified by: czy0729
* @Last Modified time: 2019-09-03 22:26:09
* @Last Modified time: 2019-09-04 22:15:27
*/
import { Platform } from 'react-native'
import Constants from 'expo-constants'

export const IOS = Platform.OS === 'ios'
export const MI = Constants.deviceName.includes('MI') // 小米MIUI
export const IOS = Platform.OS === 'ios' // 是否iOS
export const MI = Constants.deviceName.includes('MI') // 是否MIUI (假如不是小米手机刷了MIUI会检测不到)

// APP
export const APP_ID = 'bgm8885c4d524cd61fc'
export const APP_SECRET = '1da52e7834bbb73cca90302f9ddbc8dd'
export const APP_ID = 'bgm8885c4d524cd61fc' // client_id
export const APP_SECRET = '1da52e7834bbb73cca90302f9ddbc8dd' // client_secret

// TINYGRAIL
export const TINYGRAIL_APP_ID = 'bgm2525b0e4c7d93fec' // 小圣杯 client_id
export const TINYGRAIL_OAUTH_REDIRECT_URL = 'https://www.tinygrail.com/cb' // 小圣杯 授权跳转地址

// URL
export const HOST_NAME = 'bgm.tv'
export const HOST_NAME = 'bgm.tv' // 域名
export const HOST = `https://${HOST_NAME}`
export const HOST_2 = 'https://bangumi.tv'
export const HOST_MIRRO = 'https://mirror.bgm.rin.cat'
export const OAUTH_URL = `${HOST}/oauth/authorize`
export const OAUTH_REDIRECT_URL = `${HOST}/dev/app`
export const NING_MOE_HOST = 'https://www.ningmoe.com'
export const ANITAMA_HOST = 'https://app.anitama.net/'
export const HOST_2 = 'https://bangumi.tv' // 备用域名
export const OAUTH_URL = `${HOST}/oauth/authorize` // 登陆v1.0 oauth地址
export const OAUTH_REDIRECT_URL = `${HOST}/dev/app` // 登陆v1.0 授权跳转地址
export const NING_MOE_HOST = 'https://www.ningmoe.com' // 柠萌瞬间地址
export const ANITAMA_HOST = 'https://app.anitama.net/' // Anitama api地址

// GITHUB
export const FEEDBACK_URL = `${HOST}/group/topic/350677`
export const GITHUB_URL = 'https://github.com/czy0729/Bangumi'
export const GITHUB_RELEASE_URL = `${GITHUB_URL}/releases`
export const FEEDBACK_URL = `${HOST}/group/topic/350677` // 反馈地址
export const GITHUB_URL = 'https://github.com/czy0729/Bangumi' // github地址
export const GITHUB_RELEASE_URL = `${GITHUB_URL}/releases` // 版本析出地址
export const GITHUB_RELEASE_REPOS_URL =
'https://api.github.com/repos/czy0729/Bangumi/releases'
export const GITHUB_RELEASE_VERSION = '0.14.0'
export const CODE_PUSH_VERSION = ''
export const DEV = false
'https://api.github.com/repos/czy0729/Bangumi/releases' // 版本析出api地址
export const GITHUB_RELEASE_VERSION = '0.14.0' // 版本号
export const CODE_PUSH_VERSION = '' // 热推送副版本号
export const DEV = true // 是否开发模式

// 图片
export const IMG_DEFAULT_AVATAR = '//lain.bgm.tv/pic/user/s/icon.jpg'

// 白
export const IMG_DEFAULT_AVATAR = '//lain.bgm.tv/pic/user/s/icon.jpg' // 空头像
export const IMG_EMPTY = {
uri:
'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVQImWP4////GQAJyAPKSOz6nwAAAABJRU5ErkJggg=='
}
} // 白底1*1图片

export const IMG_DEFAULT = require('@assets/images/default.png')
export const IMG_ERROR = require('@assets/images/icon/pic-error-defult.png')
export const IMG_DEFAULT = require('@assets/images/default.png') // 默认图
export const IMG_ERROR = require('@assets/images/icon/pic-error-defult.png') // 图裂图

// 全局统一列表数据结构
export const LIST_EMPTY = {
Expand All @@ -63,6 +64,7 @@ export const LIST_LIMIT = 40 // 用于制造分页数据
export const LIST_COMMENTS_LIMIT = 25
export const TOPIC_PUSH_LIMIT = 300 // 对评论大于300的帖子进行网页跳转

// 时间数组
export const airtimeData = [
'全部',
'2020',
Expand Down
2 changes: 1 addition & 1 deletion navigations.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* @Author: czy0729
* @Date: 2019-06-02 14:42:28
* @Last Modified by: czy0729
* @Last Modified time: 2019-09-03 22:12:35
* @Last Modified time: 2019-09-04 22:27:16
*/
export default {
initialRouteName: 'HomeTab', // HomeTab TinygrailOverview TinygrailTrade
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
4 changes: 2 additions & 2 deletions screens/home/index.js → screens/home/index/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* @Author: czy0729
* @Date: 2019-03-13 08:34:37
* @Last Modified by: czy0729
* @Last Modified time: 2019-08-31 14:59:55
* @Last Modified time: 2019-09-04 22:27:09
*/
import React from 'react'
import { NavigationEvents, SafeAreaView } from 'react-navigation'
Expand Down Expand Up @@ -36,7 +36,7 @@ class Home extends React.Component {
<IconTabsHeader
name='trophy-full'
color={_.colorYellow}
onPress={() => navigation.push('TinygrailOverview')}
onPress={() => navigation.push('Tinygrail')}
/>
<IconTabsHeader
name='search'
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
70 changes: 42 additions & 28 deletions screens/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,38 +2,52 @@
* @Author: czy0729
* @Date: 2019-04-05 21:04:57
* @Last Modified by: czy0729
* @Last Modified time: 2019-09-03 22:02:00
* @Last Modified time: 2019-09-05 10:29:48
*/
export { default as Anitama } from './anitama'
export { default as Auth } from './auth'
export { default as Award } from './award'
export { default as Calendar } from './calendar'
export { default as Discovery } from './discovery'
export { default as Friends } from './friends'
export { default as Group } from './group'
export { default as Home } from './home'
export { default as Login } from './login'
export { default as LoginAssist } from './login-assist'
export { default as LoginV2 } from './login-v2'
export { default as Mono } from './mono'
export { default as Notify } from './notify'
export { default as Rakuen } from './rakuen'
export { default as RakuenSetting } from './rakuen-setting'
export { default as Random } from './random'
export { default as Rank } from './rank'
export { default as Search } from './search'
export { default as Setting } from './setting'
export { default as Subject } from './subject'
export { default as Tag } from './tag'
// Login
export { default as Auth } from './login/auth'
export { default as Login } from './login/index'
export { default as LoginAssist } from './login/assist'
export { default as LoginV2 } from './login/v2'

// Discovery
export { default as Anitama } from './discovery/anitama'
export { default as Award } from './discovery/award'
export { default as Calendar } from './discovery/calendar'
export { default as Discovery } from './discovery/index'
export { default as Random } from './discovery/random'
export { default as Rank } from './discovery/rank'
export { default as Search } from './discovery/search'

// Timeline
export { default as Timeline } from './timeline'
export { default as Topic } from './topic'
export { default as UGCAgree } from './ugc-agree'
export { default as User } from './user'
export { default as Video } from './video'
export { default as WebView } from './web-view'
export { default as Zone } from './zone'

// Home
export { default as Home } from './home/index'
export { default as Mono } from './home/mono'
export { default as Subject } from './home/subject'
export { default as Tag } from './home/tag'
export { default as Video } from './home/video'

// Rakuen
export { default as Group } from './rakuen/group'
export { default as Notify } from './rakuen/notify'
export { default as Rakuen } from './rakuen/index'
export { default as RakuenSetting } from './rakuen/setting'
export { default as Topic } from './rakuen/topic'
export { default as UGCAgree } from './rakuen/ugc-agree'

// User
export { default as Friends } from './user/friends'
export { default as Setting } from './user/setting'
export { default as User } from './user/index'
export { default as Zone } from './user/zone'

// Tinygrail
export { default as Tinygrail } from './tinygrail/index'
export { default as TinygrailOverview } from './tinygrail/overview'
export { default as TinygrailSearch } from './tinygrail/search'
export { default as TinygrailTrade } from './tinygrail/trade'

// Other
export { default as WebView } from './web-view'
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
* @Author: czy0729
* @Date: 2019-07-14 14:28:47
* @Last Modified by: czy0729
* @Last Modified time: 2019-08-25 18:08:38
* @Last Modified time: 2019-09-05 10:21:18
*/
import React from 'react'
import { StyleSheet, View } from 'react-native'
import { Touchable, Flex, Text, Iconfont } from '@components'
import { observer } from '@utils/decorators'
import _ from '@styles'

const History = ({ style, data, onDelete }) => {
function History({ style, data, onDelete }) {
if (!data.length) {
return (
<View style={[styles.container, style]}>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* @Author: czy0729
* @Date: 2019-07-14 14:12:35
* @Last Modified by: czy0729
* @Last Modified time: 2019-08-26 11:10:44
* @Last Modified time: 2019-09-05 10:20:37
*/
import React from 'react'
import { ScrollView } from 'react-native'
Expand All @@ -20,7 +20,7 @@ const title = '超展开设置'
export default
@withHeader()
@observer
class Setting extends React.Component {
class RakuenSetting extends React.Component {
static navigationOptions = {
title
}
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
27 changes: 27 additions & 0 deletions screens/tinygrail/index/auth.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
/*
* @Author: czy0729
* @Date: 2019-09-04 21:58:42
* @Last Modified by: czy0729
* @Last Modified time: 2019-09-04 22:02:39
*/
import React from 'react'
import PropTypes from 'prop-types'
import { Flex, Text, Button } from '@components'
import { observer } from '@utils/decorators'
import _ from '@styles'

function Auth(props, { $ }) {
return (
<Flex style={_.container.wind}>
<Button type='main' onPress={$.doAuth}>
点击授权
</Button>
</Flex>
)
}

Auth.contextTypes = {
$: PropTypes.object
}

export default observer(Auth)
113 changes: 0 additions & 113 deletions screens/tinygrail/index/award.js

This file was deleted.

Loading

0 comments on commit db5fc63

Please sign in to comment.