mirror of
https://github.com/italicsjenga/agb.git
synced 2024-12-23 08:11:33 +11:00
Prettier
This commit is contained in:
parent
7bbb52c449
commit
141a77af80
|
@ -1,9 +1,9 @@
|
|||
"use client";
|
||||
|
||||
import { useState } from 'react';
|
||||
import { useState } from "react";
|
||||
|
||||
import { ContentBlock } from "../contentBlock";
|
||||
import { GameDeveloperSummary } from './gameDeveloperSummary';
|
||||
import { GameDeveloperSummary } from "./gameDeveloperSummary";
|
||||
import { styled } from "styled-components";
|
||||
import { Debug } from "./debug";
|
||||
|
||||
|
@ -38,10 +38,21 @@ export function BacktracePage() {
|
|||
);
|
||||
}
|
||||
|
||||
function BacktraceCopyDisplay({ backtrace, setBacktrace }: { backtrace: string , setBacktrace: (newValue: string) => void}) {
|
||||
function BacktraceCopyDisplay({
|
||||
backtrace,
|
||||
setBacktrace,
|
||||
}: {
|
||||
backtrace: string;
|
||||
setBacktrace: (newValue: string) => void;
|
||||
}) {
|
||||
return (
|
||||
<BacktraceWrapper>
|
||||
<BacktraceInputBox type="text" defaultValue="Enter the backtrace code here" onChange={e => setBacktrace(e.target.value)} value={backtrace} />
|
||||
<BacktraceInputBox
|
||||
type="text"
|
||||
defaultValue="Enter the backtrace code here"
|
||||
onChange={(e) => setBacktrace(e.target.value)}
|
||||
value={backtrace}
|
||||
/>
|
||||
<BacktraceCopyButton
|
||||
onClick={() => {
|
||||
navigator.clipboard.writeText(backtrace);
|
||||
|
@ -55,7 +66,8 @@ function BacktraceCopyDisplay({ backtrace, setBacktrace }: { backtrace: string ,
|
|||
|
||||
const BacktraceInputBox = styled.input`
|
||||
font-size: larger;
|
||||
background-color: #dddddd;
|
||||
background-color: #eee;
|
||||
|
||||
flex-grow: 999;
|
||||
`;
|
||||
|
||||
|
@ -71,7 +83,6 @@ const BacktraceCopyButton = styled.button`
|
|||
padding: 10px;
|
||||
`;
|
||||
|
||||
|
||||
function getBacktrace() {
|
||||
return window.location.hash.slice(1);
|
||||
}
|
||||
|
|
|
@ -1,7 +1,8 @@
|
|||
import { styled } from "styled-components";
|
||||
|
||||
export const GameDeveloperSummary = () => {
|
||||
return <Details>
|
||||
return (
|
||||
<Details>
|
||||
<Summary>For game developers</Summary>
|
||||
<p>If you don't want players to be sent to this page, you can:</p>
|
||||
<ol>
|
||||
|
@ -10,7 +11,8 @@ export const GameDeveloperSummary = () => {
|
|||
<li>Not use the backtrace feature</li>
|
||||
</ol>
|
||||
</Details>
|
||||
}
|
||||
);
|
||||
};
|
||||
|
||||
const Details = styled.details`
|
||||
margin-top: 10px;
|
||||
|
|
Loading…
Reference in a new issue