PowerToys icon indicating copy to clipboard operation
PowerToys copied to clipboard

Add support for `IsCritical` styling on the context menu

Open DHowett opened this issue 10 months ago • 2 comments

originally filed by @zadjii-msft

IsCritical is our "this action is destructive" property. Items with that set should have red (or other warning color) text


comment from @niels9001

Do we have an example for this? E.g. uninstalling an app or deleting a file?comment from @zadjii-msft

@niels9001 I think this is a chicken & egg problem where "it wasn't supported yet" -> none of the extensions used it yet

But I'd guess the

  • "kill process" in window walker
  • "uninstall" in winget
  • the "stop" command on services(?)

should probably all be IsCritical=true.

I can make a quick pass and set that in some places if you want

DHowett avatar Mar 31 '25 15:03 DHowett

This issue is specific to the context menu, but should it also apply to primary/secondary commands? /cc @zadjii @niels9001

michaeljolley avatar May 19 '25 17:05 michaeljolley

Figma'd it up.

Image

michaeljolley avatar May 19 '25 18:05 michaeljolley

Ah, what happened?

DHowett avatar May 29 '25 21:05 DHowett

The devdocs read:

Image

michaeljolley avatar May 29 '25 23:05 michaeljolley

Oh, this. The way in which PowerToys is run unlike all other projects in existence 😆

DHowett avatar May 29 '25 23:05 DHowett

Hey, the fact that there is a process makes it leaps and bounds better than other projects. 😄

michaeljolley avatar May 30 '25 00:05 michaeljolley