Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
06aaaaa
feat(icon): add support for slotted content
brandyscarney Jul 10, 2026
175fed2
test(ionicons): refactor the tests to individual pages with shared st…
brandyscarney Jul 21, 2026
6bf9274
test(icon): move all test files into the icon test folder
brandyscarney Jul 21, 2026
3a2a57e
test(icon): consistent head tags and titles for tests
brandyscarney Jul 21, 2026
a295aef
test(icon): fix screenshots and naming
brandyscarney Jul 21, 2026
77ca364
chore(): add updated snapshots
Ionitron Jul 21, 2026
ed357ea
chore(testing): update test to run spec and e2e and document it
brandyscarney Jul 22, 2026
99cb543
chore(deps): update to playwright and jest to resolve errors
brandyscarney Jul 22, 2026
54aff8e
test(icon): fix sanitization test and add e2e test
brandyscarney Jul 22, 2026
00a2169
test(icon): add a11y test for icon
brandyscarney Jul 22, 2026
4cea47b
chore(prettier): ignore components file and run prettier on test files
brandyscarney Jul 22, 2026
4bb43d8
chore(deps): update stencil to latest
brandyscarney Jul 22, 2026
bf00f5a
chore(): add updated snapshots
Ionitron Jul 22, 2026
a912828
revert(icon): revert slotted font support
brandyscarney Jul 22, 2026
cd916b1
test(csp): fix import path
brandyscarney Jul 24, 2026
e6a33bb
chore(build): remove duplicate copy task
brandyscarney Jul 24, 2026
dfd6b88
test(icon): fix asset path
brandyscarney Jul 24, 2026
182a7ed
chore: delete snapshots to regenerate
brandyscarney Jul 24, 2026
0d622f4
chore(): add updated snapshots
Ionitron Jul 24, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
src/components.d.ts
97 changes: 71 additions & 26 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,20 +6,18 @@ This document outlines the guidelines and processes for contributing to this pro

## Table of Contents

- [Contributing to Ionicons](#contributing-to-ionicons)
- [Table of Contents](#table-of-contents)
- [Code of Conduct](#code-of-conduct)
- [Getting Started](#getting-started)
- [Prerequisites](#prerequisites)
- [Environment Setup](#environment-setup)
- [Development Workflow](#development-workflow)
- [Branch Strategy](#branch-strategy)
- [Component Modifications](#component-modifications)
- [Testing Changes](#testing-changes)
- [Code Style](#code-style)
- [Building](#building)
- [Submitting Issues](#submitting-issues)
- [Submitting Pull Requests](#submitting-pull-requests)
- [Code of Conduct](#code-of-conduct)
- [Getting Started](#getting-started)
* [Prerequisites](#prerequisites)
* [Environment Setup](#environment-setup)
- [Development Workflow](#development-workflow)
* [Branch Strategy](#branch-strategy)
* [Component Modifications](#component-modifications)
* [Testing](#testing)
* [Code Style](#code-style)
* [Building](#building)
- [Submitting Issues](#submitting-issues)
- [Submitting Pull Requests](#submitting-pull-requests)

## Code of Conduct

Expand Down Expand Up @@ -84,20 +82,67 @@ If you're modifying the `ion-icon` component:

1. Navigate to `src/components/` directory and open the `icon` component to modify
2. Make your changes to the component code
3. Test your changes (see [Testing Changes](#testing-changes))
3. Test your changes locally with `npm start`
4. Run the full test suite: `npm run test.spec` for unit tests and `npm run test.e2e` for E2E tests
5. All PRs that change component behavior must include tests covering the changes

### Testing Changes
### Testing

To preview component changes:
Tests are crucial for maintaining confidence in changes. All PRs that modify component behavior must include tests covering those changes.

1. Run:
```bash
npm start
```
This will start a local version of the icon test with a test page

2. Modify the test page in `index.html` as needed to test your changes
3. If you are modifying icons, you can run `npm run build.files` to re-run the SVG optimization script to verify there are no changes after optimizing the SVG
#### Local Development & Previewing

To preview component changes during development:

```bash
npm start
```

This starts the dev server with live-reloading. The test landing page displays all available test pages.

Test pages are organized in `src/components/icon/test/` with individual folders for each test scenario.

#### Unit Tests

Run Jest tests for component logic:

```bash
npm run test.spec
```

#### E2E Tests

Run Playwright tests to generate visual regression snapshots and verify component behavior:

```bash
npm run test.e2e
```

View the HTML report after tests complete:

```bash
npx playwright show-report
```

> [!IMPORTANT]
> All E2E test navigation URLs must include a trailing slash (e.g., `/icon/test/basic/` not `/icon/test/basic`). The trailing slash ensures proper directory routing, correct timing for script initialization, and consistent page loading across browsers.

##### Updating Snapshots

To update visual regression snapshots with new baselines:

```bash
npm run test.e2e -- --update-snapshots
```

Or for a specific test:

```bash
npm run test.e2e -- src/components/icon/test/basic/icon.e2e.ts --update-snapshots
```

> [!NOTE]
> Updating snapshots locally updates your gitignored screenshot files for local testing. To update the official repository snapshots, run the "Update Reference Screenshots" GitHub action with your development branch selected.

### Code Style

Expand Down Expand Up @@ -148,4 +193,4 @@ When creating issues:
- Include relevant tests
- Make sure all tests pass: `npm test`
- Update documentation if needed
- [Create a new pull request](https://github.com/ionic-team/ionicons/compare) with the `main` branch as the base.
- [Create a new pull request](https://github.com/ionic-team/ionicons/compare) with the `main` branch as the base.
Loading
Loading