Hi,
When configuring tiny we can customize it like this
context.Services.Configure(config =>
{
config.Default()
.AddSetting("media_dimensions", false);
});
But how do I configure if I want to customize an callback for exampke color picker?
In JS:
tinymce.init({
selector: "textarea", // change this value according to your HTML
plugins: "textcolor colorpicker",
toolbar: "forecolor backcolor"
color_picker_callback: function(callback, value) {
callback('#FF00FF');
}
});
In C# ?
context.Services.Configure(config =>
{
config.Default()
.AddSetting("media_dimensions", false)
.AddSetting("color_picker_callback", );
});
I tried returning an javascript function as string for "color_picker_callback" but the TinyMce editor is then throwing an error. I guess it wont work to return an javascript function as a string, since it wont work to set values as "true" or "false" as strings.