[WIP] Business

This commit is contained in:
Isaac
2024-02-13 20:13:40 +04:00
parent 71a40dcdb2
commit d9fec0a500
49 changed files with 5678 additions and 128 deletions

View File

@@ -82,7 +82,7 @@ public final class ComponentHostView<EnvironmentType>: UIView {
self.currentComponent = component
self.currentContainerSize = containerSize
componentState._updated = { [weak self] transition in
componentState._updated = { [weak self] transition, _ in
guard let strongSelf = self else {
return
}
@@ -208,11 +208,11 @@ public final class ComponentView<EnvironmentType> {
self.currentComponent = component
self.currentContainerSize = containerSize
componentState._updated = { [weak self] transition in
componentState._updated = { [weak self] transition, isLocal in
guard let strongSelf = self else {
return
}
if let parentState = strongSelf.parentState {
if !isLocal, let parentState = strongSelf.parentState {
parentState.updated(transition: transition)
} else {
let _ = strongSelf._update(transition: transition, component: component, maybeEnvironment: {