diff --git a/Modules/MicX/Mic/src/Mic.K.swift b/Modules/MicX/Mic/src/Mic.K.swift index 28bd311..e3f8441 100644 --- a/Modules/MicX/Mic/src/Mic.K.swift +++ b/Modules/MicX/Mic/src/Mic.K.swift @@ -2,6 +2,6 @@ public extension Mic { enum K { public static let activityDate = "Mic.activityDate" public static let isActive = "Mic.isActive" - public static let itemM = "Mic.Item.Model" + public static let MI = "Mic.Model.Item" } } diff --git a/Modules/MicX/MicItem/src/MicItem.V.swift b/Modules/MicX/MicItem/src/MicItem.V.swift index b9cc4ba..42c7d77 100644 --- a/Modules/MicX/MicItem/src/MicItem.V.swift +++ b/Modules/MicX/MicItem/src/MicItem.V.swift @@ -4,15 +4,14 @@ import SwiftUI extension MicItem { public struct V: View { var id: String? - @StateObject var isActive = BusUI.Value(Mic.K.isActive, false) + @StateObject var isActive = BusUI.Value(K.isActive, false) let ctrl = MicItem.Controller() let processors: [Any] public init(_ id: String? = nil) { self.id = id self.processors = [ - //Bus.Pipe(), - //Bus.Sync(shouldResetActivity, Mic.K.MI, Mic.K.isActive), + //Bus.Sync(shouldResetActivity, K.MI, K.isActive), ] } diff --git a/Modules/MicX/MicItem/src/MicItem.WillBe.swift b/Modules/MicX/MicItem/src/MicItem.WillBe.swift index 0cf85b5..6987451 100644 --- a/Modules/MicX/MicItem/src/MicItem.WillBe.swift +++ b/Modules/MicX/MicItem/src/MicItem.WillBe.swift @@ -16,6 +16,12 @@ extension MicItem { debugClassName: "MicICtrl", debugLog: { print($0) } ) + + + // Нижеследующее предстоит сгенерить. + m + .sink { v in Bus.send(K.MI, v) } + .store(in: &service.subscriptions) } } } diff --git a/Modules/MicX/MicItem/src/MicItem.swift b/Modules/MicX/MicItem/src/MicItem.swift index c7740eb..8dbe2b7 100644 --- a/Modules/MicX/MicItem/src/MicItem.swift +++ b/Modules/MicX/MicItem/src/MicItem.swift @@ -1 +1,3 @@ public enum MicItem { } + +typealias K = Mic.K