OrchardCMS / OrchardCore

Orchard Core is an open-source modular and multi-tenant application framework built with ASP.NET Core, and a content management system (CMS) built on top of that framework.
https://orchardcore.net
BSD 3-Clause "New" or "Revised" License
7.41k stars 2.39k forks source link

Taxonomies: default option #7942

Open MikeKry opened 3 years ago

MikeKry commented 3 years ago

Hello,

just found a minor problem, when taxonomy is not required, but is using standard tree display and has disabled multiple selection, there is no default option, so when someone selects taxonomy term by mistake, then it is not possible to remove it.

I will probably fix this myself, just letting you know if someone would be working on taxonomies..

hishamco commented 3 years ago

/cc @deanmarcussen

serverside-is commented 3 years ago

A "default option" sounds strange to me.

There could be a "clear" button.

Or, allow a second click to "uncheck" the selection (something like this). In this case the user would need to know this was possible, of course.

Just my 2 cents :-)

MikeKry commented 3 years ago

@serverside-is

sure, I was just pointing out that there is no possibility to reset it to default, it does not really matter, if it would mean adding reset button / checkbox-like behavior or even just another option e.g. with text "no selection".

Personally I would go with a button or another radio button for default, uncheckable radio is pretty uncommon for many users..

maybe we could try to implement something like this and it could also be used to extend possibilities of other parts setup: https://www.jotform.com/help/251-how-to-limit-the-number-of-selections-on-a-checkbox-field

deanmarcussen commented 3 years ago

The last time we talked about the default taxonomy browser we decided it would be good to reimplement it with this https://vue-treeselect.js.org/ vuejs plugin.

It's similar to the tags editor, so there shuld not be much to do, and then you will have both a nicer control for selecting normal taxonomies (that takes a lot less screen space, when there are a lot of terms), and a much improved ability to control defaults / what can / can't be selected.

I'd prefer the time was invested in that, rather than an extra button

MikeKry commented 3 years ago

@deanmarcussen

Cool, I just wanted to have quick fix for this problem, but that looks way better.

Is there any PR/Task already in progress on that?

If not, I will have some spare time in month or two, so I could look into this..