{"id":17676668,"url":"https://github.com/yoannchb-pro/cattract","last_synced_at":"2026-05-15T12:33:52.207Z","repository":{"id":183830422,"uuid":"667564275","full_name":"yoannchb-pro/cattract","owner":"yoannchb-pro","description":"Animate anything just like it was attracted by the cursor","archived":false,"fork":false,"pushed_at":"2025-10-06T07:57:31.000Z","size":36,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-10-06T09:42:49.357Z","etag":null,"topics":["animation","attractions","circle","javascript","round","typescript"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/yoannchb-pro.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":"2023-07-17T19:52:08.000Z","updated_at":"2025-10-06T07:57:34.000Z","dependencies_parsed_at":null,"dependency_job_id":"5ba975ea-9106-4372-b8d0-39ccd36e4cee","html_url":"https://github.com/yoannchb-pro/cattract","commit_stats":null,"previous_names":["yoannchb-pro/cattract"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/yoannchb-pro/cattract","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yoannchb-pro%2Fcattract","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yoannchb-pro%2Fcattract/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yoannchb-pro%2Fcattract/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yoannchb-pro%2Fcattract/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/yoannchb-pro","download_url":"https://codeload.github.com/yoannchb-pro/cattract/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yoannchb-pro%2Fcattract/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33067344,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-15T11:35:32.926Z","status":"ssl_error","status_checked_at":"2026-05-15T11:35:31.362Z","response_time":103,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["animation","attractions","circle","javascript","round","typescript"],"created_at":"2024-10-24T07:26:24.060Z","updated_at":"2026-05-15T12:33:52.191Z","avatar_url":"https://github.com/yoannchb-pro.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Cattract\n\nAnimate anything just like it was attracted by the cursor\n\n## Demo\n\nDemo on the [github page](https://yoannchb-pro.github.io/cattract/index.html)\n\n## Install\n\nFor nodejs\n\n```\n$ npm i @yoannchb/cattract\n```\n\nOr with the cdn\n\n```html\n\u003cscript src=\"https://unpkg.com/@yoannchb/cattract@1.0.0/dist/index.js\"\u003e\u003c/script\u003e\n```\n\n## Import\n\n```ts\nimport Cattract from \"cattract\";\n//Or\nconst Cattract = require(\"cattract\");\n```\n\n## Api\n\n```ts\nconst animation = new Cattract(document.querySelector(\"#button\"));\n```\n\nOr with specified options\n\n```ts\nconst animation = new Cattract(document.querySelector(\"#button\"), {\n  //options you need\n});\n```\n\n## Method\n\n- `animation.stop()` stop the animation\n- `animation.start()` Start the animation after a stop\n- `animation.reset()` Reset the target style\n- `animation.debug(color: string = \"#e1e1e130\")` Create two circle around the target to see the `elementRadius` and `detectionRadius`\n\n## Options\n\n```ts\ntype With3dOptions = {\n  axe?: \"x\" | \"y\";\n  inverted?: boolean | \"x\" | \"y\";\n  maxAngle?: number;\n  perspective?: number;\n};\n\ntype Options = {\n  elementRadius?: number;\n  detectionRadius?: number | \"full\";\n  animation?: {\n    ease?: string;\n    duration?: number;\n  };\n  scale?: {\n    from?: number;\n    to?: number;\n    animated?: boolean;\n  };\n  inverted?: boolean | \"x\" | \"y\";\n  axe?: \"x\" | \"y\";\n  with_3d?: boolean | With3dOptions;\n};\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyoannchb-pro%2Fcattract","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fyoannchb-pro%2Fcattract","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyoannchb-pro%2Fcattract/lists"}