Skip to content

Instantly share code, notes, and snippets.

View SegersIan's full-sized avatar

Segers Ian SegersIan

View GitHub Profile
[server]
domain = storyclub.ai
root_url = %(protocol)s://%(domain)s:%(http_port)s/admin/
serve_from_sub_path = true
const {
generateBlobSASQueryParameters,
StorageSharedKeyCredential,
ContainerSASPermissions,
SASProtocol
} = require('@azure/storage-blob');
/**
* These are the 4 variables that matter
<!DOCTYPE html>
<html>
<body>
<script>
const POLL_INTERVAL = 100;
const MAX_VOLUME = 127;
const MIN_VOLUME = 0;
let currentVolume = 0;
<!DOCTYPE html>
<html>
<body>
<script>
const POLL_INTERVAL = 100;
const MAX_VOLUME = 127;
const MIN_VOLUME = 0;
let currentVolume = 0;
<!DOCTYPE html>
<html>
<body>
<label for="volume">Volume:</label>
<input name="volume" type="range" id="volume" min="0" max="127">
<button id="play">Play/Pause</button>
<script>
<!DOCTYPE html>
<html>
<body>
<label for="volume">Volume:</label>
<input name="volume" type="range" id="volume" min="0" max="127">
<script>
const volumeSlider = document.getElementById('volume');
<html>
<body>
<label for="volume">Volume:</label>
<input name="volume" type="range" id="volume" min="0" max="127">
<script>
const volumeSlider = document.getElementById('volume');
volumeSlider.addEventListener('input', function (e) {
console.log(e.target.value)
@SegersIan
SegersIan / poc_gamepad_api.html
Created May 30, 2019 14:45
Simple PoC of using the gamepad API in the web browser.
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Gamepad Log</title>
</head>
<body>
<h1>Gamepad log</h1>
<pre id="output"></pre>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Title</title>
</head>
<body>
<button id="btn">Connect</button>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Title</title>
</head>
<body>
<button id="btn">Connect</button>