'html editor enhanced alert dialog not working when the dialog placed on editor

Dependency : html_editor_enhanced: ^2.4.0+1

HtmlEditor(
                 controller: controller,
                 htmlEditorOptions: HtmlEditorOptions(
                          darkMode: true,
                          initialText: _phase!.value,
                          hint: "Enter you information",
                          autoAdjustHeight: false,
                          shouldEnsureVisible: true,
                          webInitialScripts:
                          UnmodifiableListView([
                                        WebScript(
                                             name: "editorBG",
                                             script:"document.getElementsByClassName('note-editable')[0].style.backgroundColor='blue';"),
                                                      WebScript(
                                                          name: "height",
                                                          script: """
                                                          var height = document.body.scrollHeight;
                                                          window.parent.postMessage(JSON.stringify({"type": "toDart: height", "height": height}), "*"); //,"color":'white'
                                                          """),
                                                    ]
                                                  )
                                                ),
                                                htmlToolbarOptions:
                                                const HtmlToolbarOptions(
                                                  // toolbarItemHeight: 90.0,
                                                    // gridViewHorizontalSpacing: 0.1,
                                                    // gridViewVerticalSpacing: 0.1,
                                                    toolbarPosition: ToolbarPosition.aboveEditor,
                                                    toolbarType: ToolbarType.nativeGrid
                                                  ),
                                                    otherOptions: OtherOptions(
                                                    decoration: BoxDecoration(
                                                    color: Colors.white,
                                                    borderRadius:
                                                    BorderRadius.circular(10.0),
                                                    border: Border.all(
                                                        color: const Color.fromRGBO(244, 248, 248, 1),
                                                        width: 2),
                   ),
                  ),
                );

If I click alert dialog(image choose) cancel or ok button, then click goes to editor only which is placed under dialog box. please confirm what other dependency is compatible for this... also this is flutter inbuild widget which they already wrap it with PointerInterceptor... but still it is not working



Solution 1:[1]

I've been having a similar issue, but I found this https://github.com/flutter/flutter/issues/54027#issuecomment-797757996

Try running your flutter app with "--web-renderer html".

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 richardcode