Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Custom inputAccessoryView of SQTextEditorView? #4

Open
Borko4vp opened this issue Oct 20, 2020 · 5 comments
Open

Custom inputAccessoryView of SQTextEditorView? #4

Borko4vp opened this issue Oct 20, 2020 · 5 comments

Comments

@Borko4vp
Copy link

Is there a way to override inputAccessoryView property of SQTextEditorView?
I did manage to accomplish this by subclassing WKWebView and overriding/exposing inputAccessoryView in it, and replacing webView property of the SQTextEditorView with subclass instance.

But still i don't like this approach much since i had to make changes to the pod code? Any better solution?

Thanks.

@RahulFate
Copy link

Is there a way to override inputAccessoryView property of SQTextEditorView?
I did manage to accomplish this by subclassing WKWebView and overriding/exposing inputAccessoryView in it, and replacing webView property of the SQTextEditorView with subclass instance.

But still i don't like this approach much since i had to make changes to the pod code? Any better solution?

Thanks.

Hi @Borko4vp , I would like to implement this in my project. But I am facing same issue. I would like to show all options of editing on keyboard tool bar instead of collection view. Can you please suggest me, how can we achieve this ?

@subashparajuli007
Copy link

Hello @RahulFate did you solve this issue?

@RahulFate
Copy link

@subashparajuli007 not yet.

@RahulFate
Copy link

If you have solution for this then please share

@subashparajuli007
Copy link

Make a custom web view like this:

public class RichEditorWebView: WKWebView { public var accessoryView: UIView? public override var inputAccessoryView: UIView? { // remove/replace the default accessory view return accessoryView } }

subclass the web view in SQEditorTextView like this:
public lazy var webView: RichEditorWebView

finally add accessory view to your SQTextEditorView like this:
editorView.webView.accessoryView = bar

PhilippeWeidmann pushed a commit to Infomaniak/SQRichTextEditor that referenced this issue Nov 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants