Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

bug: Invalid @supports syntax in icon.css breaks under strict CSS parsers (e.g. Lightning CSS)

Open Beginner friendly
#1,513 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
1/5
Estimated time
Under an hour
Newbie friendliness
92/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
css
Domain
frontend

Research direction

Open icon.css and locate the @supports rule shown in the issue. Update its condition to use the explicit grouping described in Expected Behavior, then run the Lightning CSS reproduction or swap in stencil/core 5.0.0-alpha.35 and run npm run build to confirm the stylesheet parses successfully.

Written by the indexing model from the issue text.

Description

triage
Current Behavior

icon.css has:

@supports not selector(:dir(rtl)) and selector(:host-context([dir='rtl'])) {
  :host(.icon-rtl) .icon-inner {
    transform: scaleX(-1);
  }
}

Per the CSS Conditional Rules spec, not and and can't be mixed in a <supports-condition> without explicit parens grouping each operand.

Whilst PostCSS allowed this formatting, Lightning CSS (used in the upcoming stencil v5 release) fails with: Unexpected token Ident("and")

Expected Behavior
@supports (not selector(:dir(rtl))) and (selector(:host-context([dir='rtl']))) {
Steps to Reproduce
const { transform } = require('lightningcss');
transform({
  filename: 'icon.css',
  code: Buffer.from(`
    @supports not selector(:dir(rtl)) and selector(:host-context([dir='rtl'])) {
      a { color: red; }
    }
  `),
});
// throws: Unexpected token Ident("and")

Alternatively, swap in stencil/core 5.0.0-alpha.35 in the main ionic repo and run npm run build

Code Reproduction URL

No response

Additional Information

No response

Dominant language
TypeScript
Stars
18.2k
Forks
2.1k
PR merge metrics
No merged PRs in 30d

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from ionic-team/ionicons

All issues in ionic-team/ionicons

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.