{"id":19895331,"url":"https://github.com/razshare/svelte-animated-pixels","last_synced_at":"2025-10-26T05:06:45.999Z","repository":{"id":236846343,"uuid":"793269776","full_name":"razshare/svelte-animated-pixels","owner":"razshare","description":null,"archived":false,"fork":false,"pushed_at":"2024-06-03T11:04:03.000Z","size":100,"stargazers_count":18,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-09-26T16:46:30.102Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/razshare.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-04-28T21:56:26.000Z","updated_at":"2024-08-08T06:14:50.000Z","dependencies_parsed_at":null,"dependency_job_id":"58108782-98a8-46ae-8c8d-87ce87120142","html_url":"https://github.com/razshare/svelte-animated-pixels","commit_stats":null,"previous_names":["tncrazvan/svelte-animated-pixels","razshare/svelte-animated-pixels"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/razshare/svelte-animated-pixels","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/razshare%2Fsvelte-animated-pixels","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/razshare%2Fsvelte-animated-pixels/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/razshare%2Fsvelte-animated-pixels/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/razshare%2Fsvelte-animated-pixels/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/razshare","download_url":"https://codeload.github.com/razshare/svelte-animated-pixels/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/razshare%2Fsvelte-animated-pixels/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":281059632,"owners_count":26437061,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-26T02:00:06.575Z","response_time":61,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-12T18:36:25.778Z","updated_at":"2025-10-26T05:06:45.985Z","avatar_url":"https://github.com/razshare.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Svelte Animated Pixels\n\nThis library provides an easy way to create pixelated canvas animations by just declaring maps of pixels as strings.\n\n\nInstall with:\n\n```sh\nnpm i -D svelte-animated-pixels\n```\n\nThen start drawing, the idea is pretty simple\n\n- `x` delimits a pixel to be drawn.\n- `.` delimits the background.\n- Any other character that's not `x` or `.` is safely ignored.\n\n```svelte\n\u003cstyle\u003e\n  .wrapper {\n    position: fixed;\n    left: 0;\n    right: 0;\n    top: 0;\n    bottom: 0;\n    display: grid;\n    justify-items: center;\n    align-items: center;\n    background: black;\n  }\n\u003c/style\u003e\n\u003cscript\u003e\n  import { Animated, PixelMap } from 'svelte-animated-pixels';\n  const FRAMES = [\n    `\n    . x . . . . . x .\n    . . x . . . x . .\n    . . x x x x x . .\n    . x x x x x x x .\n    . x x x x x x x .\n    . . x x x x x . .\n    . x . . . . . x .\n    . . x . . . x . .\n    `,\n    `\n    . . . x . x . . .\n    . . x . . . x . .\n    . . x x x x x . .\n    . x x x x x x x .\n    . x x x x x x x .\n    . . x x x x x . .\n    . . x x . x x . .\n    . . . . . . . . .\n    `\n  ];\n\u003c/script\u003e\n\n\u003cdiv class=\"wrapper\"\u003e\n  \u003cAnimated frames={FRAMES} let:using={{ map }}\u003e\n    \u003cPixelMap scale={5} {map} /\u003e\n  \u003c/Animated\u003e\n\u003c/div\u003e\n```\n\n![Peek 2024-04-28 23-54](https://github.com/tncrazvan/svelte-animated-pixels/assets/6891346/6b83adba-1805-4c8f-9f1f-813707629550)\n\n\u003e [!NOTE]\n\u003e Once a frame has been drawn on a pixel map, all subsequent drawn frames MUST have the same shape, meaning both width and height MUST match.\n\n# Planned Features\n\n| Feature | Implemented | \n|---------|-------------|\n| Draw pixels using declarative maps of strings | ✅ Done - `\u003cPixelMap/\u003e` |\n| Created animations from list of maps | ✅ Done - `\u003cAnimated/\u003e` | \n| Fine tune each pixel's color | ✖ WIP |\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frazshare%2Fsvelte-animated-pixels","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frazshare%2Fsvelte-animated-pixels","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frazshare%2Fsvelte-animated-pixels/lists"}