index.html 2.15 KB
Newer Older
Rushikesh Padsala's avatar
Rushikesh Padsala committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    <meta name="viewport" content="initial-scale=1, maximum-scale=1,user-scalable=no"/>
    <title>BuildingViewer</title>
    <meta name="viewport" content="minimal-ui">
    <link rel="stylesheet" href="https://jsdev.arcgis.com/4.20/esri/themes/light/main.css">
    <link rel="stylesheet" href="https://s3-us-west-1.amazonaws.com/patterns.esri.com/files/calcite-web/1.2.4/css/calcite-web.min.css">
    <link rel="stylesheet" href="./src/css/main.css">
    <link rel="stylesheet" href="./src/js/sections/css/sections.css">
    <link rel="stylesheet" href="./src/js/widgets/widgets.css">
    <link href="https://fonts.googleapis.com/css?family=Roboto" rel="stylesheet">
    <link href="https://fonts.googleapis.com/css?family=Roboto+Condensed" rel="stylesheet">
    <script>
      var locationPath = location.pathname.replace(/\/[^\/]+$/, "/");
      window.dojoConfig = {
        packages: [
          {
            name: "app",
            location: locationPath + "src/js/"
          }
        ]
      };
    </script>
    <script src="https://js.arcgis.com/4.20/"></script>
    <!-- include: "type": "js", "files": "**/*.js" -->
  </head>
  <body>
    <div id="mainViewDiv"></div>
    <div id="appDiv">
    </div>
    <script>require([
      "app/BuildingViewer", 
      "app/config",
      "dojo/domReady!"
    ], 
    function(
      BuildingViewer,
      config
    ) {

      var args = {
        // The container where to display the map:
        mapContainer: "mainViewDiv",

        // The id to the scene for the BSL you'd like to display:
        websceneId: config.websceneId,

        // Your different sections:
        sections: config.sections,

        // The container where to display the html element:
        container: document.getElementById("appDiv")
      };

      if (config.portalUrl) {
        args.portalUrl = config.portalUrl;
      }

      if (config.floorMapping) {
        args.floorMapping = config.floorMapping;
      }

      if (config.extraQuery) {
        args.extraQuery = config.extraQuery;
      }

      new BuildingViewer(args);
    });</script>
  </body>
</html>