Review main Merged Breaking

59324[!!!][TASK] Refactor client-side IRRE

Andreas Kienast CR +2 V +2 Nightmare +1801 −1663 updated 07/22/20, 14:36

Commit message

This patch refactors the IRRE handling on client side, the JavaScript
land has been rewritten to have a better structure and do less repeating
on-the-fly calculations. Each IRRE container is represented by a
independent instance of InlineControlContainer.

Most of the internally used `scriptCall` directives have been removed.
Currently, `scriptCall` can't get removed completely, as further
refactorings in different areas are required.

All of the "external" communication via `inline.foobar()` has been
replaced by a event-driven approach. This also affects ElementBrowser
windows, those use a minimalistic API based on postMessage.

Some code that was never evaluated in ElementBrowser is considered dead
and has been removed regarding inserting multiple items.

A new sorting library has been added in order to replace jqueryui piece
by piece.

Executed command:

    yarn add --dev sortablejs

On PHP side, some code has been removed as well since the rewritten client
code is event-based and doesn't depend on external calls anymore.

Review

  • Code review CR +2 Done
    • Frank Nägler +2
    • Georg Ringer +1
  • Verified V +2 Done
    • Frank Nägler +2
    • Georg Ringer +1
    • TYPO3com +1 CI

Issues 1

Files 44

Show 24 more files

Review log 63104

