Skip to content

Commit 30b40b3

Browse files
committed
Removed customisable provider and cell.
1 parent 3aa0c4e commit 30b40b3

File tree

6 files changed

+2
-143
lines changed

6 files changed

+2
-143
lines changed

SPDiffable.podspec

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Pod::Spec.new do |s|
22

33
s.name = 'SPDiffable'
4-
s.version = '2.1.0'
4+
s.version = '2.1.1'
55
s.summary = 'Extension of Diffable API which allow not duplicate code and use less models. Included example for SideBar.'
66
s.homepage = 'https://github.com/ivanvorobei/SPDiffable'
77
s.source = { :git => 'https://github.com/ivanvorobei/SPDiffable.git', :tag => s.version }

Sources/SPDiffable/Table/Cells/SPDiffableCustomTableViewCell.swift

-72
This file was deleted.

Sources/SPDiffable/Table/Models/SPDiffableCustomTableRow.swift

-53
This file was deleted.

Sources/SPDiffable/Table/SPDiffableTableCellProvider.swift

+1-16
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ open class SPDiffableTableCellProvider {
3737

3838
public static var `default`: SPDiffableTableCellProvider {
3939
return SPDiffableTableCellProvider() { (tableView, indexPath, item) -> UITableViewCell? in
40-
let providers = [rowDetail, rowSubtitle, `switch`, stepper, customisable]
40+
let providers = [rowDetail, rowSubtitle, `switch`, stepper]
4141
for provider in providers {
4242
if let cell = provider.clouser(tableView, indexPath, item) {
4343
return cell
@@ -103,19 +103,4 @@ open class SPDiffableTableCellProvider {
103103
return cell
104104
}
105105
}
106-
107-
public static var customisable: SPDiffableTableCellProvider {
108-
return SPDiffableTableCellProvider() { (tableView, indexPath, item) -> UITableViewCell? in
109-
guard let item = item as? SPDiffableCustomTableRow else { return nil }
110-
let cell = tableView.dequeueReusableCell(withIdentifier: SPDiffableCustomTableViewCell.reuseIdentifier, for: indexPath) as! SPDiffableCustomTableViewCell
111-
cell.textLabel?.text = item.text
112-
cell.textLabel?.textColor = item.textColor
113-
cell.textLabel?.font = item.textFont
114-
cell.detailTextLabel?.text = item.detail
115-
cell.imageView?.image = item.icon
116-
cell.accessoryType = item.accessoryType
117-
cell.higlightStyle = item.higlightStyle
118-
return cell
119-
}
120-
}
121106
}

Sources/SPDiffable/Table/SPDiffableTableController.swift

-1
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,6 @@ open class SPDiffableTableController: UITableViewController {
4343

4444
tableView.register(SPDiffableTableViewCell.self, forCellReuseIdentifier: SPDiffableTableViewCell.reuseIdentifier)
4545
tableView.register(SPDiffableSubtitleTableViewCell.self, forCellReuseIdentifier: SPDiffableSubtitleTableViewCell.reuseIdentifier)
46-
tableView.register(SPDiffableCustomTableViewCell.self, forCellReuseIdentifier: SPDiffableCustomTableViewCell.reuseIdentifier)
4746
}
4847

4948
// MARK: - Init

0 commit comments

Comments
 (0)