CustomBangSearch icon indicating copy to clipboard operation
CustomBangSearch copied to clipboard

"Can't rename to bang currently in use" check is to aggressive.

Open Kl4rry opened this issue 3 years ago • 3 comments

If you want to add a bang which starts with a letter thats already taken you are not allowed to type that letter.

Example if i have a = https://amazon.com/s?k=%s

and i try to add

abc = https://example.com?q=%s

Then i am not allowed to type the a in abc because a is already taken.

Kl4rry avatar Feb 20 '22 15:02 Kl4rry

Yeah I see what you mean, good spot.

As a workaround for now you'll have to make the bang text box empty (e.g. add an unused letter such as z to the end of the bang, then delete the bang from the start) and you can then copy/paste your bang such as abc into it

psidex avatar Feb 20 '22 15:02 psidex

So it turns out this is a problem that I think can only be fixed by changing the way in which the extension stores data internally, which is going to be a considerable amount of work.

I don't have a massive amount of time to work on this so this issue is probably going to exist for a while, unless someone else wants to have a go at fixing it!

Like I said a workaround is to make the bang empty and then copy/paste what you want in, or export your bangs, edit the json, then import them

psidex avatar Feb 26 '22 16:02 psidex

Hey, I just proposed a MR to fix this issue. This also addresses the issue #16, as the proposed changes modify the input fields in such a way that the changes are only saved (or tried, after all) when the fields lose their focus. If you got any comments, let me know :).

befocken avatar Jul 01 '22 22:07 befocken