Spaces:
Running
Running
Update index.html
Browse files- index.html +43 -1
index.html
CHANGED
@@ -61,7 +61,6 @@
|
|
61 |
}
|
62 |
|
63 |
.btn {
|
64 |
-
background-color: #4CAF50;
|
65 |
border: none;
|
66 |
color: white;
|
67 |
padding: 10px 20px;
|
@@ -72,6 +71,39 @@
|
|
72 |
margin: 4px 2px;
|
73 |
cursor: pointer;
|
74 |
border-radius: 5px;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
75 |
}
|
76 |
|
77 |
#background-image {
|
@@ -131,6 +163,7 @@
|
|
131 |
<button id="fullscreen-btn" class="btn">Toggle Fullscreen</button>
|
132 |
<button id="save-settings" class="btn">Save</button>
|
133 |
<button id="test-image" class="btn">Test Image Generation</button>
|
|
|
134 |
</div>
|
135 |
|
136 |
<script>
|
@@ -143,6 +176,8 @@
|
|
143 |
let imageGenerationInterval;
|
144 |
let wakeLock = null;
|
145 |
|
|
|
|
|
146 |
function updateClock() {
|
147 |
const now = new Date();
|
148 |
let hours = now.getHours();
|
@@ -320,6 +355,13 @@
|
|
320 |
updateBackgroundImage();
|
321 |
});
|
322 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
323 |
document.getElementById('clock-size-input')
|
324 |
.addEventListener('input', (e) => {
|
325 |
const value = e.target.value;
|
|
|
61 |
}
|
62 |
|
63 |
.btn {
|
|
|
64 |
border: none;
|
65 |
color: white;
|
66 |
padding: 10px 20px;
|
|
|
71 |
margin: 4px 2px;
|
72 |
cursor: pointer;
|
73 |
border-radius: 5px;
|
74 |
+
transition: background-color 0.3s;
|
75 |
+
}
|
76 |
+
|
77 |
+
#fullscreen-btn {
|
78 |
+
background-color: #4CAF50;
|
79 |
+
}
|
80 |
+
|
81 |
+
#fullscreen-btn:hover {
|
82 |
+
background-color: #45a049;
|
83 |
+
}
|
84 |
+
|
85 |
+
#save-settings {
|
86 |
+
background-color: #008CBA;
|
87 |
+
}
|
88 |
+
|
89 |
+
#save-settings:hover {
|
90 |
+
background-color: #007B9A;
|
91 |
+
}
|
92 |
+
|
93 |
+
#test-image {
|
94 |
+
background-color: #f44336;
|
95 |
+
}
|
96 |
+
|
97 |
+
#test-image:hover {
|
98 |
+
background-color: #da190b;
|
99 |
+
}
|
100 |
+
|
101 |
+
#reset-prompt {
|
102 |
+
background-color: #ff9800;
|
103 |
+
}
|
104 |
+
|
105 |
+
#reset-prompt:hover {
|
106 |
+
background-color: #e68a00;
|
107 |
}
|
108 |
|
109 |
#background-image {
|
|
|
163 |
<button id="fullscreen-btn" class="btn">Toggle Fullscreen</button>
|
164 |
<button id="save-settings" class="btn">Save</button>
|
165 |
<button id="test-image" class="btn">Test Image Generation</button>
|
166 |
+
<button id="reset-prompt" class="btn">Reset Prompt</button>
|
167 |
</div>
|
168 |
|
169 |
<script>
|
|
|
176 |
let imageGenerationInterval;
|
177 |
let wakeLock = null;
|
178 |
|
179 |
+
const DEFAULT_PROMPT = 'beautiful abstract landscape that suits the time {time}';
|
180 |
+
|
181 |
function updateClock() {
|
182 |
const now = new Date();
|
183 |
let hours = now.getHours();
|
|
|
355 |
updateBackgroundImage();
|
356 |
});
|
357 |
|
358 |
+
document.getElementById('reset-prompt')
|
359 |
+
.addEventListener('click', () => {
|
360 |
+
customPrompt = DEFAULT_PROMPT;
|
361 |
+
document.getElementById('prompt-input')
|
362 |
+
.value = customPrompt;
|
363 |
+
});
|
364 |
+
|
365 |
document.getElementById('clock-size-input')
|
366 |
.addEventListener('input', (e) => {
|
367 |
const value = e.target.value;
|