I am using theTelerik Color Picker with both ColorPickerGradientView & ColorPickerPaletteView. I would like to capture the event when the Color format changes from RGB to Hex and vice versa in the ColorPickerGradientView.
I am using the Telerik ColorPicker alongside a text box. When the color is selected from the ColorPicker, it appears in the Textbox. However, when I toggle the color format from Hex to RGB and select a color, I want the RGB value to be displayed in the Textbox.
I noticed that the ColorGradient component supports a FormatChanged event which gets triggered when the color format Toggle button is clicked, but this event does not seem to work with the Telerik ColorPicker using the ColorPickerGradientView.
Inserting a hex-color code in the empty textbox of the color picker does not work. The color is not applied in the picker.
It only works if a color is already present in the textbox.
You can reproduce the bug on the demo site https://demos.telerik.com/blazor-ui/colorpicker/overview
Best regards,
Hannes
The problem is reproducible in your demo section: https://demos.telerik.com/blazor-ui/colorpicker/overview
I attached two short video clips showing the problem and the screenshots below.
Image 1: Open the Color Picker by clicking on it with the mouse. The picker dialog opens.
Image 2: Click with the mouse in the green area. You see a minor change in the RGBA fields, but no change in the color canvas.
Image 3: By clicking in the G field e.g. and changing the number with the down key from 46 to 45, the slider moves back to the blue area of it.
It seems to happen only with the first click onto the slider. With the second click and more it works like it should.
Best regards,
Hannes
When a culture that has comma for decimal separator is used, the ColorPicker formats the rgba() CSS rule as rgba(255,255,255,0,6) which is incorrect. The alpha value should always have a dot as a decimal separator.
<TelerikColorPicker @bind-Value="@value">
@code {
public string Value { get; set; } = "#282f89";
}
Set the culture of the application so that the default decimal separator is a comma (el-GR).
// in Program.cs file
CultureInfo.DefaultThreadCurrentCulture = new CultureInfo("el-GR");
CultureInfo.DefaultThreadCurrentUICulture = new CultureInfo("el-GR");
The rgba() rule is formatted as rgba(255, 255, 255, 0,6) but should be formatted as rgba(255, 255, 255, 0.6).