Ayyye, nice to see another svelter around :) I ended up doing this challenge in svelte too
some real nice stuff here, for example loved the spin transition you did on the theme switcher. design looks pretty close, being nip picky on the desktop design the remove todo button should only appears on hover
somethings you could of done better is the dragging, I used SortableJS in my project but you could also use DraggableJS this would of saved you some time however in the sport of doing stuff yourself for the fun of it, your implementation is slighlty off putting for one you're blocking interactivity with the done switch and the remove button by making the whole div a draggable component, I would suggest making only the middle part the drag handle as that allows users to still easily move the todo-item but still let them easily click the remove and done switch. another reason why your own dragging logic feels wrong is because once you put your cursor off the todo-container it stops the drag, if you're going to do that I would suggest anchoring the drag-item on the x-axis (so only move the item up and down).
apart from the dragging logic being little wacky, I would also make sure you can't submit an empty todo (although this might be preference) also would make sure you set border: none;
on the input:focus, so you don't get that out of place dotted line.
apart from all that, you did an awesome job! good stuff looking foward to maybe seeing you doing more challenges around here in svelte :)
@MasterKrab
Posted
@Yofou
I hadn't realized that the delete button should only appear on hover.
The outline in the input:focus
is for accessibility, in the checkboxes and buttons I use focus-visible
but in the input text
that doesn't work.
I want to do the drag and drop on my own, I will try to improve it, I will consider your advice.
It's my first project with svelte, I like it very much.
Thank you very much!