administrate icon indicating copy to clipboard operation
administrate copied to clipboard

Call .selectize() on all select fields

Open nhippenmeyer opened this issue 3 years ago • 1 comments

This enables using selectize with custom fields that inherit from Administrate::Field::Select without having to declare them in associative.js.

nhippenmeyer avatar Apr 13 '22 21:04 nhippenmeyer

Do you mean "fields that inherit from Administrate::Field::Associative" instead? Select fields don't use selectize (I think...?)

That aside, this might be a good idea, but I'm worried about cases where people create fields with a select field but for some reason don't want selectize on them.

Perhaps we could change the way that html_class works and make it html_classes instead. Then associative fields (and select fields) could use this to add a selectize class, and target those instead. This way a class that inherits from a selectizable one could opt out.

But perhaps I'm overthinking this :stuck_out_tongue: What do you think?

pablobm avatar Apr 14 '22 15:04 pablobm

Closing due to lack of activity.

pablobm avatar Apr 18 '23 09:04 pablobm