Telerik Forums
Kendo UI for jQuery Forum
0 answers
7 views

Hi..

I have Radio button. But I don't see the radio getting focus, or any indication that it has focus. How can set the CSS so it show's that it has focus???

 

<input type="radio' id="radio1" class ="k-radio"

 

I have tried...

 

K-radio:focus{

  border: 10px solid red;

 color : red

}

 

nothing

Any ideas?

thx

 

Jonathan
Top achievements
Rank 1
Veteran
 asked on 12 Apr 2024
0 answers
84 views

Hey guys,

currently I have an use-case where I could need a radio group with some standard text options but one radio with a dropdownlist.
With googling I could find only one question similar to this with a solution in kendoReact.

Is there a best practice solution to realize this in .NET Core?

https://www.telerik.com/forums/dropdownlist-with-radio-button-not-working
And a working example here: https://stackblitz.com/edit/react-1gnbzt?file=app/main.jsx

Does it make sense to combine radio buttons for common options with a drop  down menu for less common options? - User Experience Stack Exchange

Cheers!

 

EDIT:

Sure, like always. After asking the question, I could solve it by myself. Thanks anyways! 

@(Html.Kendo().RadioGroup()
                    .Name("xxx")
                    .Items(i =>
                    {
                        i.Add().Label("United States").Value("1");
                        i.Add().Label("Canade").Value("2");
                        i.Add().Label("Mexiko").Value("3");
                        i.Add().Value("4").Encoded(false).Label("Other: " + Html.Kendo().DropDownListFor(x => x.ProviderId)
                                    .DataSource(source => source
                                        .Custom()
                                        .Sort(x => x.Add(Html.NameFor(y => new Provider().Name)))
                                        .Transport(x => x
                                            .Read(read =>
                                            {
                                                read.Url($"https://{webApiHost}/fruehehilfen/api/Provider").Headers(new { authorization = user.TokenString });
                                            })))
                                    .DataTextField(Html.NameFor(x => new Provider().Name))
                                    .DataValueField(Html.NameFor(x => new Provider().ID))
                                    .HtmlAttributes(new { style = "width: 100%" })
                                    .OptionLabel("Bitte auswählen").ToHtmlString());
                    })
                )
Daniel
Top achievements
Rank 3
Iron
Iron
Iron
 updated question on 10 Dec 2021
1 answer
370 views

How can i use DataSource in RadioGroup instead of static data items ?

In below code instead of hard coded items i want to use the Datasource so that the Radio optoion get rendered based on data returned by API.

                       {
                        field: "RadioGroup",
                        editor: "RadioGroup",
                        label: "Select User:",
                        validation: { required: true },
                        editorOptions: {
                            items: [{"label":"Admin","value":"1"}, {"label":"Admin 2","value":"2"},{"label":"Admin 3","value":"3"}],
                            layout: "horizontal",
                            labelPosition: "after"
                        }
                    }

Neli
Telerik team
 answered on 28 Jan 2021
Narrow your results
Selected tags
Tags
+? more
Top users last month
Dominik
Top achievements
Rank 1
Giuliano
Top achievements
Rank 1
Dominic
Top achievements
Rank 1
Glendys
Top achievements
Rank 1
Iron
NoobMaster
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Dominik
Top achievements
Rank 1
Giuliano
Top achievements
Rank 1
Dominic
Top achievements
Rank 1
Glendys
Top achievements
Rank 1
Iron
NoobMaster
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?