403Webshell
Server IP : 192.158.238.246  /  Your IP : 3.16.56.30
Web Server : LiteSpeed
System : Linux uniform.iwebfusion.net 4.18.0-553.27.1.lve.1.el8.x86_64 #1 SMP Wed Nov 20 15:58:00 UTC 2024 x86_64
User : jenniferflocom ( 1321)
PHP Version : 8.1.32
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /proc/7779/task/7779/cwd/plugins/give/src/FormBuilder/resources/js/form-builder/src/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /proc/7779/task/7779/cwd/plugins/give/src/FormBuilder/resources/js/form-builder/src/App.tsx
import {ShortcutProvider} from '@wordpress/keyboard-shortcuts';
import BlockEditorContainer from './containers/BlockEditorContainer';
import {FormStateProvider} from './stores/form-state';
import {Storage} from './common';
import defaultBlocks from './blocks.json';
import {BlockInstance} from '@wordpress/blocks';
import './App.scss';
import FormBuilderErrorBoundary from '@givewp/form-builder/errors/FormBuilderErrorBounday';
import Transfer from '@givewp/form-builder/components/onboarding/transfer';
import {EditorStateProvider} from "@givewp/form-builder/stores/editor-state";

const {blocks: initialBlocks, formSettings: initialFormSettings} = Storage.load();

const initialState = {
    blocks: initialBlocks || (defaultBlocks as BlockInstance[]),
    settings: {
        ...initialFormSettings,
    },
    transfer: {
        showNotice: Boolean(window.migrationOnboardingData.transferShowNotice),
        showUpgradeModal: Boolean(window.migrationOnboardingData.showUpgradeDialog),
        showTransferModal: false,
        showTooltip: false,
    }
};

if (initialBlocks instanceof Error) {
    alert('Unable to load initial blocks.');
    console.error(initialBlocks);
}

if (ShortcutProvider === undefined) {
    console.error('ShortcutProvider is undefined.');
}

/**
 * This is a workaround for a bug where the draggable cursor does not reset.
 *
 * @since 3.0.0
 */
document.addEventListener('dragend', () => {
    // Reset the drag cursor.
    document.body.classList.remove('is-dragging-components-draggable');

    // Scroll the interface down by 1px to force a repaint and reset the popover position.
    document.getElementsByClassName('interface-interface-skeleton__body')[0].scrollBy(0,1);
});

export default function App() {
    return (
        <FormBuilderErrorBoundary>
            <EditorStateProvider initialState={{mode: 'design'}}>
                <FormStateProvider initialState={initialState}>
                    <ShortcutProvider>
                        <BlockEditorContainer />
                        <Transfer />
                    </ShortcutProvider>
                </FormStateProvider>
            </EditorStateProvider>
        </FormBuilderErrorBoundary>
    );
}

Youez - 2016 - github.com/yon3zu
LinuXploit