[TASK] Support valuePicker in colorpicker 90/52090/8
authorChristian Kuhn <lolli@schwarzbu.ch>
Fri, 17 Mar 2017 18:37:48 +0000 (19:37 +0100)
committerFrank Nägler <frank.naegler@typo3.org>
Fri, 17 Mar 2017 22:54:40 +0000 (23:54 +0100)
commit872ad59d2a7aaeb0d1bc7ae1ab9e230da29f3c65
tree349af35e0a731a8d778b058e90c7c989c99fac3a
parent3664b27d87fd2054f5a32c60bedc65c6ae939007
[TASK] Support valuePicker in colorpicker

Add the 'valuePicker' functionality to the colorpicker. This is useful
for editors to have a series of defaults. A similar configuration worked
in the past based on 'select' wizard.

Example TCA from styleguide master input_37:
    'config' => [
        'type' => 'input',
        'renderType' => 'colorpicker',
        'size' => 10,
        'valuePicker' => [
            'items' => [
                [ 'blue', '#0000FF', ],
                [ 'red', '#FF0000', ],
                [ 'typo3 orange', '#FF8700', ],
            ],
        ],
    ],

Change-Id: Idf24ecc1b47e84f6e4aa985191beebeb3631b202
Resolves: #80337
Releases: master
Reviewed-on: https://review.typo3.org/52090
Reviewed-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
Tested-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch>
Tested-by: Christian Kuhn <lolli@schwarzbu.ch>
Reviewed-by: Frank Nägler <frank.naegler@typo3.org>
Tested-by: Frank Nägler <frank.naegler@typo3.org>
typo3/sysext/backend/Classes/Form/Element/InputColorPickerElement.php
typo3/sysext/backend/Resources/Private/TypeScript/ColorPicker.ts
typo3/sysext/backend/Resources/Public/JavaScript/ColorPicker.js