[TASK] Reduce inline JavaScript in Page Module Paste logic
When having a content element on the clipboard (normal mode) the page module dynamically shows paste icons everywhere. This change centralizes the generation of the Paste icons into JavaScript, so the inline javascript usage of "top.*" functionality to park code somewhere has been removed, and the actual items are generated in JavaScript. In addition, as this code is only affecting the page module when a tt_content element is on the clipboard, the Paste.js JS module is only loaded when appropriate, thus reducing the actual loading time for "regular" visits on the Page Module. The icon in the paste button is now loaded via a native web component, and only necessary logic is used in the Paste JS module. The outer rendering for the Page Module has been simplified, moving this functionality all into PageLayoutController, reducing cross-dependencies between the PageLayout* classes. Resolves: #94840 Releases: master Change-Id: I380df9a56bfff74684616732166f25c68bbc6dec Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/70488 Tested-by:core-ci <typo3@b13.com> Tested-by:
Jochen <rothjochen@gmail.com> Tested-by:
Oliver Bartsch <bo@cedev.de> Tested-by:
Benni Mack <benni@typo3.org> Reviewed-by:
Wouter Wolters <typo3@wouterwolters.nl> Reviewed-by:
Jochen <rothjochen@gmail.com> Reviewed-by:
Oliver Bartsch <bo@cedev.de> Reviewed-by:
Benni Mack <benni@typo3.org>
Showing
- Build/Sources/TypeScript/backend/Resources/Public/TypeScript/LayoutModule/Paste.ts 51 additions, 32 deletions...backend/Resources/Public/TypeScript/LayoutModule/Paste.ts
- typo3/sysext/backend/Classes/Controller/PageLayoutController.php 29 additions, 4 deletions...ysext/backend/Classes/Controller/PageLayoutController.php
- typo3/sysext/backend/Classes/View/Drawing/BackendLayoutRenderer.php 4 additions, 111 deletions...xt/backend/Classes/View/Drawing/BackendLayoutRenderer.php
- typo3/sysext/backend/Classes/View/PageLayoutContext.php 0 additions, 12 deletionstypo3/sysext/backend/Classes/View/PageLayoutContext.php
- typo3/sysext/backend/Classes/View/PageLayoutView.php 0 additions, 78 deletionstypo3/sysext/backend/Classes/View/PageLayoutView.php
- typo3/sysext/backend/Resources/Public/JavaScript/LayoutModule/Paste.js 1 addition, 1 deletion...backend/Resources/Public/JavaScript/LayoutModule/Paste.js
Please register or sign in to comment