Spaces:
Running
Running
Add 3 files
Browse files- README.md +7 -5
- index.html +211 -19
- prompts.txt +0 -0
README.md
CHANGED
|
@@ -1,10 +1,12 @@
|
|
| 1 |
---
|
| 2 |
-
title:
|
| 3 |
-
emoji:
|
| 4 |
-
colorFrom:
|
| 5 |
-
colorTo:
|
| 6 |
sdk: static
|
| 7 |
pinned: false
|
|
|
|
|
|
|
| 8 |
---
|
| 9 |
|
| 10 |
-
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
|
|
|
| 1 |
---
|
| 2 |
+
title: sovitich-projects
|
| 3 |
+
emoji: 🐳
|
| 4 |
+
colorFrom: gray
|
| 5 |
+
colorTo: green
|
| 6 |
sdk: static
|
| 7 |
pinned: false
|
| 8 |
+
tags:
|
| 9 |
+
- deepsite
|
| 10 |
---
|
| 11 |
|
| 12 |
+
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
index.html
CHANGED
|
@@ -1,19 +1,211 @@
|
|
| 1 |
-
<!
|
| 2 |
-
<html>
|
| 3 |
-
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
|
| 17 |
-
|
| 18 |
-
|
| 19 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<!DOCTYPE html>
|
| 2 |
+
<html lang="en">
|
| 3 |
+
<head>
|
| 4 |
+
<meta charset="UTF-8">
|
| 5 |
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
| 6 |
+
<title>News Teleprompter</title>
|
| 7 |
+
<script src="https://cdn.tailwindcss.com"></script>
|
| 8 |
+
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
|
| 9 |
+
<style>
|
| 10 |
+
.teleprompter-container {
|
| 11 |
+
perspective: 1000px;
|
| 12 |
+
transform-style: preserve-3d;
|
| 13 |
+
}
|
| 14 |
+
.teleprompter-text {
|
| 15 |
+
transform: rotateX(20deg);
|
| 16 |
+
transform-origin: top center;
|
| 17 |
+
}
|
| 18 |
+
.gradient-mask {
|
| 19 |
+
mask-image: linear-gradient(to bottom,
|
| 20 |
+
rgba(0,0,0,0) 0%,
|
| 21 |
+
rgba(0,0,0,1) 10%,
|
| 22 |
+
rgba(0,0,0,1) 90%,
|
| 23 |
+
rgba(0,0,0,0) 100%);
|
| 24 |
+
-webkit-mask-image: linear-gradient(to bottom,
|
| 25 |
+
rgba(0,0,0,0) 0%,
|
| 26 |
+
rgba(0,0,0,1) 10%,
|
| 27 |
+
rgba(0,0,0,1) 90%,
|
| 28 |
+
rgba(0,0,0,0) 100%);
|
| 29 |
+
}
|
| 30 |
+
.speed-control::-webkit-slider-thumb {
|
| 31 |
+
-webkit-appearance: none;
|
| 32 |
+
width: 20px;
|
| 33 |
+
height: 20px;
|
| 34 |
+
border-radius: 50%;
|
| 35 |
+
background: #3b82f6;
|
| 36 |
+
cursor: pointer;
|
| 37 |
+
}
|
| 38 |
+
.word-line {
|
| 39 |
+
display: flex;
|
| 40 |
+
justify-content: center;
|
| 41 |
+
margin-bottom: 1.5rem;
|
| 42 |
+
}
|
| 43 |
+
.word {
|
| 44 |
+
margin: 0 0.5rem;
|
| 45 |
+
}
|
| 46 |
+
</style>
|
| 47 |
+
</head>
|
| 48 |
+
<body class="bg-gray-900 text-white min-h-screen flex flex-col">
|
| 49 |
+
<header class="bg-black py-4 px-6 shadow-lg">
|
| 50 |
+
<div class="container mx-auto flex justify-between items-center">
|
| 51 |
+
<h1 class="text-2xl font-bold text-blue-400">
|
| 52 |
+
<i class="fas fa-newspaper mr-2"></i> News Teleprompter
|
| 53 |
+
</h1>
|
| 54 |
+
<div class="flex items-center space-x-4">
|
| 55 |
+
<button id="playPauseBtn" class="bg-blue-600 hover:bg-blue-700 text-white px-4 py-2 rounded-lg flex items-center">
|
| 56 |
+
<i class="fas fa-play mr-2"></i> Play
|
| 57 |
+
</button>
|
| 58 |
+
<div class="flex items-center">
|
| 59 |
+
<i class="fas fa-tachometer-alt mr-2 text-blue-400"></i>
|
| 60 |
+
<input type="range" id="speedControl" min="1" max="20" value="5" class="speed-control w-32">
|
| 61 |
+
<span id="speedValue" class="ml-2 text-blue-400">5x</span>
|
| 62 |
+
</div>
|
| 63 |
+
</div>
|
| 64 |
+
</div>
|
| 65 |
+
</header>
|
| 66 |
+
|
| 67 |
+
<main class="flex-grow flex items-center justify-center p-6">
|
| 68 |
+
<div class="teleprompter-container w-full max-w-4xl h-96 bg-black border-2 border-blue-800 rounded-lg overflow-hidden shadow-xl">
|
| 69 |
+
<div id="teleprompterText" class="teleprompter-text h-full overflow-y-hidden text-3xl leading-relaxed p-8 gradient-mask">
|
| 70 |
+
<!-- News content will be inserted here by JavaScript -->
|
| 71 |
+
</div>
|
| 72 |
+
</div>
|
| 73 |
+
</main>
|
| 74 |
+
|
| 75 |
+
<footer class="bg-black py-4 px-6">
|
| 76 |
+
<div class="container mx-auto text-center text-gray-400">
|
| 77 |
+
<p>Use the controls to adjust the scrolling speed. Click play/pause to start or stop the teleprompter.</p>
|
| 78 |
+
</div>
|
| 79 |
+
</footer>
|
| 80 |
+
|
| 81 |
+
<script>
|
| 82 |
+
document.addEventListener('DOMContentLoaded', function() {
|
| 83 |
+
// Sample news content
|
| 84 |
+
const newsParagraphs = [
|
| 85 |
+
"BREAKING NEWS: The city council has approved the new infrastructure plan that will modernize public transportation across the metropolitan area. The $2.3 billion project is expected to create thousands of jobs and reduce commute times by an average of 25%.",
|
| 86 |
+
"INTERNATIONAL: Diplomatic tensions rise as trade negotiations between major economic powers reach a stalemate. Analysts warn that prolonged disputes could impact global markets and supply chains. Representatives from both sides are scheduled to meet again next week.",
|
| 87 |
+
"TECHNOLOGY: A breakthrough in quantum computing has been announced by researchers at the National Laboratory. The new processor demonstrates error correction capabilities that could make practical quantum computers a reality within the decade.",
|
| 88 |
+
"WEATHER: A severe weather system is moving across the region, bringing heavy rains and potential flooding to low-lying areas. Residents are advised to prepare emergency kits and monitor local alerts. The storm is expected to pass by Thursday evening.",
|
| 89 |
+
"SPORTS: In a stunning upset, the underdog team defeated the defending champions in overtime last night. The victory marks their first championship in franchise history. Fans celebrated throughout the city as the team returned home this morning.",
|
| 90 |
+
"HEALTH: New guidelines from the World Health Organization recommend updated vaccination schedules for children and adults. The changes reflect recent research on immunity duration and emerging disease patterns.",
|
| 91 |
+
"ENTERTAINMENT: The highly anticipated film adaptation of the bestselling novel series premieres this weekend. Early reviews praise the director's vision and the lead actor's performance, predicting strong box office numbers.",
|
| 92 |
+
"BUSINESS: Major retailers report stronger than expected holiday sales despite economic concerns. Analysts attribute the growth to strategic discounts and consumers prioritizing essential purchases.",
|
| 93 |
+
"SCIENCE: Astronomers have discovered a potentially habitable exoplanet orbiting a nearby star. The Earth-sized planet lies within the habitable zone where liquid water could exist on its surface.",
|
| 94 |
+
"POLITICS: The legislature is debating comprehensive education reform that would increase funding for public schools and revise curriculum standards. The bill has bipartisan support but faces opposition from some advocacy groups."
|
| 95 |
+
];
|
| 96 |
+
|
| 97 |
+
// Format text into 5-word lines
|
| 98 |
+
function formatTextToLines(text) {
|
| 99 |
+
const words = text.split(/\s+/);
|
| 100 |
+
const lines = [];
|
| 101 |
+
|
| 102 |
+
for (let i = 0; i < words.length; i += 5) {
|
| 103 |
+
const lineWords = words.slice(i, i + 5);
|
| 104 |
+
lines.push(lineWords);
|
| 105 |
+
}
|
| 106 |
+
|
| 107 |
+
return lines;
|
| 108 |
+
}
|
| 109 |
+
|
| 110 |
+
// Get DOM elements
|
| 111 |
+
const teleprompterText = document.getElementById('teleprompterText');
|
| 112 |
+
const playPauseBtn = document.getElementById('playPauseBtn');
|
| 113 |
+
const speedControl = document.getElementById('speedControl');
|
| 114 |
+
const speedValue = document.getElementById('speedValue');
|
| 115 |
+
|
| 116 |
+
// Insert formatted news content
|
| 117 |
+
let formattedContent = '';
|
| 118 |
+
newsParagraphs.forEach(paragraph => {
|
| 119 |
+
const lines = formatTextToLines(paragraph);
|
| 120 |
+
lines.forEach(lineWords => {
|
| 121 |
+
formattedContent += '<div class="word-line">';
|
| 122 |
+
lineWords.forEach(word => {
|
| 123 |
+
// Highlight category words in blue
|
| 124 |
+
if (word.endsWith(':') && word === lineWords[0]) {
|
| 125 |
+
formattedContent += `<span class="word text-blue-400 font-bold">${word}</span>`;
|
| 126 |
+
} else {
|
| 127 |
+
formattedContent += `<span class="word">${word}</span>`;
|
| 128 |
+
}
|
| 129 |
+
});
|
| 130 |
+
formattedContent += '</div>';
|
| 131 |
+
});
|
| 132 |
+
// Add extra space between paragraphs
|
| 133 |
+
formattedContent += '<div class="h-12"></div>';
|
| 134 |
+
});
|
| 135 |
+
|
| 136 |
+
teleprompterText.innerHTML = formattedContent;
|
| 137 |
+
|
| 138 |
+
// Teleprompter state
|
| 139 |
+
let isPlaying = false;
|
| 140 |
+
let scrollInterval;
|
| 141 |
+
let scrollPosition = 0;
|
| 142 |
+
let scrollSpeed = 5; // Default speed
|
| 143 |
+
|
| 144 |
+
// Update speed display
|
| 145 |
+
speedControl.addEventListener('input', function() {
|
| 146 |
+
scrollSpeed = parseInt(this.value);
|
| 147 |
+
speedValue.textContent = `${scrollSpeed}x`;
|
| 148 |
+
|
| 149 |
+
if (isPlaying) {
|
| 150 |
+
clearInterval(scrollInterval);
|
| 151 |
+
startScrolling();
|
| 152 |
+
}
|
| 153 |
+
});
|
| 154 |
+
|
| 155 |
+
// Play/Pause functionality
|
| 156 |
+
playPauseBtn.addEventListener('click', function() {
|
| 157 |
+
isPlaying = !isPlaying;
|
| 158 |
+
|
| 159 |
+
if (isPlaying) {
|
| 160 |
+
playPauseBtn.innerHTML = '<i class="fas fa-pause mr-2"></i> Pause';
|
| 161 |
+
startScrolling();
|
| 162 |
+
} else {
|
| 163 |
+
playPauseBtn.innerHTML = '<i class="fas fa-play mr-2"></i> Play';
|
| 164 |
+
clearInterval(scrollInterval);
|
| 165 |
+
}
|
| 166 |
+
});
|
| 167 |
+
|
| 168 |
+
// Start scrolling function
|
| 169 |
+
function startScrolling() {
|
| 170 |
+
scrollInterval = setInterval(function() {
|
| 171 |
+
scrollPosition += 0.5 * (scrollSpeed / 5);
|
| 172 |
+
teleprompterText.scrollTop = scrollPosition;
|
| 173 |
+
|
| 174 |
+
// Reset to top when reaching bottom
|
| 175 |
+
if (scrollPosition >= teleprompterText.scrollHeight - teleprompterText.clientHeight) {
|
| 176 |
+
scrollPosition = 0;
|
| 177 |
+
teleprompterText.scrollTop = 0;
|
| 178 |
+
}
|
| 179 |
+
}, 16); // ~60fps
|
| 180 |
+
}
|
| 181 |
+
|
| 182 |
+
// Keyboard controls
|
| 183 |
+
document.addEventListener('keydown', function(e) {
|
| 184 |
+
// Spacebar to play/pause
|
| 185 |
+
if (e.code === 'Space') {
|
| 186 |
+
e.preventDefault();
|
| 187 |
+
playPauseBtn.click();
|
| 188 |
+
}
|
| 189 |
+
|
| 190 |
+
// Arrow up to increase speed
|
| 191 |
+
if (e.code === 'ArrowUp') {
|
| 192 |
+
e.preventDefault();
|
| 193 |
+
if (scrollSpeed < 20) {
|
| 194 |
+
speedControl.value = scrollSpeed + 1;
|
| 195 |
+
speedControl.dispatchEvent(new Event('input'));
|
| 196 |
+
}
|
| 197 |
+
}
|
| 198 |
+
|
| 199 |
+
// Arrow down to decrease speed
|
| 200 |
+
if (e.code === 'ArrowDown') {
|
| 201 |
+
e.preventDefault();
|
| 202 |
+
if (scrollSpeed > 1) {
|
| 203 |
+
speedControl.value = scrollSpeed - 1;
|
| 204 |
+
speedControl.dispatchEvent(new Event('input'));
|
| 205 |
+
}
|
| 206 |
+
}
|
| 207 |
+
});
|
| 208 |
+
});
|
| 209 |
+
</script>
|
| 210 |
+
<p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - 🧬 <a href="https://enzostvs-deepsite.hf.space?remix=sovitich28/sovitich-projects" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
|
| 211 |
+
</html>
|
prompts.txt
ADDED
|
File without changes
|