3576 Commits

Author SHA1 Message Date
c94f930950 Update dependency prettier to v3.6.2 (#108689)
* Update dependency prettier to v3.6.2

* run prettier

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2025-07-25 17:47:44 +01:00
2196727226 TimeSeries: Add Time Comparison (#104672)
* TimeComparison: Add time comparison option

* Display control conditionally based on option

* Provide timeCompare option to panels that opt in

* Only render time compare if panel supports it

* Create a custom time range compare component

* Move custom component

* Remove button checked

* Move time compare options out of field config

* Fix types and remove from fieldConfigProperty enum

* Remove from field config registry

* Add headerActions to V2 schema

* Remove dependency on timeCompare support registry

* Add feature flag

* Subscribe to options change in wrapper

* Remove custom rendering to simplify wrapper

* Bump scenes version

* Hide checkbox

* Remove unneeded query refresh during disable

* Fix import order in timeseries module

* Add util tests

* Support time comparison toggle for new viz panels

* Revert grafana-app-sdk and manifest changes

* Revert yarn lock
2025-07-24 13:07:28 -07:00
512a553723 Geomap: Add tooltip support for dynamic geojson (#108203)
* Geomap: Add tooltip support for dynamic geojson

* Add tests for tooltip function
2025-07-24 08:10:12 -07:00
0f9ea44144 XYChart: Lift restrictions around re-using fields for color and size (#106690) 2025-07-23 14:55:58 +00:00
f657044afb LogLine: Add Explain in Assistant option to explain single log lines (#108387)
* LogLine: Add `Explain in Assistant` option

* LogLine: Improve menu and prompt

* LogLine: Mock `@grafana/assistant` in tests

* LogLine: Mock `@grafana/assistant` in tests

* i18n

* LogLine: Expose via loglistcontext

* LogLine: Mock in LogLineDetails

* revert

* revert changes

* LogLine: Fix LogListContext mock

* LogLineControls: Add context props

* LogLineControls: Mock `@grafana/assistant`

* LogLineControls: Remove from props

* LogLineControls: Lint menu

* LogsPanel: Mock `@grafana/assistant`
2025-07-23 12:12:47 +02:00
d43606cd3e XYChart: Fix hideFrom.tooltip (#108359) 2025-07-22 12:07:34 -05:00
7626508842 Table: Update e2e tests to support tableNextGen (#108184)
* Table: Force tableNextGen to be true for Playwright and false for Cypress

* RDG query for body text contains the headers too

* add some simple tests for row height

* dial in the row height test a little more

* more updates

* filters, pagination

* try this on CI

* more updates to the tests

* more tests

* wait for some sort stuff to flush

* replace class selectors for rdg

* target the click to the anchor in the header
2025-07-18 12:27:04 -04:00
046134db22 New Logs Panel: Add events for Panel and Details (#108272)
* New Logs Panel: Add events for Panel and Details

* Logs Panel: add noInteractions property

* New Logs Panel: conditionally report interactions

* Test
2025-07-18 13:13:51 +02:00
208df33e04 Trace View: Add span filters to URL (#107363)
* refactor(explore/spanFilters): move default filters and search props to shared folders

chore: ammend with refactor commit

chore: ammend, fix type errors

* feat(explore): add spanFilters to global state on explore

* feat(explore/spanFilters): sync span filters with global redux state

* feat(explore): sync spanFilters with URL state

* Moved span filters to panel state

* Fix types

* Fix tests in useSearch

* Fix TraceView tests

* Remove console.warn

* fix(test/trace-view-container): add span filter context to intial state

* refactor(traceview): use generic redux action

* fix(traceview): prune array objects correctly to preserve tag state in URL

---------

Co-authored-by: André Pereira <adrapereira@gmail.com>
2025-07-17 10:00:57 +01:00
974103c6fa OTel: Add experimental formatting for OTel identified log lines (#108170)
* OTel: create formats service

* LogListContext: use OTel service to resolve the default displayed fields

* Create otelLogsFormatting feature flag

* LogListContext: conditionally use otel format based on feature flag

* OTel logs: reformat body and improve displayed fields

* formats: remove duplicated scope name

* Update formats.ts

* format: use regex rules to exclude fields

* Add tests

* Formatting

* LogsPanel: expose setDisplayedFields

* LogListContext: refactor otel displayed fields

* Prettier

* format: optimize identifyOTelLanguages
2025-07-16 17:42:14 +02:00
1143cf130e Geomap: Upgrade Open Layers (#107598)
* Geomap: Upgrade Open Layers

* Fix TypeScript errors

* Fix possibly null errors

* Fix pointer events

* Simplify webgl implementation for markers

* Improve types

* Fix offset expression

* Improve layers types

* Improve types for tooltip

* Improve types for frameVectorSource

* For regular shapes convert size to radius

* Update import format for new version of ol

* Fix ESM syntax errors

* Fix more e2e stuff

* Fix tooltip test

* Simplify redundant keys
2025-07-15 17:04:41 -07:00
b839090de5 New logs Panel: Log details improvements + default details value update (#108065)
* LogLineDetails: prettify json field values

* processing: prettify json according to wrap status

* LogLineDetailsField: better column width for keys

* LogsPanel: let app have automatic details mode

* Fix prop name

* LogLineDetails: memoize

* LogLineDisplayedFields: add icons to organize

* Displayed fields: add cursor move

* LogLineDetailsFields: improve key columns

* Remove test

* Translations

* Formatting

* LogLineDetailsFields: minor refactor and fix

* LogLineDetails: remember inline scroll position

* LogLineDetails: test displayed fields reorg

* Update mock

* LogLineDetailsComponent: add missing disable actions

* Log details copy button: gap = 0

* LogLineDetailsDisplayedFields: use fixed size for inline fields
2025-07-15 16:17:20 +00:00
f19b2ef429 TableNG: Move useCallback up in TablePanel (#108080) 2025-07-14 13:08:50 -04:00
32fecb9483 Geomap: DX improvements (#107588)
chore(geomap): dev experience improvements
2025-07-14 13:38:06 +02:00
7344c1c555 TableNG: Simplify Pill cellType and reduce scope (#107934)
Co-authored-by: Paul Marbach <paul.marbach@grafana.com>
2025-07-11 21:28:06 -05:00
a63a9357bb TableNG: Follow-up style fixes (#107274)
* open cell inspect in code mode for JSON panels

* increase opacity of TableCellActions background for legibility in overlap cases

* fix nested grid width calculation

* fix 'jumping' on hover overflow

* route transparency through (needs a scenes update)

* base row hover color on transparency

* update the colors for table

* remove console.log

* reinstate header toggle for nested row transformation

* fix #59474 - graceful handling when subtable has no rows

* fix i18n

* use TABLE.LINE_HEIGHT

* change nestedData back to const
2025-07-09 14:54:48 -04:00
5108225785 Logs Panel: Explose details mode and default to inline (#107902)
Logs Panel: Explose details mode
2025-07-09 17:31:10 +02:00
e78411f17a Tempo: Fix showing dangling edges in NodeGraph (#107245)
* Tempo: Fix showing dangling edges in NodeGraph

* Remove comment
2025-07-09 10:53:31 +02:00
20c700dd52 Chore: reduces barrel files part II (#107688)
* Chore: reduce barrel files

* chore: fixes unit test

* Chore: reduces barrel files part II

* chore: fix import sorting
2025-07-09 06:15:33 +02:00
68ee251c5c TableNG: Extract links and actions tooltip into cell root renderer (#107667)
* TableNG: Extract links and actions tooltip into cell root renderer

* make TS happy

* fixes & tweaks

* lint

* skip datalinks and actions tooltip on those cell types

* add todo

* withTooltip lookup

* fix

* optional getActions

* fix

* kill cursor: 'context-menu'

* stop event propagation from TableCellActions

* update tests to move tooltip tests up to TableNG

* remove safety assertion

* add value back to DataLinksActionsTooltip

---------

Co-authored-by: Paul Marbach <paul.marbach@grafana.com>
2025-07-08 14:24:03 -04:00
0fdcae4e26 Tables: Pills for Table Cells (#107485)
* v2 of pills for tables

* cleanup bettererrrrr

* cleanup pretty

* i18n changes

* add in the option for value mapping

* value mapping

* change to just use the value mapping from the table component

* tests fixed

* betterer all better now

* fix pretty

* i18n

* fix gen issue

* i18n

* fix merge issue

* Refactor pillcell to an interface for said pill, cleanup tests

* mind the space says prettier
2025-07-08 10:56:39 -05:00
89e8a03859 New Log Details: Add support to sort displayed fields (#107635)
* Create LogLineDetailsDisplayedFields

* Log labels: properly implement plurals

* Pluralize

* LogListContext: pass setDisplayedFields

* LogLineDetailsDisplayedFields: update displayed fields

* LogLineDetails: scroll to item after opening details

* LogListContext: serve logOptionsStorageKey

* Update test

* Missing translations

* LogLineDetailsDisplayedFields: update styles

* LogLineDetails: update text selectors

* Update tests

* Reorganize log details: improve discoverability

* Update test
2025-07-08 11:57:28 +02:00
7181f8d89d TableNG: Update description for wrapHeaderText (#107722) 2025-07-07 12:36:41 -04:00
31b71f79dd Internationalisation: Manual mark up following review (#107625)
* mark up and add confirmText to lint rule

* mark up and add ariaLabel to lint rule

* add confirmText to propertiesToCheck

* mark up and add body to propsToCheck

* mark up latest

* mark up 'Dashboard saved'

* mark up filterbyvalue options

* mark up tooltip options

* mark up and add lint rules for noOptionsMessage/loadingMessage

* mark up 'Convert field type'

* mark up placeholderText/noOptionsMessage

* mark up run query

* mark up variable editor fields

* mark up week start options

* mark up dashboard link options

* mark up prom options

* mark up builder/code toggles

* make CI happy

* kick CI
2025-07-07 16:43:19 +01:00
6ce2fac2bb Internationalisation: Mark up geomap panel edit options (#107140)
mark up geomap panel edit options
2025-07-07 11:30:11 +01:00
68cbd23916 Chore: reduces barrel files (#107512)
* Chore: reduce barrel files

* chore: fixes unit test

* chore: fix broken path
2025-07-07 09:23:27 +02:00
dd6a231aad TableNG: Add option to wrap header text (#107338)
* TableNG: wrapped header text option

* reorganize variable names and code for easier reuse

* refine height math

* move empty string check to after null check

* add tests for useHeaderHeight

* maybe a bit faster

* cleanup to avoid creating fns and objects all the time, some tests

* fix unit test

* cell was using panel height

* add borders between header cells to make resizing more obvious

* fix tests

* changes from mob review

* jk

---------

Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
2025-07-03 14:21:58 -05:00
2d634639a2 Geomap: Render one marker at duplicate coordinates (#106962)
* Geomap: Render one marker at duplicate coordinates

* Take into account all dims for uniqueness

* Simplify marker uniqueness key
2025-06-30 09:06:16 -07:00
99782ae406 TableNG: Refactor to better take advantage of react-data-grid (#103755) 2025-06-30 07:18:23 -05:00
ee6cbd0efc BarChart/StateTimeline: Use noValue setting for error message when data is empty (#107147)
* fix: use fieldConfig.defaults.noValue in barchart and statetimeline

* change name of test

* remove todo comment

* lean on PanelDataErrorView in the case where no fields are present

* update StateTimeline and StatusHistory to use PanelDataErrorView

* fix test

* self-review cleanup
2025-06-27 08:28:13 -05:00
2837f8fb58 internationalisation: Mark up canvas panel edit options (#107118)
mark up canvas panel
2025-06-25 10:06:37 +01:00
182bff2555 StateTimeline: Add endTime to tooltip (#106582) 2025-06-24 19:57:46 +00:00
a39a354ff5 fix: percentage-based heights were not applied in updated scrollable iframe container 2025-06-24 09:20:42 -04:00
38fc06a6ff Internationalisation: Mark up panel edit options (#107051)
* markup timeseries panel edit

* mark up matchers ui

* mark up bar chart

* mark up stat panel

* mark up gauge

* mark up bar gauge

* mark up table component

* mark up pie chart

* mark up state timeline

* mark up heatmap

* mark up status history

* mark up histogram

* mark up text panel

* mark up alert list

* mark up dashboard list

* mark up news panel

* mark up annolist

* mark up logs panel

* mark up node-graph

* mark up traces

* mark up trend

* mark up xychart

* fix build
2025-06-24 12:55:55 +01:00
cf8e3bf7d4 XYChart: Add support for x=time (#106459)
* XYChart: Add support for x=time

* prettier

* Add time axis demo to provisioned dashboard for XY

* Add details about time fields to the documentation

---------

Co-authored-by: Kristina Durivage <kristina.durivage@grafana.com>
2025-06-23 18:13:28 -05:00
693bc51693 New Logs Panel: Read default font size from storage + add missing unescaped content check + fix mutation (#106755)
* Logs Panel: remove default value to it's taken from local storage code

* processing: do not remove newlines, let truncation handle

* LogList: check and pass unescaped content to context

* LogLine: prevent mutation of searchWords

* grammar: use parseFlags

* grammar: escape regex
2025-06-17 23:10:34 +02:00
7b70271ce6 New Logs Panel: add syntax highlighting option (#106611) 2025-06-12 20:43:13 +02:00
2b8c74de2e i18n: removes useTranslate hook (#106556)
* i18n: removes useTranslate hook

* chore: fix duplicate imports

* chore: fix import sorting and hook dependencies
2025-06-12 11:03:52 +02:00
66f79e53e5 Dashboards: Pass id prop to Switch component for bool inputs (#106438) 2025-06-11 12:45:14 +01:00
db83b4ef17 New Logs Panel: font size selector and Log Details size improvments (#106376)
* LogList: create font size option

* LogList: prevent option fontSize bouncing

* LogListContext: fix stored container size bigger than container

* LogList: render smaller font size

* virtualization: adjust to variable font size

* virtualization: strip white characters of at the start successive long lines

* LogList: add font size to log size cache

* LogList: use getters instead of fixed constants

* LogLine: prevent unnecessary overflow calls

* virtualization: strip ansi color codes before measuring

* LogListDetails: adjust size on resize and give logs panel a min width

* LogsPanel: add showControls as a dashboard option

* virtualization: update test

* virtualization: add small test case

* processing: update font size

* LogListControls: update test

* Extract translations

* Logs Panel: enable controls by default

* LogListContext: update mock

* ControlledLogRows: add missing prop

* LogLine: remove height ref

* LogList: dont touch the debounced function on successive calls

* LogLine: update test

* LogsPanel: make controls default to false again

* LogsPanel: make controls default to false again

* LogLineDetails: fix height resizing and make close button sticky

* LogLine: memo log component

* LogLineDetails: fix close button position

* New Logs Panel: Add Popover Menu support (#106394)

* LogList: add popover menu support

* LogList: test popover menu

* Chore: remove unnecessary optional chain op

* LogLinedDetails: fix close button position with and without scroll
2025-06-10 09:59:01 +00:00
a0c55e92ee LogsView: Resource attributes links extension point (#105943)
* LogsView: Resource attributes links extension point

* Mocking usePluginLinks in tests

* Update link button styling

* LogListModel: sync with LogRowModel changes

* Fix import

---------

Co-authored-by: Matias Chomicki <matyax@gmail.com>
2025-06-04 09:55:08 +02:00
b3596e8c72 New Logs Panel: Render new panel using the current visualization (#105968)
* LogsPanel: integrate new panel via feature flag

* Log Line: move sampled/errors/deduplication count outside of log line body

* LogList: increase overscan count

* Logs Panel: enable deduplication for infinite scrolling

* Logs Panel: remove margin overflowing drilldown

* Logs Panel: add missing dependency to effect

* Logs Panel: pass missing callback

* Remove console log

* LogLine: show cursor pointer only when interactable

* LogLineDetails: make resize handler more obvious

* LogsPanel: add missing props to from panel

* LogLineMenu: add support for custom items

* LogsPanel: pass custom menu items to LogList

* Fix imports

* Chore: comments and missing argument

* LogLineMenu: pass log to event listener

* LogListContext: filter log details when no longer present in the new response

* chore: log

* LogsPanel: conditionally show options per feature flag status

* LogLine: align logs when some of them are sampled or with errors

* Chore: update tests

* LogLineMenu: test custom options

* LogsSamplePanel: show controls

* LogsPanel: move return after hooks to prevent bugs
2025-06-01 14:29:49 +02:00
0a104cc0ed Geomap: Add HiDPI support to CARTO basemap (#81195) (#106211)
Co-authored-by: Cledwyn Lew <me@trangle.top>
2025-05-29 12:09:41 -07:00
4ac248a512 Internationalisation: Mark up panel plugins for translations (#106068)
* config for panel plugin translations

* markup

* tweaks

* prettier

* use data-testid

* rename disable rule now it's been moved

* final markup
2025-05-29 18:13:25 +01:00
16a6d61ca7 Geomap: Require layer to have data for legend (#105580) 2025-05-23 14:28:16 -07:00
9308f86d63 New Logs Panel: Add Log Details support (#105609)
* Log list: add onclick listener

* LogListContext: add basic details support

* LogLineDetails: create component

* Address lint issues

* Log Details: make resizable and store size

* LogListModel: add sampled and error support

* LogDetails: pass more required props

* LogLineContext: add interactive callbacks support

* LogLineDetails: pass interactive callbacks

* LogList: pass displayedFields callbacks

* LogLine: move click listener

* LogLineMenu: support showing details

* LogLine: move onclick listener

* LogListContext: remove displayedFields intermediation

* i18n

* LogListContext: abstract details shown function

* LogLine: visually show expanded lines

* LogDetails: remove min width for labels

* LogLineDetails: add close button

* LogList: add extra wrapper to get width

* LogLineDetails: update logs size on resize

* virtualization: update to new width reference

* LogLine: check overflow on every re-render

* LogList: debug virtualization when resizing

* LogLineDetails: make it scrollable

* LogListContext: make detailsWidth not undefined

* Update tests with new attributes

* LogLine: update collapsed state with container changes

* LogLine: move cursor property to clickable styles

* LogList: fix height recalculation when display options change

* Logs: fix feature toggles support

* Logs: more feature toggles adjustments

* Lint

* LogLine: support duplicates, hasError, and isSampled

* Logs: debug feature flag combinations

* i18n

* Prettier

* New Logs Panel: generate storage key for dashboards

* Explore Logs: fix filtered levels

* Logs Sample: integrate new panel

* LogLine: fix unwrapped logs

* Fix test

* Update test

* Logs panel: update test

* Prettier

* LogLine: update tests

* LogLineMenu: update test

* LogList: update unit test

* processing: update test

* virtualization: update unit test
2025-05-20 20:28:35 +03:00
c03957d805 Geomap: Update CARTO attribution (#105578) 2025-05-19 09:28:15 -07:00
a9b6d098e9 Chore: Add eslint no-restricted-globals rule (#104519)
* Chore: Add no-restricted-globals eslint rule

* Fix eslint warnings

* Revert some changes

* Update

* Feedback
2025-05-12 12:38:26 +03:00
8f17f607fa FEMT: Add no-restricted-img-srcs rule (#105006) 2025-05-12 10:34:17 +01:00
feb1ac5ba7 Geomap: Fix marker layer for line string features (#103937)
* Geomap: Fix marker layer for line string features

* Update layer stack to handle line strings
2025-05-09 21:20:14 +03:00