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

[table] Add option to remove selection chips for single-selection mode #9353

Closed
2 of 6 tasks
mpayson opened this issue May 16, 2024 · 4 comments
Closed
2 of 6 tasks
Assignees
Labels
4 - verified Issues that have been released and confirmed resolved. ArcGIS Online Issues logged by ArcGIS Online team members. c-table Issues that pertain to the calcite-table and related components calcite-components Issues specific to the @esri/calcite-components package. enhancement Issues tied to a new feature or request. estimate - 2 Small fix or update, may require updates to tests. impact - p3 - not time sensitive User set priority impact status of p3 - not time sensitive

Comments

@mpayson
Copy link

mpayson commented May 16, 2024

Check existing issues

Description

We received feedback during holistic testing that calcite-table's selection chips suggest users can make multiple selections, even in single selection mode. It'd be great to be able to remove or hide these chips. In addition, for our use case, users are required to make a selection, so removing the "Clear" button would be useful as well

Acceptance Criteria

A new property is CSS variable that allows hiding the selection chips in calcite able

Relevant Info

No response

Which Component

calcite-table

Example Use Case

No response

Priority impact

p4 - not time sensitive

Calcite package

  • @esri/calcite-components
  • @esri/calcite-components-angular
  • @esri/calcite-components-react
  • @esri/calcite-design-tokens
  • @esri/eslint-plugin-calcite-components

Esri team

ArcGIS Online

@mpayson mpayson added 0 - new New issues that need assignment. enhancement Issues tied to a new feature or request. needs triage Planning workflow - pending design/dev review. labels May 16, 2024
@github-actions github-actions bot added ArcGIS Online Issues logged by ArcGIS Online team members. calcite-components Issues specific to the @esri/calcite-components package. impact - p3 - not time sensitive User set priority impact status of p3 - not time sensitive labels May 16, 2024
@geospatialem geospatialem added the c-table Issues that pertain to the calcite-table and related components label May 16, 2024
@macandcheese
Copy link
Contributor

macandcheese commented May 16, 2024

An option we've discussed is to have a selection-display property that allows for the built-in chips (default), provides a "floating" or "pinned to bottom" selection display.

We could add a "none" mode where no UI is shown, either for cases where none should be, or the app wants to do something more custom. This could also affect all selection modes, so we didn't have a specific prop to disable the behavior of a single mode. #8914

Is the behavior described there (the "none" display mode) sufficient - we could add that "none" value first / more easily?

@mpayson
Copy link
Author

mpayson commented May 16, 2024

Is the behavior described there (the "none" display mode) sufficient - we could add that "none" value first / more easily?

I think so, if I'm understanding correctly the selectionDisplay is the chips, so setting it to none would remove the chips above the table, but keep the selection column and row highlights in the table? For context...

Current implementation

Screenshot 2024-05-16 at 12 39 40 PM

Design

Screenshot 2024-05-16 at 12 42 32 PM

@macandcheese macandcheese self-assigned this May 16, 2024
@macandcheese macandcheese added 1 - assigned Issues that are assigned to a sprint and a team member. estimate - 2 Small fix or update, may require updates to tests. and removed 0 - new New issues that need assignment. labels May 16, 2024
@macandcheese macandcheese removed the needs triage Planning workflow - pending design/dev review. label May 16, 2024
macandcheese added a commit that referenced this issue May 17, 2024
**Related Issue:** #9353 

## Summary
This adds a `selectionDisplay` property to Table. It defaults to "top"
(the current behavior), and adds a "none" option. This will hide all
selection chips and clearance affordances. It will also hide any slotted
content in `selection-actions` slot, which is noted in the doc.

We've planned on adding further customization ability to this selection
mode UI (make it sticky, floating on bottom, etc.), and that can still
occur as planned
#8914, by adding
values to this new property.
@macandcheese macandcheese added 3 - installed Issues that have been merged to master branch and are ready for final confirmation. and removed 1 - assigned Issues that are assigned to a sprint and a team member. labels May 17, 2024
@github-actions github-actions bot assigned geospatialem and DitwanP and unassigned macandcheese May 17, 2024
Copy link
Contributor

Installed and assigned for verification.

@DitwanP
Copy link
Contributor

DitwanP commented May 21, 2024

🍠 Verified locally on main

@DitwanP DitwanP closed this as completed May 21, 2024
@DitwanP DitwanP added 4 - verified Issues that have been released and confirmed resolved. and removed 3 - installed Issues that have been merged to master branch and are ready for final confirmation. labels May 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
4 - verified Issues that have been released and confirmed resolved. ArcGIS Online Issues logged by ArcGIS Online team members. c-table Issues that pertain to the calcite-table and related components calcite-components Issues specific to the @esri/calcite-components package. enhancement Issues tied to a new feature or request. estimate - 2 Small fix or update, may require updates to tests. impact - p3 - not time sensitive User set priority impact status of p3 - not time sensitive
Projects
None yet
Development

No branches or pull requests

4 participants