Skip to content
Merged
Show file tree
Hide file tree
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
22 changes: 1 addition & 21 deletions packages/block-library/src/query/edit/query-placeholder.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ export default function QueryPlaceholder( {
clientId,
name,
openPatternSelectionModal,
setAttributes,
} ) {
const [ isStartingBlank, setIsStartingBlank ] = useState( false );
const blockProps = useBlockProps();
Expand Down Expand Up @@ -64,7 +63,6 @@ export default function QueryPlaceholder( {
<QueryVariationPicker
clientId={ clientId }
attributes={ attributes }
setAttributes={ setAttributes }
icon={ icon }
label={ label }
/>
Expand Down Expand Up @@ -101,13 +99,7 @@ export default function QueryPlaceholder( {
);
}

function QueryVariationPicker( {
clientId,
attributes,
setAttributes,
icon,
label,
} ) {
function QueryVariationPicker( { clientId, attributes, icon, label } ) {
const scopeVariations = useScopedBlockVariations( attributes );
const { replaceInnerBlocks } = useDispatch( blockEditorStore );
const blockProps = useBlockProps();
Expand All @@ -118,18 +110,6 @@ function QueryVariationPicker( {
label={ label }
variations={ scopeVariations }
onSelect={ ( variation ) => {
if ( variation.attributes ) {
setAttributes( {
...variation.attributes,
query: {
...variation.attributes.query,
postType:
attributes.query.postType ||
variation.attributes.query.postType,
},
namespace: attributes.namespace,
} );
}
if ( variation.innerBlocks ) {
replaceInnerBlocks(
clientId,
Expand Down
3 changes: 3 additions & 0 deletions test/e2e/specs/editor/various/is-typing.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,9 @@ test.describe( 'isTyping', () => {
.getByRole( 'button', { name: 'Title & Date' } )
.click();

await editor.openDocumentSettingsSidebar();
await page.getByLabel( 'Inherit query from template' ).click();

// Moving the mouse shows the toolbar.
await editor.showBlockToolbar();
// Open the dropdown.
Expand Down