Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Package.swift
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// swift-tools-version: 5.9
// swift-tools-version: 6.1
import PackageDescription

let package = Package(
Expand Down
4 changes: 2 additions & 2 deletions Sources/SkipUI/SkipUI/Animation/Transition.swift
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ extension Transition {
#endif
}

public struct ContentTransition : RawRepresentable, Equatable {
public struct ContentTransition : RawRepresentable, Equatable, Sendable {
public let rawValue: Int

public init(rawValue: Int) {
Expand Down Expand Up @@ -428,7 +428,7 @@ public struct OffsetTransition : Transition {
}

// SKIP @bridge
public struct OpacityTransition : Transition {
public struct OpacityTransition : Transition, Sendable {
static let shared = OpacityTransition()

// SKIP @bridge
Expand Down
2 changes: 1 addition & 1 deletion Sources/SkipUI/SkipUI/App/Scene.swift
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ extension Scene {
}
}

public struct ScenePadding : Equatable {
public struct ScenePadding : Equatable, Sendable {
public static let minimum = ScenePadding()
}

Expand Down
2 changes: 1 addition & 1 deletion Sources/SkipUI/SkipUI/Color/Color.swift
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import androidx.compose.ui.unit.dp
#endif

// SKIP @bridge
public struct Color: ShapeStyle, Renderable, Hashable {
public struct Color: ShapeStyle, Renderable, Hashable, Sendable {
#if SKIP
public let colorImpl: @Composable () -> androidx.compose.ui.graphics.Color

Expand Down
14 changes: 7 additions & 7 deletions Sources/SkipUI/SkipUI/Commands/Actions.swift
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ public struct DismissAction {
self.action = action
}

static let `default` = DismissAction(action: { })
nonisolated(unsafe) static let `default` = DismissAction(action: { })

public func callAsFunction() {
action()
Expand All @@ -23,7 +23,7 @@ public struct DismissAction {
// SKIP @bridge
public struct OpenURLAction {
// SKIP @bridge
public struct Result {
public struct Result: Sendable {
// SKIP @bridge
public let rawValue: Int
// SKIP @bridge
Expand Down Expand Up @@ -51,7 +51,7 @@ public struct OpenURLAction {
// SKIP @bridge
public let systemHandler: ((URL) throws -> Void)?

static let `default`: OpenURLAction = OpenURLAction(handler: { _ in Result.systemAction })
nonisolated(unsafe) static let `default`: OpenURLAction = OpenURLAction(handler: { _ in Result.systemAction })

// SKIP @bridge
public init(handler: @escaping (URL) -> Result) {
Expand Down Expand Up @@ -91,10 +91,10 @@ public struct OpenURLAction {
}

// SKIP @bridge
public struct RefreshAction {
public let action: () async -> Void
public struct RefreshAction: Sendable {
public let action: @Sendable () async -> Void

public init(action: @escaping () async -> Void) {
public init(action: @Sendable @escaping () async -> Void) {
self.action = action
}

Expand Down Expand Up @@ -122,7 +122,7 @@ public struct RefreshAction {
}

// SKIP @bridge
public func run(completion: @escaping () -> Void) {
public func run(completion: @Sendable @escaping () -> Void) {
Task {
await action()
completion()
Expand Down
2 changes: 1 addition & 1 deletion Sources/SkipUI/SkipUI/Commands/DragDrop.swift
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ public enum DropOperation: Int, Hashable, Sendable {
case move = 8
case delete = 16

public struct Set : OptionSet, Hashable {
public struct Set : OptionSet, Hashable, Sendable {
public let rawValue: Int

public init(rawValue: Int) {
Expand Down
2 changes: 1 addition & 1 deletion Sources/SkipUI/SkipUI/Commands/EditActions.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#if !SKIP_BRIDGE
import Foundation

public struct EditActions /* <Data> */ : OptionSet {
public struct EditActions /* <Data> */ : OptionSet, Sendable {
public let rawValue: Int

public init(rawValue: Int) {
Expand Down
4 changes: 2 additions & 2 deletions Sources/SkipUI/SkipUI/Commands/KeyboardShortcut.swift
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
// SPDX-License-Identifier: MPL-2.0
#if !SKIP_BRIDGE

public struct KeyboardShortcut : Hashable {
public enum Localization : Hashable {
public struct KeyboardShortcut : Hashable, Sendable {
public enum Localization : Hashable, Sendable {
case automatic
case withoutMirroring
case custom
Expand Down
6 changes: 3 additions & 3 deletions Sources/SkipUI/SkipUI/Commands/Menu.swift
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ public final class Menu : View, Renderable {
#endif
}

public struct MenuStyle: RawRepresentable, Equatable {
public struct MenuStyle: RawRepresentable, Equatable, Sendable {
public let rawValue: Int

public init(rawValue: Int) {
Expand All @@ -257,7 +257,7 @@ public struct MenuStyle: RawRepresentable, Equatable {
public static let button = MenuStyle(rawValue: 1) // For bridging
}

public struct MenuActionDismissBehavior: RawRepresentable, Equatable {
public struct MenuActionDismissBehavior: RawRepresentable, Equatable, Sendable {
public let rawValue: Int

public init(rawValue: Int) {
Expand All @@ -270,7 +270,7 @@ public struct MenuActionDismissBehavior: RawRepresentable, Equatable {
public static let disabled = MenuActionDismissBehavior(rawValue: 1) // For bridging
}

public struct MenuOrder: RawRepresentable, Equatable, Hashable {
public struct MenuOrder: RawRepresentable, Equatable, Hashable, Sendable {
public let rawValue: Int

public init(rawValue: Int) {
Expand Down
2 changes: 1 addition & 1 deletion Sources/SkipUI/SkipUI/Commands/Search.swift
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ extension View {
}
}

public struct SearchFieldPlacement : RawRepresentable {
public struct SearchFieldPlacement : RawRepresentable, Sendable {
public let rawValue: Int

public init(rawValue: Int) {
Expand Down
2 changes: 1 addition & 1 deletion Sources/SkipUI/SkipUI/Commands/SubmitTriggers.swift
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
// SPDX-License-Identifier: MPL-2.0
#if !SKIP_BRIDGE

public struct SubmitTriggers : OptionSet {
public struct SubmitTriggers : OptionSet, Sendable {
public let rawValue: Int

public init(rawValue: Int) {
Expand Down
16 changes: 8 additions & 8 deletions Sources/SkipUI/SkipUI/Commands/Toolbar.swift
Original file line number Diff line number Diff line change
Expand Up @@ -214,13 +214,13 @@ public struct ToolbarSpacer : ToolbarContent, CustomizableToolbarContent, View,
#endif
}

public enum ToolbarCustomizationBehavior {
public enum ToolbarCustomizationBehavior: Sendable {
case `default`
case reorderable
case disabled
}

public struct ToolbarItemPlacement: RawRepresentable, Equatable {
public struct ToolbarItemPlacement: RawRepresentable, Equatable, Sendable {
public let rawValue: Int

public init(rawValue: Int) {
Expand Down Expand Up @@ -252,38 +252,38 @@ public struct ToolbarItemPlacement: RawRepresentable, Equatable {
public static let largeSubtitle = ToolbarItemPlacement(rawValue: 18) // For bridging
}

public enum ToolbarPlacement: Int, Equatable {
public enum ToolbarPlacement: Int, Equatable, Sendable {
case automatic = 0 // For bridging
case bottomBar = 1 // For bridging
case navigationBar = 2 // For bridging
case tabBar = 3 // For bridging
}

public enum ToolbarRole {
public enum ToolbarRole: Sendable {
case automatic
case navigationStack
case browser
case editor
}

public enum ToolbarTitleDisplayMode: Int {
public enum ToolbarTitleDisplayMode: Int, Sendable {
case automatic = 0 // For bridging
case large = 1 // For bridging
case inlineLarge = 2 // For bridging
case inline = 3 // For bridging
}

public struct ToolbarCustomizationOptions : OptionSet {
public struct ToolbarCustomizationOptions : OptionSet, Sendable, Sendable {
public let rawValue: Int

public init(rawValue: Int) {
self.rawValue = rawValue
}

public static var alwaysAvailable = ToolbarCustomizationOptions(rawValue: 1 << 0)
public static let alwaysAvailable = ToolbarCustomizationOptions(rawValue: 1 << 0)
}

public struct ToolbarDefaultItemKind : RawRepresentable {
public struct ToolbarDefaultItemKind : RawRepresentable, Sendable, Sendable {
public let rawValue: Int // For bridging

public init(rawValue: Int) {
Expand Down
2 changes: 1 addition & 1 deletion Sources/SkipUI/SkipUI/Components/ProgressView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ public struct ProgressView : View, Renderable {
#endif
}

public struct ProgressViewStyle: RawRepresentable, Equatable {
public struct ProgressViewStyle: RawRepresentable, Equatable, Sendable {
public let rawValue: Int

public init(rawValue: Int) {
Expand Down
2 changes: 1 addition & 1 deletion Sources/SkipUI/SkipUI/Compose/ComposeResult.swift
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@
/// The result of composing content.
///
/// Reserved for future use. Having a return value also expands recomposition scope. See `ComposeBuilder` for details.
public struct ComposeResult {
public struct ComposeResult: Sendable {
public static let ok = ComposeResult()
}
2 changes: 1 addition & 1 deletion Sources/SkipUI/SkipUI/Containers/DisclosureGroup.swift
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ public struct DisclosureGroup : View, Renderable {
#endif
}

public struct DisclosureGroupStyle: RawRepresentable, Equatable {
public struct DisclosureGroupStyle: RawRepresentable, Equatable, Sendable {
public let rawValue: Int

public init(rawValue: Int) {
Expand Down
2 changes: 1 addition & 1 deletion Sources/SkipUI/SkipUI/Containers/Form.swift
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ public struct Form : View {
#endif
}

public struct FormStyle: RawRepresentable, Equatable {
public struct FormStyle: RawRepresentable, Equatable, Sendable {
public let rawValue: Int

public init(rawValue: Int) {
Expand Down
2 changes: 1 addition & 1 deletion Sources/SkipUI/SkipUI/Containers/List.swift
Original file line number Diff line number Diff line change
Expand Up @@ -747,7 +747,7 @@ struct ListStyling: Equatable {
}
#endif

public struct ListStyle: RawRepresentable, Equatable {
public struct ListStyle: RawRepresentable, Equatable, Sendable {
public let rawValue: Int

public init(rawValue: Int) {
Expand Down
10 changes: 5 additions & 5 deletions Sources/SkipUI/SkipUI/Containers/Navigation.swift
Original file line number Diff line number Diff line change
Expand Up @@ -1140,16 +1140,16 @@ struct NavigationDestinationItemWrapper<D: Hashable>: View {
let LocalNavigator: ProvidableCompositionLocal<Navigator?> = compositionLocalOf { nil as Navigator? }
#endif

public struct NavigationSplitViewStyle: RawRepresentable, Equatable {
public struct NavigationSplitViewStyle: RawRepresentable, Equatable, Sendable {
public let rawValue: Int

public init(rawValue: Int) {
self.rawValue = rawValue
}

public static var automatic = NavigationSplitViewStyle(rawValue: 0)
public static var balanced = NavigationSplitViewStyle(rawValue: 1)
public static var prominentDetail = NavigationSplitViewStyle(rawValue: 2)
public static let automatic = NavigationSplitViewStyle(rawValue: 0)
public static let balanced = NavigationSplitViewStyle(rawValue: 1)
public static let prominentDetail = NavigationSplitViewStyle(rawValue: 2)
}

public struct NavigationBarItem : Hashable {
Expand Down Expand Up @@ -1556,7 +1556,7 @@ public struct NavigationLink : View, Renderable {
let label: ComposeBuilder

private static let minimumNavigationInterval = 0.35
private static var lastNavigationTime = 0.0
nonisolated(unsafe) private static var lastNavigationTime = 0.0

public init(value: Any?, @ViewBuilder label: () -> any View) {
self.value = value
Expand Down
2 changes: 1 addition & 1 deletion Sources/SkipUI/SkipUI/Containers/ScrollView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ public struct ScrollTarget {
}
}

public struct PinnedScrollableViews : OptionSet {
public struct PinnedScrollableViews : OptionSet, Sendable {
public let rawValue: Int

public init(rawValue: Int) {
Expand Down
10 changes: 5 additions & 5 deletions Sources/SkipUI/SkipUI/Containers/TabView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -691,7 +691,7 @@ public struct PageTabViewStyle: TabViewStyle {

public let indexDisplayMode: PageTabViewStyle.IndexDisplayMode

public struct IndexDisplayMode: RawRepresentable, Equatable {
public struct IndexDisplayMode: RawRepresentable, Equatable, Sendable {
public let rawValue: Int

public init(rawValue: Int) {
Expand All @@ -718,7 +718,7 @@ extension TabViewStyle where Self == PageTabViewStyle {

// MARK: Tab

public struct TabBarMinimizeBehavior : RawRepresentable, Hashable {
public struct TabBarMinimizeBehavior : RawRepresentable, Hashable, Sendable {
public let rawValue: Int

public init(rawValue: Int) {
Expand Down Expand Up @@ -913,19 +913,19 @@ public struct Tab : TabContent, Renderable {
#endif
}

public struct TabCustomizationBehavior : Equatable {
public struct TabCustomizationBehavior : Equatable, Sendable {
public static let automatic = TabCustomizationBehavior()
public static let reorderable = TabCustomizationBehavior()
public static let disabled = TabCustomizationBehavior()
}

public struct TabPlacement : Hashable {
public struct TabPlacement : Hashable, Sendable {
public static let automatic = TabPlacement()
public static let pinned = TabPlacement()
public static let sidebarOnly = TabPlacement()
}

public enum TabRole : Int, Hashable {
public enum TabRole : Int, Hashable, Sendable {
case search = 1 // For bridging
}

Expand Down
2 changes: 1 addition & 1 deletion Sources/SkipUI/SkipUI/Containers/Table.swift
Original file line number Diff line number Diff line change
Expand Up @@ -470,7 +470,7 @@ extension View {
}
}

public struct TableStyle {
public struct TableStyle: Sendable {
public static let automatic = TableStyle()
@available(*, unavailable)
public static let inset = TableStyle()
Expand Down
4 changes: 2 additions & 2 deletions Sources/SkipUI/SkipUI/Controls/Button.swift
Original file line number Diff line number Diff line change
Expand Up @@ -281,7 +281,7 @@ public struct Button : View, Renderable {
#endif
}

public struct ButtonStyle: RawRepresentable, Equatable {
public struct ButtonStyle: RawRepresentable, Equatable, Sendable {
public let rawValue: Int

public init(rawValue: Int) {
Expand Down Expand Up @@ -313,7 +313,7 @@ public enum ButtonRole : Int, Equatable {
case close = 4 // For bridging
}

public struct ButtonSizing : RawRepresentable, Hashable {
public struct ButtonSizing : RawRepresentable, Hashable, Sendable {
public let rawValue: Int

public init(rawValue: Int) {
Expand Down
2 changes: 1 addition & 1 deletion Sources/SkipUI/SkipUI/Controls/ControlGroup.swift
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public struct ControlGroup : View {
#endif
}

public struct ControlGroupStyle: RawRepresentable, Equatable {
public struct ControlGroupStyle: RawRepresentable, Equatable, Sendable {
public let rawValue: Int

public init(rawValue: Int) {
Expand Down
Loading
Loading