From 12177914d11378fa1252142ccb3146f38fb80335 Mon Sep 17 00:00:00 2001 From: Hidde van der Ploeg Date: Mon, 3 Jul 2023 02:14:43 +0200 Subject: [PATCH] More examples --- .../xcshareddata/swiftpm/Package.resolved | 2 +- Example/BillboardExample/ContentView.swift | 12 ++++++++++-- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/Example/BillboardExample.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved b/Example/BillboardExample.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved index 34e22f2..8912b92 100644 --- a/Example/BillboardExample.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved +++ b/Example/BillboardExample.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved @@ -6,7 +6,7 @@ "location" : "https://github.com/hiddevdploeg/Billboard.git", "state" : { "branch" : "main", - "revision" : "c13a38e1fd54622b5355b6f52c3e1776535868aa" + "revision" : "f03018adc5f92de60a645f6985ef4e4292510a03" } } ], diff --git a/Example/BillboardExample/ContentView.swift b/Example/BillboardExample/ContentView.swift index 577b15b..7b1b320 100644 --- a/Example/BillboardExample/ContentView.swift +++ b/Example/BillboardExample/ContentView.swift @@ -23,9 +23,9 @@ struct ContentView: View { List { if let advert = allAds.randomElement() { Section { - SmallBannerAdView(advert:advert) - .listRowInsets(.none) + SmallBannerAdView(advert: advert) .listRowBackground(Color.clear) + .listRowInsets(.init(top: 0, leading: 0, bottom: 0, trailing: 0)) } } @@ -64,6 +64,14 @@ struct ContentView: View { } .font(.system(.body, design: .rounded, weight: .medium)) } + .safeAreaInset(edge: .bottom, content: { + if let advert = allAds.randomElement() { + SmallBannerAdView(advert: advert) + .padding() + + } + + }) .refreshable { Task { if let allAds = try? await BillboardViewModel.fetchAllAds(from: config.adsJSONURL!) {