{"id":15674821,"url":"https://github.com/zachleat/throbber","last_synced_at":"2025-05-06T22:22:07.883Z","repository":{"id":222702203,"uuid":"758160362","full_name":"zachleat/throbber","owner":"zachleat","description":"A loading indicator overlay for images (and maybe other things later).","archived":false,"fork":false,"pushed_at":"2024-02-19T23:40:57.000Z","size":15,"stargazers_count":16,"open_issues_count":1,"forks_count":2,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-04-19T15:35:37.904Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://zachleat.github.io/throbber/demo.html","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/zachleat.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-02-15T18:35:24.000Z","updated_at":"2025-02-06T02:49:26.000Z","dependencies_parsed_at":null,"dependency_job_id":"24c6757b-7fcf-46de-8aa4-2cc116c94ce1","html_url":"https://github.com/zachleat/throbber","commit_stats":null,"previous_names":["zachleat/throbber"],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zachleat%2Fthrobber","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zachleat%2Fthrobber/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zachleat%2Fthrobber/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zachleat%2Fthrobber/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zachleat","download_url":"https://codeload.github.com/zachleat/throbber/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252777364,"owners_count":21802590,"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-10-03T15:51:18.304Z","updated_at":"2025-05-06T22:22:07.846Z","avatar_url":"https://github.com/zachleat.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# `\u003cthrob-ber\u003e` Web Component\n\nA web component to add a little baby rainbow gradient overlay until all of the images nested inside have finished loading. Works best with expensive dynamically generated images (like screenshots).\n\n* [Demos](https://zachleat.github.io/throbber/demo.html)\n* Used on the registration flow for [`conf.11ty.dev`](https://conf.11ty.dev/)\n\n## Features\n\n* Customize minimum `delay` before the loading indicator is shown.\n* Customize loading indicator bar height.\n\n## Installation\n\nYou can install via `npm` ([`@zachleat/throbber`](https://www.npmjs.com/package/@zachleat/throbber)) or download the `throbber.js` JavaScript file manually.\n\n```shell\nnpm install @zachleat/throbber --save\n```\n\nAdd `throbber.js` to your site’s JavaScript assets.\n\n## Usage\n\n```html\n\u003cthrob-ber\u003e\n\t\u003cimg src=\"myimage.png\" alt=\"\" width=\"600\" height=\"400\"\u003e\n\u003c/throb-ber\u003e\n```\n\n### Change minimum delay\n\nThe minimum time before the loading indicator is shown. `delay` is in milliseconds (0.5 seconds shown).\n\n```html\n\u003cthrob-ber delay=\"500\"\u003e\n\t\u003cimg src=\"myimage.png\" alt=\"\" width=\"600\" height=\"400\"\u003e\n\u003c/throb-ber\u003e\n```\n\n### Customize appearance\n\nDark background while the image is loading, loading indicator fills up the component:\n\n```html\n\u003cthrob-ber style=\"background-color: #666; --throbber-height: 100%;\"\u003e\n\t\u003cimg src=\"myimage.png\" alt=\"\" width=\"600\" height=\"400\"\u003e\n\u003c/throb-ber\u003e\n```\n\nUse your own custom gradient:\n\n```html\n\u003cthrob-ber style=\"--throbber-image: linear-gradient(to right, white, rebeccapurple); --throbber-opacity: 1\"\u003e\n\t\u003cimg src=\"myimage.png\" alt=\"\" width=\"600\" height=\"400\"\u003e\n\u003c/throb-ber\u003e\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzachleat%2Fthrobber","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzachleat%2Fthrobber","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzachleat%2Fthrobber/lists"}