Always add custom fields category to block inserter
[MAILPOET-2463]
This commit is contained in:
committed by
Pavel Dohnal
parent
e251d81a9d
commit
1d1cb3ec2b
@ -29,9 +29,8 @@ export const initBlocks = () => {
|
||||
const categories = [
|
||||
{ slug: 'obligatory', title: '' }, // Blocks from this category are not in block insert popup
|
||||
];
|
||||
if (Array.isArray(customFields) && customFields.length) {
|
||||
categories.push({ slug: 'custom-fields', title: MailPoet.I18n.t('customFieldsBlocksCategory') });
|
||||
}
|
||||
|
||||
categories.push({ slug: 'custom-fields', title: MailPoet.I18n.t('customFieldsBlocksCategory') });
|
||||
categories.push({ slug: 'fields', title: MailPoet.I18n.t('fieldsBlocksCategory') });
|
||||
setCategories(categories);
|
||||
|
||||
|
@ -27,11 +27,11 @@ class FormEditorAddNamesCest {
|
||||
|
||||
$i->click('.block-list-appender button');// CLICK the big button that adds new blocks
|
||||
$i->waitForElement('.editor-inserter__results .components-panel__body-toggle');
|
||||
$i->click('.editor-inserter__results .components-panel__body-toggle'); // toggle fields
|
||||
$i->click('.editor-inserter__results .components-panel__body:nth-child(2) .components-panel__body-toggle'); // toggle fields
|
||||
$i->click('.editor-block-list-item-mailpoet-form-first-name-input'); // add first name block to the editor
|
||||
$i->click('.block-list-appender button');// CLICK the big button that adds new blocks
|
||||
$i->waitForElement('.editor-inserter__results .components-panel__body-toggle');
|
||||
$i->click('.editor-inserter__results div:nth-child(2) .components-panel__body-toggle'); // toggle fields, get the second field, first one is now "Most Used"
|
||||
$i->click('.editor-inserter__results .components-panel__body:nth-child(3) .components-panel__body-toggle'); // toggle fields, get the second field, first one is now "Most Used"
|
||||
$i->click('.editor-block-list-item-mailpoet-form-last-name-input'); // add last name block to the editor
|
||||
|
||||
$i->click('[data-automation-id="form_save_button"]');
|
||||
|
Reference in New Issue
Block a user