- Issue created by @spuky
- ๐ฎ๐ณIndia prem suthar Ahemdabad- Gujrat , Jodhpur - Rajsthan
Prem Suthar โ made their first commit to this issueโs fork.
- Merge request !1243465459-improve-descripton : Update the Description Based on the Suggestion. โ (Merged) created by prem suthar
- Status changed to Needs review
8 months ago 1:37pm 2 August 2024 - ๐ฎ๐ณIndia prem suthar Ahemdabad- Gujrat , Jodhpur - Rajsthan
Update the Description Based on the Suggestion
Please review. -
spuky โ
committed 904a3d3e on 2.x authored by
Prem Suthar โ
Issue #3465459 by Prem Suthar, spuky, joakland: Improve description of...
-
spuky โ
committed 904a3d3e on 2.x authored by
Prem Suthar โ
- Status changed to Fixed
8 months ago 1:45pm 2 August 2024 - ๐บ๐ธUnited States joakland
I think this solution puts too much of the onus on the user. In my experience, most of the folks making configuration changes via the UI are not familiar with escaping characters and do not know how to use regular expressions. For people who do understand regex, it's not clear what constitutes "simple" regex. The only way they would know if their regex is insufficiently simple is if the path exclusion doesn't work.
There are other places in Drupal where a user may enter paths (such as the visibility section of block configurations) that address the same problem without relying on regular expressions, or requiring users to make a judgement about complexity. Adopting such an approach would be a more user-centered solution.
- ๐ฉ๐ชGermany spuky
on the one hand I understand your point... on the other hand it is an "Advanced" Setting...
So reading the description of how to use it could be expected.. the added Text + an example of how to escape slashes was added.It was taking me several tries to come up with the Idea to not escape the string here to get the warning and stack trace
This was an easy fix to Improve the usability for users by providing inline documentation.
New feature requests or even merge request for Improvements like:
- verification of entered stings on save with an error message (maybe best solution when thinking about updates of existing config..)
- spliting the config in two fields one for regex one for simple paths
- having an "regex!" prefix like the custom breadcrumb fieldare welcome
but somebody has to write that code, make sure it does not break the stuff for people already having a regex in there...
to provide a sane update... to whatever the situation is changed to...and till then a field that gives someone the power to do what they need with the risk of some "foot shooting" is better than a less powerfull alternative ;-)
- ๐บ๐ธUnited States joakland
That all makes sense. And you make a good point that someone using the advanced settings is more likely to be able to write those strings correctly. The inline documentation you added does a good job of explaining how to do this.
That said, I do think programmatically escaping slashes that are not already escaped is a low bar to clear. I'm going to do this in a different issue/push request, which you of course are free to accept, edit, or reject.
-
spuky โ
committed 904a3d3e on feature/megre_dynamic-breadcrumbs authored by
Prem Suthar โ
Issue #3465459 by Prem Suthar, spuky, joakland: Improve description of...
-
spuky โ
committed 904a3d3e on feature/megre_dynamic-breadcrumbs authored by
Prem Suthar โ
Automatically closed - issue fixed for 2 weeks with no activity.