Skip to content
This repository has been archived by the owner on Nov 13, 2024. It is now read-only.

Commit

Permalink
Make Pill, button and PartialSheetPresentation sendable
Browse files Browse the repository at this point in the history
  • Loading branch information
Muhieddine-El-Kaissi committed Jul 8, 2024
1 parent e1526f5 commit 043c8e2
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 17 deletions.
2 changes: 1 addition & 1 deletion Sources/Thumbprint/Components/Button.Theme.swift
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ public extension Button {
/**
* Button size/layout configuration
*/
struct Size: Equatable {
struct Size: Equatable, Sendable {
/// Text style for the button label.
public let textStyle: Font.TextStyle

Expand Down
2 changes: 1 addition & 1 deletion Sources/Thumbprint/Components/Pill.swift
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ open class Pill: UIView, UIContentSizeCategoryAdjusting {
}
}

public struct Theme: Equatable {
public struct Theme: Equatable, Sendable {
public let backgroundColor: UIColor
public let contentColor: UIColor
public let name: String? // Used by some old legacy logic that stores it.
Expand Down
2 changes: 1 addition & 1 deletion Sources/Thumbprint/Font.swift
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ public extension Font {

// MARK: - Public Member Types
public extension Font {
struct TextStyle: Equatable, Hashable {
struct TextStyle: Equatable, Hashable, Sendable {
/// Static font for this text style.
public let uiFont: UIFont
public let weight: ThumbprintTokens.FontWeight
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import UIKit

open class PartialSheetPresentation: NSObject, UIViewControllerTransitioningDelegate {
open class PartialSheetPresentation: NSObject, UIViewControllerTransitioningDelegate, Sendable {
private class PercentDrivenInteractiveTransition: UIPercentDrivenInteractiveTransition, UIViewControllerAnimatedTransitioning {
private var presentedViewFrame: CGRect = .zero
private let triggerPercentage: CGFloat = 0.42
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{
"originHash" : "55ec2b2e8835e0fe998e5eaab1e49761370ba5ee12434cebea0b3ac4008884df",
"pins" : [
{
"identity" : "collectionconcurrencykit",
Expand All @@ -14,8 +15,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/krzyzanowskim/CryptoSwift.git",
"state" : {
"revision" : "32f641cf24fc7abc1c591a2025e9f2f572648b0f",
"version" : "1.7.2"
"revision" : "c9c3df6ab812de32bae61fc0cd1bf6d45170ebf0",
"version" : "1.8.2"
}
},
{
Expand Down Expand Up @@ -50,35 +51,35 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/pointfreeco/swift-snapshot-testing.git",
"state" : {
"revision" : "bb0ea08db8e73324fe6c3727f755ca41a23ff2f4",
"version" : "1.14.2"
"revision" : "625ccca8570773dd84a34ee51a81aa2bc5a4f97a",
"version" : "1.16.0"
}
},
{
"identity" : "swift-syntax",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-syntax.git",
"state" : {
"revision" : "74203046135342e4a4a627476dd6caf8b28fe11b",
"version" : "509.0.0"
"revision" : "6ad4ea24b01559dde0773e3d091f1b9e36175036",
"version" : "509.0.2"
}
},
{
"identity" : "swiftformat",
"kind" : "remoteSourceControl",
"location" : "https://github.com/nicklockwood/SwiftFormat",
"state" : {
"revision" : "d37a477177d5d4ff2a3ae6328eaaab5bf793e702",
"version" : "0.52.9"
"revision" : "ad7707bd34a33fa64a2c593c53deaa7d7469e2f0",
"version" : "0.52.11"
}
},
{
"identity" : "swiftlint",
"kind" : "remoteSourceControl",
"location" : "https://github.com/realm/SwiftLint.git",
"state" : {
"revision" : "6d2e58271ebc14c37bf76d7c9f4082cc15bad718",
"version" : "0.53.0"
"revision" : "f17a4f9dfb6a6afb0408426354e4180daaf49cee",
"version" : "0.54.0"
}
},
{
Expand All @@ -104,8 +105,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/thumbtack/thumbprint-tokens.git",
"state" : {
"revision" : "a91f2295af6fe22bba47807ec384c241aa734985",
"version" : "13.0.1"
"revision" : "746c43b8e75d4678d8bf3fcf2582b74097b0237b",
"version" : "13.0.2"
}
},
{
Expand All @@ -127,5 +128,5 @@
}
}
],
"version" : 2
"version" : 3
}

0 comments on commit 043c8e2

Please sign in to comment.