- App.tsx: full navigation (Auth stack + Main tabs with 5 screens) - Auth: LoginScreen, RegisterScreen, ForgotPasswordScreen - HomeScreen: dashboard with IoT metrics, weather widget, alerts, quick actions, sensors - MapScreen: interactive map with layer toggles (6 layers) - MarketplaceScreen: categories (6), products (5), search - ChatScreen: AI chat with quick prompts (4), bot responses - ProfileScreen: user info, stats, menu (9 items), logout - AlertsScreen: alert list with severity, acknowledge - SensorsScreen: sensor list with type filters (6 types), search - ZonesScreen: zone cards with stats - SettingsScreen: language picker (FR/EN/ES/DE), privacy, about - Stores: iotStore (sensors, zones, alerts), notificationStore, uiStore + i18n - Hooks: useSensors, useAlerts, useNotifications, useLocation - Components: Card, Button, LoadingSpinner, ErrorBoundary, Header - Services: iotService, notificationService (with axios API client) - Utils: formatters (temp, AQI, noise, dates), validators (email, password, IBAN) - Theme: colors.ts with full design system (Blue Ocean palette) - Ditto: fixed MongoDB connection, new JWT secrets, official gateway image
67 lines
2.3 KiB
C++
67 lines
2.3 KiB
C++
/*
|
|
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
*
|
|
* This source code is licensed under the MIT license found in the
|
|
* LICENSE file in the root directory of this source tree.
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include "SessionState.h"
|
|
|
|
#include <jsinspector-modern/InspectorInterfaces.h>
|
|
#include <jsinspector-modern/RuntimeAgent.h>
|
|
|
|
namespace facebook::react::jsinspector_modern {
|
|
|
|
/**
|
|
* A RuntimeAgentDelegate that handles requests from the Chrome DevTools
|
|
* Protocol for a JavaScript runtime that does not support debugging.
|
|
*/
|
|
class FallbackRuntimeAgentDelegate : public RuntimeAgentDelegate {
|
|
public:
|
|
/**
|
|
* \param frontendChannel A channel used to send responses and events to the
|
|
* frontend.
|
|
* \param sessionState The state of the current debugger session.
|
|
* \param engineDescription A description of the JavaScript engine being
|
|
* debugged. This string will be used in messages sent to the frontend.
|
|
*/
|
|
FallbackRuntimeAgentDelegate(
|
|
FrontendChannel frontendChannel,
|
|
const SessionState& sessionState,
|
|
std::string engineDescription);
|
|
|
|
/**
|
|
* Handle a CDP request. The response will be sent over the provided
|
|
* \c FrontendChannel synchronously or asynchronously.
|
|
* \param req The parsed request.
|
|
* \returns true if this agent has responded, or will respond asynchronously,
|
|
* to the request (with either a success or error message). False if the
|
|
* agent expects another agent to respond to the request instead.
|
|
*/
|
|
bool handleRequest(const cdp::PreparsedRequest& req) override;
|
|
|
|
private:
|
|
/**
|
|
* Send a user-facing message explaining that this is not a debuggable
|
|
* runtime. You must ensure that the frontend has enabled Log notifications
|
|
* (using Log.enable) prior to calling this function.
|
|
*/
|
|
void sendFallbackRuntimeWarning();
|
|
|
|
/**
|
|
* Send a simple Log.entryAdded notification with the given
|
|
* \param text. You must ensure that the frontend has enabled Log
|
|
* notifications (using Log.enable) prior to calling this function. In Chrome
|
|
* DevTools, the message will appear in the Console tab along with regular
|
|
* console messages.
|
|
*/
|
|
void sendWarningLogEntry(std::string_view text);
|
|
|
|
FrontendChannel frontendChannel_;
|
|
std::string engineDescription_;
|
|
};
|
|
|
|
} // namespace facebook::react::jsinspector_modern
|