[Release] Swarth

Add-ons for Pale Moon and other UXP Applications
General discussion, compatibility, contributed extensions, themes, plugins, and more.

Moderators: FranklinDM, Lootyhoof

User avatar
FranklinDM
Add-ons Team
Add-ons Team
Posts: 310
Joined: 2017-01-14, 02:40
Location: Manila, Philippines
Contact:

[Release] Swarth

Unread post by FranklinDM » 2021-08-03, 11:23

Swarth modifies web pages to use a dark color scheme or based on the user's preferences. This extension is a fork of Dark Background and Light Text, rewritten to utilize XUL overlays instead of Jetpack/Add-ons SDK.

Several additional features were included, such as following the browser's preferred color scheme, keeping changes made in private browsing sessions, and sorting configured pages. You can use this extension alongside AutoPageColor to achieve automatic light/dark color scheme switching based on your current time, provided that you enable the Follow preferred color scheme option.

Unlike DBaLT and its current derivatives, Swarth only targets content pages in the main tab browser (pages opened in the web panel/sidebar will be covered in the future). Changes to the extension's settings (i.e. toggling enabled and default color method) are not applied immediately on all windows and tabs. Instead, they take effect upon selecting or switching to a tab, fixing the minor but noticeable performance issue when enabling/disabling DBaLT's functionality while having many tabs open.

Open for feedback and suggestions!

Compatible with Pale Moon, Basilisk, and Borealis Navigator.
Last edited by FranklinDM on 2021-08-11, 09:22, edited 1 time in total.
Reason: Update links

Likestofish
Moongazer
Moongazer
Posts: 12
Joined: 2021-04-25, 14:56

Re: [Pre-release] Swarth

Unread post by Likestofish » 2021-08-04, 22:00

Works fine on both Pale Moon and Basilisk. Until now used Advanced Night Mode and Dark Background and Light Text because the colour preferences in the content menu would black out eMatrix's display.

Thank-you.

User avatar
New Tobin Paradigm
Knows the dark side
Knows the dark side
Posts: 10523
Joined: 2012-10-09, 19:37
Location: The Seriphia Galaxy

Re: [Pre-release] Swarth

Unread post by New Tobin Paradigm » 2021-08-04, 22:46

Upon a cursory code perusal I don't see anything that would prevent it from working with Borealis as it is very clean and seems web client agnostic save overlay. If you want an updated build for testing let me know.

In any event, this is damn fine work dude. I am proud of you.
Of course, all these failures mount up and could easily end up costing more collectively than paying a proper rage would.
Image

User avatar
hujan86
Fanatic
Fanatic
Posts: 161
Joined: 2017-09-27, 06:50

Re: [Pre-release] Swarth

Unread post by hujan86 » 2021-08-05, 14:52

With the extension enabled, the top banner on PM's homepage is blacked out.

Image
Avatar's Source: yereverluvinuncleber

User avatar
New Tobin Paradigm
Knows the dark side
Knows the dark side
Posts: 10523
Joined: 2012-10-09, 19:37
Location: The Seriphia Galaxy

Re: [Pre-release] Swarth

Unread post by New Tobin Paradigm » 2021-08-05, 14:54

That is likely because the banner is a background image. My suggestion is to not change the background if it is an image.
Of course, all these failures mount up and could easily end up costing more collectively than paying a proper rage would.
Image

User avatar
FranklinDM
Add-ons Team
Add-ons Team
Posts: 310
Joined: 2017-01-14, 02:40
Location: Manila, Philippines
Contact:

Re: [Pre-release] Swarth

Unread post by FranklinDM » 2021-08-07, 09:56

v1.0.0b1 XPI is now available.
New Tobin Paradigm wrote:
2021-08-04, 22:46
...
Thanks! I've added in the necessary changes for compatibility with Borealis Navigator and it seemed to work just fine, assuming there were no changes to gBrowser behavior in the newer versions, but an updated build would certainly help in testing.
hujan86 wrote:
2021-08-05, 14:52
... the top banner on PM's homepage is blacked out.
This issue should be fixed with this release, I reverted to former behavior (based on the commented surrounding code) where the background-image is retained when no-repeat is set as its position, although I'm uncertain as to how this will impact other sites.

