create-ekka-desktop-app 0.4.4 → 0.4.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-ekka-desktop-app",
3
- "version": "0.4.4",
3
+ "version": "0.4.5",
4
4
  "description": "Create an EKKA desktop app with built-in demo backend. No setup required.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -88,7 +88,7 @@ pub fn engine_request(req: EngineRequest, state: State<EngineState>, app_handle:
88
88
  "auth.set" => auth::handle_set(&req.payload, &state),
89
89
 
90
90
  // Node Credentials (routed to Desktop Core process via JSON-RPC)
91
- // After successful set, app restarts to run full startup with credentials
91
+ // After successful set, TS calls engine_connect and proceeds to login
92
92
  "nodeCredentials.set" => handle_node_credentials_set_via_core(&req.payload, &state, app_handle),
93
93
  "nodeCredentials.status" => state.core_process.request("nodeCredentials.status", &req.payload),
94
94
  "nodeCredentials.clear" => state.core_process.request("nodeCredentials.clear", &req.payload),
@@ -307,11 +307,11 @@ fn handle_setup_status(state: &EngineState) -> EngineResponse {
307
307
  // Node Credentials Handlers
308
308
  // =============================================================================
309
309
 
310
- /// Set node credentials via Desktop Core process, then restart app
310
+ /// Set node credentials via Desktop Core process
311
311
  ///
312
312
  /// Core handles validation and encrypted storage.
313
- /// Host handles the app restart (Bridge-specific).
314
- fn handle_node_credentials_set_via_core(payload: &Value, state: &EngineState, app_handle: AppHandle) -> EngineResponse {
313
+ /// TS handles the post-onboarding transition: handleSetupComplete() → ekka.connect() → login.
314
+ fn handle_node_credentials_set_via_core(payload: &Value, state: &EngineState, _app_handle: AppHandle) -> EngineResponse {
315
315
  tracing::info!(op = "rust.local.op", opName = "nodeCredentials.set", "Routing nodeCredentials.set to Desktop Core");
316
316
 
317
317
  let resp = state.core_process.request("nodeCredentials.set", payload);
@@ -319,11 +319,8 @@ fn handle_node_credentials_set_via_core(payload: &Value, state: &EngineState, ap
319
319
  if resp.ok {
320
320
  tracing::info!(
321
321
  op = "desktop.onboarding.complete",
322
- "Credentials stored via Core - restarting app for full startup"
322
+ "Credentials stored via Core - TS will call engine_connect and proceed"
323
323
  );
324
- // Restart app to run full startup with credentials
325
- // This triggers: updater check → node auth → engine spawn
326
- app_handle.restart();
327
324
  }
328
325
 
329
326
  resp