Skip to content

Commit

Permalink
0.0.40
Browse files Browse the repository at this point in the history
  • Loading branch information
martin-desimone-1 committed Jan 8, 2024
1 parent 4d3e801 commit e327b05
Show file tree
Hide file tree
Showing 44 changed files with 8,635 additions and 6,626 deletions.
8 changes: 4 additions & 4 deletions SampleApp/Viafoura.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -827,7 +827,7 @@
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_ENTITLEMENTS = Viafoura/Viafoura.entitlements;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 81;
CURRENT_PROJECT_VERSION = 94;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
DEVELOPMENT_TEAM = JJ3874BH56;
GENERATE_INFOPLIST_FILE = YES;
Expand All @@ -842,7 +842,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.0.80;
MARKETING_VERSION = 1.0.93;
PRODUCT_BUNDLE_IDENTIFIER = com.viafoura.sampleapp;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_EMIT_LOC_STRINGS = YES;
Expand All @@ -859,7 +859,7 @@
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_ENTITLEMENTS = Viafoura/Viafoura.entitlements;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 81;
CURRENT_PROJECT_VERSION = 94;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
DEVELOPMENT_TEAM = JJ3874BH56;
GENERATE_INFOPLIST_FILE = YES;
Expand All @@ -874,7 +874,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.0.80;
MARKETING_VERSION = 1.0.93;
PRODUCT_BUNDLE_IDENTIFIER = com.viafoura.sampleapp;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_EMIT_LOC_STRINGS = YES;
Expand Down
33 changes: 23 additions & 10 deletions SampleApp/Viafoura/Features/Article/ArticleViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -106,9 +106,15 @@ class ArticleViewController: UIViewController, StoryboardCreateable {
}
}

guard let preCommentsViewController = VFPreviewCommentsViewController.new(containerId: articleViewModel.story.containerId, containerType: articleViewModel.story.storyType == .reviews ? .reviews : .conversations, articleMetadata: articleViewModel.articleMetadata, loginDelegate: self, settings: settings, paginationSize: 10, defaultSort: .newest) else {
return
}
let preCommentsViewController = VFPreviewCommentsViewController.new(
containerId: articleViewModel.story.containerId,
containerType: articleViewModel.story.storyType == .reviews ? .reviews : .conversations,
articleMetadata: articleViewModel.articleMetadata,
loginDelegate: self,
settings: settings,
paginationSize: 10,
defaultSort: articleViewModel.story.storyType == .reviews ? .mostLiked : .newest
)

preCommentsViewController.setTheme(theme: UserDefaults.standard.bool(forKey: SettingsKeys.darkMode) == true ? .dark : .light)
preCommentsViewController.setCustomUIDelegate(customUIDelegate: self)
Expand Down Expand Up @@ -166,10 +172,12 @@ class ArticleViewController: UIViewController, StoryboardCreateable {
}
}

guard let profileViewController = VFProfileViewController.new(userUUID: userUUID, presentationType: presentationType, loginDelegate: self, settings: settings) else{
return
}

let profileViewController = VFProfileViewController.new(
userUUID: userUUID,
presentationType: presentationType,
loginDelegate: self,
settings: settings
)
profileViewController.setTheme(theme: UserDefaults.standard.bool(forKey: SettingsKeys.darkMode) == true ? .dark : .light)
profileViewController.setCustomUIDelegate(customUIDelegate: self)
profileViewController.setActionCallbacks(callbacks: callbacks)
Expand Down Expand Up @@ -203,9 +211,14 @@ class ArticleViewController: UIViewController, StoryboardCreateable {
}
}

guard let newCommentViewController = VFNewCommentViewController.new(newCommentActionType: actionType, containerType: articleViewModel.story.storyType == .reviews ? .reviews : .conversations, containerId: articleViewModel.story.containerId, articleMetadata: articleViewModel.articleMetadata, loginDelegate: self, settings: settings) else{
return
}
let newCommentViewController = VFNewCommentViewController.new(
newCommentActionType: actionType,
containerType: articleViewModel.story.storyType == .reviews ? .reviews : .conversations,
containerId: articleViewModel.story.containerId,
articleMetadata: articleViewModel.articleMetadata,
loginDelegate: self,
settings: settings
)
newCommentViewController.setTheme(theme: UserDefaults.standard.bool(forKey: SettingsKeys.darkMode) == true ? .dark : .light)
newCommentViewController.setCustomUIDelegate(customUIDelegate: self)
newCommentViewController.setActionCallbacks(callbacks: callbacks)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,15 @@ class CommentsContainerViewController: UIViewController, StoryboardCreateable {
}
}

guard let preCommentsViewController = VFPreviewCommentsViewController.new(containerId: viewModel.story.containerId, articleMetadata: viewModel.articleMetadata, loginDelegate: self, settings: settings, paginationSize: 10, defaultSort: .newest) else {
return
}

let preCommentsViewController = VFPreviewCommentsViewController.new(
containerId: viewModel.story.containerId,
articleMetadata: viewModel.articleMetadata,
loginDelegate: self,
settings: settings,
paginationSize: 10,
defaultSort: .newest
)

preCommentsViewController.setTheme(theme: UserDefaults.standard.bool(forKey: SettingsKeys.darkMode) == true ? .dark : .light)
preCommentsViewController.setCustomUIDelegate(customUIDelegate: self)
preCommentsViewController.setActionCallbacks(callbacks: callbacks)
Expand Down Expand Up @@ -97,9 +102,12 @@ class CommentsContainerViewController: UIViewController, StoryboardCreateable {
}
}

guard let profileViewController = VFProfileViewController.new(userUUID: userUUID, presentationType: presentationType, loginDelegate: self, settings: settings) else{
return
}
let profileViewController = VFProfileViewController.new(
userUUID: userUUID,
presentationType: presentationType,
loginDelegate: self,
settings: settings
)

profileViewController.setTheme(theme: UserDefaults.standard.bool(forKey: SettingsKeys.darkMode) == true ? .dark : .light)
profileViewController.setCustomUIDelegate(customUIDelegate: self)
Expand All @@ -119,9 +127,13 @@ class CommentsContainerViewController: UIViewController, StoryboardCreateable {
}
}

guard let newCommentViewController = VFNewCommentViewController.new(newCommentActionType: actionType, containerId: viewModel.story.containerId, articleMetadata: viewModel.articleMetadata, loginDelegate: self, settings: settings) else{
return
}
let newCommentViewController = VFNewCommentViewController.new(
newCommentActionType: actionType,
containerId: viewModel.story.containerId,
articleMetadata: viewModel.articleMetadata,
loginDelegate: self,
settings: settings
)
newCommentViewController.setTheme(theme: UserDefaults.standard.bool(forKey: SettingsKeys.darkMode) == true ? .dark : .light)
newCommentViewController.setCustomUIDelegate(customUIDelegate: self)
newCommentViewController.setActionCallbacks(callbacks: callbacks)
Expand Down
9 changes: 6 additions & 3 deletions SampleApp/Viafoura/Features/Home/HomeViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,12 @@ class HomeViewController: UIViewController, StoryboardCreateable {

let settings = VFSettings(colors: VFColors())
let bellView = VFNotificationBellView(settings: settings, loginDelegate: self, onBellClicked: { userUUID in
guard let vc = VFProfileViewController.new(userUUID: userUUID, presentationType: .profile, loginDelegate: self, settings: settings) else {
return
}
let vc = VFProfileViewController.new(
userUUID: userUUID,
presentationType: .profile,
loginDelegate: self,
settings: settings
)
self.present(vc, animated: true)
})

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,7 @@ class LiveBlogViewController: UIViewController, StoryboardCreateable {
}
}

