ilhamdev commited on
Commit
e6366a7
1 Parent(s): 39318c4

Update index.html

Browse files
Files changed (1) hide show
  1. index.html +31 -17
index.html CHANGED
@@ -215,13 +215,13 @@
215
 
216
  .toggle-switch .sun {
217
  left: 2px;
218
- background: url('https://i.ibb.co.com/Pz8FxxY/image.png') no-repeat center;
219
  background-size: cover;
220
  }
221
 
222
  .toggle-switch .moon {
223
  right: 2px;
224
- background: url('https://i.ibb.co.com/k0b21wZ/image.png') no-repeat center;
225
  background-size: cover;
226
  }
227
 
@@ -248,6 +248,22 @@
248
  .button:active {
249
  background-color: #004080;
250
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
251
  </style>
252
  </head>
253
  <body>
@@ -384,21 +400,19 @@ lumin("query", "username", "logic", true)
384
  fetchStats();
385
 
386
  function copyToClipboard(button) {
387
- const codeBlock = button.nextElementSibling.innerText;
388
- navigator.clipboard.writeText(codeBlock).then(() => {
389
- button.querySelector('img').src = 'https://cdn.iconscout.com/icon/free/png-256/check-1781599-1518574.png';
390
- button.style.transform = 'scale(1.2)'; // Add a scale transform
391
- button.style.transition = 'transform 0.3s ease'; // Add a smooth transition
392
- alert('Kode berhasil disalin!'); // Add an alert
393
- setTimeout(() => {
394
- button.querySelector('img').src = 'https://cdn.iconscout.com/icon/free/png-256/copy-1781607-1518582.png';
395
- button.style.transform = 'scale(1)'; // Reset the transform
396
- }, 2000);
397
- }).catch(err => {
398
- console.error('Failed to copy: ', err);
399
- });
400
- }
401
-
402
 
403
  </script>
404
  </body>
 
215
 
216
  .toggle-switch .sun {
217
  left: 2px;
218
+ background: url('https://upload.wikimedia.org/wikipedia/commons/e/e1/Full_Sun_Clipart.svg') no-repeat center;
219
  background-size: cover;
220
  }
221
 
222
  .toggle-switch .moon {
223
  right: 2px;
224
+ background: url('https://upload.wikimedia.org/wikipedia/commons/3/3a/Moon_clipart.svg') no-repeat center;
225
  background-size: cover;
226
  }
227
 
 
248
  .button:active {
249
  background-color: #004080;
250
  }
251
+
252
+ /* Added styles for copy button animation */
253
+ .copy-btn img {
254
+ width: 24px;
255
+ height: 24px;
256
+ transition: transform 0.3s ease-in-out;
257
+ }
258
+
259
+ .copy-btn:hover img {
260
+ transform: rotate(360deg);
261
+ }
262
+
263
+ /* Added styles for code block copy button hover effect */
264
+ .copy-btn:hover {
265
+ background-color: #4a90e2;
266
+ }
267
  </style>
268
  </head>
269
  <body>
 
400
  fetchStats();
401
 
402
  function copyToClipboard(button) {
403
+ const codeBlock = button.nextElementSibling.innerText;
404
+ navigator.clipboard.writeText(codeBlock).then(() => {
405
+ button.querySelector('img').src = 'https://cdn.iconscout.com/icon/free/png-256/check-1781599-1518574.png';
406
+ button.style.transform = 'scale(1.2)'; // Add a scale transform
407
+ button.style.transition = 'transform 0.3s ease'; // Add a smooth transition
408
+ setTimeout(() => {
409
+ button.querySelector('img').src = 'https://cdn.iconscout.com/icon/free/png-256/copy-1781607-1518582.png';
410
+ button.style.transform = 'scale(1)'; // Reset the transform
411
+ }, 2000);
412
+ }).catch(err => {
413
+ console.error('Failed to copy: ', err);
414
+ });
415
+ }
 
 
416
 
417
  </script>
418
  </body>