From c8bca706e50d24757e9dc9968e181bbd01d1d498 Mon Sep 17 00:00:00 2001 From: Glen Davies Date: Mon, 9 May 2022 18:46:04 +1200 Subject: [PATCH] Move the new breakdown of the edit component into a subfolder --- packages/block-library/src/cover/{ => edit}/block-controls.js | 2 +- .../block-library/src/cover/{ => edit}/cover-placeholder.js | 2 +- packages/block-library/src/cover/{edit.js => edit/index.js} | 2 +- .../block-library/src/cover/{ => edit}/inspector-controls.js | 2 +- packages/block-library/src/cover/{ => edit}/resizeable-cover.js | 0 .../block-library/src/cover/{ => edit}/use-cover-is-dark.js | 0 packages/block-library/src/cover/test/block-controls.js | 2 +- 7 files changed, 5 insertions(+), 5 deletions(-) rename packages/block-library/src/cover/{ => edit}/block-controls.js (98%) rename packages/block-library/src/cover/{ => edit}/cover-placeholder.js (94%) rename packages/block-library/src/cover/{edit.js => edit/index.js} (99%) rename packages/block-library/src/cover/{ => edit}/inspector-controls.js (99%) rename packages/block-library/src/cover/{ => edit}/resizeable-cover.js (100%) rename packages/block-library/src/cover/{ => edit}/use-cover-is-dark.js (100%) diff --git a/packages/block-library/src/cover/block-controls.js b/packages/block-library/src/cover/edit/block-controls.js similarity index 98% rename from packages/block-library/src/cover/block-controls.js rename to packages/block-library/src/cover/edit/block-controls.js index 0417720138361..a08910ddddc49 100644 --- a/packages/block-library/src/cover/block-controls.js +++ b/packages/block-library/src/cover/edit/block-controls.js @@ -16,7 +16,7 @@ import { postFeaturedImage } from '@wordpress/icons'; /** * Internal dependencies */ -import { ALLOWED_MEDIA_TYPES } from './shared'; +import { ALLOWED_MEDIA_TYPES } from '../shared'; export default function CoverBlockControls( { attributes, diff --git a/packages/block-library/src/cover/cover-placeholder.js b/packages/block-library/src/cover/edit/cover-placeholder.js similarity index 94% rename from packages/block-library/src/cover/cover-placeholder.js rename to packages/block-library/src/cover/edit/cover-placeholder.js index aa9f6a565993e..2f3c070a90f36 100644 --- a/packages/block-library/src/cover/cover-placeholder.js +++ b/packages/block-library/src/cover/edit/cover-placeholder.js @@ -8,7 +8,7 @@ import { cover as icon } from '@wordpress/icons'; /** * Internal dependencies */ -import { ALLOWED_MEDIA_TYPES } from './shared'; +import { ALLOWED_MEDIA_TYPES } from '../shared'; export default function CoverPlaceholder( { disableMediaButtons = false, diff --git a/packages/block-library/src/cover/edit.js b/packages/block-library/src/cover/edit/index.js similarity index 99% rename from packages/block-library/src/cover/edit.js rename to packages/block-library/src/cover/edit/index.js index 4414d302d6ddd..513e222294dbd 100644 --- a/packages/block-library/src/cover/edit.js +++ b/packages/block-library/src/cover/edit/index.js @@ -38,7 +38,7 @@ import { isContentPositionCenter, getPositionClassName, mediaPosition, -} from './shared'; +} from '../shared'; import useCoverIsDark from './use-cover-is-dark'; import CoverInspectorControls from './inspector-controls'; import CoverBlockControls from './block-controls'; diff --git a/packages/block-library/src/cover/inspector-controls.js b/packages/block-library/src/cover/edit/inspector-controls.js similarity index 99% rename from packages/block-library/src/cover/inspector-controls.js rename to packages/block-library/src/cover/edit/inspector-controls.js index e93563669ab17..b060843c8e613 100644 --- a/packages/block-library/src/cover/inspector-controls.js +++ b/packages/block-library/src/cover/edit/inspector-controls.js @@ -29,7 +29,7 @@ import { __ } from '@wordpress/i18n'; /** * Internal dependencies */ -import { COVER_MIN_HEIGHT, mediaPosition } from './shared'; +import { COVER_MIN_HEIGHT, mediaPosition } from '../shared'; function CoverHeightInput( { onChange, diff --git a/packages/block-library/src/cover/resizeable-cover.js b/packages/block-library/src/cover/edit/resizeable-cover.js similarity index 100% rename from packages/block-library/src/cover/resizeable-cover.js rename to packages/block-library/src/cover/edit/resizeable-cover.js diff --git a/packages/block-library/src/cover/use-cover-is-dark.js b/packages/block-library/src/cover/edit/use-cover-is-dark.js similarity index 100% rename from packages/block-library/src/cover/use-cover-is-dark.js rename to packages/block-library/src/cover/edit/use-cover-is-dark.js diff --git a/packages/block-library/src/cover/test/block-controls.js b/packages/block-library/src/cover/test/block-controls.js index 25907f9fc7404..ea14dfb38d7b7 100644 --- a/packages/block-library/src/cover/test/block-controls.js +++ b/packages/block-library/src/cover/test/block-controls.js @@ -13,7 +13,7 @@ jest.mock( '@wordpress/block-editor', () => ( { /** * Internal dependencies */ -import CoverBlockControls from '../block-controls'; +import CoverBlockControls from '../edit/block-controls'; const setAttributes = jest.fn(); const onSelectMedia = jest.fn();