16 |
17 |
49 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # svelte-GridTiles
2 | Drag and drop resizable tiles on a responsive grid
3 |
4 | -------------------
5 |
6 | - add a GridTiles component to your page
7 | - import your components in the layout.js file
8 | - hard code a startup layout or build one from an optional toolbar once the page loads
9 | - allow users to add particular components from the drop down, if you want
10 | - your components appear inside the Tiles!
11 | - svelte is awesome!
12 |
13 | - works in Firefox, Chrome, and Epiphany, so should work in Safari too
14 | - TODO: allow saving of custom layouts
15 | - TODO: enable touch interaction, currently mouse only
16 |
17 | check it out:
18 | at the REPL:
19 | https://svelte.dev/repl/b993c8f5fa9f4105aa9a246321025166?version=3.46.4
20 |
21 | or by getting yourself a svelte template:
22 |
23 | ```bash
24 | npx degit sveltejs/template my-svelte-project
25 | cd my-svelte-project
26 | npm install
27 | ```
28 | then plop the files from this GridTiles repo into your new /src folder and run:
29 | ```bash
30 | npm run dev
31 | ```
32 |
33 | [](https://user-images.githubusercontent.com/98979350/152649391-5fcce1cf-8976-4eba-9f16-47e5347ad29f.png "screenshot_GridTiles")
34 |
--------------------------------------------------------------------------------
/src/GridControl.svelte:
--------------------------------------------------------------------------------
1 |
35 |
36 |