Chaban's userscripts and bookmarklet support thread

May I ask you to create another script for event relations? I have no clue about user scripts.

Since the highlighting works maybe it is not that much work?

It’s been a while since there were some visible changes to my scripts.

Editor Subscription Manager

This is probably the biggest change. It now caches the data so you don’t need to wait every time you want to manage your list of subscribed editors. Data is also passively scraped when visiting editor profiles including non-subscribed editors. This made it possible to track deleted editors and name changes.

YouTube: MusicBrainz Importer

Harmony Enhancements

  • Added a new function to drop the “artist as credited” so the artist name as currently in MB will be used. This is disabled by default, like most new modules

It’s probably just a matter of time until it’s integrated in Harmony

  • Reworked the label mapping module. You can now clean up the list and sort it manually:
    image

Click buttons across tabs

  • I’ve noticed that sometimes tabs with no changes after submission (The data you have submitted does not make any changes to the data already present) wouldn’t close automatically. The new solution should be more reliable.
  • Also, when there were lots of cover art tabs, other tabs might starve waiting for their turn until only one tab at a time was processed.
  • Added a setting to toggle the closing of merge and edit pages that were opened in a new tab/window.
    (This was feature was initially added to more efficiently do manual merges)
  • Lowered default submit rate to 5 per second.

Relationship Editor Batch Remove

Added support for the mini relationship editor for other entities as requested by @Relaxo5
However, this update also changes the behavior slightly. There are now three modifier keys:
Ctrl will select all relationships with the same target
Shift will select all relationships with the same type
Ctrl+Shift will select all relationships with the same target and type, like the old version.

While testing, I noticed relationship IDs in the relationship editor can collide across different source entities, so when you toggle relationships in the release relationship editor you need to handle the other sections separately.

Reports Statistics

Swapped the colors per request.

Compare AcoustIDs easier!

Added color highlighting to the merge queue pages as requested

2 Likes

The Relationship Editor Batch Remove works like a charm. Saved me already 200+ clicks. There should be a counter then I can give you quantified kudos :wink:

2 Likes

ListenBrainz: Extended Controls

Gave my newest (and first) script for ListenBrainz an upgrade.

Note: If you installed it from GitHub you’ll need to manually install it since the URL changed. Installations from Greasyfork will update automatically.

It can now not only add the “link listen” to the listen controls card but also all other functions plus removing the love/hate icons:

The source indicator will show the service, submission client and player on hover if available:

image

(I was thinking of adding individual icons for each player but would need proper icons for all players used by the ListenBrainz community.)

ListenBrainz: Center lengths and clip titles

I’ve also published an older userstyle that simply centers track lengths and clips overflowing titles instead of wrapping.

4 Likes

Can anybody show me a screenshot of how the “Relationship Editor Batch Remove” script looks like on an MB page, somehow I don’t get this working, although I have feeling it could be handy

You may try hovering and pressing Shift, Ctrl or Shift+Ctrl

Strange, I don’t get the icons… But the user script is installed. maybe some interaction with some other script

Hahaha, cockpit problem. I installed the extension in Chrome but tried to use it in Vivaldi…

5 Likes

Hi @chaban, happy new year. Sorry to bother you again.

Do you still have the code for your original “Batch remove cover art” script, the one where all the images are layed out like in the add images dialog, one below each other ?

Would it be posibble to use that script and add functionality to “Batch rename the disambiguation comments” for lots of images at the same time (right now you have to do this for each image individually which is very time consuming)

But please leave the current implementation for “Batch remove cover art” untouched.

Can’t promise I’ll do it. The purpose of the script was a simpler/faster method to batch remove images only which is something I had to do a few times en masse.

I’d much rather MB had a native batch edit functionality for everything.

1 Like

Of course that would be much better … don’t hurry only if you find some spare time … hahaha

I did it now by myself by asking stupid questions to Gemini. See the following screenshot:

The userscript adds a “Batch edit cover art” button after the standard “Add cover art” and “Reorder cover art” buttons. It then loads the metadata off all the images in a container (it also offers a couple of convenience buttons like “Clear all types” and “Reset to original”). In that container you can change types and comments of images as usual, and submit them all at once. The script takes care to just submit data which has really changed and also warns if no change are made at all.

You can get the script at GitHub - vzell/mb-userscripts under Batch Edit Cover Art

4 Likes

Harmony: Enhancements

Added two more modules.


You can enable them in the settings under the Release Data section:

4 Likes

Hi @chaban, could you add the following two lines to your “Batch remove cover art” script, to reload the image page after batch removing images.

@@ -591,6 +591,8 @@
             resetUI(isAborting);
             if (!isAborting) {
                 statusMessages.innerHTML += `<p>Batch removal complete. Processed ${completedRemovals} of ${totalRemovals} selected images.</p>`;
+                removeSelectedBtn.innerText = 'Finished! Reloading...';
+                setTimeout(() => window.location.reload(), 1000);
             }
         });

Why should the page be reloaded?

Personally I don’t like scripts or applications forcefully reloading a page after a successful action.There might be other things I want to do after or when I intend to close the tab the reload would just waste time and resources.

No problem, in my case it’s actually my personal preference (especially after removing images). But I can always edit it locally on my side.

I am editing concerts and tours at the moment and I want to upload the poster. But it is annoying to upload the same image one by one to each concert of the tour. Will it be possible to create a userscript to simplify this? I heard of the “click a button on many pages at one time” script or something like that.

I ask here because it looks like you are very experienced with userscripts.