-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
170 lines (166 loc) · 8.55 KB
/
index.html
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
161
162
163
164
165
166
167
168
169
170
<!DOCTYPE html>
<html lang="en-US" id="html">
<head>
<meta charset="utf-8" />
<link rel="icon" href="/favicon.ico" />
<meta name="theme-color" content="#000000" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<link rel="apple-touch-icon" href="/public/static/assets/manifest/logo192.png" />
<meta name="description" content="3D Model Viewer in your right browser" />
<link rel="stylesheet" href="/src/style.css" />
<link rel="manifest" href="/manifest.json" />
<title>3D Viewer</title>
</head>
<body id="body">
<div id="root">
<titleBar></titleBar>
<div id="splash-screen">
<div class="loaderImg">
<img src="/public/static/assets/manifest/logo512.png" />
</div>
<span class="loader"></span>
</div>
<div id="main">
<div id="settings">
<div class="seetingsComponent">
<div class="closeSettingsBtn" onClick="closeSettings()">×</div>
<div class="tab">
<button class="tablinks" onclick="openSettingsTab(event, 'Appearance')"
id="defaultOpen">Appearance</button>
<button class="tablinks" onclick="openSettingsTab(event, 'Language')">Language</button>
<button class="tablinks" onclick="openSettingsTab(event, 'Exposure')">Exposure</button>
<button class="tablinks" onclick="openSettingsTab(event, 'About')">About</button>
</div>
<div id="Appearance" class="tabcontent">
<h2 style="margin-bottom: 20px;margin-top: 20px;">Customize appearance</h2>
<div class="lightingModeToggle" style="margin-left: 15px;display: flex;gap: 10px;">
<label class="control radio">
<input type="radio" checked id="radio" name="radio">
<span class="control-indicator"></span>
Light Mode
</label>
<label class="control radio">
<input type="radio" id="radio" name="radio">
<span class="control-indicator"></span>
Dark Mode
</label>
</div>
</div>
<div id="Language" class="tabcontent">
<h2 style="margin-bottom: 20px;margin-top: 20px;">Change language</h2>
<label class="select">
<select style="margin-left: 15px;"></select>
</label>
</div>
<div id="Exposure" class="tabcontent">
<h2 style="margin-bottom: 20px;margin-top: 20px;">Exposure</h2>
<input type="range" id="exposure" name="exposure" min="0" max="100" value="75" style="margin-left: 15px;width: 300px;" />
</div>
<div id="About" class="tabcontent">
<h2 style="margin-bottom: 20px;margin-top: 20px;">About</h2>
<div style="margin-left: 15px;">
<div class="about"><img class="appLogo" src="/public/static/assets/manifest/logo192.png"
aria-hidden="true">
<div class="aboutContent"><span class="appName">3D Viewer</span><span class="appVer"
id="aboutSection_channel_version_id">
Version 1.0.6
(Official build)</span></div>
</div>
</div>
<div style="margin: 50px;font-size: 18px;width: 470px;">3D Model Viewer ⚡ powered by <a
href="https://github.com/google/model-viewer">@google/model-viewer</a> & jQuery.This
Open
Source project is available ☞ <a href="https://github.com/SatyamV7/model-viewer">here</a>.
<br /> Developed by <a href="https://github.com/SatyamV7/">@SatyamV7</a>
</div>
</div>
</div>
</div>
</section>
<header>
<center>
<h1>3D Viewer</h1>
</center>
</header>
<section>
<nav>
<div class="navigationButtons">
<div class="navigationToggleButtons">
<div style="margin-top: 3px;">

</div>
</div>
<span style=" --i:1;" style="margin-top: 4px 0 3px 0" onClick="openSettings();exitNavigation()">
<span>
<div>

</div>
</span>
</span>
<span style="--i:2;" style="margin-top: 4px 0 3px 0" onClick="exitNavigation()">
<span>
<div id="fileInput">
<label class="file">
<input type="file" id="file" accept="model/gltf, model/gltf-binary, .gltf, .glb"
aria-label="File input" onChange="toggleFullScreen();readURL(this)"
hidden="hidden" />
<text class="file-custom-open"></text>
</label>
</div>
</span>
</span>
<span style="--i:3;" style="margin-top: 4px 0 3px 0;"
onClick="toggleFullScreen();exitNavigation()" class="toggleFullScreen">
<span>
<div>

</div>
</span>
</span>
<span style="margin-top: 4px 0 3px 0;" onClick="exitFullScreen();exitNavigation()"
class="exitFullScreen">
<span>
<div>

</div>
</span>
</span>
</div>
</nav>
<div class="fileInput">
<label class="file">
<input type="file" onChange="toggleFullScreen();readURL(this)" id="file"
accept="model/gltf, model/gltf-binary, .gltf, .glb" aria-label="File input" />
<span class="file-custom"></span>
</label>
</div>
<model-viewer id="model-viewer" alt="A 3D Model" loading="eager" reveal="auto"
poster="/public/static/assets/images/poster.jpg" autoplay ar ar-modes="webxr" shadow-intensity="1"
camera-controls touch-action="pan-y" exposure="auto"></model-viewer>
</section>
<footer>
<center>
<hr />
<h5>Made with ❤️ by <a target="_blank" href="https://github.com/SatyamV7/">Satyam Verma</a></h5>
</center>
</footer>
</div>
<script src="/src/jquery.min.js"></script>
<script type="module" src="/src/model-viewer.min.js"></script>
<script src="/src/script.js"></script>
<script>
if ('serviceWorker' in navigator) {
window.addEventListener('load', function () {
navigator.serviceWorker.register('serviceworker.js').then(function (registration) {
// Registration was successful
console.log('ServiceWorker registration successful with scope: ', registration.scope);
}, function (err) {
// registration failed :(
console.log('ServiceWorker registration failed: ', err);
});
});
}
</script>
</div>
</body>
</html>