{"id":17161238,"url":"https://github.com/iagolast/squire-core","last_synced_at":"2025-08-31T01:33:36.160Z","repository":{"id":150828823,"uuid":"156453265","full_name":"IagoLast/squire-core","owner":"IagoLast","description":"javascript library to generate svg badges","archived":false,"fork":false,"pushed_at":"2018-11-09T18:20:31.000Z","size":48,"stargazers_count":1,"open_issues_count":1,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-24T15:47:50.004Z","etag":null,"topics":["badge","flat-design","markdown","shieldsio"],"latest_commit_sha":null,"homepage":null,"language":"HTML","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/IagoLast.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":"2018-11-06T21:55:53.000Z","updated_at":"2018-11-09T18:20:33.000Z","dependencies_parsed_at":"2023-04-07T03:32:32.221Z","dependency_job_id":null,"html_url":"https://github.com/IagoLast/squire-core","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/IagoLast/squire-core","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IagoLast%2Fsquire-core","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IagoLast%2Fsquire-core/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IagoLast%2Fsquire-core/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IagoLast%2Fsquire-core/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/IagoLast","download_url":"https://codeload.github.com/IagoLast/squire-core/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IagoLast%2Fsquire-core/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272929990,"owners_count":25017057,"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-08-30T02:00:09.474Z","response_time":77,"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":["badge","flat-design","markdown","shieldsio"],"created_at":"2024-10-14T22:27:37.189Z","updated_at":"2025-08-31T01:33:36.144Z","avatar_url":"https://github.com/IagoLast.png","language":"HTML","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Squire\n![](https://wt-4c17b3c888c61e0fdd8b150c4789e9c0-0.sandbox.auth0-extend.com/squire-server/version/v0.0.2/60A561) ![](https://wt-4c17b3c888c61e0fdd8b150c4789e9c0-0.sandbox.auth0-extend.com/squire-server/status/%20%F0%9F%8D%90%E2%9C%A8/82A0BC)\n\n## What is Squire? \nSquire is a mini javascript library to generate SVG project badges both in node and browser, see a [live demo here](https://iagolast.github.io/squire-core/).\n\n## API\n\n### **.generateBadgeSVG(opts)**\n\nThis method generates a SVG badge from the following parameters.\n\n- **borderRadius:** = The border radius of the badge, default value is 4.\n- **fontSize:** The size in px of the text in the badge, default value is 9.\n- **height:** The heigt in pixels of the badge, default value is 20.\n- **subject** The text shown in the left part of the badge, default value is ''.\n- **subjectColor:** The background color of the left part of the badge, default value is .\n- **subjectLengt:** The lenght in pixels of the left part of the badge.\n- **subjectTextColor:** The text color of the left part of the badge, defaults to white.\n- **value:** The text shown in the rectangle shown in the right part of the badge.\n- **valueColor:** The color of the text shown in the right part of the badge.\n- **valueLength:** The lenght in pixels of the rectangle shown in the right part of the badge.\n- **valueTextColor:** The color of the text shown in the right part of the badge, defaults to white.\n- **width:** Total with of badge. This will be applied to the SVG element.\n\n\n### **.generateBadge(subject, value, color)**\n\nThis method gives an easy way to generate a badge.\n\n- **subject** The text shown in the left part of the badge.\n- **value:** The text shown in the rectangle shown in the right part of the badge.\n- **color:** The color of the text shown in the right part of the badge.\n\n\n## Creating a server\n\nUse [https://webtask.io](https://webtask.io) and paste the code under the `server/webtask.js` to have your own badge server.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fiagolast%2Fsquire-core","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fiagolast%2Fsquire-core","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fiagolast%2Fsquire-core/lists"}