Initial Release
This commit is contained in:
@@ -0,0 +1,57 @@
|
||||
<article
|
||||
id="applications"
|
||||
authorId=""
|
||||
categoryId="api"
|
||||
title="Applications"
|
||||
created="500"
|
||||
snippet="Developer documentation for Applications"
|
||||
banner=""
|
||||
noindex="false"
|
||||
>
|
||||
<header>Introduction</header>
|
||||
<text>
|
||||
Applications allow you to integrate the suzzy API into your projects.
|
||||
You can create and manage them while in the <a href='/profile/applications'>Applications</a>
|
||||
section of your profile.
|
||||
</text>
|
||||
|
||||
<subheader>Application Object</subheader>
|
||||
<table>
|
||||
<row>
|
||||
<column>Field</column>
|
||||
<column>Type</column>
|
||||
<column>Description</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>id</column>
|
||||
<column>integer</column>
|
||||
<column>Unique Application ID</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>created</column>
|
||||
<column>Date</column>
|
||||
<column>ISO Timestamp of when application was created</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>flags</column>
|
||||
<column>integer</column>
|
||||
<column>the application's public flags</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>name</column>
|
||||
<column>string</column>
|
||||
<column>the application's name</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>description</column>
|
||||
<column>string?</column>
|
||||
<column>the application's description</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>icon</column>
|
||||
<column>string?</column>
|
||||
<column>the application's image hash</column>
|
||||
</row>
|
||||
</table>
|
||||
|
||||
</article>
|
||||
@@ -0,0 +1,23 @@
|
||||
<article
|
||||
id="changelog"
|
||||
authorId=""
|
||||
categoryId="api"
|
||||
title="Changelog"
|
||||
created="-1"
|
||||
snippet="Changelog for suzzy APIs and Services"
|
||||
banner=""
|
||||
noindex="false"
|
||||
>
|
||||
<header>Notices</header>
|
||||
<text>Important and Breaking changes will be listed below:</text>
|
||||
<list>
|
||||
<item>Nothing to report!</item>
|
||||
</list>
|
||||
<header>History</header>
|
||||
<subheader>Initial Release</subheader>
|
||||
<quote>Date: May 12th 2024</quote>
|
||||
<list>
|
||||
<item>Applications are now generally available</item>
|
||||
<item>suzzy Library now available</item>
|
||||
</list>
|
||||
</article>
|
||||
@@ -0,0 +1,155 @@
|
||||
<article
|
||||
id="oauth2"
|
||||
authorId=""
|
||||
categoryId="api"
|
||||
title="OAuth2"
|
||||
created="400"
|
||||
snippet="Developer documentation for OAuth2"
|
||||
banner=""
|
||||
noindex="false"
|
||||
>
|
||||
<header>Resources</header>
|
||||
<text>
|
||||
suzzy games provides support for OAuth2 allowing applications to
|
||||
use the API for authorization and retrieval of user data.
|
||||
</text>
|
||||
<text>
|
||||
It is recommended you
|
||||
<a href="/library/api/tutorials#creating-an-application">Create an Application</a>
|
||||
and store the given
|
||||
<c>CLIENT_ID</c> and
|
||||
<c>CLIENT_SECRET</c> for later use.
|
||||
</text>
|
||||
<subheader>OAuth2 URLs</subheader>
|
||||
<table>
|
||||
<row>
|
||||
<column>URL</column>
|
||||
<column>Description</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>https://suzzygames.com/oauth2</column>
|
||||
<column>Base Authorization URL</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>https://apis.suzzygames.com/v1/oauth2/token</column>
|
||||
<column>Token URL</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>https://apis.suzzygames.com/v1/oauth2/token/revoke</column>
|
||||
<column>Token Revocation URL</column>
|
||||
</row>
|
||||
</table>
|
||||
<quote>These endpoints will only accept the content type "application/x-www-form-urlencoded"</quote>
|
||||
<subheader>OAuth2 Scopes</subheader>
|
||||
<text>
|
||||
A list of available scopes, some endpoints will return fields with a
|
||||
<c>null</c> value or return an error if a required scope is unavailable.
|
||||
</text>
|
||||
<table>
|
||||
<row>
|
||||
<column>Name</column>
|
||||
<column>Description</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>identify</column>
|
||||
<column>Allows access to /users/@me endpoint</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>email</column>
|
||||
<column>Allows /users/@me endpoint to return the user's email</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>connections</column>
|
||||
<column>Allows access to /users/@me/applications endpoint</column>
|
||||
</row>
|
||||
</table>
|
||||
|
||||
<!-- OAuth2 User Flow -->
|
||||
<header>Authorization Code Grant</header>
|
||||
<text>
|
||||
This is most commonly known as <b>standard OAuth2</b>, where the user
|
||||
follows an Authorization Flow in return for an access code which the
|
||||
application can exchange for the user's access token.
|
||||
</text>
|
||||
<quote>
|
||||
All endpoints expect HTTP Basic Auth using your applications
|
||||
CLIENT_ID as the username and CLIENT_SECRET as the password
|
||||
</quote>
|
||||
|
||||
<subheader>Example Authorization URL</subheader>
|
||||
<code syntax="skip">
|
||||
https://suzzygames.com/oauth2?response_type=code&redirect_uri=https%3A%2F%2Fexample.org&client_id=1273&redirect_uri=https%3A%2F%2Fexample.org&scope=identify%20email&state=1734831153572
|
||||
</code>
|
||||
<text>- <c>response_type</c> must always be code, as it is currently the only supported type.</text>
|
||||
<text>- <c>redirect_uri</c> is one of the Redirect URIs set in your application settings, url encoded.</text>
|
||||
<text>- <c>client_id</c> is your Application ID. </text>
|
||||
<text>- <c>scope</c> is a list of <a href="#oauth2-scopes">OAuth2 Scopes</a> delimited by url encoded spaces <c>(%20)</c>.</text>
|
||||
<text>- <c>state</c> is a unique string that will be returned if set.</text>
|
||||
|
||||
<subheader>Example Redirect URL</subheader>
|
||||
<code syntax="skip">
|
||||
https://example.org?code=9AED9A46641F3E3F489523C643C177BB.oboQpOkOSQJvdYYa4WuPq8J3TaYqNgylfq97sa99DRk&state=1734831153572
|
||||
</code>
|
||||
<text>
|
||||
The <c>code</c> can now be exchanged for a user's access token by
|
||||
making a POST request to the <a href="#oauth2-urls">Token URL</a>
|
||||
with the following parameters:
|
||||
</text>
|
||||
<text>- <c>code</c> - parameter taken from the query string</text>
|
||||
<text>- <c>grant_type</c> - value must be <c>authorization_code</c></text>
|
||||
<text>- <c>redirect_uri</c> - the <c>redirect_uri</c> from the authorization url</text>
|
||||
<text>In response you will be bestowed an <a href="#access-token-response">Access Token Response</a></text>
|
||||
|
||||
<subheader>Access Token Response</subheader>
|
||||
<table>
|
||||
<row>
|
||||
<column>Name</column>
|
||||
<column>Type</column>
|
||||
<column>Description</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>access_token</column>
|
||||
<column>string</column>
|
||||
<column>Token to include in authorization header</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>token_type</column>
|
||||
<column>string</column>
|
||||
<column>String to prepend to token in authorization header</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>expires_in</column>
|
||||
<column>number</column>
|
||||
<column>Seconds until access token expires</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>refresh_token</column>
|
||||
<column>string</column>
|
||||
<column>Token to submit when making a refresh request</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>scope</column>
|
||||
<column>string</column>
|
||||
<column>The relevant OAuth2 Scopes for this token (delimited with a space)</column>
|
||||
</row>
|
||||
</table>
|
||||
|
||||
<subheader>Refreshing Access Token</subheader>
|
||||
<text>
|
||||
Once an access token has expired you may refresh it by making a
|
||||
POST request to the <a href="#oauth2-urls">Token URL</a> with
|
||||
the following parameters:
|
||||
</text>
|
||||
<text>- <c>grant_type</c> - value must be <c>refresh_token</c></text>
|
||||
<text>- <c>refresh_token</c> - the user's refresh token</text>
|
||||
<text>In response you will be bestowed a fresh <a href="#access-token-response">Access Token Response</a></text>
|
||||
|
||||
<subheader>Revoking Access Token</subheader>
|
||||
<text>
|
||||
You can revoke an access token by making a POST request to the
|
||||
<a href="#oauth2-urls">Token Revocation URL</a> with the following
|
||||
parameters:
|
||||
</text>
|
||||
<text>- <c>token</c> - the user's access token or refresh token</text>
|
||||
|
||||
</article>
|
||||
@@ -0,0 +1,108 @@
|
||||
<article
|
||||
id="reference"
|
||||
authorId=""
|
||||
categoryId="api"
|
||||
title="Reference"
|
||||
created="100"
|
||||
snippet="References for suzzy APIs and Services"
|
||||
banner=""
|
||||
noindex="false"
|
||||
>
|
||||
<!-- Server URLs -->
|
||||
<header>Sending Requests</header>
|
||||
<text>
|
||||
All requests to the api should be made to the following URL: <c>https://apis.suzzygames.com/v1/</c>
|
||||
</text>
|
||||
|
||||
<!-- Server Ratelimiting -->
|
||||
<header>Ratelimiting</header>
|
||||
<text>
|
||||
Each response will include headers related to ratelimiting, follow them otherwise
|
||||
the server will automatically reject your request and respond with a
|
||||
<c>429 Too Many Requests</c> error.
|
||||
</text>
|
||||
<table>
|
||||
<row>
|
||||
<column>Header</column>
|
||||
<column>Description</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>RateLimit-Limit</column>
|
||||
<column>Request Quota</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>RateLimit-Remaining</column>
|
||||
<column>Requests Remaining</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>RateLimit-Reset</column>
|
||||
<column>Float seconds until Quota Resets</column>
|
||||
</row>
|
||||
</table>
|
||||
<quote>
|
||||
Sending too many bad requests too quickly will result in your IP Address
|
||||
being blocked temporarily.
|
||||
</quote>
|
||||
<quote>
|
||||
Frequent abusers will get the ban hammer!
|
||||
</quote>
|
||||
|
||||
<!-- User Assets -->
|
||||
<header>Content URLs</header>
|
||||
<text>
|
||||
User Uploads <h>(Avatars, Banners, etc.)</h> are available at
|
||||
<c>https://content.suzzygames.com/</c> using the following paths:
|
||||
</text>
|
||||
<table>
|
||||
<row>
|
||||
<column>Name</column>
|
||||
<column>Path</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>User Avatars</column>
|
||||
<column>/avatars/{user.id}/{user.avatar}/{extension}/{size}</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>User Banners</column>
|
||||
<column>/banners/{user.id}/{user.banner}/{extension}/{size}</column>
|
||||
</row>
|
||||
</table>
|
||||
<quote>Image Sizes: Large (192px), Medium (96px), Small (48px)</quote>
|
||||
<quote>Image Extensions: webp, png, gif (if animated)</quote>
|
||||
<quote>Animated images will have their hash begin with "a_"</quote>
|
||||
|
||||
<!-- User Default Assets -->
|
||||
<header>Default Assets</header>
|
||||
<text>
|
||||
Ocasionally users won't have uploaded an avatar, you can use the provided
|
||||
default ones by calculating the index with <c>index = {user.id} % 6</c> and using the follow URL:
|
||||
</text>
|
||||
<text>
|
||||
<c>https://suzzygames.com/assets/images/default-user{index}.png</c>
|
||||
</text>
|
||||
<quote>Signed out users use "default-anon.png" instead</quote>
|
||||
|
||||
<subheader>Default Colors</subheader>
|
||||
<text>
|
||||
Default colors for user profiles are available below:
|
||||
</text>
|
||||
<table>
|
||||
<row>
|
||||
<column>Name</column>
|
||||
<column>Color (Hex)</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>Profile Banner</column>
|
||||
<column>#1D1E2E</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>Profile Background</column>
|
||||
<column>#333550</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>Profile Border</column>
|
||||
<column>#282A3F</column>
|
||||
</row>
|
||||
</table>
|
||||
|
||||
</article>
|
||||
@@ -0,0 +1,28 @@
|
||||
<article
|
||||
id="tutorials"
|
||||
authorId=""
|
||||
categoryId="api"
|
||||
title="Tutorials"
|
||||
created="200"
|
||||
snippet="Simple tutorials on certain things."
|
||||
banner=""
|
||||
noindex="false"
|
||||
>
|
||||
<header>Creating an Application</header>
|
||||
<text>
|
||||
You can create an application using the <a href="https://suzzygames.com/account/applications">My Applications</a>
|
||||
page in the account management portal. Ensure your application has a
|
||||
memorable name and that you keep its secret key secure and private.
|
||||
</text>
|
||||
<image
|
||||
alt="Click on the Create Application Button"
|
||||
caption="Click on the Create Application Button"
|
||||
resource="file://library/tutorials/applications-step-1.png"
|
||||
/>
|
||||
<image
|
||||
alt="You can then edit your Application by clicking on the Edit Button"
|
||||
caption="You can then edit your Application by clicking on the Edit Button"
|
||||
resource="file://library/tutorials/applications-step-2.png"
|
||||
/>
|
||||
<!-- TODO: IMPROVE OAUTH2 TUTORIAL -->
|
||||
</article>
|
||||
@@ -0,0 +1,212 @@
|
||||
<article
|
||||
id="users"
|
||||
authorId=""
|
||||
categoryId="api"
|
||||
title="Users"
|
||||
created="300"
|
||||
snippet="Developer documentation for Users"
|
||||
banner=""
|
||||
noindex="false"
|
||||
>
|
||||
<!-- User Object Reference -->
|
||||
<header>User Object</header>
|
||||
<text>
|
||||
Fields for a user object and the required oAuth2 Scope to view them.
|
||||
Optional fields <h>(Type ending with ?)</h> or hidden fields <h>(Missing oAuth2 Scope)</h>
|
||||
will have their value set as <c>null</c> instead.
|
||||
</text>
|
||||
<table>
|
||||
<row>
|
||||
<column>Field</column>
|
||||
<column>Type</column>
|
||||
<column>Description</column>
|
||||
<column>Required oAuth2 Scope</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>id</column>
|
||||
<column>integer</column>
|
||||
<column>their unique account id</column>
|
||||
<column>identify</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>created</column>
|
||||
<column>timestamp</column>
|
||||
<column>their account creation timestamp</column>
|
||||
<column>identify</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>public_flags</column>
|
||||
<column>integer</column>
|
||||
<column>their public flags (badges)</column>
|
||||
<column>identify</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>username</column>
|
||||
<column>string</column>
|
||||
<column>their username</column>
|
||||
<column>identify</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>displayname</column>
|
||||
<column>string</column>
|
||||
<column>their displayname</column>
|
||||
<column>identify</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>subtitle</column>
|
||||
<column>string</column>
|
||||
<column>their pronouns, status, etc.</column>
|
||||
<column>identify</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>biography</column>
|
||||
<column>string</column>
|
||||
<column>their biography</column>
|
||||
<column>identify</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>accent_background</column>
|
||||
<column>integer</column>
|
||||
<column>their profile background color</column>
|
||||
<column>identify</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>accent_banner</column>
|
||||
<column>integer</column>
|
||||
<column>their profile banner color</column>
|
||||
<column>identify</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>accent_border</column>
|
||||
<column>integer</column>
|
||||
<column>their profile border color</column>
|
||||
<column>identify</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>avatar</column>
|
||||
<column>string?</column>
|
||||
<column>their avatar image hash</column>
|
||||
<column>identify</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>banner</column>
|
||||
<column>string?</column>
|
||||
<column>their banner image hash</column>
|
||||
<column>identify</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>verified</column>
|
||||
<column>boolean</column>
|
||||
<column>has email been verified?</column>
|
||||
<column>identify</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>email</column>
|
||||
<column>string?</column>
|
||||
<column>their email address</column>
|
||||
<column>email</column>
|
||||
</row>
|
||||
</table>
|
||||
<quote>Usernames will always be alphanumeric with underscores and between 3-32 characters long</quote>
|
||||
<quote>Usernames may change without warning, use account IDs instead!</quote>
|
||||
<quote>Displaynames and Subtitles are up to 32 characters long</quote>
|
||||
<quote>Biographies are up to 320 chracters long</quote>
|
||||
<quote>Colors are in Decimal Representation</quote>
|
||||
|
||||
<!-- User Public Flags/Badges -->
|
||||
<header>Public Flags</header>
|
||||
<text>
|
||||
Use a <b>Bitwise AND</b> operation in your language of choice to see if a flag is
|
||||
set for a user. Flags are primarily used for badges which are special achievements
|
||||
that were obtainable for a limited time or gifted to specific users.
|
||||
</text>
|
||||
<table>
|
||||
<row>
|
||||
<column>Value</column>
|
||||
<column>Name</column>
|
||||
<column>Description</column>
|
||||
<column>Obtainable?</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>1 (1 << 0)</column>
|
||||
<column>BADGE_CROWN</column>
|
||||
<column>Reserved for bakonpancakz</column>
|
||||
<column>Never</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>2 (1 << 1)</column>
|
||||
<column>BADGE_VIP</column>
|
||||
<column>Reserved for important users</column>
|
||||
<column>No</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>4 (1 << 2)</column>
|
||||
<column>BADGE_PICROSS</column>
|
||||
<column>Awarded by completing Challenge #1</column>
|
||||
<column>Yes</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>8 (1 << 3)</column>
|
||||
<column>PUBLIC_UNAVAILABLE</column>
|
||||
<column>Account is Unavailable</column>
|
||||
<column>TOS Violation</column>
|
||||
</row>
|
||||
</table>
|
||||
<quote>
|
||||
Unavailable accounts, may be banned or deleted.
|
||||
The reasoning will be sent to the account owners email.
|
||||
</quote>
|
||||
|
||||
<!-- GET /users/@me -->
|
||||
<header>Get Current User</header>
|
||||
<text><c>GET /users/@me</c></text>
|
||||
<text>
|
||||
Returns the current user if you have the <c>identify</c> scope, also
|
||||
returns email if you also have the <c>email</c> scope.
|
||||
</text>
|
||||
|
||||
<!-- GET /users/@me/connections -->
|
||||
<header>Get Connections for Current User</header>
|
||||
<text><c>GET /users/@me/connections</c></text>
|
||||
<text>
|
||||
Requires the <c>connections</c> <a href='/library/api/oauth2#oauth2-scopes'>OAuth2 Scope</a>.
|
||||
Returns an array of <a href="#connection-object">Connection</a> Objects the user is actively connected to.
|
||||
</text>
|
||||
<subheader>Connection Object</subheader>
|
||||
<table>
|
||||
<row>
|
||||
<column>Field</column>
|
||||
<column>Type</column>
|
||||
<column>Description</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>id</column>
|
||||
<column>integer</column>
|
||||
<column>Unique Connection ID</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>created</column>
|
||||
<column>Date</column>
|
||||
<column>ISO Timestamp of when connection was created</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>scopes</column>
|
||||
<column>integer</column>
|
||||
<column>Associated OAuth2 scopes with connection</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>application</column>
|
||||
<column>Application Object</column>
|
||||
<column>An Application Object</column>
|
||||
</row>
|
||||
</table>
|
||||
<text><i>Quick link to</i> <a href="/library/api/applications#application-object">Application Object</a>.</text>
|
||||
|
||||
<!-- GET /users/<user.username> -->
|
||||
<header>Get User by Username </header>
|
||||
<text><c>GET /users/<user.username></c></text>
|
||||
<text>
|
||||
Returns a <a href="#user-object">user object</a> for a given username,
|
||||
doesn't require any authorization.
|
||||
</text>
|
||||
</article>
|
||||
@@ -0,0 +1,64 @@
|
||||
<article
|
||||
id="branding"
|
||||
authorId=""
|
||||
categoryId="home"
|
||||
title="Branding"
|
||||
created="200"
|
||||
snippet="Branding Guidelines for suzzy games"
|
||||
banner=""
|
||||
noindex="true"
|
||||
>
|
||||
<!-- Guidelines -->
|
||||
<header>Usage</header>
|
||||
<text>
|
||||
This page contains high quality versions of promotional assets from most
|
||||
suzzy projects and games. Please use common sense and don't hesistate to
|
||||
<a href="mailto:bakonpancakz@suzzygames.com">contact me</a> if you have any
|
||||
questions.
|
||||
</text>
|
||||
<text>
|
||||
<b>Do not use these assets commercially or for impersonation.</b>
|
||||
</text>
|
||||
<quote>Hint: You can click on any image to download it to your device.</quote>
|
||||
|
||||
<!-- Product: suzzy games -->
|
||||
<header>suzzy games</header>
|
||||
<beanie alt="suzzy games Logo" resource="file://library/branding/suzzy-logo.png?preset=branding" />
|
||||
<beanie alt="suzzy games Icon" resource="file://library/branding/suzzy-icon.png?preset=branding" />
|
||||
<quote>Trivia: The name for our ghost mascot is Boo! You can find them in the logo.</quote>
|
||||
<quote>Trivia: The accent color for suzzy is #A1A8FF and is actually considered to be a light sky blue. Not purple!</quote>
|
||||
|
||||
<!-- Product: BECCA2D -->
|
||||
<header>BECCA2D</header>
|
||||
<text>
|
||||
BECCA2D is a <b>2D Web Game Engine</b> developed by suzzy games and is
|
||||
used in the upcoming <a href="/projects">super marimari_eno</a> fan-game.
|
||||
</text>
|
||||
<beanie alt="BECCA2D Logo" resource="file://library/branding/becca-logo.svg?preset=branding" />
|
||||
<quote>Trivia: BECCA2D is named after my sister, since my nickname for her is Becca.</quote>
|
||||
|
||||
<!-- Product: Project Monke -->
|
||||
<header>Project Monke</header>
|
||||
<text>Project Monke is an upcoming platformer game developed by suzzy games.</text>
|
||||
<beanie alt="PM Game Icon #1" resource="file://library/branding/monke-gameicon.png?preset=branding" />
|
||||
<beanie alt="PM Game Icon #2" resource="file://library/branding/monke-gameicon-initials.png?preset=branding" />
|
||||
<beanie alt="PM Game Logo #1" resource="file://library/branding/monke-logo-text.png?preset=branding" />
|
||||
<beanie alt="PM Game Logo #2" resource="file://library/branding/monke-logo-initials.png?preset=branding" />
|
||||
<beanie alt="PM Promo Art #1" resource="file://library/branding/monke-promo-1.png?preset=branding" />
|
||||
<quote>Trivia: The Polka Dot pattern was inspired by DDLC+ promo art.</quote>
|
||||
|
||||
<!-- Product: Cart Ride around a Fumo -->
|
||||
<header>Cart Ride Around a Fumo</header>
|
||||
<text>
|
||||
Cart Ride around a Fumo is a <a href="https://www.roblox.com/games/9987852646/Cart-Ride-Around-a-Fumo">ROBLOX experience</a> developed by suzzy games.
|
||||
Promo and Game Icon Art drawn by <a href="https://twitter.com/MondaeAkari">@mondaeakari</a>.
|
||||
</text>
|
||||
<beanie alt="CRAF Game Icon #1" resource="file://library/branding/craf-gameicon-1.png?preset=branding" />
|
||||
<beanie alt="CRAF Game Icon #2" resource="file://library/branding/craf-gameicon-2.png?preset=branding" />
|
||||
<beanie alt="CRAF Promo Art #1" resource="file://library/branding/craf-promo-1.png?preset=branding" />
|
||||
<beanie alt="CRAF Promo Art #2" resource="file://library/branding/craf-promo-2.png?preset=branding" />
|
||||
<quote>
|
||||
Trivia: The first icon didn't do so well to bring in new players.
|
||||
Which sucks because I liked it ;-;
|
||||
</quote>
|
||||
</article>
|
||||
@@ -0,0 +1,27 @@
|
||||
<article
|
||||
id="welcome"
|
||||
authorId=""
|
||||
categoryId="home"
|
||||
title="Welcome"
|
||||
created="100"
|
||||
snippet="Welcome to the suzzy Library!"
|
||||
banner=""
|
||||
noindex="true"
|
||||
>
|
||||
<banner resource="file://library/introduction/banner-welcome.png" alt="Welcome Banner" />
|
||||
<subheader>Welcome to the library!</subheader>
|
||||
<text>
|
||||
This site contains documentation and guides intended for developers.
|
||||
You can navigate the website using the links on the side. <h>Or above if you're on mobile!</h>
|
||||
</text>
|
||||
|
||||
<subheader>Heads up!</subheader>
|
||||
<text>
|
||||
Documentation and features are still early in development, you may occasionally
|
||||
encounter an unexpected <c>500 Internal Server Error</c> or find a random typo.
|
||||
</text>
|
||||
<text>
|
||||
Please send bug reports or feature requests to
|
||||
<a href="mailto:bakonpancakz@gmail.com">bakonpancakz@gmail.com</a>
|
||||
</text>
|
||||
</article>
|
||||
@@ -0,0 +1,24 @@
|
||||
<article
|
||||
id="privacy-policy"
|
||||
authorId=""
|
||||
categoryId="legal"
|
||||
title="Privacy Policy"
|
||||
created="999999"
|
||||
snippet="Privacy Policy governing all suzzy services and products"
|
||||
noindex="true"
|
||||
banner=""
|
||||
>
|
||||
<header>Introduction</header>
|
||||
<text>
|
||||
This document entails the general privacy policy, covering all suzzy services.
|
||||
Specific services may override it as necessary — please refer to their respective documents for more information.
|
||||
</text>
|
||||
<text>
|
||||
<c>Last Updated on May 11th 2024</c>
|
||||
</text>
|
||||
|
||||
<header>1. todo</header>
|
||||
<text>
|
||||
<h>here's where i would put my privacy policy. IF I HAD ONE!</h>
|
||||
</text>
|
||||
</article>
|
||||
@@ -0,0 +1,24 @@
|
||||
<article
|
||||
id="terms-of-service"
|
||||
authorId=""
|
||||
categoryId="legal"
|
||||
title="Terms of Service"
|
||||
created="999998"
|
||||
snippet="Terms of Service governing all suzzy services and products"
|
||||
noindex="true"
|
||||
banner=""
|
||||
>
|
||||
<header>Introduction</header>
|
||||
<text>
|
||||
This document entails the general terms of service, covering all suzzy services.
|
||||
Specific services may override it as necessary — please refer to their respective documents for more information.
|
||||
</text>
|
||||
<text>
|
||||
<c>Last Updated on May 11th 2024</c>
|
||||
</text>
|
||||
|
||||
<header>1. todo</header>
|
||||
<text>
|
||||
<h>here's where i would put my terms of service. IF I HAD ONE!</h>
|
||||
</text>
|
||||
</article>
|
||||
@@ -0,0 +1,135 @@
|
||||
<article
|
||||
id="endpoints"
|
||||
authorId=""
|
||||
categoryId="status"
|
||||
title="Endpoints"
|
||||
created="100"
|
||||
snippet=""
|
||||
banner=""
|
||||
noindex="false"
|
||||
>
|
||||
<!-- GET /widget.json -->
|
||||
<header>Get Widget</header>
|
||||
<text><c>GET /widget.json</c></text>
|
||||
<text>
|
||||
Returns a unique <a href="#widget-object">Widget Object</a>. This
|
||||
is the same endpoint use for the widget displayed in the top-right
|
||||
corner of the suzzy games webpage.
|
||||
</text>
|
||||
|
||||
<subheader>Widget Object</subheader>
|
||||
<table>
|
||||
<row>
|
||||
<column>Field</column>
|
||||
<column>Type</column>
|
||||
<column>Description</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>status</column>
|
||||
<column>string</column>
|
||||
<column>Current status either "online", "degraded", or "down"</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>counter_players_online</column>
|
||||
<column>number?</column>
|
||||
<column>Estimated number of players online</column>
|
||||
</row>
|
||||
</table>
|
||||
<quote>This endpoint returns the headers 'X-Refresh' and 'Etag'</quote>
|
||||
|
||||
<!-- GET /status.json -->
|
||||
<header>Get Status</header>
|
||||
<text><c>GET /status.json</c></text>
|
||||
<text>
|
||||
Returns a unique <a href="#status-object">Status Object</a>. Includes
|
||||
the current status, an array of
|
||||
<a href="/library/status/reference#tracker-object">tracker objects</a>,
|
||||
and an array of
|
||||
<a href="/library/status/reference#event-object">event objects</a>
|
||||
which occurred today.
|
||||
</text>
|
||||
<subheader>Status Object</subheader>
|
||||
<table>
|
||||
<row>
|
||||
<column>Field</column>
|
||||
<column>Type</column>
|
||||
<column>Description</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>status</column>
|
||||
<column>string</column>
|
||||
<column>Current status either "online", "degraded", or "down"</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>trackers</column>
|
||||
<column>Array<Trackers></column>
|
||||
<column>List of Trackers</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>events</column>
|
||||
<column>Array<Events></column>
|
||||
<column>List of Events for Today</column>
|
||||
</row>
|
||||
</table>
|
||||
<quote>This endpoint returns the headers 'X-Refresh' and 'Etag'</quote>
|
||||
<text>
|
||||
<b>Notice:</b> This endpoint is compressed with <a target="_blank" href="https://developer.mozilla.org/en-US/docs/Glossary/gzip_compression">gzip</a>.
|
||||
Your client must support and notify the server that it accepts gzip
|
||||
encoded content via the <c>Accept-Encoding</c> header. Otherwise
|
||||
your request will be rejected with a <c>415 Unsupported Media Type</c>
|
||||
status code.
|
||||
</text>
|
||||
|
||||
<!-- GET /events -->
|
||||
<header>Get Events</header>
|
||||
<text><c>GET /events</c></text>
|
||||
<text>
|
||||
Returns an array of <a href="/library/status/reference#event-object">Event Objects</a>
|
||||
for today. You can request a specific day using the query parameter <c>date</c> in
|
||||
<c>MM/DD/YYYY</c> format <h>(ex. date=06/26/2003)</h>.
|
||||
</text>
|
||||
|
||||
<!-- GET /status.json -->
|
||||
<header>Get Events Summary</header>
|
||||
<text><c>GET /events/summary</c></text>
|
||||
|
||||
<text>
|
||||
Returns a Unique <a href="#summary-object">Summary Object</a> for this month.
|
||||
You can request a specific month using the query parameter <c>date</c> in
|
||||
<c>MM/YYYY</c> format. <h>(ex. date=06/2003)</h>
|
||||
</text>
|
||||
<subheader>Summary Object</subheader>
|
||||
<table>
|
||||
<row>
|
||||
<column>Field</column>
|
||||
<column>Type</column>
|
||||
<column>Description</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>uptime</column>
|
||||
<column>string</column>
|
||||
<column>Uptime Percentage in Float</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>results</column>
|
||||
<column>...</column>
|
||||
<column>See Description Below</column>
|
||||
</row>
|
||||
</table>
|
||||
<text>
|
||||
The results field is a JSON object with the <b>keys</b> being the <i>day of the month</i>, and it's
|
||||
<b>value</b> being an <i>Array with three integers</i>. Each integer represents how many seconds of
|
||||
<b>Degredation</b>, <b>Downtime</b>, and <b>Maintenance</b> occurred
|
||||
that day, respectively.
|
||||
</text>
|
||||
|
||||
<code syntax="json">
|
||||
{
|
||||
"uptime": "99.99", // Uptime Percent as Float
|
||||
"results": {
|
||||
"0": [0, 0, 3600], // "Day": [Seconds Degraded, Downtime, Maintenance]
|
||||
"12": [300, 0, 0], // Ex. 5 Minutes of Downtime on the 12th day of the month
|
||||
}
|
||||
}
|
||||
</code>
|
||||
</article>
|
||||
@@ -0,0 +1,310 @@
|
||||
<article
|
||||
id="reference"
|
||||
authorId=""
|
||||
categoryId="status"
|
||||
title="Reference"
|
||||
created="0"
|
||||
snippet=""
|
||||
banner=""
|
||||
noindex="false"
|
||||
>
|
||||
<!-- Server URLs -->
|
||||
<header>Sending Requests</header>
|
||||
<text>
|
||||
All requests to the <b>Status Service</b> should be made to the following URL:
|
||||
<c>https://status.suzzygames.com/api/</c>
|
||||
</text>
|
||||
|
||||
<header>Automatic Refreshing</header>
|
||||
<text>
|
||||
This service updates the <a href="/library/status/endpoints#fetch-widget">widget</a>
|
||||
and <a href="/library/status/endpoints#fetch-status">status</a> endpoints
|
||||
every minute.
|
||||
</text>
|
||||
<text>
|
||||
You can use the <c>X-Refresh</c> header to calculate how many float seconds
|
||||
your client should wait before attempting to make another request.
|
||||
</text>
|
||||
<text>
|
||||
This service also returns a <c>ETag</c> header which you can optionally include
|
||||
in the next request. If nothing has changed the service will respond with a
|
||||
<c>304 Not Modified</c> and an <b>empty body</b>.
|
||||
</text>
|
||||
<code syntax="yml">
|
||||
X-Refresh: 12.73 # Seconds until next refresh
|
||||
ETag: 1735594572 # Unique Cache Identifier
|
||||
</code>
|
||||
<quote>
|
||||
Note: The 'X-Refresh' header is randomly offset up to 5 seconds to
|
||||
help mitigate the sudden spike in traffic.
|
||||
</quote>
|
||||
|
||||
<header>Service Unavailable</header>
|
||||
<text>
|
||||
On rare occasions the Service may return a <c>503 Service Unavailable</c>
|
||||
error. This happens when the service has just restarted <h>(usually due to an update)</h>
|
||||
and is doing some digital housekeeping before preparing the <a href="/library/status/endpoints#fetch-widget">widget</a>
|
||||
and <a href="/library/status/endpoints#fetch-status">status</a> endpoints.
|
||||
</text>
|
||||
<text>
|
||||
The error will however return the <c>X-Refresh</c> header and the
|
||||
aforementioned endpoints should become available then.
|
||||
</text>
|
||||
<quote>
|
||||
Note: The status service always returns an empty body when an error occurs.
|
||||
Your client should not attempt to parse any JSON.
|
||||
</quote>
|
||||
|
||||
<header>About Trackers</header>
|
||||
|
||||
<subheader>Tracker Object</subheader>
|
||||
<text>
|
||||
All trackers share the same base fields, but some fields are only
|
||||
included for their respective types.
|
||||
</text>
|
||||
<text>
|
||||
<b>Charts</b> take in values from multiple servers and average them
|
||||
every specified interval compiling it into a <a href="#chart-data-point">Data Point</a>.
|
||||
Charts return the <c>interval</c>, <c>history</c>, and <c>history_length</c> fields.
|
||||
</text>
|
||||
<text>
|
||||
<b>Counters</b> take in individual numbers from multiple servers and accumulate
|
||||
them together as one number. Counters return the <c>value</c> field.
|
||||
</text>
|
||||
<text>
|
||||
<b>Services</b> keep track of multiple servers to ensure they're healthy and operational.
|
||||
If the health check fails their status is changed to either <b>degraded</b> or <b>down</b>
|
||||
generating an event and alerting an engineer.
|
||||
Services return the <c>status</c> field.
|
||||
</text>
|
||||
<table>
|
||||
<row>
|
||||
<column>Field</column>
|
||||
<column>Type</column>
|
||||
<column>Description</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>id</column>
|
||||
<column>string</column>
|
||||
<column>Unique Tracker Identifier</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>public</column>
|
||||
<column>boolean</column>
|
||||
<column>Is this tracker public? (Internal)</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>ephemeral</column>
|
||||
<column>boolean</column>
|
||||
<column>Clear tracker data on startup? (Internal)</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>name</column>
|
||||
<column>string</column>
|
||||
<column>User-Friendly name for this tracker</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>description</column>
|
||||
<column>string</column>
|
||||
<column>Description that appears when mouse is hovered over</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>tags</column>
|
||||
<column>Array<string></column>
|
||||
<column>Strings used to categorize this tracker</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>type</column>
|
||||
<column>integer</column>
|
||||
<column>The Type of Tracker</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>value</column>
|
||||
<column>integer?</column>
|
||||
<column>COUNTER: Current Tracker Value</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>status</column>
|
||||
<column>integer?</column>
|
||||
<column>SERVICE: Current Service Status</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>interval</column>
|
||||
<column>integer?</column>
|
||||
<column>CHART: Data Point Interval</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>history_length</column>
|
||||
<column>integer?</column>
|
||||
<column>CHART: Data Point History Length</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>history</column>
|
||||
<column>Array<DataPoint>?</column>
|
||||
<column>CHART: Data Point History</column>
|
||||
</row>
|
||||
</table>
|
||||
|
||||
<subheader>Tracker Types</subheader>
|
||||
<table>
|
||||
<row>
|
||||
<column>Enum</column>
|
||||
<column>Value</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>COUNTER</column>
|
||||
<column>1</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>CHART</column>
|
||||
<column>2</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>SERVICE</column>
|
||||
<column>3</column>
|
||||
</row>
|
||||
</table>
|
||||
|
||||
<subheader>Service Status</subheader>
|
||||
<table>
|
||||
<row>
|
||||
<column>Enum</column>
|
||||
<column>Value</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>HEALTHY</column>
|
||||
<column>0</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>DEGRADED</column>
|
||||
<column>1</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>DOWN</column>
|
||||
<column>2</column>
|
||||
</row>
|
||||
</table>
|
||||
|
||||
<subheader>Chart Data Point</subheader>
|
||||
<text>
|
||||
<b>Data Points</b> are Arrays that contain two integers.
|
||||
The first integer is a timestamp for when the service compiled
|
||||
the data into a point and can be converted into a UNIX Timestamp with
|
||||
<c>TIMESTAMP * (INTERVAL * 60) * 1000</c>. The second integer is the
|
||||
calculated average value.
|
||||
</text>
|
||||
<text>
|
||||
You can then reverse iterate over the <a href="#tracker-object">trackers history field</a>
|
||||
to plot the values on a line chart.
|
||||
</text>
|
||||
<table>
|
||||
<row>
|
||||
<column>Index</column>
|
||||
<column>Type</column>
|
||||
<column>Description</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>0</column>
|
||||
<column>integer</column>
|
||||
<column>Data Timestamp</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>1</column>
|
||||
<column>integer</column>
|
||||
<column>Data Value</column>
|
||||
</row>
|
||||
</table>
|
||||
|
||||
<header>About Events</header>
|
||||
<subheader>Event Object</subheader>
|
||||
<text>
|
||||
Events are generated when downtime is detected or for when downtime is
|
||||
scheduled. They include <b>"helpful"</b> messages either generated by
|
||||
the service itself or personally written by an engineer.
|
||||
</text>
|
||||
<table>
|
||||
<row>
|
||||
<column>field</column>
|
||||
<column>Type</column>
|
||||
<column>Description</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>id</column>
|
||||
<column>string</column>
|
||||
<column>Unique Event Identifier</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>type</column>
|
||||
<column>integer</column>
|
||||
<column>Event Type</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>affects</column>
|
||||
<column>string</column>
|
||||
<column>The ID of Tracker this event pertains to</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>occurred</column>
|
||||
<column>ISO Timestamp</column>
|
||||
<column>When this event began</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>resolved</column>
|
||||
<column>ISO Timestamp?</column>
|
||||
<column>When this event was resolved</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>messages</column>
|
||||
<column>Array<Message></column>
|
||||
<column>List of Message Objects (Unsorted)</column>
|
||||
</row>
|
||||
</table>
|
||||
|
||||
<subheader>Event Types</subheader>
|
||||
<table>
|
||||
<row>
|
||||
<column>Enum</column>
|
||||
<column>Value</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>DEGREDATION</column>
|
||||
<column>0</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>DOWNTIME</column>
|
||||
<column>1</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>MAINTENANCE</column>
|
||||
<column>2</column>
|
||||
</row>
|
||||
</table>
|
||||
<quote>Their respective Hex Colors: #f1c40f, #ff005b, #6cc0e0</quote>
|
||||
|
||||
<subheader>Message Object</subheader>
|
||||
<text>
|
||||
These message contain HTML Content. Which usually only use the
|
||||
standard text formatting tags <c><b> <s> <i></c>.
|
||||
</text>
|
||||
<text>
|
||||
<a target="_blank" href="">They may also occasionally include an image tag.</a>
|
||||
</text>
|
||||
<table>
|
||||
<row>
|
||||
<column>Field</column>
|
||||
<column>Type</column>
|
||||
<column>Description</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>created</column>
|
||||
<column>ISO Timestamp</column>
|
||||
<column>When this message was written</column>
|
||||
</row>
|
||||
<row>
|
||||
<column>message</column>
|
||||
<column>string</column>
|
||||
<column>HTML Content</column>
|
||||
</row>
|
||||
</table>
|
||||
|
||||
</article>
|
||||
@@ -0,0 +1 @@
|
||||
extends template
|
||||
@@ -0,0 +1,47 @@
|
||||
{
|
||||
"itemsPerPage": 8,
|
||||
"noBrowser": true,
|
||||
"authors": [
|
||||
{
|
||||
"id": "",
|
||||
"name": "suzzy",
|
||||
"icon": ""
|
||||
}
|
||||
],
|
||||
"categories": [
|
||||
{
|
||||
"id": "home",
|
||||
"name": "Home",
|
||||
"icon": ""
|
||||
},
|
||||
{
|
||||
"id": "legal",
|
||||
"name": "Legal",
|
||||
"icon": ""
|
||||
},
|
||||
{
|
||||
"id": "api",
|
||||
"name": "API",
|
||||
"icon": ""
|
||||
},
|
||||
{
|
||||
"id": "status",
|
||||
"name": "Status",
|
||||
"icon": ""
|
||||
}
|
||||
],
|
||||
"articles": [
|
||||
"home/Welcome.xml",
|
||||
"home/Branding.xml",
|
||||
"legal/Privacy Policy.xml",
|
||||
"legal/Terms of Service.xml",
|
||||
"api/Users.xml",
|
||||
"api/OAuth2.xml",
|
||||
"api/Applications.xml",
|
||||
"api/Reference.xml",
|
||||
"api/Tutorials.xml",
|
||||
"api/Changelog.xml",
|
||||
"status/Reference.xml",
|
||||
"status/Endpoints.xml"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
extends template
|
||||
@@ -0,0 +1,110 @@
|
||||
-
|
||||
// Create Sidebar Categories
|
||||
const t = {}
|
||||
for (const a of articles) {
|
||||
const k = categories.find(c => c.id === a.category.id).name
|
||||
t[k] ? t[k].push(a) : t[k] = [a]
|
||||
}
|
||||
// Sort Sidebar Articles
|
||||
for (const v of Object.values(t)) {
|
||||
v.sort((a, b) => parseInt(a.info.created) - parseInt(b.info.created))
|
||||
}
|
||||
|
||||
doctype html
|
||||
html(lang='en')
|
||||
head
|
||||
meta(charset='UTF-8')
|
||||
meta(name='viewport' content='width=device-width, initial-scale=1.0')
|
||||
link(rel='icon' type='image/png' href='file://library/favicon.png')
|
||||
link(rel='stylesheet' href='file://styles/template-global.css')
|
||||
link(rel='stylesheet' href='file://styles/template-article.css')
|
||||
link(rel='stylesheet' href='file://styles/browser-library.css')
|
||||
link(rel='stylesheet' href='file://fonts/font-poppins.css')
|
||||
meta(property='theme-color' content='#A1A8FF')
|
||||
meta(property='og:image' content='file://library/logo-og.png?direct=true')
|
||||
meta(property='og:title' content=`library | ${relevantArticle.category.name} > ${relevantArticle.info.title}`)
|
||||
meta(property='og:description' content=relevantArticle.info.snippet)
|
||||
meta(name='description' content=relevantArticle.info.snippet)
|
||||
title library - #{relevantArticle.info.title} (#{relevantArticle.category.name})
|
||||
body
|
||||
div(class='wrapper-search')
|
||||
div(class='container-search special-dropshadow')
|
||||
|
||||
div(class='search-actions')
|
||||
input(class='search-input' tabindex='-1' type='text' name='Search Library' placeholder='Search Library')
|
||||
button(class='search-close' tabindex='-1') ×
|
||||
|
||||
div(class='search-body')
|
||||
//- Loading Icon
|
||||
div(class='pane' id='loading')
|
||||
img(src='file://icons/diagram-loading.svg' style='width: 64px;')
|
||||
|
||||
//- Error Message
|
||||
div(class='pane' id='error')
|
||||
img(src='file://library/search/search-error.png')
|
||||
span I ran into an issue...
|
||||
p(class='text-tip text-muted') TypeError: Failed to Fetch
|
||||
|
||||
//- First Open/Empty Query
|
||||
div(class='pane' id='help')
|
||||
img(src='file://library/search/search-initial.png')
|
||||
span Can't find something? Let me help you out!
|
||||
p(class='text-tip text-muted') start typing to begin our search
|
||||
|
||||
//- Empty Results
|
||||
div(class='pane' id='empty')
|
||||
img(src='file://library/search/search-empty.png')
|
||||
span I couldn't find anything!
|
||||
p(class='text-tip text-muted') try again with some different keywords
|
||||
|
||||
//- Some Results
|
||||
div(class='pane' id='results')
|
||||
|
||||
div(class='search-footer')
|
||||
p(class='text-tip text-muted')
|
||||
div(style='flex-basis: 100%;')
|
||||
p Close #[span ESC]
|
||||
p Navigate #[span ⬆⬇]
|
||||
p Select #[span ↩]
|
||||
|
||||
|
||||
div(class='wrapper-layout')
|
||||
div(class='layout-navigation background-scroll special-shadow')
|
||||
//- Logo and Search Box
|
||||
a(class='navigation-button' id='skipper' href='#home')
|
||||
| Skip to Content
|
||||
a(href='/')
|
||||
img(
|
||||
class='navigation-logo'
|
||||
alt='Logo for suzzy games'
|
||||
src='file://library/logo-navigation.png'
|
||||
)
|
||||
button(class='navigation-button' id='search-open')
|
||||
| Search Library
|
||||
|
||||
//- Render Sidebar
|
||||
each [categoryName, categoryArticles] of Object.entries(t)
|
||||
p(class='navigation-header') #{categoryName}
|
||||
each someArticle of categoryArticles
|
||||
- var thisLink = `${relevantArticle.category.id}/${relevantArticle.info.id}`
|
||||
- var someLink = `${someArticle.category.id}/${someArticle.info.id}`
|
||||
- var matchLink = (thisLink === someLink)
|
||||
a(class='navigation-link' href=`/library/${someLink}` active=matchLink)
|
||||
| #{someArticle.info.title}
|
||||
if matchLink
|
||||
each element of someArticle.elements
|
||||
if element.type === 'header'
|
||||
a(class='navigation-chapter' href=`#${formatString(element.value)}`)
|
||||
| #{element.value}
|
||||
|
||||
div(class='layout-content' id='home')
|
||||
//- Article Content
|
||||
include ../_TemplateArticle
|
||||
|
||||
//- Mobile Users get a Return to Top Button
|
||||
//- Also includes spacer so content doesn't cover button
|
||||
div(class='layout-spacer')
|
||||
a(class='default layout-return' href='#home') ▲
|
||||
|
||||
script(src='file://scripts/shared-article.ts')
|
||||
script(src='file://scripts/browser-library.ts')
|
||||
Reference in New Issue
Block a user