|
|
@@ -13,7 +13,6 @@ import UIKit |
|
|
|
|
|
|
|
public protocol MeetupIdContext { |
|
|
|
var join: Bool { get } |
|
|
|
var textApp: MPAK.Recent<String> { get } |
|
|
|
var textUI: MPAK.Recent<String> { get } |
|
|
|
} |
|
|
|
|
|
|
@@ -36,7 +35,6 @@ extension MeetupId { |
|
|
|
|
|
|
|
public struct Model: MeetupIdContext { |
|
|
|
public var join: Bool = false |
|
|
|
public var textApp: MPAK.Recent<String> = .init("") |
|
|
|
public var textUI: MPAK.Recent<String> = .init("") |
|
|
|
} |
|
|
|
|
|
|
@@ -60,7 +58,6 @@ extension MeetupId { |
|
|
|
|
|
|
|
public struct World { |
|
|
|
let join = PassthroughSubject<Void, Never>() |
|
|
|
let textApp = PassthroughSubject<String, Never>() |
|
|
|
let textUI = PassthroughSubject<String, Never>() |
|
|
|
|
|
|
|
public init( |
|
|
@@ -103,19 +100,6 @@ extension MeetupId { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ctrl.pipeValue( |
|
|
|
dbg: "textA", |
|
|
|
sub: nil, |
|
|
|
Bus.events.compactMap { Bus.convertKeyValue(K.textApp, $0) }.map { (k: String, v: String) in v }.eraseToAnyPublisher(), |
|
|
|
{ |
|
|
|
$0.textApp.value = $1 |
|
|
|
$0.textApp.isRecent = true |
|
|
|
}, |
|
|
|
{ m, _ in m.textApp.isRecent = false } |
|
|
|
) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ctrl.pipeValue( |
|
|
|
dbg: "textUI", |
|
|
|
sub: nil, |
|
|
|