Skip to content

Commit

Permalink
Enable Previews for Navigation Link Blocks (#36412)
Browse files Browse the repository at this point in the history
* Enable Previews for Navigation Link Blocks in the Navigation editor and block editor

Closes #32555
  • Loading branch information
georgeh authored Nov 12, 2021
1 parent f2cbf5f commit 23412da
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions packages/block-library/src/navigation-link/edit.js
Original file line number Diff line number Diff line change
Expand Up @@ -722,6 +722,7 @@ export default function NavigationLinkEdit( {
>
<LinkControl
hasTextControl
hasRichPreviews
className="wp-block-navigation-link__inline-link-input"
value={ link }
showInitialSuggestions={ true }
Expand Down
2 changes: 2 additions & 0 deletions packages/edit-navigation/src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import {
import { dispatch, useDispatch } from '@wordpress/data';
import { render, useMemo } from '@wordpress/element';
import {
__experimentalFetchUrlData,
__experimentalFetchLinkSuggestions as fetchLinkSuggestions,
store as coreStore,
} from '@wordpress/core-data';
Expand Down Expand Up @@ -42,6 +43,7 @@ function NavEditor( { settings } ) {
...settings,
__experimentalFetchLinkSuggestions,
__experimentalSetIsInserterOpened,
__experimentalFetchRichUrlData: __experimentalFetchUrlData,
};
}, [
settings,
Expand Down

0 comments on commit 23412da

Please sign in to comment.