Is there a way to intercept these events? We would like to override the default behavior for this. We created a custom post creation fragment, and we want to intercept the edit button so we can take the user to our custom post fragment
Hello Franco,
We currently don’t expose an ability to intercept edit/delete post event directly. However, you’re able to customise post viewholders in our recyclerview by inheriting AmityPostRenderer
→
Once you inherited AmityPostRenderer
, you can specific the post type that you need to customise. For example
override fun getDataType(): String = AmityPost.DataType.TEXT.getApiKey()
or
override fun getDataType(): String = AmityPost.DataType.IMAGE.getApiKey()
Feel free to ask any further questions
Thanks for your response.
But seems like this is a partial solution?
From my understanding, if I create a custom PostRenderer, I’ll have to set the enableHeader to false, to then rewrite the header myself and have a custom edit btn. So far, this could work.
But then, what if a user clicks to see the comments? That takes the user to the Post Detail page, where again there is an edit post button. Is there a workaround there without having to rewrite a everything?
Hello @franco the tech success team will reach out to you with the update