Skip to content

Commit

Permalink
Adjust expand button offset
Browse files Browse the repository at this point in the history
  • Loading branch information
kraenhansen committed Nov 5, 2024
1 parent 913c310 commit 8f71a2c
Showing 1 changed file with 14 additions and 6 deletions.
20 changes: 14 additions & 6 deletions packages/compass-editor/src/actions-container.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,12 @@ const actionsContainerStyle = css({
pointerEvents: 'none',
});

const expandContainerStyle = css({
position: 'relative',
top: -spacing[100],
left: -spacing[100],
});

const actionsGroupItemSeparator = css({
flex: '1 0 auto',
pointerEvents: 'none',
Expand All @@ -47,12 +53,14 @@ export const ActionsContainer = ({
)}
>
{onExpand && (
<ActionButton
label={expanded ? 'Collapse all' : 'Expand all'}
icon={expanded ? 'CaretDown' : 'CaretRight'}
onClick={onExpand}
compact
/>
<div className={expandContainerStyle}>
<ActionButton
label={expanded ? 'Collapse all' : 'Expand all'}
icon={expanded ? 'CaretDown' : 'CaretRight'}
onClick={onExpand}
compact
/>
</div>
)}
<span className={actionsGroupItemSeparator}></span>
{copyable && (
Expand Down

0 comments on commit 8f71a2c

Please sign in to comment.