<script lang="ts" setup>
import {AppMain, Navbar} from '@/layout/components/index.js'
import AntvMap from '@/components/AntvMap/index.vue'

let navbarHeight = '12vh'

let theme = ''
let navbarStyle = {height: navbarHeight}
</script>

<template>
  <div :style="{ '--current-color': theme }" class="app-wrapper">

    <antv-map class="floor-container"></antv-map>

    <!-- 顶部阴影 -->
    <div class="header-shade"></div>
    <!-- 底部阴影 -->
    <!--    <div class="bottom-shade"></div>-->
    <!-- 左侧阴影 -->
    <div class="left-shade"></div>
    <!-- 右侧阴影 -->
    <div class="right-shade"></div>

    <!-- 主页 -->
    <div class="main-container">
      <!-- 顶部 -->
      <navbar :style="navbarStyle"/>
      <!-- 展示页 -->
      <app-main/>
    </div>
  </div>
</template>

<style lang="scss" scoped>
@use '@/assets/styles/mixin.scss';
@use '@/assets/styles/variables.scss';

$base-background-color: rgba(10, 117, 195, 0.6);
$base-background-color2: rgba(10, 117, 195, 1);

.app-wrapper {
  height: 100%;
  width: 100%;
  pointer-events: none;

  .main-container {
    // background: linear-gradient(120deg, #6236ff 0%, #6236ff 0%, #32c5ff 99%, #32c5ff 100%);
    width: 100%;
    height: 100%;
    position: relative;

    .header-container {
      width: 100%;
      background-image: linear-gradient(132deg, #4791f8 0%, #2d3bdb 100%);
    }

    .app-main {
      position: absolute;
      top: 8vh;
      left: 0;
      width: 100%;
      height: 92vh;
    }
  }

  .floor-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
  }

  .header-shade {
    width: 100%;
    height: 8vh;
    top: 0;
    left: 0;
    background-image: linear-gradient(180deg,
      $base-background-color2 0%,
      rgba(0, 0, 0, 0) 100%);

  }

  .bottom-shade {
    width: 100%;
    height: 8vh;
    bottom: 0;
    left: 0;
    background-image: linear-gradient(0deg,
      $base-background-color 0%,
      rgba(0, 0, 0, 0) 100%);

  }

  .left-shade {
    top: 0;
    left: 0;
    background-image: linear-gradient(90deg,
      $base-background-color 0%,
      rgba(0, 0, 0, 0) 100%);
  }

  .right-shade {
    top: 0;
    right: 0;
    background-image: linear-gradient(270deg,
      $base-background-color 0%,
      rgba(0, 0, 0, 0) 100%);
  }

  .left-shade,
  .right-shade {
    width: 25vw;
    height: 100%;
  }

  .header-shade,
  .bottom-shade,
  .left-shade,
  .right-shade {
    pointer-events: none;
    //z-index: 1;
    position: absolute;
    background-size: 100% 100%;
    background-repeat: no-repeat;
    opacity: 1;
  }

}
</style>
