 |
 |
 |
[Script] Gallery List Helper, API information, tag buttons, gallery blacklisting, display fixes, and more |
|
Dec 9 2016, 11:26
|
Superlatanium
Group: Gold Star Club
Posts: 7,593
Joined: 27-November 13

|
This is something I wrote a while ago to make my vigilante cleanup work easier, but it can be helpful for anyone who wants a better UI on the search results pages.
Gallery_List_Helper_1.2.6.user.js.txt ( 22.5k )
Number of downloads: 9368The short version: This script changes your search results to look something like this  or this  This is extremely useful for both renamers and taggers. (Learn to tag accurately using this. Make renaming much easier by using this ( info)) The long version: There are a bunch of moderate display tweaks as well: - Gallery rows now reach across the whole page, allowing you to see much more useful information
- Automatically focuses the search box so you can start typing immediately
- Removes "new" icons and normalizes the starting X-position of each gallery title
- Adds padding before gallery titles allowing for much easier copying
- Visited links are colored green, so you know what you've visited before
- Lets you right-click other search result pages so you can more easily Open Link In New Tab or something similar
- Gallery filecount has been added to the "Published" column
To get the most out of this script, you have to customize it depending on your gallery and vigilante habits; sure, you can just install and forget about it, but that's not the best use of the script. Paging Enlargement is highly recommended for more tag button results, but especially for if you want to do an advanced search within results using the blacklist, in which case <25 galleries/page is often not enough. If you don't like some of the display changes, feel free to delete the appropriate section from the script. I made all of the changes because I liked them, but I know not everyone will think the same. There are comments before every major section so it should be pretty obvious. Only works in List display mode. The main point of the script is to increase information density, after all. Works in at least Firefox (use [ www.greasespot.net] Greasemonkey) and Chrome (use [ tampermonkey.net] Tampermonkey). Please tell me if you encounter any bugs, and feel free to ask if you want the script to display (or hide) something but aren't sure how (don't worry, it's almost always very easy). This post has been edited by Superlatanium: Feb 20 2018, 08:57
|
|
|
|
 |
|
Dec 9 2016, 23:52
|
Simpleton8
Group: Members
Posts: 336
Joined: 2-November 15

|
Works great. Thanks. 1) Doesn't work in Fjords? Not just simply adding @include fjord 2) I really like having the tables with the + or - for different tags in order of the number of the galleries. It is also nice information if we want to know the tags associated with specific authors and/or other tags. 3) Considering supporting thumbnail views in the future (or just the tables)? I remembered using a script that display the tags on top of the gallery thumbnails. 4) Perhaps add tables added to the highlighter scripts or vice versa (if that's fine with you) to minimize the number of api calls (?). If I do it, I would add you to the credits. (IMG:[ invalid] style_emoticons/default/smile.gif) -- 5) Doesn't remove existing tags by pressing "-" (e.g., ends up looking like group:"kinokonabe hinanjo$" -group:"kinokonabe hinanjo$" instead of just "-group:"kinokonabe hinanjo$") This post has been edited by Simpleton8: Dec 9 2016, 23:59
|
|
|
|
 |
|
Dec 12 2016, 04:01
|
blue penguin
Group: Gold Star Club
Posts: 10,046
Joined: 24-March 12

|
I really like the API/tag display part. 'tis good stuff! Added to the index. QUOTE(Simpleton8 @ Dec 9 2016, 21:52)  1) Doesn't work in Fjords? Not just simply adding @include fjord Oh, come one, you can figure that one out. Took me 15 seconds (IMG:[ invalid] style_emoticons/default/smile.gif) (although an all caps parameter could be added to the top, e.g. API_URL = 'http:/g.e-hentai.org/api.php')
|
|
|
|
 |
|
Jan 21 2017, 13:14
|
prescott L G
Newcomer
 Group: Members
Posts: 49
Joined: 18-January 09

|
QUOTE(blue penguin @ Dec 11 2016, 20:01)  Oh, come one, you can figure that one out. Took me 15 seconds (IMG:[ invalid] style_emoticons/default/smile.gif) (although an all caps parameter could be added to the top, e.g. API_URL = 'http:/g.e-hentai.org/api.php') I tried adding all the expunged gallerie's .org links to the scripts "Include Section" but it still won't work!? What did you do, to get it to work? This post has been edited by prescott L G: Jan 24 2017, 12:38
|
|
|
|
 |
|
Jan 23 2017, 16:16
|
Simpleton8
Group: Members
Posts: 336
Joined: 2-November 15

