import { setMode } from '@stencil/core/internal/client';
export { setAssetPath, setNonce, setPlatformOptions } from '@stencil/core/internal/client';

const appGlobalScript = () => {
  const themeResolver = (elm) => {
    const theme = elm.theme || elm.getAttribute('theme');
    if (theme) {
      return theme;
    }
    else if (!elm.parentElement) {
      return 'ec';
    }
    else {
      return themeResolver(elm.parentElement);
    }
  };
  setMode((elm) => {
    return themeResolver(elm);
  });
};

const globalScripts = appGlobalScript;

globalScripts();

//# sourceMappingURL=index.js.map