User avatar
New Tobin Paradigm
Knows the dark side
Knows the dark side
Posts: 10523
Joined: 2012-10-09, 19:37
Location: The Seriphia Galaxy

Re: [Pre-release] Swarth

Unread post by New Tobin Paradigm » 2021-08-07, 10:00

no-repeat backgrounds for divs is a common case .. least it was.. You can only do what you can do when you are making a generic styling extension.
Of course, all these failures mount up and could easily end up costing more collectively than paying a proper rage would.
Image

User avatar
FranklinDM
Add-ons Team
Add-ons Team
Posts: 310
Joined: 2017-01-14, 02:40
Location: Manila, Philippines
Contact:

Re: [Release] Swarth

Unread post by FranklinDM » 2021-08-11, 09:32

Thanks to everyone who tested this extension! The initial stable release (v1.0.0) of Swarth is now available in the Pale Moon and Basilisk add-ons sites.

This includes several changes from the previous test releases:
  • The Swarth toolbar button was changed to a menu button, with the main button functioning mainly as a toggle to enable/disable the extension's functionality. The action of the toolbar button can be changed via Swarth's preferences.
  • Moved the list of configured pages into its own window.
  • Implemented import/export of configured pages. Configured pages can now be imported from/exported to JSON.
  • Implemented import of configured pages from other extensions (Advanced Night Mode and Dark Background and Light Text, if available) via the configured pages window.
  • The sidebar's web panel is now covered by this extension. This does not include other panels, such as bookmarks and history.

Pause
Moongazer
Moongazer
Posts: 7
Joined: 2021-08-19, 10:05

Re: [Release] Swarth

Unread post by Pause » 2021-09-18, 16:01

First of all, thank you for this forked extension. :D

Secondly, unfortunately the blacking out images (as well as video) issue appears to occur on the front page, article listings and inside articles themselves at Ars Technica.

Front Page:
Swarth-Ars1.png
Policy category:
Swarth-Ars2.png
Aritcle:
Swarth-Ars3.png
The image will show with its 'Enlarge' link popping it up in a lightbox though, but only there, not in place as the third image above shows.

Author profile images do show properly, as do 'Further Reading' images and multiple-photo slideshows such as in this article.

Images also do show properly in the 'Related Stories'/'Today on Ars' section above the footer navigation in articles.

I don't know if the way Ars does things is something this extension can realistically detect and account for, but felt it should at least be pointed out in case it can with an update.

User avatar
FranklinDM
Add-ons Team
Add-ons Team
Posts: 310
Joined: 2017-01-14, 02:40
Location: Manila, Philippines
Contact:

Re: [Release] Swarth

Unread post by FranklinDM » 2021-09-19, 06:53

Pause wrote:
2021-09-18, 16:01
... Ars Technica.
I'll see what I can do about this.

Pause
Moongazer
Moongazer
Posts: 7
Joined: 2021-08-19, 10:05

Re: [Release] Swarth

Unread post by Pause » 2021-09-19, 07:55

Thank You. :)

User avatar
Tharthan
Board Warrior
Board Warrior
Posts: 1285
Joined: 2019-05-20, 20:07
Location: New England

Re: [Release] Swarth

Unread post by Tharthan » 2021-09-21, 21:22

Love the extension name, as someone knowledgeable about English and other Germanic languages.
English "swart" being an archaic word for "black" (in Old English the words "sweart" and "blæc" were exact synonyms). Although the base word is archaic, it still persists in the modern language in the altered derivative "swarthy" ('of a dark complexion').

English is the only Germanic language where the word did not become the predominant word for "black". Compare Dutch zwart, German schwarz, Low Saxon swart/schwart, Swedish and Norwegian svart, Icelandic svartur.
"This is a war against individuality and intelligence. Only thing we can do is stand strong."adesh, 9 January 2020

"I used to think I was a grumpy old man, but I don't hold a candle compared to Tharthan."Cassette, 9 September 2020

Image

Post Reply