[Lestrades.com] Nao 尚

  • I'm Share-Locked
  • Administrator
  • Posts: 1,292
  • Trades: 211
Re: What's up at Lestrade's?
« Reply #736,  »
NEW: Game trailers are now being shown on game pages, in HD (yay!)
Just click the preview image in the sidebar. (And yes, I pretty much reserved the sidebar for trailers long ago... Was just too lazy to get the app IDs for said trailers.)
The list is being generated right now, it'll be done in about a week, I estimate.

On Firefox and Webkit/Safari/Chrome, you'll get an animation when clicking the trailer preview.
On Opera (Blink), the animation was disabled because Opera shows a stupid 'detach' button that is drawn through the Shadow DOM, meaning I can't hide it.
On mobile browsers, the trailer window can't be moved.
On Firefox, you can move a trailer by dragging the black background below it. (Which is the main reason I have some text there.)
On all other browsers, you should be able to drag the entire video, including by clicking and dragging the video itself.
Click outside the video to close it.

It took me an entire day to build this, mostly because of the browser bugs mentioned above that forced me to try various things to fix them. (I failed, obviously. But it's better than nothing.)

Note that I'll eventually support trailers & images for all Steam games. I just need to finish my updated API scraper.

Akylen

  • Full Member
  • Posts: 194
  • Trades: 50

[Lestrades.com] Nao 尚

  • I'm Share-Locked
  • Administrator
  • Posts: 1,292
  • Trades: 211
Re: What's up at Lestrade's?
« Reply #738,  »
Thanks ;) Although I don't want to be 'better than the competition', I just want to be 'as good as I can be', if you understand what I mean. Just like the fact that Wedge[1] is 'the best I could hope for in a forum', rather than 'doing everything better than the competition'. (Maybe it does; I just don't care.)

NEW: Code was updated to support multiple videos playing at the same time. You can put them side to side if you wanna compare them or just watch them both at the same time, lol. I tested the changes extensively in Opera Blink and Firefox, and it works great. The new video will show up on top of the previous one, pausing it; you can move it, play the previous video and then compare. Or just ignore the previous video. Click on the 'pause' button on either of the video thumbnails to pause & hide its associated video. Note that pausing the video with the default controls won't change the thumbnail icon. I just thought it was more important to use that 'pause' icon as a way to track which videos are opened (which, when I'll end up having all videos for any given game, will be way more useful.)

Example (I can give you more links to games that have two videos): https://lestrades.com/game/96740/

Also note that the thumbnail icons look really fine and are animated. I actually wrote my own stuff and was unhappy with it on mobile, then found a real nice sample at CSS-Tricks that also had the added benefit of a morphing animation. Then I added a shadow filter, because box-shadows don't work on border tricks. (Which it is, really.)
This may not work on very old browsers, but who cares about IE8 anyway?
 1. The forum software I wrote, on which Lestrade's is based.[1]
 1. See? What other forums have nested footnotes out of the box?
Re: What's up at Lestrade's?
« Reply #739,  »
FIX (not important at all, though): Firefox 55 (a while ago!) added support for proper -moz-appearance: none on checkboxes, so I'm now using the Chrome path for Firefox 55+ and you should see proper styling on checkboxes now, rather than some weird JavaScript and CSS hack.

Akylen

  • Full Member
  • Posts: 194
  • Trades: 50
Re: What's up at Lestrade's?
« Reply #740,  »
IE  :wow:

Please do not get me wrong, I think Wedge is really fluid. However sometimes I get annoyed when I reply to a post and the result font is smaller than default or paragraphs have too much spacing. Something odd with the formatting. So I have to go back and change it for every paragraph. It happens frequently. Quick or full editor doesn't seem to make a difference. Using Chrome btw.

[Lestrades.com] Nao 尚

  • I'm Share-Locked
  • Administrator
  • Posts: 1,292
  • Trades: 211
