import { setConfig } from '../../utils/config.mjs';
import '../../composables/index.mjs';
import Viewer from './src/index.mjs';
import useLog from '../../composables/private/use-log.mjs';
import { version } from '../../version.mjs';
import { localeProviderMaker, LocaleInjectionKey } from '../../composables/use-locale/index.mjs';

const logger = useLog(void 0);
Viewer.install = (app, opts) => {
  const defaultInstallOpt = {
    cesiumPath: "https://cdn.jsdelivr.net/npm/cesium@latest/Build/Cesium/Cesium.js",
    accessToken: "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJqdGkiOiI5Y2U0ZTk2Ni1jNzdkLTQ3OWYtYjVmYS0yMGM3YTk3NjgzMmUiLCJpZCI6Njk5Nywic2NvcGVzIjpbImFzciIsImdjIl0sImlhdCI6MTU0ODA1MTc0OH0.Csy6yyAnv6JSBppH0Ou3ahshqcHFEhP27iOz5gjQMEo"
  };
  const option = Object.assign(defaultInstallOpt, opts);
  if (option.locale) {
    const localeProvides = localeProviderMaker(opts.locale);
    localeProvides && app.provide(LocaleInjectionKey, localeProvides);
  }
  app.config.globalProperties.$VueCesium = option;
  setConfig(option);
  app.component(Viewer.name, Viewer);
  if (process.env.NODE_ENV === "development") {
    logger.capsule("VueCesium", `v${version}`);
    logger.success("VueCesium  https://github.com/zouyaoji/vue-cesium");
    logger.success("Document  https://zouyaoji.top/vue-cesium");
    logger.success(`If you like it, give it a star reward, ^_^`);
    logger.success(`\u8868\u793A\u8D5E\uFF0C\u7ED9\u5B83\u4E00\u4E2A\u661F\u661F\u5956\u52B1\uFF0C^_^`);
  }
};
const _Viewer = Viewer;
const VcViewer = _Viewer;

export { VcViewer, _Viewer as default };
//# sourceMappingURL=index.mjs.map
