diff --git a/.gitignore b/.gitignore
index c10d7ea..54ad191 100644
--- a/.gitignore
+++ b/.gitignore
@@ -23,3 +23,4 @@ dist-ssr
*.sln
*.sw?
public/webftp-backend.exe
+public/webftp.exe
diff --git a/App.tsx b/App.tsx
index e6b9ca9..a71ef65 100644
--- a/App.tsx
+++ b/App.tsx
@@ -165,55 +165,6 @@ const App: React.FC = () => {
ws!.send(JSON.stringify({ command: 'LOCAL_LIST', path: storedLocalPath }));
};
- ws.onmessage = (event) => {
- try {
- const data = JSON.parse(event.data);
-
- switch (data.type) {
- // ... (no change to inside of switch) ...
- case 'status':
- if (data.status === 'connected') {
- setConnection(prev => ({ ...prev, connected: true, connecting: false }));
- addLog('success', data.message || 'FTP 연결 성공');
-
- // Use Ref for latest state (especially initialPath from Site Manager)
- const currentConn = connectionRef.current;
-
- // 1. Initial Directory from Site Config
- if (currentConn.initialPath) {
- ws?.send(JSON.stringify({ command: 'LIST', path: currentConn.initialPath }));
- }
- // 2. Last Visited Path (Persistence)
- else {
- const lastRemote = localStorage.getItem(`last_remote_path_${currentConn.host}`);
- const initialPath = lastRemote || '/';
- ws?.send(JSON.stringify({ command: 'LIST', path: initialPath }));
- }
- } else if (data.status === 'disconnected') {
- setConnection(prev => ({ ...prev, connected: false, connecting: false }));
- setRemote(prev => ({ ...prev, files: [], path: '/' }));
- addLog('system', 'FTP 연결 종료');
- } else if (data.status === 'error') {
- setConnection(prev => ({ ...prev, connecting: false }));
- addLog('error', data.message);
- }
- break;
-
- case 'list':
- // ... (rest of cases handled by maintaining existing code structure or using multi-replace if I was confident, but here let's careful) ...
- // Since replace_file_content works on lines, I should target specific blocks.
- // BE CAREFUL: attempting to replace too large block blindly.
- // I should stick to smaller replaces.
- }
-
- // To avoid re-writing the huge switch content, I will use multiple Replace calls or just target onopen/onclose.
- } catch (e) {
- // ...
- }
- }; // This close brace is problematic if I don't include the switch logic.
- // Better: just replace onopen and onclose separately.
-
-
ws.onmessage = (event) => {
try {
const data = JSON.parse(event.data);
@@ -1024,14 +975,16 @@ const App: React.FC = () => {
{connection.connecting ?
: (connection.connected ? <> 연결 해제> : '빠른 연결')}
-
- 백엔드
-
+ {!(window as any).__IS_STANDALONE__ && (
+
+ 백엔드
+
+ )}