diff --git a/Shortcuts/README.md b/Shortcuts/README.md index ac85db5..c9a44e4 100644 --- a/Shortcuts/README.md +++ b/Shortcuts/README.md @@ -1,19 +1,15 @@ -# StadiaIcons Shortcuts BETA +# StadiaIcons Shortcuts + ## What is it? StadiaIcons Shortcuts is a system that leverages the power of Progressive Web Apps and some popup trickery to allow you to easily add individual Stadia game shortcuts to your computer in just a few clicks. And the best part is that each icon will automatically use StadiaIcons images! -As part of the Beta, you can access StadiaIcons Shortcuts through [temporary standalone page](https://stadiaicons.000webhostapp.com/) that will allow you to access each game's installation page directly. The end-goal is to eventually build this directly into Stadia using systems similar to [Stadia+](https://chrome.google.com/webstore/detail/stadia%20-extension/bbhmnnecicphphjamhdefpagipoegijd) or [Stadia Enhanced](https://chrome.google.com/webstore/detail/stadia-enhanced/ldeakaihfnkjmelifgmbmjlphdfncbfg). - -### BETA WARNING -This system is in **BETA**, and as such it is almost certainly *temporary*. It will eventually move it to a more stable platform or simply be integrated into existing extensions/userscripts by other developers. - -***Note:** If/when the service goes down, your shortcuts will open a window pointing you to whatever has replaced it instead of launching the game. At that point you'll simply have to uninstall each shortcut (I will include some basic instructions) and reinstall them using the new system(s).* +Currently, you can access StadiaIcons Shortcuts through a [temporary standalone page](https://stadiaicons.000webhostapp.com/) that will allow you to access each game's installation page directly. The end-goal is to build this directly into Stadia using systems similar to [Stadia+](https://chrome.google.com/webstore/detail/stadia%20-extension/bbhmnnecicphphjamhdefpagipoegijd) or [Stadia Enhanced](https://chrome.google.com/webstore/detail/stadia-enhanced/ldeakaihfnkjmelifgmbmjlphdfncbfg). ## How it Works StadiaIcons works by dynamically creating a unique webpage for each Stadia game with a StadiaIcons icon and letting you "install" this site as a Progressive Web App. This allows your device to launch the site directly from a custom shortcut; once launched, this site acts as a pass-through, opening a link to your game in a new tab and closing itself down right away. ### Requirements -StadiaIcons Shortcuts has currently only been tested on Windows 10 using the Chrome and Chromium Edge browsers. It may verry well function with other operating systems and/or browsers, but I have no means of testing this myself. +StadiaIcons Shortcuts has currently only been tested on Windows 10 using the Chrome and Chromium Edge browsers. Users have also reported that it works well on ChromeOS, though I do not have the means of testing it myself. ***Important:* In order to be able to open your game "transparently" when you use the shortcut, the system requires that you authorize the website site to display popups. There doesn't seem to be any way around this at this time.** @@ -28,60 +24,32 @@ Here are the steps to follow in order to "uninstall" a StadiaIcons Shortcut: The StadiaIcons Shortcuts system does not gather, track or store any of your information, it simply takes a game's unique ID and name and uses them to create a progressive web app that immediately redirects you to the game's Stadia link. # For Developers -The StadiaIcons Shortcuts Beta is more of a *proof of concept*, and my main objective is to make it available for other developers to use in their own projects. - -Of course, if you make use of this project, it would be cool if you can include a mention or maybe even a link to this GitHub project :wink:. - -In this folder, you will find all the code that is used to run the Beta site. Below, I will briefly explain what each file is used for, and how the system works. -## Basic Concept +## Using Links -The basic idea is that a single web page will be able to dynamically generate a functional Progressive Web App (PWA) using a specific URL structure: +This is the simplest way to use StadiaIcons Shortcuts: simply set up a link within your app/plugin/project that follows this structure: -https://yourdomain.com/`{uid}`/?fullName=`{title}`&uid=`{uid}`&shortName=`{short tite}`&alt=`{alt marker}`&variant=`{variant id}` +https://stadiaicons.web.app/`{uid}`/?fullName=`{title}`&shortName=`{short tite}`&alt=`{alt marker}`&variant=`{variant id}`&lang=`{language}` ***Parameters:*** * `{uid}`: The game's unique uid, which is found in the game's Stadia launch url and is used to identify it in the StadiaIcons [refs.json](/refs.json) reference sheet. -* `{title}`: The game's title. -* `{short tite}`: *(optional)* A shorter version of the title that will be used as the shortcut name in some cases (this can be useful with games that have huge titles that couldn't be displayed in most UIs). -* `{alt marker}`: *(optional)* If set to the `altSuffix` value found in the StadiaIcons [refs.json](/refs.json) reference sheet (`_alt` by default), the icon used for the PWA will not have the red filter. -* `{variant id}`: *(optional)* In the case where a game has multiple icon variants, this `int` value will be used to determine which version to use (defaults to `0`à. - -## Contents -### [index.php](index.php) -This is the main file that renders the PWA contents. - -Without going into too many details, there are 2 elements worth mentioning: -1. A lot of stuff is happening inside the `` tag; most of this boills down to gathering data based on the URL parameters and setting things up to form a valid PWA-enabled HTML file. -2. All the content that will be displayed to the end-user is found inside the various `
` tags and the lone `