Skip to content

Conversation

@Kyle-Ye
Copy link
Collaborator

@Kyle-Ye Kyle-Ye commented Jan 11, 2026

No description provided.

@augmentcode
Copy link

augmentcode bot commented Jan 11, 2026

🤖 Augment PR Summary

Summary: This PR introduces the SwiftUI-compatible SymbolVariants API surface in OpenSwiftUI, enabling environment-driven selection of SF Symbols variants.

Changes:

  • Added SymbolVariants (Hashable/Sendable) with support for shape variants (circle/square/rectangle) and flag variants (fill, slash, and SPI background).
  • Implemented variant composition semantics via formUnion/contains so repeated modifiers accumulate and the closest shape modifier wins.
  • Added a View.symbolVariant(_:) modifier that updates EnvironmentValues.symbolVariants using transformEnvironment.
  • Introduced environment keys for symbolVariants plus SPI v4 values (symbolBackgroundCornerRadius, symbolsGrowToFitBackground).
  • Included internal helpers to derive shape suffixes and generate paths for symbol backgrounds.

Technical Notes: The implementation focuses on API + environment plumbing (v3+ public surface, v4 SPI additions) and sets defaults to .none with additive composition behavior.

🤖 Was this summary useful? React with 👍 or 👎

Copy link

@augmentcode augmentcode bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review completed. 1 suggestions posted.

Fix All in Augment

Comment augment review to trigger a new review at any time.

@Kyle-Ye Kyle-Ye force-pushed the feature/symbol_varients branch 2 times, most recently from 4337c01 to d038036 Compare January 11, 2026 19:47
@codecov
Copy link

codecov bot commented Jan 11, 2026

Codecov Report

❌ Patch coverage is 0% with 54 lines in your changes missing coverage. Please review.
✅ Project coverage is 14.43%. Comparing base (d0249df) to head (2b65fba).
⚠️ Report is 2 commits behind head on main.

Files with missing lines Patch % Lines
...es/OpenSwiftUICore/View/Image/SymbolVariants.swift 0.00% 54 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #719      +/-   ##
==========================================
- Coverage   14.46%   14.43%   -0.04%     
==========================================
  Files         565      566       +1     
  Lines       33335    33389      +54     
==========================================
- Hits         4822     4819       -3     
- Misses      28513    28570      +57     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@Kyle-Ye Kyle-Ye changed the title Add SymbolVarients API support Add SymbolVariants API support Jan 11, 2026
@Kyle-Ye Kyle-Ye force-pushed the feature/symbol_varients branch from d038036 to 2b65fba Compare January 11, 2026 20:20
@Kyle-Ye Kyle-Ye merged commit 2e669c9 into main Jan 11, 2026
5 of 8 checks passed
@Kyle-Ye Kyle-Ye deleted the feature/symbol_varients branch January 11, 2026 20:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants