I saw a few other posts that requested this feature which in all of the cases was denied saying to use Enabled instead...
The reason we need a ReadOnly state is because the user can not highlight to select the text to copy/paste if desired... that would be the reason we need ReadOnly vs disabled...
Disabled does not allow you to select the text to copy/paste...
---
ADMIN EDIT
A workaround is to re-enable the pointer events and to, optionally, set a highlight color:
<style>
/* Re-enable selection and scrolling of disabled textboxes.
Apply text selection style.
Can cause some side effects with appearance of hover and focus states */
/* UI for Blazor 3.0 + */
.k-input-inner.k-disabled,
.k-disabled > .k-input-inner,
input.k-textbox[disabled] {
pointer-events: initial;
}
.k-input-inner[disabled]::selection {
color: #fff;
background-color: #ff6358;
}
/* UI for Blazor 2.30 - */
.k-input.k-state-disabled,
.k-state-disabled > .k-input,
.k-state-disabled > .k-dateinput-wrap > .k-input,
input.k-textbox[disabled] {
pointer-events: initial;
}
.k-input[disabled]::selection {
color: #fff;
background-color: #ff6358;
}
</style>
<TelerikTextBox @bind-Value="@tbText" Enabled="false" />
<TelerikTextArea @bind-Value="@taText" Enabled="false" />
<TelerikDatePicker @bind-Value="@dpDate" Enabled="false" />
<TelerikDropDownList @bind-Value="@ddlVal" Data="@ddlData" Enabled="false" />
@code{
string tbText { get; set; } = "lorem ipsum";
string taText { get; set; } = "lorem ipsum\ndolor sit amet\nlorem ipsum\ndolor sit amet";
DateTime dpDate { get; set; } = DateTime.Now;
List<int> ddlData { get; set; } = Enumerable.Range(1, 10).ToList();
int ddlVal { get; set; } = 2;
}
---