Metaprime commited on
Commit
f91c403
ยท
verified ยท
1 Parent(s): 8fd9e2d

Update index.html

Browse files
Files changed (1) hide show
  1. index.html +140 -63
index.html CHANGED
@@ -1,72 +1,149 @@
1
  <!DOCTYPE html>
2
  <html>
3
  <head>
4
- <meta charset="UTF-8">
5
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
- <title>Holodeck</title>
7
- <style>
8
- body {
9
- margin: 0;
10
- background: #000;
11
- color: #0f0;
12
- font-family: monospace;
13
- text-align: center;
14
- overflow: hidden;
15
- }
16
- .galaxy {
17
- position: fixed;
18
- top: 0; left: 0; right: 0; bottom: 0;
19
- background: radial-gradient(circle at center, #112 0%, #000 70%);
20
- z-index: -1;
21
- }
22
- h1 {
23
- color: #0ff;
24
- font-size: 3.5em;
25
- margin-top: 80px;
26
- text-shadow: 0 0 30px #0ff;
27
- letter-spacing: 4px;
28
- }
29
- .status {
30
- background: rgba(0,255,0,0.08);
31
- border: 2px solid #0f0;
32
- padding: 25px;
33
- max-width: 620px;
34
- margin: 30px auto;
35
- border-radius: 12px;
36
- box-shadow: 0 0 25px rgba(0,255,0,0.3);
37
- }
38
- button {
39
- background: transparent;
40
- color: #0ff;
41
- border: 2px solid #0ff;
42
- padding: 14px 24px;
43
- margin: 10px;
44
- font-size: 1.1em;
45
- border-radius: 8px;
46
- cursor: pointer;
47
- }
48
- button:hover {
49
- background: rgba(0,255,255,0.1);
50
- }
51
- </style>
52
  </head>
53
  <body>
54
- <div class="galaxy"></div>
55
-
56
- <h1>๐ŸŒŒ HOLODECK</h1>
57
-
58
- <div class="status">
59
- <p>โœ… Running on Hugging Face Spaces</p>
60
- <p>MetaPrime Holodeck v0.1</p>
61
- </div>
62
 
63
- <div style="margin-top: 30px;">
64
- <button onclick="alert('3D Environment coming soon...')">๐ŸŒ  Enter 3D Environment</button>
65
- <button onclick="alert('AI Chat coming soon...')">๐Ÿ’ฌ Talk to MetaPrime</button>
66
- </div>
67
 
68
- <p style="margin-top: 80px; color:#555;">
69
- Built by iamlikegod1795-jpg โ€ข Private Space
70
- </p>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
71
  </body>
72
  </html>
 
1
  <!DOCTYPE html>
2
  <html>
3
  <head>
4
+ <meta charset="utf-8">
5
+ <title>Holodeck</title>
6
+ <script src="https://aframe.io/releases/1.6.0/aframe.min.js"></script>
7
+ <style>
8
+ #bead {
9
+ position:fixed; bottom:35px; left:30px; width:38px; height:38px;
10
+ background:rgba(255,30,30,0.08); border:2px solid #ff3366; border-radius:50%;
11
+ box-shadow:0 0 18px #ff3366, 0 0 35px #ff3366, inset 0 0 12px rgba(255,255,255,0.3);
12
+ z-index:1000; cursor:pointer;
13
+ }
14
+ #panel {
15
+ position:fixed; bottom:88px; left:22px; width:205px;
16
+ background:rgba(20,0,10,0.12); backdrop-filter:blur(18px);
17
+ border:2px solid #ff3366; box-shadow:0 0 25px #ff3366, 0 0 45px #ff3366;
18
+ border-radius:16px; padding:12px; display:none; flex-direction:column; gap:8px;
19
+ z-index:1002;
20
+ }
21
+ button {
22
+ background:rgba(255,50,50,0.08);
23
+ color:#ff99aa;
24
+ border:1px solid #ff3366;
25
+ box-shadow:0 0 12px #ff3366;
26
+ padding:11px 12px;
27
+ border-radius:10px;
28
+ font-size:15px;
29
+ margin: 4px 0;
30
+ }
31
+ #videoContainer {
32
+ position:fixed; bottom:170px; left:50%; transform:translateX(-50%);
33
+ width:380px; display:none; z-index:1000; background:rgba(0,0,0,0.85);
34
+ border-radius:12px; padding:8px;
35
+ }
36
+ #myVideo { width:100%; border-radius:8px; }
37
+ .close-btn {
38
+ position:absolute; top:12px; right:12px; color:white; font-size:24px;
39
+ background:rgba(255,60,60,0.9); width:28px; height:28px; border-radius:50%;
40
+ display:flex; align-items:center; justify-content:center; z-index:1001;
41
+ }
42
+ </style>
 
 
 
 
 
 
 
 
 
