The Picker is getting created and I am able to set as a macroparameter but when i use the macro in RTE it doesn't show any colours to pick from, instead it only says "You have not configured any approved colours"
Does anyone knows how it works with Umbraco V8 or it could be great if some one can share some example or code.
Approved Color property editor in a Macro umbraco V8
I want to use approved colors color picker as a macro paramter. I have created a package.manifest file as on
https://our.umbraco.com/forum/templates-partial-views-and-macros/89150-approved-color-property-editor-in-a-macro
the code for macrocolorpicker manifest file is
"propertyEditors": [ { "alias": "MacroColorPicker", "name": "Macro Color Picker", "isParameterEditor": true, "editor": { "view": "~/App_Plugins/MacroColorPicker/colorpicker.html" }, "defaultConfig": { "useLabel": true, "items": [ { "id": 1, "value": { "value": "000000", "label": "000000" } }, { "id": 2, "value": { "value": "ffffff", "label": "ffffff" } }, { "id": 6, "value": { "value": "f0f0f0", "label": "f0f0f0" } }, { "id": 4, "value": { "value": "2e8fff", "label": "2e8fff" } }, { "id": 5, "value": { "value": "370037", "label": "370037" } } ] }
] }
The Picker is getting created and I am able to set as a macroparameter but when i use the macro in RTE it doesn't show any colours to pick from, instead it only says "You have not configured any approved colours"
Does anyone knows how it works with Umbraco V8 or it could be great if some one can share some example or code.
Thanks Qaisar
Use this code:
The empty prevalues list is important, as Umbraco will otherwise just ignore the defaultConfig. Yes, it sucks, and there is zero documentation.
is working on a reply...