guard let vc = VFLiveBlogViewController.new(containerId: viewModel.story.containerId, articleMetadata: viewModel.articleMetadata, loginDelegate: self, settings: settings) else {
return
}
let vc = VFLiveBlogViewController.new(containerId: viewModel.story.containerId, articleMetadata: viewModel.articleMetadata, loginDelegate: self, settings: settings)
vc.setTheme(theme: UserDefaults.standard.bool(forKey: SettingsKeys.darkMode) == true ? .dark : .light)
vc.setLayoutDelegate(layoutDelegate: self)
vc.setActionCallbacks(callbacks: callbacks)
Expand Down Expand Up @@ -72,9 +70,12 @@ class LiveBlogViewController: UIViewController, StoryboardCreateable {
}
}

guard let profileViewController = VFProfileViewController.new(userUUID: userUUID, presentationType: presentationType, loginDelegate: self, settings: settings) else{
return
}
let profileViewController = VFProfileViewController.new(
userUUID: userUUID,
presentationType: presentationType,
loginDelegate: self,
settings: settings
)

profileViewController.setTheme(theme: UserDefaults.standard.bool(forKey: SettingsKeys.darkMode) == true ? .dark : .light)
profileViewController.setActionCallbacks(callbacks: callbacks)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,12 @@ class LiveChatPortraitViewController: UIViewController, StoryboardCreateable {
}
}

guard let vc = VFLiveChatViewController.new(containerId: viewModel.containerId, articleMetadata: viewModel.articleMetadata, loginDelegate: self, settings: settings) else {
return
}
let vc = VFLiveChatViewController.new(
containerId: viewModel.containerId,
articleMetadata: viewModel.articleMetadata,
loginDelegate: self,
settings: settings
)

addChild(vc)
containerView.addSubview(vc.view)
Expand All @@ -63,10 +66,12 @@ class LiveChatPortraitViewController: UIViewController, StoryboardCreateable {
func presentProfileViewController(userUUID: UUID, presentationType: VFProfilePresentationType){
let colors = VFColors(colorPrimary: UIColor(red: 0.00, green: 0.45, blue: 0.91, alpha: 1.00), colorPrimaryLight: UIColor(red: 0.90, green: 0.95, blue: 1.00, alpha: 1.00))
let settings = VFSettings(colors: colors)
guard let profileViewController = VFProfileViewController.new(userUUID: userUUID, presentationType: presentationType, loginDelegate: self, settings: settings) else{
return
}

let profileViewController = VFProfileViewController.new(
userUUID: userUUID,
presentationType: presentationType,
loginDelegate: self,
settings: settings
)
profileViewController.setTheme(theme: UserDefaults.standard.bool(forKey: SettingsKeys.darkMode) == true ? .dark : .light)
self.present(profileViewController, animated: true)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,12 @@ class LiveChatPortraitOverlayViewController: UIViewController, StoryboardCreatea
}
}

guard let vc = VFLiveChatViewController.new(containerId: viewModel.containerId, articleMetadata: viewModel.articleMetadata, loginDelegate: self, settings: settings) else {
return
}
let vc = VFLiveChatViewController.new(
containerId: viewModel.containerId,
articleMetadata: viewModel.articleMetadata,
loginDelegate: self,
settings: settings
)

