/*!
 * Built by Revolist OU ❤️
 */
'use strict';

var index = require('./index-Dq8Xzj5l.js');
var theme_service = require('./theme.service-BgnxGIjK.js');

function global () {
    index.setMode(elm => {
        let theme = elm.theme || elm.getAttribute('theme');
        if (typeof theme === 'string') {
            theme = theme.trim();
        }
        const parsedTheme = theme_service.getTheme(theme);
        if (parsedTheme !== theme) {
            elm.setAttribute('theme', parsedTheme);
        }
        return parsedTheme;
    });
}

const appGlobalScript = global || (() => {});
const globalScripts = appGlobalScript;

exports.globalScripts = globalScripts;
