{"id":13659008,"url":"https://github.com/uxebu/bonsai","last_synced_at":"2025-05-15T12:06:29.870Z","repository":{"id":3734861,"uuid":"4808664","full_name":"uxebu/bonsai","owner":"uxebu","description":"BonsaiJS is a graphics library and renderer","archived":false,"fork":false,"pushed_at":"2017-12-18T22:54:13.000Z","size":11635,"stargazers_count":1961,"open_issues_count":93,"forks_count":188,"subscribers_count":96,"default_branch":"master","last_synced_at":"2025-05-07T15:47:52.282Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://bonsaijs.org","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/uxebu.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2012-06-27T13:35:13.000Z","updated_at":"2025-04-24T08:08:12.000Z","dependencies_parsed_at":"2022-08-17T23:00:15.645Z","dependency_job_id":null,"html_url":"https://github.com/uxebu/bonsai","commit_stats":null,"previous_names":[],"tags_count":17,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/uxebu%2Fbonsai","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/uxebu%2Fbonsai/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/uxebu%2Fbonsai/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/uxebu%2Fbonsai/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/uxebu","download_url":"https://codeload.github.com/uxebu/bonsai/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254337613,"owners_count":22054253,"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","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-08-02T05:01:04.512Z","updated_at":"2025-05-15T12:06:24.856Z","avatar_url":"https://github.com/uxebu.png","language":"JavaScript","funding_links":[],"categories":["JavaScript","11. 图表绘制/图形库(Graphics) ##","11. 图表绘制/图形库(Graphics)","SVG","📦 Legacy \u0026 Inactive Projects"],"sub_categories":["10.9 样式修正 ###","10.10 样式修正"],"readme":"# Bonsai\n\n(previously known as *bikeshedjs*)\n\n \u003e *The art of bonsai tells a story through living illusion. A bonsai artist searches for ways to express his personal creativity by mixing form and thought in a miniature world.* [*[source]*](http://whatijustlearned.wordpress.com/2011/04/22/bonsai-heaven-and-earth-in-one-container/)\n\n### Introduction\n\nBonsai is a JavaScript graphics library. For the finer details, see the [documentation](http://docs.bonsaijs.org) (currently in construction).\n\nBonsai's main features include:\n\n * Architecturally separated runner and renderer\n * iFrame, Worker and Node running contexts\n * Shapes\n * Paths\n * Assets (Videos, Images, Fonts, SubMovies)\n * Keyframe and regular animation (easing functions too)\n * Shape/path morphing\n * *and much more*...\n\n### An example\n\nDraw a `100x200` rectangle to the stage at `{0,0}`:\n\n```js\nvar r = new Rect(0, 0, 100, 200).addTo(stage);\n```\n\nFill it:\n\n```js\nr.fill('red');\n```\n\nChange your mind... make it darker:\n\n```js\nr.fill( color('red').darker() );\n```\n\nAnimate it:\n\n```js\nr.animate('400ms', {\n  x: 50,\n  y: 50,\n  width: 200\n});\n```\n\nSee more here: [Bonsai Documentation/Overviews](http://docs.bonsaijs.org) or\njoin the IRC channel [#bonsaijs on freenode](http://webchat.freenode.net/?channels=bonsaijs) and ask for help.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fuxebu%2Fbonsai","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fuxebu%2Fbonsai","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fuxebu%2Fbonsai/lists"}