Skip to content

[List item] Child elements behavior can be toggled open without selection change and event dispatch #8515

@geospatialem

Description

@geospatialem

Check existing issues

Description

A way to opt in to an stripped-down behavior when clicking a list-item that contains nested list-items.

Originally posted in #6544, diverging the two separate functions - selection and filtering - for development efforts.

cc @nwhittaker

Acceptance Criteria

Clicking the content area of a list-item with nested list-items:

  • Toggle's the list-item's open property to show/hide the nested list-items.
  • Does not mark the list-item as selected and does not trigger its calciteListItemSelect event.
  • Does not deselect the previously selected list-item.
  • Clicking any of the list-item's actions does not toggle the open property.

Relevant Info

Originally posted in #6544, diverging the two separate functions - selection and filtering - for development efforts.

Which Component

list-item

Example Use Case

The Field Maps web app would like to use the calcite-list element to display the layers in a map. For group layers, nested layers are shown as child list-items.

Selecting a leaf layer navigates the app for further handling of the layer. However, the app does not provide further handling for group layers. They are treated more like folders that organize sets of layers -- so clicking them in the list should have no effect other than to drill down to leaf layers.

Priority impact

p2 - want for current milestone

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 Field Apps

Metadata

Metadata

Assignees

No one assigned

    Labels

    0 - newNew issues that need assignment.ArcGIS Field AppsIssues logged by ArcGIS Field Apps team members.c-listIssues that pertain to the calcite-list componentcalcite-componentsIssues specific to the @esri/calcite-components package.designIssues that need design consultation prior to, or during, development.enhancementIssues tied to a new feature or request.impact - p2 - want for an upcoming milestoneUser set priority impact status of p2 - want for an upcoming milestoneneed more infoIssues that are missing information and/or a clear, actionable description.needs triagePlanning workflow - pending design/dev review.p - mediumIssue is non core or affecting less that 60% of people using the library

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions