Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/swiftui support #43

Open
wants to merge 20 commits into
base: master
Choose a base branch
from
Open

Conversation

ZvonimirMedak
Copy link
Contributor

Summary

This PR adds SwiftUI support to the Sentinel library, with the refactor of the currently available tools to SwiftUI.
There are a lot of files changed, but some of them are minor changes, and some of them have been deleted

Related issue: None

Changes

Type

  • [-] Feature: This pull request introduces a new feature.
  • [-] Bug fix: This pull request fixes a bug.
  • Refactor: This pull request refactors existing code.
  • [-] Documentation: This pull request updates documentation.
  • [-] Other: This pull request makes other changes.

Additional information

  • This pull request introduces a breaking change.

Description

This PR contains three major updates to the current state of the library:

  1. The Tool protocol now contains a ViewBuilder for the SwiftUI view representing the Tool. Removing the UIKit coupling with the presentPreview
  2. The ToolTableItem is an Enum now which contains four primary cases (Navigation, Toggle, CustomInfo, and Performance) which can be added to the List view to be easily shown in Sentinel. Also, includes a new .custom case which adds support for a custom View, and behavior
  3. The currently available tools have been refactored to use SwiftUI. Although, EmailSender, and Custom location have been wrapped in a UIViewRepresentable since there's no support for MessagesUI in SwiftUI, and CustomLocation would lose some of its functionalities due to lack of MapReader on iOS 14

Checklist

  • I have performed a self-review of my own code.
  • I have tested my changes, including edge cases.
  • I have added necessary tests for the changes introduced (if applicable).
  • [-] I have updated the documentation to reflect my changes (if applicable).

Additional notes

The code documentation will be added in a separate PR

@ZvonimirMedak ZvonimirMedak added the enhancement New feature or request label Dec 13, 2024
@ZvonimirMedak ZvonimirMedak self-assigned this Dec 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant