Spaces:
Runtime error
Runtime error
Commit
·
2513f2b
1
Parent(s):
9688d35
Make wiki-screen 20% of full screen, add more information on tunnel access of frontend.
Browse files- README.md +1 -0
- frontend/src/components/Map.js +2 -1
README.md
CHANGED
@@ -18,3 +18,4 @@ pinned: false
|
|
18 |
- Use `ngrok` for frontend, `ngrok http 3000` (Since it doesnt have the password issue)
|
19 |
- Use `localtunnel` for backend, `ngrok http 8004` (I don't want remote users to have to enter password or click on a suspicious looking link).
|
20 |
- It works, I tested it on my phone, but it doesn't work on sandbox, most likely due to sandbox's requirement of `Authentication` from backend. Throws an `Error 511`.
|
|
|
|
18 |
- Use `ngrok` for frontend, `ngrok http 3000` (Since it doesnt have the password issue)
|
19 |
- Use `localtunnel` for backend, `ngrok http 8004` (I don't want remote users to have to enter password or click on a suspicious looking link).
|
20 |
- It works, I tested it on my phone, but it doesn't work on sandbox, most likely due to sandbox's requirement of `Authentication` from backend. Throws an `Error 511`.
|
21 |
+
- Unfortunately, user still has to visit the `localtunnel` link to avoid `Network Authentication` issue. For that they would reuire the `localtunnel` link, and a password, which can be obtianed from `https://loca.lt/mytunnelpassword`, on the device that is hosting the codebase.
|
frontend/src/components/Map.js
CHANGED
@@ -42,7 +42,7 @@ const Map = ( { onMapClick, searchQuery } ) => {
|
|
42 |
const [markerPosition, setMarkerPosition] = useState([0,0]);
|
43 |
const [wikiContent, setWikiContent] = useState(null);
|
44 |
const [panelSize, setPanelSize] = useState('half');
|
45 |
-
const [wikiWidth, setWikiWidth] = useState(
|
46 |
const isDragging = useRef(false);
|
47 |
const startX = useRef(0);
|
48 |
const startWidth = useRef(0);
|
@@ -109,6 +109,7 @@ const Map = ( { onMapClick, searchQuery } ) => {
|
|
109 |
if (prev === 'full') return 'half';
|
110 |
return 'half';
|
111 |
});
|
|
|
112 |
};
|
113 |
|
114 |
return (
|
|
|
42 |
const [markerPosition, setMarkerPosition] = useState([0,0]);
|
43 |
const [wikiContent, setWikiContent] = useState(null);
|
44 |
const [panelSize, setPanelSize] = useState('half');
|
45 |
+
const [wikiWidth, setWikiWidth] = useState(20);
|
46 |
const isDragging = useRef(false);
|
47 |
const startX = useRef(0);
|
48 |
const startWidth = useRef(0);
|
|
|
109 |
if (prev === 'full') return 'half';
|
110 |
return 'half';
|
111 |
});
|
112 |
+
setWikiWidth(20);
|
113 |
};
|
114 |
|
115 |
return (
|