Visitar URL original
keepandroidopen.github.io/src/content/pages/banner.md at main · TheTearMiser/keepandroidopen.github.io · GitHub
Skip to content

Latest commit

 

History

History
66 lines (46 loc) · 2.55 KB

banner.md

File metadata and controls

66 lines (46 loc) · 2.55 KB
title Add the Countdown Banner to Your Site
description Embed the Keep Android Open countdown banner on your own website with a single script tag.
lang en

Add the Keep Android Open countdown banner to your website with a single <script> tag. The banner is self-contained with no external dependencies — all styling and 20 localizations are built in. It auto-detects the visitor's browser language and displays a live countdown to the September 2026 lockdown date.

Basic usage

Inserts a full-width banner at the top of the page:

<script src="https://keepandroidopen.org/banner.js"></script>
<script src="/banner.js"></script>

Query parameters

Customize the banner by appending query parameters to the script URL:

Parameter Values Default Description
lang en, fr, de, es, … Browser language Override the display language
id Any element id (prepend to body) Insert the banner inside the element with this id
size normal, mini, minimal normal Banner size variant
link Any URL, or none https://keepandroidopen.org Make the banner text a clickable link; set to none to disable
hidebutton on, off on Show or hide the X close button (dismissed state is remembered per-site via localStorage)
animation on, off on Enable or disable the banner's pulsing animation

Examples

French, mini size, inserted into a specific element:

<div id="my-banner"></div>
<script src="https://keepandroidopen.org/banner.js?lang=fr&size=mini&id=my-banner"></script>
<script src="/banner.js?lang=fr&size=mini&id=my-banner"></script>

Link to a custom page, no close button:

<script src="https://keepandroidopen.org/banner.js?link=https://example.com/android&hidebutton=off"></script>
<script src="/banner.js?link=https://example.com/android&hidebutton=off&size=mini&id=my-banner-custom"></script>

Minimal size without animations.

<script src="https://keepandroidopen.org/banner.js?size=minimal&animation=off"></script>
<script src="/banner.js?size=minimal&animation=off&id=my-banner-minimal"></script>

Source

The source for the banner can be found at https://github.com/keepandroidopen/keepandroidopen.github.io/blob/main/public/banner.js. Suggestions for improvement are welcome!