Compare commits
6 Commits
72d8b4e6be
...
28ae7dd791
Author | SHA1 | Date |
---|---|---|
name | 28ae7dd791 | |
name | 3b0c9bf5aa | |
name | 625770866d | |
name | b6fa0257c8 | |
name | d46d9147d8 | |
name | b58a94eff5 |
|
@ -88,9 +88,7 @@ To self-host a mirror site of Wolfree instances using Docker Engine, follow thes
|
||||||
[SUCCESS] Serving "build" directory at: http://localhost:80/
|
[SUCCESS] Serving "build" directory at: http://localhost:80/
|
||||||
```
|
```
|
||||||
|
|
||||||
9. Access the mirror site locally on the same computer where the Docker container runs. Open a web browser and navigate to [http://localhost/](http://localhost/).
|
9. Access the mirror site locally on the same computer where the Docker container runs. Open a web browser and navigate to [http://localhost/](http://localhost/). On the home page of the mirror site, enter a math problem in the text box and click the submit button.
|
||||||
|
|
||||||
10. On the home page of the mirror site, enter a math problem in the text box and click the submit button.
|
|
||||||
|
|
||||||
Congratulations! You have successfully self-hosted Wolfree.
|
Congratulations! You have successfully self-hosted Wolfree.
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
/* SPDX-License-Identifier: AGPL-3.0-or-later */
|
/* SPDX-License-Identifier: AGPL-3.0-or-later */
|
||||||
|
|
||||||
.markdown {
|
.markdown {
|
||||||
--ifm-h2-vertical-rhythm-top: 4;
|
--ifm-h2-vertical-rhythm-top: 3;
|
||||||
}
|
}
|
||||||
|
|
||||||
:root {
|
:root {
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
/* SPDX-License-Identifier: AGPL-3.0-or-later */
|
/* SPDX-License-Identifier: AGPL-3.0-or-later */
|
||||||
|
|
||||||
import React from "react";
|
import React from "react";
|
||||||
|
import typescriptNever from "./typescriptNever";
|
||||||
|
|
||||||
export default (event: React.FormEvent<HTMLFormElement>): void => {
|
export default (event: React.FormEvent<HTMLFormElement>): void => {
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
|
@ -15,8 +16,7 @@ export default (event: React.FormEvent<HTMLFormElement>): void => {
|
||||||
} else if (i instanceof File) {
|
} else if (i instanceof File) {
|
||||||
console.warn({ i });
|
console.warn({ i });
|
||||||
} else {
|
} else {
|
||||||
const typescriptExhaustivenessCheck: never = i;
|
typescriptNever(i);
|
||||||
console.warn({ typescriptExhaustivenessCheck });
|
|
||||||
}
|
}
|
||||||
|
|
||||||
window.location.assign(url);
|
window.location.assign(url);
|
||||||
|
|
|
@ -1,37 +0,0 @@
|
||||||
/* SPDX-License-Identifier: AGPL-3.0-or-later */
|
|
||||||
|
|
||||||
import React from "react";
|
|
||||||
|
|
||||||
export default (): React.JSX.Element => {
|
|
||||||
const [insertIframe, setInsertIframe] = React.useState(false);
|
|
||||||
|
|
||||||
React.useEffect((): (() => void) => {
|
|
||||||
const handleIframeLoad = (): (() => void) => {
|
|
||||||
// Insert the iframe after a 3000ms delay.
|
|
||||||
const timerId = setTimeout((): void => setInsertIframe(true), 3000);
|
|
||||||
|
|
||||||
// Cleanup the timer when the component unmounts.
|
|
||||||
return (): void => clearTimeout(timerId);
|
|
||||||
};
|
|
||||||
|
|
||||||
window.addEventListener("load", handleIframeLoad);
|
|
||||||
|
|
||||||
window.scroll(0, 0);
|
|
||||||
|
|
||||||
// Cleanup the event listener when the component unmounts.
|
|
||||||
return (): void => window.removeEventListener("load", handleIframeLoad);
|
|
||||||
}, []); // Empty dependency array means the effect runs only once after initial render.
|
|
||||||
|
|
||||||
return (
|
|
||||||
<>
|
|
||||||
{/* Use a descriptive title for accessibility */}
|
|
||||||
{insertIframe && (
|
|
||||||
<iframe
|
|
||||||
title="Input Page Preloader"
|
|
||||||
src="/input/"
|
|
||||||
style={{ display: "none" }}
|
|
||||||
/>
|
|
||||||
)}
|
|
||||||
</>
|
|
||||||
);
|
|
||||||
};
|
|
|
@ -1,14 +0,0 @@
|
||||||
/* SPDX-License-Identifier: AGPL-3.0-or-later */
|
|
||||||
|
|
||||||
import Footer from "@theme-original/Footer";
|
|
||||||
import InputPreloader from "./InputPreloader";
|
|
||||||
import React from "react";
|
|
||||||
|
|
||||||
export default (
|
|
||||||
props: React.JSX.ElementAttributesProperty
|
|
||||||
): React.JSX.Element => (
|
|
||||||
<>
|
|
||||||
<Footer {...props} />
|
|
||||||
<InputPreloader />
|
|
||||||
</>
|
|
||||||
);
|
|
|
@ -3,25 +3,206 @@
|
||||||
import React from "react";
|
import React from "react";
|
||||||
|
|
||||||
export default (): React.JSX.Element => (
|
export default (): React.JSX.Element => (
|
||||||
<center
|
<div
|
||||||
style={{
|
style={{
|
||||||
display: "flex",
|
fontFamily:
|
||||||
justifyContent: "center",
|
'system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji"',
|
||||||
alignItems: "center",
|
//
|
||||||
height: "99vh",
|
lineHeight: 1.15,
|
||||||
|
// -webkit-text-size-adjust: 100%;
|
||||||
|
// color: #313131;
|
||||||
|
color: "black",
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<center>
|
<div
|
||||||
<h1>Checking your browser before accessing Wolfree</h1>
|
style={{
|
||||||
<p>
|
display: "flex",
|
||||||
This process is automatic. Your browser will redirect to your requested
|
flexDirection: "column",
|
||||||
content shortly.
|
minHeight: "100vh",
|
||||||
</p>
|
}}
|
||||||
<p>Please allow up to 5 seconds...</p>
|
>
|
||||||
<p>
|
<div
|
||||||
<br />
|
style={{
|
||||||
</p>
|
display: "flex",
|
||||||
<p>DDoS Protection by Wolfree</p>
|
flex: 1,
|
||||||
</center>
|
flexDirection: "column",
|
||||||
</center>
|
alignItems: "center",
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<div
|
||||||
|
style={{
|
||||||
|
paddingRight: "1.5rem",
|
||||||
|
paddingLeft: "1.5rem",
|
||||||
|
//
|
||||||
|
margin: "8rem auto",
|
||||||
|
width: "100%",
|
||||||
|
maxWidth: "60rem",
|
||||||
|
//
|
||||||
|
marginTop: " 4rem",
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<div
|
||||||
|
style={{
|
||||||
|
marginBottom: "1rem",
|
||||||
|
//
|
||||||
|
overflowWrap: "break-word",
|
||||||
|
//
|
||||||
|
lineHeight: "1.75rem",
|
||||||
|
fontSize: "1.5rem",
|
||||||
|
//
|
||||||
|
// line-height: 3.75rem;
|
||||||
|
// font-size: 2.5rem;
|
||||||
|
fontWeight: 500,
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div
|
||||||
|
style={{
|
||||||
|
lineHeight: "1.5rem",
|
||||||
|
fontSize: "1.25rem",
|
||||||
|
//
|
||||||
|
// line-height: 2.25rem;
|
||||||
|
// font-size: 1.5rem;
|
||||||
|
fontWeight: 500,
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
Checking if the site connection is secure
|
||||||
|
</div>
|
||||||
|
<div
|
||||||
|
style={{
|
||||||
|
display: "flex",
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<div
|
||||||
|
style={{
|
||||||
|
flexWrap: "wrap",
|
||||||
|
justifyContent: "center",
|
||||||
|
//
|
||||||
|
display: "flex",
|
||||||
|
//
|
||||||
|
margin: "2rem 0",
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<div>
|
||||||
|
<div
|
||||||
|
style={{
|
||||||
|
border: "none",
|
||||||
|
overflow: "hidden",
|
||||||
|
width: "300px",
|
||||||
|
height: "65px",
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<div
|
||||||
|
style={{
|
||||||
|
margin: 0,
|
||||||
|
padding: 0,
|
||||||
|
width: "100%",
|
||||||
|
height: "100%",
|
||||||
|
overflow: "hidden",
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<div
|
||||||
|
style={{
|
||||||
|
backgroundColor: "#fff",
|
||||||
|
lineHeight: "17px",
|
||||||
|
// color: #1d1f20;
|
||||||
|
color: "black",
|
||||||
|
fontFamily:
|
||||||
|
"-apple-system,system-ui,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Helvetica Neue,Arial,sans-serif",
|
||||||
|
fontSize: "14px",
|
||||||
|
fontWeight: 400,
|
||||||
|
// -webkit-font-smoothing: antialiased;
|
||||||
|
fontStyle: "normal",
|
||||||
|
//
|
||||||
|
margin: 0,
|
||||||
|
padding: 0,
|
||||||
|
width: "100%",
|
||||||
|
height: "100%",
|
||||||
|
overflow: "hidden",
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<div style={{ borderSpacing: 0 }}>
|
||||||
|
<div
|
||||||
|
style={{
|
||||||
|
display: "flex",
|
||||||
|
//
|
||||||
|
alignItems: "center",
|
||||||
|
justifyContent: "space-between",
|
||||||
|
border: "1px solid #e0e0e0",
|
||||||
|
backgroundColor: "#fafafa",
|
||||||
|
height: "63px",
|
||||||
|
userSelect: "none",
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<div
|
||||||
|
style={{
|
||||||
|
display: "flex",
|
||||||
|
alignItems: "center",
|
||||||
|
marginLeft: "11px",
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<div
|
||||||
|
style={{
|
||||||
|
display: "flex",
|
||||||
|
marginRight: "8px",
|
||||||
|
width: "30px",
|
||||||
|
height: "30px",
|
||||||
|
animation: "rotate 5s linear infinite",
|
||||||
|
}}
|
||||||
|
></div>
|
||||||
|
<div>Verifying...</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div
|
||||||
|
style={{
|
||||||
|
overflowWrap: "break-word",
|
||||||
|
//
|
||||||
|
lineHeight: "1.5rem",
|
||||||
|
fontSize: "1rem",
|
||||||
|
//
|
||||||
|
// line-height: 2.25rem;
|
||||||
|
// font-size: 1.5rem;
|
||||||
|
fontWeight: 400,
|
||||||
|
//
|
||||||
|
margin: "2rem 0",
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
Wolfree needs to review the security of your connection before
|
||||||
|
proceeding.
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div
|
||||||
|
style={{
|
||||||
|
margin: "0 auto",
|
||||||
|
width: "100%",
|
||||||
|
maxWidth: "60rem",
|
||||||
|
lineHeight: "1.125rem",
|
||||||
|
fontSize: ".75rem",
|
||||||
|
paddingRight: "1.5rem",
|
||||||
|
paddingLeft: "1.5rem",
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<div
|
||||||
|
style={{
|
||||||
|
borderTop: "1px solid #d9d9d9",
|
||||||
|
paddingTop: "1rem",
|
||||||
|
paddingBottom: "1rem",
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<div style={{ textAlign: "center" }}>
|
||||||
|
Performance & security by Wolfree
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
);
|
);
|
||||||
|
|
|
@ -63,6 +63,10 @@ fn main() -> Result<(), Box<dyn error::Error>> {
|
||||||
"'www.wolframalpha.com'"
|
"'www.wolframalpha.com'"
|
||||||
)?;
|
)?;
|
||||||
|
|
||||||
|
// block Wolfram trackers
|
||||||
|
// https://wal.wolfram.com/js/3.0.0/wal.js
|
||||||
|
sed("./docusaurus/static/input/", "wal.wolfram.com", "data:,//")?;
|
||||||
|
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue