mirror of
https://github.com/italicsjenga/agb.git
synced 2024-12-23 08:11:33 +11:00
Properly fullscreen
This commit is contained in:
parent
683afbf133
commit
91dfb63fbd
|
@ -21,6 +21,11 @@ const ActionButton = styled.button`
|
||||||
margin-top: 20px;
|
margin-top: 20px;
|
||||||
`;
|
`;
|
||||||
|
|
||||||
|
const AppContainer = styled.main`
|
||||||
|
height: calc(100vh - 20px);
|
||||||
|
padding: 10px;
|
||||||
|
`;
|
||||||
|
|
||||||
function App() {
|
function App() {
|
||||||
const [{ volume, bindings }, setState] = useLocalStorage(
|
const [{ volume, bindings }, setState] = useLocalStorage(
|
||||||
{ volume: 1.0, bindings: DefaultBindingsSet() },
|
{ volume: 1.0, bindings: DefaultBindingsSet() },
|
||||||
|
@ -43,7 +48,7 @@ function App() {
|
||||||
});
|
});
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div>
|
<AppContainer>
|
||||||
{showBindings && (
|
{showBindings && (
|
||||||
<BindingsWindow
|
<BindingsWindow
|
||||||
bindings={bindings}
|
bindings={bindings}
|
||||||
|
@ -62,7 +67,7 @@ function App() {
|
||||||
controls={bindings.Actual}
|
controls={bindings.Actual}
|
||||||
paused={paused}
|
paused={paused}
|
||||||
/>
|
/>
|
||||||
</div>
|
</AppContainer>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
8
website/src/globalStyles.ts
Normal file
8
website/src/globalStyles.ts
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
import { createGlobalStyle } from "styled-components";
|
||||||
|
|
||||||
|
export const GlobalStyle = createGlobalStyle`
|
||||||
|
body {
|
||||||
|
margin: 0;
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
|
`;
|
|
@ -1,6 +1,7 @@
|
||||||
import React from "react";
|
import React from "react";
|
||||||
import ReactDOM from "react-dom/client";
|
import ReactDOM from "react-dom/client";
|
||||||
import App from "./App";
|
import App from "./App";
|
||||||
|
import { GlobalStyle } from "./globalStyles";
|
||||||
|
|
||||||
const root = ReactDOM.createRoot(
|
const root = ReactDOM.createRoot(
|
||||||
document.getElementById("root") as HTMLElement
|
document.getElementById("root") as HTMLElement
|
||||||
|
@ -8,6 +9,7 @@ const root = ReactDOM.createRoot(
|
||||||
|
|
||||||
root.render(
|
root.render(
|
||||||
<React.StrictMode>
|
<React.StrictMode>
|
||||||
|
<GlobalStyle />
|
||||||
<App />
|
<App />
|
||||||
</React.StrictMode>
|
</React.StrictMode>
|
||||||
);
|
);
|
||||||
|
|
Loading…
Reference in a new issue