Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion src/components/action-bar/action-bar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,11 @@ export class ActionBar {
};

private renderCollapseExpandButton() {
if (!this.collapsible || this.actions.length <= 1) {
if (
!this.collapsible ||
this.actions.length <= 1 ||
this.layout !== 'floating'
) {
Comment on lines +212 to +216
Copy link
Contributor

Choose a reason for hiding this comment

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

I feel a bit unsure about having a prop, that only works when another prop is set to a certain state. This is what I was trying to communicate in the other issue as one of the reasons for reconsidering this design choice.

If you wanna keep this as a temporary solution for now, please update the documentations as well as documenting the prop itself as alpha and even perhaps private.

Like below:

    /**
     * When set to `true`, the action bar will be collapsible,
     * but only when the `layout` prop is also set to `floating`.
     * 
     * @private
     * @alpha
     */
    @Prop({ reflect: true })
    public collapsible = false;

As you see, the updated docs feels a bit strange. But if we make it alpha, it feels safer later to revert the changes.

return;
}

Expand Down