Re: What's up at Lestrade's?
« Reply #741,  »
I don't care about IE. I only care about making the site work on it, doesn't have to look good.
I don't understand your issue... Are you using WYSYWYG mode, perchance? Either way, your post above is the exact same size as mine.
Posted: June 27th, 02:04 PM

FIX: On game pages with two videos, you can now click any of the videos to have it show up on top of the other one. Up until now, the first video in the list would always be behind the other ones, regardless of whether your clicked it first or last.
(Also fixed a JS error on some browsers.)

Akylen

  • Full Member
  • Posts: 194
  • Trades: 50

/u/humpaaa

  • Full Member
  • ▶ ¦ Yep
  • Posts: 186
  • Trades: 10
Re: What's up at Lestrade's?
« Reply #743,  »
The trailers look pretty cool. Especially that they are freely movable.
Are they added automatically to every game page?

[Lestrades.com] Nao 尚

  • I'm Share-Locked
  • Administrator
  • Posts: 1,292
  • Trades: 211
Re: What's up at Lestrade's?
« Reply #744,  »
Quote from /u/humpaaa on June 28th, 08:40 PM
Are they added automatically to every game page?
Yes, because BVG started making them 'public' (previously they were non-guests only and I didn't want to scrape it with a hack, gotta respect that).
If a video isn't online for a game, check back in a few days.
Also, at some point I'll switch to getting video URLs from the Steam API itself. I just need to finish that scraper. It's based on very old code I wrote in 2017 and was buggy. I made so many changes to my scrapers, I'm probably better off restarting from scratch or close to.
When I'm using the Steam API path, I'll be able to store all trailers for all games.
Re: What's up at Lestrade's?
« Reply #745,  »
Quote from /u/humpaaa on June 28th, 08:40 PM
The trailers look pretty cool. Especially that they are freely movable.
Note: while they are freely movable in Firefox as well, it has two limitations because it doesn't support mousedown and mousemove events on video tags. As I said, you can't move the video by dragging it, you have to drag the text below the video. And secondly, if you click on a video in the background to play it, it'll play, but it won't show on top of the previous video, you'll have to move the previous video aside. I could fix that one by putting the mousedown event on the bottom text as well, but... Well, man, it's a Firefox bug. I can't fix everything for them.

Also-- I fixed some game pages that used to have 2 videos and suddenly starting just having one again.
Re: What's up at Lestrade's?
« Reply #746,  »
NEW: Game pages will now list related entries using the same code path as generic game lists.
- If there are 10 entries or less in a related category, they'll be shown using a banner.
- If there are more, they'll be shown without a banner, so it'll look very similar to what it used to look like, with the addition of card counts and some details like current price.

PS: I'm open to showing the banners on a higher number of related entries.

:edit: Here's Portal 2, a very good example with all three categories, one of which has more than 10 entries. As you can see, it's very 'readable', and allows you to quickly find outdated products (i.e. the ones without a proper banner).

https://lestrades.com/game/456/
Re: What's up at Lestrade's?
« Reply #747,  »
NEW: Related items now show their own descriptions in game pages.
(limited to 250 chars on desktop browsers, and 100 chars on mobile browsers or when there are more than 100 items in that category.)

It sounds easy, but I had a real hard time debugging some of the visual alignments for these. Meh...
Re: What's up at Lestrade's?
« Reply #748,  »
Note: I've tested on mobile and there are issues. I'll have to work on them...
I don't know why I'm doing all of that. It's not triggering any interest... Dunno if I'm heading in the right direction.
Re: What's up at Lestrade's?
« Reply #749,  »
FIX: Tag pages had become too slow to load due to the current size of the database (which is four times than when I first wrote the website.) I've tweaked my tag sorting method to ensure I could now freely go through the most common tags (Action, Adventure...), which tended to crash the page.

Also, I added game descriptions on more game lists-- /tag/ pages, /games/ and so on. I tweaked my code to make it usable on mobile devices. Unfortunately, it also created issues with the vertical alignment of game titles when there's no associated description. I don't know whethere I should bother to fix that, though...