Remove preview

This commit is contained in:
Liam 2022-10-30 14:54:22 +00:00
parent 4af129ea20
commit 99c9f4053d

@ -5,7 +5,6 @@ import {
Grid,
Input,
Link,
Modal,
Radio,
Spacer,
Spinner,
@ -30,8 +29,6 @@ export default class Home extends Component {
this.state = {
loading: true,
steamId: undefined,
isPreviewVisible: false,
previewUrl: undefined,
overlayUrl: undefined,
avatarUrl: undefined,
@ -87,13 +84,6 @@ export default class Home extends Component {
this.setState({ loading: false });
}
loadPreview() {
this.setState({
isPreviewVisible: true,
previewUrl: this.generateUrl(),
});
}
generateUrl() {
let values = "";
Object.entries(this.state.values).forEach((value) => {
@ -161,26 +151,6 @@ export default class Home extends Component {
marginTop: "$8",
}}
>
{/* Preview */}
{this.state.isPreviewVisible ? (
<Modal
closeButton
open={this.state.isPreviewVisible}
width={"100%"}
blur
onClose={() => this.setState({ isPreviewVisible: false })}
>
<Modal.Header>
<Text size={18}>Overlay Preview</Text>
</Modal.Header>
<Modal.Body>
<iframe height={600} src={this.state.previewUrl}></iframe>
</Modal.Body>
</Modal>
) : (
<></>
)}
<Grid.Container gap={2} justify="center">
<Grid
xs={12}
@ -326,19 +296,6 @@ export default class Home extends Component {
>
Open Overlay
</Button>
<Button
flat
auto
onPress={() => {
if (!this.state.steamId) {
toast.error("Please provide a Steam ID");
return;
}
this.loadPreview();
}}
>
Preview
</Button>
</Button.Group>
<Text