Skip to content
Merged
Changes from all commits
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: 3 additions & 3 deletions packages/patterns/src/components/reset-overrides-control.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
*/
import {
store as blockEditorStore,
BlockControls,
__unstableBlockToolbarLastItem as BlockToolbarLastItem,
Copy link
Member

Choose a reason for hiding this comment

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

It looks like we're not currently using that for anything. 🤔

Copy link
Member

Choose a reason for hiding this comment

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

It was introduced in #39290.

Copy link
Member

Choose a reason for hiding this comment

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

Maybe @youknowriad has an opinion here (I think you added the grouping once upon a time). But I'm not against this approach.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

You're right it is not used anymore 🤷 It seems it was also used in this pull request, and the initial implementation was "removed" in this other one.

} from '@wordpress/block-editor';
import { ToolbarButton, ToolbarGroup } from '@wordpress/components';
import { useRegistry, useSelect } from '@wordpress/data';
Expand Down Expand Up @@ -79,12 +79,12 @@ export default function ResetOverridesControl( props ) {
}

return (
<BlockControls group="other">
<BlockToolbarLastItem>
<ToolbarGroup>
<ToolbarButton onClick={ onClick } disabled={ ! isOverriden }>
{ __( 'Reset' ) }
</ToolbarButton>
</ToolbarGroup>
</BlockControls>
</BlockToolbarLastItem>
);
}