Skip to content

Support an "sp-action-menu" w/o value #350

@Westbrook

Description

@Westbrook

I'm working with an sp-action-menu instance that doesn't want for a specific sp-menu-item to be selected or for the sp-action-menu to have a value. This is different than the current version which implements an extension of sp-dropdown and always has a value and selected menu item. It's unclear whether this element should just not have a value, ever, or whether we should add an attribute that can prevent it from managing this data.

Thoughts on whether this pattern should ever have a value/manage the selected attribute on its children? This is lightly implied by the lack of designs to support these states: https://opensource.adobe.com/spectrum-css/components/actionmenu/

On the attribute based flag site, it might might sense to use an action-only attribute, which would leave the following implementation as not managing a value property or setting selected on it's children:

                <sp-action-menu action-only>
                    <span slot="icon">More</span>
                    <sp-menu slot="options">
                        <sp-menu-item @click=${doFlipHorizontal}>
                            Flip Horizontally
                        </sp-menu-item>
                        <sp-menu-item @click=${doFlipVertical}>
                            Flip Vertically
                        </sp-menu-item>
                    </sp-menu>
                </sp-action-menu>

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions