kbin Enhancement Suite: a community-curated script manager that lets you customize your kbin experience

artillect@kbin.social to /kbin meta@kbin.social – 1 points –

A couple of weeks ago, @shazbot made this post about a project that they were working on. Since then, @shazbot, @ori, @minnieo and I have been hard at work, and we are excited to finally announce the official release of kbin Enhancement Suite (KES)!

kbin has seen an explosion of user-made add-ons, but keeping track of them in one place, letting them share settings with one another, and toggling them on and off can be a challenge. KES is an expandable add-on manager that aims to rectify this by providing a unified interface and framework for script makers to collaborate, and letting you use them all in one place.

KES brings together userscripts from the community, with a built-in settings menu that lets you tailor your experience to your liking. It also offers a flexible framework that empowers script authors to effortlessly integrate scripts into KES and set up custom input fields with no additional code.

KES gives you a single window onto a collection of enhancements that is growing by the day. And those features can be added to by you!

The KES settings menu

What the feed looks like with everything enabled

The comments with everything turned on

Features

We’ve focused on making customizing your kbin experience as easy as possible, whether you are on mobile or desktop. After we sort out the bug reports from this release, we plan on adding many more features! Here’s what we have so far:

  • Collapsible comments with nesting (by @artillect)
  • Use slash commands to add emoticons in text areas (by @minnieo)
  • Add syntax highlighting (with customizable themes) to code blocks (by @ori)
  • Show instance names next to non-local users and communities (by @artillect)
  • Add a link to message users on your instance next to their usernames (by @shazbot)
  • Hide upvote/downvote buttons and reputation (by @artillect)
  • Show more detailed timestamps on threads and comments (by @shazbot)
  • Hide thumbnails on threads (by @shazbot)
  • Add link to subscribed magazines to the navbar (by @shazbot)
  • Replace or hide the kbin logo in the navbar (by @shazbot)
  • Add “OP” label next to thread author’s username in comments (by @shazbot)
  • Convert navigation links on profile pages into a dropdown (by @shazbot)

Each of these can be toggled in the settings menu, and some of them have additional configuration options, such as setting custom labels, colors, etc.

New features are added on a rolling basis and the menu pages will update on the fly to reflect this new content.

Installation

Click here to install KES, and follow your userscript manager’s prompt to complete the installation.

If you don’t have a userscript management extension, you can install one of these, and then install KES using the link above:

Once KES is successfully installed, access the settings menu by clicking on the wrench icon located at the top-right corner next to your username. From there, you can enable the features you like, and customize your browsing experience.

More information

For bug reports and feature requests, visit our GitHub repository’s issues page. If you have any questions or need assistance, don’t hesitate to ask here or make a post on /m/enhancement!

Developers

If you are a userscript author, we’d love it if you could try porting your userscripts into KES, or try writing completely new ones for it! @shazbot has made it easy to integrate your scripts: you just need to add your script’s information to manifest.json, make a few small modifications to your script, add it all to the GitHub repository, and you’re good to go!

KES benefits:

  • Turnkey integration: a simple, declarative framework for dynamically adding features to the UI without touching the underlying code
  • Sharing of user-defined settings through script namespaces: access your script settings, and those from other scripts, through a well-defined object
  • Automatically responds to infinite scroll and page reload events
  • Attribution of script authors
  • Easily toggle scripts on/off

Explore KES’s documentation here to get started. If you have any questions, feel free to reach out here, on /m/enhancement, or at our GitHub repository.

45

Hm. Been using kbin enhancement script + kbin usability pack so far but I'll check it out.

Edit: Nevermind, doesn't seem to work for me at all. I don't even get the settings button.

what browser are you using and what extension to run the script?

I’ve got the same issue - using iOS Safari and Userscripts.

If you have time, would you mind trying the 2.0.0 release here?

Roger. I’ve updated (script says v2.0.1) but still seems a bust - no wrench menu.

Make sure you are on 2.0.2 at the minimum. A small hotfix was needed.

Updated to v2.0.2 - still nothing.

OK, just wanted to isolate the scope of the problem. Seems to still be isolated to iOS.

Not sure if any relevant changes were made between 2.0.2 -> 2.0.4, but just fyi it’s still not working for me on iOS + Userscripts.

Take a look at this thread, think we have the smoking gun here after putting the pieces together and looking at what is different in your setups. It seems to be a totally cosmetic issue: KES is loading, but the wrench icon got buried in the attenuated navbar on mobile view. This explains why it worked on tablet Safari but not for users on phones. This should be easy to fix now that we know the scope of the problem.

That’s great! I’ll keep an eye out for an update and give it a test.

May I ask what mobile phone you are using? There is a hotfix live now that should move the wrench icon into the hamburger menu if the viewport is too small.

1 more...
1 more...
1 more...
1 more...
1 more...
1 more...
1 more...
1 more...
1 more...
1 more...

Firefox + Greasemonkey.

This should be fixed, would you mind trying the 2.0.0 release here?

I already switched to Violentmonkey over the weekend, since Greasemonkey seems to be abandoned for now.
At least for the previous version I couldn't really find much use for. Most of the features were sort of worse than the one in my other used scripts. Like the collapsible comments didn't work with the endless comment scrolling from kbin usability pack and I found the ones from kbin enhancement script just had more usable features that come with it, like collapsing replies and a default collapsed state. Other features didn't really offer much use. Like hiding the sidebar, which a) also hides the config button and doesn't really do anything with the empty space, like enlarging the main content to that side.

Edit: Also, updating to the latest version did not work in ViolentMonkey.

1 more...
1 more...

Fantastic project and fantastic work.

For what it's worth I'd love to see the following userscripts ported to KES:

  • Better Navigation Page - makes the page number at the bottom more readable
  • Kbin Notifications Panel - adds a notification panel to the navigation bar
  • Kbin Subscriptions Panel - adds a collapsible, filterable side panel with a list of all magazine subscriptions (KES has an "Add subs to navbar" option, but the subscriptions panel is a more sophisticated and user-friendly alternative)

I'm still running these three scripts in addition to KES, but if they were ported to KES it would make managing them easier (via a common interface for options) and reduce the potential for conflicts.

For example, running Kbin Subscriptions Panel a well as KES produces this visual glitch in the navbar, where the icons get mixed up:

Kbin Notification Panel for sure, it's SO much better than the vanilla notifications.

I'd like to see @raltsm4k 's Floating Subs List make the cut instead of that Subscription Panel though. Its the same functionally, just more aesthetically pleasing.

I love it! I have one question though, wouldn't it be better to separate KES version from all of the userscript/settings versions? Updating from 1.1.4 to 1.1.6 only moved the version up in userscript info, since all the userscripts are updated separately anyway. Updating KES would make sense only if something in kes.user.js is changed, right now users just get KES update prompts that do nothing.

This is done to force re-cache of the new version of a userscript when it gets added as a feature. MINOR version bumps indicate addition of a mod (userscript) or internal feature, while PATCH version bumps indicate a hotfix. By design in GM, when the version number of the main script is bumped, it will redownload the requisite remote resources. We leverage this functionality to serve new files.

This should partially be rectified by the addition of the changelog link (flask icon) in 1.2.0.

When new mods are added to KES, they are integration tested, so bumping the MINOR version does imply some feature change to the KES interaction itself, albeit not necessarily at the code level.

The userscripts are not updated separately, they are cached once per KES version download. Hope this makes sense.

Seems to work pretty well on mobile Firefox with Tampermonkey. Haven't had a chance to fully explore yet, but looks really good so far! Good job!

I know this is a few days old, but I'm just now seeing this, and wanted to thank you for collapsible comments. This one little addition makes things so much cleaner now!

