SGPP icon indicating copy to clipboard operation
SGPP copied to clipboard

Advanced filters

Open Enissay opened this issue 10 years ago • 11 comments

Mainly filter by levels... That would be greatly helpful :)

Enissay avatar Feb 19 '15 19:02 Enissay

+ The possibility of blacklisting a game from inside it's giveaway page...

Enissay avatar Feb 23 '15 15:02 Enissay

Hey sorry, yes, we are interested in doing such things, but we need to wait till Endless Scroll is able to inform whether new giveaways are added. That will makes things much smoother and easier to implement.

leomoty avatar Feb 23 '15 15:02 leomoty

@leomoty: I'm working on it. :)

nikop avatar Feb 23 '15 15:02 nikop

Forgot to add a follow up on this, we just need someone to create the filters now, since @nikop already created the events to make it possible.

leomoty avatar Mar 03 '15 10:03 leomoty

  • Also when you blacklist a game, the page auto-reloads, and it take a while to find where you were :> (nth page in Endless Scroll), it would be great if you make that optional (reload or not) or even make it come back to the same page after the reaload

Enissay avatar Mar 14 '15 14:03 Enissay

Should ping @nikop about this one.

2015-03-14 11:26 GMT-03:00 Enissay [email protected]:

  • Also when you blacklist a game, the page auto-reloads, and it take a while to find where you were :> (nth page in Endless Scroll), it would be great if you make that optional (reload or not) or even make it come back to the same page after the reaload

— Reply to this email directly or view it on GitHub https://github.com/leomoty/SGPP/issues/80#issuecomment-80507767.

leomoty avatar Mar 14 '15 15:03 leomoty

I made a little script with greasemonkey (adding colors to interesting games for me, remove others, filtering, ...) but I guess it confilcted SGPP since for example I cant no more blacklist a game :<

Anyway, I told myself why not help you move ahead instead of making my own script... I have some basic-medium experience with js-jQuery-Dom (No ts thought !), so maybe If you gimme some tasks (im a beginner at collaborative projects), i'll be glad to help...

@nikop @leomoty

Enissay avatar Mar 28 '15 14:03 Enissay

Sure, add me on steam @Enissay

leomoty avatar Mar 28 '15 20:03 leomoty

Should we add base module for giveaway filters?

Currently I have all code filtering in MarkOwnedGames. This isn't best solution, but it works.

https://github.com/leomoty/SGPP/blob/beta/SGPP/Modules/MarkOwnedGames.ts

  1. We ensure it gets initiated first
  2. Maybe provide function to call other modules (not needed, but would allow cleaner code).

Would return true on success and false on failure. No warnings, since modules may provide other features too.

  1. Modules that want to add filters calls base module which handles filtering.

[BaseFilter instance].addFilter(filter|array of filter) for registering

Filter provided could be class that provides:

shouldHide() -> boolean if giveaway will be hidden. render(element) -> Render element (that provides tool for changing filters settings) setState(state) -> sets state from previous event stateChanged -> for saving state when changed (if enabled?)

nikop avatar Apr 16 '15 12:04 nikop

Pull request #95 contains first version.

nikop avatar Apr 22 '15 12:04 nikop

Initial version of filtering framework merged to beta branch.

nikop avatar May 24 '15 19:05 nikop