From 3db4c85e7d83e09cf62d86c03512484428444bba Mon Sep 17 00:00:00 2001 From: RyosukeCla Date: Tue, 14 Nov 2023 14:40:40 +0900 Subject: [PATCH] update --- ios/Example/Example/ContentView.swift | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/ios/Example/Example/ContentView.swift b/ios/Example/Example/ContentView.swift index f5977d6..d3866ae 100644 --- a/ios/Example/Example/ContentView.swift +++ b/ios/Example/Example/ContentView.swift @@ -125,14 +125,21 @@ Morondava is a charming coastal town located on the western coast of Madagascar. """) ] @EnvironmentObject var nativebrik: NativebrikClient + var body: some View { VStack(alignment: .leading, spacing: 0) { Header() ScrollView(.vertical) { nativebrik .experiment - .embedding("TOP_COMPONENT") - .frame(width: nil, height: 270) + .embedding("TOP_COMPONENT", onEvent: nil) { phase in + switch phase { + case .completed(let view): + view.frame(width: nil, height: 270) + default: + EmptyView().frame(width: nil, height: 0) + } + } ForEach(self.items, id: \.title) { item in item.padding()