Do you know if hiding individual threads from the feed is something that can be added to this, as well? Or does that require an update with Kbin, itself?

By hiding threads, are you referring to blacklisting certain types of threads based on a keyword, or are you talking about "cleaning" the thread index by clicking a hide button to wipe it from the view?

The latter, hiding individual threads by pressing a button.

Permanent hide?

Yeah, I'm thinking basically the same implementation Reddit has, where you can tap "Hide" on a post, and it'll disappear after a few seconds and stays gone from your feed.

I've been thinking about this. I think I would say: hide posts for the duration of the browser session and localized only to that tab, yes, eminently doable, and they won't return while you browse around until you exit the browser. But for permanent storage, we have to store the ID of each post in perpetuity, and this will necessarily grow to epic proportions over time as you hide stuff, but there is a small upper bound (5MB) on how much can be retained persistently across all apps. In addition, you'd be carrying around the ID of every post you've blocked before and it would be visible to other tabs in your browser, which is a small security concern insofar as it vaguely indicates your preferences. So there is a security and performance negative to this. I don't think we should retain any such information, only generic information such as on/off states, etc. Hope this is clear.

Pretty sure you could do that locally via cookies without the need for that server load. I think that's how Reddit's implementation of hiding posts works, at least.

There is no server load, I am talking about the equivalent to cookies: sessionStorage and localStorage. Albeit small, the performance drag comes from parsing a growing list of IDs, and the fact that 5MB is shared across the entire browser for all scripts and applications, and the aforementioned security consideration. When I said "we have to store," I was talking about the localStorage method. Also, KES should never callback to a remote server to store settings, we are against that.

Seems to throw some errors with Violentmonkey on Firefox. Haven't looked too deep into it yet though.

Edit: It appears that this doesn't completely work, we'll keep working on it

I've figured out the issue, as soon as @shazbot sees my pull request on GitHub there should be an update that fixes it! For a temporary fix for now though, you can Ctrl-F GM. and replace them with GM_ (there should be 4 of these, on lines 17, 18, 128, and 133), and remove the await on line 133

I apologize for the inconvenience. This should be fixed in 1.1.3. The update should be available momentarily as a prompt within KES. If you don't see it, try invoking Ctrl-F5 to refresh cache.

ViolentMonkey can at times be more idiosyncratic than TamperMonkey in the syntax it expects, and I don't usually recommend it because I don't think it has feature parity with TM, but regardless, this issue was my fault for not testing more thoroughly against different extensions.

Maybe some day, when Tampermoney decides to opensource their code again 😉

We have worked up a more comprehensive fix that provides cross-API support for the different GreaseMonkey implementations found in various browser add-ons. Update should be forthcoming after being stress-tested. As it turns out, there is no truly universal API standard between these tools and they have highly similar, but ultimately different, implementations, so we had to make a shim.

Love the concept, though it looks like Firefox ViolentMonkey comment collapsing doesn't work quite right. The comments end up stacked on top of each other like cards.

I feel this is my fault for not sufficiently testing against ViolentMonkey; apologies. I have made a few hotfixes now that should ensure the manager itself functions as intended. As for the comment collapsing add-on, that is the responsibility of @artillect, but I've suggested a fix and it should be making its way into the app presently.

It's totally fine! Public exposure essentially blasts any project with just about every combination of variables. Something is bound to slip by. I was just commenting to make sure you guys knew it was happening.

EDIT: Just got the update, everything works beautifully now. Great work!

Collapsing comments is really smooth and the tap anywhere to collapse is something I didn't knew I needed. Good job, thank you!

Thanks! I worked really hard on that before working on KES, and it was super easy to integrate my script into it

vger.app web app for Lemmy is annoyingly stuttery when collapsing comments, this is much better!

I'm hoping there will eventually be a kbin update or userscript that allows you to change the text size of comments separately from the rest of the site. The text is too small for me.