Log Rows: Added popover menu with filter options when a log line is selected (#75306)

* LogRow: detect text selection

* LogRow: refactor menu as component

* LogRow: add actions to menu

* LogRow: hack menu position

* Remove unsused imports

* LogRowMessage: remove popover code

* PopoverMenu: refactor

* LogRows: implement PopoverMenu at log rows level

* PopoverMenu: implement copy

* PopoverMenu: receive row model

* PopoverMenu: fix onClick capture issue

* Explore: add new filter methods and props for line filters

* PopoverMenu: use new filter props

* Explore: separate toggleable and non toggleable filters

* PopoverMenu: improve copy

* ModifyQuery: extend line filter with value argument

* PopoverMenu: close with escape

* Remove unused import

* Prettier

* PopoverMenu: remove label filter options

* LogRow: rename text selection handling prop

* Update test

* Remove unused import

* Popover menu: add unit test

* LogRows: update unit test

* Log row: hide the log row menu if the user is selecting text

* Log row: dont hide row menu if popover is not in scope

* Log rows: rename state variable

* Popover menu: allow menu to scroll

* Log rows: fix classname prop

* Log rows: close popover if mouse event comes from outside the log rows

* Declare new class using object style

* Fix style declaration

* Logs Popover Menu: add string filtering functions (#76757)

* Loki modifyQuery: add line does not contain query modification

* Elastic modifyQuery: implement line filters

* Modify query: change action name to not be loki specific

* Prettier

* Prettier

* Elastic: escape filter values

* Popover menu: create feature flag

* Log Rows: integrate logsRowsPopoverMenu flag

* Rename feature flag

* Popover menu: track interactions

* Prettier

* logRowsPopoverMenu: update stage

* Popover menu: add ds type to tracking data

* Log rows: move feature flag check

* Improve handle deselection
This commit is contained in:
Matias Chomicki
2023-11-16 11:48:10 +02:00
committed by GitHub
parent 05cf8c9253
commit 9cb303c3f7
24 changed files with 636 additions and 79 deletions
+7
View File
@@ -1063,6 +1063,13 @@ var (
Owner: grafanaAlertingSquad,
HideFromDocs: true,
},
{
Name: "logRowsPopoverMenu",
Description: "Enable filtering menu displayed when text of a log line is selected",
Stage: FeatureStageExperimental,
FrontendOnly: true,
Owner: grafanaObservabilityLogsSquad,
},
{
Name: "pluginsSkipHostEnvVars",
Description: "Disables passing host environment variable to plugin processes",
+1
View File
@@ -143,4 +143,5 @@ flameGraphItemCollapsing,experimental,@grafana/observability-traces-and-profilin
alertingDetailsViewV2,experimental,@grafana/alerting-squad,false,false,false,true
datatrails,experimental,@grafana/dashboards-squad,false,false,false,true
alertingSimplifiedRouting,experimental,@grafana/alerting-squad,false,false,false,false
logRowsPopoverMenu,experimental,@grafana/observability-logs,false,false,false,true
pluginsSkipHostEnvVars,experimental,@grafana/plugins-platform-backend,false,false,false,false
1 Name Stage Owner requiresDevMode RequiresLicense RequiresRestart FrontendOnly
143 alertingDetailsViewV2 experimental @grafana/alerting-squad false false false true
144 datatrails experimental @grafana/dashboards-squad false false false true
145 alertingSimplifiedRouting experimental @grafana/alerting-squad false false false false
146 logRowsPopoverMenu experimental @grafana/observability-logs false false false true
147 pluginsSkipHostEnvVars experimental @grafana/plugins-platform-backend false false false false
+4
View File
@@ -583,6 +583,10 @@ const (
// Enables the simplified routing for alerting
FlagAlertingSimplifiedRouting = "alertingSimplifiedRouting"
// FlagLogRowsPopoverMenu
// Enable filtering menu displayed when text of a log line is selected
FlagLogRowsPopoverMenu = "logRowsPopoverMenu"
// FlagPluginsSkipHostEnvVars
// Disables passing host environment variable to plugin processes
FlagPluginsSkipHostEnvVars = "pluginsSkipHostEnvVars"