Skip to content

Commit 698cdf4

Browse files
authored
Merge pull request #33 from star-s/master
SPM support
2 parents 1475369 + f204fa5 commit 698cdf4

File tree

3 files changed

+47
-1
lines changed

3 files changed

+47
-1
lines changed

Package.swift

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
// swift-tools-version:5.3
2+
// The swift-tools-version declares the minimum version of Swift required to build this package.
3+
4+
import PackageDescription
5+
6+
let package = Package(
7+
name: "PasswordTextField",
8+
products: [
9+
// Products define the executables and libraries a package produces, and make them visible to other packages.
10+
.library(
11+
name: "PasswordTextField",
12+
targets: ["PasswordTextField"]),
13+
],
14+
dependencies: [
15+
// Dependencies declare other packages that this package depends on.
16+
// .package(url: /* package url */, from: "1.0.0"),
17+
],
18+
targets: [
19+
// Targets are the basic building blocks of a package. A target can define a module or a test suite.
20+
// Targets can depend on other targets in this package, and on products in packages this package depends on.
21+
.target(
22+
name: "PasswordTextField",
23+
dependencies: [],
24+
path: "PasswordTextField",
25+
exclude: ["BundleUtil.swift", "Info.plist"],
26+
resources: [.process("Media")]),
27+
]
28+
)
29+
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
//
2+
// File.swift
3+
//
4+
//
5+
// Created by Sergey Starukhin on 06.03.2021.
6+
//
7+
8+
import Foundation
9+
10+
/// Get the SPM Bundle
11+
public final class BundleUtil: NSObject{
12+
13+
/// Gets the bundle property for the spm module
14+
public static var bundle: Bundle{
15+
Bundle.module
16+
}
17+
}

PasswordTextField/SecureTextToggleButton.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
//
88

99
import Foundation
10-
10+
import UIKit
1111

1212
/// The Segure text button toggle shown in the right side of the textfield
1313
open class SecureTextToggleButton: UIButton {

0 commit comments

Comments
 (0)