dennis-tra / alfred-dict.cc-workflow

🌍 Alfred 4/5 workflow to get translations from dict.cc
137 stars 4 forks source link

FR: indication of property entries like British/American English or colloquial #20

Closed chrisgrieser closed 1 month ago

chrisgrieser commented 1 month ago

Just a small feature suggestion:

it would be very useful if there could be an indication, if the word is colloquial, or from a certain region (such as American/British English).

dennis-tra commented 1 month ago

Hi @chrisgrieser, sorry for the late reply. That would indeed be a cool addition! However, adding this feature would make the workflow much more complex. This is only because right now the workflow is so stupidly simple that I'm actually surprised it’s been working like this for the last 8 years.

In the header of the page source there are two arrays. Here's an example:

var c1Arr = new Array("","translation","translation","translation","translation","translation","translation","translation","translation","translation","translation","translation","translation","translation","translation","without translation","to defy translation","abridged translation","accepted translation","accurate translation","address translation","address translation","address translation","alphabetic translation","analogous translation","authentic translation","authorized translation","authorized translation","back translation","back-translation","bad translation","Bible translation","certified translation","character translation","close translation","close translation","code translation","code translation","complete translation","consecutive translation","correct translation","courtesy translation","courtesy translation","currency translation","data translation","direct translation","exact translation","extemporaneous translation","extract translation","formula translation","free translation");
var c2Arr = new Array("","Übersetzung","Umsetzung","Translation","Umwandlung","Parallelverschiebung","Übertragung","Verschiebung","Konvertierung","Entrückung","Überführung","Übertragung","Sinnübertragung","(sprachliche) Übertragung","Translatio","ohne Übersetzung","(fast) unübersetzbar sein","Teilübersetzung","Standardübersetzung","gewissenhafte Übersetzung","Adressenübersetzung","Adressübersetzung","Adressumrechnung","Lochschriftübersetzung","sinngemäße Übersetzung","maßgebliche Übersetzung","autorisierte Übersetzung","beglaubigte Übersetzung","Rückübersetzung","Rückübersetzung","schlechte Übersetzung","Bibelübersetzung","beglaubigte Übersetzung","Zeichenumsetzung","genaue Übersetzung","wortgetreue Übersetzung","Codeumwandlung","Kodeübertragung","vollständige Übersetzung","konsekutive Übersetzung","fehlerlose Übersetzung","Gefälligkeitsübersetzung","Höflichkeitsübersetzung","Währungsumrechnung","Datenkonversion","Direktübersetzung","genaue Übersetzung","Stegreifübersetzung","auszugsweise Übersetzung","Formelübersetzung","Gratisübersetzung");

I'm just parsing these two arrays and I'm not looking at the rest of the page. Unfortunately, these arrays don't have indications regarding colloquialism or regional variations. Getting that information would require actually parsing the HTML and extracting it from there which would make it much more complicated than it is right now.

I'm afraid I need to dismiss this feature request :/

chrisgrieser commented 1 month ago

too bad, but since I am an open source maintainer myself, I can totally understand that maintainability is important. Thanks for maintaining this project for so long!