Skip to content

Commit ed91060

Browse files
ci-botyann300
authored andcommitted
clean up
1 parent 4045a7a commit ed91060

File tree

2 files changed

+7
-17
lines changed

2 files changed

+7
-17
lines changed

apps/remix-ide/src/app/components/preload.tsx

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import { RemixApp } from '@remix-ui/app'
22
import axios from 'axios'
33
import React, { useState, useEffect, useRef } from 'react'
4-
import { FormattedMessage, useIntl } from 'react-intl'
54
import { useTracking, TrackingProvider } from '../contexts/TrackingContext'
65
import { TrackingFunction } from '../utils/TrackingFunction'
76
import * as packageJson from '../../../../../package.json'
@@ -28,7 +27,6 @@ export const Preload = (props: PreloadProps) => {
2827
const [showDownloader, setShowDownloader] = useState<boolean>(false)
2928
const containerRef = useRef<HTMLDivElement>(null)
3029
const mainRef = useRef<HTMLDivElement>(null)
31-
const tipsRef = useRef<HTMLDivElement>(null)
3230
const remixFileSystems = useRef<fileSystems>(new fileSystems())
3331
const remixIndexedDB = useRef<fileSystem>(new indexedDBFileSystem())
3432
const localStorageFileSystem = useRef<fileSystem>(new localStorageFS())
@@ -113,7 +111,7 @@ export const Preload = (props: PreloadProps) => {
113111
}
114112
async function loadStorage() {
115113
; (await remixFileSystems.current.addFileSystem(remixIndexedDB.current)) || trackMatomoEvent?.({ category: 'Storage', action: 'error', name: 'indexedDB not supported', isClick: false })
116-
; (await remixFileSystems.current.addFileSystem(localStorageFileSystem.current)) || trackMatomoEvent?.({ category: 'Storage', action: 'error', name: 'localstorage not supported', isClick: false })
114+
; (await remixFileSystems.current.addFileSystem(localStorageFileSystem.current)) || trackMatomoEvent?.({ category: 'Storage', action: 'error', name: 'localstorage not supported', isClick: false })
117115
await testmigration()
118116
remixIndexedDB.current.loaded && (await remixIndexedDB.current.checkWorkspaces())
119117
localStorageFileSystem.current.loaded && (await localStorageFileSystem.current.checkWorkspaces())
@@ -137,7 +135,6 @@ export const Preload = (props: PreloadProps) => {
137135
console.log(e)
138136
}
139137

140-
141138
return () => {
142139
abortController.abort();
143140
};
@@ -206,10 +203,10 @@ export const Preload = (props: PreloadProps) => {
206203
) : null}
207204
</div>
208205
<div className="preload-bottom opt-out">
209-
{ tip && <div className='remix_tips text-center mt-3'>
210-
<div><b>DID YOU KNOW</b></div>
211-
<span>{tip}</span>
212-
</div> }
206+
{ tip && <div className='remix_tips text-center mt-3'>
207+
<div><b>DID YOU KNOW</b></div>
208+
<span>{tip}</span>
209+
</div> }
213210
</div>
214211
</div>
215212
</>

apps/remix-ide/src/app/components/styles/preload.css

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
align-items: center; /* centers .preload-main horizontally */
77
height: 100vh;
88
}
9+
910
/* Center the main content while allowing a footer-like tips area below */
1011
.preload-main {
1112
display: flex;
@@ -16,14 +17,6 @@
1617
position: relative;
1718
}
1819

19-
.preload-tips {
20-
position: absolute; /* top is set dynamically to sit below the main block */
21-
left: 0;
22-
right: 0;
23-
width: 100%;
24-
padding: 0 16px;
25-
}
26-
2720
.preload-info-container {
2821
display: flex;
2922
flex-direction: column;
@@ -74,6 +67,7 @@
7467
max-width: 800px;
7568
margin: 0 auto;
7669
}
70+
7771
.remix_tips span {
7872
display: -webkit-box;
7973
line-clamp: 2;
@@ -82,7 +76,6 @@
8276
overflow: hidden;
8377
}
8478

85-
8679
.preload-bottom.opt-out {
8780
position: absolute;
8881
top: 50%;

0 commit comments

Comments
 (0)