Show 4379 earlier messages
  1. Andreas Kienast uploaded patch set 1 01/03/19, 21:10

  2. TYPO3com voted on patch set 1 V +1 01/03/19, 21:21 Completed build in 10m 41s on Thu, 3 Jan, 10:21 PM Test Summary: 47833 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-31196

  3. Andreas Kienast uploaded patch set 2 01/04/19, 09:11

  4. TYPO3com voted on patch set 2 V +1 01/04/19, 09:21 Completed build in 10m 35s on Fri, 4 Jan, 10:21 AM Test Summary: 47833 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-31198

  5. Andreas Kienast uploaded patch set 3 01/04/19, 12:31

  6. TYPO3com voted on patch set 3 V -1 01/04/19, 12:41 Completed build in 09m 58s on Fri, 4 Jan, 01:41 PM Test Summary: 3 of 48244 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-31199

  7. Andreas Kienast uploaded patch set 4 01/09/19, 18:41

  8. TYPO3com voted on patch set 4 V -1 01/09/19, 18:52 Completed build in 11m 12s on Wed, 9 Jan, 07:52 PM Test Summary: 2 of 25789 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-31382

  9. Andreas Kienast uploaded patch set 5 01/23/19, 15:53

  10. TYPO3com voted on patch set 5 V -1 01/23/19, 16:05 Completed build in 11m 28s on Wed, 23 Jan, 05:05 PM Test Summary: 4 of 47303 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-31736

  11. Andreas Kienast uploaded patch set 6 01/23/19, 21:24

  12. TYPO3com voted on patch set 6 V -1 01/23/19, 21:35 Completed build in 11m 26s on Wed, 23 Jan, 10:35 PM Test Summary: 4 of 47303 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-31740

  13. Andreas Kienast uploaded patch set 7 01/27/19, 10:40

  14. TYPO3com voted on patch set 7 V -1 01/27/19, 10:51 Completed build in 11m 04s on Sun, 27 Jan, 11:51 AM Test Summary: 4 of 47303 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-31769

  15. Andreas Kienast uploaded patch set 8 01/27/19, 17:19

  16. Andreas Kienast uploaded patch set 9 01/27/19, 17:27

  17. TYPO3com voted on patch set 8 V -1 01/27/19, 17:31 Completed build in 11m 52s on Sun, 27 Jan, 06:31 PM Test Summary: 6 of 47303 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-31770

  18. TYPO3com voted on patch set 9 V -1 01/27/19, 17:39 Completed build in 11m 37s on Sun, 27 Jan, 06:39 PM Test Summary: 6 of 47303 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-31771

  19. Andreas Kienast uploaded patch set 10 01/29/19, 12:57

  20. TYPO3com voted on patch set 10 V -1 01/29/19, 13:09 Completed build in 11m 56s on Tue, 29 Jan, 02:09 PM Test Summary: 5 of 47291 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-31813

  21. Andreas Kienast uploaded patch set 11 01/29/19, 14:06

  22. TYPO3com voted on patch set 11 V -1 01/29/19, 14:16 Completed build in 09m 53s on Tue, 29 Jan, 03:16 PM Test Summary: 5 of 47291 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-31814

  23. Andreas Kienast uploaded patch set 12 01/29/19, 16:57

  24. TYPO3com voted on patch set 12 V -1 01/29/19, 17:07 Completed build in 09m 56s on Tue, 29 Jan, 06:07 PM Test Summary: 3 of 47291 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-31817

  25. Andreas Kienast uploaded patch set 13 01/30/19, 13:57

  26. TYPO3com voted on patch set 13 V -1 01/30/19, 14:07 Completed build in 10m 13s on Wed, 30 Jan, 03:07 PM Test Summary: 3 of 47291 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-31833

  27. Andreas Kienast uploaded patch set 14 01/30/19, 14:59

  28. TYPO3com voted on patch set 14 V -1 01/30/19, 15:08 Completed build in 09m 20s on Wed, 30 Jan, 04:08 PM Test Summary: 3 of 47291 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-31836

  29. Benni Mack commented on patch set 13 01/30/19, 16:00

    InlineControlContainer.php:289

    hsc everything please

    FormResultCompiler.php:270

    remove the lines, don't comment them out.
  30. Andreas Kienast commented on patch set 14 01/30/19, 16:13

    FormResultCompiler.php:270 Reply

    Will do when I'm done, I have to re-check the PHP classes anyway (now unused variables, etc.).
  31. Andreas Kienast uploaded patch set 15 01/30/19, 17:18

  32. TYPO3com voted on patch set 15 V -1 01/30/19, 17:29 Completed build in 10m 35s on Wed, 30 Jan, 06:29 PM Test Summary: 3 of 47291 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-31847

  33. Andreas Kienast uploaded patch set 16 02/02/19, 20:31

  34. TYPO3com voted on patch set 16 V -1 02/02/19, 20:42 Completed build in 10m 43s on Sat, 2 Feb, 09:42 PM Test Summary: 2 of 46798 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-31992

  35. Andreas Kienast uploaded patch set 17 02/02/19, 22:38

  36. TYPO3com voted on patch set 17 V -1 02/02/19, 22:48 Completed build in 09m 55s on Sat, 2 Feb, 11:48 PM Test Summary: 4 of 46798 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-31994

  37. Andreas Kienast uploaded patch set 18 03/09/19, 13:52

  38. TYPO3com voted on patch set 18 V -1 03/09/19, 14:20 Completed build in 19m 49s on Sat, 9 Mar, 03:20 PM Test Summary: 4 of 47593 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-32633

  39. Benni Mack commented on patch set 18 03/13/19, 06:26

    FormInlineAjaxController.php:397

    we could move that to line 391 or 390 completely right?

    InlineRecordContainer.php:545

    seriously? "enabledisable-button" ;)

    ObjectUtility.ts:24

    jsfunc.inline.js:48

    get rid of it :)
  40. Oliver Hader commented on patch set 18 03/13/19, 08:08

    ObjectUtility.ts:24 Reply Unresolved

    Object.size is a custom implementation which I would not bind to the native Object implementation. In general that depends on what are the input values. For arrays `array.length` is enough and for simple objects (no inheritance, no class instance) `Object.keys(object).length` is enough as well... Thus, I'd rather drop this ObjectUtility and either use one of them when needed

    Utility.ts:26

    `"a, b ,, c, d".split(',').map((item) => item.trim()).filter((item) => item !== '')`

    Utility.ts:46 Unresolved

    `"1, 2 ,000, c, 4".split(',').map((item) => parseInt(item, 10)).filter((item) => !isNaN(item) || excludeZeroValues && item === 0) `
  41. Andreas Kienast commented on patch set 18 03/13/19, 08:24

    FormInlineAjaxController.php:397 Reply Unresolved

    True

    InlineRecordContainer.php:545 Reply Unresolved

    Naming things... Is "toggle-visibility-button" better?

    Utility.ts:26 Reply Unresolved

    Wow, I definitely have to learn that arrow syntax and paint it on my skin.

    jsfunc.inline.js:48 Reply Unresolved

    I will drop that code when everything is migrated. Until then, I will keep this as some kind of a cheat sheet in case stuff behaves differently than before :)
  42. Andreas Kienast uploaded patch set 19 03/15/19, 13:20

  43. Andreas Kienast uploaded patch set 20 03/15/19, 13:23

  44. TYPO3com voted on patch set 19 V -1 03/15/19, 13:38 Completed build in 17m 36s on Fri, 15 Mar, 02:38 PM Test Summary: 4 of 47593 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-32753

  45. TYPO3com voted on patch set 20 V -1 03/15/19, 13:40 Completed build in 17m 47s on Fri, 15 Mar, 02:41 PM Test Summary: 4 of 47593 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-32754

  46. Andreas Kienast uploaded patch set 21 03/15/19, 14:57

  47. TYPO3com voted on patch set 21 V -1 03/15/19, 15:12 Completed build in 14m 26s on Fri, 15 Mar, 04:12 PM Test Summary: 4 of 47593 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-32761

  48. Andreas Kienast uploaded patch set 22 03/15/19, 16:18

  49. TYPO3com voted on patch set 22 V -1 03/15/19, 16:33 Completed build in 15m 04s on Fri, 15 Mar, 05:33 PM Test Summary: 1 of 47608 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-32770

  50. Andreas Kienast uploaded patch set 23 03/17/19, 07:51

  51. TYPO3com voted on patch set 23 V +1 03/17/19, 08:05 Completed build in 14m 22s on Sun, 17 Mar, 09:06 AM Test Summary: 47201 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-32814

  52. Andreas Kienast uploaded patch set 24 03/17/19, 21:37

  53. TYPO3com voted on patch set 24 V +1 03/17/19, 21:49 Completed build in 12m 09s on Sun, 17 Mar, 10:49 PM Test Summary: 47201 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-32831

  54. Oliver Hader rebased onto patch set 25 03/20/19, 12:48

  55. TYPO3com voted on patch set 25 V +1 03/20/19, 13:02 Completed build in 13m 55s on Wed, 20 Mar, 02:02 PM Test Summary: 47201 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-32864

  56. Andreas Kienast uploaded patch set 26 04/06/19, 06:16

  57. TYPO3com voted on patch set 26 V +1 04/06/19, 06:33 Completed build in 17m 26s on Sat, 6 Apr, 08:33 AM Test Summary: 47267 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-33089

  58. Andreas Kienast uploaded patch set 27 04/07/19, 18:53

  59. TYPO3com voted on patch set 27 V +1 04/07/19, 19:03 Completed build in 09m 53s on Sun, 7 Apr, 09:03 PM Test Summary: 47267 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-33102

  60. Andreas Kienast uploaded patch set 28 04/08/19, 07:28

  61. TYPO3com voted on patch set 28 V +1 04/08/19, 07:38 Completed build in 10m 02s on Mon, 8 Apr, 09:38 AM Test Summary: 47267 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-33103

  62. Andreas Kienast uploaded patch set 29 04/13/19, 14:05

  63. TYPO3com voted on patch set 29 V +1 04/13/19, 14:18 Completed build in 12m 06s on Sat, 13 Apr, 04:18 PM Test Summary: 47343 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-33237

  64. Andreas Kienast uploaded patch set 30 04/13/19, 15:53

  65. TYPO3com voted on patch set 30 V +1 04/13/19, 16:06 Completed build in 13m 18s on Sat, 13 Apr, 06:06 PM Test Summary: 47343 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-33238

  66. Andreas Kienast uploaded patch set 31 04/13/19, 16:44

  67. TYPO3com voted on patch set 31 V +1 04/13/19, 16:55 Completed build in 10m 32s on Sat, 13 Apr, 06:55 PM Test Summary: 47343 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-33239

  68. Andreas Kienast uploaded patch set 32 04/13/19, 17:36

  69. TYPO3com voted on patch set 32 V -1 04/13/19, 17:47 Completed build in 10m 17s on Sat, 13 Apr, 07:47 PM Test Summary: 2 of 47736 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-33240

  70. Andreas Kienast uploaded patch set 33 04/13/19, 19:20

  71. TYPO3com voted on patch set 33 V +1 04/13/19, 19:33 Completed build in 13m 21s on Sat, 13 Apr, 09:33 PM Test Summary: 47343 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-33243

  72. Andreas Kienast uploaded patch set 34 04/22/19, 14:39

  73. TYPO3com voted on patch set 34 V +1 04/22/19, 14:49 Completed build in 09m 28s on Mon, 22 Apr, 04:49 PM Test Summary: 47469 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-33370

  74. Andreas Kienast uploaded patch set 35 04/22/19, 15:15

  75. TYPO3com voted on patch set 35 V +1 04/22/19, 15:26 Completed build in 11m 26s on Mon, 22 Apr, 05:26 PM Test Summary: 47469 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-33372

  76. Björn Jacob commented on patch set 35 04/23/19, 06:22

    ElementBrowser.ts:69

    Don't need this, right? ;)
  77. Andreas Kienast commented on patch set 35 04/23/19, 07:10

    ElementBrowser.ts:69 Reply Unresolved

    It's still WIP, see the open TODOs ;)
  78. Andreas Kienast uploaded patch set 36 04/27/19, 13:33

  79. TYPO3com voted on patch set 36 V +1 04/27/19, 13:50 Completed build in 13m 49s on Sat, 27 Apr, 03:50 PM Test Summary: 47488 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-33545

  1. Andreas Kienast uploaded patch set 37 04/27/19, 14:11

  2. TYPO3com voted on patch set 37 V +1 04/27/19, 14:36 Completed build in 24m 07s on Sat, 27 Apr, 04:36 PM Test Summary: 47488 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-33549

  3. Benni Mack commented on patch set 37 04/29/19, 07:14

    Great stuff. Can you please point me to the additional third-party lib you've added? I need to check license, compat, maintenability. On top: Could you provide the commands you executed in the commit message to add this library?
  4. Andreas Kienast commented on patch set 37 04/29/19, 15:52

    > Patch Set 37: > > Great stuff. > > Can you please point me to the additional third-party lib you've added? I need to check license, compat, maintenability. Library is https://github.com/SortableJS/Sortable using MIT licence. > On top: Could you provide the commands you executed in the commit message to add this library? Yes, will push another patch set now since the library got a new release meanwhile.
  5. Andreas Kienast uploaded patch set 38 04/29/19, 15:54

  6. TYPO3com voted on patch set 38 V +1 04/29/19, 16:08 Completed build in 13m 31s on Mon, 29 Apr, 06:08 PM Test Summary: 47468 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-33652

  7. Markus Klein commented on patch set 38 05/12/19, 07:54

    was

    AjaxDispatcher.ts:61

    they
  8. Markus Klein commented on patch set 38 05/12/19, 08:58

    AjaxRequest.ts:44

    string[] ?

    AbstractFormEngineAjaxController.php:56

    I would switch those two lines and go with $callback = reset($module); $moduleName = key($module); Makes sure that we really take the first entry

    FormInlineAjaxController.php:139

    is this still needed?

    InlineControlContainer.php:367

    this somehow still hurts a bit ;-)

    FormResultCompiler.php:267

    Where is this loading call removed?
  9. Andreas Kienast commented on patch set 38 05/12/19, 09:17

    AjaxRequest.ts:44 Reply

    That's IIRC no valid TypeScript syntax.

    AbstractFormEngineAjaxController.php:56 Reply

    Ack

    FormInlineAjaxController.php:139 Reply Unresolved

    Yes, there are some calls left that can't get removed right now (e.g custom eval functions)

    InlineControlContainer.php:367 Reply Unresolved

    Well yeah. We can come up with a better solution once we've split and migrated everything.

    FormResultCompiler.php:267 Reply

    Huh? See the two lines below.
  10. Andreas Kienast commented on patch set 38 05/12/19, 17:39

    Reply

    Done

    AjaxDispatcher.ts:61 Reply

    Done

    AjaxRequest.ts:44 Reply

    Would work, but I wouldn't change that for now to avoid mixes

    AbstractFormEngineAjaxController.php:56 Reply

    Done
  11. Andreas Kienast uploaded patch set 39 05/12/19, 17:39

  12. TYPO3com voted on patch set 39 V +1 05/12/19, 17:52 Completed build in 12m 57s on Sun, 12 May, 07:52 PM Test Summary: 47670 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-33828

  13. Markus Klein commented on patch set 39 05/13/19, 08:36

    AjaxRequest.ts:44 Reply

    It has always been. ;-) https://www.typescriptlang.org/docs/handbook/basic-types.html Do we use this syntax all over the core or not? I also don't mind that much, but it should be consistent within core's TS and it would be nice to be consistent with PHP too, which would speak for `type[]` syntax.

    FormResultCompiler.php:267 Reply Unresolved

    I totally misunderstood the comment. Thanks. forget it.
  14. Andreas Kienast commented on patch set 39 05/13/19, 08:41

    AjaxRequest.ts:44 Reply Unresolved

    We use that syntax in one file right now. I'd keep this variant for now, we can streamline that later.
  15. Andreas Kienast uploaded patch set 40 05/15/19, 17:17

  16. TYPO3com voted on patch set 40 V +1 05/15/19, 17:28 Completed build in 10m 50s on Wed, 15 May, 07:28 PM Test Summary: 47599 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-33878

  17. Benni Mack commented on patch set 40 05/15/19, 18:52

    on testing: hiding (enable/disable) does not grey out the header anymore.
  18. Andreas Kienast commented on patch set 40 05/15/19, 19:22

    > Patch Set 40: > > on testing: hiding (enable/disable) does not grey out the header anymore. True, will fix
  19. Andreas Kienast uploaded patch set 41 05/15/19, 19:30

  20. TYPO3com voted on patch set 41 V +1 05/15/19, 19:55 Completed build in 16m 25s on Wed, 15 May, 09:55 PM Test Summary: 47591 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-33885

  21. Georg Ringer voted on patch set 41 V +1 CR +1 05/21/19, 13:35

  22. Frank Nägler voted on patch set 41 V +1 CR +1 05/24/19, 10:00

  23. Frank Nägler voted on patch set 41 V +2 CR +2 05/24/19, 10:01

  24. Frank Nägler merged patch set 42 05/24/19, 10:01

  25. Nicole Hummel commented on patch set 42 07/22/20, 14:36

    InlineControlContainer.php:626 Unresolved

    The onChange event for the "create new button" was removed and the related (new) class wasn't set. The button currently is not working.