43
  </head>
44
  <body>
45
+ <a-scene background="color: #000000">
46
+ <a-sky id="sky" color="#112233"></a-sky>
47
+ </a-scene>
 
 
 
 
 
48
 
49
+ <div id="bead" onclick="togglePanel()"></div>
 
 
 
50
 
51
+ <div id="panel">
52
+ <button onclick="launchSky()">๐ŸŒŒ Sky Launcher</button>
53
+ <button onclick="pickScreenMedia()">๐Ÿ“บ Change Screen Media</button>
54
+ <button onclick="playSky()">โ–ถ๏ธ Play</button>
55
+ <button onclick="pauseSky()">โธ๏ธ Pause</button>
56
+ <button onclick="toggleMute()">๐Ÿ”‡ Mute / Unmute</button>
57
+ <button onclick="alert('AI Chat coming soon')">๐Ÿ’ฌ AI Chat</button>
58
+ <button onclick="alert('Knowledge base coming soon')">๐Ÿ“– Knowledge</button>
59
+ </div>
60
+
61
+ <div id="videoContainer">
62
+ <div class="close-btn" onclick="closeVideo()">ร—</div>
63
+ <video id="myVideo" controls loop></video>
64
+ </div>
65
+
66
+ <input type="file" id="skyInput" accept="image/*,video/*" style="display:none;">
67
+ <input type="file" id="screenInput" accept="video/*,image/*" style="display:none;">
68
+
69
+ <script>
70
+ const screenVideo = document.getElementById('myVideo');
71
+ const container = document.getElementById('videoContainer');
72
+ let skyVideo = null;
73
+
74
+ function togglePanel() {
75
+ const panel = document.getElementById('panel');
76
+ panel.style.display = (panel.style.display === 'flex') ? 'none' : 'flex';
77
+ }
78
+
79
+ function launchSky() { document.getElementById('skyInput').click(); }
80
+ function pickScreenMedia() { document.getElementById('screenInput').click(); }
81
+ function playSky() { if (skyVideo) skyVideo.play(); }
82
+ function pauseSky() { if (skyVideo) skyVideo.pause(); }
83
+
84
+ function toggleMute() {
85
+ if (skyVideo) skyVideo.muted = !skyVideo.muted;
86
+ else screenVideo.muted = !screenVideo.muted;
87
+ }
88
+
89
+ function closeVideo() {
90
+ screenVideo.pause();
91
+ container.style.display = 'none';
92
+ }
93
+
94
+ // Sky Launcher
95
+ document.getElementById('skyInput').addEventListener('change', function(e) {
96
+ const file = e.target.files[0];
97
+ if (!file) return;
98
+ const url = URL.createObjectURL(file);
99
+ const isVideo = file.type.startsWith('video/');
100
+
101
+ if (isVideo) {
102
+ if (skyVideo) skyVideo.pause();
103
+ skyVideo = document.createElement('video');
104
+ skyVideo.src = url;
105
+ skyVideo.loop = true;
106
+ skyVideo.muted = false;
107
+ skyVideo.volume = 0.6;
108
+ skyVideo.onloadeddata = () => {
109
+ const sky = document.getElementById('sky');
110
+ if (sky) {
111
+ const mesh = sky.getObject3D('mesh');
112
+ if (mesh && mesh.material) {
113
+ const texture = new THREE.VideoTexture(skyVideo);
114
+ texture.mapping = THREE.EquirectangularReflectionMapping;
115
+ mesh.material.map = texture;
116
+ mesh.material.needsUpdate = true;
117
+ skyVideo.play();
118
+ }
119
+ }
120
+ };
121
+ skyVideo.load();
122
+ } else {
123
+ const loader = new THREE.TextureLoader();
124
+ loader.load(url, function(texture) {
125
+ const sky = document.getElementById('sky');
126
+ if (sky) {
127
+ const mesh = sky.getObject3D('mesh');
128
+ if (mesh && mesh.material) {
129
+ texture.mapping = THREE.EquirectangularReflectionMapping;
130
+ mesh.material.map = texture;
131
+ mesh.material.needsUpdate = true;
132
+ }
133
+ }
134
+ });
135
+ }
136
+ });
137
+
138
+ // Screen Media
139
+ document.getElementById('screenInput').addEventListener('change', function(e) {
140
+ const file = e.target.files[0];
141
+ if (!file) return;
142
+ const url = URL.createObjectURL(file);
143
+ screenVideo.src = url;
144
+ container.style.display = 'block';
145
+ screenVideo.play();
146
+ });
147
+ </script>
148
  </body>
149
  </html>