umbraco / Umbraco-CMS

Umbraco is a free and open source .NET content management system helping you deliver delightful digital experiences.
https://umbraco.com
MIT License
4.42k stars 2.67k forks source link

LinkPicker overlay opens too slow from RTE #3311

Closed RomanNalapko closed 5 years ago

RomanNalapko commented 5 years ago

Bug summary

User needs to wait 10-15 seconds to see link picker overlay opened from RTE inserted to custom dialog.

Specifics

Umbraco version: 7.12.3 Affected browsers: Google Chrome (69.0.3497.100), Firefox (62.0.3)

Steps to reproduce

  1. Create custom control which contains RTE inserted via umb-editor (see example below)
  2. Open custom control, add some text into RTE, highlight text in the RTE and click the "insert/edit link" icon.

Control example:

<umb-editor model="model.rte"></umb-editor>

Controller: angular.module("umbraco").controller("CustomControl.EditorDialog.Controller", function ($scope, $timeout, dialogService) { $scope.model = { rte: { label: 'Text', description: 'Alert text', view: 'rte', value: "", config: { editor: { toolbar: [ "codemirror", "undo", "redo", "styleselect", "bold", "numlist", "bullist", "alignleft", "aligncenter", "link", "unlink" ], dimensions: { height: 300 } } } } }; });

Expected result

LinkPicker overlay opened immediately.

Actual result

User needs to wait 10-15 seconds to see link picker.

Interesting behavior: when user clicks the "insert/edit link" icon in RTE and then click "unlink" icon - LinkPicker overlay opened immediately.

dawoe commented 5 years ago

Hi @RomanNalapko

Are you using the dialogService to open the dialog or the umb-overlay directive ?

If it is the first maybe you can have a look at this similar issue for doctype grid editor : https://github.com/umco/umbraco-doc-type-grid-editor/issues/80

Which was fixed in this PR : https://github.com/umco/umbraco-doc-type-grid-editor/pull/86

Dave Community Pull Request team

RomanNalapko commented 5 years ago

Hi @dawoe,

Yes, I'm using dialogService, issue is the same.

dawoe commented 5 years ago

It's advised to use the umb-overlay directive for dialogs.

Dave

nul800sebastiaan commented 5 years ago

As advised by Dave, make sure to use umb-overlay 👍