forked from OHDSI/Atlas
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
160 lines (141 loc) · 6.32 KB
/
Copy pathindex.html
File metadata and controls
160 lines (141 loc) · 6.32 KB
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
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
<!DOCTYPE html>
<html lang="en">
<head>
<base href="/atlas/">
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="">
<meta name="author" content="">
<link rel="shortcut icon" href="images/favicon.ico" type="image/x-icon" />
<link rel="stylesheet" href="js/styles/splash.css" />
<link rel="stylesheet" href="js/styles/browserWarning.css" />
<title data-bind="text: pageTitle">ATLAS</title>
<script src="node_modules/bowser/bundled.js"></script>
<script>
// Atlas and Portal should share the same origin
// https://developer.mozilla.org/en-US/docs/Web/API/Window/postMessage
const originUrl = `${window.location.protocol}//${window.location.hostname}${window.location.port ? ':' + window.location.port : ''}`;
window.addEventListener('message', (event) => {
if (event.origin !== originUrl || event.data?.source?.includes("react-devtools")) {
// Ignore messages from React DevTools
return;
}
if (!event?.data?.token) {
console.error('No D2E token passed from portal')
return
}
sessionStorage.setItem("d2e-token", event.data.token);
sessionStorage.setItem("d2e-datasetId", event.data.datasetId);
sessionStorage.setItem("d2e-username", event.data.username);
})
</script>
</head>
<body class="app">
<div id="b-alarm" style="display: none" class="browser-alarm" data-bind="visible: toggleBrowserWarning(bowser)">
<div class="browser-alarm__warning-text" data-bind="text: ko.i18n('commonErrors.browserWarning', 'Note that only Chrome browser newer than v.63 is officially supported')">
Note that only Chrome browser newer than v.63 is officially supported
</div>
<button type="button" class="close browser-alarm__close" onclick="toggleWarning(true)">×</button>
</div>
<!-- ko if: !initializationComplete() -->
<div id="splash">
<div id="stage">
<img src="images/atlas_loading.svg" />
</div>
<div id="heading">
<a href="#/search">ATLAS</a>
</div>
<div data-bind="text:applicationStatus" id="status"></div>
</div>
<!-- /ko -->
<div data-bind="css: classes('container')">
<div style="display:none;" data-bind="visible: initializationComplete(), css: classes({ element: 'menu-container'})">
<div id="wrapperLogo">
<a href="#/home">ATLAS</a>
</div>
<div class="app__menu">
<a
style="cursor: pointer;"
data-bind="click: function() {
window.parent.postMessage(
{ type: 'CLOSE_ATLAS' },
`${window.location.protocol}//${window.location.hostname}${window.location.port ? ':' + window.location.port : ''}`
);},
css: $root.classes({ element: 'menu-item', modifiers: '' })"
>
<i data-bind="css: $root.classes({ element: 'menu-icon', extra: `fa fa-fw fa-chevron-circle-left`})" aria-hidden="true"></i>
<span
data-bind="text: 'Back to Cohorts', css: $root.classes('menu-title')"
></span>
</a>
<!-- ko foreach: router.pages -->
<a data-bind="visible: !$data.hidden, attr: {href: navUrl()}, css: $parent.classes({ element: 'menu-item', modifiers: $parent.router.activeRoute().title === $data.title ? 'selected' : '', extra: statusCss() })">
<i data-bind="css: $parent.classes({ element: 'menu-icon', extra: `fa fa-fw fa-${icon}`})" aria-hidden="true"></i>
<span data-bind="text: $data.title, css: $parent.classes('menu-title')"></span>
</a>
<!-- /ko -->
</div>
<!-- ko if: !companyInfoTemplate && showCompanyInfo-->
<div class="wrapper_ohdsi">
<div><a href="https://www.apache.org/licenses/LICENSE-2.0">Apache 2.0</a></div>
<div style="margin-bottom:10px;">open source software</div>
<div>provided by</div>
<div><a href="http://www.ohdsi.org"><img src="images/ohdsi_color.png"></a></div>
<div><a href="http://www.ohdsi.org">join the journey</a></div>
</div>
<!-- /ko -->
<!-- ko if: companyInfoTemplate && showCompanyInfo-->
<div class="wrapper_ohdsi" data-bind="html: companyInfoTemplate"></div>
<!-- /ko -->
</div>
<div id="wrapperMainWindow" style="display:none;" data-bind="visible:initializationComplete(), css: classes({ element: 'main-window'})">
<div id="wrapperMainWindowContainer">
<user-bar params="{model: $data}"></user-bar>
<div data-bind="if: !router.currentViewAccessible()">
<div style="width:100px;margin-left:auto;margin-right:auto;">
<svg width="100" height="100" viewBox="0 -200 400 400">
<g id="rings">
<circle cx="205" cy="17" r="165" stroke="#800" fill="none" stroke-width="15px"></circle>
<ellipse cx="205" cy="17" rx="70" ry="70" stroke="#f00" fill="none" stroke-width="6px" stroke-opacity="0.4">
</ellipse>
<ellipse cx="205" cy="17" rx="100" ry="100" stroke="#c00" fill="none" stroke-width="10px" stroke-opacity="0.4">
</ellipse>
<ellipse cx="205" cy="17" rx="135" ry="135" stroke="#800" fill="none" stroke-width="12px" stroke-opacity="0.4">
</ellipse>
</g>
</svg>
</div>
<div class="error" data-bind="text: ko.i18n('commonErrors.initFailed', 'Application initialization failed')"></div>
<div class="error">
<p data-bind="html: appInitializationErrorMessage"></p>
</div>
</div>
<!-- ko ifnot: EventBus.errorMsg() -->
<div data-bind="if: $data.router.currentViewAccessible" class="flexed">
<div id="currentComponent" class="flexed" data-bind='component: {name: $data.router.currentView, params: { router: $data.router, model: $data } }'></div>
</div>
<!-- /ko -->
<div data-bind="if: EventBus.errorMsg()" class="flexed">
<div class="empty-state flexed">
<span class="empty-state empty-state__message" data-bind="text: EventBus.errorMsg()"></span>
</div>
</div>
</div>
</div>
</div>
<!-- ko if: appInitializationStatus() === 'running' -->
<terms-and-conditions params="model: $data"></terms-and-conditions>
<!-- /ko -->
<script>
// define waitSeconds above require script tag
// to override the default, until main.js loads
//see https://github.com/yeoman/yeoman/issues/1051
window.require = { waitSeconds: 0 };
</script>
<!-- non-bundled mode -->
<script data-main="js/main" src="js/require.js"></script>
<!-- bundled mode -->
<!-- <script data-main="js/assets/bundle/bundle" src="js/require.js"></script>-->
</body>
</html>