{"id":21240630,"url":"https://github.com/chrisnajman/filter-items","last_synced_at":"2025-06-12T06:42:17.737Z","repository":{"id":212699126,"uuid":"732102480","full_name":"chrisnajman/filter-items","owner":"chrisnajman","description":"Filter items by category.","archived":false,"fork":false,"pushed_at":"2024-01-16T17:23:09.000Z","size":36,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-21T19:36:43.434Z","etag":null,"topics":["css-imports","css-nesting","dark-mode","es6-modules","html-css-javascript","intersection-observer-api","lazy-loading","startviewtransition-api"],"latest_commit_sha":null,"homepage":"https://chrisnajman.github.io/filter-items/","language":"CSS","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/chrisnajman.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-12-15T16:43:28.000Z","updated_at":"2024-10-04T23:33:37.000Z","dependencies_parsed_at":"2023-12-24T19:50:25.246Z","dependency_job_id":"a7b570d3-08ad-457b-874d-dbe338048248","html_url":"https://github.com/chrisnajman/filter-items","commit_stats":null,"previous_names":["chrisnajman/filter-items"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chrisnajman%2Ffilter-items","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chrisnajman%2Ffilter-items/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chrisnajman%2Ffilter-items/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chrisnajman%2Ffilter-items/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/chrisnajman","download_url":"https://codeload.github.com/chrisnajman/filter-items/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243681002,"owners_count":20330155,"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":["css-imports","css-nesting","dark-mode","es6-modules","html-css-javascript","intersection-observer-api","lazy-loading","startviewtransition-api"],"created_at":"2024-11-21T00:52:12.299Z","updated_at":"2025-03-15T03:43:41.611Z","avatar_url":"https://github.com/chrisnajman.png","language":"CSS","readme":"# Filter Items\n\n## Description\n\nThe page displays the contents of a `.json` file and allows filtering by category. Filter transitions are implemented using the `startViewTransition` API, while images are lazily loaded through the `intersectionObserver` API.\n\nThis template has been assembled from a combination of online tutorials (see [Sources](#sources) section) and has been extended and customized.\n\n## HTML\n\n- The HTML uses the `template` tag to generate individual items.\n\n## JavaScript\n\nES6 Modules are used without transpilation to ES5.\n\n- `js/modules/items/items-filter.js` - Filters items based on their category, wrapped in a `startViewTransition` function. _Note_: There is a fallback for non-supporting browsers; however, Firefox may log `startViewTransition` as a type error without affecting the page display.\n- `js/modules/observers/lazy-load-images-intersection-observer.js` - Lazy-loads images upon entering the viewport.\n- `js/modules/items/items-display.js` - Outputs content from items.json into the HTML template.\n- `js/modules/observers/article-header-intersection-observer` - Handles the visibility of 'Back to filters' when scrolling past the article header.\n- Additionally, `js/modules/theme-switcher.js` provides functionality for toggling dark mode, saving the selected mode to local storage.\n\n## CSS\n\n- grid is used for page layout, while flexbox is used for page elements.\n- File organization is done using @import to pull modules into index.css.\n- CSS nesting is used for internal file organization.\n- Dark theme option is available.\n\n## WAVE Web Accessibility Evaluation Tools Report\n\n- [Automated accessibility analysis results](https://wave.webaim.org/report#/https://wave.webaim.org/report#/https://chrisnajman.github.io/filter-items/)\n\n## Testing\n\nTested on Windows 10 with:\n\n- Chrome\n- Firefox\n- Microsoft Edge\n\nThe page has been tested in both browser and device views.\n\n## Related\n\n- [Index of Git Pages](https://github.com/chrisnajman/git-pages-index/). A directory of all of my Git Pages websites built from this template.\n\n## Sources\n\n- [Awesome filtering animation with vanilla JS!](https://youtu.be/jZiZs8cZAKU?si=NLNAy0kLiczORjaW)\n- [Image Lazy Loading Using Browser's Intersection Observer API by Roy (Codepen)](https://codepen.io/roypartha97/pen/abpKNJr)\n- A directory containing all my Git Pages websites built from this template.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchrisnajman%2Ffilter-items","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fchrisnajman%2Ffilter-items","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchrisnajman%2Ffilter-items/lists"}