Move email editor components out of the engine folder
MAILPOET-6215
This commit is contained in:
committed by
Oluwaseun Olorunsola
parent
e6d607028c
commit
1c3ea9cd0a
@ -11,8 +11,8 @@
|
||||
"start": "wp-scripts start",
|
||||
"lint:css": "wp-scripts lint-style",
|
||||
"lint:css-fix": "wp-scripts lint-style --fix",
|
||||
"lint:js": "wp-scripts lint-js ./src/**",
|
||||
"lint:js-fix": "wp-scripts lint-js ./src/** --fix",
|
||||
"lint:js": "wp-scripts lint-js './src/**/*.{js,jsx,json,ts,tsx,yml,yaml}'",
|
||||
"lint:js-fix": "wp-scripts lint-js './src/**/*.{js,jsx,json,ts,tsx}' --fix",
|
||||
"check-types": "NODE_OPTIONS=--max_old_space_size=2048 tsc --noEmit",
|
||||
"format": "./node_modules/.bin/prettier --config .prettierrc.js --write 'src/**/*.{js,jsx,json,ts,tsx,yml,yaml}'"
|
||||
},
|
||||
|
@ -12,7 +12,7 @@ import { useMemo } from '@wordpress/element';
|
||||
import { SlotFillProvider, Spinner } from '@wordpress/components';
|
||||
import { Post, store as coreStore } from '@wordpress/core-data';
|
||||
import { storeName } from '../../store';
|
||||
import { unlock } from '../../../lock-unlock';
|
||||
import { unlock } from '../../lock-unlock';
|
||||
|
||||
/**
|
||||
* Internal dependencies
|
@ -8,7 +8,7 @@ import { store as blockEditorStore } from '@wordpress/block-editor';
|
||||
/**
|
||||
* Internal dependencies
|
||||
*/
|
||||
import { unlock } from '../../../../lock-unlock';
|
||||
import { unlock } from '../../../lock-unlock';
|
||||
|
||||
const DISTANCE_THRESHOLD = 500;
|
||||
|
@ -23,7 +23,7 @@ import { store as editorStore } from '@wordpress/editor';
|
||||
*/
|
||||
import EditTemplateBlocksNotification from './edit-template-blocks-notification';
|
||||
import useSelectNearestEditableBlock from './use-select-nearest-editable-block';
|
||||
import { unlock } from '../../../../lock-unlock';
|
||||
import { unlock } from '../../../lock-unlock';
|
||||
|
||||
export const TEMPLATE_POST_TYPE = 'wp_template';
|
||||
export const TEMPLATE_PART_POST_TYPE = 'wp_template_part';
|
@ -21,7 +21,7 @@ import { SaveButton } from './save-button';
|
||||
import { CampaignName } from './campaign-name';
|
||||
import { SendButton } from './send-button';
|
||||
|
||||
import { unlock } from '../../../lock-unlock';
|
||||
import { unlock } from '../../lock-unlock';
|
||||
|
||||
// Build type for ToolbarItem contains only "as" and "children" properties but it takes all props from
|
||||
// component passed to "as" property (in this case Button). So as fix for TS errors we need to pass all props from Button to ToolbarItem.
|
@ -2,7 +2,7 @@ import { __ } from '@wordpress/i18n';
|
||||
import * as React from '@wordpress/element';
|
||||
import { privateApis as componentsPrivateApis } from '@wordpress/components';
|
||||
import { mainSidebarEmailTab, mainSidebarBlockTab } from '../../store';
|
||||
import { unlock } from '../../../lock-unlock';
|
||||
import { unlock } from '../../lock-unlock';
|
||||
|
||||
const { Tabs } = unlock( componentsPrivateApis );
|
||||
|
@ -18,7 +18,7 @@ import {
|
||||
import { Header } from './header';
|
||||
import { EmailSettings } from './email-settings';
|
||||
import { TemplateSettings } from './template-settings';
|
||||
import { unlock } from '../../../lock-unlock';
|
||||
import { unlock } from '../../lock-unlock';
|
||||
|
||||
import './index.scss';
|
||||
|
@ -14,7 +14,7 @@ import {
|
||||
} from '@wordpress/blocks';
|
||||
import { addQueryArgs } from '@wordpress/url';
|
||||
import { storeName } from '../../store';
|
||||
import { unlock } from '../../../lock-unlock';
|
||||
import { unlock } from '../../lock-unlock';
|
||||
|
||||
// Todo: This is not available yet. Replace when possible.
|
||||
async function revertTemplate( template ) {
|
@ -5,7 +5,7 @@ import {
|
||||
privateApis as blockEditorPrivateApis,
|
||||
} from '@wordpress/block-editor';
|
||||
import ScreenHeader from './screen-header';
|
||||
import { unlock } from '../../../../lock-unlock';
|
||||
import { unlock } from '../../../lock-unlock';
|
||||
import { useEmailStyles } from '../../../hooks';
|
||||
import { storeName } from '../../../store';
|
||||
|
@ -5,7 +5,7 @@ import {
|
||||
// @ts-expect-error No types for this exist yet.
|
||||
privateApis as blockEditorPrivateApi,
|
||||
} from '@wordpress/block-editor';
|
||||
import { unlock } from '../../lock-unlock';
|
||||
import { unlock } from '../lock-unlock';
|
||||
import { EmailStyles, storeName } from '../store';
|
||||
import { useEmailTheme } from './use-email-theme';
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { initialize } from './engine/editor';
|
||||
import { initialize } from './editor';
|
||||
|
||||
window.addEventListener( 'DOMContentLoaded', () => {
|
||||
initialize( 'mailpoet-email-editor' );
|
||||
|
Reference in New Issue
Block a user