addChild(vc)
containerView.addSubview(vc.view)
Expand All @@ -88,9 +91,12 @@ class LiveChatPortraitOverlayViewController: UIViewController, StoryboardCreatea
func presentProfileViewController(userUUID: UUID, presentationType: VFProfilePresentationType){
let colors = VFColors(colorPrimary: UIColor(red: 0.00, green: 0.45, blue: 0.91, alpha: 1.00), colorPrimaryLight: UIColor(red: 0.90, green: 0.95, blue: 1.00, alpha: 1.00))
let settings = VFSettings(colors: colors)
guard let profileViewController = VFProfileViewController.new(userUUID: userUUID, presentationType: presentationType, loginDelegate: self, settings: settings) else{
return
}
let profileViewController = VFProfileViewController.new(
userUUID: userUUID,
presentationType: presentationType,
loginDelegate: self,
settings: settings
)

profileViewController.setTheme(theme: UserDefaults.standard.bool(forKey: SettingsKeys.darkMode) == true ? .dark : .light)
self.present(profileViewController, animated: true)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,8 @@ class LiveChatsViewController: UIViewController, StoryboardCreateable {
func presentProfileViewController(userUUID: UUID, presentationType: VFProfilePresentationType){
let colors = VFColors(colorPrimary: UIColor(red: 0.00, green: 0.45, blue: 0.91, alpha: 1.00), colorPrimaryLight: UIColor(red: 0.90, green: 0.95, blue: 1.00, alpha: 1.00))
let settings = VFSettings(colors: colors)
guard let profileViewController = VFProfileViewController.new(userUUID: userUUID, presentationType: presentationType, loginDelegate: self, settings: settings) else{
return
}

let profileViewController = VFProfileViewController.new(userUUID: userUUID, presentationType: presentationType, loginDelegate: self, settings: settings)
profileViewController.setTheme(theme: UserDefaults.standard.bool(forKey: SettingsKeys.darkMode) == true ? .dark : .light)
self.present(profileViewController, animated: true)
}
Expand Down Expand Up @@ -77,9 +75,12 @@ extension LiveChatsViewController: UITableViewDelegate{
}

let settings = VFSettings(colors: VFColors())
guard let liveChatVC = VFLiveChatViewController.new(containerId: liveChat.containerId, articleMetadata: articleMetadata, loginDelegate: self, settings: settings) else {
return
}
let liveChatVC = VFLiveChatViewController.new(
containerId: liveChat.containerId,
articleMetadata: articleMetadata,
loginDelegate: self,
settings: settings
)

liveChatVC.setActionCallbacks(callbacks: callbacks)
liveChatVC.setTheme(theme: UserDefaults.standard.bool(forKey: SettingsKeys.darkMode) == true ? .dark : .light)
Expand Down
4 changes: 1 addition & 3 deletions SampleApp/Viafoura/Features/Poll/PollViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,7 @@ class PollViewController: UIViewController, StoryboardCreateable {

func addPollViewController(){
let settings = VFSettings(colors: VFColors())
guard let pollVC = VFPollViewController.new(contentContainerUUID: pollViewModel.poll.contentContainerUUID, loginDelegate: self, settings: settings) else {
return
}
let pollVC = VFPollViewController.new(contentContainerUUID: pollViewModel.poll.contentContainerUUID, loginDelegate: self, settings: settings)

pollVC.setLayoutDelegate(layoutDelegate: self)
pollVC.setTheme(theme: UserDefaults.standard.bool(forKey: SettingsKeys.darkMode) == true ? .dark : .light)
Expand Down
4 changes: 2 additions & 2 deletions SampleApp/Viafoura/Model/Content.swift
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ public enum ContentType {
}

public let defaultContents: [Content] = [
Content(type: .story, story: Story(pictureUrl: "https://www.datocms-assets.com/55856/1636753460-information-overload.jpg?crop=focalpoint&fit=crop&fm=webp&fp-x=0.86&fp-y=0.47&h=428&w=856", title: "Moving Staff to Cover the Coronavirus", description: "Here Are What Media Companies Are Doing to Deal With COVID-19 Information Overload", author: "Norman Phillips", category: "ECONOMY", link: "https://viafoura-mobile-demo.vercel.app/posts/here-are-what-media-companies-are-doing-with-covid-19-overload", containerId: "6cc1ec0f-7e39-5de6-8a3c-9a643ddc103d", authorId: "3147700024522", storyType: .comments), poll: nil),
Content(type: .story, story: Story(pictureUrl: "https://www.datocms-assets.com/55856/1636753460-information-overload.jpg?crop=focalpoint&fit=crop&fm=webp&fp-x=0.86&fp-y=0.47&h=428&w=856", title: "Moving Staff to Cover the Coronavirus", description: "Here Are What Media Companies Are Doing to Deal With COVID-19 Information Overload", author: "Norman Phillips", category: "ECONOMY", link: "https://viafoura-mobile-demo.vercel.app/posts/here-are-what-media-companies-are-doing-with-covid-19-overload", containerId: "1994-7e39-5de6-8a3c-9a643ddc103d", authorId: "3147700024522", storyType: .comments), poll: nil),
Content(type: .poll, story: nil, poll: Poll(contentContainerUUID: UUID(uuidString: "9BC06A89-2B04-402F-8379-D4E21A249B3C")!, title: "Who is the best player ever?")),
Content(type: .story, story: Story(pictureUrl: "https://www.datocms-assets.com/55856/1636663477-blognewheights.jpg?fit=crop&fm=webp&h=428&w=856", title: "Grow civility", description: "Don't shut out your community, instead guide them towards civility", author: "Tom Hardington", category: "ECONOMY", link: "https://viafoura-mobile-demo.vercel.app/posts/dont-shut-out-your-community-guide-them-to-civility", containerId: "101113531", authorId: "3147700024522", storyType: .comments), poll: nil),
Content(type: .story, story: Story(pictureUrl: "https://www.datocms-assets.com/55856/1636663477-blognewheights.jpg?fit=crop&fm=webp&h=428&w=856", title: "Grow civility", description: "Don't shut out your community, instead guide them towards civility", author: "Tom Hardington", category: "ECONOMY", link: "https://viafoura-mobile-demo.vercel.app/posts/dont-shut-out-your-community-guide-them-to-civility", containerId: "231414", authorId: "3147700024522", storyType: .comments), poll: nil),
Content(type: .story, story: Story(pictureUrl: "https://www.datocms-assets.com/67251/1701970811-tacos.jpg?fit=crop&fm=webp&h=428&w=856", title: "Korean Fusion Delight", description: "Homemade Bulgogi Tacos Recipe", author: "Tom Hardington", category: "COOKING", link: "https://viafoura-mobile-demo.vercel.app/posts/brexit-to-cost-gbp1-200-for-each-person-in-uk", containerId: "a0335064233e55d-4442-aa6b-7fdcfe54636b", authorId: "3147700024522", storyType: .reviews), poll: nil)
]
2 changes: 1 addition & 1 deletion ViafouraCore.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

Pod::Spec.new do |s|
s.name = 'ViafouraCore'
s.version = '0.0.39'
s.version = '0.0.40'
s.swift_versions = ['5.0']
s.summary = 'Viafoura SDK'
s.description = 'This SDK allows you to integrate Viafoura tools into your iOS app.'
Expand Down
10 changes: 5 additions & 5 deletions ViafouraSDK.xcframework/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -8,32 +8,32 @@
<key>BinaryPath</key>
<string>ViafouraSDK.framework/ViafouraSDK</string>
<key>LibraryIdentifier</key>
<string>ios-arm64_x86_64-simulator</string>
<string>ios-arm64</string>
<key>LibraryPath</key>
<string>ViafouraSDK.framework</string>
<key>SupportedArchitectures</key>
<array>
<string>arm64</string>
<string>x86_64</string>
</array>
<key>SupportedPlatform</key>
<string>ios</string>
<key>SupportedPlatformVariant</key>
<string>simulator</string>
</dict>
<dict>
<key>BinaryPath</key>
<string>ViafouraSDK.framework/ViafouraSDK</string>
<key>LibraryIdentifier</key>
<string>ios-arm64</string>
<string>ios-arm64_x86_64-simulator</string>
<key>LibraryPath</key>
<string>ViafouraSDK.framework</string>
<key>SupportedArchitectures</key>
<array>
<string>arm64</string>
<string>x86_64</string>
</array>
<key>SupportedPlatform</key>
<string>ios</string>
<key>SupportedPlatformVariant</key>
<string>simulator</string>
</dict>
</array>
<key>CFBundlePackageType</key>
Expand Down
Binary file not shown.
Loading

0 comments on commit e327b05

Please sign in to comment.