Custom UI
Customize the UI components in your app
The VFCustomUIDelegate allows you to customize the UI components, by giving you direct references to them.
guard let preCommentsViewController = VFPreviewCommentsViewController.new(
containerId: containerId,
articleMetadata: articleMetadata,
loginDelegate: self, settings: settings) else {
return
}
preCommentsViewController.setCustomUIDelegate(customUIDelegate: self)
guard let newCommentViewController = VFNewCommentViewController.new(newCommentActionType: actionType, containerId: containerId, articleMetadata: articleMetadata, loginDelegate: self, settings: settings) else {
return
}
newCommentViewController.setCustomUIDelegate(customUIDelegate: self)
guard let profileViewController = VFProfileViewController.new(userUUID: userUUID, presentationType: presentationType, loginDelegate: self, settings: settings) else {
return
}
profileViewController.setCustomUIDelegate(customUIDelegate: self)
Implement the VFCustomUIDelegate.
extension ArticleViewController: VFCustomUIDelegate {
func customizeView(view: VFCustomizableView) {
switch view {
case .postButton(let button):
break
default:
break
}
}
}
Customizable views
Component | View name |
---|---|
Post button |
|
Post text view |
|
Post close image |
|
Post title |
|
Post placeholder label |
|
Post loading indicator (only shown on replies) |
|
Profile name label |
|
Profile logout label |
|
Profile close image |
|
Profile likes label |
|
Profile followers label |
|
Profile segmented control |
|
Comment cell date label |
|
Comment cell name label |
|
Comment cell content label |
|
Comment cell like image |
|
Comment cell like label |
|
Comment cell dislike image |
|
Comment cell dislike label |
|
Comment cell reply label |
|
Comment cell replies label |
|
Preview comments empty view |
|
Preview comments see more comments button |
|
Preview comments title label |
|
Preview comments counter label |
|
Preview comments loading view |
|
Preview comments privacy label |
|
Preview comments viafoura logo |
|
Trending vertical full image |
|
Trending vertical full title label |
|
Trending vertical full count label |
|
Trending vertical condensed title label |
|
Trending vertical condensed count label |
|
Trending carousel title |
|
Trending carousel image |
|
Trending carousel comment count |
|
Chat cell content label |
|
Chat cell date label |
|
Chat cell user name label |
|
Updated 18 days ago