mirror of
https://github.com/ragestudio/comty.git
synced 2025-06-10 02:54:15 +00:00
remove splash
This commit is contained in:
parent
516dba1209
commit
2fe9756506
@ -263,26 +263,37 @@ const OpenTagEditor = ({ tag, onFinish = () => app.navigation.softReload() } = {
|
||||
|
||||
const TapShareRender = () => {
|
||||
return <div className="tap-share-render">
|
||||
{
|
||||
!app.cores.nfc.scanning && app.isMobile && <antd.Alert
|
||||
type="warning"
|
||||
message="NFC is disabled"
|
||||
description="You can enable it in your device settings."
|
||||
/>
|
||||
}
|
||||
|
||||
<div className="tap-share-field">
|
||||
<div className="tap-share-field_header">
|
||||
<h1>
|
||||
<Icons.MdSpoke /> Registered Tags
|
||||
</h1>
|
||||
</div>
|
||||
<span className="tip">
|
||||
<Icons.MdInfo /> You can quickly edit your tags by tapping them.
|
||||
</span>
|
||||
|
||||
{
|
||||
app.cores.nfc.scanning && <span className="tip">
|
||||
<Icons.MdInfo /> You can quickly edit your tags by tapping them.
|
||||
</span>
|
||||
}
|
||||
<OwnTags />
|
||||
</div>
|
||||
|
||||
<antd.Button
|
||||
type="primary"
|
||||
icon={<Icons.Plus />}
|
||||
onClick={() => OpenTagEditor()}
|
||||
>
|
||||
Add new
|
||||
</antd.Button>
|
||||
{
|
||||
app.isMobile && <antd.Button
|
||||
type="primary"
|
||||
icon={<Icons.Plus />}
|
||||
onClick={() => OpenTagEditor()}
|
||||
>
|
||||
Add new
|
||||
</antd.Button>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
|
||||
|
@ -22,13 +22,6 @@ export default (props) => {
|
||||
return false
|
||||
}
|
||||
|
||||
const nfcInstance = app.cores.nfc.instance()
|
||||
|
||||
if (!nfcInstance) {
|
||||
setError(NFC_ERRORS.NFC_NOT_AVAILABLE)
|
||||
return false
|
||||
}
|
||||
|
||||
setError(null)
|
||||
setLoading(true)
|
||||
|
||||
@ -40,7 +33,7 @@ export default (props) => {
|
||||
return false
|
||||
}
|
||||
|
||||
nfcInstance.write({
|
||||
app.cores.nfc.writeNdef({
|
||||
records: [{
|
||||
recordType: "url",
|
||||
data: context.values.endpoint_url
|
||||
|
@ -66,7 +66,6 @@ import loadable from "@loadable/component"
|
||||
|
||||
import { StatusBar, Style } from "@capacitor/status-bar"
|
||||
import { App as CapacitorApp } from "@capacitor/app"
|
||||
import { SplashScreen } from "@capacitor/splash-screen"
|
||||
import { CapacitorUpdater } from "@capgo/capacitor-updater"
|
||||
|
||||
import SessionModel from "models/session"
|
||||
@ -98,6 +97,8 @@ import * as Router from "./router"
|
||||
|
||||
import "theme/index.less"
|
||||
|
||||
console.log(`REACT VERSION: ${React.version}`)
|
||||
|
||||
CapacitorUpdater.notifyAppReady()
|
||||
|
||||
class ComtyApp extends React.Component {
|
||||
@ -118,15 +119,10 @@ class ComtyApp extends React.Component {
|
||||
}
|
||||
|
||||
static splashAwaitEvent = "app.initialization.finish"
|
||||
|
||||
static async initialize() {
|
||||
SplashScreen.show({
|
||||
autoHide: false,
|
||||
})
|
||||
|
||||
window.app.splash = SplashScreen
|
||||
window.app.version = config.package.version
|
||||
window.app.message = antd.message
|
||||
window.app.isCapacitor = window.navigator.userAgent === "capacitor"
|
||||
|
||||
window.localStorage.setItem("last_version", window.app.version)
|
||||
|
||||
@ -492,8 +488,6 @@ class ComtyApp extends React.Component {
|
||||
this.setState({ initialized: true })
|
||||
|
||||
Utils.handleOpenDevTools()
|
||||
|
||||
SplashScreen.hide()
|
||||
}
|
||||
|
||||
onRuntimeStateUpdate = (state) => {
|
||||
|
Loading…
x
Reference in New Issue
Block a user