[FEATURE] Store icons in localStorage 21/56721/7
authorAndreas Fernandez <a.fernandez@scripting-base.de>
Wed, 18 Apr 2018 08:03:59 +0000 (10:03 +0200)
committerFrank Naegler <frank.naegler@typo3.org>
Thu, 19 Apr 2018 13:01:43 +0000 (15:01 +0200)
commit6f9e25d9181f50ef4c7bf951dd91864b536b90e2
treeb516a3f8208da14ecb85e897a506c4577da2b743
parent895ec99720a4fef4c010d45bb324b30e264948eb
[FEATURE] Store icons in localStorage

The icons that get requested by the Icon API on JavaScript side are not
stored in the client's localStorage.
To have a proper invalidation, a hash of the IconRegistry is built and
stored in the localStorage, too. If the hash changes, all icons in the
localStorage get flushed.

To achieve this, the Storage/Client module is extended to allow removing
values by a given prefix.

Resolves: #84780
Releases: master
Change-Id: Ic2137b05530201a8a94a7ea6c28ae1a012206221
Reviewed-on: https://review.typo3.org/56721
Reviewed-by: Mathias Schreiber <mathias.schreiber@typo3.com>
Tested-by: Mathias Schreiber <mathias.schreiber@typo3.com>
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Kay Strobach <typo3@kay-strobach.de>
Tested-by: Kay Strobach <typo3@kay-strobach.de>
Reviewed-by: Frank Naegler <frank.naegler@typo3.org>
Tested-by: Frank Naegler <frank.naegler@typo3.org>
typo3/sysext/backend/Configuration/Backend/AjaxRoutes.php
typo3/sysext/backend/Resources/Private/TypeScript/Icons.ts
typo3/sysext/backend/Resources/Private/TypeScript/Storage/Client.ts
typo3/sysext/backend/Resources/Public/JavaScript/Icons.js
typo3/sysext/backend/Resources/Public/JavaScript/Storage/Client.js
typo3/sysext/backend/Tests/JavaScript/IconsTest.js
typo3/sysext/core/Classes/Controller/IconController.php
typo3/sysext/core/Classes/Imaging/IconRegistry.php
typo3/sysext/core/Documentation/Changelog/master/Feature-84780-RemoveEntriesInLocalStorageByKeyPrefix.rst [new file with mode: 0644]
typo3/sysext/core/Documentation/Changelog/master/Feature-84780-StoreIconsFetchedByTheIconAPIInLocalStorage.rst [new file with mode: 0644]