kevinsousa258gmailcom commited on
Commit
d4a35c4
·
verified ·
1 Parent(s): 31c43d5

Crie um gerador de video por texto

Browse files
Files changed (2) hide show
  1. README.md +8 -5
  2. index.html +174 -18
README.md CHANGED
@@ -1,10 +1,13 @@
1
  ---
2
- title: Texttovideo Magic Maker
3
- emoji: 🏢
4
- colorFrom: indigo
5
- colorTo: blue
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: TextToVideo Magic Maker
3
+ colorFrom: yellow
4
+ colorTo: yellow
5
+ emoji: 🐳
6
  sdk: static
7
  pinned: false
8
+ tags:
9
+ - deepsite-v3
10
  ---
11
 
12
+ # Welcome to your new DeepSite project!
13
+ This project was created with [DeepSite](https://deepsite.hf.co).
index.html CHANGED
@@ -1,19 +1,175 @@
1
- <!doctype html>
2
- <html>
3
- <head>
4
- <meta charset="utf-8" />
5
- <meta name="viewport" content="width=device-width" />
6
- <title>My static Space</title>
7
- <link rel="stylesheet" href="style.css" />
8
- </head>
9
- <body>
10
- <div class="card">
11
- <h1>Welcome to your static Space!</h1>
12
- <p>You can modify this app directly by editing <i>index.html</i> in the Files and versions tab.</p>
13
- <p>
14
- Also don't forget to check the
15
- <a href="https://huggingface.co/docs/hub/spaces" target="_blank">Spaces documentation</a>.
16
- </p>
17
- </div>
18
- </body>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
19
  </html>
 
1
+ <!DOCTYPE html>
2
+ <html lang="en" class="dark">
3
+ <head>
4
+ <meta charset="UTF-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>TextToVideo Magic Maker</title>
7
+ <script src="https://cdn.tailwindcss.com"></script>
8
+ <script src="https://unpkg.com/feather-icons"></script>
9
+ <script src="https://cdn.jsdelivr.net/npm/vanta@latest/dist/vanta.globe.min.js"></script>
10
+ <style>
11
+ @import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');
12
+ body {
13
+ font-family: 'Poppins', sans-serif;
14
+ }
15
+ .gradient-text {
16
+ background-clip: text;
17
+ -webkit-background-clip: text;
18
+ color: transparent;
19
+ background-image: linear-gradient(90deg, #6366f1, #8b5cf6);
20
+ }
21
+ #vanta-bg {
22
+ position: absolute;
23
+ top: 0;
24
+ left: 0;
25
+ width: 100%;
26
+ height: 100%;
27
+ z-index: -1;
28
+ }
29
+ </style>
30
+ </head>
31
+ <body class="bg-gray-900 text-gray-100 min-h-screen flex flex-col">
32
+ <div id="vanta-bg"></div>
33
+
34
+ <header class="py-6 px-4 sm:px-6 lg:px-8">
35
+ <div class="container mx-auto flex justify-between items-center">
36
+ <h1 class="text-2xl font-bold gradient-text">TextToVideo ✨</h1>
37
+ <button id="theme-toggle" class="p-2 rounded-full bg-gray-800 hover:bg-gray-700 transition">
38
+ <i data-feather="moon"></i>
39
+ </button>
40
+ </div>
41
+ </header>
42
+
43
+ <main class="flex-grow flex items-center justify-center px-4 sm:px-6 lg:px-8">
44
+ <div class="container mx-auto max-w-4xl">
45
+ <div class="bg-gray-800 bg-opacity-80 backdrop-blur-lg rounded-xl p-6 sm:p-8 shadow-2xl">
46
+ <h2 class="text-2xl font-bold mb-6 text-center gradient-text">Create Your Video Magic</h2>
47
+
48
+ <div class="space-y-6">
49
+ <div>
50
+ <label for="text-input" class="block text-sm font-medium mb-2">Enter your text</label>
51
+ <textarea id="text-input" rows="4" class="w-full px-4 py-3 bg-gray-700 border border-gray-600 rounded-lg focus:ring-2 focus:ring-indigo-500 focus:border-indigo-500 text-white placeholder-gray-400 transition" placeholder="Type your text here to generate an amazing video..."></textarea>
52
+ </div>
53
+
54
+ <div class="grid grid-cols-1 md:grid-cols-2 gap-4">
55
+ <div>
56
+ <label class="block text-sm font-medium mb-2">Style</label>
57
+ <select class="w-full px-4 py-3 bg-gray-700 border border-gray-600 rounded-lg focus:ring-2 focus:ring-indigo-500 focus:border-indigo-500 text-white transition">
58
+ <option>Minimal</option>
59
+ <option>Modern</option>
60
+ <option>Vintage</option>
61
+ <option>Futuristic</option>
62
+ </select>
63
+ </div>
64
+ <div>
65
+ <label class="block text-sm font-medium mb-2">Duration (seconds)</label>
66
+ <input type="number" min="5" max="60" value="15" class="w-full px-4 py-3 bg-gray-700 border border-gray-600 rounded-lg focus:ring-2 focus:ring-indigo-500 focus:border-indigo-500 text-white transition">
67
+ </div>
68
+ </div>
69
+
70
+ <div class="flex justify-center">
71
+ <button id="generate-btn" class="px-8 py-3 bg-gradient-to-r from-indigo-500 to-purple-600 rounded-lg font-medium hover:from-indigo-600 hover:to-purple-700 transition-all transform hover:scale-105 shadow-lg flex items-center">
72
+ <i data-feather="play" class="mr-2"></i>
73
+ Generate Video
74
+ </button>
75
+ </div>
76
+ </div>
77
+ </div>
78
+
79
+ <div id="preview-container" class="mt-12 hidden">
80
+ <div class="bg-gray-800 bg-opacity-80 backdrop-blur-lg rounded-xl p-6 shadow-2xl">
81
+ <h3 class="text-xl font-bold mb-4 text-center">Your Video Preview</h3>
82
+ <div class="aspect-w-16 aspect-h-9 bg-gray-700 rounded-lg overflow-hidden flex items-center justify-center">
83
+ <div id="video-placeholder" class="text-center p-8">
84
+ <i data-feather="film" class="w-16 h-16 text-gray-500 mx-auto mb-4"></i>
85
+ <p class="text-gray-400">Your video will appear here</p>
86
+ </div>
87
+ <video id="video-output" class="hidden w-full" controls></video>
88
+ </div>
89
+ <div class="mt-4 flex justify-center space-x-4">
90
+ <button class="px-4 py-2 bg-indigo-600 rounded-lg hover:bg-indigo-700 transition flex items-center">
91
+ <i data-feather="download" class="mr-2"></i>
92
+ Download
93
+ </button>
94
+ <button class="px-4 py-2 bg-gray-600 rounded-lg hover:bg-gray-700 transition flex items-center">
95
+ <i data-feather="share-2" class="mr-2"></i>
96
+ Share
97
+ </button>
98
+ </div>
99
+ </div>
100
+ </div>
101
+ </div>
102
+ </main>
103
+
104
+ <footer class="py-6 px-4 sm:px-6 lg:px-8 text-center text-gray-400 text-sm">
105
+ <p>© 2023 TextToVideo Magic Maker. All rights reserved.</p>
106
+ </footer>
107
+
108
+ <script>
109
+ feather.replace();
110
+
111
+ // Initialize Vanta.js background
112
+ VANTA.GLOBE({
113
+ el: "#vanta-bg",
114
+ mouseControls: true,
115
+ touchControls: true,
116
+ gyroControls: false,
117
+ minHeight: 200.00,
118
+ minWidth: 200.00,
119
+ scale: 1.00,
120
+ scaleMobile: 1.00,
121
+ color: 0x6366f1,
122
+ backgroundColor: 0x111827,
123
+ size: 0.8
124
+ });
125
+
126
+ // Theme toggle functionality
127
+ const themeToggle = document.getElementById('theme-toggle');
128
+ themeToggle.addEventListener('click', () => {
129
+ document.documentElement.classList.toggle('dark');
130
+ const icon = themeToggle.querySelector('i');
131
+ if (document.documentElement.classList.contains('dark')) {
132
+ feather.icons['moon'].replace(icon);
133
+ } else {
134
+ feather.icons['sun'].replace(icon);
135
+ }
136
+ });
137
+
138
+ // Generate button functionality
139
+ const generateBtn = document.getElementById('generate-btn');
140
+ const previewContainer = document.getElementById('preview-container');
141
+ const videoPlaceholder = document.getElementById('video-placeholder');
142
+ const videoOutput = document.getElementById('video-output');
143
+
144
+ generateBtn.addEventListener('click', () => {
145
+ const textInput = document.getElementById('text-input').value;
146
+ if (!textInput.trim()) {
147
+ alert('Please enter some text to generate a video');
148
+ return;
149
+ }
150
+
151
+ // Show loading state
152
+ generateBtn.disabled = true;
153
+ generateBtn.innerHTML = '<i data-feather="loader" class="animate-spin mr-2"></i> Generating...';
154
+ feather.replace();
155
+
156
+ // Simulate video generation (in a real app, this would call an API)
157
+ setTimeout(() => {
158
+ previewContainer.classList.remove('hidden');
159
+ videoPlaceholder.classList.add('hidden');
160
+ videoOutput.classList.remove('hidden');
161
+
162
+ // In a real app, you would set the video source here
163
+ // videoOutput.src = generatedVideoUrl;
164
+
165
+ generateBtn.disabled = false;
166
+ generateBtn.innerHTML = '<i data-feather="play" class="mr-2"></i> Generate Video';
167
+ feather.replace();
168
+
169
+ // Scroll to preview
170
+ previewContainer.scrollIntoView({ behavior: 'smooth' });
171
+ }, 3000);
172
+ });
173
+ </script>
174
+ </body>
175
  </html>