Skip to content

Instantly share code, notes, and snippets.

Avatar

Sven Franck frequent

  • Nexedi Sa | Volt France
  • France
View GitHub Profile
View resampler.js
/*jslint nomen: true, indent: 2, maxerr: 3 */
/*global self, buffer */
(function (worker_instance) {
"use strict";
//JavaScript Audio Resampler (c) 2011 - Grant Galitz
var INCORRECT_BUFFER_LENGTH = "Buffer was of incorrect sample length.";
var INCORRECT_SETTINGS = "Invalid settings specified for the resampler.";
@frequent
frequent / gist:da0dd977fb0cf0e9177a32f9a08fd379
Created Jun 14, 2016
PyData Hyperconvergence Tutorial: Graph Gadget HTML
View gist:da0dd977fb0cf0e9177a32f9a08fd379
/*global window, rJS, console, RSVP, Dygraph */
/*jslint indent: 2, maxerr: 3 */
(function (rJS) {
"use strict";
var ARRAY_VALUE_LENGTH = 8,
OPTION_DICT = {
start_date: 0,
time_factor: 1000,
resolution: 1,
@frequent
frequent / gist:1269cadfcda31ec6a03fc0778d55c3dd
Last active Jun 14, 2016
PyData Hyperconvergence Tutorial: Updated Graph Gadget HTML
View gist:1269cadfcda31ec6a03fc0778d55c3dd
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
<meta name="viewport" content="width=device-width, user-scalable=no" />
<title>PyData Graph</title>
<!-- renderjs -->
<script src="rsvp.js" type="text/javascript"></script>
<script src="renderjs.js" type="text/javascript"></script>
@frequent
frequent / gist:1d12343b86332d43f4262ab6dda5e415
Last active Jun 14, 2016
PyData Hyperconvergence Tutorial: Graph Gadget JS
View gist:1d12343b86332d43f4262ab6dda5e415
/*global window, rJS, RSVP, URI */
/*jslint nomen: true, indent: 2, maxerr: 3 */
(function (window, rJS, RSVP, URI) {
"use strict";
rJS(window)
// Init local properties
.ready(function (g) {
g.props = {};
})
// Assign the element to a variable
@frequent
frequent / gist:794f8374560380a39c74718736c08ced
Last active Jun 14, 2016
PyData Hyperconvergence Tutorial: Graph Gadget HTML
View gist:794f8374560380a39c74718736c08ced
<html>
<head>
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
<meta name="viewport" content="width=device-width, user-scalable=no" />
<title>PyData Graph</title>
<script src="rsvp.js" type="text/javascript"></script>
<script src="renderjs.js" type="text/javascript"></script>
<script src="gadget_global.js" type="text/javascript"></script>
<script src="gadget_erp5_page_pydata.js" type="text/javascript"></script>
</head>
View gist:0e9ca7ae840a2a8b3882
<!-- field-search with tags and filter button -->
<script id="field-search-template" type="text/x-handlebars-template">
<div class="field_container">
<div class="ui-field-contain">
<div class="css-compatability-helper">
<div class="ui-input-text ui-body-{{theme}} ui-input-has-icon ui-corner-all ui-shadow-inset ui-input-has-clear {{status_class}} {{css_class}}">
<form class="save_form document_form">
<input type="text" data-enhanced="true" value="{{value}}" name="search" {{status_attribute}} />
<div class="ui-btn ui-input-clear ui-input-btn ui-corner-all ui-icon-search ui-btn-icon-notext" data-i18n="[node]{{search_i18n}}">
{{search_i18n}}<input tabindex="-1" data-role="button" data-enhanced="true" type="submit" data-i18n="[value]{{search_i18n}}" value=" " {{status_attribute}} />
@frequent
frequent / index.html
Created Aug 12, 2015
rtc-brainstorming
View index.html
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title></title>
<!--
<script type="text/javascript" src="sockjs-client.js"></script>
<script type="text/javascript" src="webtcp_client.js"></script>
View gist:2d54478d01649ba4706c
/* --------------------------- gadget_core.css -------------------------- */
/*
=========================================================================
================================ fonts =================================
=========================================================================
*/
/* global reference font-size (.9em = 14.4px) */
html.ui-mobile body div p,
html.ui-mobile body div a,
html.ui-mobile body div button,
@frequent
frequent / navigation.js
Created Jul 1, 2014
JQM navigation gadget, which allows deeplinking and (uri encoded) query parameters
View navigation.js
/*jslint indent: 2, maxlen: 80, nomen: true */
/*global console, window, document, rJS, RSVP, $ */
(function (window, document, rJS) {
"use strict";
rJS(window)
/**
* Override navigation of jQuery Mobile and allow deeplinking. Missing
* pages will now be loaded and added to the DOM as new page-gadgets -
View gist:48507187ef8c006c6d15
/*jslint indent: 2, maxlen: 80, nomen: true */
/*global console, window, document, rJS, RSVP, $ */
(function (window, document, rJS) {
"use strict";
rJS(window)
/**
* Override navigation of jQuery Mobile and allow deeplinking. Missing
* pages will now be loaded and added to the DOM as new gadgets - and