training-kit icon indicating copy to clipboard operation
training-kit copied to clipboard

Feedback: Open Show Me How in new Tab

Open crichID opened this issue 9 years ago • 4 comments

👋 This user reached out on Twitter requesting that we add an easy way to open these GIFs in a new tab. The specific example they included definitely makes sense to me since embedded, I can't actually read what's happening in the GIF:

https://services.github.com/on-demand/windows/vs-make-commit

Tweets:

would be nice to be able to open animations in tutorials in a separate tab to see it enlarged w/o right click/open in new tab1/2

See here: http://bit.ly/2jfJRtk (Show me how section) 2/2

https://twitter.com/sfeldman/status/907099165771014146 https://twitter.com/sfeldman/status/907099267981967361

Maybe a 'show full size' button?

/cc @shawnajean thank you for keeping :eyes: on our community and passing this feedback along to us.

crichID avatar Sep 18 '17 12:09 crichID

Maybe a 'show full size' button?

@crichID I think this problem can be solved in one of two ways:

  1. I don't record gifs at 3840 x NotSmallResolution resulting in a larger screen to actually see what is happening.

  2. Adding a "full size button" as you suggested that just opens the gif in a new tab. For example the vs-make-commit gif looks like this when opened in a new tab: https://services.github.com/on-demand/images/gifs/windows/tfs-make-commit.gif

    • Technically a user could right click the image and open it in a new tab without us providing a "show me a big image" button, but, having the button makes for a better user experience.

beardofedu avatar Sep 18 '17 17:09 beardofedu

Could also wrap the GIF in an <a> tag:

<a href="path/to/gif" target="_blank"><img src="...gif" /></a>

If Jekyll causes problems with that approach, you can use JS to add in that functionality later:

document.querySelectorAll('img[src*=".gif"]').forEach(img => {
  img.addEventListener('click', (e) => {
    window.open(e.target.src, '_blank');
  }
});

I would also suggest some kind of visual hint for discoverability; a commonly used icon for something that will open in a new tab/window is the link-external octicon that could be layed over the GIF with some opacity.

JasonEtco avatar Sep 18 '17 17:09 JasonEtco

Adding a "full size button" as you suggested that just opens the gif in a new tab.

@beardofedu FYI, this was the recommendation from the user on Twitter --- it was passed along to us as an idea but we should certainly consider all options :wink:

crichID avatar Sep 18 '17 21:09 crichID

@crichID Oh, I think a full size button or the octicon that @JasonEtco suggested are defintely a potential solution to the problem, I was really just focusing on the bad gif that I created for the course using such a large resolution. Apologies for not being more clear about that, was trying to quickly add some 💭 s on the matter before jumping on a plane and didn't provide enough context. 🙇

beardofedu avatar Sep 19 '17 02:09 beardofedu