Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Commands glow up #5516

Merged
merged 5 commits into from
Sep 6, 2024
Merged

Commands glow up #5516

merged 5 commits into from
Sep 6, 2024

Conversation

JamesNK
Copy link
Member

@JamesNK JamesNK commented Sep 2, 2024

Description

This PR:

  • Renames commands column to actions
  • Adds logs and view details to actions menu
  • Removes logs and view details columns
  • Adds icons to commands
  • Adds highlighted commands

Addresses #295

Demo:

resource-actions-menu2

Checklist

  • Is this feature complete?
    • Yes. Ready to ship.
    • No. Follow-up changes expected.
  • Are you including unit tests for the changes and scenario tests if relevant?
    • Yes
    • No
  • Did you add public API?
    • Yes
      • If yes, did you have an API Review for it?
        • Yes
        • No
      • Did you add <remarks /> and <code /> elements on your triple slash comments?
        • Yes
        • No
    • No
  • Does the change make any security assumptions or guarantees?
    • Yes
      • If yes, have you done a threat model and had a security review?
        • Yes
        • No
    • No
  • Does the change require an update in our Aspire docs?
    • Yes
      • Link to aspire-docs issue:
    • No
Microsoft Reviewers: Open in CodeFlow

@JamesNK JamesNK force-pushed the jamesnk/commands-glow-up branch from d648ce6 to e6cb0f9 Compare September 4, 2024 03:15
@leslierichardson95
Copy link

These changes look great! Suggestion: can we consider changing the tooltip text from just "stop" or "play" to "stop resource" and "play resource" just for some added clarity?

@JamesNK JamesNK mentioned this pull request Sep 4, 2024
16 tasks
@JamesNK
Copy link
Member Author

JamesNK commented Sep 4, 2024

These changes look great! Suggestion: can we consider changing the tooltip text from just "stop" or "play" to "stop resource" and "play resource" just for some added clarity?

The buttons here are examples. I'll keep this mind for when they're added in the future.

@timheuer
Copy link
Member

timheuer commented Sep 5, 2024

we're elevating stop/start as the PRIMARY action here, hiding others behind a ... -- are these truly the primary actions we think folks want on a resource? Details has been my primary (viewing config values) with logs being second. Yes because the others aren't there yet, but feels like stop/start/restart aren't going to be primary actions. Reserve the default space for primary and/or have fallaway logic (show more and responsively hide based on priorirty) /cc @leslierichardson95

@DamianEdwards
Copy link
Member

Details has been my primary (viewing config values) with logs being second. Yes because the others aren't there yet, but feels like stop/start/restart aren't going to be primary actions.

Personally I'd like to see Stop/Start and Details (aka info) be the primary actions, but given the new UX it seems we could easily fit all three in icon form (Stop/Start, Details, Logs).

@JamesNK
Copy link
Member Author

JamesNK commented Sep 5, 2024

"View details" doesn't need to be primary. 8.2 introduces clicking the row to show/hide details. That was introduced in 8.2. The main reason that "View details" still exists is for accessibility.

There may be UI space when viewing the resource page on a high-res display, but keep in mind that this column will be displayed in mobile view, and we don't want the ... button to be hidden.

e.g.
image

Promoting and demoting buttons isn't difficult. I want to stick with the current setup, and we can change based on feedback.

@leslierichardson95
Copy link

leslierichardson95 commented Sep 5, 2024

we're elevating stop/start as the PRIMARY action here, hiding others behind a ... -- are these truly the primary actions we think folks want on a resource? Details has been my primary (viewing config values) with logs being second. Yes because the others aren't there yet, but feels like stop/start/restart aren't going to be primary actions. Reserve the default space for primary and/or have fallaway logic (show more and responsively hide based on priorirty) /cc @leslierichardson95

That's a good point. For now, it might make more sense to stay consistent with the ACA stop/start resource experience where those actions take less priority over logs / details and are part of the "...".

[2 minutes later update]: I didn't see James make a response post before I could comment 😅. I think having the click row to view details is a nice addition and I also don't have an issue with sticking to the new change, but let's watch for feedback in case we encounter discoverability issues on the user's end.

Copy link
Member

@drewnoakes drewnoakes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Main question here is around the use of SVG in the protocol. See comments below. I'm facing the same issue in extensibility, for top-level navigation items provided by extensions.

Also, we now use the terms "command" and "actions" interchangeably. Can we consolidate? Command is already used in the .proto, so is hard to change (I think). I like "actions" for column header. Having two terms for the same thing is confusing though.

@davidfowl
Copy link
Member

I agree I don’t like usage of svg in the protocol. While more flexible it feels really bad coupling to the html that way. Can we do what we do for status icons or maybe a little more closed down and allowing names from an icon set

@JamesNK
Copy link
Member Author

JamesNK commented Sep 6, 2024

I can make it a name from the FluentUI icons, but if someone wants a custom icon, e.g. an Azure product icon, then they're stuck.

@davidfowl
Copy link
Member

That’s ok for now

@JamesNK
Copy link
Member Author

JamesNK commented Sep 6, 2024

Also, we now use the terms "command" and "actions" interchangeably. Can we consolidate? Command is already used in the .proto, so is hard to change (I think). I like "actions" for column header. Having two terms for the same thing is confusing though.

It's too late to change the proto. But I don't think it will be confusing. Here is how I think of it:

  • Grids have action menus. Right now, it is just the resources page, but I think we'll have an actions column on structured logs and traces eventually.
  • The resources action menu also contains actions to execute resource commands.

IMO having a different name to disambiguate them is good even.

@JamesNK
Copy link
Member Author

JamesNK commented Sep 6, 2024

All feedback applied.

@JamesNK
Copy link
Member Author

JamesNK commented Sep 6, 2024

/azp run

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@JamesNK JamesNK enabled auto-merge (squash) September 6, 2024 10:20
@JamesNK JamesNK merged commit bc69e39 into main Sep 6, 2024
11 checks passed
@JamesNK JamesNK deleted the jamesnk/commands-glow-up branch September 6, 2024 10:38
@github-actions github-actions bot locked and limited conversation to collaborators Oct 7, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants