How to use the @webiny/app-page-builder/editor/selectors.getActiveElement function in @webiny/app-page-builder

To help you get started, we’ve selected a few @webiny/app-page-builder examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github webiny / webiny-js / packages / app-page-builder / src / editor / plugins / elementSettings / border / Selector.js View on Github external
(state, { valueKey }: Object) => {
        return {
            value: get(getActiveElement(state), valueKey, 0)
        };
    },
    null,
github webiny / webiny-js / packages / app-page-builder / src / editor / plugins / elementSettings / components / Input.js View on Github external
export default connect((state, { value, valueKey, defaultValue }: Object) => {
    return {
        value: valueKey ? get(getActiveElement(state), valueKey, defaultValue) : value
    };
})(Input);
github webiny / webiny-js / packages / app-page-builder / src / editor / plugins / elementSettings / bar / ElementSettingsBar.js View on Github external
state => {
        const element = getActiveElement(state);
        return {
            elementType: element ? element.type : null
        };
    },
    { deactivateElement }
github webiny / webiny-js / packages / app-page-builder / src / editor / plugins / elementSettings / components / PMSettings.js View on Github external
(state, { styleAttribute }: Object) => {
        const valueKey = "data.settings." + styleAttribute;
        const element = getActiveElement(state);
        return {
            valueKey,
            advanced: get(element, valueKey + ".advanced", false),
            element: {
                id: element.id,
                type: element.type,
                path: element.path
            }
        };
    },
    { updateElement },
github webiny / webiny-js / packages / app-page-builder / src / editor / plugins / elementSettings / components / ColorPicker.js View on Github external
export default connect((state, { value, valueKey, defaultValue }: Object) => {
    return {
        value: valueKey ? get(getActiveElement(state), valueKey, defaultValue) : value
    };
})(ColorPicker);
github webiny / webiny-js / packages / app-page-builder / src / editor / plugins / elementSettings / border / Settings.js View on Github external
state => {
        const { id, type, path } = getActiveElement(state);
        return { element: { id, type, path } };
    },
    { updateElement },

@webiny/app-page-builder

[![](https://img.shields.io/npm/dw/@webiny/app-page-builder.svg)](https://www.npmjs.com/package/@webiny/app-page-builder) [![](https://img.shields.io/npm/v/@webiny/app-page-builder.svg)](https://www.npmjs.com/package/@webiny/app-page-builder) [![code sty

MIT
Latest version published 2 days ago

Package Health Score

80 / 100
Full package analysis

Similar packages