|
QUOTE(prescott L G @ Jan 21 2017, 13:14)  I tried adding all the expunged gallerie's .org links to the scripts "Include Section" but it still won't work!? What did you do, to get it to work?
Essentially what I did. Then I realized I wasn't using list mode. (IMG:[ invalid] style_emoticons/default/wink.gif) Just c/p the @include lines and changed one character of each url to fjord's.
|
|
|
Jan 24 2017, 04:26
|
prescott L G
Newcomer
 Group: Members
Posts: 49
Joined: 18-January 09

|
Even when I have it in List Mode, it still doesn't show up!? Its there on the normal galleries though?
|
|
|
Jan 25 2017, 04:31
|
prescott L G
Newcomer
 Group: Members
Posts: 49
Joined: 18-January 09

|
Nevermind, I figured out why it wasn't working anymore. I think it was because I had "allow paste" still in the script. It works now! (IMG:[ invalid] style_emoticons/default/tongue.gif) This post has been edited by prescott L G: Jan 25 2017, 04:32
|
|
|
Jan 26 2017, 10:59
|
prescott L G
Newcomer
 Group: Members
Posts: 49
Joined: 18-January 09

|
Question: When it's on Thumbnail mode, the galleries are moved to the Left side, instead of Centered on the page. What do I edit to have them Centered?
|
|
|
|
 |
|
Jan 26 2017, 11:46
|
Superlatanium
Group: Gold Star Club
Posts: 7,593
Joined: 27-November 13

|
It was never designed for thumbnail mode, it's meant for list mode only. Though, adding basic functionality for thumbnail mode wouldn't be hard (adding the tag buttons). Maybe someone who knows more about CSS could do it more easily than me, but here's what you could add after the "Autofocuses the search box" section to center the thumbnails: CODE if (document.getElementById('dmi').children[0].textContent == 'Thumbnails'){ function fix(c){ var elm = document.getElementsByClassName(c)[0]; elm.style.maxWidth = '100%'; elm.style.textAlign = 'center'; } fix('itg'); fix('ido'); [].forEach.call(document.getElementsByClassName('id1'), function(id1){ id1.style.float = 'none'; id1.style.display = 'inline-block'; id1.style.height = '335px'; id1.children[1].style.height = '280px'; }); return; }
|
|
|
|
 |
|
Jan 26 2017, 12:33
|
TeaAndBiscuits
Newcomer
 Group: Gold Star Club
Posts: 46
Joined: 19-October 13

|
For simple CSS, add this line to the top of the script (or after the autofocus, as above): CODE document.head.appendChild(document.createElement("STYLE")).innerHTML = "div.itg{text-align:center}div.id1{float:none;display:inline-block}"; It'll leave an arbitrary number on the bottom row based on your screen size. To have the normal thumbnails, use this instead: CODE if (document.getElementById("dmi").children[0].textContent === "Thumbnails"){ document.head.appendChild(document.createElement("STYLE")).innerHTML = "div.ido{max-width:1200px!important}div.itg{max-width:1175px!important}"; } This post has been edited by TeaAndBiscuits: Jan 26 2017, 12:33
|
|
|
Jan 30 2017, 09:40
|
prescott L G
Newcomer
 Group: Members
Posts: 49
Joined: 18-January 09

|
Removed
This post has been edited by prescott L G: Apr 10 2017, 15:36
|
|
|
Feb 15 2017, 08:34
|
lolatyoutoo
Newcomer
 Group: Members
Posts: 31
Joined: 3-March 12

|
Thanks again for the script, I modified the styles a bit to make tag distinction clearer (as well as making it look better overall imo (IMG:[ invalid] style_emoticons/default/tongue.gif) ) 
Gallery_List_Helper.user.js.txt ( 21.9k )
Number of downloads: 167This post has been edited by lolatyoutoo: Feb 15 2017, 08:35
|
|
|
Mar 19 2017, 05:01
|
Hyoros
Group: Members
Posts: 443
Joined: 24-September 12

|
Thank you Superlatanium. It works for me. This will really be helpful for me in future. Now few questions. I found this from other forum where you said your script can search gallery based on gallery size. How do I do this? Also these -R- on right side. Are they suppose to make a gallery disappear from sight?
|
|
|
|
 |
|
Apr 14 2017, 20:28
|
Superlatanium
Group: Gold Star Club
Posts: 7,593
Joined: 27-November 13

