Mercurial Hosting > dad
view src/examples/simple.html @ 5:1293cb0d30da
minor
author | Franklin Schmidt <fschmidt@gmail.com> |
---|---|
date | Sun, 23 Apr 2023 17:14:52 -0600 |
parents | 6d5e4b38b4fb |
children | 332d3e280f7e |
line wrap: on
line source
<!doctype html> <html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style> @import "/site.css"; @import "/dad.css"; span[drag] { display: inline-block; background-color: LightGreen; padding: 8px; } </style> <script src="/dad.js"></script> <script> function init() { let span = document.querySelector('span[drag]'); dad.setDraggable(span); } </script> </head> <body> <h1>Simple</h1> <p><span drag>drag me</span></p> <p>bottom</p> </body> <script> init(); </script> </html>