Modeling view appearance final tweaks (#6425)

* Remove bug button from LowerRightControls

There is a "report a bug" button in the help menus, both native and
lower-right corner. This is overkill, and users are not using coredump
well.

* Remove coredump from refresh UI button

* Add a "Refresh app" command to palette

* Update snapshots

* Rework "Refresh and report bug" menu item to "Report a bug"

* Add refresh button to sidebar

* Convert upper-right refresh button to Share

* Tweak styles of command button

* Make anonymous user icon same size as known user image

* Remove ModelStateIndicator

* Use hotkeyDisplay for the sidebar too

* Update snapshots

* Remove tooltip from command bar open button

* tsc, lint, and fmt
This commit is contained in:
Frank Noirot
2025-04-23 15:20:45 -04:00
committed by GitHub
parent 45e17c50e7
commit f03a684eec
44 changed files with 156 additions and 291 deletions

View File

@ -8,6 +8,28 @@ import type { AsyncFn } from '@src/lib/types'
export const uuidv4 = v4
/**
* Refresh the browser page after reporting to Plausible.
*/
export async function refreshPage(method = 'UI button') {
if (window && 'plausible' in window) {
const p = window.plausible as (
event: string,
options?: { props: Record<string, string> }
) => Promise<void>
// Send a refresh event to Plausible so we can track how often users get stuck
await p('Refresh', {
props: {
method,
// optionally add more data here
},
})
}
// Window may not be available in some environments
window?.location.reload()
}
/**
* Get all labels for a keyword call expression.
*/