|
QUOTE(Hyoros @ Mar 19 2017, 03:01)  Thank you Superlatanium. It works for me. This will really be helpful for me in future. Now few questions. I found this from other forum where you said your script can search gallery based on gallery size. How do I do this? Also these -R- on right side. Are they suppose to make a gallery disappear from sight? Sorry for late reply, last bump was over 30 days ago so it fell off of my subscribed threads list. Yes, the R lets you remove rows. (occasionally useful for me when I'm looking at many versions of a similar gallery and want to only pay attention to a select few of them - for example) You can filter by gallery size with a line similar to the following, in testHide function: CODE if (metadata.filesize < 50000) return true; (This will hide all galleries smaller than 50 MB or so)
|
|
|
|
 |
|
May 1 2017, 03:31
|
Hyoros
Group: Members
Posts: 443
Joined: 24-September 12

|
I tried. Script works but I can still see galleries which size is over 50mb. Which lines do I have to remove? CODE //Hides a gallery from all search results if it "returns true" on one of the following tests. //See full explanation of metadata info at https://ehwiki.org/wiki/API //Please customize. This allows for much greater search flexibility, especially in combination with Paging Enlargement perk. function testHide(metadata){ //examples: //if (metadata.tags.indexOf('group') == -1) //return true; if (metadata.filesize < 50000) return true; -I omitted other examples here for this post- /* var found = false; metadata.tags.forEach(function(tag){ //if (/parody\:dragon\squest\s/.test(tag)) //if (/^male/.test(tag)) found = true; }); if (!found) return true; */ }
Thank you for quick reply. I saw your reply for a while but I can't find time to test it. This post has been edited by Hyoros: May 20 2017, 02:52
|
|
|
|
 |
|
May 1 2017, 03:58
|
Superlatanium
Group: Gold Star Club
Posts: 7,593
Joined: 27-November 13

|
https://ehwiki.org/wiki/API50000 is quite small. Eg https://e-hentai.org/g/618395/0439fa3666/, ordinary size doujin, has 51210504 filesize, or 48.84 MB. Also, "return true" in that function means that galleries that pass the condition will be hidden. So you'd want something more along the lines of CODE if (metadata.filesize > 50000000) return true; To make it more intuitive, you can change the section to something like this: CODE function testHide(metadata){ var hide = false; if (metadata.filesize > 50000000) hide = true; //other stuff... //other stuff... return hide; }
|
|
|
|
 |
|
May 24 2017, 15:42
|
exisence
Group: Members
Posts: 285
Joined: 18-January 13

|
I was just looking for something to customize search results. Thanks Superlatanium. But i have a question. Would it be possible to include favcount like fc next to date? Or simply hide posts based on favcount? I checked wiki/api and there is no favcount there. That's probably why it does not simply work. I saw this AgentLillian post which points that it should be possible to do something with favcount.
|
|
|
|
 |
|
May 25 2017, 04:16
|
Superlatanium
Group: Gold Star Club
Posts: 7,593
Joined: 27-November 13

|
QUOTE(exisence @ May 24 2017, 13:42)  I was just looking for something to customize search results. Thanks Superlatanium. But i have a question. Would it be possible to include favcount like fc next to date? Or simply hide posts based on favcount? I checked wiki/api and there is no favcount there. That's probably why it does not simply work. I saw this AgentLillian post which points that it should be possible to do something with favcount. I asked Luna what he meant but neither of us know a way to get gallery favcount without navigating to each gallery individually, unfortunately (which would be way too hard on the servers for the information it provides).
|
|
|
|
 |
|
Feb 11 2018, 09:54
|
ALL_MIGHT
Group: Gold Star Club
Posts: 1,548
Joined: 14-October 16

|
Hi, I Just installed it (did not make any changes to default script), but i am not able to use + and - options. whenever i click them nothing happens and in console these errors gets generated Screenshot is  Do i have to make some changes in script to use them? If yes, how can i add my desired tag in them. (I am total dumb when it comes to scripts) thanks (IMG:[ invalid] style_emoticons/default/biggrin.gif) This post has been edited by ALL_MIGHT: Feb 11 2018, 10:00
|
|
|
Feb 11 2018, 10:32
|
Superlatanium
Group: Gold Star Club
Posts: 7,593
Joined: 27-November 13

|
Not your fault, the recent update broke it, should be fixed now in the version I just posted. (IMG:[ invalid] style_emoticons/default/smile.gif)
|
|
|
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:
|
 |
 |
 |
|