From 2a05c32c3b54c9103cf11b0cdc6bb360573e73a0 Mon Sep 17 00:00:00 2001 From: Andreas Fernandez <a.fernandez@scripting-base.de> Date: Thu, 30 Mar 2023 10:23:00 +0200 Subject: [PATCH] [BUGFIX] Drop obsolete `table-wizard` module The FormEngine JavaScript module `table-wizard` became obsolete with ticket #95036 and was forgotten to be removed, which is now done. Resolves: #100356 Related: #95036 Releases: main, 11.5 Change-Id: I2f517a29ec5298efb4ddc7149f903b9837338037 Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/78329 Tested-by: Andreas Fernandez <a.fernandez@scripting-base.de> Reviewed-by: Andreas Fernandez <a.fernandez@scripting-base.de> Tested-by: core-ci <typo3@b13.com> --- .../FormEngine/FieldControl/TableWizard.ts | 40 ------------------- .../FormEngine/FieldControl/TableWizard.js | 13 ------ 2 files changed, 53 deletions(-) delete mode 100644 Build/Sources/TypeScript/backend/Resources/Public/TypeScript/FormEngine/FieldControl/TableWizard.ts delete mode 100644 typo3/sysext/backend/Resources/Public/JavaScript/FormEngine/FieldControl/TableWizard.js diff --git a/Build/Sources/TypeScript/backend/Resources/Public/TypeScript/FormEngine/FieldControl/TableWizard.ts b/Build/Sources/TypeScript/backend/Resources/Public/TypeScript/FormEngine/FieldControl/TableWizard.ts deleted file mode 100644 index 121736b6e042..000000000000 --- a/Build/Sources/TypeScript/backend/Resources/Public/TypeScript/FormEngine/FieldControl/TableWizard.ts +++ /dev/null @@ -1,40 +0,0 @@ -/* - * This file is part of the TYPO3 CMS project. - * - * It is free software; you can redistribute it and/or modify it under - * the terms of the GNU General Public License, either version 2 - * of the License, or any later version. - * - * For the full copyright and license information, please read the - * LICENSE.txt file that was distributed with this source code. - * - * The TYPO3 project - inspiring people to share! - */ - -import DocumentService = require('TYPO3/CMS/Core/DocumentService'); -import FormEngine = require('TYPO3/CMS/Backend/FormEngine'); - -/** - * Handles the "Table wizard" field control - */ -class TableWizard { - private controlElement: HTMLElement = null; - - constructor(controlElementId: string) { - DocumentService.ready().then((): void => { - this.controlElement = <HTMLElement>document.querySelector(controlElementId); - this.controlElement.addEventListener('click', this.registerClickHandler); - }); - } - - /** - * @param {Event} e - */ - private registerClickHandler = (e: Event): void => { - e.preventDefault(); - - FormEngine.preventFollowLinkIfNotSaved(this.controlElement.getAttribute('href')); - } -} - -export = TableWizard; diff --git a/typo3/sysext/backend/Resources/Public/JavaScript/FormEngine/FieldControl/TableWizard.js b/typo3/sysext/backend/Resources/Public/JavaScript/FormEngine/FieldControl/TableWizard.js deleted file mode 100644 index e94903b08a33..000000000000 --- a/typo3/sysext/backend/Resources/Public/JavaScript/FormEngine/FieldControl/TableWizard.js +++ /dev/null @@ -1,13 +0,0 @@ -/* - * This file is part of the TYPO3 CMS project. - * - * It is free software; you can redistribute it and/or modify it under - * the terms of the GNU General Public License, either version 2 - * of the License, or any later version. - * - * For the full copyright and license information, please read the - * LICENSE.txt file that was distributed with this source code. - * - * The TYPO3 project - inspiring people to share! - */ -define(["require","exports","TYPO3/CMS/Core/DocumentService","TYPO3/CMS/Backend/FormEngine"],(function(e,t,r,n){"use strict";return class{constructor(e){this.controlElement=null,this.registerClickHandler=e=>{e.preventDefault(),n.preventFollowLinkIfNotSaved(this.controlElement.getAttribute("href"))},r.ready().then(()=>{this.controlElement=document.querySelector(e),this.controlElement.addEventListener("click",this.registerClickHandler)})}}})); \ No newline at end of file -- GitLab