Please sign in to access this page

//public:canvas

//public:canvas

16 devlogs
41h 57m
•  Ship certified

This project will result in a website that offers ppl to draw together on a public canvas (like r/place).

Tech used:
- Angular with Tailwind css
- Django
- PostgreSQL
- Redis

Disclaimer: This my first Django project. I only know Python and how an API basically works , therefore my progress may seem a bit slow, but learning all these new concepts takes time.

I have often asked the AI for how to do things. I also used the AI to fix certain things, like a backend websocket bug where the data wasnt sent to the user but updated in the db, but I didnt let the AI code ALL the things for me.

Timeline

Earned sticker

Implement pixel chunking to make website faster.

Update attachment
Earned sticker

Started to improve the canvas db (before i had a db entry for every pixel - now im putting 50x50 pixel into one tuple and saving the color data in a data column. For some reason I experience this problem currently. Still not sure how this happens.

Update attachment

Ship 1

1 payout of shell 443.0 shells

Manuel Hofmarcher

10 days ago

Manuel Hofmarcher Covers 14 devlogs and 37h 19m

The website is now hosted on my publicly available server. Took some time cause I had to change some thing in the compose files and in the db.

Update attachment

added thiccnes slider and colour picker (they dont do anything yet, but the values of those items are correctly transmitted accross components). Also changed the sizing of some components to make the site more responsive on 4k displays.

Update attachment

Created custom angular material theme but for some reason this weird glow doesnt go away.

Update attachment

Took a way easier approach by just adding an event listener to the window once is resized. The listener calls a function that calculates the right scale by checking the window height. Making the canvas tag responsive is hard because it has to has this fixed logical size of 1000x500, my current approach is set a multiplier for the curser calculation.

Update attachment

Tried some time making the canvas zoomable. Then decided to throw that idea away and go with a new approach. The canvas should have fixed breakpoints and adjusts its size using them. Firstly this approach sounds way easier. Only issue is that my canvas still has a logical size of 1000 x 500 pixel. I somehow have to figure that one still out. Idk what picture i should insert so i just show what currently happens when u zoom out.

Update attachment

Added websocket functionality. Now the frontend sends messages live to the backend, while the backend sends out updates to all users.

Update attachment

Canvas element added. API is now initially called to retrieve current Canvas state. Site also waits for API call to finish, before that a text is shown. Next step is to implement the websocket feature to also send the inputs to the db. I am also not currently able to draw lines, the drawn pixels are apart from each other.

Update attachment

worked some time on the ui

Update attachment

tinkered with the design of the site a bit. Also switched burger icon

Update attachment

looked for some fonts, icons and tried to import the downloaded font into tailwind. couldnt figure it out.

Update attachment

fucking hate browser caching. Tried solving an issue with nginx that was already fixed probably half an hour ago. switched to angular btw.

Update attachment

finished websocket support. Created svelte project and nginx config. Got it to forward me to the api trough nginx. Learned much about Svelte (first time use)

Update attachment

kind of started the websocket support. But I learned what WSGI and ASGI means. For the websocket support, I implemented a consumer on the server side and I installed the channels app for Django. I also finally found out what Redis does in this whole system and set a password for it.

Update attachment

Learned how to create Django Apps, how Models work and what they are. I also created some test apps and models, but I deleted them in the end. Then I created a model for the canvas table and the first API endpoint that returns the current canvas state.

Update attachment