angular-editor icon indicating copy to clipboard operation
angular-editor copied to clipboard

feat: add shadow dom support, fixes #321

Open enkeli opened this issue 3 years ago • 2 comments
trafficstars

When using angular-editor under a shadow dom encapsulated component, it was throwing errors as it tried to find some elements by their id's using the global document api: angular_editor_error

This pull request tries to solve it by changing the way we access those elements using Angular's ElementRef instead of document. It also adds a new page on the angular-editor-app project to showcase the use of angular-editor under a shadow dom encapsulated component.

Test are passing: angular_editor_tests

enkeli avatar Aug 01 '22 06:08 enkeli

Codecov Report

Merging #479 (c2cfe4b) into master (40431f4) will increase coverage by 0.24%. The diff coverage is 50.00%.

@@            Coverage Diff             @@
##           master     #479      +/-   ##
==========================================
+ Coverage   20.66%   20.91%   +0.24%     
==========================================
  Files           8        8              
  Lines         479      483       +4     
  Branches      103      103              
==========================================
+ Hits           99      101       +2     
- Misses        377      379       +2     
  Partials        3        3              
Impacted Files Coverage Δ
...editor/src/lib/angular-editor-toolbar.component.ts 18.25% <42.85%> (+0.51%) :arrow_up:
...angular-editor/src/lib/angular-editor.component.ts 17.44% <60.00%> (+0.38%) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 40431f4...c2cfe4b. Read the comment docs.

codecov[bot] avatar Aug 01 '22 06:08 codecov[bot]

The same issue is happening to me. Does anyone have a solution?

MeAkib avatar Oct 14 '22 11:10 MeAkib