SILENT KILLERPanel

Current Path: > home > codekrsu > > ameliagraphics.com > wp-content > plugins > > > essential-blocks > > src > store


Operation   : Linux premium131.web-hosting.com 4.18.0-553.44.1.lve.el8.x86_64 #1 SMP Thu Mar 13 14:29:12 UTC 2025 x86_64
Software     : Apache
Server IP    : 162.0.232.56 | Your IP: 216.73.216.111
Domains      : 1034 Domain(s)
Permission   : [ 0755 ]

Files and Folders in: /home/codekrsu//ameliagraphics.com/wp-content/plugins///essential-blocks//src/store

NameTypeSizeLast ModifiedActions
actions.js File 6270 bytes February 26 2025 16:22:10.
constant.js File 1857 bytes February 26 2025 16:22:10.
controls.js File 3806 bytes February 26 2025 16:22:10.
index.js File 496 bytes August 27 2024 16:37:06.
reducer.js File 2835 bytes February 26 2025 16:22:10.
resolvers.js File 1509 bytes August 27 2024 16:37:06.
selectors.js File 1982 bytes February 26 2025 16:22:10.

Reading File: /home/codekrsu//ameliagraphics.com/wp-content/plugins///essential-blocks//src/store/controls.js

/**
 * Import Helper Functions
*/
import {
    ebJsonStringCheck
} from "@essential-blocks/controls";

/**
 * Import Constants
 */
import {
    globalColorKey,
    customColorKey,
    gradientColorKey,
    customGradientColorKey,
    globalTypoKey,
    blockDefaultsKey,
} from "./constant";

/**
 * Import Fetch Functions
 */
import {
    getGlobalSettings,
    getBlockDefaults
} from '../helpers/fetch';

/**
 * Fetch Global Color from Database using AJAX
 * @returns {Object || false}
 */
export function FETCH_GLOBAL_COLORS() {
    return getGlobalSettings().then(response => {
        if (response && typeof response === 'object') {
            if (response[globalColorKey] && ebJsonStringCheck(response[globalColorKey]) && typeof JSON.parse(response[globalColorKey]) === 'object') {
                return JSON.parse(response[globalColorKey])
            }
            else {
                return false
            }
        }
        else {
            return false
        }
    });
}

/**
 * Fetch Custom Color from Database using AJAX
 * @returns {Object || false}
 */
export function FETCH_CUSTOM_COLORS() {
    return getGlobalSettings().then(response => {
        if (response && typeof response === 'object') {
            if (response[customColorKey] && ebJsonStringCheck(response[customColorKey]) && typeof JSON.parse(response[customColorKey]) === 'object') {
                return JSON.parse(response[customColorKey])
            }
            else {
                return false
            }
        }
        else {
            return false
        }
    });
}

/**
 * Fetch Gradient Color from Database using AJAX
 * @returns {Object || false}
 */
export function FETCH_GRADIENT_COLORS() {
    return getGlobalSettings().then(response => {
        if (response && typeof response === 'object') {
            if (response[gradientColorKey] && ebJsonStringCheck(response[gradientColorKey]) && typeof JSON.parse(response[gradientColorKey]) === 'object') {
                return JSON.parse(response[gradientColorKey])
            }
            else {
                return false
            }
        }
        else {
            return false
        }
    });
}

/**
 * Fetch Custom Gradient Color from Database using AJAX
 * @returns {Object || false}
 */
export function FETCH_CUSTOM_GRADIENT_COLORS() {
    return getGlobalSettings().then(response => {
        if (response && typeof response === 'object') {
            if (response[customGradientColorKey] && ebJsonStringCheck(response[customGradientColorKey]) && typeof JSON.parse(response[customGradientColorKey]) === 'object') {
                return JSON.parse(response[customGradientColorKey])
            }
            else {
                return false
            }
        }
        else {
            return false
        }
    });
}

/**
 * Fetch Global Typography from Database using AJAX
 * @returns {Object || false}
 */
export function FETCH_GLOBAL_TYPOGRAPHY() {
    return getGlobalSettings().then(response => {
        if (response && typeof response === 'object') {
            if (response[globalTypoKey] && ebJsonStringCheck(response[globalTypoKey]) && typeof JSON.parse(response[globalTypoKey]) === 'object') {
                return JSON.parse(response[globalTypoKey])
            }
            else {
                return false
            }
        }
        else {
            return false
        }
    });
}

/**
 * Fetch Block Defaults from Database using AJAX
 * @returns {Object || false}
 */
export function FETCH_BLOCK_DEFAULTS() {
    return getBlockDefaults().then(response => {
        if (response && ebJsonStringCheck(response) && typeof JSON.parse(response) === 'object') {
            return JSON.parse(response)
        }
        else {
            return false
        }
    });
}

SILENT KILLER Tool