telemetry: Add panel button clicked event (#36735)

The event has two fields

1. name: The name of the panel being clicked
2. toggle_state: true if clicking to open, otherwise false

cc @katie-z-geer 

Release Notes:

- N/A
This commit is contained in:
Anthony Eid
2025-08-22 05:54:25 +00:00
committed by GitHub
parent b349a8f34c
commit e360691106
+5
View File
@@ -915,6 +915,11 @@ impl Render for PanelButtons {
.on_click({
let action = action.boxed_clone();
move |_, window, cx| {
telemetry::event!(
"Panel Button Clicked",
name = name,
toggle_state = !is_open
);
window.focus(&focus_handle);
window.dispatch_action(action.boxed_clone(), cx)
}