{"id":15760520,"url":"https://github.com/lucasnbsb/ngx-shot-chart","last_synced_at":"2026-01-11T01:58:47.349Z","repository":{"id":242617768,"uuid":"810064873","full_name":"lucasnbsb/ngx-shot-chart","owner":"lucasnbsb","description":"An Angular component to create basketball shot charts in real time","archived":false,"fork":false,"pushed_at":"2024-06-09T19:40:39.000Z","size":929,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-10T15:55:10.078Z","etag":null,"topics":["angular","basketball","d3"],"latest_commit_sha":null,"homepage":"https://lucasnbsb.github.io/ngx-shot-chart/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lucasnbsb.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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-06-04T01:29:00.000Z","updated_at":"2024-09-09T02:47:43.000Z","dependencies_parsed_at":"2024-06-04T03:06:49.689Z","dependency_job_id":"2a5674af-7b14-44e8-bd30-30162fefcc10","html_url":"https://github.com/lucasnbsb/ngx-shot-chart","commit_stats":null,"previous_names":["lucasnbsb/ngx-shot-chart"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lucasnbsb%2Fngx-shot-chart","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lucasnbsb%2Fngx-shot-chart/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lucasnbsb%2Fngx-shot-chart/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lucasnbsb%2Fngx-shot-chart/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lucasnbsb","download_url":"https://codeload.github.com/lucasnbsb/ngx-shot-chart/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246695061,"owners_count":20819205,"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":["angular","basketball","d3"],"created_at":"2024-10-04T10:58:32.405Z","updated_at":"2026-01-11T01:58:47.324Z","avatar_url":"https://github.com/lucasnbsb.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# NgxShotChart 🏀\n\nA simple way to create shotcharts in real time with Angular and d3.js.\n\n[Try it out in the demo app!](https://lucasnbsb.github.io/ngx-shot-chart/)\n\n## Installation\n```\nnpm install ngx-shot-chart d3 @types/d3\n```\n\n## Basic functionality\nThis lib exposes a `NgxShotChartComponent` that renders a shot chart and a `NgxShotChartService` with primitives to manipulate symbols in the chart.\n\n\n## The component\n- Only emmits the mutually esclusive  `ChartClicked` and `SymbolClicked` events \n- Symbols can be any [d3.symbolType](https://d3js.org/d3-shape/symbol#symbolsFill)\n- Court and symbols default fill collor is the current text color\n- ⛹️ Pre-configured with NBA, FIBA and NCAA court sizes\n\n### Usage: \n```typescript\n\u003cngx-shot-chart league='nba' (ChartClicked)=\"handleChartClicked($event)\" (SymbolClicked)=\"handleSymbolClicked($event)\"\u003e\u003c/ngx-shot-chart\u003e\n```\n\n## The service\n\nExposes a crud interface for shots, methods to draw and clear the court and symbols, and utilities.\n\n### Usage:\n\n```typescript\nimport { ShotChartService } from 'ngx-shot-chart';\n\nconstructor(private shotChartService: ShotChartService) {}\n\n// Add a shot to the chart whenever it is clicked 🪣\nhandleChartClick(event: ChartClickedEvent) {\n  this.chart.AddShot(event, d3.symbolCircle);\n}\n\n// Remove a shot from the chart whenever the symbol is clicked 🗑️\nhandleSymbolClick(event: SymbolClickEvent) {\n  this.chart.RemoveShot(event.id);\n}\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flucasnbsb%2Fngx-shot-chart","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flucasnbsb%2Fngx-shot-chart","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flucasnbsb%2Fngx-shot-chart/lists"}