// file: crates/ksp-app-store-desk/src/lib.rs // version: 6 //! Tauri desktop scaffold for backend-neutral KSP Store inspection. #![forbid(unsafe_code)] #![deny(unreachable_pub)] #![warn(missing_docs)] mod app_state; mod bootstrap; mod constants; mod dto_account; mod dto_common; mod dto_observation; mod dto_transaction; mod errors; mod frontend_logging; mod logging_runtime; mod splash; mod store_runtime; mod tauri; mod tw_main; mod tw_splash; /// Runs the KSP Store desktop application. pub use self::tauri::run; /// Shared Store Desk application state managed by Tauri. pub(crate) use self::app_state::AppState; /// Crate-internal Logging startup state shared by the application state. pub(crate) use self::bootstrap::LoggingStartup; /// Builds the Config management facade from the common KSP CLI bootstrap contract. pub(crate) use self::bootstrap::config_management; /// Initializes verbose development Logging from the Store Desk composite. pub(crate) use self::bootstrap::initialize_logging; /// Loads the concrete Store Desk Config composite. pub(crate) use self::bootstrap::load_store_desk_composite; /// Returns one required standard component profile from the Store Desk composite. pub(crate) use self::bootstrap::required_composite_component_profile; /// Composite component identifier for Logging. pub(crate) use self::constants::COMPOSITE_COMPONENT_ID_LOGGING; /// Composite component identifier for Store. pub(crate) use self::constants::COMPOSITE_COMPONENT_ID_STORE; /// Logging profile used while Store Desk is under active development. pub(crate) use self::constants::DEVELOPMENT_LOGGING_PROFILE; /// Structured domain used while bootstrapping Config and Logging. pub(crate) use self::constants::TRACING_DOMAIN_BOOTSTRAP; /// Structured domain used by technical frontend events. pub(crate) use self::constants::TRACING_DOMAIN_FRONTEND; /// Structured domain used by the Store Desk shell. pub(crate) use self::constants::TRACING_DOMAIN_SHELL; /// Structured domain used by Store readiness and shutdown operations. pub(crate) use self::constants::TRACING_DOMAIN_STORE; /// Structured domain used by Tauri window lifecycle operations. pub(crate) use self::constants::TRACING_DOMAIN_WINDOWS; /// Owning target for backend events emitted by Store Desk. pub(crate) use self::constants::TRACING_TARGET; /// Owning target for generic frontend events emitted through the KSP bridge. pub(crate) use self::constants::TRACING_TARGET_FRONTEND; /// Owning target for main-window frontend events. pub(crate) use self::constants::TRACING_TARGET_FRONTEND_MAIN; /// Owning target for splash-window frontend events. pub(crate) use self::constants::TRACING_TARGET_FRONTEND_SPLASH; /// Bounded detail projection for one complete RAW account state. pub(crate) use self::dto_account::StoreAccountDetailDto; /// App-owned identity request for one explicit RAW account-state detail load. pub(crate) use self::dto_account::StoreAccountDetailRequestDto; /// Bounded Store-owned account query request projected from one DataTables page request. pub(crate) use self::dto_account::StoreAccountQueryRequestDto; /// Server-side account-state table result using exact decimal counts. pub(crate) use self::dto_account::StoreAccountQueryResponseDto; /// Data-free RAW account-state row returned to the server-side DataTables adapter. pub(crate) use self::dto_account::StoreAccountRowDto; /// Safe command error projection exposed to Tauri commands. pub(crate) use self::dto_common::CommandErrorDto; /// Safe shell/Config/Logging snapshot exposed to the shell. pub(crate) use self::dto_common::ShellStatusDto; /// Backend-neutral Store runtime and health projection exposed to Overview. pub(crate) use self::dto_common::StoreRuntimeStatusDto; /// DataTables random-access request for observations of one explicit RAW account state. pub(crate) use self::dto_observation::StoreAccountObservationQueryRequestDto; /// Server-side account-observation table result using exact decimal counts. pub(crate) use self::dto_observation::StoreAccountObservationQueryResponseDto; /// Safe metadata-only row for one RAW account observation. pub(crate) use self::dto_observation::StoreAccountObservationRowDto; /// Safe source-independent acquisition provenance projected for observation tables. pub(crate) use self::dto_observation::StoreObservationProvenanceDto; /// DataTables random-access request for observations of one explicit RAW transaction. pub(crate) use self::dto_observation::StoreTransactionObservationQueryRequestDto; /// Server-side transaction-observation table result using exact decimal counts. pub(crate) use self::dto_observation::StoreTransactionObservationQueryResponseDto; /// Safe metadata-only row for one RAW transaction observation. pub(crate) use self::dto_observation::StoreTransactionObservationRowDto; /// Bounded detail projection for one RAW transaction. pub(crate) use self::dto_transaction::StoreTransactionDetailDto; /// App-owned identity request for one explicit RAW transaction detail load. pub(crate) use self::dto_transaction::StoreTransactionDetailRequestDto; /// Bounded Store-owned query request projected from one DataTables page request. pub(crate) use self::dto_transaction::StoreTransactionQueryRequestDto; /// Server-side transaction table result using exact decimal counts. pub(crate) use self::dto_transaction::StoreTransactionQueryResponseDto; /// Payload-free RAW transaction row returned to the server-side DataTables adapter. pub(crate) use self::dto_transaction::StoreTransactionRowDto; /// Shared Store Desk runtime state is internally inconsistent. pub(crate) use self::errors::ERROR_CODE_APP_STATE_INVALID; /// Shared Store Desk runtime state cannot be locked safely. pub(crate) use self::errors::ERROR_CODE_APP_STATE_LOCK_FAILED; /// Store Desk composite configuration is missing or references an unexpected document/profile. pub(crate) use self::errors::ERROR_CODE_CONFIG_COMPOSITE_INVALID; /// Frontend logging requested an unsupported level. pub(crate) use self::errors::ERROR_CODE_FRONTEND_LOG_LEVEL_INVALID; /// Frontend logging requested a target outside the application whitelist. pub(crate) use self::errors::ERROR_CODE_FRONTEND_LOG_TARGET_INVALID; /// Store Desk could not install the managed Logging runtime or its safe fallback. pub(crate) use self::errors::ERROR_CODE_LOGGING_BOOTSTRAP_FAILED; /// Splash readiness was invoked from a window other than the splash window. pub(crate) use self::errors::ERROR_CODE_SPLASH_ORIGIN_INVALID; /// A KSP desk splash environment duration is malformed or exceeds its safety bound. pub(crate) use self::errors::ERROR_CODE_SPLASH_SETTING_INVALID; /// Store Desk could not resolve the requested RAW account-state identity to a coherent Store entity. pub(crate) use self::errors::ERROR_CODE_STORE_ACCOUNT_NOT_FOUND; /// Store Desk received an invalid transaction inspection/detail request. pub(crate) use self::errors::ERROR_CODE_STORE_QUERY_INVALID; /// Store Desk cannot serve a Store command because the runtime is unavailable or already closed. pub(crate) use self::errors::ERROR_CODE_STORE_RUNTIME_UNAVAILABLE; /// Store Desk cannot complete the bounded Store shutdown lifecycle. pub(crate) use self::errors::ERROR_CODE_STORE_SHUTDOWN_FAILED; /// Store Desk could not resolve the requested transaction identity to a coherent Store entity. pub(crate) use self::errors::ERROR_CODE_STORE_TRANSACTION_NOT_FOUND; /// Tauri runtime assembly or execution failed. pub(crate) use self::errors::ERROR_CODE_TAURI_RUNTIME_FAILED; /// A required Tauri window is missing from the configured application runtime. pub(crate) use self::errors::ERROR_CODE_TAURI_WINDOW_MISSING; /// A Tauri window show/focus/destroy/event operation failed. pub(crate) use self::errors::ERROR_CODE_TAURI_WINDOW_OPERATION_FAILED; /// Log payload sent by Store Desk frontend scripts. pub(crate) use self::frontend_logging::FrontendLogPayloadDto; /// Emits one validated frontend event through the KSP Logging facade. pub(crate) use self::frontend_logging::emit_frontend_log_event; /// Creates the stable runtime identity for this Store Desk process launch. pub(crate) use self::logging_runtime::launch_identity; /// Command emitted by Rust to the splash frontend. pub(crate) use self::splash::SplashOrderDto; /// Runtime timings used by the common desk splash lifecycle. pub(crate) use self::splash::SplashSettings; /// Store runtime retained behind the Store Desk lifecycle boundary. pub(crate) use self::store_runtime::StoreRuntime; /// Store startup state retained by the application shell. pub(crate) use self::store_runtime::StoreStartup; /// Initializes Store from the Store Desk composite. pub(crate) use self::store_runtime::initialize_store; /// Resolves the required main window or returns a typed error. pub(crate) use self::tw_main::require_main_window; /// Shows and focuses the main Store Desk window. pub(crate) use self::tw_main::show_main_window; /// Resolves the required splash window or returns a typed error. pub(crate) use self::tw_splash::require_splash_window; /// Starts the one-shot splash lifecycle after the splash frontend reports readiness. pub(crate) use self::tw_splash::splash_frontend_ready_service;