Skip to content
This repository has been archived by the owner on Oct 17, 2022. It is now read-only.

techouse/termania-firefox-extension

Repository files navigation

Termania.net Lookup Firefox Extension

Mozilla Add-on Mozilla Add-on GitHub license Codacy Badge GitHub manifest.json dynamic

This Firefox extension enables foreigners as well as Slovenian native speakers to search the extensive Slovenian dictionary search engine Termania.net with the click of a single button.

Why yet another Firefox Extension

Actually this is a port of my original Termania.net Lookup Google Chrome Extension.

How do I install it? 🚀

Simply visit Firefox Browser Add-ons and download it.

Is there a Chrome version as well? 🔮

Yes and it can be accessed here.

How does it work?

The user first needs to select a Slovenian word and right-click it to open Firefox's context menu:

Context menu

In order to query only the lemmas of each word form the extension makes use of the Morphological lexicon Sloleks 2.0 indexed in an IndexedDB database which holds over 100.000 lemmas. In order to get the 1.5 GB lexicon from XML to SQLite and then finally into IndexedDB I wrote parser in Python.

Once the correct lemma is identified an API call gets sent to Termania.net which in turn supplies all the information that is then presented to the user in a popup window.

Results

You also have the option to change the default dictionary to any dictionary provided by Termania.net! All you have to do is open the popup menu in Firefox's Menu bar and make your choice!

Dictionaries

The extension also supports dark mode 😎

Dark mode

Dark mode

Why is the installation of the extension taking so long?

Unfortunately the Sloleks database housing all those 100.000 lemmas is quite large (approx. 50MB) and importing it into IndexedDB takes about 5 minutes to complete during which time you wou't be able to use the extension.

How do I build it from source?

The extension uses a lot of different JavaScript libraries and has to be compiled with npm and Webpack. Ensure you have Node.js and npm installed and run these commands:

npm install
npm run build

The finished extension will present itself in a directory called build. From there you can load it as a temporary extension.