{"id":18810376,"url":"https://github.com/absaoss/cps-shared-ui","last_synced_at":"2026-04-15T20:01:09.671Z","repository":{"id":216793924,"uuid":"624459608","full_name":"AbsaOSS/cps-shared-ui","owner":"AbsaOSS","description":"Angular shared components library","archived":false,"fork":false,"pushed_at":"2025-08-06T09:23:15.000Z","size":3247,"stargazers_count":9,"open_issues_count":26,"forks_count":3,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-08-06T10:09:58.734Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://absaoss.github.io/cps-shared-ui/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/AbsaOSS.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":".github/CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2023-04-06T14:11:08.000Z","updated_at":"2025-08-06T09:23:18.000Z","dependencies_parsed_at":"2024-03-25T15:25:50.576Z","dependency_job_id":"393d8327-ebe3-41da-adbb-0d04b5c4886a","html_url":"https://github.com/AbsaOSS/cps-shared-ui","commit_stats":null,"previous_names":["absaoss/cps-shared-ui"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/AbsaOSS/cps-shared-ui","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AbsaOSS%2Fcps-shared-ui","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AbsaOSS%2Fcps-shared-ui/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AbsaOSS%2Fcps-shared-ui/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AbsaOSS%2Fcps-shared-ui/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/AbsaOSS","download_url":"https://codeload.github.com/AbsaOSS/cps-shared-ui/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AbsaOSS%2Fcps-shared-ui/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":269690619,"owners_count":24459874,"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-10T02:00:08.965Z","response_time":71,"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":[],"created_at":"2024-11-07T23:20:01.483Z","updated_at":"2026-04-15T20:01:09.665Z","avatar_url":"https://github.com/AbsaOSS.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"## Consumer Products UI Kit\n\n### Angular shared components library\n\nThis repository consists of two projects:\n\n- `cps-ui-kit` - shared components library itself\n- `composition` - application for previewing compositions of components consumed from the library\n\n#### Available components\n\n- Autocomplete\n- Button\n- Button toggles\n- Checkbox\n- Chip\n- Datepicker\n- Dialog\n- Divider\n- Expansion panel\n- File upload\n- Icon\n- Info circle\n- Input\n- Loader\n- Menu\n- Notifications\n- Paginator\n- Progress circular (indeterminate)\n- Progress linear (indeterminate)\n- Radio\n- Scheduler\n- Select\n- Sidebar menu\n- Switch\n- Table\n- Tabs\n- Tag\n- Textarea\n- Timepicker\n- Tooltip directive\n- Tree autocomplete\n- Tree select\n- Tree table\n\n## Development server\n\nRun `ng build cps-ui-kit --watch` and `ng serve` for a dev server. Navigate to `http://localhost:4200/`. The application will automatically reload if you change any of the source files.\n\n## Design guidelines\n\nhttps://www.figma.com/file/JAlfp4zwZIONMWYPbLY4aM/Consumer-products-design-system?node-id=0%3A1\u0026t=qVkCtHGgnZSpAYVp-1\n\n## How-to\n\n#### Create a new component\n\n- go to `projects/cps-ui-kit/src/lib/components` directory\n- run: `ng g c cps-componentname --standalone --prefix`\n- modify `projects/cps-ui-kit/src/public-api.ts` to export the component from the library\n- update available components list in `projects/cps-ui-kit/README.md` (keep alphabetical order!)\n\nMake sure `ng build cps-ui-kit --watch` is running, so the library will be rebuilt on each change of its contents due to `--watch` flag\n\n#### Create a composition page\n\n- go to `projects/composition/src/app/pages` directory\n- run: `ng g c componentname-page --standalone`\n- there is no need to test composition pages, so manually delete `componentname-page.component.cy.ts` file (can't be done automatically with Angular CLI flag, since cypress is used)\n- provide `host: { class: 'composition-page' }` into page `@Component`\n- import the components for the composition page from `cps-ui-kit`, provide them to imports array of `@Component`\n- include `ComponentDocsViewerComponent` into `@Component` `imports` array in case of a new component page, include `ServiceDocsViewerComponent` into `@Component` `imports` array in case of a new service page\n- import `ComponentData or ServiceData` from '../../api-data/cps-componentname.json' once it is generated\n- wrap page html template contents into `\u003capp-component-docs-viewer [componentData]=\"componentData\"\u003e...\u003c/app-component-docs-viewer\u003e` in case of a new component page, wrap page html template contents into `\u003capp-service-docs-viewer [serviceData]=\"serviceData\"\u003e...\u003c/app-service-docs-viewer\u003e` in case of a new service page\n- go to `projects/composition/src/app/components/navigation-sidebar.component.ts` file and extend `_components` array (keep alphabetical order!)\n- go to `projects/composition/src/app/app-routing.module.ts` and add a new route for a new page\n- update available components list in `/README.md` (keep alphabetical order!)\n\n#### Generate API documentation\n\nExecute `npm run generate-json-api` to generate documentation for any changes in the components' API.\n\n#### Run Jest unit tests\n\n`npm run test`\n\n#### Run Playwright e2e tests\n\n`npm run test:playwright` (headless run)\n\n`npm run test:playwright:headed` to run tests in headed mode (browser visible)\n\n`npm run test:playwright:interactive` to open Playwright UI mode\n\nSee [playwright/README.md](playwright/README.md) for full details.\n\n#### Versioning and publishing\n\nThe CI/CD pipeline automatically bumps the **minor version** and publishes the package to NPM on every push to `master` that either touches files under `projects/cps-ui-kit/**` or modifies `.github/workflows/cps-ui-kit-publish.yml`.\n\nTo publish a **major** or **patch** version instead:\n\n1. Manually update the version in [`projects/cps-ui-kit/package.json`](projects/cps-ui-kit/package.json) to the desired version.\n2. Include `#SkipVersionBump` in the commit message so the pipeline skips the automatic minor bump and publishes exactly the version you set.\n\nExample commit message for the **final/head commit in the push** (the workflow checks only `github.event.head_commit.message`, so `#SkipVersionBump` must appear in the last commit message; the token is matched against the full message, so placing it in the footer is preferred):\n\n```\nchore: release patch fix\n\n#SkipVersionBump\n```\n\n\u003e **Note:** Without `#SkipVersionBump`, any manual version change in `package.json` will be overwritten by the automatic minor bump before publishing.\n\n#### Run accessibility tests\n\nThe project uses [pa11y-ci](https://github.com/pa11y/pa11y-ci) to test all components for WCAG 2.0 AA compliance.\n\nTo run accessibility tests:\n\n1. Start the development server:\n\n   ```bash\n   npm run start\n   ```\n\n2. In a separate terminal, run the accessibility tests:\n   ```bash\n   npm run test:a11y\n   ```\n\nAlternatively, use the combined script that starts the server and runs tests:\n\n```bash\nnpm run test:a11y:local\n```\n\nFor a colorful summary with statistics:\n\n```bash\nnpm run test:a11y:summary\n```\n\nThis will display:\n\n- Total URLs tested with pass/fail ratio\n- Total accessibility errors found\n- Accessibility standard (WCAG 2.0 AA)\n- Test engine (axe-core via pa11y-ci)\n- Top 10 components with the most issues\n\nThe tests will check all 33 components for accessibility issues and report any violations found.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fabsaoss%2Fcps-shared-ui","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fabsaoss%2Fcps-shared-ui","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fabsaoss%2Fcps-shared-ui/lists"}