@oneuptime/common 12.0.33 → 13.0.0
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/Models/AnalyticsModels/RumSession.ts +117 -1
- package/Models/AnalyticsModels/RumSessionChunk.ts +13 -0
- package/Models/DatabaseModels/AlertCustomField.ts +77 -3
- package/Models/DatabaseModels/ApiKeyPermission.ts +3 -27
- package/Models/DatabaseModels/GlobalConfig.ts +12 -12
- package/Models/DatabaseModels/IncidentCustomField.ts +77 -3
- package/Models/DatabaseModels/InventoryItem.ts +44 -1
- package/Models/DatabaseModels/InventoryItemCustomField.ts +77 -3
- package/Models/DatabaseModels/MonitorCustomField.ts +77 -3
- package/Models/DatabaseModels/NetworkDevice.ts +126 -0
- package/Models/DatabaseModels/OnCallDutyPolicyCustomField.ts +77 -3
- package/Models/DatabaseModels/RumApplication.ts +6 -6
- package/Models/DatabaseModels/ScheduledMaintenanceCustomField.ts +77 -3
- package/Models/DatabaseModels/StatusPageCustomField.ts +77 -3
- package/Models/DatabaseModels/TeamCustomField.ts +77 -3
- package/Models/DatabaseModels/TeamMember.ts +0 -9
- package/Models/DatabaseModels/TeamMemberCustomField.ts +77 -3
- package/Models/DatabaseModels/TeamPermission.ts +3 -24
- package/Models/DatabaseModels/TelemetryIngestionKey.ts +260 -0
- package/Models/DatabaseModels/UserTelegram.ts +0 -4
- package/Scripts/benchmark-fanin-capacity.js +181 -0
- package/Server/API/TelemetryAPI.ts +1284 -164
- package/Server/API/UserNotificationSettingAPI.ts +55 -0
- package/Server/API/UserTelegramAPI.ts +48 -4
- package/Server/EnvironmentConfig.ts +82 -18
- package/Server/Infrastructure/Postgres/SchemaMigrations/1791300000000-AddTelemetryIngestionKeyType.ts +91 -0
- package/Server/Infrastructure/Postgres/SchemaMigrations/1791400000000-SessionReplayRecordEverySessionByDefault.ts +67 -0
- package/Server/Infrastructure/Postgres/SchemaMigrations/1791500000000-WidenCustomFieldDropdownOptions.ts +139 -0
- package/Server/Infrastructure/Postgres/SchemaMigrations/1791600000000-AddCustomFieldValueMapping.ts +121 -0
- package/Server/Infrastructure/Postgres/SchemaMigrations/1791700000000-AddMacAddressToNetworkDevice.ts +25 -0
- package/Server/Infrastructure/Postgres/SchemaMigrations/Index.ts +10 -0
- package/Server/Infrastructure/QueueWorker.ts +20 -14
- package/Server/Infrastructure/Redis.ts +8 -8
- package/Server/Infrastructure/Semaphore.ts +2 -0
- package/Server/Infrastructure/Status.ts +10 -4
- package/Server/Middleware/TelemetryIngest.ts +453 -7
- package/Server/Services/AccessTokenService.ts +1 -0
- package/Server/Services/AlertCustomFieldService.ts +98 -0
- package/Server/Services/AlertService.ts +37 -0
- package/Server/Services/ApiKeyPermissionService.ts +461 -29
- package/Server/Services/CustomFieldMappingService.ts +879 -0
- package/Server/Services/DatabaseService.ts +65 -13
- package/Server/Services/GlobalConfigService.ts +194 -0
- package/Server/Services/IncidentCustomFieldService.ts +98 -0
- package/Server/Services/IncidentService.ts +35 -0
- package/Server/Services/InventoryItemService.ts +31 -1
- package/Server/Services/MetricService.ts +194 -0
- package/Server/Services/MonitorService.ts +32 -0
- package/Server/Services/MonitorTemplateService.ts +140 -19
- package/Server/Services/NetworkDeviceAutoImportRuleEngineService.ts +427 -66
- package/Server/Services/NetworkDeviceDiscoveryScanService.ts +87 -2
- package/Server/Services/NetworkDeviceService.ts +69 -0
- package/Server/Services/ProjectService.ts +22 -0
- package/Server/Services/RoutineEmailSettingsService.ts +73 -0
- package/Server/Services/RumSessionReplayViewService.ts +104 -24
- package/Server/Services/ScheduledMaintenanceCustomFieldService.ts +98 -0
- package/Server/Services/ScheduledMaintenanceService.ts +32 -0
- package/Server/Services/TeamMemberService.ts +78 -0
- package/Server/Services/TeamPermissionService.ts +235 -3
- package/Server/Services/TelemetryIngestionKeyService.ts +722 -19
- package/Server/Services/UserNotificationRuleService.ts +76 -25
- package/Server/Services/UserNotificationSettingService.ts +34 -6
- package/Server/Services/UserTelegramService.ts +326 -5
- package/Server/Types/Database/Permissions/ReadPermission.ts +45 -5
- package/Server/Types/Database/QueryHelper.ts +2 -0
- package/Server/Types/Database/QueryUtil.ts +56 -0
- package/Server/Types/Markdown.ts +93 -1
- package/Server/Utils/APIKey/AccessPermission.ts +5 -2
- package/Server/Utils/CustomField/CustomFieldDefinitionMappingHooks.ts +54 -0
- package/Server/Utils/CustomField/CustomFieldMappingRegistry.ts +415 -0
- package/Server/Utils/CustomField/CustomFieldMappingValidator.ts +335 -0
- package/Server/Utils/Dashboard/PublicDashboardResourceListPolicy.ts +82 -17
- package/Server/Utils/DataSource/EgressGuard.ts +177 -8
- package/Server/Utils/EmailRollup/EmailRollupConstants.ts +38 -5
- package/Server/Utils/EmailRollup/EmailRollupFlushRunner.ts +67 -5
- package/Server/Utils/EmailRollup/EmailRollupRenderer.ts +2 -2
- package/Server/Utils/FrontendEnvironment.ts +40 -0
- package/Server/Utils/LogRedaction.ts +20 -0
- package/Server/Utils/Logger.ts +11 -0
- package/Server/Utils/Monitor/Criteria/CompareCriteria.ts +394 -86
- package/Server/Utils/Monitor/Criteria/IncomingRequestCriteria.ts +30 -4
- package/Server/Utils/Monitor/Criteria/MetricMonitorCriteria.ts +31 -5
- package/Server/Utils/Monitor/MonitorAlert.ts +29 -6
- package/Server/Utils/Monitor/MonitorCriteriaEvaluator.ts +312 -52
- package/Server/Utils/Monitor/MonitorCriteriaExpectationBuilder.ts +82 -9
- package/Server/Utils/Monitor/MonitorCriteriaMessageBuilder.ts +16 -7
- package/Server/Utils/Monitor/MonitorCriteriaMessageFormatter.ts +29 -17
- package/Server/Utils/Monitor/MonitorCriteriaObservationBuilder.ts +107 -48
- package/Server/Utils/Monitor/MonitorIncident.ts +22 -6
- package/Server/Utils/Monitor/MonitorTemplateUtil.ts +29 -0
- package/Server/Utils/Monitor/NetworkDeviceMacLearningUtil.ts +158 -0
- package/Server/Utils/Monitor/NetworkInventoryUtil.ts +27 -0
- package/Server/Utils/Monitor/SeriesContextEnricher.ts +304 -0
- package/Server/Utils/SSRFProtection.ts +217 -10
- package/Server/Utils/SessionReplay/SessionReplayGateCache.ts +239 -138
- package/Server/Utils/SessionReplay/SessionReplayHealthCounters.ts +305 -0
- package/Server/Utils/SessionReplay/SessionReplayReadService.ts +1430 -289
- package/Server/Utils/StartServer.ts +2 -17
- package/Server/Utils/TelegramVerificationToken.ts +185 -0
- package/Server/Utils/Telemetry/EntityRegistry.ts +11 -1
- package/Server/Utils/Telemetry/PinServiceName.ts +197 -0
- package/Server/Utils/Telemetry/TelemetryEntity.ts +83 -9
- package/Server/Utils/Telemetry/TelemetryFanInWriter.ts +38 -16
- package/Server/Utils/Telemetry/TelemetryIngestionKeyGuard.ts +92 -0
- package/Server/Utils/Telemetry/TelemetryIngestionKeyRateLimiter.ts +217 -0
- package/Server/Utils/VM/VMAPI.ts +1 -0
- package/Server/Utils/VM/VMRunner.ts +975 -95
- package/Tests/App/AdminDashboard/AdminHeaderSmallScreens.test.tsx +202 -0
- package/Tests/App/Dashboard/AddNeighborToMonitoringModal.test.tsx +32 -0
- package/Tests/App/Dashboard/AdoptedDeviceDrawer.test.tsx +374 -0
- package/Tests/App/Dashboard/DashboardHeaderSmallScreens.test.tsx +404 -0
- package/Tests/App/Dashboard/DashboardLabelVariables.test.tsx +580 -0
- package/Tests/App/Dashboard/DashboardMonitorLabelVariable.test.tsx +438 -0
- package/Tests/App/Dashboard/DashboardVariableAllContract.test.tsx +5 -2
- package/Tests/App/Dashboard/DeviceAttachmentCard.test.tsx +273 -0
- package/Tests/App/Dashboard/DiscoveryReviewInventoryRefresh.test.tsx +505 -0
- package/Tests/App/Dashboard/DiscoveryScanWizardValidation.test.tsx +468 -0
- package/Tests/App/Dashboard/EntityDetailPanel.test.tsx +163 -0
- package/Tests/App/Dashboard/InfrastructureExplorer.test.tsx +401 -0
- package/Tests/App/Dashboard/InfrastructureGraph.test.tsx +232 -0
- package/Tests/App/Dashboard/InventoryItems.test.tsx +201 -0
- package/Tests/App/Dashboard/InventoryTypeAndStatusFacets.test.tsx +798 -0
- package/Tests/App/Dashboard/NetworkTopologyLiveView.test.tsx +320 -0
- package/Tests/App/Dashboard/NetworkTopologyToolbar.test.tsx +275 -0
- package/Tests/App/Dashboard/OnCallCalendarFeedEmptyState.test.tsx +975 -0
- package/Tests/App/Dashboard/OnCallCalendarFeedPlanGate.test.tsx +63 -0
- package/Tests/App/Dashboard/ServiceMapGraph.test.tsx +626 -0
- package/Tests/App/Dashboard/TopologyDataLoading.test.tsx +348 -0
- package/Tests/App/Dashboard/TopologyPageNavigation.test.tsx +331 -0
- package/Tests/App/Dashboard/UserSettingsEmailPreferences.test.tsx +603 -0
- package/Tests/App/Dashboard/UserSettingsNotificationSettings.test.tsx +324 -0
- package/Tests/App/PublicDashboard/DashboardVariableSelector.test.tsx +13 -4
- package/Tests/App/StatusPage/StatusPageLastUpdated.test.tsx +263 -0
- package/Tests/App/StatusPage/StatusPageOidcOrigin.test.tsx +223 -0
- package/Tests/App/StatusPage/StatusPageOverviewLiveAndSearch.test.tsx +753 -0
- package/Tests/App/StatusPage/StatusPageResourceSearchBox.test.tsx +224 -0
- package/Tests/Models/AnalyticsModels/RumSessionReplayColumns.test.ts +262 -0
- package/Tests/Models/CustomFieldMappingColumns.test.ts +166 -0
- package/Tests/Models/DatabaseModels/SessionReplayModels.test.ts +20 -6
- package/Tests/Models/InventoryItemStatus.test.ts +147 -0
- package/Tests/Models/NetworkDeviceMacAddressColumn.test.ts +294 -0
- package/Tests/ResponsiveVisibility.test.ts +115 -0
- package/Tests/ResponsiveVisibility.ts +183 -0
- package/Tests/Server/API/DashboardPublicResourceListAPI.test.ts +129 -0
- package/Tests/Server/API/SessionReplayAPI.test.ts +1940 -216
- package/Tests/Server/API/UserNotificationSettingAPI.test.ts +186 -0
- package/Tests/Server/API/UserTelegramAPISecurity.test.ts +231 -0
- package/Tests/Server/EnvironmentConfigFrontendSecurity.test.ts +234 -0
- package/Tests/Server/EnvironmentConfigValkey.test.ts +227 -0
- package/Tests/Server/Infrastructure/Postgres/AddMacAddressToNetworkDeviceMigration.test.ts +365 -0
- package/Tests/Server/Infrastructure/Postgres/CustomFieldValueMappingMigration.test.ts +241 -0
- package/Tests/Server/Infrastructure/Postgres/InventoryItemArchiveMigration.test.ts +41 -0
- package/Tests/Server/Infrastructure/Postgres/SessionReplayRecordEverySessionByDefaultMigration.test.ts +169 -0
- package/Tests/Server/Infrastructure/QueueWorkerTimeout.test.ts +210 -0
- package/Tests/Server/Infrastructure/TelemetryExporterDeploymentConfig.test.ts +130 -0
- package/Tests/Server/Infrastructure/ValkeyDeploymentConfig.test.ts +265 -0
- package/Tests/Server/Middleware/HttpMetricsMiddleware.test.ts +382 -0
- package/Tests/Server/Middleware/ProjectAuthorizationApiKeyMiddleware.test.ts +4 -1
- package/Tests/Server/Middleware/SCIMAuthorization.test.ts +525 -0
- package/Tests/Server/Middleware/TelemetryIngestBrowserKey.test.ts +1163 -0
- package/Tests/Server/Middleware/TelemetryIngestTokenLog.test.ts +5 -3
- package/Tests/Server/Services/AddTelemetryIngestionKeyTypeMigration.test.ts +555 -0
- package/Tests/Server/Services/ApiKeyPermissionSecurity.test.ts +678 -0
- package/Tests/Server/Services/ApiKeyPermissionService.test.ts +276 -28
- package/Tests/Server/Services/CustomFieldDropdownOptionsColumnWidth.test.ts +431 -0
- package/Tests/Server/Services/CustomFieldMappingService.test.ts +850 -0
- package/Tests/Server/Services/DatabaseServiceAggregateBy.test.ts +291 -56
- package/Tests/Server/Services/DatabaseServiceSortTiebreaker.test.ts +151 -0
- package/Tests/Server/Services/DiscoveryScanClaimHookFreeSafety.test.ts +32 -0
- package/Tests/Server/Services/GlobalConfigService.test.ts +414 -1
- package/Tests/Server/Services/InventoryItemManualCreate.test.ts +105 -0
- package/Tests/Server/Services/InventoryItemPromotionGate.test.ts +178 -0
- package/Tests/Server/Services/MetricRawEntityKeyPrune.test.ts +592 -0
- package/Tests/Server/Services/MonitorTemplateServiceCustomFieldSync.test.ts +502 -0
- package/Tests/Server/Services/NetworkDeviceAutoImportRuleEngineService.test.ts +1351 -74
- package/Tests/Server/Services/NetworkDeviceDiscoveryScanRegistration.test.ts +520 -0
- package/Tests/Server/Services/NetworkDeviceMacAddressNormalization.test.ts +572 -0
- package/Tests/Server/Services/RoutineEmailSettingsPostgres.test.ts +329 -0
- package/Tests/Server/Services/RumSessionReplayViewService.test.ts +267 -0
- package/Tests/Server/Services/TeamMemberAutoAcceptInvitation.test.ts +9 -0
- package/Tests/Server/Services/TeamMemberInviteRegistrationToken.test.ts +9 -0
- package/Tests/Server/Services/TeamPrivilegeEscalation.test.ts +834 -0
- package/Tests/Server/Services/TelemetryIngestionKeyPolicyResolution.test.ts +814 -0
- package/Tests/Server/Services/TelemetryIngestionKeyValidation.test.ts +998 -0
- package/Tests/Server/Services/UserNotificationSettingRollupRouting.test.ts +141 -0
- package/Tests/Server/Services/UserNotificationSettingWorkspaceChannels.test.ts +18 -10
- package/Tests/Server/Services/UserTelegramVerificationSecurity.test.ts +688 -0
- package/Tests/Server/Types/Database/InventoryStatusPostgres.test.ts +368 -0
- package/Tests/Server/Types/Database/Permissions/ReadBlockPermission.test.ts +261 -14
- package/Tests/Server/Types/Database/QueryUtilIncludesAnyOfGroups.test.ts +169 -0
- package/Tests/Server/Types/Database/QueryUtilIncludesAnyOfGroupsPostgres.test.ts +297 -0
- package/Tests/Server/Types/Markdown.test.ts +194 -1
- package/Tests/Server/Types/Workflow/Components/IncomingWebhookUtils.test.ts +279 -0
- package/Tests/Server/Types/Workflow/Components/TextToJson.test.ts +212 -0
- package/Tests/Server/Utils/AI/SRE/Insights/FixRouting.test.ts +497 -0
- package/Tests/Server/Utils/AI/Toolbox/Serializer.test.ts +383 -0
- package/Tests/Server/Utils/APIKey/AccessPermission.test.ts +7 -3
- package/Tests/Server/Utils/AnalyticsDatabase/ClusterConfig.test.ts +315 -0
- package/Tests/Server/Utils/CustomField/CustomFieldMappingRegistry.test.ts +436 -0
- package/Tests/Server/Utils/CustomField/CustomFieldMappingValidator.test.ts +437 -0
- package/Tests/Server/Utils/Dashboard/PublicDashboardResourceListPolicy.test.ts +214 -0
- package/Tests/Server/Utils/DataSource/EgressGuard.test.ts +300 -11
- package/Tests/Server/Utils/EmailRollup/EmailRollupBurstWindow.test.ts +83 -0
- package/Tests/Server/Utils/EmailRollup/EmailRollupFlushRunnerBehaviour.test.ts +2 -2
- package/Tests/Server/Utils/EmailRollup/EmailRollupFlushRunnerPreferences.test.ts +362 -0
- package/Tests/Server/Utils/EmailRollup/EmailRollupRenderer.test.ts +10 -3
- package/Tests/Server/Utils/EmailRollup/EmailRollupTestHarness.ts +77 -1
- package/Tests/Server/Utils/EventLoop.test.ts +359 -0
- package/Tests/Server/Utils/FrontendEnvironment.test.ts +190 -0
- package/Tests/Server/Utils/JsonWebToken.test.ts +30 -0
- package/Tests/Server/Utils/LogRedaction.test.ts +26 -0
- package/Tests/Server/Utils/LoggerCredentialLeak.test.ts +23 -9
- package/Tests/Server/Utils/Monitor/Criteria/CompareCriteria.test.ts +242 -0
- package/Tests/Server/Utils/Monitor/Criteria/CompareCriteriaAggregation.test.ts +590 -0
- package/Tests/Server/Utils/Monitor/Criteria/DatabaseMonitorCriteria.test.ts +29 -0
- package/Tests/Server/Utils/Monitor/Criteria/IncomingRequestHeaderCriteria.test.ts +236 -0
- package/Tests/Server/Utils/Monitor/Criteria/MetricMonitorCriteria.test.ts +30 -6
- package/Tests/Server/Utils/Monitor/Criteria/MetricMonitorCriteriaAnomalyUnits.test.ts +246 -0
- package/Tests/Server/Utils/Monitor/MonitorCriteriaEmailEvalLogAgreement.test.ts +280 -0
- package/Tests/Server/Utils/Monitor/MonitorCriteriaEvaluator.test.ts +659 -8
- package/Tests/Server/Utils/Monitor/MonitorCriteriaEvaluatorMetricUnits.test.ts +570 -0
- package/Tests/Server/Utils/Monitor/MonitorCriteriaExpectationBuilderUnits.test.ts +30 -5
- package/Tests/Server/Utils/Monitor/MonitorCriteriaMessageBuilderUnits.test.ts +68 -21
- package/Tests/Server/Utils/Monitor/MonitorCriteriaObservationBuilderUnits.test.ts +36 -19
- package/Tests/Server/Utils/Monitor/MonitorTemplateUtilSeriesContext.test.ts +176 -0
- package/Tests/Server/Utils/Monitor/NetworkDeviceMacLearningUtil.test.ts +573 -0
- package/Tests/Server/Utils/Monitor/NetworkInventoryUtil.test.ts +317 -0
- package/Tests/Server/Utils/Monitor/SeriesContextEnricher.test.ts +356 -0
- package/Tests/Server/Utils/SSRFProtectionCloudServiceAddresses.test.ts +595 -0
- package/Tests/Server/Utils/SessionReplay/SessionReplayGateCachePolicy.test.ts +198 -1
- package/Tests/Server/Utils/SessionReplay/SessionReplayHealthCounters.test.ts +453 -0
- package/Tests/Server/Utils/SessionReplay/SessionReplayReadServiceQueries.test.ts +1378 -0
- package/Tests/Server/Utils/SessionReplayOriginAllowListRefactor.test.ts +420 -0
- package/Tests/Server/Utils/TelegramVerificationToken.test.ts +253 -0
- package/Tests/Server/Utils/Telemetry/ContextSpanProcessor.test.ts +281 -0
- package/Tests/Server/Utils/Telemetry/InventoryDuplicateIdentity.test.ts +316 -0
- package/Tests/Server/Utils/Telemetry/PinServiceName.test.ts +666 -0
- package/Tests/Server/Utils/Telemetry/TelemetryEntity.test.ts +111 -8
- package/Tests/Server/Utils/Telemetry/TelemetryFanInWriterCapacity.test.ts +458 -0
- package/Tests/Server/Utils/Telemetry/TelemetryIngestionKeyGuard.test.ts +424 -0
- package/Tests/Server/Utils/Telemetry/TelemetryIngestionKeyRateLimiter.test.ts +528 -0
- package/Tests/Server/Utils/TelemetryExporterEnvironment.test.ts +56 -0
- package/Tests/Server/Utils/VM/VMRunnerHostBridgeLatency.test.ts +74 -0
- package/Tests/Server/Utils/VM/VMRunnerPrivateNetworkWiring.test.ts +100 -7
- package/Tests/Server/Utils/VM/VMRunnerSsrf.test.ts +1176 -6
- package/Tests/Types/CustomField/CustomFieldMappingCatalog.test.ts +220 -0
- package/Tests/Types/CustomField/CustomFieldValueMapping.test.ts +348 -0
- package/Tests/Types/Database/IncludesAnyOfGroups.test.ts +106 -0
- package/Tests/Types/JSONFunctions.test.ts +300 -0
- package/Tests/Types/Monitor/CephAlertTemplates.test.ts +422 -53
- package/Tests/Types/Monitor/DockerAlertTemplates.test.ts +495 -15
- package/Tests/Types/Monitor/DockerSwarmAlertTemplates.test.ts +191 -45
- package/Tests/Types/Monitor/HostAlertTemplates.test.ts +370 -42
- package/Tests/Types/Monitor/IotAlertTemplates.test.ts +375 -20
- package/Tests/Types/Monitor/KubernetesAlertTemplates.test.ts +636 -42
- package/Tests/Types/Monitor/KubernetesMetricCatalog.test.ts +189 -0
- package/Tests/Types/Monitor/KubernetesTemplateGroupByKeys.test.ts +95 -14
- package/Tests/Types/Monitor/PodmanAlertTemplates.test.ts +190 -21
- package/Tests/Types/Monitor/ProxmoxAlertTemplates.test.ts +352 -22
- package/Tests/Types/Monitor/Recommendation/MonitorRecommendationAlertDebuggability.test.ts +363 -0
- package/Tests/Types/Monitor/Recommendation/MonitorRecommendationNotificationMode.test.ts +93 -18
- package/Tests/Types/Monitor/Recommendation/MonitorRecommendationSeverityMapper.test.ts +259 -0
- package/Tests/Types/Monitor/Recommendation/RecommendationCriteriaBuilder.test.ts +476 -0
- package/Tests/Types/Monitor/RumAlertTemplates.test.ts +136 -0
- package/Tests/Types/Monitor/SeriesContext/SeriesDebugHints.test.ts +661 -0
- package/Tests/Types/Monitor/SeriesContext/SeriesLabelDisplay.test.ts +507 -0
- package/Tests/Types/Monitor/ServiceAlertTemplates.test.ts +270 -0
- package/Tests/Types/Monitor/TemplateGroupByKeys.test.ts +38 -10
- package/Tests/Types/Monitor/Utils/RecommendationCriteriaAssertions.ts +102 -0
- package/Tests/Types/NetworkAutomation/AutoImportRunMerge.test.ts +235 -0
- package/Tests/Types/NetworkAutomation/RuleRunResult.test.ts +66 -0
- package/Tests/Types/NetworkAutomation/RuleRunResultDescribe.test.ts +309 -1
- package/Tests/Types/NotificationSetting/RoutineEmailEvents.test.ts +47 -0
- package/Tests/Types/Rum/SessionReplayApiContracts.test.ts +608 -0
- package/Tests/Types/Rum/SessionReplayCustomEvents.test.ts +434 -0
- package/Tests/Types/Telemetry/InventoryLiveness.test.ts +99 -0
- package/Tests/Types/WebsiteRequest.test.ts +285 -3
- package/Tests/UI/Components/Charts/ChartBucketIdentity.test.ts +16 -3
- package/Tests/UI/Components/Charts/ChartTrailingBucketGap.test.ts +691 -0
- package/Tests/UI/Components/ComponentsModal.test.tsx +12 -4
- package/Tests/UI/Components/ComponentsModalUsability.test.tsx +518 -0
- package/Tests/UI/Components/CustomFields/CustomFieldsDetail.test.tsx +160 -0
- package/Tests/UI/Components/CustomFields/CustomFieldsDetailMapping.test.tsx +324 -0
- package/Tests/UI/Components/CustomFields/MapFromCustomFieldInput.test.tsx +176 -0
- package/Tests/UI/Components/Graphs/DayUptimeGraph.test.tsx +484 -0
- package/Tests/UI/Components/HeaderRightRail.test.tsx +157 -0
- package/Tests/UI/Components/IconDropdownItem.test.tsx +102 -0
- package/Tests/UI/Components/JSONTablePrototypePollution.test.tsx +117 -0
- package/Tests/UI/Components/KeyboardShortcutsModal.test.tsx +214 -0
- package/Tests/UI/Components/ModelTable/ModelTableWrapContent.test.tsx +561 -0
- package/Tests/UI/Components/MonitorGraphs/UptimeBarDayModal.test.tsx +302 -0
- package/Tests/UI/Components/MonitorTemplateVariables/TemplateVariablesCatalog.test.ts +28 -12
- package/Tests/UI/Components/ShortcutDialogGuard.test.tsx +74 -0
- package/Tests/UI/Components/StatusPage/ResourceGroupSectionAutoExpand.test.tsx +248 -0
- package/Tests/UI/Components/TableCellWrapping.test.tsx +625 -0
- package/Tests/UI/Components/TableLoadingStates.test.tsx +205 -0
- package/Tests/UI/Components/Workflow/NodePlacement.test.ts +148 -0
- package/Tests/UI/Components/Workflow/Workflow.test.tsx +981 -0
- package/Tests/UI/ConfigBrowserTelemetry.test.ts +70 -0
- package/Tests/UI/ReactRouterSingletonBuild.test.ts +133 -0
- package/Tests/UI/Rum/ChunkLoader.test.ts +1036 -2
- package/Tests/UI/Rum/FidelityNotices.test.ts +187 -0
- package/Tests/UI/Rum/InactivityMap.test.ts +341 -0
- package/Tests/UI/Rum/PrivacySummaryCard.test.tsx +259 -0
- package/Tests/UI/Rum/RecordingHealthCard.test.tsx +855 -0
- package/Tests/UI/Rum/RecordingHealthStrip.test.tsx +594 -0
- package/Tests/UI/Rum/ReplayCard.test.tsx +451 -0
- package/Tests/UI/Rum/ReplayCorrelationPanel.test.tsx +536 -0
- package/Tests/UI/Rum/ReplayEngine.test.ts +2503 -0
- package/Tests/UI/Rum/ReplayEngineTypes.test.ts +171 -0
- package/Tests/UI/Rum/ReplayHeader.test.tsx +719 -0
- package/Tests/UI/Rum/ReplayLink.test.tsx +119 -0
- package/Tests/UI/Rum/ReplayPinControl.test.tsx +408 -0
- package/Tests/UI/Rum/ReplayPlaybackIntent.test.ts +152 -0
- package/Tests/UI/Rum/ReplayPlayerChrome.test.tsx +514 -0
- package/Tests/UI/Rum/ReplayRail.test.tsx +1296 -0
- package/Tests/UI/Rum/ReplayRailDetail.test.tsx +900 -0
- package/Tests/UI/Rum/ReplayScrubber.test.tsx +763 -147
- package/Tests/UI/Rum/ReplaySignalTypes.test.ts +189 -0
- package/Tests/UI/Rum/ReplaySignals.test.ts +1579 -0
- package/Tests/UI/Rum/ReplayStage.test.tsx +396 -473
- package/Tests/UI/Rum/ReplayStageOverlays.test.tsx +918 -0
- package/Tests/UI/Rum/ReplayTimeFormat.test.ts +94 -0
- package/Tests/UI/Rum/ReplayTimeline.test.tsx +696 -0
- package/Tests/UI/Rum/ReplayUi.test.tsx +559 -0
- package/Tests/UI/Rum/SessionReplayEmptyState.test.tsx +499 -0
- package/Tests/UI/Rum/SessionReplaySearchBar.test.tsx +346 -0
- package/Tests/UI/Rum/SessionReplaySetupGuide.test.tsx +545 -0
- package/Tests/UI/Rum/SessionReplayTable.test.tsx +991 -0
- package/Tests/UI/Rum/TargetedCapturePanel.test.tsx +254 -0
- package/Tests/UI/Telemetry/BrowserExporterIsolation.test.ts +71 -0
- package/Tests/UI/Utils/Breadcrumb/fixtures/RealBreadcrumbTrails.ts +5 -0
- package/Tests/UI/Utils/Breadcrumb/fixtures/RealRoutePatterns.ts +1 -0
- package/Tests/UI/Utils/GlobalKeyboardShortcut.test.ts +344 -0
- package/Tests/Utils/API.test.ts +308 -0
- package/Tests/Utils/Dashboard/Components/DashboardMonitorListComponent.test.ts +11 -1
- package/Tests/Utils/Dashboard/LabelVariable.test.ts +257 -0
- package/Tests/Utils/Dashboard/VariableUrlState.test.ts +144 -14
- package/Tests/Utils/HTTPResponseBodyReader.test.ts +323 -0
- package/Tests/Utils/MetricUnitUtil.test.ts +81 -0
- package/Tests/Utils/Monitor/DeviceMacLearningUtil.test.ts +497 -0
- package/Tests/Utils/Monitor/MetricValueFormatter.test.ts +546 -0
- package/Tests/Utils/Monitor/MonitorTemplateCustomFieldUtil.test.ts +218 -0
- package/Tests/Utils/Monitor/NetworkTopologyEndpointAdoption.test.ts +1755 -0
- package/Tests/Utils/NetworkAutomation/AutoImportRunChain.test.ts +320 -0
- package/Tests/Utils/NetworkDiscovery/DiscoveryScanStatus.test.ts +117 -0
- package/Tests/Utils/Rum/ChunkMath.test.ts +83 -0
- package/Tests/Utils/Rum/SessionReplayHealthDiagnosis.test.ts +993 -0
- package/Tests/Utils/Rum/SessionReplayStringMap.test.ts +245 -0
- package/Tests/Utils/StatusPage/ResourceSearch.test.ts +631 -0
- package/Tests/Utils/Telemetry/OriginAllowList.test.ts +633 -0
- package/Tests/Utils/Uptime/DayUptimeGraphUtil.test.ts +461 -0
- package/Tests/Utils/ValueFormatter.test.ts +148 -0
- package/Types/BaseDatabase/IncludesAnyOfGroups.ts +77 -0
- package/Types/CustomField/CustomFieldMappingCatalog.ts +161 -0
- package/Types/CustomField/CustomFieldMappingSourceResource.ts +19 -0
- package/Types/CustomField/CustomFieldValueMapping.ts +288 -0
- package/Types/Dashboard/DashboardComponents/ComponentArgument.ts +1 -0
- package/Types/Dashboard/DashboardComponents/DashboardMonitorListComponent.ts +1 -0
- package/Types/Dashboard/DashboardVariable.ts +8 -0
- package/Types/Icon/IconProp.ts +1 -0
- package/Types/JSON.ts +4 -0
- package/Types/JSONFunctions.ts +205 -43
- package/Types/Monitor/CephAlertTemplates.ts +157 -195
- package/Types/Monitor/DockerAlertTemplates.ts +338 -128
- package/Types/Monitor/DockerSwarmAlertTemplates.ts +95 -112
- package/Types/Monitor/HostAlertTemplates.ts +302 -130
- package/Types/Monitor/IotAlertTemplates.ts +112 -104
- package/Types/Monitor/KubernetesAlertTemplates.ts +415 -224
- package/Types/Monitor/KubernetesMetricCatalog.ts +23 -19
- package/Types/Monitor/PodmanAlertTemplates.ts +116 -163
- package/Types/Monitor/ProxmoxAlertTemplates.ts +217 -99
- package/Types/Monitor/Recommendation/MonitorRecommendationSeverityMapper.ts +98 -6
- package/Types/Monitor/Recommendation/MonitorRecommendationUtil.ts +44 -7
- package/Types/Monitor/Recommendation/RecommendationCriteriaBuilder.ts +383 -0
- package/Types/Monitor/RumAlertTemplates.ts +46 -7
- package/Types/Monitor/SeriesContext/SeriesDebugHints.ts +596 -0
- package/Types/Monitor/SeriesContext/SeriesLabelDisplay.ts +554 -0
- package/Types/Monitor/ServiceAlertTemplates.ts +98 -11
- package/Types/Monitor/SnmpMonitor/NetworkTopology.ts +13 -0
- package/Types/Monitor/UptimeHistoryLabels.ts +56 -0
- package/Types/NetworkAutomation/RuleRunResult.ts +402 -13
- package/Types/NotificationSetting/RoutineEmailEvents.ts +30 -0
- package/Types/Rum/SessionReplay.ts +209 -0
- package/Types/Rum/SessionReplayApi.ts +722 -0
- package/Types/Rum/SessionReplayCaptureTrigger.ts +21 -12
- package/Types/Rum/SessionReplayConsentMode.ts +11 -7
- package/Types/Rum/SessionReplayCustomEvents.ts +549 -0
- package/Types/Rum/SessionReplayHealth.ts +238 -0
- package/Types/SerializableObjectDictionary.ts +4 -0
- package/Types/Telemetry/InventoryLiveness.ts +56 -0
- package/Types/Telemetry/TelemetryIngestSurface.ts +95 -0
- package/Types/Telemetry/TelemetryIngestionKeyPolicy.ts +75 -0
- package/Types/Telemetry/TelemetryIngestionKeyType.ts +29 -0
- package/Types/WebsiteRequest.ts +85 -3
- package/UI/Components/CSVFileUpload/CSVFileUpload.tsx +9 -2
- package/UI/Components/Charts/Area/AreaChart.tsx +13 -2
- package/UI/Components/Charts/Bar/BarChart.tsx +6 -2
- package/UI/Components/Charts/Line/LineChart.tsx +13 -2
- package/UI/Components/Charts/Types/XAxis/XAxis.ts +29 -0
- package/UI/Components/Charts/Utils/DataPoint.ts +22 -3
- package/UI/Components/Charts/Utils/TimeAnnotation.ts +76 -9
- package/UI/Components/Charts/Utils/XAxis.ts +217 -0
- package/UI/Components/CustomFields/CustomFieldsDetail.tsx +189 -46
- package/UI/Components/CustomFields/MapFromCustomFieldInput.tsx +216 -0
- package/UI/Components/Dashboard/DashboardVariableControl.tsx +285 -0
- package/UI/Components/Graphs/DayUptimeGraph.tsx +173 -8
- package/UI/Components/Graphs/UptimeBarTooltip.tsx +22 -278
- package/UI/Components/Graphs/UptimeDaySummary.tsx +327 -0
- package/UI/Components/Header/Header.tsx +25 -9
- package/UI/Components/Header/IconDropdown/IconDropdownItem.tsx +10 -1
- package/UI/Components/Header/IconDropdown/IconDropdownMenu.tsx +6 -1
- package/UI/Components/Header/ProjectPicker/ProjectPicker.tsx +6 -1
- package/UI/Components/HeaderAlert/NotificationBell/NotificationBellDropdown.tsx +6 -1
- package/UI/Components/Icon/Icon.tsx +11 -0
- package/UI/Components/JSONTable/JSONTable.tsx +2 -2
- package/UI/Components/KeyboardShortcut/KeyboardShortcutsModal.tsx +125 -0
- package/UI/Components/KeyboardShortcut/Screenshots/README.md +19 -0
- package/UI/Components/KeyboardShortcut/Screenshots/keyboard-shortcuts-command-palette.png +0 -0
- package/UI/Components/KeyboardShortcut/Screenshots/keyboard-shortcuts-dialog-dark.png +0 -0
- package/UI/Components/KeyboardShortcut/Screenshots/keyboard-shortcuts-dialog.png +0 -0
- package/UI/Components/KeyboardShortcut/Screenshots/keyboard-shortcuts-help-menu.png +0 -0
- package/UI/Components/KeyboardShortcut/Screenshots/keyboard-shortcuts-narrow.png +0 -0
- package/UI/Components/ModelTable/Column.ts +15 -0
- package/UI/Components/Monitor/SeriesDebugCommandsViewer.tsx +64 -0
- package/UI/Components/Monitor/SeriesLabelsViewer.tsx +93 -0
- package/UI/Components/MonitorGraphs/Uptime.tsx +14 -2
- package/UI/Components/MonitorGraphs/UptimeBarDayModal.tsx +63 -10
- package/UI/Components/MonitorTemplateVariables/TemplateVariablesCatalog.ts +44 -0
- package/UI/Components/StatusPage/ResourceGroupSection.tsx +40 -0
- package/UI/Components/Table/CellClassName.ts +81 -0
- package/UI/Components/Table/TableRow.tsx +20 -14
- package/UI/Components/Table/TableSkeletonRows.tsx +9 -9
- package/UI/Components/Table/Types/Column.ts +36 -0
- package/UI/Components/Tooltip/Tooltip.tsx +11 -1
- package/UI/Components/Workflow/ComponentsModal.tsx +60 -39
- package/UI/Components/Workflow/NodePlacement.ts +57 -0
- package/UI/Components/Workflow/Workflow.tsx +47 -18
- package/UI/Config.ts +15 -33
- package/UI/Utils/GlobalKeyboardShortcut.ts +208 -0
- package/UI/Utils/Telemetry/BrowserTelemetryConfig.ts +28 -0
- package/UI/Utils/Telemetry/Telemetry.ts +10 -8
- package/UI/esbuild-config.js +6 -0
- package/Utils/API.ts +129 -3
- package/Utils/Dashboard/Components/DashboardMonitorListComponent.ts +12 -1
- package/Utils/Dashboard/LabelVariable.ts +152 -0
- package/Utils/Dashboard/VariableUrlState.ts +27 -5
- package/Utils/HTTPResponseBodyReader.ts +221 -0
- package/Utils/MetricUnitUtil.ts +34 -0
- package/Utils/Monitor/DeviceMacLearningUtil.ts +177 -0
- package/Utils/Monitor/MetricValueFormatter.ts +342 -0
- package/Utils/Monitor/MonitorTemplateCustomFieldUtil.ts +124 -0
- package/Utils/Monitor/NetworkDeviceMonitorTemplateUtil.ts +7 -2
- package/Utils/Monitor/NetworkTopologyUtil.ts +693 -0
- package/Utils/NetworkAutomation/AutoImportRunChain.ts +138 -0
- package/Utils/NetworkDiscovery/DiscoveryScanStatus.ts +77 -0
- package/Utils/Rum/ChunkMath.ts +106 -0
- package/Utils/Rum/SessionReplayHealth.ts +732 -0
- package/Utils/Rum/SessionReplayStringMap.ts +226 -0
- package/Utils/Schema/ModelSchema.ts +1 -0
- package/Utils/StatusPage/ResourceSearch.ts +290 -0
- package/Utils/Telemetry/OriginAllowList.ts +355 -0
- package/Utils/Uptime/DayUptimeGraphUtil.ts +205 -0
- package/Utils/ValueFormatter.ts +35 -1
- package/build/dist/Models/AnalyticsModels/RumSession.js +102 -19
- package/build/dist/Models/AnalyticsModels/RumSession.js.map +1 -1
- package/build/dist/Models/AnalyticsModels/RumSessionChunk.js +11 -9
- package/build/dist/Models/AnalyticsModels/RumSessionChunk.js.map +1 -1
- package/build/dist/Models/DatabaseModels/AlertCustomField.js +79 -3
- package/build/dist/Models/DatabaseModels/AlertCustomField.js.map +1 -1
- package/build/dist/Models/DatabaseModels/ApiKeyPermission.js +3 -27
- package/build/dist/Models/DatabaseModels/ApiKeyPermission.js.map +1 -1
- package/build/dist/Models/DatabaseModels/GlobalConfig.js +12 -12
- package/build/dist/Models/DatabaseModels/GlobalConfig.js.map +1 -1
- package/build/dist/Models/DatabaseModels/IncidentCustomField.js +79 -3
- package/build/dist/Models/DatabaseModels/IncidentCustomField.js.map +1 -1
- package/build/dist/Models/DatabaseModels/InventoryItem.js +34 -1
- package/build/dist/Models/DatabaseModels/InventoryItem.js.map +1 -1
- package/build/dist/Models/DatabaseModels/InventoryItemCustomField.js +79 -3
- package/build/dist/Models/DatabaseModels/InventoryItemCustomField.js.map +1 -1
- package/build/dist/Models/DatabaseModels/MonitorCustomField.js +79 -3
- package/build/dist/Models/DatabaseModels/MonitorCustomField.js.map +1 -1
- package/build/dist/Models/DatabaseModels/NetworkDevice.js +128 -0
- package/build/dist/Models/DatabaseModels/NetworkDevice.js.map +1 -1
- package/build/dist/Models/DatabaseModels/OnCallDutyPolicyCustomField.js +79 -3
- package/build/dist/Models/DatabaseModels/OnCallDutyPolicyCustomField.js.map +1 -1
- package/build/dist/Models/DatabaseModels/RumApplication.js +6 -6
- package/build/dist/Models/DatabaseModels/RumApplication.js.map +1 -1
- package/build/dist/Models/DatabaseModels/ScheduledMaintenanceCustomField.js +79 -3
- package/build/dist/Models/DatabaseModels/ScheduledMaintenanceCustomField.js.map +1 -1
- package/build/dist/Models/DatabaseModels/StatusPageCustomField.js +79 -3
- package/build/dist/Models/DatabaseModels/StatusPageCustomField.js.map +1 -1
- package/build/dist/Models/DatabaseModels/TeamCustomField.js +79 -3
- package/build/dist/Models/DatabaseModels/TeamCustomField.js.map +1 -1
- package/build/dist/Models/DatabaseModels/TeamMember.js +0 -9
- package/build/dist/Models/DatabaseModels/TeamMember.js.map +1 -1
- package/build/dist/Models/DatabaseModels/TeamMemberCustomField.js +79 -3
- package/build/dist/Models/DatabaseModels/TeamMemberCustomField.js.map +1 -1
- package/build/dist/Models/DatabaseModels/TeamPermission.js +3 -24
- package/build/dist/Models/DatabaseModels/TeamPermission.js.map +1 -1
- package/build/dist/Models/DatabaseModels/TelemetryIngestionKey.js +267 -0
- package/build/dist/Models/DatabaseModels/TelemetryIngestionKey.js.map +1 -1
- package/build/dist/Models/DatabaseModels/UserTelegram.js +0 -4
- package/build/dist/Models/DatabaseModels/UserTelegram.js.map +1 -1
- package/build/dist/Server/API/TelemetryAPI.js +769 -109
- package/build/dist/Server/API/TelemetryAPI.js.map +1 -1
- package/build/dist/Server/API/UserNotificationSettingAPI.js +35 -0
- package/build/dist/Server/API/UserNotificationSettingAPI.js.map +1 -0
- package/build/dist/Server/API/UserTelegramAPI.js +28 -6
- package/build/dist/Server/API/UserTelegramAPI.js.map +1 -1
- package/build/dist/Server/EnvironmentConfig.js +73 -14
- package/build/dist/Server/EnvironmentConfig.js.map +1 -1
- package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1791300000000-AddTelemetryIngestionKeyType.js +60 -0
- package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1791300000000-AddTelemetryIngestionKeyType.js.map +1 -0
- package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1791400000000-SessionReplayRecordEverySessionByDefault.js +53 -0
- package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1791400000000-SessionReplayRecordEverySessionByDefault.js.map +1 -0
- package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1791500000000-WidenCustomFieldDropdownOptions.js +82 -0
- package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1791500000000-WidenCustomFieldDropdownOptions.js.map +1 -0
- package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1791600000000-AddCustomFieldValueMapping.js +46 -0
- package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1791600000000-AddCustomFieldValueMapping.js.map +1 -0
- package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1791700000000-AddMacAddressToNetworkDevice.js +14 -0
- package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1791700000000-AddMacAddressToNetworkDevice.js.map +1 -0
- package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/Index.js +10 -0
- package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/Index.js.map +1 -1
- package/build/dist/Server/Infrastructure/QueueWorker.js +19 -7
- package/build/dist/Server/Infrastructure/QueueWorker.js.map +1 -1
- package/build/dist/Server/Infrastructure/Redis.js +8 -8
- package/build/dist/Server/Infrastructure/Redis.js.map +1 -1
- package/build/dist/Server/Infrastructure/Semaphore.js +1 -0
- package/build/dist/Server/Infrastructure/Semaphore.js.map +1 -1
- package/build/dist/Server/Infrastructure/Status.js +10 -4
- package/build/dist/Server/Infrastructure/Status.js.map +1 -1
- package/build/dist/Server/Middleware/TelemetryIngest.js +315 -8
- package/build/dist/Server/Middleware/TelemetryIngest.js.map +1 -1
- package/build/dist/Server/Services/AccessTokenService.js +1 -0
- package/build/dist/Server/Services/AccessTokenService.js.map +1 -1
- package/build/dist/Server/Services/AlertCustomFieldService.js +93 -0
- package/build/dist/Server/Services/AlertCustomFieldService.js.map +1 -1
- package/build/dist/Server/Services/AlertService.js +34 -0
- package/build/dist/Server/Services/AlertService.js.map +1 -1
- package/build/dist/Server/Services/ApiKeyPermissionService.js +331 -28
- package/build/dist/Server/Services/ApiKeyPermissionService.js.map +1 -1
- package/build/dist/Server/Services/CustomFieldMappingService.js +614 -0
- package/build/dist/Server/Services/CustomFieldMappingService.js.map +1 -0
- package/build/dist/Server/Services/DatabaseService.js +58 -13
- package/build/dist/Server/Services/DatabaseService.js.map +1 -1
- package/build/dist/Server/Services/GlobalConfigService.js +133 -0
- package/build/dist/Server/Services/GlobalConfigService.js.map +1 -1
- package/build/dist/Server/Services/IncidentCustomFieldService.js +93 -0
- package/build/dist/Server/Services/IncidentCustomFieldService.js.map +1 -1
- package/build/dist/Server/Services/IncidentService.js +32 -0
- package/build/dist/Server/Services/IncidentService.js.map +1 -1
- package/build/dist/Server/Services/InventoryItemService.js +28 -1
- package/build/dist/Server/Services/InventoryItemService.js.map +1 -1
- package/build/dist/Server/Services/MetricService.js +163 -0
- package/build/dist/Server/Services/MetricService.js.map +1 -1
- package/build/dist/Server/Services/MonitorService.js +29 -0
- package/build/dist/Server/Services/MonitorService.js.map +1 -1
- package/build/dist/Server/Services/MonitorTemplateService.js +116 -17
- package/build/dist/Server/Services/MonitorTemplateService.js.map +1 -1
- package/build/dist/Server/Services/NetworkDeviceAutoImportRuleEngineService.js +349 -64
- package/build/dist/Server/Services/NetworkDeviceAutoImportRuleEngineService.js.map +1 -1
- package/build/dist/Server/Services/NetworkDeviceDiscoveryScanService.js +65 -0
- package/build/dist/Server/Services/NetworkDeviceDiscoveryScanService.js.map +1 -1
- package/build/dist/Server/Services/NetworkDeviceService.js +54 -0
- package/build/dist/Server/Services/NetworkDeviceService.js.map +1 -1
- package/build/dist/Server/Services/ProjectService.js +22 -0
- package/build/dist/Server/Services/ProjectService.js.map +1 -1
- package/build/dist/Server/Services/RoutineEmailSettingsService.js +69 -0
- package/build/dist/Server/Services/RoutineEmailSettingsService.js.map +1 -0
- package/build/dist/Server/Services/RumSessionReplayViewService.js +86 -24
- package/build/dist/Server/Services/RumSessionReplayViewService.js.map +1 -1
- package/build/dist/Server/Services/ScheduledMaintenanceCustomFieldService.js +93 -0
- package/build/dist/Server/Services/ScheduledMaintenanceCustomFieldService.js.map +1 -1
- package/build/dist/Server/Services/ScheduledMaintenanceService.js +29 -0
- package/build/dist/Server/Services/ScheduledMaintenanceService.js.map +1 -1
- package/build/dist/Server/Services/TeamMemberService.js +62 -2
- package/build/dist/Server/Services/TeamMemberService.js.map +1 -1
- package/build/dist/Server/Services/TeamPermissionService.js +166 -3
- package/build/dist/Server/Services/TeamPermissionService.js.map +1 -1
- package/build/dist/Server/Services/TelemetryIngestionKeyService.js +562 -18
- package/build/dist/Server/Services/TelemetryIngestionKeyService.js.map +1 -1
- package/build/dist/Server/Services/UserNotificationRuleService.js +60 -25
- package/build/dist/Server/Services/UserNotificationRuleService.js.map +1 -1
- package/build/dist/Server/Services/UserNotificationSettingService.js +26 -6
- package/build/dist/Server/Services/UserNotificationSettingService.js.map +1 -1
- package/build/dist/Server/Services/UserTelegramService.js +257 -4
- package/build/dist/Server/Services/UserTelegramService.js.map +1 -1
- package/build/dist/Server/Types/Database/Permissions/ReadPermission.js +29 -4
- package/build/dist/Server/Types/Database/Permissions/ReadPermission.js.map +1 -1
- package/build/dist/Server/Types/Database/QueryHelper.js.map +1 -1
- package/build/dist/Server/Types/Database/QueryUtil.js +36 -0
- package/build/dist/Server/Types/Database/QueryUtil.js.map +1 -1
- package/build/dist/Server/Types/Markdown.js +75 -0
- package/build/dist/Server/Types/Markdown.js.map +1 -1
- package/build/dist/Server/Utils/APIKey/AccessPermission.js +2 -2
- package/build/dist/Server/Utils/APIKey/AccessPermission.js.map +1 -1
- package/build/dist/Server/Utils/CustomField/CustomFieldDefinitionMappingHooks.js +27 -0
- package/build/dist/Server/Utils/CustomField/CustomFieldDefinitionMappingHooks.js.map +1 -0
- package/build/dist/Server/Utils/CustomField/CustomFieldMappingRegistry.js +226 -0
- package/build/dist/Server/Utils/CustomField/CustomFieldMappingRegistry.js.map +1 -0
- package/build/dist/Server/Utils/CustomField/CustomFieldMappingValidator.js +189 -0
- package/build/dist/Server/Utils/CustomField/CustomFieldMappingValidator.js.map +1 -0
- package/build/dist/Server/Utils/Dashboard/PublicDashboardResourceListPolicy.js +53 -18
- package/build/dist/Server/Utils/Dashboard/PublicDashboardResourceListPolicy.js.map +1 -1
- package/build/dist/Server/Utils/DataSource/EgressGuard.js +121 -7
- package/build/dist/Server/Utils/DataSource/EgressGuard.js.map +1 -1
- package/build/dist/Server/Utils/EmailRollup/EmailRollupConstants.js +38 -5
- package/build/dist/Server/Utils/EmailRollup/EmailRollupConstants.js.map +1 -1
- package/build/dist/Server/Utils/EmailRollup/EmailRollupFlushRunner.js +54 -3
- package/build/dist/Server/Utils/EmailRollup/EmailRollupFlushRunner.js.map +1 -1
- package/build/dist/Server/Utils/EmailRollup/EmailRollupRenderer.js +2 -2
- package/build/dist/Server/Utils/EmailRollup/EmailRollupRenderer.js.map +1 -1
- package/build/dist/Server/Utils/FrontendEnvironment.js +33 -0
- package/build/dist/Server/Utils/FrontendEnvironment.js.map +1 -0
- package/build/dist/Server/Utils/LogRedaction.js +20 -0
- package/build/dist/Server/Utils/LogRedaction.js.map +1 -1
- package/build/dist/Server/Utils/Logger.js +10 -0
- package/build/dist/Server/Utils/Logger.js.map +1 -1
- package/build/dist/Server/Utils/Monitor/Criteria/CompareCriteria.js +323 -81
- package/build/dist/Server/Utils/Monitor/Criteria/CompareCriteria.js.map +1 -1
- package/build/dist/Server/Utils/Monitor/Criteria/IncomingRequestCriteria.js +20 -4
- package/build/dist/Server/Utils/Monitor/Criteria/IncomingRequestCriteria.js.map +1 -1
- package/build/dist/Server/Utils/Monitor/Criteria/MetricMonitorCriteria.js +29 -5
- package/build/dist/Server/Utils/Monitor/Criteria/MetricMonitorCriteria.js.map +1 -1
- package/build/dist/Server/Utils/Monitor/MonitorAlert.js +29 -6
- package/build/dist/Server/Utils/Monitor/MonitorAlert.js.map +1 -1
- package/build/dist/Server/Utils/Monitor/MonitorCriteriaEvaluator.js +254 -48
- package/build/dist/Server/Utils/Monitor/MonitorCriteriaEvaluator.js.map +1 -1
- package/build/dist/Server/Utils/Monitor/MonitorCriteriaExpectationBuilder.js +58 -9
- package/build/dist/Server/Utils/Monitor/MonitorCriteriaExpectationBuilder.js.map +1 -1
- package/build/dist/Server/Utils/Monitor/MonitorCriteriaMessageBuilder.js +9 -3
- package/build/dist/Server/Utils/Monitor/MonitorCriteriaMessageBuilder.js.map +1 -1
- package/build/dist/Server/Utils/Monitor/MonitorCriteriaMessageFormatter.js +26 -12
- package/build/dist/Server/Utils/Monitor/MonitorCriteriaMessageFormatter.js.map +1 -1
- package/build/dist/Server/Utils/Monitor/MonitorCriteriaObservationBuilder.js +74 -33
- package/build/dist/Server/Utils/Monitor/MonitorCriteriaObservationBuilder.js.map +1 -1
- package/build/dist/Server/Utils/Monitor/MonitorIncident.js +22 -6
- package/build/dist/Server/Utils/Monitor/MonitorIncident.js.map +1 -1
- package/build/dist/Server/Utils/Monitor/MonitorTemplateUtil.js +22 -0
- package/build/dist/Server/Utils/Monitor/MonitorTemplateUtil.js.map +1 -1
- package/build/dist/Server/Utils/Monitor/NetworkDeviceMacLearningUtil.js +114 -0
- package/build/dist/Server/Utils/Monitor/NetworkDeviceMacLearningUtil.js.map +1 -0
- package/build/dist/Server/Utils/Monitor/NetworkInventoryUtil.js +25 -0
- package/build/dist/Server/Utils/Monitor/NetworkInventoryUtil.js.map +1 -1
- package/build/dist/Server/Utils/Monitor/SeriesContextEnricher.js +237 -0
- package/build/dist/Server/Utils/Monitor/SeriesContextEnricher.js.map +1 -0
- package/build/dist/Server/Utils/SSRFProtection.js +136 -9
- package/build/dist/Server/Utils/SSRFProtection.js.map +1 -1
- package/build/dist/Server/Utils/SessionReplay/SessionReplayGateCache.js +174 -89
- package/build/dist/Server/Utils/SessionReplay/SessionReplayGateCache.js.map +1 -1
- package/build/dist/Server/Utils/SessionReplay/SessionReplayHealthCounters.js +223 -0
- package/build/dist/Server/Utils/SessionReplay/SessionReplayHealthCounters.js.map +1 -0
- package/build/dist/Server/Utils/SessionReplay/SessionReplayReadService.js +945 -164
- package/build/dist/Server/Utils/SessionReplay/SessionReplayReadService.js.map +1 -1
- package/build/dist/Server/Utils/StartServer.js +3 -14
- package/build/dist/Server/Utils/StartServer.js.map +1 -1
- package/build/dist/Server/Utils/TelegramVerificationToken.js +129 -0
- package/build/dist/Server/Utils/TelegramVerificationToken.js.map +1 -0
- package/build/dist/Server/Utils/Telemetry/EntityRegistry.js +9 -1
- package/build/dist/Server/Utils/Telemetry/EntityRegistry.js.map +1 -1
- package/build/dist/Server/Utils/Telemetry/PinServiceName.js +163 -0
- package/build/dist/Server/Utils/Telemetry/PinServiceName.js.map +1 -0
- package/build/dist/Server/Utils/Telemetry/TelemetryEntity.js +70 -13
- package/build/dist/Server/Utils/Telemetry/TelemetryEntity.js.map +1 -1
- package/build/dist/Server/Utils/Telemetry/TelemetryFanInWriter.js +28 -15
- package/build/dist/Server/Utils/Telemetry/TelemetryFanInWriter.js.map +1 -1
- package/build/dist/Server/Utils/Telemetry/TelemetryIngestionKeyGuard.js +64 -0
- package/build/dist/Server/Utils/Telemetry/TelemetryIngestionKeyGuard.js.map +1 -0
- package/build/dist/Server/Utils/Telemetry/TelemetryIngestionKeyRateLimiter.js +171 -0
- package/build/dist/Server/Utils/Telemetry/TelemetryIngestionKeyRateLimiter.js.map +1 -0
- package/build/dist/Server/Utils/VM/VMAPI.js.map +1 -1
- package/build/dist/Server/Utils/VM/VMRunner.js +780 -69
- package/build/dist/Server/Utils/VM/VMRunner.js.map +1 -1
- package/build/dist/Types/BaseDatabase/IncludesAnyOfGroups.js +54 -0
- package/build/dist/Types/BaseDatabase/IncludesAnyOfGroups.js.map +1 -0
- package/build/dist/Types/CustomField/CustomFieldMappingCatalog.js +60 -0
- package/build/dist/Types/CustomField/CustomFieldMappingCatalog.js.map +1 -0
- package/build/dist/Types/CustomField/CustomFieldMappingSourceResource.js +20 -0
- package/build/dist/Types/CustomField/CustomFieldMappingSourceResource.js.map +1 -0
- package/build/dist/Types/CustomField/CustomFieldValueMapping.js +141 -0
- package/build/dist/Types/CustomField/CustomFieldValueMapping.js.map +1 -0
- package/build/dist/Types/Dashboard/DashboardComponents/ComponentArgument.js +1 -0
- package/build/dist/Types/Dashboard/DashboardComponents/ComponentArgument.js.map +1 -1
- package/build/dist/Types/Dashboard/DashboardVariable.js +1 -0
- package/build/dist/Types/Dashboard/DashboardVariable.js.map +1 -1
- package/build/dist/Types/Icon/IconProp.js +1 -0
- package/build/dist/Types/Icon/IconProp.js.map +1 -1
- package/build/dist/Types/JSON.js +1 -0
- package/build/dist/Types/JSON.js.map +1 -1
- package/build/dist/Types/JSONFunctions.js +131 -37
- package/build/dist/Types/JSONFunctions.js.map +1 -1
- package/build/dist/Types/Monitor/CephAlertTemplates.js +130 -171
- package/build/dist/Types/Monitor/CephAlertTemplates.js.map +1 -1
- package/build/dist/Types/Monitor/DockerAlertTemplates.js +286 -121
- package/build/dist/Types/Monitor/DockerAlertTemplates.js.map +1 -1
- package/build/dist/Types/Monitor/DockerSwarmAlertTemplates.js +84 -105
- package/build/dist/Types/Monitor/DockerSwarmAlertTemplates.js.map +1 -1
- package/build/dist/Types/Monitor/HostAlertTemplates.js +250 -122
- package/build/dist/Types/Monitor/HostAlertTemplates.js.map +1 -1
- package/build/dist/Types/Monitor/IotAlertTemplates.js +81 -81
- package/build/dist/Types/Monitor/IotAlertTemplates.js.map +1 -1
- package/build/dist/Types/Monitor/KubernetesAlertTemplates.js +375 -215
- package/build/dist/Types/Monitor/KubernetesAlertTemplates.js.map +1 -1
- package/build/dist/Types/Monitor/KubernetesMetricCatalog.js +19 -19
- package/build/dist/Types/Monitor/KubernetesMetricCatalog.js.map +1 -1
- package/build/dist/Types/Monitor/PodmanAlertTemplates.js +104 -153
- package/build/dist/Types/Monitor/PodmanAlertTemplates.js.map +1 -1
- package/build/dist/Types/Monitor/ProxmoxAlertTemplates.js +156 -91
- package/build/dist/Types/Monitor/ProxmoxAlertTemplates.js.map +1 -1
- package/build/dist/Types/Monitor/Recommendation/MonitorRecommendationSeverityMapper.js +67 -6
- package/build/dist/Types/Monitor/Recommendation/MonitorRecommendationSeverityMapper.js.map +1 -1
- package/build/dist/Types/Monitor/Recommendation/MonitorRecommendationUtil.js +38 -7
- package/build/dist/Types/Monitor/Recommendation/MonitorRecommendationUtil.js.map +1 -1
- package/build/dist/Types/Monitor/Recommendation/RecommendationCriteriaBuilder.js +261 -0
- package/build/dist/Types/Monitor/Recommendation/RecommendationCriteriaBuilder.js.map +1 -0
- package/build/dist/Types/Monitor/RumAlertTemplates.js +46 -7
- package/build/dist/Types/Monitor/RumAlertTemplates.js.map +1 -1
- package/build/dist/Types/Monitor/SeriesContext/SeriesDebugHints.js +422 -0
- package/build/dist/Types/Monitor/SeriesContext/SeriesDebugHints.js.map +1 -0
- package/build/dist/Types/Monitor/SeriesContext/SeriesLabelDisplay.js +441 -0
- package/build/dist/Types/Monitor/SeriesContext/SeriesLabelDisplay.js.map +1 -0
- package/build/dist/Types/Monitor/ServiceAlertTemplates.js +79 -15
- package/build/dist/Types/Monitor/ServiceAlertTemplates.js.map +1 -1
- package/build/dist/Types/Monitor/UptimeHistoryLabels.js +17 -0
- package/build/dist/Types/Monitor/UptimeHistoryLabels.js.map +1 -0
- package/build/dist/Types/NetworkAutomation/RuleRunResult.js +291 -6
- package/build/dist/Types/NetworkAutomation/RuleRunResult.js.map +1 -1
- package/build/dist/Types/NotificationSetting/RoutineEmailEvents.js +29 -0
- package/build/dist/Types/NotificationSetting/RoutineEmailEvents.js.map +1 -0
- package/build/dist/Types/Rum/SessionReplay.js +117 -0
- package/build/dist/Types/Rum/SessionReplay.js.map +1 -1
- package/build/dist/Types/Rum/SessionReplayApi.js +181 -0
- package/build/dist/Types/Rum/SessionReplayApi.js.map +1 -0
- package/build/dist/Types/Rum/SessionReplayCaptureTrigger.js +21 -12
- package/build/dist/Types/Rum/SessionReplayCaptureTrigger.js.map +1 -1
- package/build/dist/Types/Rum/SessionReplayConsentMode.js +11 -7
- package/build/dist/Types/Rum/SessionReplayConsentMode.js.map +1 -1
- package/build/dist/Types/Rum/SessionReplayCustomEvents.js +172 -0
- package/build/dist/Types/Rum/SessionReplayCustomEvents.js.map +1 -0
- package/build/dist/Types/Rum/SessionReplayHealth.js +37 -0
- package/build/dist/Types/Rum/SessionReplayHealth.js.map +1 -0
- package/build/dist/Types/SerializableObjectDictionary.js +4 -0
- package/build/dist/Types/SerializableObjectDictionary.js.map +1 -1
- package/build/dist/Types/Telemetry/InventoryLiveness.js +37 -0
- package/build/dist/Types/Telemetry/InventoryLiveness.js.map +1 -0
- package/build/dist/Types/Telemetry/TelemetryIngestSurface.js +85 -0
- package/build/dist/Types/Telemetry/TelemetryIngestSurface.js.map +1 -0
- package/build/dist/Types/Telemetry/TelemetryIngestionKeyPolicy.js +15 -0
- package/build/dist/Types/Telemetry/TelemetryIngestionKeyPolicy.js.map +1 -0
- package/build/dist/Types/Telemetry/TelemetryIngestionKeyType.js +30 -0
- package/build/dist/Types/Telemetry/TelemetryIngestionKeyType.js.map +1 -0
- package/build/dist/Types/WebsiteRequest.js +55 -3
- package/build/dist/Types/WebsiteRequest.js.map +1 -1
- package/build/dist/UI/Components/CSVFileUpload/CSVFileUpload.js +7 -0
- package/build/dist/UI/Components/CSVFileUpload/CSVFileUpload.js.map +1 -1
- package/build/dist/UI/Components/Charts/Area/AreaChart.js +13 -2
- package/build/dist/UI/Components/Charts/Area/AreaChart.js.map +1 -1
- package/build/dist/UI/Components/Charts/Bar/BarChart.js +6 -2
- package/build/dist/UI/Components/Charts/Bar/BarChart.js.map +1 -1
- package/build/dist/UI/Components/Charts/Line/LineChart.js +13 -2
- package/build/dist/UI/Components/Charts/Line/LineChart.js.map +1 -1
- package/build/dist/UI/Components/Charts/Types/XAxis/XAxis.js.map +1 -1
- package/build/dist/UI/Components/Charts/Utils/DataPoint.js +15 -3
- package/build/dist/UI/Components/Charts/Utils/DataPoint.js.map +1 -1
- package/build/dist/UI/Components/Charts/Utils/TimeAnnotation.js +40 -9
- package/build/dist/UI/Components/Charts/Utils/TimeAnnotation.js.map +1 -1
- package/build/dist/UI/Components/Charts/Utils/XAxis.js +186 -0
- package/build/dist/UI/Components/Charts/Utils/XAxis.js.map +1 -1
- package/build/dist/UI/Components/CustomFields/CustomFieldsDetail.js +89 -8
- package/build/dist/UI/Components/CustomFields/CustomFieldsDetail.js.map +1 -1
- package/build/dist/UI/Components/CustomFields/MapFromCustomFieldInput.js +118 -0
- package/build/dist/UI/Components/CustomFields/MapFromCustomFieldInput.js.map +1 -0
- package/build/dist/UI/Components/Dashboard/DashboardVariableControl.js +137 -0
- package/build/dist/UI/Components/Dashboard/DashboardVariableControl.js.map +1 -0
- package/build/dist/UI/Components/Graphs/DayUptimeGraph.js +112 -7
- package/build/dist/UI/Components/Graphs/DayUptimeGraph.js.map +1 -1
- package/build/dist/UI/Components/Graphs/UptimeBarTooltip.js +5 -162
- package/build/dist/UI/Components/Graphs/UptimeBarTooltip.js.map +1 -1
- package/build/dist/UI/Components/Graphs/UptimeDaySummary.js +181 -0
- package/build/dist/UI/Components/Graphs/UptimeDaySummary.js.map +1 -0
- package/build/dist/UI/Components/Header/Header.js +2 -3
- package/build/dist/UI/Components/Header/Header.js.map +1 -1
- package/build/dist/UI/Components/Header/IconDropdown/IconDropdownItem.js +2 -1
- package/build/dist/UI/Components/Header/IconDropdown/IconDropdownItem.js.map +1 -1
- package/build/dist/UI/Components/Header/IconDropdown/IconDropdownMenu.js +7 -1
- package/build/dist/UI/Components/Header/IconDropdown/IconDropdownMenu.js.map +1 -1
- package/build/dist/UI/Components/Header/ProjectPicker/ProjectPicker.js +7 -1
- package/build/dist/UI/Components/Header/ProjectPicker/ProjectPicker.js.map +1 -1
- package/build/dist/UI/Components/HeaderAlert/NotificationBell/NotificationBellDropdown.js +7 -1
- package/build/dist/UI/Components/HeaderAlert/NotificationBell/NotificationBellDropdown.js.map +1 -1
- package/build/dist/UI/Components/Icon/Icon.js +5 -0
- package/build/dist/UI/Components/Icon/Icon.js.map +1 -1
- package/build/dist/UI/Components/JSONTable/JSONTable.js +2 -2
- package/build/dist/UI/Components/JSONTable/JSONTable.js.map +1 -1
- package/build/dist/UI/Components/KeyboardShortcut/KeyboardShortcutsModal.js +35 -0
- package/build/dist/UI/Components/KeyboardShortcut/KeyboardShortcutsModal.js.map +1 -0
- package/build/dist/UI/Components/Monitor/SeriesDebugCommandsViewer.js +34 -0
- package/build/dist/UI/Components/Monitor/SeriesDebugCommandsViewer.js.map +1 -0
- package/build/dist/UI/Components/Monitor/SeriesLabelsViewer.js +49 -0
- package/build/dist/UI/Components/Monitor/SeriesLabelsViewer.js.map +1 -0
- package/build/dist/UI/Components/MonitorGraphs/Uptime.js +1 -1
- package/build/dist/UI/Components/MonitorGraphs/Uptime.js.map +1 -1
- package/build/dist/UI/Components/MonitorGraphs/UptimeBarDayModal.js +32 -6
- package/build/dist/UI/Components/MonitorGraphs/UptimeBarDayModal.js.map +1 -1
- package/build/dist/UI/Components/MonitorTemplateVariables/TemplateVariablesCatalog.js +38 -0
- package/build/dist/UI/Components/MonitorTemplateVariables/TemplateVariablesCatalog.js.map +1 -1
- package/build/dist/UI/Components/StatusPage/ResourceGroupSection.js +22 -1
- package/build/dist/UI/Components/StatusPage/ResourceGroupSection.js.map +1 -1
- package/build/dist/UI/Components/Table/CellClassName.js +55 -0
- package/build/dist/UI/Components/Table/CellClassName.js.map +1 -0
- package/build/dist/UI/Components/Table/TableRow.js +16 -13
- package/build/dist/UI/Components/Table/TableRow.js.map +1 -1
- package/build/dist/UI/Components/Table/TableSkeletonRows.js +9 -8
- package/build/dist/UI/Components/Table/TableSkeletonRows.js.map +1 -1
- package/build/dist/UI/Components/Tooltip/Tooltip.js +25 -1
- package/build/dist/UI/Components/Tooltip/Tooltip.js.map +1 -1
- package/build/dist/UI/Components/Workflow/ComponentsModal.js +47 -30
- package/build/dist/UI/Components/Workflow/ComponentsModal.js.map +1 -1
- package/build/dist/UI/Components/Workflow/NodePlacement.js +37 -0
- package/build/dist/UI/Components/Workflow/NodePlacement.js.map +1 -0
- package/build/dist/UI/Components/Workflow/Workflow.js +35 -18
- package/build/dist/UI/Components/Workflow/Workflow.js.map +1 -1
- package/build/dist/UI/Config.js +10 -20
- package/build/dist/UI/Config.js.map +1 -1
- package/build/dist/UI/Utils/GlobalKeyboardShortcut.js +138 -0
- package/build/dist/UI/Utils/GlobalKeyboardShortcut.js.map +1 -0
- package/build/dist/UI/Utils/Telemetry/BrowserTelemetryConfig.js +14 -0
- package/build/dist/UI/Utils/Telemetry/BrowserTelemetryConfig.js.map +1 -0
- package/build/dist/UI/Utils/Telemetry/Telemetry.js +7 -5
- package/build/dist/UI/Utils/Telemetry/Telemetry.js.map +1 -1
- package/build/dist/Utils/API.js +67 -5
- package/build/dist/Utils/API.js.map +1 -1
- package/build/dist/Utils/Dashboard/Components/DashboardMonitorListComponent.js +9 -1
- package/build/dist/Utils/Dashboard/Components/DashboardMonitorListComponent.js.map +1 -1
- package/build/dist/Utils/Dashboard/LabelVariable.js +96 -0
- package/build/dist/Utils/Dashboard/LabelVariable.js.map +1 -0
- package/build/dist/Utils/Dashboard/VariableUrlState.js +19 -4
- package/build/dist/Utils/Dashboard/VariableUrlState.js.map +1 -1
- package/build/dist/Utils/HTTPResponseBodyReader.js +157 -0
- package/build/dist/Utils/HTTPResponseBodyReader.js.map +1 -0
- package/build/dist/Utils/MetricUnitUtil.js +26 -0
- package/build/dist/Utils/MetricUnitUtil.js.map +1 -1
- package/build/dist/Utils/Monitor/DeviceMacLearningUtil.js +112 -0
- package/build/dist/Utils/Monitor/DeviceMacLearningUtil.js.map +1 -0
- package/build/dist/Utils/Monitor/MetricValueFormatter.js +276 -0
- package/build/dist/Utils/Monitor/MetricValueFormatter.js.map +1 -0
- package/build/dist/Utils/Monitor/MonitorTemplateCustomFieldUtil.js +101 -0
- package/build/dist/Utils/Monitor/MonitorTemplateCustomFieldUtil.js.map +1 -0
- package/build/dist/Utils/Monitor/NetworkDeviceMonitorTemplateUtil.js +7 -2
- package/build/dist/Utils/Monitor/NetworkDeviceMonitorTemplateUtil.js.map +1 -1
- package/build/dist/Utils/Monitor/NetworkTopologyUtil.js +484 -0
- package/build/dist/Utils/Monitor/NetworkTopologyUtil.js.map +1 -1
- package/build/dist/Utils/NetworkAutomation/AutoImportRunChain.js +59 -0
- package/build/dist/Utils/NetworkAutomation/AutoImportRunChain.js.map +1 -0
- package/build/dist/Utils/NetworkDiscovery/DiscoveryScanStatus.js +69 -0
- package/build/dist/Utils/NetworkDiscovery/DiscoveryScanStatus.js.map +1 -0
- package/build/dist/Utils/Rum/ChunkMath.js +76 -0
- package/build/dist/Utils/Rum/ChunkMath.js.map +1 -1
- package/build/dist/Utils/Rum/SessionReplayHealth.js +534 -0
- package/build/dist/Utils/Rum/SessionReplayHealth.js.map +1 -0
- package/build/dist/Utils/Rum/SessionReplayStringMap.js +165 -0
- package/build/dist/Utils/Rum/SessionReplayStringMap.js.map +1 -0
- package/build/dist/Utils/Schema/ModelSchema.js +1 -0
- package/build/dist/Utils/Schema/ModelSchema.js.map +1 -1
- package/build/dist/Utils/StatusPage/ResourceSearch.js +200 -0
- package/build/dist/Utils/StatusPage/ResourceSearch.js.map +1 -0
- package/build/dist/Utils/Telemetry/OriginAllowList.js +299 -0
- package/build/dist/Utils/Telemetry/OriginAllowList.js.map +1 -0
- package/build/dist/Utils/Uptime/DayUptimeGraphUtil.js +147 -0
- package/build/dist/Utils/Uptime/DayUptimeGraphUtil.js.map +1 -0
- package/build/dist/Utils/ValueFormatter.js +32 -1
- package/build/dist/Utils/ValueFormatter.js.map +1 -1
- package/jest.config.json +2 -0
- package/package.json +1 -1
- package/test-setup.sh +9 -9
- package/tsconfig.json +51 -11
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
import API from "../../Utils/API/API";
|
|
2
|
+
import ModelAPI from "../../Utils/ModelAPI/ModelAPI";
|
|
3
|
+
import ComponentLoader from "../ComponentLoader/ComponentLoader";
|
|
4
|
+
import Dropdown from "../Dropdown/Dropdown";
|
|
5
|
+
import ErrorMessage from "../ErrorMessage/ErrorMessage";
|
|
6
|
+
import { LIMIT_PER_PROJECT } from "../../../Types/Database/LimitMax";
|
|
7
|
+
import React, { useEffect, useState, } from "react";
|
|
8
|
+
const MapFromCustomFieldInput = (props) => {
|
|
9
|
+
const [sourceFields, setSourceFields] = useState([]);
|
|
10
|
+
const [isLoading, setIsLoading] = useState(true);
|
|
11
|
+
const [loadError, setLoadError] = useState("");
|
|
12
|
+
const [selectedValue, setSelectedValue] = useState(props.initialValue || "");
|
|
13
|
+
const sourceModelName = props.sourceDefinitionModelType.name;
|
|
14
|
+
useEffect(() => {
|
|
15
|
+
let isMounted = true;
|
|
16
|
+
const load = async () => {
|
|
17
|
+
try {
|
|
18
|
+
setIsLoading(true);
|
|
19
|
+
setLoadError("");
|
|
20
|
+
const result = await ModelAPI.getList({
|
|
21
|
+
modelType: props.sourceDefinitionModelType,
|
|
22
|
+
query: {
|
|
23
|
+
projectId: props.projectId,
|
|
24
|
+
},
|
|
25
|
+
limit: LIMIT_PER_PROJECT,
|
|
26
|
+
skip: 0,
|
|
27
|
+
select: {
|
|
28
|
+
name: true,
|
|
29
|
+
customFieldType: true,
|
|
30
|
+
},
|
|
31
|
+
sort: {},
|
|
32
|
+
});
|
|
33
|
+
if (!isMounted) {
|
|
34
|
+
return;
|
|
35
|
+
}
|
|
36
|
+
setSourceFields(result.data.map((item) => {
|
|
37
|
+
return {
|
|
38
|
+
name: item["name"],
|
|
39
|
+
customFieldType: item["customFieldType"],
|
|
40
|
+
};
|
|
41
|
+
}));
|
|
42
|
+
setIsLoading(false);
|
|
43
|
+
}
|
|
44
|
+
catch (err) {
|
|
45
|
+
if (!isMounted) {
|
|
46
|
+
return;
|
|
47
|
+
}
|
|
48
|
+
setIsLoading(false);
|
|
49
|
+
setLoadError(API.getFriendlyMessage(err));
|
|
50
|
+
}
|
|
51
|
+
};
|
|
52
|
+
load().catch(() => {
|
|
53
|
+
// load() reports its own failures through loadError.
|
|
54
|
+
});
|
|
55
|
+
return () => {
|
|
56
|
+
isMounted = false;
|
|
57
|
+
};
|
|
58
|
+
/*
|
|
59
|
+
* The source list is per-project and per-source-table; neither changes
|
|
60
|
+
* while this input is mounted. The type filter below is applied on each
|
|
61
|
+
* render instead, so choosing a different field type re-filters without a
|
|
62
|
+
* refetch.
|
|
63
|
+
*/
|
|
64
|
+
}, [props.projectId.toString(), sourceModelName]);
|
|
65
|
+
const options = sourceFields
|
|
66
|
+
.filter((field) => {
|
|
67
|
+
if (!field.name) {
|
|
68
|
+
return false;
|
|
69
|
+
}
|
|
70
|
+
/*
|
|
71
|
+
* With no type chosen yet there is nothing to be compatible with, so
|
|
72
|
+
* offer nothing rather than a list that will be rejected on save.
|
|
73
|
+
*/
|
|
74
|
+
if (!props.targetFieldType) {
|
|
75
|
+
return false;
|
|
76
|
+
}
|
|
77
|
+
return field.customFieldType === props.targetFieldType;
|
|
78
|
+
})
|
|
79
|
+
.map((field) => {
|
|
80
|
+
return { label: field.name, value: field.name };
|
|
81
|
+
});
|
|
82
|
+
const isSelectedValueOffered = options.some((option) => {
|
|
83
|
+
return option.value === selectedValue;
|
|
84
|
+
});
|
|
85
|
+
if (selectedValue && !isSelectedValueOffered) {
|
|
86
|
+
options.unshift({
|
|
87
|
+
label: `${selectedValue} (no longer available on ${props.sourceTitle})`,
|
|
88
|
+
value: selectedValue,
|
|
89
|
+
});
|
|
90
|
+
}
|
|
91
|
+
if (isLoading) {
|
|
92
|
+
return React.createElement(ComponentLoader, null);
|
|
93
|
+
}
|
|
94
|
+
if (loadError) {
|
|
95
|
+
return React.createElement(ErrorMessage, { message: loadError });
|
|
96
|
+
}
|
|
97
|
+
if (!props.targetFieldType) {
|
|
98
|
+
return (React.createElement(ErrorMessage, { message: "Choose a field type above before picking the field to map from." }));
|
|
99
|
+
}
|
|
100
|
+
if (options.length === 0) {
|
|
101
|
+
return (React.createElement(ErrorMessage, { message: `No ${props.sourceTitle} custom field of this type exists in this project. Create one first, or choose a different field type.` }));
|
|
102
|
+
}
|
|
103
|
+
return (React.createElement(Dropdown, { options: options, value: options.find((option) => {
|
|
104
|
+
return option.value === selectedValue;
|
|
105
|
+
}), tabIndex: props.tabIndex, error: props.error, placeholder: `Select a ${props.sourceTitle} custom field`, onBlur: () => {
|
|
106
|
+
if (props.onBlur) {
|
|
107
|
+
props.onBlur();
|
|
108
|
+
}
|
|
109
|
+
}, onChange: (value) => {
|
|
110
|
+
const nextValue = value ? value.toString() : "";
|
|
111
|
+
setSelectedValue(nextValue);
|
|
112
|
+
if (props.onChange) {
|
|
113
|
+
props.onChange(nextValue);
|
|
114
|
+
}
|
|
115
|
+
} }));
|
|
116
|
+
};
|
|
117
|
+
export default MapFromCustomFieldInput;
|
|
118
|
+
//# sourceMappingURL=MapFromCustomFieldInput.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MapFromCustomFieldInput.js","sourceRoot":"","sources":["../../../../../UI/Components/CustomFields/MapFromCustomFieldInput.tsx"],"names":[],"mappings":"AAAA,OAAO,GAAG,MAAM,qBAAqB,CAAC;AACtC,OAAO,QAAwB,MAAM,+BAA+B,CAAC;AACrE,OAAO,eAAe,MAAM,oCAAoC,CAAC;AACjE,OAAO,QAA2C,MAAM,sBAAsB,CAAC;AAC/E,OAAO,YAAY,MAAM,8BAA8B,CAAC;AAKxD,OAAO,EAAE,iBAAiB,EAAE,MAAM,kCAAkC,CAAC;AAErE,OAAO,KAAK,EAAE,EAGZ,SAAS,EACT,QAAQ,GACT,MAAM,OAAO,CAAC;AA2Cf,MAAM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,EAAE,CAAC;YAExD,gBAAgB,CAAC,SAAS,CAAC,CAAC;YAE5B,IAAI,KAAK,CAAC,QAAQ,EAAE,CAAC;gBACnB,KAAK,CAAC,QAAQ,CAAC,SAAS,CAAC,CAAC;YAC5B,CAAC;QACH,CAAC,GACD,CACH,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,uBAAuB,CAAC"}
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
import React, { useEffect, useRef, useState, } from "react";
|
|
2
|
+
import { DashboardVariableType, } from "../../../Types/Dashboard/DashboardVariable";
|
|
3
|
+
const MultiSelectPopover = ({ options, selected, label, isLoading, maxSelections, unavailableLabel, onChange, }) => {
|
|
4
|
+
var _a;
|
|
5
|
+
const [open, setOpen] = useState(false);
|
|
6
|
+
const wrapRef = useRef(null);
|
|
7
|
+
useEffect(() => {
|
|
8
|
+
if (!open) {
|
|
9
|
+
return undefined;
|
|
10
|
+
}
|
|
11
|
+
const onDocClick = (e) => {
|
|
12
|
+
if (wrapRef.current && !wrapRef.current.contains(e.target)) {
|
|
13
|
+
setOpen(false);
|
|
14
|
+
}
|
|
15
|
+
};
|
|
16
|
+
document.addEventListener("mousedown", onDocClick);
|
|
17
|
+
return () => {
|
|
18
|
+
document.removeEventListener("mousedown", onDocClick);
|
|
19
|
+
};
|
|
20
|
+
}, [open]);
|
|
21
|
+
const buttonText = selected.length === 0
|
|
22
|
+
? isLoading
|
|
23
|
+
? "Loading…"
|
|
24
|
+
: "All"
|
|
25
|
+
: selected.length === 1
|
|
26
|
+
? ((_a = options.find((option) => {
|
|
27
|
+
return option.value === selected[0];
|
|
28
|
+
})) === null || _a === void 0 ? void 0 : _a.label) ||
|
|
29
|
+
unavailableLabel ||
|
|
30
|
+
selected[0]
|
|
31
|
+
: `${selected.length} selected`;
|
|
32
|
+
const toggle = (value) => {
|
|
33
|
+
if (selected.includes(value)) {
|
|
34
|
+
onChange(selected.filter((v) => {
|
|
35
|
+
return v !== value;
|
|
36
|
+
}));
|
|
37
|
+
}
|
|
38
|
+
else {
|
|
39
|
+
onChange([...selected, value]);
|
|
40
|
+
}
|
|
41
|
+
};
|
|
42
|
+
return (React.createElement("div", { className: "relative", ref: wrapRef },
|
|
43
|
+
React.createElement("button", { type: "button", className: "text-xs border border-gray-200 rounded-md px-2.5 py-1.5 bg-white text-gray-700 hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-blue-100 focus:border-blue-300 transition-colors flex items-center gap-1", disabled: isLoading, onClick: () => {
|
|
44
|
+
setOpen(!open);
|
|
45
|
+
}, title: label, "aria-label": `${label}: ${buttonText}`, "aria-expanded": open },
|
|
46
|
+
React.createElement("span", { className: "truncate max-w-[10rem]" }, buttonText),
|
|
47
|
+
React.createElement("span", { className: "text-gray-400" }, "\u25BE")),
|
|
48
|
+
open && (React.createElement("div", { className: "absolute z-30 mt-1 right-0 w-56 max-h-72 overflow-auto rounded-md border border-gray-200 bg-white shadow-lg py-1" },
|
|
49
|
+
React.createElement("div", { className: "flex items-center justify-between px-3 py-1.5 border-b border-gray-100 text-[11px] text-gray-500" },
|
|
50
|
+
React.createElement("span", null,
|
|
51
|
+
selected.length,
|
|
52
|
+
" selected"),
|
|
53
|
+
React.createElement("button", { type: "button", className: "text-blue-600 hover:underline disabled:text-gray-300", disabled: selected.length === 0, onClick: () => {
|
|
54
|
+
onChange([]);
|
|
55
|
+
} }, "Clear")),
|
|
56
|
+
maxSelections !== undefined && selected.length >= maxSelections && (React.createElement("p", { className: "px-3 py-1 text-xs text-gray-500" },
|
|
57
|
+
"Choose up to ",
|
|
58
|
+
maxSelections,
|
|
59
|
+
" labels.")),
|
|
60
|
+
options.length === 0 ? (React.createElement("div", { className: "px-3 py-2 text-xs text-gray-400" }, isLoading ? "Loading options…" : "No options available")) : (options.map((option) => {
|
|
61
|
+
const checked = selected.includes(option.value);
|
|
62
|
+
return (React.createElement("label", { key: option.value, className: "flex items-center gap-2 px-3 py-1.5 text-xs text-gray-700 hover:bg-gray-50 cursor-pointer" },
|
|
63
|
+
React.createElement("input", { type: "checkbox", className: "h-3.5 w-3.5", checked: checked, disabled: !checked &&
|
|
64
|
+
maxSelections !== undefined &&
|
|
65
|
+
selected.length >= maxSelections, onChange: () => {
|
|
66
|
+
toggle(option.value);
|
|
67
|
+
} }),
|
|
68
|
+
React.createElement("span", { className: "truncate" }, option.label)));
|
|
69
|
+
}))))));
|
|
70
|
+
};
|
|
71
|
+
const DashboardVariableControl = (props) => {
|
|
72
|
+
var _a, _b, _c, _d, _e, _f;
|
|
73
|
+
const { variable } = props;
|
|
74
|
+
const isTelemetryAttribute = variable.type === DashboardVariableType.TelemetryAttribute;
|
|
75
|
+
const isCustomList = variable.type === DashboardVariableType.CustomList ||
|
|
76
|
+
Boolean(variable.customListValues);
|
|
77
|
+
const customListOptions = variable.customListValues
|
|
78
|
+
? variable.customListValues.split(",").map((v) => {
|
|
79
|
+
return v.trim();
|
|
80
|
+
})
|
|
81
|
+
: [];
|
|
82
|
+
const isProjectLabel = variable.type === DashboardVariableType.ProjectLabel;
|
|
83
|
+
const options = isProjectLabel
|
|
84
|
+
? variable.labelOptions || []
|
|
85
|
+
: (isTelemetryAttribute
|
|
86
|
+
? props.dynamicOptions || []
|
|
87
|
+
: customListOptions).map((value) => {
|
|
88
|
+
return { label: value, value };
|
|
89
|
+
});
|
|
90
|
+
const selectedValue = (_b = (_a = variable.selectedValue) !== null && _a !== void 0 ? _a : variable.defaultValue) !== null && _b !== void 0 ? _b : "";
|
|
91
|
+
const isUnavailableSelection = Boolean(isProjectLabel &&
|
|
92
|
+
selectedValue &&
|
|
93
|
+
!options.some((option) => {
|
|
94
|
+
return option.value === selectedValue;
|
|
95
|
+
}));
|
|
96
|
+
const useSelect = isTelemetryAttribute || isCustomList || isProjectLabel;
|
|
97
|
+
const label = variable.label || variable.name;
|
|
98
|
+
return (React.createElement("div", { className: "flex items-center gap-1.5" },
|
|
99
|
+
React.createElement("label", { className: "text-xs font-medium text-gray-400 uppercase tracking-wide" }, label),
|
|
100
|
+
useSelect && variable.isMultiSelect ? (
|
|
101
|
+
/*
|
|
102
|
+
* `selectedValues` only — never defaultValue. The popover renders
|
|
103
|
+
* "All" for an empty list, and DashboardVariableInterpolation
|
|
104
|
+
* resolves an empty list to no predicate, so the two agree. Seeding
|
|
105
|
+
* this from defaultValue would put a filter behind a control that
|
|
106
|
+
* reads "All".
|
|
107
|
+
*/
|
|
108
|
+
React.createElement(MultiSelectPopover, { options: options, selected: variable.selectedValues || [], label: label, isLoading: Boolean(props.isLoadingOptions), maxSelections: isProjectLabel ? 100 : undefined, unavailableLabel: isProjectLabel ? "Unavailable label" : undefined, onChange: (next) => {
|
|
109
|
+
props.onVariableValueChange(variable.id, { selectedValues: next });
|
|
110
|
+
} })) : useSelect ? (React.createElement("select", { "aria-label": label, className: "text-xs border border-gray-200 rounded-md px-2.5 py-1.5 bg-white text-gray-700 focus:outline-none focus:ring-2 focus:ring-blue-100 focus:border-blue-300 transition-colors",
|
|
111
|
+
/*
|
|
112
|
+
* `??`, not `||`: picking "All" stores selectedValue as "", which is
|
|
113
|
+
* a real selection and must not collapse back to defaultValue. Only
|
|
114
|
+
* an unset (undefined) selection falls through to the default — the
|
|
115
|
+
* same rule the query side applies in
|
|
116
|
+
* Common/Utils/Dashboard/VariableInterpolation.ts, so what the
|
|
117
|
+
* toolbar shows and what the widgets are filtered by stay in step.
|
|
118
|
+
*/
|
|
119
|
+
value: (_d = (_c = variable.selectedValue) !== null && _c !== void 0 ? _c : variable.defaultValue) !== null && _d !== void 0 ? _d : "", disabled: props.isLoadingOptions, onChange: (e) => {
|
|
120
|
+
props.onVariableValueChange(variable.id, {
|
|
121
|
+
selectedValue: e.target.value,
|
|
122
|
+
});
|
|
123
|
+
} },
|
|
124
|
+
React.createElement("option", { value: "" }, props.isLoadingOptions ? "Loading…" : "All"),
|
|
125
|
+
isUnavailableSelection && (React.createElement("option", { value: selectedValue }, "Unavailable label")),
|
|
126
|
+
options.map((option) => {
|
|
127
|
+
return (React.createElement("option", { key: option.value, value: option.value }, option.label));
|
|
128
|
+
}))) : (React.createElement("input", { type: "text", "aria-label": label, className: "text-xs border border-gray-200 rounded-md px-2.5 py-1.5 bg-white text-gray-700 w-28 focus:outline-none focus:ring-2 focus:ring-blue-100 focus:border-blue-300 transition-colors",
|
|
129
|
+
// `??` so clearing the box stays cleared. See the select above.
|
|
130
|
+
value: (_f = (_e = variable.selectedValue) !== null && _e !== void 0 ? _e : variable.defaultValue) !== null && _f !== void 0 ? _f : "", placeholder: variable.name, onChange: (e) => {
|
|
131
|
+
props.onVariableValueChange(variable.id, {
|
|
132
|
+
selectedValue: e.target.value,
|
|
133
|
+
});
|
|
134
|
+
} }))));
|
|
135
|
+
};
|
|
136
|
+
export default DashboardVariableControl;
|
|
137
|
+
//# sourceMappingURL=DashboardVariableControl.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DashboardVariableControl.js","sourceRoot":"","sources":["../../../../../UI/Components/Dashboard/DashboardVariableControl.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAGZ,SAAS,EACT,MAAM,EACN,QAAQ,GACT,MAAM,OAAO,CAAC;AACf,OAA0B,EACxB,qBAAqB,GAEtB,MAAM,4CAA4C,CAAC;AAiBpD,MAAM,kBAAkB,GAQnB,CAAC,EACJ,OAAO,EACP,QAAQ,EACR,KAAK,EACL,SAAS,EACT,aAAa,EACb,gBAAgB,EAChB,QAAQ,GAST,EAAgB,EAAE;;IACjB,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,GAAG,QAAQ,CAAU,KAAK,CAAC,CAAC;IACjD,MAAM,OAAO,GAAoC,MAAM,CAAiB,IAAI,CAAC,CAAC;IAE9E,SAAS,CAAC,GAAG,EAAE;QACb,IAAI,CAAC,IAAI,EAAE,CAAC;YACV,OAAO,SAAS,CAAC;QACnB,CAAC;QACD,MAAM,UAAU,GAA4B,CAAC,CAAa,EAAQ,EAAE;YAClE,IAAI,OAAO,CAAC,OAAO,IA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ACP,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,wBAAwB,CAAC"}
|
|
@@ -2,12 +2,64 @@ import Tooltip from "../Tooltip/Tooltip";
|
|
|
2
2
|
import UptimeBarTooltip from "./UptimeBarTooltip";
|
|
3
3
|
import { Green } from "../../../Types/BrandColors";
|
|
4
4
|
import OneUptimeDate from "../../../Types/Date";
|
|
5
|
-
import
|
|
5
|
+
import DayUptimeGraphUtil from "../../../Utils/Uptime/DayUptimeGraphUtil";
|
|
6
|
+
import React, { useEffect, useRef, useState, } from "react";
|
|
6
7
|
const DayUptimeGraph = (props) => {
|
|
7
8
|
const [days, setDays] = useState(0);
|
|
9
|
+
/*
|
|
10
|
+
* The strip is one tab stop with a roving tabindex inside it - see
|
|
11
|
+
* DayUptimeGraphUtil. null means "nothing focused yet", which resolves to
|
|
12
|
+
* today rather than to three months ago.
|
|
13
|
+
*/
|
|
14
|
+
const [focusedBarIndex, setFocusedBarIndex] = useState(null);
|
|
15
|
+
const barRefs = useRef([]);
|
|
16
|
+
/*
|
|
17
|
+
* Set only by a key press, so that moving focus is a thing the widget does
|
|
18
|
+
* in response to the keyboard and never a thing it does to a visitor who
|
|
19
|
+
* simply clicked. Focus is applied in an effect rather than in the handler
|
|
20
|
+
* because the bar the visitor is moving to may not be the same DOM node
|
|
21
|
+
* after the render that the key press causes.
|
|
22
|
+
*/
|
|
23
|
+
const shouldRestoreFocus = useRef(false);
|
|
24
|
+
useEffect(() => {
|
|
25
|
+
var _a;
|
|
26
|
+
if (!shouldRestoreFocus.current) {
|
|
27
|
+
return;
|
|
28
|
+
}
|
|
29
|
+
shouldRestoreFocus.current = false;
|
|
30
|
+
if (focusedBarIndex === null) {
|
|
31
|
+
return;
|
|
32
|
+
}
|
|
33
|
+
(_a = barRefs.current[focusedBarIndex]) === null || _a === void 0 ? void 0 : _a.focus();
|
|
34
|
+
}, [focusedBarIndex]);
|
|
8
35
|
useEffect(() => {
|
|
9
36
|
setDays(OneUptimeDate.getNumberOfDaysBetweenDatesInclusive(props.startDate, props.endDate));
|
|
10
37
|
}, [props.startDate, props.endDate]);
|
|
38
|
+
const activeBarIndex = DayUptimeGraphUtil.getActiveBarIndex({
|
|
39
|
+
storedIndex: focusedBarIndex,
|
|
40
|
+
barCount: days,
|
|
41
|
+
});
|
|
42
|
+
const moveFocus = (event, index) => {
|
|
43
|
+
var _a;
|
|
44
|
+
const nextIndex = DayUptimeGraphUtil.getNextFocusIndex({
|
|
45
|
+
key: event.key,
|
|
46
|
+
currentIndex: index,
|
|
47
|
+
barCount: days,
|
|
48
|
+
});
|
|
49
|
+
if (nextIndex === null) {
|
|
50
|
+
// Not ours: Tab, Enter and Space must keep their normal meaning.
|
|
51
|
+
return;
|
|
52
|
+
}
|
|
53
|
+
event.preventDefault();
|
|
54
|
+
shouldRestoreFocus.current = true;
|
|
55
|
+
setFocusedBarIndex(nextIndex);
|
|
56
|
+
/*
|
|
57
|
+
* Focused here as well as in the effect: when the strip does not re-render
|
|
58
|
+
* (the index it was already on), the effect does not run, and focus must
|
|
59
|
+
* still land somewhere real.
|
|
60
|
+
*/
|
|
61
|
+
(_a = barRefs.current[nextIndex]) === null || _a === void 0 ? void 0 : _a.focus();
|
|
62
|
+
};
|
|
11
63
|
const getIncidentsForDay = (startOfDay, endOfDay) => {
|
|
12
64
|
if (!props.incidents || props.incidents.length === 0) {
|
|
13
65
|
return [];
|
|
@@ -116,14 +168,59 @@ const DayUptimeGraph = (props) => {
|
|
|
116
168
|
isDowntime: downtimeStatusIds.includes(key),
|
|
117
169
|
});
|
|
118
170
|
}
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
171
|
+
/*
|
|
172
|
+
* Every day opens, not only the days that happen to carry an incident.
|
|
173
|
+
* The uptime reading and the status breakdown used to live in a hover
|
|
174
|
+
* tooltip and nowhere else, which put them out of reach of every phone
|
|
175
|
+
* and every keyboard - and a phone is how most people read a status page
|
|
176
|
+
* during an outage.
|
|
177
|
+
*/
|
|
178
|
+
const isClickable = Boolean(props.onBarClick);
|
|
179
|
+
const summary = {
|
|
180
|
+
date: todaysDay,
|
|
181
|
+
uptimePercent: uptimePercentForTheDay,
|
|
182
|
+
hasEvents: hasEvents,
|
|
183
|
+
statusDurations: statusDurations,
|
|
184
|
+
incidents: dayIncidents,
|
|
185
|
+
};
|
|
186
|
+
const ariaLabel = DayUptimeGraphUtil.getDayAriaLabel({
|
|
187
|
+
dateLabel: OneUptimeDate.getDateAsUserFriendlyLocalFormattedString(todaysDay, true),
|
|
188
|
+
hasEvents: hasEvents,
|
|
189
|
+
uptimePercent: uptimePercentForTheDay,
|
|
190
|
+
incidentCount: dayIncidents.length,
|
|
191
|
+
labels: props.labels,
|
|
192
|
+
});
|
|
193
|
+
return (React.createElement(Tooltip, { key: dayNumber, richContent: React.createElement(UptimeBarTooltip, { date: todaysDay, uptimePercent: uptimePercentForTheDay, hasEvents: hasEvents, statusDurations: statusDurations, incidents: dayIncidents, onIncidentClick: props.onIncidentClick, labels: props.labels }) },
|
|
194
|
+
React.createElement("button", { type: "button", ref: (element) => {
|
|
195
|
+
barRefs.current[dayNumber] = element;
|
|
196
|
+
}, "data-testid": "uptime-bar", "data-day-index": dayNumber, "aria-label": ariaLabel,
|
|
197
|
+
/*
|
|
198
|
+
* One tab stop for the whole strip. Ninety bars per resource across
|
|
199
|
+
* a page of resources would otherwise bury the footer behind
|
|
200
|
+
* thousands of Tab presses.
|
|
201
|
+
*/
|
|
202
|
+
tabIndex: DayUptimeGraphUtil.getBarTabIndex({
|
|
203
|
+
index: dayNumber,
|
|
204
|
+
activeIndex: activeBarIndex,
|
|
205
|
+
}),
|
|
206
|
+
/*
|
|
207
|
+
* The focus indicator is drawn *inside* the bar (a negative outline
|
|
208
|
+
* offset), not around it. Callers wrap this strip in an
|
|
209
|
+
* overflow-x-auto scroller so it can be swiped on a phone, and
|
|
210
|
+
* overflow-x also clips vertically - anything drawn outside the
|
|
211
|
+
* bar's own box loses its top and bottom edge to that scroller. Two
|
|
212
|
+
* pixels of indigo inside a seven pixel bar reads clearly against
|
|
213
|
+
* every bar colour and cannot be clipped by anything.
|
|
214
|
+
*/
|
|
215
|
+
className: `${className} relative block p-0 border-0 appearance-none focus:outline-none focus-visible:z-10 focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-[-2px] focus-visible:outline-indigo-600${isClickable ? " cursor-pointer hover:opacity-80" : ""}`, style: {
|
|
123
216
|
backgroundColor: color.toString(),
|
|
217
|
+
}, onFocus: () => {
|
|
218
|
+
setFocusedBarIndex(dayNumber);
|
|
219
|
+
}, onKeyDown: (event) => {
|
|
220
|
+
moveFocus(event, dayNumber);
|
|
124
221
|
}, onClick: isClickable
|
|
125
222
|
? () => {
|
|
126
|
-
props.onBarClick(todaysDay, dayIncidents);
|
|
223
|
+
props.onBarClick(todaysDay, dayIncidents, summary);
|
|
127
224
|
}
|
|
128
225
|
: undefined })));
|
|
129
226
|
};
|
|
@@ -134,7 +231,15 @@ const DayUptimeGraph = (props) => {
|
|
|
134
231
|
}
|
|
135
232
|
return elements;
|
|
136
233
|
};
|
|
137
|
-
|
|
234
|
+
/*
|
|
235
|
+
* Deliberately not overflow-hidden any more: it clipped the focus ring of
|
|
236
|
+
* the first and last bar, which is the one part of this widget a keyboard
|
|
237
|
+
* user has to be able to see.
|
|
238
|
+
*/
|
|
239
|
+
return (React.createElement("div", { className: "flex space-x-0.5 rounded", role: "group", "aria-label": DayUptimeGraphUtil.getGraphAriaLabel({
|
|
240
|
+
dayCount: days,
|
|
241
|
+
labels: props.labels,
|
|
242
|
+
}), "data-testid": "day-uptime-graph" }, getUptimeGraph()));
|
|
138
243
|
};
|
|
139
244
|
export default DayUptimeGraph;
|
|
140
245
|
//# sourceMappingURL=DayUptimeGraph.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DayUptimeGraph.js","sourceRoot":"","sources":["../../../../../UI/Components/Graphs/DayUptimeGraph.tsx"],"names":[],"mappings":"AAAA,OAAO,OAAO,M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C;oBACtD,CAAC;oBACH,CAAC,CAAC,SAAS,GAEf,CACM,CACX,CAAC;IACJ,CAAC,CAAC;IAIF,MAAM,cAAc,GAA2B,GAAwB,EAAE;QACvE,MAAM,QAAQ,GAAwB,EAAE,CAAC;QAEzC,KAAK,IAAI,CAAC,GAAW,CAAC,EAAE,CAAC,GAAG,IAAI,EAAE,CAAC,EAAE,EAAE,CAAC;YACtC,QAAQ,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC,CAAC,CAAC,CAAC;QACjC,CAAC;QAED,OAAO,QAAQ,CAAC;IAClB,CAAC,CAAC;IAEF;;;;OAIG;IACH,OAAO,CACL,6BACE,SAAS,EAAC,0BAA0B,EACpC,IAAI,EAAC,OAAO,gBACA,kBAAkB,CAAC,iBAAiB,CAAC;YAC/C,QAAQ,EAAE,IAAI;YACd,MAAM,EAAE,KAAK,CAAC,MAAM;SACrB,CAAC,iBACU,kBAAkB,IAE7B,cAAc,EAAE,CACb,CACP,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,cAAc,CAAC"}
|
|
@@ -1,29 +1,11 @@
|
|
|
1
1
|
import OneUptimeDate from "../../../Types/Date";
|
|
2
|
+
import UptimeDaySummary from "./UptimeDaySummary";
|
|
3
|
+
import { DefaultUptimeHistoryLabels, } from "../../../Types/Monitor/UptimeHistoryLabels";
|
|
2
4
|
import React from "react";
|
|
3
5
|
const UptimeBarTooltip = (props) => {
|
|
4
6
|
const dateStr = OneUptimeDate.getDateAsUserFriendlyLocalFormattedString(props.date, true);
|
|
5
|
-
// Color tiers
|
|
6
|
-
const isGood = props.uptimePercent >= 99.9;
|
|
7
|
-
const isWarn = !isGood && props.uptimePercent >= 99;
|
|
8
|
-
const uptimeColor = isGood
|
|
9
|
-
? "#059669"
|
|
10
|
-
: isWarn
|
|
11
|
-
? "#d97706"
|
|
12
|
-
: "#dc2626";
|
|
13
|
-
// Sort: downtime first, then by duration desc
|
|
14
|
-
const sortedDurations = [
|
|
15
|
-
...props.statusDurations,
|
|
16
|
-
].sort((a, b) => {
|
|
17
|
-
if (a.isDowntime !== b.isDowntime) {
|
|
18
|
-
return a.isDowntime ? -1 : 1;
|
|
19
|
-
}
|
|
20
|
-
return b.seconds - a.seconds;
|
|
21
|
-
});
|
|
22
|
-
const totalSeconds = sortedDurations.reduce((sum, d) => {
|
|
23
|
-
return sum + d.seconds;
|
|
24
|
-
}, 0);
|
|
25
7
|
const hasIncidents = props.incidents.length > 0;
|
|
26
|
-
const
|
|
8
|
+
const labels = props.labels || DefaultUptimeHistoryLabels;
|
|
27
9
|
return (React.createElement("div", { style: {
|
|
28
10
|
minWidth: "280px",
|
|
29
11
|
maxWidth: "340px",
|
|
@@ -48,146 +30,7 @@ const UptimeBarTooltip = (props) => {
|
|
|
48
30
|
color: "var(--ou-text-primary, #111827)",
|
|
49
31
|
letterSpacing: "-0.01em",
|
|
50
32
|
} }, dateStr)),
|
|
51
|
-
props.hasEvents
|
|
52
|
-
marginBottom: hasStatuses || hasIncidents ? "12px" : "0",
|
|
53
|
-
} },
|
|
54
|
-
React.createElement("div", { style: {
|
|
55
|
-
display: "flex",
|
|
56
|
-
alignItems: "baseline",
|
|
57
|
-
justifyContent: "space-between",
|
|
58
|
-
marginBottom: "8px",
|
|
59
|
-
} },
|
|
60
|
-
React.createElement("span", { style: {
|
|
61
|
-
fontSize: "11px",
|
|
62
|
-
color: "var(--ou-text-muted, #6b7280)",
|
|
63
|
-
fontWeight: 500,
|
|
64
|
-
} }, "Uptime"),
|
|
65
|
-
React.createElement("div", { style: { display: "flex", alignItems: "baseline" } },
|
|
66
|
-
React.createElement("span", { style: {
|
|
67
|
-
fontSize: "14px",
|
|
68
|
-
fontWeight: 600,
|
|
69
|
-
color: uptimeColor,
|
|
70
|
-
fontVariantNumeric: "tabular-nums",
|
|
71
|
-
lineHeight: 1,
|
|
72
|
-
letterSpacing: "-0.03em",
|
|
73
|
-
} }, props.uptimePercent >= 100
|
|
74
|
-
? "100"
|
|
75
|
-
: props.uptimePercent.toFixed(2)),
|
|
76
|
-
React.createElement("span", { style: {
|
|
77
|
-
fontSize: "11px",
|
|
78
|
-
fontWeight: 600,
|
|
79
|
-
color: uptimeColor,
|
|
80
|
-
marginLeft: "1px",
|
|
81
|
-
opacity: 0.7,
|
|
82
|
-
} }, "%"))),
|
|
83
|
-
totalSeconds > 0 && sortedDurations.length > 1 ? (React.createElement("div", { style: {
|
|
84
|
-
width: "100%",
|
|
85
|
-
height: "4px",
|
|
86
|
-
borderRadius: "100px",
|
|
87
|
-
overflow: "hidden",
|
|
88
|
-
display: "flex",
|
|
89
|
-
gap: "1px",
|
|
90
|
-
backgroundColor: "var(--ou-border-default, #e5e7eb)",
|
|
91
|
-
} }, sortedDurations.map((status, index) => {
|
|
92
|
-
const widthPercent = (status.seconds / totalSeconds) * 100;
|
|
93
|
-
if (widthPercent < 0.5) {
|
|
94
|
-
return null;
|
|
95
|
-
}
|
|
96
|
-
return (React.createElement("div", { key: index, style: {
|
|
97
|
-
width: `${widthPercent}%`,
|
|
98
|
-
height: "100%",
|
|
99
|
-
backgroundColor: status.color.toString(),
|
|
100
|
-
} }));
|
|
101
|
-
}))) : (React.createElement("div", { style: {
|
|
102
|
-
width: "100%",
|
|
103
|
-
height: "4px",
|
|
104
|
-
backgroundColor: "var(--ou-border-default, #e5e7eb)",
|
|
105
|
-
borderRadius: "100px",
|
|
106
|
-
overflow: "hidden",
|
|
107
|
-
} },
|
|
108
|
-
React.createElement("div", { style: {
|
|
109
|
-
width: `${Math.min(props.uptimePercent, 100)}%`,
|
|
110
|
-
height: "100%",
|
|
111
|
-
backgroundColor: uptimeColor,
|
|
112
|
-
borderRadius: "100px",
|
|
113
|
-
} }))))),
|
|
114
|
-
!props.hasEvents && (React.createElement("div", { style: {
|
|
115
|
-
backgroundColor: "var(--ou-surface-secondary, #f9fafb)",
|
|
116
|
-
borderRadius: "8px",
|
|
117
|
-
padding: "16px",
|
|
118
|
-
textAlign: "center",
|
|
119
|
-
} },
|
|
120
|
-
React.createElement("svg", { width: "18", height: "18", viewBox: "0 0 24 24", fill: "none", stroke: "var(--ou-border-strong, #d1d5db)", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round", style: { margin: "0 auto 6px" } },
|
|
121
|
-
React.createElement("circle", { cx: "12", cy: "12", r: "10" }),
|
|
122
|
-
React.createElement("line", { x1: "12", y1: "8", x2: "12", y2: "12" }),
|
|
123
|
-
React.createElement("line", { x1: "12", y1: "16", x2: "12.01", y2: "16" })),
|
|
124
|
-
React.createElement("div", { style: {
|
|
125
|
-
fontSize: "12px",
|
|
126
|
-
color: "var(--ou-text-subtle, #9ca3af)",
|
|
127
|
-
fontWeight: 500,
|
|
128
|
-
} }, "No monitoring data for this day"))),
|
|
129
|
-
hasStatuses && (React.createElement("div", { style: {
|
|
130
|
-
paddingBottom: hasIncidents ? "10px" : "0",
|
|
131
|
-
marginBottom: hasIncidents ? "10px" : "0",
|
|
132
|
-
borderBottom: hasIncidents
|
|
133
|
-
? "1px solid var(--ou-border-subtle, #f0f0f0)"
|
|
134
|
-
: "none",
|
|
135
|
-
} }, sortedDurations.map((status, index) => {
|
|
136
|
-
const pct = totalSeconds > 0 ? (status.seconds / totalSeconds) * 100 : 0;
|
|
137
|
-
return (React.createElement("div", { key: index, style: {
|
|
138
|
-
display: "flex",
|
|
139
|
-
alignItems: "center",
|
|
140
|
-
padding: "4px 0",
|
|
141
|
-
gap: "8px",
|
|
142
|
-
} },
|
|
143
|
-
React.createElement("div", { style: {
|
|
144
|
-
display: "flex",
|
|
145
|
-
alignItems: "center",
|
|
146
|
-
gap: "6px",
|
|
147
|
-
width: "100px",
|
|
148
|
-
flexShrink: 0,
|
|
149
|
-
} },
|
|
150
|
-
React.createElement("span", { style: {
|
|
151
|
-
width: "6px",
|
|
152
|
-
height: "6px",
|
|
153
|
-
borderRadius: "50%",
|
|
154
|
-
backgroundColor: status.color.toString(),
|
|
155
|
-
display: "inline-block",
|
|
156
|
-
flexShrink: 0,
|
|
157
|
-
} }),
|
|
158
|
-
React.createElement("span", { style: {
|
|
159
|
-
fontSize: "12px",
|
|
160
|
-
color: "var(--ou-text-secondary, #374151)",
|
|
161
|
-
fontWeight: 500,
|
|
162
|
-
whiteSpace: "nowrap",
|
|
163
|
-
overflow: "hidden",
|
|
164
|
-
textOverflow: "ellipsis",
|
|
165
|
-
} }, status.label)),
|
|
166
|
-
React.createElement("div", { style: {
|
|
167
|
-
flex: 1,
|
|
168
|
-
height: "4px",
|
|
169
|
-
backgroundColor: "var(--ou-surface-tertiary, #f3f4f6)",
|
|
170
|
-
borderRadius: "100px",
|
|
171
|
-
overflow: "hidden",
|
|
172
|
-
} },
|
|
173
|
-
React.createElement("div", { style: {
|
|
174
|
-
width: `${pct}%`,
|
|
175
|
-
height: "100%",
|
|
176
|
-
backgroundColor: status.color.toString(),
|
|
177
|
-
borderRadius: "100px",
|
|
178
|
-
opacity: 0.7,
|
|
179
|
-
} })),
|
|
180
|
-
React.createElement("span", { style: {
|
|
181
|
-
fontSize: "11px",
|
|
182
|
-
color: status.isDowntime
|
|
183
|
-
? "var(--ou-danger-text, #b91c1c)"
|
|
184
|
-
: "var(--ou-text-muted, #6b7280)",
|
|
185
|
-
fontWeight: status.isDowntime ? 600 : 400,
|
|
186
|
-
fontVariantNumeric: "tabular-nums",
|
|
187
|
-
whiteSpace: "nowrap",
|
|
188
|
-
flexShrink: 0,
|
|
189
|
-
} }, OneUptimeDate.secondsToFormattedFriendlyTimeString(status.seconds))));
|
|
190
|
-
}))),
|
|
33
|
+
React.createElement(UptimeDaySummary, { uptimePercent: props.uptimePercent, hasEvents: props.hasEvents, statusDurations: props.statusDurations, hasFollowingContent: hasIncidents, labels: props.labels }),
|
|
191
34
|
hasIncidents && (React.createElement("div", null,
|
|
192
35
|
React.createElement("div", { style: {
|
|
193
36
|
display: "flex",
|
|
@@ -200,7 +43,7 @@ const UptimeBarTooltip = (props) => {
|
|
|
200
43
|
color: "var(--ou-text-muted, #6b7280)",
|
|
201
44
|
fontWeight: 500,
|
|
202
45
|
flex: 1,
|
|
203
|
-
} },
|
|
46
|
+
} }, labels.incidents),
|
|
204
47
|
React.createElement("span", { style: {
|
|
205
48
|
fontSize: "10px",
|
|
206
49
|
fontWeight: 600,
|