Skip to content

Commit

Permalink
Fix CI
Browse files Browse the repository at this point in the history
  • Loading branch information
Juliano1612 committed May 13, 2024
1 parent 2a341a6 commit 5aa0cf0
Show file tree
Hide file tree
Showing 6 changed files with 5 additions and 113 deletions.
79 changes: 0 additions & 79 deletions .swiftpm/xcode/xcshareddata/xcschemes/SpruceIDWalletSdk.xcscheme

This file was deleted.

18 changes: 0 additions & 18 deletions Package.resolved
Original file line number Diff line number Diff line change
Expand Up @@ -18,24 +18,6 @@
"version" : "1.0.2"
}
},
{
"identity" : "swiftbackports",
"kind" : "remoteSourceControl",
"location" : "https://github.com/shaps80/SwiftBackports",
"state" : {
"revision" : "ddca6a237c1ba2291d5a3cc47ec8480ce6e9f805",
"version" : "1.0.3"
}
},
{
"identity" : "swiftuibackports",
"kind" : "remoteSourceControl",
"location" : "https://github.com/shaps80/SwiftUIBackports.git",
"state" : {
"revision" : "f5f23b016eeda6642a0fe1020241af19c9c05556",
"version" : "2.8.1"
}
},
{
"identity" : "wallet-sdk-rs",
"kind" : "remoteSourceControl",
Expand Down
4 changes: 1 addition & 3 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import PackageDescription
let package = Package(
name: "SpruceIDWalletSdk",
platforms: [
.iOS(.v13)
.iOS(.v14)
],
products: [
.library(
Expand All @@ -17,15 +17,13 @@ let package = Package(
.package(url: "https://github.com/spruceid/wallet-sdk-rs.git", from: "0.0.25"),
// .package(path: "../wallet-sdk-rs"),
.package(url: "https://github.com/apple/swift-algorithms", from: "1.2.0"),
.package(url: "https://github.com/shaps80/SwiftUIBackports.git", from: "2.0.0")
],
targets: [
.target(
name: "SpruceIDWalletSdk",
dependencies: [
.product(name: "SpruceIDWalletSdkRs", package: "wallet-sdk-rs"),
.product(name: "Algorithms", package: "swift-algorithms"),
.product(name: "SwiftUIBackports", package: "SwiftUIBackports")
]
),
.testTarget(
Expand Down
12 changes: 4 additions & 8 deletions Sources/WalletSdk/ui/QRCodeScanner.swift
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import SwiftUI
import AVKit
import SwiftUIBackports
import os.log

public class QRScannerDelegate: NSObject, ObservableObject, AVCaptureMetadataOutputObjectsDelegate {
Expand Down Expand Up @@ -69,7 +68,7 @@ public struct QRCodeScanner: View {
@State private var qrOutput: AVCaptureMetadataOutput = .init()

/// Camera QR Output delegate
@Backport.StateObject private var qrDelegate = QRScannerDelegate()
@StateObject private var qrDelegate = QRScannerDelegate()

/// Scanned code
@State private var scannedCode: String = ""
Expand Down Expand Up @@ -152,16 +151,13 @@ public struct QRCodeScanner: View {
)
.rotationEffect(.init(degrees: rotation))
}
}
.frame(width: size.width * 0.6, height: size.width * 0.6)

/// Scanner Animation
.backport.overlay {
/// Scanner Animation
Rectangle()
.fill(readerColor)
.frame(height: 2.5)
.offset(y: isScanning ? (size.width * 0.59)/2 : -(size.width * 0.59)/2)
}
.frame(width: size.width * 0.6, height: size.width * 0.6)

}
/// Square Shape
Expand Down Expand Up @@ -210,7 +206,7 @@ public struct QRCodeScanner: View {
session.stopRunning()
}

.backport.onChange(of: qrDelegate.scannedCode) { newValue in
.onChange(of: qrDelegate.scannedCode) { newValue in
if let code = newValue {
scannedCode = code

Expand Down
1 change: 0 additions & 1 deletion SpruceIDWalletSdk.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ Pod::Spec.new do |spec|

spec.static_framework = true
spec.dependency 'SpruceIDWalletSdkRs', "~> 0.0.24"
spec.dependency 'SwiftUIBackports', "~> 2.0.0"
spec.dependency 'SwiftAlgorithms', "~> 1.0.0"
spec.frameworks = 'Foundation', 'CoreBluetooth', 'CryptoKit'
end
4 changes: 0 additions & 4 deletions project.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,6 @@ packages:
SwiftLint:
url: https://github.com/realm/SwiftLint
from: 0.54.0
SwiftUIBackports:
url: https://github.com/shaps80/SwiftUIBackports.git
from: 2.0.0
settings:
ENABLE_USER_SCRIPT_SANDBOXING: YES
GENERATE_INFOPLIST_FILE: YES
Expand All @@ -27,7 +24,6 @@ targets:
sources:
- Sources
dependencies:
- package: SwiftUIBackports
- package: SpruceIDWalletSdkRs
- package: SwiftAlgorithms
product: Algorithms
Expand Down

0 comments on commit 5aa0cf0

Please sign in to comment.