Skip to content

[Bug] Some icons render incorrectly or throw warnings when used in iOS, macOS xcasset bundles #866

@eliperkins

Description

@eliperkins

Describe the bug

I put the SVG assets from the v17.9.0 release of Octicons into an xcasset bundle, enabling "Preserve Vector Data", and built a viewer for the Octicons within a macOS app.

A number of the icons rendered odd paths, resulting in improper display of the icons.

List of affected icons

  • broadcast-16
  • broadcast-24
  • copilot-48
  • copilot-96
  • copilot-warning-16
  • eye-closed-24
  • file-badge-16
  • gear-24
  • history-16
  • issue-draft-16
  • issue-draft-24
  • issue-reopened-16
  • iterations-16
  • iterations-24
  • link-16
  • link-24
  • mention-16
  • mention-24
  • meter-16
  • moon-16
  • number-24
  • paintbrush-16
  • paperclip-16
  • paste-16
  • paste-16
  • people-16
  • people-24
  • person-16
  • person-24
  • person-add-16
  • person-add-24
  • person-fill-16
  • person-fill-24
  • question-16
  • rss-16
  • rss-24
  • squirrel-16
  • squirrel-24
  • tools-24
  • unmute-16
  • unmute-24
  • unverified-16
  • webhook-16

Steps to reproduce

For Hubbers:

  1. Run the Octicons.app from github/octicons

For non-Hubbers:

  1. Create a new iOS or macOS app
  2. Add any of the affected Octicons to the app as an SVG asset within an xcassets bundle
  3. Render the Octicon within the app

Expected behavior

Octicons render on iOS and macOS in the same manner that they do within web browsers, without the need for modifications.

Screenshots

Please add screenshots to help explain the problem.

gear-24 history-16 issue-draft-16 iterations-24 person-24
Screenshot 2022-11-07 at 4 06 04 PM Screenshot 2022-11-07 at 4 06 09 PM Screenshot 2022-11-07 at 4 06 12 PM Screenshot 2022-11-07 at 4 06 15 PM Screenshot 2022-11-07 at 4 06 22 PM

Device details

Desktop (please complete the following information):

  • OS: macOS 12+
  • Browser: n/a
  • Version: n/a

Smartphone (please complete the following information):

  • Device: all iOS devices
  • OS: iOS 15+
  • Browser: n/a
  • Version: n/a

Additional info

Currently, GitHub Mobile uses the PDFs as exported from the Octicons site, which render fine! It seems to be the format of the SVGs that iOS and macOS don't like.

However, if we can build SVGs that work on iOS and macOS, we can leverage the versioning of the npm package to have Octicons be version-bumped by Dependabot automagically, keeping GitHub Mobile's icons consistently up-to-date.

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions