hexsha
string
size
int64
ext
string
lang
string
max_stars_repo_path
string
max_stars_repo_name
string
max_stars_repo_head_hexsha
string
max_stars_repo_licenses
list
max_stars_count
int64
max_stars_repo_stars_event_min_datetime
string
max_stars_repo_stars_event_max_datetime
string
max_issues_repo_path
string
max_issues_repo_name
string
max_issues_repo_head_hexsha
string
max_issues_repo_licenses
list
max_issues_count
int64
max_issues_repo_issues_event_min_datetime
string
max_issues_repo_issues_event_max_datetime
string
max_forks_repo_path
string
max_forks_repo_name
string
max_forks_repo_head_hexsha
string
max_forks_repo_licenses
list
max_forks_count
int64
max_forks_repo_forks_event_min_datetime
string
max_forks_repo_forks_event_max_datetime
string
content
string
avg_line_length
float64
max_line_length
int64
alphanum_fraction
float64
c4c6cd789970db9bdc494769a3bcca4f89dc9d51
5,780
js
JavaScript
dist/bus/observable.js
knowledge-express/ontopic
64c34978d4c72af6a053119251def45c6bef0ac0
[ "MIT" ]
1
2018-04-16T23:26:05.000Z
2018-04-16T23:26:05.000Z
dist/bus/observable.js
knowledge-express/ontopic
64c34978d4c72af6a053119251def45c6bef0ac0
[ "MIT" ]
null
null
null
dist/bus/observable.js
knowledge-express/ontopic
64c34978d4c72af6a053119251def45c6bef0ac0
[ "MIT" ]
null
null
null
"use strict"; var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { return new (P || (P = Promise))(function (resolve, reject) { function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } function step(result) { result.done ? resolve(result.value) : new P(function (resolve) { resolve(result.value); }).then(fulfilled, rejected); } step((generator = generator.apply(thisArg, _arguments || [])).next()); }); }; Object.defineProperty(exports, "__esModule", { value: true }); var Disposable; (function (Disposable) { function create(disposer) { var done = false; return { dispose() { if (done) return; done = true; if (disposer) disposer(); } }; } Disposable.create = create; })(Disposable = exports.Disposable || (exports.Disposable = {})); var Observable; (function (Observable) { function create(fn) { var subject; function subscribe(observer) { if (!subject) { subject = Subject.create(); if (fn) fn(subject); } return subject.subscribe(observer); } return { subscribe }; } Observable.create = create; function pipe(observable, observer) { observable.subscribe(observer); return observer; } Observable.pipe = pipe; function map(observable, mapFn) { return create(subject => { observable.subscribe({ onNext: value => Promise.resolve(mapFn(value)).then(subject.onNext) }); }); } Observable.map = map; function filter(observable, filterFn) { return create(subject => { observable.subscribe({ onNext: value => Promise.resolve(filterFn(value)).then(result => result ? subject.onNext(value) : undefined) }); }); } Observable.filter = filter; function flatten(observable) { return create(subject => { observable.subscribe({ onNext: (values) => __awaiter(this, void 0, void 0, function* () { return values.reduce((memo, value) => __awaiter(this, void 0, void 0, function* () { yield memo; return subject.onNext(value); }), Promise.resolve()); }) }); }); } Observable.flatten = flatten; function scan(observable, scanFn, memo) { return create(subject => { observable.subscribe({ onNext: value => Promise.resolve(scanFn(memo, value)).then(value => { memo = value; return subject.onNext(value); }) }); }); } Observable.scan = scan; function forEach(observable, fn) { return observable.subscribe({ onNext: fn }); } Observable.forEach = forEach; function fromPromise(promise) { return create(subject => { promise.then(subject.onNext).then(subject.onComplete); }); } Observable.fromPromise = fromPromise; function toPromise(observable) { return new Promise((resolve, reject) => { observable.subscribe({ onNext: resolve, onComplete: resolve, onError: reject }); }); } Observable.toPromise = toPromise; })(Observable = exports.Observable || (exports.Observable = {})); var Subject; (function (Subject) { function isSubject(obj) { return typeof obj["onNext"] === "function"; } Subject.isSubject = isSubject; function create() { var observers = Object.create(null), current = Promise.resolve(), completed = false, result, errored = false, error; function subscribe(observer) { if (completed) { Promise.resolve(() => observer.onComplete(result)); return Disposable.create(); } if (errored) { Promise.resolve(() => observer.onError(error)); return Disposable.create(); } var observerKey = `observer-${Math.random()}`; observers[observerKey] = observer; return Disposable.create(() => delete observers[observerKey]); } function onNext(value) { return __awaiter(this, void 0, void 0, function* () { return current = current.then(() => Promise.all(Object.keys(observers).map(key => observers[key].onNext(value))).then(() => { })); }); } function onComplete(res) { return __awaiter(this, void 0, void 0, function* () { completed = true; result = res; return current = current.then(() => Promise.all(Object.keys(observers).map(key => observers[key].onComplete ? observers[key].onComplete(res) : undefined)).then(() => { observers = null; })); }); } function onError(reason) { return __awaiter(this, void 0, void 0, function* () { errored = true; error = reason; return current = current.then(() => Promise.all(Object.keys(observers).map(key => observers[key].onError ? observers[key].onError(reason) : undefined)).then(() => { observers = null; })); }); } return { subscribe, onNext, onComplete, onError }; } Subject.create = create; })(Subject = exports.Subject || (exports.Subject = {}));
38.278146
206
0.539965
c4c6f75004aeadad21c1d7f335ebd323a89dd8dc
287
js
JavaScript
packages/themes/lobster.js
philmirez/mdx-deck
31cf2a86f3d0d12cae743768c0d8a38d0bbf9d1c
[ "MIT" ]
10,642
2018-07-29T20:37:01.000Z
2022-03-31T14:50:15.000Z
packages/themes/lobster.js
philmirez/mdx-deck
31cf2a86f3d0d12cae743768c0d8a38d0bbf9d1c
[ "MIT" ]
507
2018-07-29T20:37:47.000Z
2022-03-31T01:47:11.000Z
packages/themes/lobster.js
philmirez/mdx-deck
31cf2a86f3d0d12cae743768c0d8a38d0bbf9d1c
[ "MIT" ]
807
2018-07-30T00:56:39.000Z
2022-03-28T14:50:32.000Z
const text = '#220011' export default { googleFont: 'https://fonts.googleapis.com/css?family=Lobster|Roboto+Mono', fonts: { body: 'Lobster, cursive', monospace: '"Roboto Mono", monospace', }, colors: { text: text, background: 'tomato', primary: text, }, }
19.133333
76
0.623693
c4c72cd73b3f76817866a7edb132443266e8387f
1,979
js
JavaScript
src/components/Navigation/index.js
TheSavageDev/hawkufire
3b20017ff1c4cdda55283aef10d867400e8dc4b8
[ "MIT" ]
null
null
null
src/components/Navigation/index.js
TheSavageDev/hawkufire
3b20017ff1c4cdda55283aef10d867400e8dc4b8
[ "MIT" ]
6
2019-04-17T00:43:55.000Z
2019-04-17T01:02:49.000Z
src/components/Navigation/index.js
JSavage42/hawkufire
3b20017ff1c4cdda55283aef10d867400e8dc4b8
[ "MIT" ]
null
null
null
import React from "react"; // *** Constants *** // import * as ROUTES from "../../constants/routes"; // *** Styles *** // import "../../styles/components/Navigation.css"; // *** Third-Party *** // import { NavLink } from "react-router-dom"; // *** HOC and Context *** // import { AuthUserContext } from "../Session"; // *** Components *** // import SignOutButton from "../SignOut"; const Navigation = () => ( <AuthUserContext.Consumer> {authUser => authUser ? <NavigationAuth authUser={authUser} /> : <NavigationNonAuth /> } </AuthUserContext.Consumer> ); const NavigationAuth = ({ authUser }) => ( <header> <div id="logo-title"> <h1>HAWKU</h1> <SignOutButton /> </div> <nav> <ul> <li> <NavLink to={ROUTES.HOME} exact activeClassName="selected"> Home </NavLink> </li> <li> <NavLink to={ROUTES.COMPETITIONS} activeClassName="selected"> Competitions </NavLink> </li> <li> <NavLink to={ROUTES.TEAMS} activeClassName="selected"> Teams </NavLink> </li> <li> <NavLink to={ROUTES.ANOMALIES} activeClassName="selected"> Anomalies </NavLink> </li> <li> <NavLink to={ROUTES.COMPETITORS} activeClassName="selected"> Competitors </NavLink> </li> <li> <NavLink to={ROUTES.REPORTS} activeClassName="selected"> Reports </NavLink> </li> <li> <NavLink to={ROUTES.DASHBOARD} activeClassName="selected"> Dashboard </NavLink> </li> </ul> </nav> </header> ); const NavigationNonAuth = () => ( <header> <h2>HAWKU</h2> <nav> <ul> <li> <NavLink to={ROUTES.SIGN_IN}>Sign In</NavLink> </li> </ul> </nav> </header> ); export default Navigation;
22.488636
79
0.514401
c4c735eab923d68d7774ebe6bdf75d619d5e9ca9
6,747
js
JavaScript
index.js
xprezzo/xprezzo-finalhandler
b0ca195c7ae97e3907a79c23b6387c05d5523beb
[ "MIT" ]
null
null
null
index.js
xprezzo/xprezzo-finalhandler
b0ca195c7ae97e3907a79c23b6387c05d5523beb
[ "MIT" ]
null
null
null
index.js
xprezzo/xprezzo-finalhandler
b0ca195c7ae97e3907a79c23b6387c05d5523beb
[ "MIT" ]
null
null
null
/*! * xprezzo-finalhandler * Copyright(c) 2022 Cloudgen Wong <cloudgen.wong@gmail.com> * MIT Licensed * * Create a function to handle the final response. * * @param {Request} req * @param {Response} res * @param {Object} [options] * @return {Function} * @public */ 'use strict' /** * Module dependencies. * @private */ const debug = require('xprezzo-debug')('xprezzo:finalhandler') const encodeUrl = require('encodeurl') const escapeHtml = require('escape-html') const onFinished = require('xprezzo-on-finished') const parseUrl = require('parseurl') const statuses = require('statuses') const unpipe = require('xprezzo-stream-unpipe') /** * Module variables. * @private */ let DOUBLE_SPACE_REGEXP = /\x20{2}/g let NEWLINE_REGEXP = /\n/g /* istanbul ignore next */ let defer = typeof setImmediate === 'function' ? setImmediate : function (fn) { process.nextTick(fn.bind.apply(fn, arguments)) } let isFinished = onFinished.isFinished /** * Create a minimal HTML document. * * @param {string} message * @private */ const createHtmlDocument = (message) => { let body = escapeHtml(message) .replace(NEWLINE_REGEXP, '<br>') .replace(DOUBLE_SPACE_REGEXP, ' &nbsp;') return '<!DOCTYPE html>\n' + '<html lang="en">\n' + '<head>\n' + '<meta charset="utf-8">\n' + '<title>Error</title>\n' + '</head>\n' + '<body>\n' + '<pre>' + body + '</pre>\n' + '</body>\n' + '</html>\n' } /** * Get headers from Error object. * * @param {Error} err * @return {object} * @private */ const getErrorHeaders = (err) => { if (!err.headers || typeof err.headers !== 'object') { return undefined } let headers = Object.create(null) let keys = Object.keys(err.headers) for (let i = 0; i < keys.length; i++) { let key = keys[i] headers[key] = err.headers[key] } return headers } /** * Get message from Error object, fallback to status message. * * @param {Error} err * @param {number} status * @param {string} env * @return {string} * @private */ const getErrorMessage = (err, status, env) => { let msg if (env !== 'production') { // use err.stack, which typically includes err.message msg = err.stack // fallback to err.toString() when possible if (!msg && typeof err.toString === 'function') { msg = err.toString() } } return msg || statuses.message[status] || String(status) } /** * Get status code from Error object. * * @param {Error} err * @return {number} * @private */ const getErrorStatusCode = (err) => { // check err.status if (typeof err.status === 'number' && err.status >= 400 && err.status < 600) { return err.status } // check err.statusCode if (typeof err.statusCode === 'number' && err.statusCode >= 400 && err.statusCode < 600) { return err.statusCode } return undefined } /** * Get resource name for the request. * * This is typically just the original pathname of the request * but will fallback to "resource" is that cannot be determined. * * @param {IncomingMessage} req * @return {string} * @private */ const getResourceName = (req) => { try { return parseUrl.original(req).pathname } catch (e) { return 'resource' } } /** * Get status code from response. * * @param {OutgoingMessage} res * @return {number} * @private */ const getResponseStatusCode = (res) => { let status = res.statusCode // default status code to 500 if outside valid range if (typeof status !== 'number' || status < 400 || status > 599) { status = 500 } return status } /** * Determine if the response headers have been sent. * * @param {object} res * @returns {boolean} * @private */ const headersSent = (res) => { return typeof res.headersSent !== 'boolean' ? Boolean(res._header) : res.headersSent } /** * Send response. * * @param {IncomingMessage} req * @param {OutgoingMessage} res * @param {number} status * @param {object} headers * @param {string} message * @private */ const sendResponse = (req, res, status, headers, message) => { let write = () => { // response body let body = createHtmlDocument(message) // response status res.statusCode = status res.statusMessage = statuses.message[status] || String(status) // response headers setHeaders(res, headers) // security headers res.setHeader('Content-Security-Policy', "default-src 'none'") res.setHeader('X-Content-Type-Options', 'nosniff') // standard headers res.setHeader('Content-Type', 'text/html; charset=utf-8') res.setHeader('Content-Length', Buffer.byteLength(body, 'utf8')) if (req.method === 'HEAD') { res.end() return } res.end(body, 'utf8') } if (isFinished(req)) { write() return } // unpipe everything from the request unpipe(req) // flush the request onFinished(req, write) req.resume() } /** * Set response headers from an object. * * @param {OutgoingMessage} res * @param {object} headers * @private */ const setHeaders = (res, headers) => { if (!headers) { return } let keys = Object.keys(headers) for (let i = 0; i < keys.length; i++) { let key = keys[i] res.setHeader(key, headers[key]) } } /** * Module exports. * @public */ module.exports = (req, res, options) => { let opts = options || {} // get environment let env = opts.env || process.env.NODE_ENV || 'development' // get error callback let onerror = opts.onerror return function (err) { let headers let msg let status // cannot actually respond if (headersSent(res)) { debug('cannot %d after headers sent', status) res.end('') return this } // unhandled error if (err) { // respect status code from error status = getErrorStatusCode(err) if (status === undefined) { // fallback to status code on response status = getResponseStatusCode(res) } else { // respect headers from error headers = getErrorHeaders(err) } // get error message msg = getErrorMessage(err, status, env) } else { // not found status = 404 msg = 'Cannot ' + req.method + ' ' + encodeUrl(getResourceName(req)) } debug('error dispatching %s %s', req.method, encodeUrl(getResourceName(req))) if (opts.app && typeof opts.app.emit === 'function') { opts.app.emit('errorDispatch', { method: req.method, url: encodeUrl(getResourceName(req)) }) } debug('default %s', status) // schedule onerror callback if (err && onerror) { defer(onerror, err, req, res) } // send response sendResponse(req, res, status, headers, msg) } }
21.216981
92
0.617904
c4c77f35d6714e2899960aef897aebc00433d8fd
1,058
js
JavaScript
public/javascripts/validateForms.js
EzekielCarvalho/restaurant-land-europe
d9cfe0eec104031c40450be22047b87e4e6978b3
[ "MIT" ]
null
null
null
public/javascripts/validateForms.js
EzekielCarvalho/restaurant-land-europe
d9cfe0eec104031c40450be22047b87e4e6978b3
[ "MIT" ]
null
null
null
public/javascripts/validateForms.js
EzekielCarvalho/restaurant-land-europe
d9cfe0eec104031c40450be22047b87e4e6978b3
[ "MIT" ]
null
null
null
(function () { 'use strict' // Fetch all the forms we want to apply custom Bootstrap validation styles to const forms = document.querySelectorAll('.validated') //select all forms with the class "validated" which is added above // Loop over them and prevent submission Array.from(forms) //this Array.from is used to make an array (From "form") .forEach(function (form) { //loop over it with forEach form.addEventListener('submit', function (event) { //add an event listener to each form if (!form.checkValidity()) { //check each's validity when the form is submitted and if it's not valid, then prevent default and stop propagating event.preventDefault() event.stopPropagation() } form.classList.add('was-validated') }, false) }) })()
50.380952
187
0.519849
c4c8a738597f2bfa8c654f9f6c337c0d6be14c17
3,078
js
JavaScript
src/src/generator.js
codeofnode/work-event-gen
c5348910939a6694141fd26c5a7560e10b13e33f
[ "MIT" ]
null
null
null
src/src/generator.js
codeofnode/work-event-gen
c5348910939a6694141fd26c5a7560e10b13e33f
[ "MIT" ]
null
null
null
src/src/generator.js
codeofnode/work-event-gen
c5348910939a6694141fd26c5a7560e10b13e33f
[ "MIT" ]
null
null
null
/* global global */ import { EventEmitter } from 'events'; import callRequest from '../lib/request'; const HOLIDAY_SOURCE = 'http://get-holidays.com/api/v1/holidays.json'; /** * @module gnerator */ /** * A Generator class * @class */ class Generator extends EventEmitter { /** * Create an instance of class Generator. * @param {object} - the various options */ constructor(options) { super(); this.employees = options.employees; this.countries = options.countries || []; this.period = options.period; this.preHolidays = Generator.convertToDateString(options.holidays || []); this.holidays = {}; this.countries.forEach((country) => { this.holidays[country] = []; }); this.loadHolidays(options.holidaysSource, options.countries); } /** * convert list of dates to date strings * @param {string[]} - list of dates */ static convertToDateString(ar) { return (ar || []) .map(vl => new Date(vl)) .filter(vl => !(isNaN(vl.getTime()))) .map(vl => vl.toDateString()); } /** * return if a day is holiday in a country * @param {Date} date - the date * @param {string} country - country */ isAHoliday(date, country) { const ds = date.toDateString(); if (this.preHolidays.indexOf(ds) !== -1) return true; if (country) { if (Array.isArray(this.holidays[country])) { return this.holidays[country].indexOf(ds) !== 1; } } return false; } /** * load holidays * @param {string} holidaysSource - the url file, to read the list of urls and assertions * @param {string[]} countries - list of countries */ async loadHolidays(holidaysSource = HOLIDAY_SOURCE, countries) { if (Array.isArray(countries) && countries.length) { (await callRequest(`${holidaysSource}?country=${countries.join(',')}`)) .forEach((ob) => { if (!Array.isArray(ob.country)) { this.holidays[ob.country] = []; } this.holidays[ob.country].push(...[ob.date]); }); } } /** * start the work */ start() { this.emit('log:gen-started'); } /** * stop the service * @param {function} [callback] - if found, to be called when the service is stopped */ stop() { this.emit('log:gen-ended'); } /** * the function that is called generating the work events */ generate() { let date = this.period[0]; this.employees.forEach((ob) => { ob.leaves // eslint-disable-line no-param-reassign = Generator.convertToDateString(ob.leaves || []); }); while (date <= this.period[1]) { this.employees.forEach((ob) => { // eslint-disable-line no-loop-func if (ob.isActive !== false && ob.leaves.indexOf(date.toDateString()) === -1 && !this.isAHoliday(date, ob.country)) { this.emit('work:event', { employeeId: ob.id, isWorking: true, date }); } }); date = new Date(date.getTime() + (24 * 60 * 60 * 1000)); } this.stop(); } } export default Generator;
26.084746
91
0.589344
c4c8b753a5c89e34fc1073b64c7d528d2474b320
2,130
js
JavaScript
lib/index.js
adrs2002/chara_gen_1
85b372fe112d75f88a07af1fe89a8f399eb1804e
[ "MIT" ]
null
null
null
lib/index.js
adrs2002/chara_gen_1
85b372fe112d75f88a07af1fe89a8f399eb1804e
[ "MIT" ]
null
null
null
lib/index.js
adrs2002/chara_gen_1
85b372fe112d75f88a07af1fe89a8f399eb1804e
[ "MIT" ]
null
null
null
/* 大本ページに設定する共通js */ window.content = new Content(); window.frame1 = document.getElementById('frame1'); window.nextPage = ''; window.transferData = null; window.onload = function() { window.frame1.onload = () => { this.onresize(); }; window.frame1.contentWindow.addEventListener( 'orientationchange resize', function() { if (this.Engine) { this.Engine.onWindowResize(); } } ); parentCall('location', { url: window.defaultpage }); }; function parentCall(_ev, _opt) { switch (_ev) { case 'view_load': document.getElementById('loader_d').style.display = 'block'; break; case 'hide_load': document.getElementById('loader_d').style.display = 'none'; break; case 'location': let url = null; if (_opt && _opt.url) { url = _opt.url; } if (!url) { url = window.nextPage; } if (_opt.nextUrl) { window.nextPage = _opt.nextUrl; } else { window.nextPage = null; } if (_opt.transferData) { window.transferData = _opt.transferData; } if (window.frame1.contentDocument == null) { var iframed = window.frame1.contentWindow || window.frame1.contentDocument; window.frame1.location.replace(url); } else { window.frame1.contentDocument.location.replace(url); } } } window.reSizeTimer = null; window.onresize = () => { if (window.reSizeTimer > 0) { clearTimeout(window.reSizeTimer); } window.reSizeTimer = setTimeout(() => { window.frame1.width = window.innerWidth; window.frame1.height = window.innerHeight; if (window.frame1.contentWindow.Engine) { window.frame1.contentWindow.Engine.onWindowResize({ width: window.innerWidth, height: window.innerHeight, }); } }, 200); };
28.026316
91
0.530047
c4c9add327e6c3fcab43e722118858e8a6526090
160
js
JavaScript
src/selectors/book.js
vladimir-trifonov/bitfinex-ext
c62be8e630eb72e6a3d07fc02d9bb9d1954229ad
[ "Unlicense" ]
null
null
null
src/selectors/book.js
vladimir-trifonov/bitfinex-ext
c62be8e630eb72e6a3d07fc02d9bb9d1954229ad
[ "Unlicense" ]
null
null
null
src/selectors/book.js
vladimir-trifonov/bitfinex-ext
c62be8e630eb72e6a3d07fc02d9bb9d1954229ad
[ "Unlicense" ]
null
null
null
import { createSelector } from 'reselect' const getBook = ({ book }) => book export const getBookSelector = createSelector( [ getBook ], (book) => book )
20
46
0.66875
c4cb6f631a45711cdfbed1d419fdaf2220364227
504
js
JavaScript
redbubble/node_modules/@redbubble/design-system/react/Icons/List.js
vunamhung/codebases
f1d4beccca4e57c2684d281464b9ae462f76ee65
[ "MIT" ]
null
null
null
redbubble/node_modules/@redbubble/design-system/react/Icons/List.js
vunamhung/codebases
f1d4beccca4e57c2684d281464b9ae462f76ee65
[ "MIT" ]
null
null
null
redbubble/node_modules/@redbubble/design-system/react/Icons/List.js
vunamhung/codebases
f1d4beccca4e57c2684d281464b9ae462f76ee65
[ "MIT" ]
null
null
null
// This file was generated by https://github.com/redbubble/design/blob/master/scripts/generateIcons.js import React from 'react'; import Icon from '../Icon'; const ListIcon = props => <Icon {...props} dangerouslySetIcon={'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path d="M13 22H3a1 1 0 010-2h10a1 1 0 010 2zm7-4H4a2 2 0 01-2-2V4a2 2 0 012-2h16a2 2 0 012 2v12a2 2 0 01-2 2zM4 4v12h16V4z"/></svg>'} />; ListIcon.displayName = 'ListIcon'; export default ListIcon;
50.4
282
0.720238
c4cdb76f322a43a19f65be9e539cffe8e048a315
2,194
js
JavaScript
src/components/contact/ContactInstructions.js
leanjs/leanjscom-react
58c19e0abf6352a9c32b41c7cd7f1e27ad9c7601
[ "MIT" ]
null
null
null
src/components/contact/ContactInstructions.js
leanjs/leanjscom-react
58c19e0abf6352a9c32b41c7cd7f1e27ad9c7601
[ "MIT" ]
6
2020-07-20T18:45:16.000Z
2022-02-13T13:37:27.000Z
src/components/contact/ContactInstructions.js
leanjs/leanjscom-react
58c19e0abf6352a9c32b41c7cd7f1e27ad9c7601
[ "MIT" ]
null
null
null
import React from 'react' import styled from 'styled-components' import Link, { styleChildLinkColor, MailtoLink } from '../navigation/Link' import Grid, { Col, Row } from '../layout/Grid' import Section from '../layout/Section' import { LIGHTGREY, MEDIUMGREY, DARKGREY, EXTRADARKGREY, WHITE, SPACING_MEDIUM, } from '../../config/styles' import { SCREEN_XS_MAX } from '../utils' import ContactUsBullet from '../bullets/ContactUsBullet' import { H2, H4, P } from '../text' import ContactForm from './ContactForm' import Ul, { Li } from '../layout/Ul' const LinkList = styled(Ul)` padding-left: 0; list-style: none; margin-left: 0; ${styleChildLinkColor(WHITE)}; ` const ContactInstructions = () => ( <Section dark> <Grid> <Row> <H2> <a name="contact" />We'd love to chat </H2> </Row> <Row> <Col md={5}> <P>Let's start a conversation right now! Here's how:</P> <LinkList> <Li> <a href="tel:+44 20 8123 8184"> <ContactUsBullet image="phone" />Phone +44 20 8123 8184 </a> </Li> <Li> <MailtoLink to="hello@leanjs.com"> <ContactUsBullet image="email" />Email hello@leanjs.com </MailtoLink> </Li> <Li> <Link to="https://twitter.com/leanjscom"> <ContactUsBullet image="twitter" />Tweet us @leanjscom </Link> </Li> <Li> <Link to="https://www.instagram.com/leanjscom/"> <ContactUsBullet image="instagram" />Instagram us @leanjscom </Link> </Li> <Li> <ContactUsBullet image="office" />Visit us at WeWork Moorgate, 1 Fore St Ave, London, EC2Y 9DT -{' '} <Link to="https://goo.gl/maps/jsLZCb4Yi352">See on map</Link> </Li> </LinkList> </Col> <Col md={1} /> <Col md={5}> <H4>Or fill out our contact form</H4> <ContactForm /> </Col> </Row> </Grid> </Section> ) export default ContactInstructions
28.128205
78
0.530538
c4cdc423c4986dc39a7cf288064323a179211b35
1,208
js
JavaScript
helper/rm-package.js
gautham-juego/njs2-cli
f61489a874597952d6b3d9105fee77eac43eaaaf
[ "MIT" ]
null
null
null
helper/rm-package.js
gautham-juego/njs2-cli
f61489a874597952d6b3d9105fee77eac43eaaaf
[ "MIT" ]
null
null
null
helper/rm-package.js
gautham-juego/njs2-cli
f61489a874597952d6b3d9105fee77eac43eaaaf
[ "MIT" ]
2
2021-06-30T13:35:59.000Z
2021-11-07T06:05:21.000Z
const path = require('path'); const child_process = require('child_process'); const fs = require('fs'); module.exports.execute = (CLI_KEYS, CLI_ARGS) => { try { if (!fs.existsSync(`${path.resolve(process.cwd(), `package.json`)}`)) throw new Error('Run from project root direcory: njs2 rm-package <package-name> (Eg: njs2-auth-email)'); const packageJson = require(`${path.resolve(process.cwd(), `package.json`)}`); if (packageJson['njs2-type'] != 'project') { throw new Error('Run from project root direcory: njs2 rm-package <package-name> (Eg: njs2 rm-package njs2-auth-email)'); } let packageName = CLI_ARGS[0]; if (!packageName || packageName.length == 0) { throw new Error('Invalid package name'); } const packageExists = Object.keys(packageJson.dependencies).filter(package => package == packageName); if (packageExists.length == 0) { throw new Error("Package Dose not exists!"); } child_process.execSync(`npm uninstall ${packageName}`, { stdio: "inherit" }); child_process.execSync(`rm -rf "${path.resolve(process.cwd(), `njs2_modules/${packageName}`)}"`, { stdio: "inherit" }); } catch (e) { console.error(e); } };
40.266667
126
0.653146
c4ce062a3c310b36b8858ad7d94c253e16506e95
8,232
js
JavaScript
public/javascripts/application.js
jbripley/brazil
ce969edb6b93625136e8dc5e6210d29b9a05e7c3
[ "MIT" ]
3
2016-05-08T18:56:00.000Z
2020-02-12T01:37:04.000Z
public/javascripts/application.js
jbripley/brazil
ce969edb6b93625136e8dc5e6210d29b9a05e7c3
[ "MIT" ]
null
null
null
public/javascripts/application.js
jbripley/brazil
ce969edb6b93625136e8dc5e6210d29b9a05e7c3
[ "MIT" ]
1
2020-09-30T13:31:12.000Z
2020-09-30T13:31:12.000Z
jQuery.ajaxSetup({dataType: 'html'}) // Brazil namespace var brazil = function() { function form_insert_ajax_submit(options) { var defaults = { show_form: '', inserted_fieldset: '', response_container: '', success: function(){}, error: function(){}, done: function(){} }; var settings = jQuery.extend(defaults, options); jQuery(settings.inserted_fieldset).find('form').ajaxForm({ beforeSubmit: function(formData, jqForm, options) { jQuery('input[type="submit"]', jqForm).attr('disabled', 'disabled'); }, success: function(responseText, statusText) { jQuery(settings.inserted_fieldset).remove(); jQuery(settings.response_container).hide(); jQuery(settings.response_container).empty().append(responseText); settings.success(); settings.done(); jQuery(settings.show_form).show(); jQuery(settings.response_container).show(); }, error: function(XMLHttpRequest, textStatus, errorThrown) { jQuery(settings.inserted_fieldset).replaceWith(XMLHttpRequest.responseText); settings.error(); settings.done(); form_insert_ajax_submit(options); } }); jQuery(settings.inserted_fieldset).find('.form_close').show(); jQuery(settings.inserted_fieldset).find('.form_close').live("click", function() { jQuery(settings.inserted_fieldset).remove(); jQuery(settings.show_form).show(); settings.done(); return false; }); } function form_inline_ajax_submit(options) { var defaults = { inserted_fieldset: '', form_container: null, success: function(){}, error: function(){}, done: function(){} }; var settings = jQuery.extend(defaults, options); settings.form_container.find('form').ajaxForm({ beforeSubmit: function(formData, jqForm, options) { jQuery('input[type="submit"]', jqForm).attr('disabled', 'disabled'); }, success: function(responseText, statusText) { settings.form_container.replaceWith(responseText); settings.success(); settings.done(); }, error: function(XMLHttpRequest, textStatus, errorThrown) { settings.form_container.empty().append(XMLHttpRequest.responseText); settings.error(); settings.done(); form_inline_ajax_submit(options); } }); jQuery(settings.inserted_fieldset).find('.form_close').show(); jQuery(settings.inserted_fieldset).find('.form_close').live("click", function() { jQuery.get(settings.form_container.children('form').attr('action'), function(response) { settings.form_container.replaceWith(response); settings.done(); }); return false; }); } return { move : { scrollable: function(id) { jQuery(id).css("position", "relative"); jQuery(id).scrollFollow(); } }, flash : { notice: function() { jQuery.get('/flash/notice', function(response) { jQuery('#notice').hide().empty().append(response).fadeIn('slow', function() { setTimeout('jQuery("#notice").fadeOut()', 3000); }); }); }, discard: function() { jQuery.get('/flash/notice', function() { }); } }, manipulate: { syntax_highlight: function() { if (typeof SyntaxHighlighter != "undefined") { SyntaxHighlighter.config.clipboardSwf = '/javascripts/syntaxhighlighter/clipboard.swf'; SyntaxHighlighter.defaults.gutter = false; SyntaxHighlighter.highlight(); } }, expand: function(options) { var defaults = { expand_button: '', collapse_button: '', expand_container: '' }; var settings = jQuery.extend(defaults, options); jQuery(settings.expand_button).live("click", function() { jQuery.get(this.href, function(response) { jQuery(settings.expand_button).parents(settings.expand_container).replaceWith(response); }); return false; }); } }, form : { inline: function(options) { var defaults = { show_form: '', form_container: '', success: function(){}, error: function(){}, done: function(){} }; var settings = jQuery.extend(defaults, options); jQuery(settings.show_form).live("click", function() { var show_form = this; jQuery.get(this.href, function(response) { var form_container = jQuery(show_form).parents(settings.form_container); form_container.empty().append(response).show('blind'); form_inline_ajax_submit({ form_container: form_container, inserted_fieldset: settings.inserted_fieldset, success: settings.success, error: settings.error, done: settings.done }); }); return false; }); }, insert: function(options) { var defaults = { show_form: '', form_container: '', inserted_fieldset: '', response_container: '', success: function(){}, error: function(){}, done: function(){} }; var settings = jQuery.extend(defaults, options); jQuery(settings.show_form).live("click", function() { jQuery(this).hide(); jQuery.get(this.href, function(response) { jQuery(response).prependTo(settings.form_container); jQuery(settings.inserted_fieldset).show("drop", { direction: 'left' }); form_insert_ajax_submit({ inserted_fieldset: settings.inserted_fieldset, response_container: settings.response_container, show_form: settings.show_form, success: settings.success, error: settings.error, done: settings.done }); }); return false; }); }, insert_only: function(options) { var defaults = { show_form: '', form_container: '', inserted_fieldset: '', done: function(){} }; var settings = jQuery.extend(defaults, options); jQuery(settings.show_form).live("click", function() { jQuery(this).hide(); jQuery.get(this.href, function(response) { jQuery(response).prependTo(settings.form_container); jQuery(settings.inserted_fieldset).show("drop", { direction: 'left' }); jQuery(settings.inserted_fieldset).find('.form_close').show(); jQuery(settings.inserted_fieldset).find('.form_close').live("click", function() { jQuery(settings.inserted_fieldset).remove(); jQuery(settings.show_form).show(); settings.done(); return false; }); }); return false; }); }, existing: function(options) { var defaults = { form_container: '', response_container: '', success: function(){}, error: function(){}, done: function(){} }; var settings = jQuery.extend(defaults, options); jQuery(settings.form_container).find('form').ajaxForm({ beforeSubmit: function(formData, jqForm, options) { jQuery('input[type="submit"]', jqForm).attr('disabled', 'disabled'); }, success: function(responseText, statusText) { jQuery(settings.response_container).hide(); jQuery(settings.response_container).empty().append(responseText); settings.success(); jQuery(settings.form_container).find('#form_error').hide(); jQuery(settings.form_container).find('.fieldWithErrors').removeClass('fieldWithErrors'); jQuery(settings.form_container).find('input[type="submit"]').removeAttr('disabled'); jQuery(settings.response_container).show(); settings.done(); }, error: function(XMLHttpRequest, textStatus, errorThrown) { jQuery(settings.form_container).replaceWith(XMLHttpRequest.responseText); settings.error(); settings.done(); brazil.form.existing(options); } }); } } } }();
35.330472
172
0.596939
c4ce6ef1e29837c7697c8b7b398fd9c640767d89
9,579
js
JavaScript
components/Header.js
WeCare-Online-Clinic/wecare-mob-expo
f0a60fd28f87da5732036cf3b9012f04a65faa59
[ "MIT" ]
1
2021-09-17T12:40:55.000Z
2021-09-17T12:40:55.000Z
components/Header.js
WeCare-Online-Clinic/wecare-mob-expo
f0a60fd28f87da5732036cf3b9012f04a65faa59
[ "MIT" ]
null
null
null
components/Header.js
WeCare-Online-Clinic/wecare-mob-expo
f0a60fd28f87da5732036cf3b9012f04a65faa59
[ "MIT" ]
null
null
null
import React, {useState, useEffect} from 'react' import {useSelector, useDispatch} from 'react-redux'; import { View, Text, StyleSheet, Dimensions, Modal, SafeAreaView, ScrollView, TouchableOpacity} from 'react-native' // import FontAwesome5Icon from 'react-native-vector-icons/fontawesome5'; import FontAwesome5 from 'react-native-vector-icons/FontAwesome5'; import { styles } from '../styles/global'; import ActionButton from '../components/Button' import axios from 'axios' import Constants from '../utils/Constants' // import Clock from 'react-live-clock' import Clock from './Clock' async function get_messages(userId) { let message_list = [] try { await axios .get(Constants.API_BASE_URL + '/patient/message/list/' + userId) .then((res) => { if (res.status == 200) { message_list = res.data console.log("dataaaa", res.data) } }) return message_list } catch (error) { console.log(error) } } const Header = () => { const { width, height } = Dimensions.get("window"); const user = useSelector((state) => state); const userData = user.login.user[0] const userId = userData.id // const userId = 200004 const [currentTime, setCurrentTime] = useState(''); const [currentDate, setCurrentDate] = useState(''); const [messageList, setMessageList] = useState({ clinicMessages: [], clinicDateMessages: [], patientMessages: [], }) const [clinicMessages, setClinicMessages] = useState([]) useEffect(() => { get_messages(userId).then((res) => { setMessageList(res) // console.log('messssssssssssga' , res) if (res) { setClinicMessages(res.clinicDateMessages.concat(res.clinicMessages)) } }) var date = new Date().getDate(); //Current Date var month = new Date().getMonth() + 1; //Current Month var year = new Date().getFullYear(); //Current Year var hours = new Date().getHours(); //Current Hours var min = new Date().getMinutes(); //Current Minutes var sec = new Date().getSeconds(); //Current Seconds if(min <=9 ){ min = '0'+min } setCurrentTime( // date + '/' + month + '/' + year // + ' ' + hours + ':' + min // + ':' + sec ); setCurrentDate( date + '/' + month + '/' + year ) }, []); const [isModalVisible, setModalVisible] = useState(false); const [isModal2Visible, setModal2Visible] = useState(false); const [notiData, setNotidata] = useState(false); const NotificationView = () => { setModalVisible(!isModalVisible) // console.log("pressssss", notiData) } const list = () => { setModal2Visible(!isModal2Visible) }; return ( <View style={[styless.row , { paddingHorizontal: 0}]}> <View > <Text style={styless.dateTime}> {currentDate} </Text> <View style={[styless.time, {marginHorizontal: 15}]}> <Clock/> </View> </View> <View style={styless.notiIcon}> <FontAwesome5 name="envelope-open-text" size={30} color={'#1B3E72'} onPress={() => { setModalVisible(!isModalVisible) }} /> </View> <Modal animationType="slide" transparent visible={isModalVisible} presentationStyle="overFullScreen" onDismiss={()=> {setModalVisible(!isModalVisible)}}> <View style={styles.viewWrapper}> <View style={[styles.modalView , {transform: [{ translateX: -(width * 0.4) }, { translateY: -(height * 0.49) }],}]}> <View style={[styles.row ,{paddingVertical: 10}]}> <Text style={[styles.H1 ,{color: "#1B3E72"}]}> Notifications</Text> </View> <View style={[styles.card ,{paddingVertical: 10, width: '90%' }]}> <Text style={[styles.pBold ,{color: "#1B3E72", textAlign: 'center'}]}>Public Notifications</Text> {messageList.clinicMessages.map((row, index) => ( <View key={index} style={[styles.row, {paddingHorizontal: 30, marginVertical: 10}]}> <Text style={styles.p}>{row.id && row.clinic.name} Clinic</Text> <View style={{marginLeft: 'auto', marginRight: 10}}> <ActionButton text={'View'} onPress={() => {list(), setNotidata(row) }}/> </View> </View> ))} </View> <View style={[styles.card ,{paddingVertical: 10, width: '90%' }]}> <Text style={[styles.pBold ,{color: "#1B3E72", textAlign: 'center'}]}>Private Notifications</Text> {messageList && messageList.patientMessages && messageList.patientMessages .map((row, index) => ( <View key={index} style={[styles.row, {paddingHorizontal: 10, marginVertical: 5}]}> <Text style={[styles.p, {textAlign: 'justify'}]}>{row.id && row.message } </Text> </View> ))} </View> <View style={[styles.row, {paddingHorizontal: 32, paddingTop: 20}]}> <View style={{flex: 2}}> <ActionButton text="Close" onPress={() => setModalVisible(!isModalVisible)} /> </View> </View> </View> </View> </Modal> <Modal animationType="slide" transparent visible={isModal2Visible} presentationStyle="overFullScreen" onDismiss={()=> {setModal2Visible(!isModal2Visible)}}> <View style={styles.viewWrapper}> <View style={[styles.modalView , {transform: [{ translateX: -(width * 0.4) }, { translateY: -(height * 0.3) }],}]}> <View style={[styles.card ,{paddingVertical: 10, width: '90%' }]}> <Text style={[styles.p18 ,{color: "#1B3E72", textAlign: 'center'}]}> {notiData.id && notiData.clinic.name} Clinic</Text> <View style={[{flex: 8, flexDirection: "row" }]}> <View style={[styles.cardI, {flex: 2,}]}> <Text style={styles.p}>Date </Text> <Text style={styles.p}>Time </Text> </View> <View style={[styles.cardI, {flex: 4,}]}> <Text style={styles.p}>- {notiData.id && notiData.date }</Text> <Text style={styles.p}>- {notiData.id && notiData.time }</Text> </View> </View> <Text style={[styles.pBold, {paddingHorizontal: 25, textAlign: 'justify'}]}> {notiData.id && notiData.message}</Text> </View> {/** This button is responsible to close the modal */} <View style={[styles.row, {paddingHorizontal: 32, paddingTop: 20}]}> <View style={{flex: 2}}> <ActionButton text="Close" onPress={() => setModal2Visible(!isModal2Visible)} /> </View> </View> </View> </View> </Modal> </View> ) } export default Header const { width } = Dimensions.get("window"); const styless = StyleSheet.create({ dateTime: { margin: 0, marginHorizontal: 21, fontSize: 14, color: "#1B3E72", }, time: { fontSize: 23, marginHorizontal: 21, color: "#1B3E72", }, row: { flexDirection: 'row', marginVertical: 15, marginHorizontal: 4, // backgroundColor: 'gray', }, notiIcon: { flexDirection: "row", flexWrap: 'wrap', marginLeft: "auto", marginRight: 25, alignContent: 'center', alignItems: 'center', } })
42.573333
173
0.4418
c4ce898f3943299bd4721b9004c11946d18b922a
785
js
JavaScript
cypress/integration/is-on-spec.js
rafael-anachoreta/cypress-skip-test
60ea117c85eaf5daa9299c1a10e95f85f16322c6
[ "MIT" ]
153
2019-11-07T15:39:11.000Z
2022-03-18T03:04:08.000Z
cypress/integration/is-on-spec.js
rafael-anachoreta/cypress-skip-test
60ea117c85eaf5daa9299c1a10e95f85f16322c6
[ "MIT" ]
157
2019-11-07T15:07:06.000Z
2022-03-26T15:57:18.000Z
cypress/integration/is-on-spec.js
rafael-anachoreta/cypress-skip-test
60ea117c85eaf5daa9299c1a10e95f85f16322c6
[ "MIT" ]
10
2019-11-26T17:36:18.000Z
2021-06-10T10:32:15.000Z
/// <reference types="cypress" /> import { isOn } from '../..' it('returns true for current browser', () => { expect(isOn(Cypress.browser.name)).to.be.true }) it('returns true for current platform', () => { expect(isOn(Cypress.platform)).to.be.true }) it('returns true for current url', () => { const url = Cypress.config('baseUrl') expect(url).to.be.a('string') expect(isOn(url)).to.be.true expect(isOn('foo.com')).to.be.false }) it('uses variable ENVIRONMENT', () => { Cypress.env('ENVIRONMENT', 'current test') expect(isOn('current test'), 'matches current ENVIRONMENT').to.be.true expect(isOn('anywhere else'), 'any other value').to.be.false Cypress.env('ENVIRONMENT', 'test env 2') expect(isOn('test env 2'), 'matches second ENVIRONMENT').to.be.true })
29.074074
72
0.661146
c4cee194e5b9cd1f9591868fade74ec124111692
885
js
JavaScript
node_modules/@wordpress/block-editor/build-module/components/block-icon/index.native.js
ajchdev/outside-event
edaa958d74d5a1431f617bcbcef0d2e838103bd2
[ "MIT" ]
null
null
null
node_modules/@wordpress/block-editor/build-module/components/block-icon/index.native.js
ajchdev/outside-event
edaa958d74d5a1431f617bcbcef0d2e838103bd2
[ "MIT" ]
null
null
null
node_modules/@wordpress/block-editor/build-module/components/block-icon/index.native.js
ajchdev/outside-event
edaa958d74d5a1431f617bcbcef0d2e838103bd2
[ "MIT" ]
null
null
null
import { createElement } from "@wordpress/element"; /** * External dependencies */ import { get } from 'lodash'; import { View } from 'react-native'; /** * WordPress dependencies */ import { Icon } from '@wordpress/components'; import { blockDefault } from '@wordpress/icons'; export default function BlockIcon(_ref) { var icon = _ref.icon, _ref$showColors = _ref.showColors, showColors = _ref$showColors === void 0 ? false : _ref$showColors; if (get(icon, ['src']) === 'block-default') { icon = { src: blockDefault }; } var renderedIcon = createElement(Icon, { icon: icon && icon.src ? icon.src : icon }); var style = showColors ? { backgroundColor: icon && icon.background, color: icon && icon.foreground } : {}; return createElement(View, { style: style }, renderedIcon); } //# sourceMappingURL=index.native.js.map
24.583333
72
0.644068
c4cf8d0a858071a09fb3d912aa417a3ab974fb86
621
js
JavaScript
src/translations/homepage.translations.js
ita-social-projects/horondi_client_fe
3f19d172e078c54ed9a63de562e35e7758579c20
[ "MIT" ]
17
2020-12-14T10:13:56.000Z
2022-02-15T14:50:03.000Z
src/translations/homepage.translations.js
ita-social-projects/horondi_client_fe
3f19d172e078c54ed9a63de562e35e7758579c20
[ "MIT" ]
1,651
2020-09-08T19:02:14.000Z
2022-03-31T21:11:01.000Z
src/translations/homepage.translations.js
ita-social-projects/horondi_client_fe
3f19d172e078c54ed9a63de562e35e7758579c20
[ "MIT" ]
5
2020-10-29T14:28:23.000Z
2022-01-15T12:36:06.000Z
export const HOME_BUTTONS = { 0: { NEWS: 'НОВИНИ', ABOUT_US: 'ПРО НАС', SEE_MORE: 'ДІЗНАТИСЬ БІЛЬШЕ', MOVE_TO_CATEGORY: 'ПЕРЕЙТИ ДО КАТЕГОРІЇ', MOVE_TO_CONSTRUCTOR: 'СТВОРИ СВІЙ СТИЛЬ', MOVE_TO_MODEL: 'ПЕРЕЙТИ ДО МОДЕЛІ', ALL_MODELS: 'ВСІ МОДЕЛІ', HIDE_MODELS: 'ПРИХОВАТИ', DETAILS: 'ДЕТАЛІ' }, 1: { NEWS: 'NEWS', ABOUT_US: 'ABOUT US', SEE_MORE: 'SEE MORE', MOVE_TO_CATEGORY: 'MOVE TO CATEGORY', MOVE_TO_CONSTRUCTOR: 'CREATE YOUR STYLE', MOVE_TO_MODEL: 'MOVE TO MODEL', ALL_MODELS: 'ALL MODELS', HIDE_MODELS: 'HIDE', DETAILS: 'DETAILS' } };
24.84
45
0.634461
c4d07a62bc3a00eeab20a0763acf9deb4a7571b4
1,937
js
JavaScript
frontend/scripts_angular/RanksController.js
mozvip/sports-predictions
c26e4791acffa3e62e1ae257ad4fd2294af12ad4
[ "Apache-2.0" ]
6
2016-04-12T18:52:37.000Z
2018-05-11T08:32:44.000Z
frontend/scripts_angular/RanksController.js
mozvip/sports-predictions
c26e4791acffa3e62e1ae257ad4fd2294af12ad4
[ "Apache-2.0" ]
18
2016-04-29T09:45:15.000Z
2022-01-21T23:15:43.000Z
frontend/scripts_angular/RanksController.js
mozvip/sports-predictions
c26e4791acffa3e62e1ae257ad4fd2294af12ad4
[ "Apache-2.0" ]
3
2016-05-20T14:25:30.000Z
2018-05-14T07:27:21.000Z
/** * Angular Controller -> RanksController * Contains ranking data in application. * init() * Get rankings for this community **/ angular.module('sports-predictions') .controller('RanksController', ['$scope', '$filter', '$location', 'UserService', 'RankingService', 'Notification', '$linq', 'NgTableParams', function($scope, $filter, $location, UserService, RankingService, Notification, $linq, NgTableParams){ $scope.Ranks = []; $scope.currentUser = UserService.getCurrentLogin(); $scope.init = function(){ var res = RankingService.getRanks(); res.then(function (result) { if (result.Ranks.RanksData != undefined){ $scope.Ranks = result.Ranks.RanksData; $scope.RanksParams = new NgTableParams({ page: 1, // show first page count: 20, // count per page }, { total: $scope.Ranks.length, // length of data getData: function($defer, params) { // use build-in angular filter var filteredData = params.filter() ? $filter('filter')($scope.Ranks, params.filter()) : $scope.Ranks; var orderedData = params.sorting() ? $filter('orderBy')(filteredData, params.orderBy()) : $scope.Ranks; params.total(orderedData.length); // set total for recalc pagination $defer.resolve(orderedData.slice((params.page() - 1) * params.count(), params.page() * params.count())); } }); } else Notification.error({message: result.Ranks.message, title: 'Erreur lors de la récupération du classement'}); }); } $scope.classCurentUser = function(rank){ if(rank.email == UserService.getCurrentLogin()) return "currentUser"; else return "notCurrentUser"; } $scope.whatArrow = function(rank){ if(rank.currentRanking > rank.previousRanking) return "arrow-down"; else if(rank.currentRanking < rank.previousRanking) return "arrow-up"; else return "arrow-right"; } }]);
33.396552
140
0.651007
c4d22d164ffd65c11fd4b6d06ad57e01256f68dc
1,818
js
JavaScript
src/index.js
shorwood/gptsh
d7a40dc3d2a151b7591202d3d4b7ab4b808c46e8
[ "MIT" ]
8
2021-05-27T08:22:32.000Z
2021-10-15T20:26:47.000Z
src/index.js
shorwood/gptsh
d7a40dc3d2a151b7591202d3d4b7ab4b808c46e8
[ "MIT" ]
24
2021-05-04T06:43:22.000Z
2022-03-10T09:07:55.000Z
src/index.js
shorwood/gptsh
d7a40dc3d2a151b7591202d3d4b7ab4b808c46e8
[ "MIT" ]
null
null
null
#!/usr/bin/env node //--- Import dependencies. const yargs = require('yargs/yargs') const { hideBin } = require('yargs/helpers') const uniq = require('lodash/uniq') const complete = require('./complete') const buildConfig = require('./buildConfig') const buildPrompt = require('./buildPrompt') //--- Parse argv arguments using 'yargs' package. const argv = yargs(hideBin(process.argv)) .usage('Usage: $0 <input> [options]') .example('$0 List all files of this directory | bash') .example('$0 Install the lodash package --secret <YOUR_SECRET_KEY> | bash') .example('$0 Delete the root directory --engine ada') .example('$0 Add remote from github with name shorwood/gptsh --max-tokens 32') .option('secret', {type: 'string', alias: 's', description: 'OpenAI API key for authentication'}) .option('engine', {type: 'string', alias: 'e', description: 'ID of the engine to use'}) .option('tokens', {type: 'number', alias: 't', description: 'Maximum number of tokens to consume', default: 100}) .option('temperature', {type: 'number',description: 'Higher values means the model will take more risks', default: 0.0}) .option('platform', {type: 'string', alias: 'p', description: 'Platform of the command to output'}) .option('n', {type: 'number', description: 'Number of completions to generate'}) .demandCommand() .help() .argv //--- Build the configuration object. const appConfig = buildConfig({ engineId: argv.engine, secret: argv.secret, max_tokens: argv.tokens, temperature: argv.temperature, n: argv.n, platform: argv.platform }) //--- Build the prompt string. const prompt = buildPrompt(argv._.join(' '), appConfig) //--- Compute the apporpirate shell command and output it. complete(prompt, appConfig).then(outputs => { for(output of uniq(outputs)) console.log(output.replace('$ ', '')) })
40.4
121
0.70132
c4d25a4b0c08fc8887beca28ecab9454a0a5087e
367
js
JavaScript
src/leetcode/valid-parentheses.js
zweimach/wiyata.js
7aeb8c3b4f421a4c4bb36429693d9bbb07c8a446
[ "MIT" ]
null
null
null
src/leetcode/valid-parentheses.js
zweimach/wiyata.js
7aeb8c3b4f421a4c4bb36429693d9bbb07c8a446
[ "MIT" ]
null
null
null
src/leetcode/valid-parentheses.js
zweimach/wiyata.js
7aeb8c3b4f421a4c4bb36429693d9bbb07c8a446
[ "MIT" ]
null
null
null
export function validParentheses(str) { const stack = []; const mappings = { "{": "}", "[": "]", "(": ")" }; const last = () => stack[stack.length - 1]; for (const st of str) { if (mappings[st]) { stack.push(st); } else if (mappings[last()] === st) { stack.pop(); } else { return false; } } return stack.length === 0; }
21.588235
52
0.493188
c4d419a4576960b8e7721c0bc2835b35b44271bb
62
js
JavaScript
crates/swc_ecma_minifier/tests/terser/compress/harmony/class_name_can_be_preserved/output.js
tamaroning/swc
4cf27769c9098be59419fc590bbc5e94bcad8b6e
[ "Apache-2.0" ]
1
2022-03-25T05:35:24.000Z
2022-03-25T05:35:24.000Z
crates/swc_ecma_minifier/tests/terser/compress/harmony/class_name_can_be_preserved/output.js
tamaroning/swc
4cf27769c9098be59419fc590bbc5e94bcad8b6e
[ "Apache-2.0" ]
null
null
null
crates/swc_ecma_minifier/tests/terser/compress/harmony/class_name_can_be_preserved/output.js
tamaroning/swc
4cf27769c9098be59419fc590bbc5e94bcad8b6e
[ "Apache-2.0" ]
null
null
null
function x() { (class a { }); class Foo { } }
8.857143
15
0.370968
c4d7ae0038a43e413867a00d66ac0dc383eb2d73
2,735
js
JavaScript
web/src/pages/contact-us.js
tsimons/metro-pest
c668db5f42d8e21f9575b0d66085161db24d26ed
[ "MIT" ]
null
null
null
web/src/pages/contact-us.js
tsimons/metro-pest
c668db5f42d8e21f9575b0d66085161db24d26ed
[ "MIT" ]
34
2019-10-30T08:18:26.000Z
2022-03-25T23:19:28.000Z
web/src/pages/contact-us.js
tsimons/metro-pest
c668db5f42d8e21f9575b0d66085161db24d26ed
[ "MIT" ]
null
null
null
import React from 'react' import { graphql } from 'gatsby' import cn from 'classnames' import { snakeToCamelObject } from '../lib/helpers' import BlockContent from '../components/block-content' import Container from '../components/container' import GraphQLErrorList from '../components/graphql-error-list' import SEO from '../components/seo' import Heading from '../components/Heading' import Layout from '../containers/layout' import AddressBlock from '../components/address-block' import Form from '../components/Form' import PhoneNumbers from '../components/PhoneNumbers'; import styles from './internal.module.css' import contactStyles from './contact.module.css' export const query = graphql` query ContactPageQuery { companyInfo: sanityCompanyInfo { name address city state zipCode email } phone: allSanityPhonenumber { edges { node { id area number } } } page: sanityPage(_id: { regex: "/(drafts.|)contact/" }) { id _id title _rawBody headingImage { asset { fluid { ...GatsbySanityImageFluid } } } seo { ...SEOFragment } social { ...SocialFragment } } } ` const ContactPage = props => { const { data, errors } = props if (errors) { return ( <Layout> <GraphQLErrorList errors={errors} /> </Layout> ) } const page = data && data.page const companyInfo = data && data.companyInfo const formattedPhoneNumbers = data.phone.edges.map(({ node }) => ({ heading: node.area, number: { number: node.number } })) return ( <Layout hideContact> <SEO {...page.seo} {...snakeToCamelObject(page.social)} /> <Container> <Heading title={page.title} image={page.headingImage.asset.fluid} /> <div className={cn(styles.pageContent, contactStyles.container)}> <div className={contactStyles.column}> <BlockContent blocks={page._rawBody || []} /> <PhoneNumbers numbers={formattedPhoneNumbers} vertical /> <AddressBlock email={companyInfo.email} name={companyInfo.name} address={companyInfo.address} city={companyInfo.city} state={companyInfo.state} zipCode={companyInfo.zipCode} /> </div> <div className={contactStyles.divider} /> <div className={contactStyles.column}> <Form /> </div> </div> </Container> </Layout> ) } export default ContactPage
23.577586
76
0.575503
c4d8f532efe8dc2a8c08dbffdb0642dfaa538f19
2,740
js
JavaScript
src/state.js
fossgis-routing-server/osrm-frontend
d58f04d2428d5cded3d51223164374ee9cbcdab2
[ "BSD-2-Clause" ]
9
2018-09-15T16:19:01.000Z
2022-01-14T16:13:04.000Z
src/state.js
fossgis-routing-server/osrm-frontend
d58f04d2428d5cded3d51223164374ee9cbcdab2
[ "BSD-2-Clause" ]
1
2018-09-19T13:45:50.000Z
2018-09-19T16:10:33.000Z
src/state.js
fossgis-routing-server/osrm-frontend
d58f04d2428d5cded3d51223164374ee9cbcdab2
[ "BSD-2-Clause" ]
7
2018-09-15T13:35:30.000Z
2022-01-05T05:52:41.000Z
'use strict'; var L = require('leaflet'); var links = require('./links'); var State = L.Class.extend({ options: { }, initialize: function(map, lrm_control, tools, default_options) { this._lrm = lrm_control; this._map = map; this._tools = tools; this.set(default_options); this._lrm.on('routeselected', function(e) { this.options.alternative = e.route.routesIndex; }, this); this._lrm.getPlan().on('waypointschanged', function() { this.options.waypoints = this._lrm.getWaypoints(); var ropt = this._lrm.options.router.options, i; for (i = 0; i < ropt.services.length; i++) { if (ropt.serviceUrl === ropt.services[i].path) this.options.service = i } this.update(); }.bind(this)); this._map.on('zoomend', function() { this.options.zoom = this._map.getZoom(); this.update(); }.bind(this)); this._map.on('moveend', function() { this.options.center = this._map.getCenter(); this.update(); }.bind(this)); this._tools.on('languagechanged', function(e) { this.options.language = e.language; this.reload(); }.bind(this)); this._tools.on('unitschanged', function(e) { this.options.units = e.unit; this.update(); }.bind(this)); }, get: function() { return this.options; }, set: function(options) { var self = this; L.setOptions(this, options); L.Util.setOptions(this._lrm.options.router, { serviceUrl: this._lrm.options.router.options.services[this.options.service].path}); var profileSelector = L.DomUtil.get("profile-selector"); profileSelector.selectedIndex = this.options.service; var services = self._lrm.options.router.options.services; L.DomEvent.addListener(profileSelector, 'change', function () { if (profileSelector.selectedIndex >= 0 && profileSelector.selectedIndex < services.length) { self._tools.setProfile(services[profileSelector.selectedIndex]); } }); if (this.options.service >= 0 && this.options.service < services.length) { self._tools.setProfile(services[this.options.service]); } this._lrm.setWaypoints(this.options.waypoints); this._map.setView(this.options.center, this.options.zoom); }, reload: function() { this.update(); window.location.reload(); }, // Update browser url update: function() { var baseURL = window.location.href.split('?')[0]; var newParms = links.format(this.options); var newURL = baseURL.concat('?').concat(newParms); window.location.hash = newParms; history.replaceState({}, 'Project OSRM Demo', newURL); }, }); module.exports = function(map, lrm_control, tools, default_options) { return new State(map, lrm_control, tools, default_options); };
34.683544
117
0.662044
c4dab31a9863a19d62e6b34be2641b40a5dd9928
387
js
JavaScript
src/components/UserInfo.js
mauriballes/react-tutorial
d0c8a731edfe9099074abccfca41c3cb0f0d3569
[ "MIT" ]
null
null
null
src/components/UserInfo.js
mauriballes/react-tutorial
d0c8a731edfe9099074abccfca41c3cb0f0d3569
[ "MIT" ]
null
null
null
src/components/UserInfo.js
mauriballes/react-tutorial
d0c8a731edfe9099074abccfca41c3cb0f0d3569
[ "MIT" ]
null
null
null
import React from 'react'; import Avatar from './Avatar'; export default class UserInfo extends React.Component { render() { return ( <div className="UserInfo"> <Avatar user={this.props.user} /> <div className="UserInfo-name"> {this.props.user.name} </div> </div> ); } }
25.8
55
0.49354
c4dae107e30acd8431e0993acb4ebf0c7d366c2a
711
js
JavaScript
api/controllers/techniciansCtrl.js
andrewcrane152/UtahPianoTuning
613f711d1cb5a33264b12d3a3b881bbd780944df
[ "Apache-2.0" ]
1
2015-08-14T17:57:50.000Z
2015-08-14T17:57:50.000Z
api/controllers/techniciansCtrl.js
andrewcrane152/UtahPianoTuning
613f711d1cb5a33264b12d3a3b881bbd780944df
[ "Apache-2.0" ]
null
null
null
api/controllers/techniciansCtrl.js
andrewcrane152/UtahPianoTuning
613f711d1cb5a33264b12d3a3b881bbd780944df
[ "Apache-2.0" ]
null
null
null
var Technician = require('../models/techniciansModel'); var User = require('../models/UserModel'); module.exports = { createTechnician: function(req, res) { console.log(req.body.technician); newService = req.body.technician.newTechnicianServices; newUser = req.body.technician.newTechnicianPerson; technicianInstance = new Technician(newService); userInstance = new User(newUser); response = {}; technicianInstance.save(function(err, result){ if (err) return res.status(500).json(err); response.newService = result; userInstance.save(function(err, result) { if (err) return res.status(500).json(err); response.newUser = result; return res.send(response); }); }); } };
30.913043
57
0.710267
c4db0bf7a9f6987624191942f171884ffd785ad3
186,736
js
JavaScript
asset/jui2/library.min.js
caphodel/krs_uniga
e409ec8636480dea392b76b4c329493e93b00fad
[ "MIT" ]
1
2016-07-30T04:53:42.000Z
2016-07-30T04:53:42.000Z
asset/jui2/library.min.js
caphodel/krs_uniga
e409ec8636480dea392b76b4c329493e93b00fad
[ "MIT" ]
6
2016-07-30T04:12:41.000Z
2016-07-30T14:15:51.000Z
asset/jui2/library.min.js
caphodel/krs_uniga
e409ec8636480dea392b76b4c329493e93b00fad
[ "MIT" ]
null
null
null
/*! jui2 24-11-2015 Copyright Deddy Lasmono Putro */ jQuery.base64=function(){function a(a,b){var c=f.indexOf(a.charAt(b));if(-1===c)throw"Cannot decode base64";return c}function b(b){var c,d,f=0,g=b.length,h=[];if(b=String(b),0===g)return b;if(g%4!==0)throw"Cannot decode base64";for(b.charAt(g-1)===e&&(f=1,b.charAt(g-2)===e&&(f=2),g-=4),c=0;g>c;c+=4)d=a(b,c)<<18|a(b,c+1)<<12|a(b,c+2)<<6|a(b,c+3),h.push(String.fromCharCode(d>>16,d>>8&255,255&d));switch(f){case 1:d=a(b,c)<<18|a(b,c+1)<<12|a(b,c+2)<<6,h.push(String.fromCharCode(d>>16,d>>8&255));break;case 2:d=a(b,c)<<18|a(b,c+1)<<12,h.push(String.fromCharCode(d>>16))}return h.join("")}function c(a,b){var c=a.charCodeAt(b);if(c>255)throw"INVALID_CHARACTER_ERR: DOM Exception 5";return c}function d(a){if(1!==arguments.length)throw"SyntaxError: exactly one argument required";a=String(a);var b,d,g=[],h=a.length-a.length%3;if(0===a.length)return a;for(b=0;h>b;b+=3)d=c(a,b)<<16|c(a,b+1)<<8|c(a,b+2),g.push(f.charAt(d>>18)),g.push(f.charAt(d>>12&63)),g.push(f.charAt(d>>6&63)),g.push(f.charAt(63&d));switch(a.length-h){case 1:d=c(a,b)<<16,g.push(f.charAt(d>>18)+f.charAt(d>>12&63)+e+e);break;case 2:d=c(a,b)<<16|c(a,b+1)<<8,g.push(f.charAt(d>>18)+f.charAt(d>>12&63)+f.charAt(d>>6&63)+e)}return g.join("")}var e="=",f="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",g="1.0";return{decode:b,encode:d,VERSION:g}}(jQuery),function(a){function b(a,b,c){switch(arguments.length){case 2:return null!=a?a:b;case 3:return null!=a?a:null!=b?b:c;default:throw new Error("Implement me")}}function c(){return{empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1}}function d(a,b){function c(){mb.suppressDeprecationWarnings===!1&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+a)}var d=!0;return j(function(){return d&&(c(),d=!1),b.apply(this,arguments)},b)}function e(a,b){return function(c){return m(a.call(this,c),b)}}function f(a,b){return function(c){return this.lang().ordinal(a.call(this,c),b)}}function g(){}function h(a){z(a),j(this,a)}function i(a){var b=s(a),c=b.year||0,d=b.quarter||0,e=b.month||0,f=b.week||0,g=b.day||0,h=b.hour||0,i=b.minute||0,j=b.second||0,k=b.millisecond||0;this._milliseconds=+k+1e3*j+6e4*i+36e5*h,this._days=+g+7*f,this._months=+e+3*d+12*c,this._data={},this._bubble()}function j(a,b){for(var c in b)b.hasOwnProperty(c)&&(a[c]=b[c]);return b.hasOwnProperty("toString")&&(a.toString=b.toString),b.hasOwnProperty("valueOf")&&(a.valueOf=b.valueOf),a}function k(a){var b,c={};for(b in a)a.hasOwnProperty(b)&&Ab.hasOwnProperty(b)&&(c[b]=a[b]);return c}function l(a){return 0>a?Math.ceil(a):Math.floor(a)}function m(a,b,c){for(var d=""+Math.abs(a),e=a>=0;d.length<b;)d="0"+d;return(e?c?"+":"":"-")+d}function n(a,b,c,d){var e=b._milliseconds,f=b._days,g=b._months;d=null==d?!0:d,e&&a._d.setTime(+a._d+e*c),f&&hb(a,"Date",gb(a,"Date")+f*c),g&&fb(a,gb(a,"Month")+g*c),d&&mb.updateOffset(a,f||g)}function o(a){return"[object Array]"===Object.prototype.toString.call(a)}function p(a){return"[object Date]"===Object.prototype.toString.call(a)||a instanceof Date}function q(a,b,c){var d,e=Math.min(a.length,b.length),f=Math.abs(a.length-b.length),g=0;for(d=0;e>d;d++)(c&&a[d]!==b[d]||!c&&u(a[d])!==u(b[d]))&&g++;return g+f}function r(a){if(a){var b=a.toLowerCase().replace(/(.)s$/,"$1");a=bc[a]||cc[b]||b}return a}function s(a){var b,c,d={};for(c in a)a.hasOwnProperty(c)&&(b=r(c),b&&(d[b]=a[c]));return d}function t(b){var c,d;if(0===b.indexOf("week"))c=7,d="day";else{if(0!==b.indexOf("month"))return;c=12,d="month"}mb[b]=function(e,f){var g,h,i=mb.fn._lang[b],j=[];if("number"==typeof e&&(f=e,e=a),h=function(a){var b=mb().utc().set(d,a);return i.call(mb.fn._lang,b,e||"")},null!=f)return h(f);for(g=0;c>g;g++)j.push(h(g));return j}}function u(a){var b=+a,c=0;return 0!==b&&isFinite(b)&&(c=b>=0?Math.floor(b):Math.ceil(b)),c}function v(a,b){return new Date(Date.UTC(a,b+1,0)).getUTCDate()}function w(a,b,c){return bb(mb([a,11,31+b-c]),b,c).week}function x(a){return y(a)?366:365}function y(a){return a%4===0&&a%100!==0||a%400===0}function z(a){var b;a._a&&-2===a._pf.overflow&&(b=a._a[tb]<0||a._a[tb]>11?tb:a._a[ub]<1||a._a[ub]>v(a._a[sb],a._a[tb])?ub:a._a[vb]<0||a._a[vb]>23?vb:a._a[wb]<0||a._a[wb]>59?wb:a._a[xb]<0||a._a[xb]>59?xb:a._a[yb]<0||a._a[yb]>999?yb:-1,a._pf._overflowDayOfYear&&(sb>b||b>ub)&&(b=ub),a._pf.overflow=b)}function A(a){return null==a._isValid&&(a._isValid=!isNaN(a._d.getTime())&&a._pf.overflow<0&&!a._pf.empty&&!a._pf.invalidMonth&&!a._pf.nullInput&&!a._pf.invalidFormat&&!a._pf.userInvalidated,a._strict&&(a._isValid=a._isValid&&0===a._pf.charsLeftOver&&0===a._pf.unusedTokens.length)),a._isValid}function B(a){return a?a.toLowerCase().replace("_","-"):a}function C(a,b){return b._isUTC?mb(a).zone(b._offset||0):mb(a).local()}function D(a,b){return b.abbr=a,zb[a]||(zb[a]=new g),zb[a].set(b),zb[a]}function E(a){delete zb[a]}function F(a){var b,c,d,e,f=0,g=function(a){if(!zb[a]&&Bb)try{require("./lang/"+a)}catch(b){}return zb[a]};if(!a)return mb.fn._lang;if(!o(a)){if(c=g(a))return c;a=[a]}for(;f<a.length;){for(e=B(a[f]).split("-"),b=e.length,d=B(a[f+1]),d=d?d.split("-"):null;b>0;){if(c=g(e.slice(0,b).join("-")))return c;if(d&&d.length>=b&&q(e,d,!0)>=b-1)break;b--}f++}return mb.fn._lang}function G(a){return a.match(/\[[\s\S]/)?a.replace(/^\[|\]$/g,""):a.replace(/\\/g,"")}function H(a){var b,c,d=a.match(Fb);for(b=0,c=d.length;c>b;b++)d[b]=hc[d[b]]?hc[d[b]]:G(d[b]);return function(e){var f="";for(b=0;c>b;b++)f+=d[b]instanceof Function?d[b].call(e,a):d[b];return f}}function I(a,b){return a.isValid()?(b=J(b,a.lang()),dc[b]||(dc[b]=H(b)),dc[b](a)):a.lang().invalidDate()}function J(a,b){function c(a){return b.longDateFormat(a)||a}var d=5;for(Gb.lastIndex=0;d>=0&&Gb.test(a);)a=a.replace(Gb,c),Gb.lastIndex=0,d-=1;return a}function K(a,b){var c,d=b._strict;switch(a){case"Q":return Rb;case"DDDD":return Tb;case"YYYY":case"GGGG":case"gggg":return d?Ub:Jb;case"Y":case"G":case"g":return Wb;case"YYYYYY":case"YYYYY":case"GGGGG":case"ggggg":return d?Vb:Kb;case"S":if(d)return Rb;case"SS":if(d)return Sb;case"SSS":if(d)return Tb;case"DDD":return Ib;case"MMM":case"MMMM":case"dd":case"ddd":case"dddd":return Mb;case"a":case"A":return F(b._l)._meridiemParse;case"X":return Pb;case"Z":case"ZZ":return Nb;case"T":return Ob;case"SSSS":return Lb;case"MM":case"DD":case"YY":case"GG":case"gg":case"HH":case"hh":case"mm":case"ss":case"ww":case"WW":return d?Sb:Hb;case"M":case"D":case"d":case"H":case"h":case"m":case"s":case"w":case"W":case"e":case"E":return Hb;case"Do":return Qb;default:return c=new RegExp(T(S(a.replace("\\","")),"i"))}}function L(a){a=a||"";var b=a.match(Nb)||[],c=b[b.length-1]||[],d=(c+"").match(_b)||["-",0,0],e=+(60*d[1])+u(d[2]);return"+"===d[0]?-e:e}function M(a,b,c){var d,e=c._a;switch(a){case"Q":null!=b&&(e[tb]=3*(u(b)-1));break;case"M":case"MM":null!=b&&(e[tb]=u(b)-1);break;case"MMM":case"MMMM":d=F(c._l).monthsParse(b),null!=d?e[tb]=d:c._pf.invalidMonth=b;break;case"D":case"DD":null!=b&&(e[ub]=u(b));break;case"Do":null!=b&&(e[ub]=u(parseInt(b,10)));break;case"DDD":case"DDDD":null!=b&&(c._dayOfYear=u(b));break;case"YY":e[sb]=mb.parseTwoDigitYear(b);break;case"YYYY":case"YYYYY":case"YYYYYY":e[sb]=u(b);break;case"a":case"A":c._isPm=F(c._l).isPM(b);break;case"H":case"HH":case"h":case"hh":e[vb]=u(b);break;case"m":case"mm":e[wb]=u(b);break;case"s":case"ss":e[xb]=u(b);break;case"S":case"SS":case"SSS":case"SSSS":e[yb]=u(1e3*("0."+b));break;case"X":c._d=new Date(1e3*parseFloat(b));break;case"Z":case"ZZ":c._useUTC=!0,c._tzm=L(b);break;case"dd":case"ddd":case"dddd":d=F(c._l).weekdaysParse(b),null!=d?(c._w=c._w||{},c._w.d=d):c._pf.invalidWeekday=b;break;case"w":case"ww":case"W":case"WW":case"d":case"e":case"E":a=a.substr(0,1);case"gggg":case"GGGG":case"GGGGG":a=a.substr(0,2),b&&(c._w=c._w||{},c._w[a]=u(b));break;case"gg":case"GG":c._w=c._w||{},c._w[a]=mb.parseTwoDigitYear(b)}}function N(a){var c,d,e,f,g,h,i,j;c=a._w,null!=c.GG||null!=c.W||null!=c.E?(g=1,h=4,d=b(c.GG,a._a[sb],bb(mb(),1,4).year),e=b(c.W,1),f=b(c.E,1)):(j=F(a._l),g=j._week.dow,h=j._week.doy,d=b(c.gg,a._a[sb],bb(mb(),g,h).year),e=b(c.w,1),null!=c.d?(f=c.d,g>f&&++e):f=null!=c.e?c.e+g:g),i=cb(d,e,f,h,g),a._a[sb]=i.year,a._dayOfYear=i.dayOfYear}function O(a){var c,d,e,f,g=[];if(!a._d){for(e=Q(a),a._w&&null==a._a[ub]&&null==a._a[tb]&&N(a),a._dayOfYear&&(f=b(a._a[sb],e[sb]),a._dayOfYear>x(f)&&(a._pf._overflowDayOfYear=!0),d=Z(f,0,a._dayOfYear),a._a[tb]=d.getUTCMonth(),a._a[ub]=d.getUTCDate()),c=0;3>c&&null==a._a[c];++c)a._a[c]=g[c]=e[c];for(;7>c;c++)a._a[c]=g[c]=null==a._a[c]?2===c?1:0:a._a[c];a._d=(a._useUTC?Z:Y).apply(null,g),null!=a._tzm&&a._d.setUTCMinutes(a._d.getUTCMinutes()+a._tzm)}}function P(a){var b;a._d||(b=s(a._i),a._a=[b.year,b.month,b.day,b.hour,b.minute,b.second,b.millisecond],O(a))}function Q(a){var b=new Date;return a._useUTC?[b.getUTCFullYear(),b.getUTCMonth(),b.getUTCDate()]:[b.getFullYear(),b.getMonth(),b.getDate()]}function R(a){if(a._f===mb.ISO_8601)return void V(a);a._a=[],a._pf.empty=!0;var b,c,d,e,f,g=F(a._l),h=""+a._i,i=h.length,j=0;for(d=J(a._f,g).match(Fb)||[],b=0;b<d.length;b++)e=d[b],c=(h.match(K(e,a))||[])[0],c&&(f=h.substr(0,h.indexOf(c)),f.length>0&&a._pf.unusedInput.push(f),h=h.slice(h.indexOf(c)+c.length),j+=c.length),hc[e]?(c?a._pf.empty=!1:a._pf.unusedTokens.push(e),M(e,c,a)):a._strict&&!c&&a._pf.unusedTokens.push(e);a._pf.charsLeftOver=i-j,h.length>0&&a._pf.unusedInput.push(h),a._isPm&&a._a[vb]<12&&(a._a[vb]+=12),a._isPm===!1&&12===a._a[vb]&&(a._a[vb]=0),O(a),z(a)}function S(a){return a.replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(a,b,c,d,e){return b||c||d||e})}function T(a){return a.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function U(a){var b,d,e,f,g;if(0===a._f.length)return a._pf.invalidFormat=!0,void(a._d=new Date(0/0));for(f=0;f<a._f.length;f++)g=0,b=j({},a),b._pf=c(),b._f=a._f[f],R(b),A(b)&&(g+=b._pf.charsLeftOver,g+=10*b._pf.unusedTokens.length,b._pf.score=g,(null==e||e>g)&&(e=g,d=b));j(a,d||b)}function V(a){var b,c,d=a._i,e=Xb.exec(d);if(e){for(a._pf.iso=!0,b=0,c=Zb.length;c>b;b++)if(Zb[b][1].exec(d)){a._f=Zb[b][0]+(e[6]||" ");break}for(b=0,c=$b.length;c>b;b++)if($b[b][1].exec(d)){a._f+=$b[b][0];break}d.match(Nb)&&(a._f+="Z"),R(a)}else a._isValid=!1}function W(a){V(a),a._isValid===!1&&(delete a._isValid,mb.createFromInputFallback(a))}function X(b){var c=b._i,d=Cb.exec(c);c===a?b._d=new Date:d?b._d=new Date(+d[1]):"string"==typeof c?W(b):o(c)?(b._a=c.slice(0),O(b)):p(c)?b._d=new Date(+c):"object"==typeof c?P(b):"number"==typeof c?b._d=new Date(c):mb.createFromInputFallback(b)}function Y(a,b,c,d,e,f,g){var h=new Date(a,b,c,d,e,f,g);return 1970>a&&h.setFullYear(a),h}function Z(a){var b=new Date(Date.UTC.apply(null,arguments));return 1970>a&&b.setUTCFullYear(a),b}function $(a,b){if("string"==typeof a)if(isNaN(a)){if(a=b.weekdaysParse(a),"number"!=typeof a)return null}else a=parseInt(a,10);return a}function _(a,b,c,d,e){return e.relativeTime(b||1,!!c,a,d)}function ab(a,b,c){var d=rb(Math.abs(a)/1e3),e=rb(d/60),f=rb(e/60),g=rb(f/24),h=rb(g/365),i=d<ec.s&&["s",d]||1===e&&["m"]||e<ec.m&&["mm",e]||1===f&&["h"]||f<ec.h&&["hh",f]||1===g&&["d"]||g<=ec.dd&&["dd",g]||g<=ec.dm&&["M"]||g<ec.dy&&["MM",rb(g/30)]||1===h&&["y"]||["yy",h];return i[2]=b,i[3]=a>0,i[4]=c,_.apply({},i)}function bb(a,b,c){var d,e=c-b,f=c-a.day();return f>e&&(f-=7),e-7>f&&(f+=7),d=mb(a).add("d",f),{week:Math.ceil(d.dayOfYear()/7),year:d.year()}}function cb(a,b,c,d,e){var f,g,h=Z(a,0,1).getUTCDay();return h=0===h?7:h,c=null!=c?c:e,f=e-h+(h>d?7:0)-(e>h?7:0),g=7*(b-1)+(c-e)+f+1,{year:g>0?a:a-1,dayOfYear:g>0?g:x(a-1)+g}}function db(b){var c=b._i,d=b._f;return null===c||d===a&&""===c?mb.invalid({nullInput:!0}):("string"==typeof c&&(b._i=c=F().preparse(c)),mb.isMoment(c)?(b=k(c),b._d=new Date(+c._d)):d?o(d)?U(b):R(b):X(b),new h(b))}function eb(a,b){var c,d;if(1===b.length&&o(b[0])&&(b=b[0]),!b.length)return mb();for(c=b[0],d=1;d<b.length;++d)b[d][a](c)&&(c=b[d]);return c}function fb(a,b){var c;return"string"==typeof b&&(b=a.lang().monthsParse(b),"number"!=typeof b)?a:(c=Math.min(a.date(),v(a.year(),b)),a._d["set"+(a._isUTC?"UTC":"")+"Month"](b,c),a)}function gb(a,b){return a._d["get"+(a._isUTC?"UTC":"")+b]()}function hb(a,b,c){return"Month"===b?fb(a,c):a._d["set"+(a._isUTC?"UTC":"")+b](c)}function ib(a,b){return function(c){return null!=c?(hb(this,a,c),mb.updateOffset(this,b),this):gb(this,a)}}function jb(a){mb.duration.fn[a]=function(){return this._data[a]}}function kb(a,b){mb.duration.fn["as"+a]=function(){return+this/b}}function lb(a){"undefined"==typeof ender&&(nb=qb.moment,qb.moment=a?d("Accessing Moment through the global scope is deprecated, and will be removed in an upcoming release.",mb):mb)}for(var mb,nb,ob,pb="2.7.0",qb="undefined"!=typeof global?global:this,rb=Math.round,sb=0,tb=1,ub=2,vb=3,wb=4,xb=5,yb=6,zb={},Ab={_isAMomentObject:null,_i:null,_f:null,_l:null,_strict:null,_tzm:null,_isUTC:null,_offset:null,_pf:null,_lang:null},Bb="undefined"!=typeof module&&module.exports,Cb=/^\/?Date\((\-?\d+)/i,Db=/(\-)?(?:(\d*)\.)?(\d+)\:(\d+)(?:\:(\d+)\.?(\d{3})?)?/,Eb=/^(-)?P(?:(?:([0-9,.]*)Y)?(?:([0-9,.]*)M)?(?:([0-9,.]*)D)?(?:T(?:([0-9,.]*)H)?(?:([0-9,.]*)M)?(?:([0-9,.]*)S)?)?|([0-9,.]*)W)$/,Fb=/(\[[^\[]*\])|(\\)?(Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Q|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|mm?|ss?|S{1,4}|X|zz?|ZZ?|.)/g,Gb=/(\[[^\[]*\])|(\\)?(LT|LL?L?L?|l{1,4})/g,Hb=/\d\d?/,Ib=/\d{1,3}/,Jb=/\d{1,4}/,Kb=/[+\-]?\d{1,6}/,Lb=/\d+/,Mb=/[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF\/]+(\s*?[\u0600-\u06FF]+){1,2}/i,Nb=/Z|[\+\-]\d\d:?\d\d/gi,Ob=/T/i,Pb=/[\+\-]?\d+(\.\d{1,3})?/,Qb=/\d{1,2}/,Rb=/\d/,Sb=/\d\d/,Tb=/\d{3}/,Ub=/\d{4}/,Vb=/[+-]?\d{6}/,Wb=/[+-]?\d+/,Xb=/^\s*(?:[+-]\d{6}|\d{4})-(?:(\d\d-\d\d)|(W\d\d$)|(W\d\d-\d)|(\d\d\d))((T| )(\d\d(:\d\d(:\d\d(\.\d+)?)?)?)?([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,Yb="YYYY-MM-DDTHH:mm:ssZ",Zb=[["YYYYYY-MM-DD",/[+-]\d{6}-\d{2}-\d{2}/],["YYYY-MM-DD",/\d{4}-\d{2}-\d{2}/],["GGGG-[W]WW-E",/\d{4}-W\d{2}-\d/],["GGGG-[W]WW",/\d{4}-W\d{2}/],["YYYY-DDD",/\d{4}-\d{3}/]],$b=[["HH:mm:ss.SSSS",/(T| )\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss",/(T| )\d\d:\d\d:\d\d/],["HH:mm",/(T| )\d\d:\d\d/],["HH",/(T| )\d\d/]],_b=/([\+\-]|\d\d)/gi,ac=("Date|Hours|Minutes|Seconds|Milliseconds".split("|"),{Milliseconds:1,Seconds:1e3,Minutes:6e4,Hours:36e5,Days:864e5,Months:2592e6,Years:31536e6}),bc={ms:"millisecond",s:"second",m:"minute",h:"hour",d:"day",D:"date",w:"week",W:"isoWeek",M:"month",Q:"quarter",y:"year",DDD:"dayOfYear",e:"weekday",E:"isoWeekday",gg:"weekYear",GG:"isoWeekYear"},cc={dayofyear:"dayOfYear",isoweekday:"isoWeekday",isoweek:"isoWeek",weekyear:"weekYear",isoweekyear:"isoWeekYear"},dc={},ec={s:45,m:45,h:22,dd:25,dm:45,dy:345},fc="DDD w W M D d".split(" "),gc="M D H h m s w W".split(" "),hc={M:function(){return this.month()+1},MMM:function(a){return this.lang().monthsShort(this,a)},MMMM:function(a){return this.lang().months(this,a)},D:function(){return this.date()},DDD:function(){return this.dayOfYear()},d:function(){return this.day()},dd:function(a){return this.lang().weekdaysMin(this,a)},ddd:function(a){return this.lang().weekdaysShort(this,a)},dddd:function(a){return this.lang().weekdays(this,a)},w:function(){return this.week()},W:function(){return this.isoWeek()},YY:function(){return m(this.year()%100,2)},YYYY:function(){return m(this.year(),4)},YYYYY:function(){return m(this.year(),5)},YYYYYY:function(){var a=this.year(),b=a>=0?"+":"-";return b+m(Math.abs(a),6)},gg:function(){return m(this.weekYear()%100,2)},gggg:function(){return m(this.weekYear(),4)},ggggg:function(){return m(this.weekYear(),5)},GG:function(){return m(this.isoWeekYear()%100,2)},GGGG:function(){return m(this.isoWeekYear(),4)},GGGGG:function(){return m(this.isoWeekYear(),5)},e:function(){return this.weekday()},E:function(){return this.isoWeekday()},a:function(){return this.lang().meridiem(this.hours(),this.minutes(),!0)},A:function(){return this.lang().meridiem(this.hours(),this.minutes(),!1)},H:function(){return this.hours()},h:function(){return this.hours()%12||12},m:function(){return this.minutes()},s:function(){return this.seconds()},S:function(){return u(this.milliseconds()/100)},SS:function(){return m(u(this.milliseconds()/10),2)},SSS:function(){return m(this.milliseconds(),3)},SSSS:function(){return m(this.milliseconds(),3)},Z:function(){var a=-this.zone(),b="+";return 0>a&&(a=-a,b="-"),b+m(u(a/60),2)+":"+m(u(a)%60,2)},ZZ:function(){var a=-this.zone(),b="+";return 0>a&&(a=-a,b="-"),b+m(u(a/60),2)+m(u(a)%60,2)},z:function(){return this.zoneAbbr()},zz:function(){return this.zoneName()},X:function(){return this.unix()},Q:function(){return this.quarter()}},ic=["months","monthsShort","weekdays","weekdaysShort","weekdaysMin"];fc.length;)ob=fc.pop(),hc[ob+"o"]=f(hc[ob],ob);for(;gc.length;)ob=gc.pop(),hc[ob+ob]=e(hc[ob],2);for(hc.DDDD=e(hc.DDD,3),j(g.prototype,{set:function(a){var b,c;for(c in a)b=a[c],"function"==typeof b?this[c]=b:this["_"+c]=b},_months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),months:function(a){return this._months[a.month()]},_monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),monthsShort:function(a){return this._monthsShort[a.month()]},monthsParse:function(a){var b,c,d;for(this._monthsParse||(this._monthsParse=[]),b=0;12>b;b++)if(this._monthsParse[b]||(c=mb.utc([2e3,b]),d="^"+this.months(c,"")+"|^"+this.monthsShort(c,""),this._monthsParse[b]=new RegExp(d.replace(".",""),"i")),this._monthsParse[b].test(a))return b},_weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdays:function(a){return this._weekdays[a.day()]},_weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysShort:function(a){return this._weekdaysShort[a.day()]},_weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),weekdaysMin:function(a){return this._weekdaysMin[a.day()]},weekdaysParse:function(a){var b,c,d;for(this._weekdaysParse||(this._weekdaysParse=[]),b=0;7>b;b++)if(this._weekdaysParse[b]||(c=mb([2e3,1]).day(b),d="^"+this.weekdays(c,"")+"|^"+this.weekdaysShort(c,"")+"|^"+this.weekdaysMin(c,""),this._weekdaysParse[b]=new RegExp(d.replace(".",""),"i")),this._weekdaysParse[b].test(a))return b},_longDateFormat:{LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D YYYY",LLL:"MMMM D YYYY LT",LLLL:"dddd, MMMM D YYYY LT"},longDateFormat:function(a){var b=this._longDateFormat[a];return!b&&this._longDateFormat[a.toUpperCase()]&&(b=this._longDateFormat[a.toUpperCase()].replace(/MMMM|MM|DD|dddd/g,function(a){return a.slice(1)}),this._longDateFormat[a]=b),b},isPM:function(a){return"p"===(a+"").toLowerCase().charAt(0)},_meridiemParse:/[ap]\.?m?\.?/i,meridiem:function(a,b,c){return a>11?c?"pm":"PM":c?"am":"AM"},_calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},calendar:function(a,b){var c=this._calendar[a];return"function"==typeof c?c.apply(b):c},_relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},relativeTime:function(a,b,c,d){var e=this._relativeTime[c];return"function"==typeof e?e(a,b,c,d):e.replace(/%d/i,a)},pastFuture:function(a,b){var c=this._relativeTime[a>0?"future":"past"];return"function"==typeof c?c(b):c.replace(/%s/i,b)},ordinal:function(a){return this._ordinal.replace("%d",a)},_ordinal:"%d",preparse:function(a){return a},postformat:function(a){return a},week:function(a){return bb(a,this._week.dow,this._week.doy).week},_week:{dow:0,doy:6},_invalidDate:"Invalid date",invalidDate:function(){return this._invalidDate}}),mb=function(b,d,e,f){var g;return"boolean"==typeof e&&(f=e,e=a),g={},g._isAMomentObject=!0,g._i=b,g._f=d,g._l=e,g._strict=f,g._isUTC=!1,g._pf=c(),db(g)},mb.suppressDeprecationWarnings=!1,mb.createFromInputFallback=d("moment construction falls back to js Date. This is discouraged and will be removed in upcoming major release. Please refer to https://github.com/moment/moment/issues/1407 for more info.",function(a){a._d=new Date(a._i)}),mb.min=function(){var a=[].slice.call(arguments,0);return eb("isBefore",a)},mb.max=function(){var a=[].slice.call(arguments,0);return eb("isAfter",a)},mb.utc=function(b,d,e,f){var g;return"boolean"==typeof e&&(f=e,e=a),g={},g._isAMomentObject=!0,g._useUTC=!0,g._isUTC=!0,g._l=e,g._i=b,g._f=d,g._strict=f,g._pf=c(),db(g).utc()},mb.unix=function(a){return mb(1e3*a)},mb.duration=function(a,b){var c,d,e,f=a,g=null;return mb.isDuration(a)?f={ms:a._milliseconds,d:a._days,M:a._months}:"number"==typeof a?(f={},b?f[b]=a:f.milliseconds=a):(g=Db.exec(a))?(c="-"===g[1]?-1:1,f={y:0,d:u(g[ub])*c,h:u(g[vb])*c,m:u(g[wb])*c,s:u(g[xb])*c,ms:u(g[yb])*c}):(g=Eb.exec(a))&&(c="-"===g[1]?-1:1,e=function(a){var b=a&&parseFloat(a.replace(",","."));return(isNaN(b)?0:b)*c},f={y:e(g[2]),M:e(g[3]),d:e(g[4]),h:e(g[5]),m:e(g[6]),s:e(g[7]),w:e(g[8])}),d=new i(f),mb.isDuration(a)&&a.hasOwnProperty("_lang")&&(d._lang=a._lang),d},mb.version=pb,mb.defaultFormat=Yb,mb.ISO_8601=function(){},mb.momentProperties=Ab,mb.updateOffset=function(){},mb.relativeTimeThreshold=function(b,c){return ec[b]===a?!1:(ec[b]=c,!0)},mb.lang=function(a,b){var c;return a?(b?D(B(a),b):null===b?(E(a),a="en"):zb[a]||F(a),c=mb.duration.fn._lang=mb.fn._lang=F(a),c._abbr):mb.fn._lang._abbr},mb.langData=function(a){return a&&a._lang&&a._lang._abbr&&(a=a._lang._abbr),F(a)},mb.isMoment=function(a){return a instanceof h||null!=a&&a.hasOwnProperty("_isAMomentObject")},mb.isDuration=function(a){return a instanceof i},ob=ic.length-1;ob>=0;--ob)t(ic[ob]);mb.normalizeUnits=function(a){return r(a)},mb.invalid=function(a){var b=mb.utc(0/0);return null!=a?j(b._pf,a):b._pf.userInvalidated=!0,b},mb.parseZone=function(){return mb.apply(null,arguments).parseZone()},mb.parseTwoDigitYear=function(a){return u(a)+(u(a)>68?1900:2e3)},j(mb.fn=h.prototype,{clone:function(){return mb(this)},valueOf:function(){return+this._d+6e4*(this._offset||0)},unix:function(){return Math.floor(+this/1e3)},toString:function(){return this.clone().lang("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")},toDate:function(){return this._offset?new Date(+this):this._d},toISOString:function(){var a=mb(this).utc();return 0<a.year()&&a.year()<=9999?I(a,"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]"):I(a,"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]")},toArray:function(){var a=this;return[a.year(),a.month(),a.date(),a.hours(),a.minutes(),a.seconds(),a.milliseconds()]},isValid:function(){return A(this)},isDSTShifted:function(){return this._a?this.isValid()&&q(this._a,(this._isUTC?mb.utc(this._a):mb(this._a)).toArray())>0:!1},parsingFlags:function(){return j({},this._pf)},invalidAt:function(){return this._pf.overflow},utc:function(){return this.zone(0)},local:function(){return this.zone(0),this._isUTC=!1,this},format:function(a){var b=I(this,a||mb.defaultFormat);return this.lang().postformat(b)},add:function(a,b){var c;return c="string"==typeof a&&"string"==typeof b?mb.duration(isNaN(+b)?+a:+b,isNaN(+b)?b:a):"string"==typeof a?mb.duration(+b,a):mb.duration(a,b),n(this,c,1),this},subtract:function(a,b){var c;return c="string"==typeof a&&"string"==typeof b?mb.duration(isNaN(+b)?+a:+b,isNaN(+b)?b:a):"string"==typeof a?mb.duration(+b,a):mb.duration(a,b),n(this,c,-1),this},diff:function(a,b,c){var d,e,f=C(a,this),g=6e4*(this.zone()-f.zone());return b=r(b),"year"===b||"month"===b?(d=432e5*(this.daysInMonth()+f.daysInMonth()),e=12*(this.year()-f.year())+(this.month()-f.month()),e+=(this-mb(this).startOf("month")-(f-mb(f).startOf("month")))/d,e-=6e4*(this.zone()-mb(this).startOf("month").zone()-(f.zone()-mb(f).startOf("month").zone()))/d,"year"===b&&(e/=12)):(d=this-f,e="second"===b?d/1e3:"minute"===b?d/6e4:"hour"===b?d/36e5:"day"===b?(d-g)/864e5:"week"===b?(d-g)/6048e5:d),c?e:l(e)},from:function(a,b){return mb.duration(this.diff(a)).lang(this.lang()._abbr).humanize(!b)},fromNow:function(a){return this.from(mb(),a)},calendar:function(a){var b=a||mb(),c=C(b,this).startOf("day"),d=this.diff(c,"days",!0),e=-6>d?"sameElse":-1>d?"lastWeek":0>d?"lastDay":1>d?"sameDay":2>d?"nextDay":7>d?"nextWeek":"sameElse";return this.format(this.lang().calendar(e,this))},isLeapYear:function(){return y(this.year())},isDST:function(){return this.zone()<this.clone().month(0).zone()||this.zone()<this.clone().month(5).zone()},day:function(a){var b=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=a?(a=$(a,this.lang()),this.add({d:a-b})):b},month:ib("Month",!0),startOf:function(a){switch(a=r(a)){case"year":this.month(0);case"quarter":case"month":this.date(1);case"week":case"isoWeek":case"day":this.hours(0);case"hour":this.minutes(0);case"minute":this.seconds(0);case"second":this.milliseconds(0)}return"week"===a?this.weekday(0):"isoWeek"===a&&this.isoWeekday(1),"quarter"===a&&this.month(3*Math.floor(this.month()/3)),this},endOf:function(a){return a=r(a),this.startOf(a).add("isoWeek"===a?"week":a,1).subtract("ms",1)},isAfter:function(a,b){return b="undefined"!=typeof b?b:"millisecond",+this.clone().startOf(b)>+mb(a).startOf(b)},isBefore:function(a,b){return b="undefined"!=typeof b?b:"millisecond",+this.clone().startOf(b)<+mb(a).startOf(b)},isSame:function(a,b){return b=b||"ms",+this.clone().startOf(b)===+C(a,this).startOf(b)},min:d("moment().min is deprecated, use moment.min instead. https://github.com/moment/moment/issues/1548",function(a){return a=mb.apply(null,arguments),this>a?this:a}),max:d("moment().max is deprecated, use moment.max instead. https://github.com/moment/moment/issues/1548",function(a){return a=mb.apply(null,arguments),a>this?this:a}),zone:function(a,b){var c=this._offset||0;return null==a?this._isUTC?c:this._d.getTimezoneOffset():("string"==typeof a&&(a=L(a)),Math.abs(a)<16&&(a=60*a),this._offset=a,this._isUTC=!0,c!==a&&(!b||this._changeInProgress?n(this,mb.duration(c-a,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,mb.updateOffset(this,!0),this._changeInProgress=null)),this)},zoneAbbr:function(){return this._isUTC?"UTC":""},zoneName:function(){return this._isUTC?"Coordinated Universal Time":""},parseZone:function(){return this._tzm?this.zone(this._tzm):"string"==typeof this._i&&this.zone(this._i),this},hasAlignedHourOffset:function(a){return a=a?mb(a).zone():0,(this.zone()-a)%60===0},daysInMonth:function(){return v(this.year(),this.month())},dayOfYear:function(a){var b=rb((mb(this).startOf("day")-mb(this).startOf("year"))/864e5)+1;return null==a?b:this.add("d",a-b)},quarter:function(a){return null==a?Math.ceil((this.month()+1)/3):this.month(3*(a-1)+this.month()%3)},weekYear:function(a){var b=bb(this,this.lang()._week.dow,this.lang()._week.doy).year;return null==a?b:this.add("y",a-b)},isoWeekYear:function(a){var b=bb(this,1,4).year;return null==a?b:this.add("y",a-b)},week:function(a){var b=this.lang().week(this);return null==a?b:this.add("d",7*(a-b))},isoWeek:function(a){var b=bb(this,1,4).week;return null==a?b:this.add("d",7*(a-b))},weekday:function(a){var b=(this.day()+7-this.lang()._week.dow)%7;return null==a?b:this.add("d",a-b)},isoWeekday:function(a){return null==a?this.day()||7:this.day(this.day()%7?a:a-7)},isoWeeksInYear:function(){return w(this.year(),1,4)},weeksInYear:function(){var a=this._lang._week;return w(this.year(),a.dow,a.doy)},get:function(a){return a=r(a),this[a]()},set:function(a,b){return a=r(a),"function"==typeof this[a]&&this[a](b),this},lang:function(b){return b===a?this._lang:(this._lang=F(b),this)}}),mb.fn.millisecond=mb.fn.milliseconds=ib("Milliseconds",!1),mb.fn.second=mb.fn.seconds=ib("Seconds",!1),mb.fn.minute=mb.fn.minutes=ib("Minutes",!1),mb.fn.hour=mb.fn.hours=ib("Hours",!0),mb.fn.date=ib("Date",!0),mb.fn.dates=d("dates accessor is deprecated. Use date instead.",ib("Date",!0)),mb.fn.year=ib("FullYear",!0),mb.fn.years=d("years accessor is deprecated. Use year instead.",ib("FullYear",!0)),mb.fn.days=mb.fn.day,mb.fn.months=mb.fn.month,mb.fn.weeks=mb.fn.week,mb.fn.isoWeeks=mb.fn.isoWeek,mb.fn.quarters=mb.fn.quarter,mb.fn.toJSON=mb.fn.toISOString,j(mb.duration.fn=i.prototype,{_bubble:function(){var a,b,c,d,e=this._milliseconds,f=this._days,g=this._months,h=this._data;h.milliseconds=e%1e3,a=l(e/1e3),h.seconds=a%60,b=l(a/60),h.minutes=b%60,c=l(b/60),h.hours=c%24,f+=l(c/24),h.days=f%30,g+=l(f/30),h.months=g%12,d=l(g/12),h.years=d},weeks:function(){return l(this.days()/7)},valueOf:function(){return this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*u(this._months/12)},humanize:function(a){var b=+this,c=ab(b,!a,this.lang());return a&&(c=this.lang().pastFuture(b,c)),this.lang().postformat(c)},add:function(a,b){var c=mb.duration(a,b);return this._milliseconds+=c._milliseconds,this._days+=c._days,this._months+=c._months,this._bubble(),this},subtract:function(a,b){var c=mb.duration(a,b);return this._milliseconds-=c._milliseconds,this._days-=c._days,this._months-=c._months,this._bubble(),this},get:function(a){return a=r(a),this[a.toLowerCase()+"s"]()},as:function(a){return a=r(a),this["as"+a.charAt(0).toUpperCase()+a.slice(1)+"s"]()},lang:mb.fn.lang,toIsoString:function(){var a=Math.abs(this.years()),b=Math.abs(this.months()),c=Math.abs(this.days()),d=Math.abs(this.hours()),e=Math.abs(this.minutes()),f=Math.abs(this.seconds()+this.milliseconds()/1e3);return this.asSeconds()?(this.asSeconds()<0?"-":"")+"P"+(a?a+"Y":"")+(b?b+"M":"")+(c?c+"D":"")+(d||e||f?"T":"")+(d?d+"H":"")+(e?e+"M":"")+(f?f+"S":""):"P0D"}});for(ob in ac)ac.hasOwnProperty(ob)&&(kb(ob,ac[ob]),jb(ob.toLowerCase()));kb("Weeks",6048e5),mb.duration.fn.asMonths=function(){return(+this-31536e6*this.years())/2592e6+12*this.years()},mb.lang("en",{ordinal:function(a){var b=a%10,c=1===u(a%100/10)?"th":1===b?"st":2===b?"nd":3===b?"rd":"th";return a+c}}),Bb?module.exports=mb:"function"==typeof define&&define.amd?(define("moment",function(a,b,c){return c.config&&c.config()&&c.config().noGlobal===!0&&(qb.moment=nb),mb}),lb(!0)):lb()}.call(this),function(a,b){"object"==typeof exports&&"object"==typeof module?module.exports=b():"function"==typeof define&&define.amd?define(b):"object"==typeof exports?exports.Handlebars=b():a.Handlebars=b()}(this,function(){return function(a){function b(d){if(c[d])return c[d].exports;var e=c[d]={exports:{},id:d,loaded:!1};return a[d].call(e.exports,e,e.exports,b),e.loaded=!0,e.exports}var c={};return b.m=a,b.c=c,b.p="",b(0)}([function(a,b,c){"use strict";function d(){var a=new h.HandlebarsEnvironment;return n.extend(a,h),a.SafeString=j["default"],a.Exception=l["default"],a.Utils=n,a.escapeExpression=n.escapeExpression,a.VM=p,a.template=function(b){return p.template(b,a)},a}var e=c(7)["default"],f=c(8)["default"];b.__esModule=!0;var g=c(1),h=e(g),i=c(2),j=f(i),k=c(3),l=f(k),m=c(4),n=e(m),o=c(5),p=e(o),q=c(6),r=f(q),s=d();s.create=d,r["default"](s),s["default"]=s,b["default"]=s,a.exports=b["default"]},function(a,b,c){"use strict";function d(a,b){this.helpers=a||{},this.partials=b||{},e(this)}function e(a){a.registerHelper("helperMissing",function(){if(1===arguments.length)return void 0;throw new l["default"]('Missing helper: "'+arguments[arguments.length-1].name+'"')}),a.registerHelper("blockHelperMissing",function(b,c){var d=c.inverse,e=c.fn;if(b===!0)return e(this);if(b===!1||null==b)return d(this);if(p(b))return b.length>0?(c.ids&&(c.ids=[c.name]),a.helpers.each(b,c)):d(this);if(c.data&&c.ids){var g=f(c.data);g.contextPath=j.appendContextPath(c.data.contextPath,c.name),c={data:g}}return e(b,c)}),a.registerHelper("each",function(a,b){function c(b,c,e){i&&(i.key=b,i.index=c,i.first=0===c,i.last=!!e,k&&(i.contextPath=k+b)),h+=d(a[b],{data:i,blockParams:j.blockParams([a[b],b],[k+b,null])})}if(!b)throw new l["default"]("Must pass iterator to #each");var d=b.fn,e=b.inverse,g=0,h="",i=void 0,k=void 0;if(b.data&&b.ids&&(k=j.appendContextPath(b.data.contextPath,b.ids[0])+"."),q(a)&&(a=a.call(this)),b.data&&(i=f(b.data)),a&&"object"==typeof a)if(p(a))for(var m=a.length;m>g;g++)c(g,g,g===a.length-1);else{var n=void 0;for(var o in a)a.hasOwnProperty(o)&&(n&&c(n,g-1),n=o,g++); n&&c(n,g-1,!0)}return 0===g&&(h=e(this)),h}),a.registerHelper("if",function(a,b){return q(a)&&(a=a.call(this)),!b.hash.includeZero&&!a||j.isEmpty(a)?b.inverse(this):b.fn(this)}),a.registerHelper("unless",function(b,c){return a.helpers["if"].call(this,b,{fn:c.inverse,inverse:c.fn,hash:c.hash})}),a.registerHelper("with",function(a,b){q(a)&&(a=a.call(this));var c=b.fn;if(j.isEmpty(a))return b.inverse(this);if(b.data&&b.ids){var d=f(b.data);d.contextPath=j.appendContextPath(b.data.contextPath,b.ids[0]),b={data:d}}return c(a,b)}),a.registerHelper("log",function(b,c){var d=c.data&&null!=c.data.level?parseInt(c.data.level,10):1;a.log(d,b)}),a.registerHelper("lookup",function(a,b){return a&&a[b]})}function f(a){var b=j.extend({},a);return b._parent=a,b}var g=c(7)["default"],h=c(8)["default"];b.__esModule=!0,b.HandlebarsEnvironment=d,b.createFrame=f;var i=c(4),j=g(i),k=c(3),l=h(k),m="3.0.1";b.VERSION=m;var n=6;b.COMPILER_REVISION=n;var o={1:"<= 1.0.rc.2",2:"== 1.0.0-rc.3",3:"== 1.0.0-rc.4",4:"== 1.x.x",5:"== 2.0.0-alpha.x",6:">= 2.0.0-beta.1"};b.REVISION_CHANGES=o;var p=j.isArray,q=j.isFunction,r=j.toString,s="[object Object]";d.prototype={constructor:d,logger:t,log:u,registerHelper:function(a,b){if(r.call(a)===s){if(b)throw new l["default"]("Arg not supported with multiple helpers");j.extend(this.helpers,a)}else this.helpers[a]=b},unregisterHelper:function(a){delete this.helpers[a]},registerPartial:function(a,b){if(r.call(a)===s)j.extend(this.partials,a);else{if("undefined"==typeof b)throw new l["default"]("Attempting to register a partial as undefined");this.partials[a]=b}},unregisterPartial:function(a){delete this.partials[a]}};var t={methodMap:{0:"debug",1:"info",2:"warn",3:"error"},DEBUG:0,INFO:1,WARN:2,ERROR:3,level:1,log:function(a,b){if("undefined"!=typeof console&&t.level<=a){var c=t.methodMap[a];(console[c]||console.log).call(console,b)}}};b.logger=t;var u=t.log;b.log=u},function(a,b){"use strict";function c(a){this.string=a}b.__esModule=!0,c.prototype.toString=c.prototype.toHTML=function(){return""+this.string},b["default"]=c,a.exports=b["default"]},function(a,b){"use strict";function c(a,b){var e=b&&b.loc,f=void 0,g=void 0;e&&(f=e.start.line,g=e.start.column,a+=" - "+f+":"+g);for(var h=Error.prototype.constructor.call(this,a),i=0;i<d.length;i++)this[d[i]]=h[d[i]];Error.captureStackTrace&&Error.captureStackTrace(this,c),e&&(this.lineNumber=f,this.column=g)}b.__esModule=!0;var d=["description","fileName","lineNumber","message","name","number","stack"];c.prototype=new Error,b["default"]=c,a.exports=b["default"]},function(a,b){"use strict";function c(a){return j[a]}function d(a){for(var b=1;b<arguments.length;b++)for(var c in arguments[b])Object.prototype.hasOwnProperty.call(arguments[b],c)&&(a[c]=arguments[b][c]);return a}function e(a,b){for(var c=0,d=a.length;d>c;c++)if(a[c]===b)return c;return-1}function f(a){if("string"!=typeof a){if(a&&a.toHTML)return a.toHTML();if(null==a)return"";if(!a)return a+"";a=""+a}return l.test(a)?a.replace(k,c):a}function g(a){return a||0===a?o(a)&&0===a.length?!0:!1:!0}function h(a,b){return a.path=b,a}function i(a,b){return(a?a+".":"")+b}b.__esModule=!0,b.extend=d,b.indexOf=e,b.escapeExpression=f,b.isEmpty=g,b.blockParams=h,b.appendContextPath=i;var j={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#x27;","`":"&#x60;"},k=/[&<>"'`]/g,l=/[&<>"'`]/,m=Object.prototype.toString;b.toString=m;var n=function(a){return"function"==typeof a};n(/x/)&&(b.isFunction=n=function(a){return"function"==typeof a&&"[object Function]"===m.call(a)});var n;b.isFunction=n;var o=Array.isArray||function(a){return a&&"object"==typeof a?"[object Array]"===m.call(a):!1};b.isArray=o},function(a,b,c){"use strict";function d(a){var b=a&&a[0]||1,c=q.COMPILER_REVISION;if(b!==c){if(c>b){var d=q.REVISION_CHANGES[c],e=q.REVISION_CHANGES[b];throw new p["default"]("Template was precompiled with an older version of Handlebars than the current runtime. Please update your precompiler to a newer version ("+d+") or downgrade your runtime to an older version ("+e+").")}throw new p["default"]("Template was precompiled with a newer version of Handlebars than the current runtime. Please update your runtime to a newer version ("+a[1]+").")}}function e(a,b){function c(c,d,e){e.hash&&(d=n.extend({},d,e.hash)),c=b.VM.resolvePartial.call(this,c,d,e);var f=b.VM.invokePartial.call(this,c,d,e);if(null==f&&b.compile&&(e.partials[e.name]=b.compile(c,a.compilerOptions,b),f=e.partials[e.name](d,e)),null!=f){if(e.indent){for(var g=f.split("\n"),h=0,i=g.length;i>h&&(g[h]||h+1!==i);h++)g[h]=e.indent+g[h];f=g.join("\n")}return f}throw new p["default"]("The partial "+e.name+" could not be compiled when running in runtime-only mode")}function d(b){var c=void 0===arguments[1]?{}:arguments[1],f=c.data;d._setup(c),!c.partial&&a.useData&&(f=j(b,f));var g=void 0,h=a.useBlockParams?[]:void 0;return a.useDepths&&(g=c.depths?[b].concat(c.depths):[b]),a.main.call(e,b,e.helpers,e.partials,f,h,g)}if(!b)throw new p["default"]("No environment passed to template");if(!a||!a.main)throw new p["default"]("Unknown template object: "+typeof a);b.VM.checkRevision(a.compiler);var e={strict:function(a,b){if(!(b in a))throw new p["default"]('"'+b+'" not defined in '+a);return a[b]},lookup:function(a,b){for(var c=a.length,d=0;c>d;d++)if(a[d]&&null!=a[d][b])return a[d][b]},lambda:function(a,b){return"function"==typeof a?a.call(b):a},escapeExpression:n.escapeExpression,invokePartial:c,fn:function(b){return a[b]},programs:[],program:function(a,b,c,d,e){var g=this.programs[a],h=this.fn(a);return b||e||d||c?g=f(this,a,h,b,c,d,e):g||(g=this.programs[a]=f(this,a,h)),g},data:function(a,b){for(;a&&b--;)a=a._parent;return a},merge:function(a,b){var c=a||b;return a&&b&&a!==b&&(c=n.extend({},b,a)),c},noop:b.VM.noop,compilerInfo:a.compiler};return d.isTop=!0,d._setup=function(c){c.partial?(e.helpers=c.helpers,e.partials=c.partials):(e.helpers=e.merge(c.helpers,b.helpers),a.usePartial&&(e.partials=e.merge(c.partials,b.partials)))},d._child=function(b,c,d,g){if(a.useBlockParams&&!d)throw new p["default"]("must pass block params");if(a.useDepths&&!g)throw new p["default"]("must pass parent depths");return f(e,b,a[b],c,0,d,g)},d}function f(a,b,c,d,e,f,g){function h(b){var e=void 0===arguments[1]?{}:arguments[1];return c.call(a,b,a.helpers,a.partials,e.data||d,f&&[e.blockParams].concat(f),g&&[b].concat(g))}return h.program=b,h.depth=g?g.length:0,h.blockParams=e||0,h}function g(a,b,c){return a?a.call||c.name||(c.name=a,a=c.partials[a]):a=c.partials[c.name],a}function h(a,b,c){if(c.partial=!0,void 0===a)throw new p["default"]("The partial "+c.name+" could not be found");return a instanceof Function?a(b,c):void 0}function i(){return""}function j(a,b){return b&&"root"in b||(b=b?q.createFrame(b):{},b.root=a),b}var k=c(7)["default"],l=c(8)["default"];b.__esModule=!0,b.checkRevision=d,b.template=e,b.wrapProgram=f,b.resolvePartial=g,b.invokePartial=h,b.noop=i;var m=c(4),n=k(m),o=c(3),p=l(o),q=c(1)},function(a,b){(function(c){"use strict";b.__esModule=!0,b["default"]=function(a){var b="undefined"!=typeof c?c:window,d=b.Handlebars;a.noConflict=function(){b.Handlebars===a&&(b.Handlebars=d)}},a.exports=b["default"]}).call(b,function(){return this}())},function(a,b){"use strict";b["default"]=function(a){if(a&&a.__esModule)return a;var b={};if("object"==typeof a&&null!==a)for(var c in a)Object.prototype.hasOwnProperty.call(a,c)&&(b[c]=a[c]);return b["default"]=a,b},b.__esModule=!0},function(a,b){"use strict";b["default"]=function(a){return a&&a.__esModule?a:{"default":a}},b.__esModule=!0}])});var TAFFY,exports,T;!function(){var a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w;if(!TAFFY)for(e="2.7",f=1,g="000000",h=1e3,i={},j=function(a){return TAFFY.isArray(a)||TAFFY.isObject(a)?a:JSON.parse(a)},s=function(a,b){return t(a,function(a){return b.indexOf(a)>=0})},t=function(a,b,c){var d=[];return null==a?d:Array.prototype.filter&&a.filter===Array.prototype.filter?a.filter(b,c):(k(a,function(a,e,f){b.call(c,a,e,f)&&(d[d.length]=a)}),d)},w=function(a){return"[object RegExp]"===Object.prototype.toString.call(a)},v=function(a){var b=T.isArray(a)?[]:T.isObject(a)?{}:null;if(null===a)return a;for(var c in a)b[c]=w(a[c])?a[c].toString():T.isArray(a[c])||T.isObject(a[c])?v(a[c]):a[c];return b},u=function(a){var b=JSON.stringify(a);return null===b.match(/regex/)?b:JSON.stringify(v(a))},k=function(a,b,c){var d,e,f,g;if(a&&(T.isArray(a)&&1===a.length||!T.isArray(a)))b(T.isArray(a)?a[0]:a,0);else for(f=0,a=T.isArray(a)?a:[a],g=a.length;g>f&&(e=a[f],T.isUndefined(e)&&!c||(d=b(e,f),d!==T.EXIT));f++);},l=function(a,b){var c,d,e=0;for(d in a)if(a.hasOwnProperty(d)&&(c=b(a[d],d,e++),c===T.EXIT))break},i.extend=function(a,b){i[a]=function(){return b.apply(this,arguments)}},m=function(a){var b;return T.isString(a)&&/[t][0-9]*[r][0-9]*/i.test(a)?!0:T.isObject(a)&&a.___id&&a.___s?!0:T.isArray(a)?(b=!0,k(a,function(a){return m(a)?void 0:(b=!1,TAFFY.EXIT)}),b):!1},o=function(a,b){var c=!0;return k(b,function(b){switch(T.typeOf(b)){case"function":if(!b.apply(a))return c=!1,TAFFY.EXIT;break;case"array":c=1===b.length?o(a,b[0]):2===b.length?o(a,b[0])||o(a,b[1]):3===b.length?o(a,b[0])||o(a,b[1])||o(a,b[2]):4===b.length?o(a,b[0])||o(a,b[1])||o(a,b[2])||o(a,b[3]):!1,b.length>4&&k(b,function(b){o(a,b)&&(c=!0)})}}),c},n=function(a){var b=[];return T.isString(a)&&/[t][0-9]*[r][0-9]*/i.test(a)&&(a={___id:a}),T.isArray(a)?(k(a,function(a){b.push(n(a))}),a=function(){var a=this,c=!1;return k(b,function(b){o(a,b)&&(c=!0)}),c}):T.isObject(a)?(T.isObject(a)&&a.___id&&a.___s&&(a={___id:a.___id}),l(a,function(a,c){T.isObject(a)||(a={is:a}),l(a,function(a,d){var e,f=[];e="hasAll"===d?function(a,b){b(a)}:k,e(a,function(a){var b,e=!0;b=function(){var b,f=this[c],g="==",h="!=",i="===",j="<",k=">",l="<=",m=">=",n="!==";return"undefined"==typeof f?!1:(0===d.indexOf("!")&&d!==h&&d!==n&&(e=!1,d=d.substring(1,d.length)),b="regex"===d?a.test(f):"lt"===d||d===j?a>f:"gt"===d||d===k?f>a:"lte"===d||d===l?a>=f:"gte"===d||d===m?f>=a:"left"===d?0===f.indexOf(a):"leftnocase"===d?0===f.toLowerCase().indexOf(a.toLowerCase()):"right"===d?f.substring(f.length-a.length)===a:"rightnocase"===d?f.toLowerCase().substring(f.length-a.length)===a.toLowerCase():"like"===d?f.indexOf(a)>=0:"likenocase"===d?f.toLowerCase().indexOf(a.toLowerCase())>=0:d===i||"is"===d?f===a:d===g?f==a:d===n?f!==a:d===h?f!=a:"isnocase"===d?f.toLowerCase?f.toLowerCase()===a.toLowerCase():f===a:"has"===d?T.has(f,a):"hasall"===d?T.hasAll(f,a):"contains"===d?TAFFY.isArray(f)&&f.indexOf(a)>-1:-1!==d.indexOf("is")||TAFFY.isNull(f)||TAFFY.isUndefined(f)||TAFFY.isObject(a)||TAFFY.isArray(a)?T[d]&&T.isFunction(T[d])&&0===d.indexOf("is")?T[d](f)===a:T[d]&&T.isFunction(T[d])?T[d](f,a):!1:a===f[d],b=b&&!e?!1:b||e?b:!0)},f.push(b)}),b.push(1===f.length?f[0]:function(){var a=this,b=!1;return k(f,function(c){c.apply(a)&&(b=!0)}),b})})}),a=function(){var a=this,c=!0;return c=(1!==b.length||b[0].apply(a))&&(2!==b.length||b[0].apply(a)&&b[1].apply(a))&&(3!==b.length||b[0].apply(a)&&b[1].apply(a)&&b[2].apply(a))&&(4!==b.length||b[0].apply(a)&&b[1].apply(a)&&b[2].apply(a)&&b[3].apply(a))?!0:!1,b.length>4&&k(b,function(b){o(a,b)||(c=!1)}),c}):T.isFunction(a)?a:void 0},q=function(a,b){var c=function(a,c){var d=0;return T.each(b,function(b){var e,f,g,h,i;if(e=b.split(" "),f=e[0],g=1===e.length?"logical":e[1],"logical"===g)h=p(a[f]),i=p(c[f]),T.each(h.length<=i.length?h:i,function(a,b){return h[b]<i[b]?(d=-1,TAFFY.EXIT):h[b]>i[b]?(d=1,TAFFY.EXIT):void 0});else if("logicaldesc"===g)h=p(a[f]),i=p(c[f]),T.each(h.length<=i.length?h:i,function(a,b){return h[b]>i[b]?(d=-1,TAFFY.EXIT):h[b]<i[b]?(d=1,TAFFY.EXIT):void 0});else{if("asec"===g&&a[f]<c[f])return d=-1,T.EXIT;if("asec"===g&&a[f]>c[f])return d=1,T.EXIT;if("desc"===g&&a[f]>c[f])return d=-1,T.EXIT;if("desc"===g&&a[f]<c[f])return d=1,T.EXIT}return 0===d&&"logical"===g&&h.length<i.length?d=-1:0===d&&"logical"===g&&h.length>i.length?d=1:0===d&&"logicaldesc"===g&&h.length>i.length?d=-1:0===d&&"logicaldesc"===g&&h.length<i.length&&(d=1),0!==d?T.EXIT:void 0}),d};return a&&a.push?a.sort(c):a},function(){var a={},b=0;p=function(c){return b>h&&(a={},b=0),a["_"+c]||function(){var d,e,f,g=String(c),h=[],i="_",j="";for(d=0,e=g.length;e>d;d++)f=g.charCodeAt(d),f>=48&&57>=f||46===f?("n"!==j&&(j="n",h.push(i.toLowerCase()),i=""),i+=g.charAt(d)):("s"!==j&&(j="s",h.push(parseFloat(i)),i=""),i+=g.charAt(d));return h.push("n"===j?parseFloat(i):i.toLowerCase()),h.shift(),a["_"+c]=h,b++,h}()}}(),r=function(){this.context({results:this.getDBI().query(this.context())})},i.extend("filter",function(){var a=TAFFY.mergeObj(this.context(),{run:null}),b=[];return k(a.q,function(a){b.push(a)}),a.q=b,k(arguments,function(b){a.q.push(n(b)),a.filterRaw.push(b)}),this.getroot(a)}),i.extend("order",function(a){a=a.split(",");var b,c=[];return k(a,function(a){c.push(a.replace(/^\s*/,"").replace(/\s*$/,""))}),b=TAFFY.mergeObj(this.context(),{sort:null}),b.order=c,this.getroot(b)}),i.extend("limit",function(a){var b,c=TAFFY.mergeObj(this.context(),{});return c.limit=a,c.run&&c.sort&&(b=[],k(c.results,function(c,d){return d+1>a?TAFFY.EXIT:void b.push(c)}),c.results=b),this.getroot(c)}),i.extend("start",function(a){var b,c=TAFFY.mergeObj(this.context(),{});return c.start=a,c.run&&c.sort&&!c.limit?(b=[],k(c.results,function(c,d){d+1>a&&b.push(c)}),c.results=b):c=TAFFY.mergeObj(this.context(),{run:null,start:a}),this.getroot(c)}),i.extend("update",function(a,b,c){var d,e=!0,f={},g=arguments;return!TAFFY.isString(a)||2!==arguments.length&&3!==arguments.length?(f=a,2===g.length&&(e=b)):(f[a]=b,3===arguments.length&&(e=c)),d=this,r.call(this),k(this.context().results,function(a){var b=f;TAFFY.isFunction(b)?b=b.apply(TAFFY.mergeObj(a,{})):T.isFunction(b)&&(b=b(TAFFY.mergeObj(a,{}))),TAFFY.isObject(b)&&d.getDBI().update(a.___id,b,e)}),this.context().results.length&&this.context({run:null}),this}),i.extend("remove",function(a){var b=this,c=0;return r.call(this),k(this.context().results,function(a){b.getDBI().remove(a.___id),c++}),this.context().results.length&&(this.context({run:null}),b.getDBI().removeCommit(a)),c}),i.extend("count",function(){return r.call(this),this.context().results.length}),i.extend("callback",function(a,b){if(a){var c=this;setTimeout(function(){r.call(c),a.call(c.getroot(c.context()))},b||0)}return null}),i.extend("get",function(){return r.call(this),this.context().results}),i.extend("stringify",function(){return JSON.stringify(this.get())}),i.extend("first",function(){return r.call(this),this.context().results[0]||!1}),i.extend("last",function(){return r.call(this),this.context().results[this.context().results.length-1]||!1}),i.extend("sum",function(){var a=0,b=this;return r.call(b),k(arguments,function(c){k(b.context().results,function(b){a+=b[c]||0})}),a}),i.extend("min",function(a){var b=null;return r.call(this),k(this.context().results,function(c){(null===b||c[a]<b)&&(b=c[a])}),b}),function(){var a=function(){var a,b,c;return a=function(a,b,c){var d,e,f;switch(2===c.length?(d=a[c[0]],f="===",e=b[c[1]]):(d=a[c[0]],f=c[1],e=b[c[2]]),f){case"===":return d===e;case"!==":return d!==e;case"<":return e>d;case">":return d>e;case"<=":return e>=d;case">=":return d>=e;case"==":return d==e;case"!=":return d!=e;default:throw String(f)+" is not supported"}},b=function(a,b){var c,d,e={};for(c in a)a.hasOwnProperty(c)&&(e[c]=a[c]);for(c in b)b.hasOwnProperty(c)&&"___id"!==c&&"___s"!==c&&(d=TAFFY.isUndefined(e[c])?"":"right_",e[d+String(c)]=b[c]);return e},c=function(c){var d,e,f=arguments,g=f.length,h=[];if("function"!=typeof c.filter){if(!c.TAFFY)throw"TAFFY DB or result not supplied";d=c()}else d=c;return this.context({results:this.getDBI().query(this.context())}),TAFFY.each(this.context().results,function(c){d.each(function(d){var i,j=!0;a:for(e=1;g>e&&(i=f[e],j="function"==typeof i?i(c,d):"object"==typeof i&&i.length?a(c,d,i):!1,j);e++);j&&h.push(b(c,d))})}),TAFFY(h)()}}();i.extend("join",a)}(),i.extend("max",function(a){var b=null;return r.call(this),k(this.context().results,function(c){(null===b||c[a]>b)&&(b=c[a])}),b}),i.extend("select",function(){var a=[],b=arguments;return r.call(this),1===arguments.length?k(this.context().results,function(c){a.push(c[b[0]])}):k(this.context().results,function(c){var d=[];k(b,function(a){d.push(c[a])}),a.push(d)}),a}),i.extend("distinct",function(){var a=[],b=arguments;return r.call(this),1===arguments.length?k(this.context().results,function(c){var d=c[b[0]],e=!1;k(a,function(a){return d===a?(e=!0,TAFFY.EXIT):void 0}),e||a.push(d)}):k(this.context().results,function(c){var d=[],e=!1;k(b,function(a){d.push(c[a])}),k(a,function(a){var c=!0;return k(b,function(b,e){return d[e]!==a[e]?(c=!1,TAFFY.EXIT):void 0}),c?(e=!0,TAFFY.EXIT):void 0}),e||a.push(d)}),a}),i.extend("supplant",function(a,b){var c=[];return r.call(this),k(this.context().results,function(b){c.push(a.replace(/\{([^\{\}]*)\}/g,function(a,c){var d=b[c];return"string"==typeof d||"number"==typeof d?d:a}))}),b?c:c.join("")}),i.extend("each",function(a){return r.call(this),k(this.context().results,a),this}),i.extend("map",function(a){var b=[];return r.call(this),k(this.context().results,function(c){b.push(a(c))}),b}),T=function(a){var b,c,d,e=[],h={},p=1,r={template:!1,onInsert:!1,onUpdate:!1,onRemove:!1,onDBChange:!1,storageName:!1,forcePropertyCase:null,cacheSize:100,name:""},s=new Date,t=0,v=0,w={};return c=function(a){var b=[],d=!1;return 0===a.length?e:(k(a,function(a){T.isString(a)&&/[t][0-9]*[r][0-9]*/i.test(a)&&e[h[a]]&&(b.push(e[h[a]]),d=!0),T.isObject(a)&&a.___id&&a.___s&&e[h[a.___id]]&&(b.push(e[h[a.___id]]),d=!0),T.isArray(a)&&k(a,function(a){k(c(a),function(a){b.push(a)})})}),d&&b.length>1&&(b=[]),b)},b={dm:function(a){return a&&(s=a,w={},t=0,v=0),r.onDBChange&&setTimeout(function(){r.onDBChange.call(e)},0),r.storageName&&setTimeout(function(){localStorage.setItem("taffy_"+r.storageName,JSON.stringify(e))}),s},insert:function(a,c){var i=[],m=[],n=j(a);return k(n,function(a,d){var j,n;return T.isArray(a)&&0===d?(k(a,function(a){i.push("lower"===r.forcePropertyCase?a.toLowerCase():"upper"===r.forcePropertyCase?a.toUpperCase():a)}),!0):(T.isArray(a)?(j={},k(a,function(a,b){j[i[b]]=a}),a=j):T.isObject(a)&&r.forcePropertyCase&&(n={},l(a,function(b,c){n["lower"===r.forcePropertyCase?c.toLowerCase():"upper"===r.forcePropertyCase?c.toUpperCase():c]=a[c]}),a=n),p++,a.___id="T"+String(g+f).slice(-6)+"R"+String(g+p).slice(-6),a.___s=!0,m.push(a.___id),r.template&&(a=T.mergeObj(r.template,a)),e.push(a),h[a.___id]=e.length-1,r.onInsert&&(c||TAFFY.isUndefined(c))&&r.onInsert.call(a),void b.dm(new Date))}),d(m)},sort:function(a){return e=q(e,a.split(",")),h={},k(e,function(a,b){h[a.___id]=b}),b.dm(new Date),!0},update:function(a,c,d){var f,g,i,j,k={};r.forcePropertyCase&&(l(c,function(a,b){k["lower"===r.forcePropertyCase?b.toLowerCase():"upper"===r.forcePropertyCase?b.toUpperCase():b]=a}),c=k),f=e[h[a]],g=T.mergeObj(f,c),i={},j=!1,l(g,function(a,b){(TAFFY.isUndefined(f[b])||f[b]!==a)&&(i[b]=a,j=!0)}),j&&(r.onUpdate&&(d||TAFFY.isUndefined(d))&&r.onUpdate.call(g,e[h[a]],i),e[h[a]]=g,b.dm(new Date))},remove:function(a){e[h[a]].___s=!1},removeCommit:function(a){var c;for(c=e.length-1;c>-1;c--)e[c].___s||(r.onRemove&&(a||TAFFY.isUndefined(a))&&r.onRemove.call(e[c]),h[e[c].___id]=void 0,e.splice(c,1));h={},k(e,function(a,b){h[a.___id]=b}),b.dm(new Date)},query:function(a){var d,f,g,h,i,j;if(r.cacheSize&&(f="",k(a.filterRaw,function(a){return T.isFunction(a)?(f="nocache",TAFFY.EXIT):void 0}),""===f&&(f=u(T.mergeObj(a,{q:!1,run:!1,sort:!1})))),!a.results||!a.run||a.run&&b.dm()>a.run){if(g=[],r.cacheSize&&w[f])return w[f].i=t++,w[f].results;0===a.q.length&&0===a.index.length?(k(e,function(a){g.push(a)}),d=g):(h=c(a.index),k(h,function(b){(0===a.q.length||o(b,a.q))&&g.push(b)}),d=g)}else d=a.results;return!(a.order.length>0)||a.run&&a.sort||(d=q(d,a.order)),d.length&&(a.limit&&a.limit<d.length||a.start)&&(i=[],k(d,function(b,c){if(!a.start||a.start&&c+1>=a.start)if(a.limit){if(j=a.start?c+1-a.start:c,j<a.limit)i.push(b);else if(j>a.limit)return TAFFY.EXIT}else i.push(b)}),d=i),r.cacheSize&&"nocache"!==f&&(v++,setTimeout(function(){var a,b;v>=2*r.cacheSize&&(v=0,a=t-r.cacheSize,b={},l(function(c,d){c.i>=a&&(b[d]=c)}),w=b)},0),w[f]={i:t++,results:d}),d}},d=function(){var a,c;return a=TAFFY.mergeObj(TAFFY.mergeObj(i,{insert:void 0}),{getDBI:function(){return b},getroot:function(a){return d.call(a)},context:function(a){return a&&(c=TAFFY.mergeObj(c,a.hasOwnProperty("results")?TAFFY.mergeObj(a,{run:new Date,sort:new Date}):a)),c},extend:void 0}),c=this&&this.q?this:{limit:!1,start:!1,q:[],filterRaw:[],index:[],order:[],results:!1,run:null,sort:null,settings:r},k(arguments,function(a){m(a)?c.index.push(a):c.q.push(n(a)),c.filterRaw.push(a)}),a},f++,a&&b.insert(a),d.insert=b.insert,d.merge=function(a,c,e){var f={},g=[],h={};return e=e||!1,c=c||"id",k(a,function(a){var h;f[c]=a[c],g.push(a[c]),h=d(f).first(),h?b.update(h.___id,a,e):b.insert(a,e)}),h[c]=g,d(h)},d.TAFFY=!0,d.sort=b.sort,d.settings=function(a){return a&&(r=TAFFY.mergeObj(r,a),a.template&&d().update(a.template)),r},d.store=function(a){var b,c=!1;return localStorage&&(a&&(b=localStorage.getItem("taffy_"+a),b&&b.length>0&&(d.insert(b),c=!0),e.length>0&&setTimeout(function(){localStorage.setItem("taffy_"+r.storageName,JSON.stringify(e))})),d.settings({storageName:a})),d},d},TAFFY=T,T.each=k,T.eachin=l,T.extend=i.extend,TAFFY.EXIT="TAFFYEXIT",TAFFY.mergeObj=function(a,b){var c={};return l(a,function(b,d){c[d]=a[d]}),l(b,function(a,d){c[d]=b[d]}),c},TAFFY.has=function(a,b){var c,d=!1;if(a.TAFFY)return d=a(b),d.length>0?!0:!1;switch(T.typeOf(a)){case"object":if(T.isObject(b))l(b,function(c,e){return d!==!0||T.isUndefined(a[e])||!a.hasOwnProperty(e)?(d=!1,TAFFY.EXIT):void(d=T.has(a[e],b[e]))});else if(T.isArray(b))k(b,function(c,e){return d=T.has(a,b[e]),d?TAFFY.EXIT:void 0});else if(T.isString(b))return TAFFY.isUndefined(a[b])?!1:!0;return d;case"array":if(T.isObject(b))k(a,function(c,e){return d=T.has(a[e],b),d===!0?TAFFY.EXIT:void 0});else if(T.isArray(b))k(b,function(c,e){return k(a,function(c,f){return d=T.has(a[f],b[e]),d===!0?TAFFY.EXIT:void 0}),d===!0?TAFFY.EXIT:void 0});else if(T.isString(b)||T.isNumber(b))for(d=!1,c=0;c<a.length;c++)if(d=T.has(a[c],b))return!0;return d;case"string":if(T.isString(b)&&b===a)return!0;break;default:if(T.typeOf(a)===T.typeOf(b)&&a===b)return!0}return!1},TAFFY.hasAll=function(a,b){var c,d=TAFFY;return d.isArray(b)?(c=!0,k(b,function(b){return c=d.has(a,b),c===!1?TAFFY.EXIT:void 0}),c):d.has(a,b)},TAFFY.typeOf=function(a){var b=typeof a;return"object"===b&&(a?"number"!=typeof a.length||a.propertyIsEnumerable("length")||(b="array"):b="null"),b},TAFFY.getObjectKeys=function(a){var b=[];return l(a,function(a,c){b.push(c)}),b.sort(),b},TAFFY.isSameArray=function(a,b){return TAFFY.isArray(a)&&TAFFY.isArray(b)&&a.join(",")===b.join(",")?!0:!1},TAFFY.isSameObject=function(a,b){var c=TAFFY,d=!0;return c.isObject(a)&&c.isObject(b)&&c.isSameArray(c.getObjectKeys(a),c.getObjectKeys(b))?l(a,function(e,f){return c.isObject(a[f])&&c.isObject(b[f])&&c.isSameObject(a[f],b[f])||c.isArray(a[f])&&c.isArray(b[f])&&c.isSameArray(a[f],b[f])||a[f]===b[f]?void 0:(d=!1,TAFFY.EXIT)}):d=!1,d},a=["String","Number","Object","Array","Boolean","Null","Function","Undefined"],b=function(a){return function(b){return TAFFY.typeOf(b)===a.toLowerCase()?!0:!1}},c=0;c<a.length;c++)d=a[c],TAFFY["is"+d]=b(d)}(),"object"==typeof exports&&(exports.taffy=TAFFY),function(a,b,c){"undefined"!=typeof module&&module.exports?module.exports=c():"function"==typeof define&&define.amd?define(c):b[a]=c()}("bean",this,function(a,b){a=a||"bean",b=b||this;var c,d=window,e=b[a],f=/[^\.]*(?=\..*)\.|.*/,g=/\..*/,h="addEventListener",i="removeEventListener",j=document||{},k=j.documentElement||{},l=k[h],m=l?h:"attachEvent",n={},o=Array.prototype.slice,p=function(a,b){return a.split(b||" ")},q=function(a){return"string"==typeof a},r=function(a){return"function"==typeof a},s="click dblclick mouseup mousedown contextmenu mousewheel mousemultiwheel DOMMouseScroll mouseover mouseout mousemove selectstart selectend keydown keypress keyup orientationchange focus blur change reset select submit load unload beforeunload resize move DOMContentLoaded readystatechange message error abort scroll ",t="show input invalid touchstart touchmove touchend touchcancel gesturestart gesturechange gestureend textinputreadystatechange pageshow pagehide popstate hashchange offline online afterprint beforeprint dragstart dragenter dragover dragleave drag drop dragend loadstart progress suspend emptied stalled loadmetadata loadeddata canplay canplaythrough playing waiting seeking seeked ended durationchange timeupdate play pause ratechange volumechange cuechange checking noupdate downloading cached updateready obsolete ",u=function(a,b,c){for(c=0;c<b.length;c++)b[c]&&(a[b[c]]=1);return a}({},p(s+(l?t:""))),v=function(){var a="compareDocumentPosition"in k?function(a,b){return b.compareDocumentPosition&&16===(16&b.compareDocumentPosition(a))}:"contains"in k?function(a,b){return b=9===b.nodeType||b===window?k:b,b!==a&&b.contains(a)}:function(a,b){for(;a=a.parentNode;)if(a===b)return 1;return 0},b=function(b){var c=b.relatedTarget;return c?c!==this&&"xul"!==c.prefix&&!/document/.test(this.toString())&&!a(c,this):null==c};return{mouseenter:{base:"mouseover",condition:b},mouseleave:{base:"mouseout",condition:b},mousewheel:{base:/Firefox/.test(navigator.userAgent)?"DOMMouseScroll":"mousewheel"}}}(),w=function(){var a=p("altKey attrChange attrName bubbles cancelable ctrlKey currentTarget detail eventPhase getModifierState isTrusted metaKey relatedNode relatedTarget shiftKey srcElement target timeStamp type view which propertyName"),b=a.concat(p("button buttons clientX clientY dataTransfer fromElement offsetX offsetY pageX pageY screenX screenY toElement")),c=b.concat(p("wheelDelta wheelDeltaX wheelDeltaY wheelDeltaZ axis")),e=a.concat(p("char charCode key keyCode keyIdentifier keyLocation location")),f=a.concat(p("data")),g=a.concat(p("touches targetTouches changedTouches scale rotation")),h=a.concat(p("data origin source")),i=a.concat(p("state")),l=/over|out/,m=[{reg:/key/i,fix:function(a,b){return b.keyCode=a.keyCode||a.which,e}},{reg:/click|mouse(?!(.*wheel|scroll))|menu|drag|drop/i,fix:function(a,c,d){return c.rightClick=3===a.which||2===a.button,c.pos={x:0,y:0},a.pageX||a.pageY?(c.clientX=a.pageX,c.clientY=a.pageY):(a.clientX||a.clientY)&&(c.clientX=a.clientX+j.body.scrollLeft+k.scrollLeft,c.clientY=a.clientY+j.body.scrollTop+k.scrollTop),l.test(d)&&(c.relatedTarget=a.relatedTarget||a[("mouseover"==d?"from":"to")+"Element"]),b}},{reg:/mouse.*(wheel|scroll)/i,fix:function(){return c}},{reg:/^text/i,fix:function(){return f}},{reg:/^touch|^gesture/i,fix:function(){return g}},{reg:/^message$/i,fix:function(){return h}},{reg:/^popstate$/i,fix:function(){return i}},{reg:/.*/,fix:function(){return a}}],n={},o=function(a,b,c){if(arguments.length&&(a=a||((b.ownerDocument||b.document||b).parentWindow||d).event,this.originalEvent=a,this.isNative=c,this.isBean=!0,a)){var e,f,g,h,i,j=a.type,k=a.target||a.srcElement;if(this.target=k&&3===k.nodeType?k.parentNode:k,c){if(i=n[j],!i)for(e=0,f=m.length;f>e;e++)if(m[e].reg.test(j)){n[j]=i=m[e].fix;break}for(h=i(a,this,j),e=h.length;e--;)!((g=h[e])in this)&&g in a&&(this[g]=a[g])}}};return o.prototype.preventDefault=function(){this.originalEvent.preventDefault?this.originalEvent.preventDefault():this.originalEvent.returnValue=!1},o.prototype.stopPropagation=function(){this.originalEvent.stopPropagation?this.originalEvent.stopPropagation():this.originalEvent.cancelBubble=!0},o.prototype.stop=function(){this.preventDefault(),this.stopPropagation(),this.stopped=!0},o.prototype.stopImmediatePropagation=function(){this.originalEvent.stopImmediatePropagation&&this.originalEvent.stopImmediatePropagation(),this.isImmediatePropagationStopped=function(){return!0}},o.prototype.isImmediatePropagationStopped=function(){return this.originalEvent.isImmediatePropagationStopped&&this.originalEvent.isImmediatePropagationStopped()},o.prototype.clone=function(a){var b=new o(this,this.element,this.isNative);return b.currentTarget=a,b},o}(),x=function(a,b){return l||b||a!==j&&a!==d?a:k},y=function(){var a=function(a,b,c,d){var e=function(c,e){return b.apply(a,d?o.call(e,c?0:1).concat(d):e)},f=function(c,d){return b.__beanDel?b.__beanDel.ft(c.target,a):d},g=c?function(a){var b=f(a,this);return c.apply(b,arguments)?(a&&(a.currentTarget=b),e(a,arguments)):void 0}:function(a){return b.__beanDel&&(a=a.clone(f(a))),e(a,arguments)};return g.__beanDel=b.__beanDel,g},b=function(b,c,d,e,f,g,h){var i,j=v[c];"unload"==c&&(d=D(E,b,c,d,e)),j&&(j.condition&&(d=a(b,d,j.condition,g)),c=j.base||c),this.isNative=i=u[c]&&!!b[m],this.customType=!l&&!i&&c,this.element=b,this.type=c,this.original=e,this.namespaces=f,this.eventType=l||i?c:"propertychange",this.target=x(b,i),this[m]=!!this.target[m],this.root=h,this.handler=a(b,d,null,g)};return b.prototype.inNamespaces=function(a){var b,c,d=0;if(!a)return!0;if(!this.namespaces)return!1;for(b=a.length;b--;)for(c=this.namespaces.length;c--;)a[b]==this.namespaces[c]&&d++;return a.length===d},b.prototype.matches=function(a,b,c){return!(this.element!==a||b&&this.original!==b||c&&this.handler!==c)},b}(),z=function(){var a={},b=function(c,d,e,f,g,h){var i=g?"r":"$";if(d&&"*"!=d){var j,k=0,l=a[i+d],m="*"==c;if(!l)return;for(j=l.length;j>k;k++)if((m||l[k].matches(c,e,f))&&!h(l[k],l,k,d))return}else for(var n in a)n.charAt(0)==i&&b(c,n.substr(1),e,f,g,h)},c=function(b,c,d,e){var f,g=a[(e?"r":"$")+c];if(g)for(f=g.length;f--;)if(!g[f].root&&g[f].matches(b,d,null))return!0;return!1},d=function(a,c,d,e){var f=[];return b(a,c,d,null,e,function(a){return f.push(a)}),f},e=function(b){var c=!b.root&&!this.has(b.element,b.type,null,!1),d=(b.root?"r":"$")+b.type;return(a[d]||(a[d]=[])).push(b),c},f=function(c){b(c.element,c.type,null,c.handler,c.root,function(b,c,d){return c.splice(d,1),b.removed=!0,0===c.length&&delete a[(b.root?"r":"$")+b.type],!1})},g=function(){var b,c=[];for(b in a)"$"==b.charAt(0)&&(c=c.concat(a[b]));return c};return{has:c,get:d,put:e,del:f,entries:g}}(),A=function(a){c=arguments.length?a:j.querySelectorAll?function(a,b){return b.querySelectorAll(a)}:function(){throw new Error("Bean: No selector engine installed")}},B=function(a,b){if(l||!b||!a||a.propertyName=="_on"+b){var c=z.get(this,b||a.type,null,!1),d=c.length,e=0;for(a=new w(a,this,!0),b&&(a.type=b);d>e&&!a.isImmediatePropagationStopped();e++)c[e].removed||c[e].handler.call(this,a)}},C=l?function(a,b,c){a[c?h:i](b,B,!1)}:function(a,b,c,d){var e;c?(z.put(e=new y(a,d||b,function(b){B.call(a,b,d)},B,null,null,!0)),d&&null==a["_on"+d]&&(a["_on"+d]=0),e.target.attachEvent("on"+e.eventType,e.handler)):(e=z.get(a,d||b,B,!0)[0],e&&(e.target.detachEvent("on"+e.eventType,e.handler),z.del(e)))},D=function(a,b,c,d,e){return function(){d.apply(this,arguments),a(b,c,e)}},E=function(a,b,c,d){var e,f,h=b&&b.replace(g,""),i=z.get(a,h,null,!1),j={};for(e=0,f=i.length;f>e;e++)(!c||i[e].original===c)&&i[e].inNamespaces(d)&&(z.del(i[e]),!j[i[e].eventType]&&i[e][m]&&(j[i[e].eventType]={t:i[e].eventType,c:i[e].type}));for(e in j)z.has(a,j[e].t,null,!1)||C(a,j[e].t,!1,j[e].c)},F=function(a,b){var d=function(b,d){for(var e,f=q(a)?c(a,d):a;b&&b!==d;b=b.parentNode)for(e=f.length;e--;)if(f[e]===b)return b},e=function(a){var c=d(a.target,this);c&&b.apply(c,arguments)};return e.__beanDel={ft:d,selector:a},e},G=l?function(a,b,c){var e=j.createEvent(a?"HTMLEvents":"UIEvents");e[a?"initEvent":"initUIEvent"](b,!0,!0,d,1),c.dispatchEvent(e)}:function(a,b,c){c=x(c,a),a?c.fireEvent("on"+b,j.createEventObject()):c["_on"+b]++},H=function(a,b,c){var d,e,h,i,j=q(b);if(j&&b.indexOf(" ")>0){for(b=p(b),i=b.length;i--;)H(a,b[i],c);return a}if(e=j&&b.replace(g,""),e&&v[e]&&(e=v[e].base),!b||j)(h=j&&b.replace(f,""))&&(h=p(h,".")),E(a,e,c,h);else if(r(b))E(a,null,b);else for(d in b)b.hasOwnProperty(d)&&H(a,d,b[d]);return a},I=function(a,b,d,e){var h,i,j,k,l,q,s; {if(void 0!==d||"object"!=typeof b){for(r(d)?(l=o.call(arguments,3),e=h=d):(h=e,l=o.call(arguments,4),e=F(d,h,c)),j=p(b),this===n&&(e=D(H,a,b,e,h)),k=j.length;k--;)s=z.put(q=new y(a,j[k].replace(g,""),e,h,p(j[k].replace(f,""),"."),l,!1)),q[m]&&s&&C(a,q.eventType,!0,q.customType);return a}for(i in b)b.hasOwnProperty(i)&&I.call(this,a,i,b[i])}},J=function(a,b,c,d){return I.apply(null,q(c)?[a,c,b,d].concat(arguments.length>3?o.call(arguments,5):[]):o.call(arguments))},K=function(){return I.apply(n,arguments)},L=function(a,b,c){var d,e,h,i,j,k=p(b);for(d=k.length;d--;)if(b=k[d].replace(g,""),(i=k[d].replace(f,""))&&(i=p(i,".")),i||c||!a[m])for(j=z.get(a,b,null,!1),c=[!1].concat(c),e=0,h=j.length;h>e;e++)j[e].inNamespaces(i)&&j[e].handler.apply(a,c);else G(u[b],b,a);return a},M=function(a,b,c){for(var d,e,f=z.get(b,c,null,!1),g=f.length,h=0;g>h;h++)f[h].original&&(d=[a,f[h].type],(e=f[h].handler.__beanDel)&&d.push(e.selector),d.push(f[h].original),I.apply(null,d));return a},N={on:I,add:J,one:K,off:H,remove:H,clone:M,fire:L,Event:w,setSelectorEngine:A,noConflict:function(){return b[a]=e,this}};if(d.attachEvent){var O=function(){var a,b=z.entries();for(a in b)b[a].type&&"unload"!==b[a].type&&H(b[a].element,b[a].type);d.detachEvent("onunload",O),d.CollectGarbage&&d.CollectGarbage()};d.attachEvent("onunload",O)}return A(),N}),!function(a,b){"undefined"==typeof bean&&(bean=require("bean"));var c=bean,d=getComputedStyle||currentStyle,e="ontouchstart"in b.documentElement?!0:!1;drag=function(a){return new Drag(drag.select(a))},drag.select=function(a){return"string"==typeof a?document.getElementById(a)||document.querySelectorAll(a)[0]:a},drag.value=function(a,b,c){return c?void(a.style[b]=c):parseFloat(d(a).getPropertyValue(b))},drag.evs=function(){return e?{start:"touchstart",move:"touchmove",end:"touchend"}:{start:"mousedown",move:"mousemove",end:"mouseup"}}(),Drag=function g(a){return this instanceof g?(this.el=a,this._axis="both",this._start=[],this._dragging=[],this._end=[],this.pos={},this):new g(a)},Drag.prototype.current=function(a){return drag.value(this.el,a)},Drag.prototype.axis=function(a){return("x"==a||"y"==a||"both"==a)&&(this._axis=a),this},Drag.prototype.container=function(a){return this._container=drag.select(a),this},Drag.prototype.handle=function(a){return this._handle=drag.select(a),this},Drag.prototype.start=function(a){return a&&"function"==typeof a&&this._start.push(a),this},Drag.prototype.dragging=function(a){return a&&"function"==typeof a&&this._dragging.push(a),this},Drag.prototype.end=function(a){return a&&"function"==typeof a&&this._end.push(a),this},Drag.prototype.getPos=function(a){return this.pos.x=this.current("left"),this.pos.y=this.current("top"),a&&"function"==typeof a&&a.apply(this),this},Drag.prototype.bind=function(){var a=this;return this.unbind(),this._eventHandler=function(d){var f=a.current("left"),g=a.current("top"),h=function(b){var c,h,i,j;if(e?1==d.touches.length&&(c=b.touches[0].clientX-d.touches[0].clientX,h=b.touches[0].clientY-d.touches[0].clientY):(c=b.clientX-d.clientX,h=b.clientY-d.clientY),i=f+c,j=g+h,a.pos.dX=i-a.current("left"),a.pos.dY=j-a.current("top"),a._container){var k=a._container;0>i?i=0:i>=0&&(maxX=drag.value(k,"padding-left")+drag.value(k,"width")+drag.value(k,"padding-right")-(drag.value(a.el,"margin-left")+drag.value(a.el,"border-left-width")+drag.value(a.el,"padding-left")+drag.value(a.el,"width")+drag.value(a.el,"padding-right")+drag.value(a.el,"border-right-width")+drag.value(a.el,"margin-right")),i>maxX&&(i=maxX)),0>j?j=0:j>=0&&(maxY=drag.value(k,"padding-top")+drag.value(k,"height")+drag.value(k,"padding-bottom")-(drag.value(a.el,"margin-top")+drag.value(a.el,"border-top-width")+drag.value(a.el,"padding-top")+drag.value(a.el,"height")+drag.value(a.el,"padding-bottom")+drag.value(a.el,"border-bottom-width")+drag.value(a.el,"margin-bottom")),j>maxY&&(j=maxY))}"x"==a._axis?drag.value(a.el,"left",i+"px"):"y"==a._axis?drag.value(a.el,"top",j+"px"):(drag.value(a.el,"left",i+"px"),drag.value(a.el,"top",j+"px")),a.getPos();for(var l in a._dragging)a._dragging[l].apply(a);b.preventDefault(),b.stopPropagation()},i=function(){c.remove(b,drag.evs.move,h),c.remove(b,drag.evs.end,j),c.remove(b,"selectstart",k),c.remove(a._handle,"dragstart",k)},j=function(){for(var b in a._end)a._end[b].apply(a);i()},k=function(a){a.preventDefault(),a.stopPropagation()};for(var l in a._start)a._start[l].apply(a);b.body.focus(),c.add(b,"selectstart",k),c.add(a._handle,"dragstart",k),c.add(b,drag.evs.move,h),c.add(b,drag.evs.end,j)},this.getPos(),this._handle||(this._handle=this.el),c.add(this._handle,drag.evs.start,this._eventHandler),this},Drag.prototype.unbind=function(){return this._eventHandler?(c.remove(this.el,drag.evs.start,this._eventHandler),c.remove(this._handle,drag.evs.start,this._eventHandler),this):this};var f=a.drag;drag.noConflict=function(){return a.drag=f,this},"undefined"!=typeof module&&module.exports&&(module.exports=drag),a.drag=drag}(this,document),function(){"use strict";var a=/\/\*!?(?:\@preserve)?\s*(?:\r\n|\n)([\s\S]*?)(?:\r\n|\n)\s*\*\//,b=function(b){if("function"!=typeof b)throw new TypeError("Expected a function.");var c=a.exec(b.toString());if(!c)throw new TypeError("Multiline comment missing.");return c[1]};"undefined"!=typeof module&&module.exports?module.exports=b:window.multiline=b}(),function(a){var b="object"==typeof exports&&exports,c="object"==typeof module&&module&&module.exports==b&&module,d="object"==typeof global&&global;(d.global===d||d.window===d)&&(a=d);var e=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,f=/[\x01-\x7F]/g,g=/[\x01-\t\x0B\f\x0E-\x1F\x7F\x81\x8D\x8F\x90\x9D\xA0-\uFFFF]/g,h=/<\u20D2|=\u20E5|>\u20D2|\u205F\u200A|\u219D\u0338|\u2202\u0338|\u2220\u20D2|\u2229\uFE00|\u222A\uFE00|\u223C\u20D2|\u223D\u0331|\u223E\u0333|\u2242\u0338|\u224B\u0338|\u224D\u20D2|\u224E\u0338|\u224F\u0338|\u2250\u0338|\u2261\u20E5|\u2264\u20D2|\u2265\u20D2|\u2266\u0338|\u2267\u0338|\u2268\uFE00|\u2269\uFE00|\u226A\u0338|\u226A\u20D2|\u226B\u0338|\u226B\u20D2|\u227F\u0338|\u2282\u20D2|\u2283\u20D2|\u228A\uFE00|\u228B\uFE00|\u228F\u0338|\u2290\u0338|\u2293\uFE00|\u2294\uFE00|\u22B4\u20D2|\u22B5\u20D2|\u22D8\u0338|\u22D9\u0338|\u22DA\uFE00|\u22DB\uFE00|\u22F5\u0338|\u22F9\u0338|\u2933\u0338|\u29CF\u0338|\u29D0\u0338|\u2A6D\u0338|\u2A70\u0338|\u2A7D\u0338|\u2A7E\u0338|\u2AA1\u0338|\u2AA2\u0338|\u2AAC\uFE00|\u2AAD\uFE00|\u2AAF\u0338|\u2AB0\u0338|\u2AC5\u0338|\u2AC6\u0338|\u2ACB\uFE00|\u2ACC\uFE00|\u2AFD\u20E5|[\xA0-\u0113\u0116-\u0122\u0124-\u012B\u012E-\u014D\u0150-\u017E\u0192\u01B5\u01F5\u0237\u02C6\u02C7\u02D8-\u02DD\u0311\u0391-\u03A1\u03A3-\u03A9\u03B1-\u03C9\u03D1\u03D2\u03D5\u03D6\u03DC\u03DD\u03F0\u03F1\u03F5\u03F6\u0401-\u040C\u040E-\u044F\u0451-\u045C\u045E\u045F\u2002-\u2005\u2007-\u2010\u2013-\u2016\u2018-\u201A\u201C-\u201E\u2020-\u2022\u2025\u2026\u2030-\u2035\u2039\u203A\u203E\u2041\u2043\u2044\u204F\u2057\u205F-\u2063\u20AC\u20DB\u20DC\u2102\u2105\u210A-\u2113\u2115-\u211E\u2122\u2124\u2127-\u2129\u212C\u212D\u212F-\u2131\u2133-\u2138\u2145-\u2148\u2153-\u215E\u2190-\u219B\u219D-\u21A7\u21A9-\u21AE\u21B0-\u21B3\u21B5-\u21B7\u21BA-\u21DB\u21DD\u21E4\u21E5\u21F5\u21FD-\u2205\u2207-\u2209\u220B\u220C\u220F-\u2214\u2216-\u2218\u221A\u221D-\u2238\u223A-\u2257\u2259\u225A\u225C\u225F-\u2262\u2264-\u228B\u228D-\u229B\u229D-\u22A5\u22A7-\u22B0\u22B2-\u22BB\u22BD-\u22DB\u22DE-\u22E3\u22E6-\u22F7\u22F9-\u22FE\u2305\u2306\u2308-\u2310\u2312\u2313\u2315\u2316\u231C-\u231F\u2322\u2323\u232D\u232E\u2336\u233D\u233F\u237C\u23B0\u23B1\u23B4-\u23B6\u23DC-\u23DF\u23E2\u23E7\u2423\u24C8\u2500\u2502\u250C\u2510\u2514\u2518\u251C\u2524\u252C\u2534\u253C\u2550-\u256C\u2580\u2584\u2588\u2591-\u2593\u25A1\u25AA\u25AB\u25AD\u25AE\u25B1\u25B3-\u25B5\u25B8\u25B9\u25BD-\u25BF\u25C2\u25C3\u25CA\u25CB\u25EC\u25EF\u25F8-\u25FC\u2605\u2606\u260E\u2640\u2642\u2660\u2663\u2665\u2666\u266A\u266D-\u266F\u2713\u2717\u2720\u2736\u2758\u2772\u2773\u27C8\u27C9\u27E6-\u27ED\u27F5-\u27FA\u27FC\u27FF\u2902-\u2905\u290C-\u2913\u2916\u2919-\u2920\u2923-\u292A\u2933\u2935-\u2939\u293C\u293D\u2945\u2948-\u294B\u294E-\u2976\u2978\u2979\u297B-\u297F\u2985\u2986\u298B-\u2996\u299A\u299C\u299D\u29A4-\u29B7\u29B9\u29BB\u29BC\u29BE-\u29C5\u29C9\u29CD-\u29D0\u29DC-\u29DE\u29E3-\u29E5\u29EB\u29F4\u29F6\u2A00-\u2A02\u2A04\u2A06\u2A0C\u2A0D\u2A10-\u2A17\u2A22-\u2A27\u2A29\u2A2A\u2A2D-\u2A31\u2A33-\u2A3C\u2A3F\u2A40\u2A42-\u2A4D\u2A50\u2A53-\u2A58\u2A5A-\u2A5D\u2A5F\u2A66\u2A6A\u2A6D-\u2A75\u2A77-\u2A9A\u2A9D-\u2AA2\u2AA4-\u2AB0\u2AB3-\u2AC8\u2ACB\u2ACC\u2ACF-\u2ADB\u2AE4\u2AE6-\u2AE9\u2AEB-\u2AF3\u2AFD\uFB00-\uFB04]|\uD835[\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDCCF\uDD04\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDD6B]/g,i={Á:"Aacute",á:"aacute",Ă:"Abreve",ă:"abreve","∾":"ac","∿":"acd","∾̳":"acE",Â:"Acirc",â:"acirc","´":"acute",А:"Acy",а:"acy",Æ:"AElig",æ:"aelig","⁡":"af","𝔄":"Afr","𝔞":"afr",À:"Agrave",à:"agrave",ℵ:"aleph",Α:"Alpha",α:"alpha",Ā:"Amacr",ā:"amacr","⨿":"amalg","&":"amp","⩕":"andand","⩓":"And","∧":"and","⩜":"andd","⩘":"andslope","⩚":"andv","∠":"ang","⦤":"ange","⦨":"angmsdaa","⦩":"angmsdab","⦪":"angmsdac","⦫":"angmsdad","⦬":"angmsdae","⦭":"angmsdaf","⦮":"angmsdag","⦯":"angmsdah","∡":"angmsd","∟":"angrt","⊾":"angrtvb","⦝":"angrtvbd","∢":"angsph",Å:"angst","⍼":"angzarr",Ą:"Aogon",ą:"aogon","𝔸":"Aopf","𝕒":"aopf","⩯":"apacir","≈":"ap","⩰":"apE","≊":"ape","≋":"apid","'":"apos",å:"aring","𝒜":"Ascr","𝒶":"ascr","≔":"colone","*":"ast","≍":"CupCap",Ã:"Atilde",ã:"atilde",Ä:"Auml",ä:"auml","∳":"awconint","⨑":"awint","≌":"bcong","϶":"bepsi","‵":"bprime","∽":"bsim","⋍":"bsime","∖":"setmn","⫧":"Barv","⊽":"barvee","⌅":"barwed","⌆":"Barwed","⎵":"bbrk","⎶":"bbrktbrk",Б:"Bcy",б:"bcy","„":"bdquo","∵":"becaus","⦰":"bemptyv",ℬ:"Bscr",Β:"Beta",β:"beta",ℶ:"beth","≬":"twixt","𝔅":"Bfr","𝔟":"bfr","⋂":"xcap","◯":"xcirc","⋃":"xcup","⨀":"xodot","⨁":"xoplus","⨂":"xotime","⨆":"xsqcup","★":"starf","▽":"xdtri","△":"xutri","⨄":"xuplus","⋁":"Vee","⋀":"Wedge","⤍":"rbarr","⧫":"lozf","▪":"squf","▴":"utrif","▾":"dtrif","◂":"ltrif","▸":"rtrif","␣":"blank","▒":"blk12","░":"blk14","▓":"blk34","█":"block","=⃥":"bne","≡⃥":"bnequiv","⫭":"bNot","⌐":"bnot","𝔹":"Bopf","𝕓":"bopf","⊥":"bot","⋈":"bowtie","⧉":"boxbox","┐":"boxdl","╕":"boxdL","╖":"boxDl","╗":"boxDL","┌":"boxdr","╒":"boxdR","╓":"boxDr","╔":"boxDR","─":"boxh","═":"boxH","┬":"boxhd","╤":"boxHd","╥":"boxhD","╦":"boxHD","┴":"boxhu","╧":"boxHu","╨":"boxhU","╩":"boxHU","⊟":"minusb","⊞":"plusb","⊠":"timesb","┘":"boxul","╛":"boxuL","╜":"boxUl","╝":"boxUL","└":"boxur","╘":"boxuR","╙":"boxUr","╚":"boxUR","│":"boxv","║":"boxV","┼":"boxvh","╪":"boxvH","╫":"boxVh","╬":"boxVH","┤":"boxvl","╡":"boxvL","╢":"boxVl","╣":"boxVL","├":"boxvr","╞":"boxvR","╟":"boxVr","╠":"boxVR","˘":"breve","¦":"brvbar","𝒷":"bscr","⁏":"bsemi","⧅":"bsolb","\\":"bsol","⟈":"bsolhsub","•":"bull","≎":"bump","⪮":"bumpE","≏":"bumpe",Ć:"Cacute",ć:"cacute","⩄":"capand","⩉":"capbrcup","⩋":"capcap","∩":"cap","⋒":"Cap","⩇":"capcup","⩀":"capdot",ⅅ:"DD","∩︀":"caps","⁁":"caret",ˇ:"caron",ℭ:"Cfr","⩍":"ccaps",Č:"Ccaron",č:"ccaron",Ç:"Ccedil",ç:"ccedil",Ĉ:"Ccirc",ĉ:"ccirc","∰":"Cconint","⩌":"ccups","⩐":"ccupssm",Ċ:"Cdot",ċ:"cdot","¸":"cedil","⦲":"cemptyv","¢":"cent","·":"middot","𝔠":"cfr",Ч:"CHcy",ч:"chcy","✓":"check",Χ:"Chi",χ:"chi",ˆ:"circ","≗":"cire","↺":"olarr","↻":"orarr","⊛":"oast","⊚":"ocir","⊝":"odash","⊙":"odot","®":"reg","Ⓢ":"oS","⊖":"ominus","⊕":"oplus","⊗":"otimes","○":"cir","⧃":"cirE","⨐":"cirfnint","⫯":"cirmid","⧂":"cirscir","∲":"cwconint","”":"rdquo","’":"rsquo","♣":"clubs",":":"colon","∷":"Colon","⩴":"Colone",",":"comma","@":"commat","∁":"comp","∘":"compfn",ℂ:"Copf","≅":"cong","⩭":"congdot","≡":"equiv","∮":"oint","∯":"Conint","𝕔":"copf","∐":"coprod","©":"copy","℗":"copysr","↵":"crarr","✗":"cross","⨯":"Cross","𝒞":"Cscr","𝒸":"cscr","⫏":"csub","⫑":"csube","⫐":"csup","⫒":"csupe","⋯":"ctdot","⤸":"cudarrl","⤵":"cudarrr","⋞":"cuepr","⋟":"cuesc","↶":"cularr","⤽":"cularrp","⩈":"cupbrcap","⩆":"cupcap","∪":"cup","⋓":"Cup","⩊":"cupcup","⊍":"cupdot","⩅":"cupor","∪︀":"cups","↷":"curarr","⤼":"curarrm","⋎":"cuvee","⋏":"cuwed","¤":"curren","∱":"cwint","⌭":"cylcty","†":"dagger","‡":"Dagger",ℸ:"daleth","↓":"darr","↡":"Darr","⇓":"dArr","‐":"dash","⫤":"Dashv","⊣":"dashv","⤏":"rBarr","˝":"dblac",Ď:"Dcaron",ď:"dcaron",Д:"Dcy",д:"dcy","⇊":"ddarr",ⅆ:"dd","⤑":"DDotrahd","⩷":"eDDot","°":"deg","∇":"Del",Δ:"Delta",δ:"delta","⦱":"demptyv","⥿":"dfisht","𝔇":"Dfr","𝔡":"dfr","⥥":"dHar","⇃":"dharl","⇂":"dharr","˙":"dot","`":"grave","˜":"tilde","⋄":"diam","♦":"diams","¨":"die",ϝ:"gammad","⋲":"disin","÷":"div","⋇":"divonx",Ђ:"DJcy",ђ:"djcy","⌞":"dlcorn","⌍":"dlcrop",$:"dollar","𝔻":"Dopf","𝕕":"dopf","⃜":"DotDot","≐":"doteq","≑":"eDot","∸":"minusd","∔":"plusdo","⊡":"sdotb","⇐":"lArr","⇔":"iff","⟸":"xlArr","⟺":"xhArr","⟹":"xrArr","⇒":"rArr","⊨":"vDash","⇑":"uArr","⇕":"vArr","∥":"par","⤓":"DownArrowBar","⇵":"duarr","̑":"DownBreve","⥐":"DownLeftRightVector","⥞":"DownLeftTeeVector","⥖":"DownLeftVectorBar","↽":"lhard","⥟":"DownRightTeeVector","⥗":"DownRightVectorBar","⇁":"rhard","↧":"mapstodown","⊤":"top","⤐":"RBarr","⌟":"drcorn","⌌":"drcrop","𝒟":"Dscr","𝒹":"dscr",Ѕ:"DScy",ѕ:"dscy","⧶":"dsol",Đ:"Dstrok",đ:"dstrok","⋱":"dtdot","▿":"dtri","⥯":"duhar","⦦":"dwangle",Џ:"DZcy",џ:"dzcy","⟿":"dzigrarr",É:"Eacute",é:"eacute","⩮":"easter",Ě:"Ecaron",ě:"ecaron",Ê:"Ecirc",ê:"ecirc","≖":"ecir","≕":"ecolon",Э:"Ecy",э:"ecy",Ė:"Edot",ė:"edot",ⅇ:"ee","≒":"efDot","𝔈":"Efr","𝔢":"efr","⪚":"eg",È:"Egrave",è:"egrave","⪖":"egs","⪘":"egsdot","⪙":"el","∈":"in","⏧":"elinters",ℓ:"ell","⪕":"els","⪗":"elsdot",Ē:"Emacr",ē:"emacr","∅":"empty","◻":"EmptySmallSquare","▫":"EmptyVerySmallSquare"," ":"emsp13"," ":"emsp14"," ":"emsp",Ŋ:"ENG",ŋ:"eng"," ":"ensp",Ę:"Eogon",ę:"eogon","𝔼":"Eopf","𝕖":"eopf","⋕":"epar","⧣":"eparsl","⩱":"eplus",ε:"epsi",Ε:"Epsilon",ϵ:"epsiv","≂":"esim","⩵":"Equal","=":"equals","≟":"equest","⇌":"rlhar","⩸":"equivDD","⧥":"eqvparsl","⥱":"erarr","≓":"erDot",ℯ:"escr",ℰ:"Escr","⩳":"Esim",Η:"Eta",η:"eta",Ð:"ETH",ð:"eth",Ë:"Euml",ë:"euml","€":"euro","!":"excl","∃":"exist",Ф:"Fcy",ф:"fcy","♀":"female",ffi:"ffilig",ff:"fflig",ffl:"ffllig","𝔉":"Ffr","𝔣":"ffr",fi:"filig","◼":"FilledSmallSquare",fj:"fjlig","♭":"flat",fl:"fllig","▱":"fltns",ƒ:"fnof","𝔽":"Fopf","𝕗":"fopf","∀":"forall","⋔":"fork","⫙":"forkv",ℱ:"Fscr","⨍":"fpartint","½":"half","⅓":"frac13","¼":"frac14","⅕":"frac15","⅙":"frac16","⅛":"frac18","⅔":"frac23","⅖":"frac25","¾":"frac34","⅗":"frac35","⅜":"frac38","⅘":"frac45","⅚":"frac56","⅝":"frac58","⅞":"frac78","⁄":"frasl","⌢":"frown","𝒻":"fscr",ǵ:"gacute",Γ:"Gamma",γ:"gamma",Ϝ:"Gammad","⪆":"gap",Ğ:"Gbreve",ğ:"gbreve",Ģ:"Gcedil",Ĝ:"Gcirc",ĝ:"gcirc",Г:"Gcy",г:"gcy",Ġ:"Gdot",ġ:"gdot","≥":"ge","≧":"gE","⪌":"gEl","⋛":"gel","⩾":"ges","⪩":"gescc","⪀":"gesdot","⪂":"gesdoto","⪄":"gesdotol","⋛︀":"gesl","⪔":"gesles","𝔊":"Gfr","𝔤":"gfr","≫":"gg","⋙":"Gg",ℷ:"gimel",Ѓ:"GJcy",ѓ:"gjcy","⪥":"gla","≷":"gl","⪒":"glE","⪤":"glj","⪊":"gnap","⪈":"gne","≩":"gnE","⋧":"gnsim","𝔾":"Gopf","𝕘":"gopf","⪢":"GreaterGreater","≳":"gsim","𝒢":"Gscr",ℊ:"gscr","⪎":"gsime","⪐":"gsiml","⪧":"gtcc","⩺":"gtcir",">":"gt","⋗":"gtdot","⦕":"gtlPar","⩼":"gtquest","⥸":"gtrarr","≩︀":"gvnE"," ":"hairsp",ℋ:"Hscr",Ъ:"HARDcy",ъ:"hardcy","⥈":"harrcir","↔":"harr","↭":"harrw","^":"Hat",ℏ:"hbar",Ĥ:"Hcirc",ĥ:"hcirc","♥":"hearts","…":"mldr","⊹":"hercon","𝔥":"hfr",ℌ:"Hfr","⤥":"searhk","⤦":"swarhk","⇿":"hoarr","∻":"homtht","↩":"larrhk","↪":"rarrhk","𝕙":"hopf",ℍ:"Hopf","―":"horbar","𝒽":"hscr",Ħ:"Hstrok",ħ:"hstrok","⁃":"hybull",Í:"Iacute",í:"iacute","⁣":"ic",Î:"Icirc",î:"icirc",И:"Icy",и:"icy",İ:"Idot",Е:"IEcy",е:"iecy","¡":"iexcl","𝔦":"ifr",ℑ:"Im",Ì:"Igrave",ì:"igrave",ⅈ:"ii","⨌":"qint","∭":"tint","⧜":"iinfin","℩":"iiota",IJ:"IJlig",ij:"ijlig",Ī:"Imacr",ī:"imacr",ℐ:"Iscr",ı:"imath","⊷":"imof",Ƶ:"imped","℅":"incare","∞":"infin","⧝":"infintie","⊺":"intcal","∫":"int","∬":"Int",ℤ:"Zopf","⨗":"intlarhk","⨼":"iprod","⁢":"it",Ё:"IOcy",ё:"iocy",Į:"Iogon",į:"iogon","𝕀":"Iopf","𝕚":"iopf",Ι:"Iota",ι:"iota","¿":"iquest","𝒾":"iscr","⋵":"isindot","⋹":"isinE","⋴":"isins","⋳":"isinsv",Ĩ:"Itilde",ĩ:"itilde",І:"Iukcy",і:"iukcy",Ï:"Iuml",ï:"iuml",Ĵ:"Jcirc",ĵ:"jcirc",Й:"Jcy",й:"jcy","𝔍":"Jfr","𝔧":"jfr",ȷ:"jmath","𝕁":"Jopf","𝕛":"jopf","𝒥":"Jscr","𝒿":"jscr",Ј:"Jsercy",ј:"jsercy",Є:"Jukcy",є:"jukcy",Κ:"Kappa",κ:"kappa",ϰ:"kappav",Ķ:"Kcedil",ķ:"kcedil",К:"Kcy",к:"kcy","𝔎":"Kfr","𝔨":"kfr",ĸ:"kgreen",Х:"KHcy",х:"khcy",Ќ:"KJcy",ќ:"kjcy","𝕂":"Kopf","𝕜":"kopf","𝒦":"Kscr","𝓀":"kscr","⇚":"lAarr",Ĺ:"Lacute",ĺ:"lacute","⦴":"laemptyv",ℒ:"Lscr",Λ:"Lambda",λ:"lambda","⟨":"lang","⟪":"Lang","⦑":"langd","⪅":"lap","«":"laquo","⇤":"larrb","⤟":"larrbfs","←":"larr","↞":"Larr","⤝":"larrfs","↫":"larrlp","⤹":"larrpl","⥳":"larrsim","↢":"larrtl","⤙":"latail","⤛":"lAtail","⪫":"lat","⪭":"late","⪭︀":"lates","⤌":"lbarr","⤎":"lBarr","❲":"lbbrk","{":"lcub","[":"lsqb","⦋":"lbrke","⦏":"lbrksld","⦍":"lbrkslu",Ľ:"Lcaron",ľ:"lcaron",Ļ:"Lcedil",ļ:"lcedil","⌈":"lceil",Л:"Lcy",л:"lcy","⤶":"ldca","“":"ldquo","⥧":"ldrdhar","⥋":"ldrushar","↲":"ldsh","≤":"le","≦":"lE","⇆":"lrarr","⟦":"lobrk","⥡":"LeftDownTeeVector","⥙":"LeftDownVectorBar","⌊":"lfloor","↼":"lharu","⇇":"llarr","⇋":"lrhar","⥎":"LeftRightVector","↤":"mapstoleft","⥚":"LeftTeeVector","⋋":"lthree","⧏":"LeftTriangleBar","⊲":"vltri","⊴":"ltrie","⥑":"LeftUpDownVector","⥠":"LeftUpTeeVector","⥘":"LeftUpVectorBar","↿":"uharl","⥒":"LeftVectorBar","⪋":"lEg","⋚":"leg","⩽":"les","⪨":"lescc","⩿":"lesdot","⪁":"lesdoto","⪃":"lesdotor","⋚︀":"lesg","⪓":"lesges","⋖":"ltdot","≶":"lg","⪡":"LessLess","≲":"lsim","⥼":"lfisht","𝔏":"Lfr","𝔩":"lfr","⪑":"lgE","⥢":"lHar","⥪":"lharul","▄":"lhblk",Љ:"LJcy",љ:"ljcy","≪":"ll","⋘":"Ll","⥫":"llhard","◺":"lltri",Ŀ:"Lmidot",ŀ:"lmidot","⎰":"lmoust","⪉":"lnap","⪇":"lne","≨":"lnE","⋦":"lnsim","⟬":"loang","⇽":"loarr","⟵":"xlarr","⟷":"xharr","⟼":"xmap","⟶":"xrarr","↬":"rarrlp","⦅":"lopar","𝕃":"Lopf","𝕝":"lopf","⨭":"loplus","⨴":"lotimes","∗":"lowast",_:"lowbar","↙":"swarr","↘":"searr","◊":"loz","(":"lpar","⦓":"lparlt","⥭":"lrhard","‎":"lrm","⊿":"lrtri","‹":"lsaquo","𝓁":"lscr","↰":"lsh","⪍":"lsime","⪏":"lsimg","‘":"lsquo","‚":"sbquo",Ł:"Lstrok",ł:"lstrok","⪦":"ltcc","⩹":"ltcir","<":"lt","⋉":"ltimes","⥶":"ltlarr","⩻":"ltquest","◃":"ltri","⦖":"ltrPar","⥊":"lurdshar","⥦":"luruhar","≨︀":"lvnE","¯":"macr","♂":"male","✠":"malt","⤅":"Map","↦":"map","↥":"mapstoup","▮":"marker","⨩":"mcomma",М:"Mcy",м:"mcy","—":"mdash","∺":"mDDot"," ":"MediumSpace",ℳ:"Mscr","𝔐":"Mfr","𝔪":"mfr","℧":"mho",µ:"micro","⫰":"midcir","∣":"mid","−":"minus","⨪":"minusdu","∓":"mp","⫛":"mlcp","⊧":"models","𝕄":"Mopf","𝕞":"mopf","𝓂":"mscr",Μ:"Mu",μ:"mu","⊸":"mumap",Ń:"Nacute",ń:"nacute","∠⃒":"nang","≉":"nap","⩰̸":"napE","≋̸":"napid",ʼn:"napos","♮":"natur",ℕ:"Nopf"," ":"nbsp","≎̸":"nbump","≏̸":"nbumpe","⩃":"ncap",Ň:"Ncaron",ň:"ncaron",Ņ:"Ncedil",ņ:"ncedil","≇":"ncong","⩭̸":"ncongdot","⩂":"ncup",Н:"Ncy",н:"ncy","–":"ndash","⤤":"nearhk","↗":"nearr","⇗":"neArr","≠":"ne","≐̸":"nedot","​":"ZeroWidthSpace","≢":"nequiv","⤨":"toea","≂̸":"nesim","\n":"NewLine","∄":"nexist","𝔑":"Nfr","𝔫":"nfr","≧̸":"ngE","≱":"nge","⩾̸":"nges","⋙̸":"nGg","≵":"ngsim","≫⃒":"nGt","≯":"ngt","≫̸":"nGtv","↮":"nharr","⇎":"nhArr","⫲":"nhpar","∋":"ni","⋼":"nis","⋺":"nisd",Њ:"NJcy",њ:"njcy","↚":"nlarr","⇍":"nlArr","‥":"nldr","≦̸":"nlE","≰":"nle","⩽̸":"nles","≮":"nlt","⋘̸":"nLl","≴":"nlsim","≪⃒":"nLt","⋪":"nltri","⋬":"nltrie","≪̸":"nLtv","∤":"nmid","⁠":"NoBreak","𝕟":"nopf","⫬":"Not","¬":"not","≭":"NotCupCap","∦":"npar","∉":"notin","≹":"ntgl","⋵̸":"notindot","⋹̸":"notinE","⋷":"notinvb","⋶":"notinvc","⧏̸":"NotLeftTriangleBar","≸":"ntlg","⪢̸":"NotNestedGreaterGreater","⪡̸":"NotNestedLessLess","∌":"notni","⋾":"notnivb","⋽":"notnivc","⊀":"npr","⪯̸":"npre","⋠":"nprcue","⧐̸":"NotRightTriangleBar","⋫":"nrtri","⋭":"nrtrie","⊏̸":"NotSquareSubset","⋢":"nsqsube","⊐̸":"NotSquareSuperset","⋣":"nsqsupe","⊂⃒":"vnsub","⊈":"nsube","⊁":"nsc","⪰̸":"nsce","⋡":"nsccue","≿̸":"NotSucceedsTilde","⊃⃒":"vnsup","⊉":"nsupe","≁":"nsim","≄":"nsime","⫽⃥":"nparsl","∂̸":"npart","⨔":"npolint","⤳̸":"nrarrc","↛":"nrarr","⇏":"nrArr","↝̸":"nrarrw","𝒩":"Nscr","𝓃":"nscr","⊄":"nsub","⫅̸":"nsubE","⊅":"nsup","⫆̸":"nsupE",Ñ:"Ntilde",ñ:"ntilde",Ν:"Nu",ν:"nu","#":"num","№":"numero"," ":"numsp","≍⃒":"nvap","⊬":"nvdash","⊭":"nvDash","⊮":"nVdash","⊯":"nVDash","≥⃒":"nvge",">⃒":"nvgt","⤄":"nvHarr","⧞":"nvinfin","⤂":"nvlArr","≤⃒":"nvle","<⃒":"nvlt","⊴⃒":"nvltrie","⤃":"nvrArr","⊵⃒":"nvrtrie","∼⃒":"nvsim","⤣":"nwarhk","↖":"nwarr","⇖":"nwArr","⤧":"nwnear",Ó:"Oacute",ó:"oacute",Ô:"Ocirc",ô:"ocirc",О:"Ocy",о:"ocy",Ő:"Odblac",ő:"odblac","⨸":"odiv","⦼":"odsold",Œ:"OElig",œ:"oelig","⦿":"ofcir","𝔒":"Ofr","𝔬":"ofr","˛":"ogon",Ò:"Ograve",ò:"ograve","⧁":"ogt","⦵":"ohbar",Ω:"ohm","⦾":"olcir","⦻":"olcross","‾":"oline","⧀":"olt",Ō:"Omacr",ō:"omacr",ω:"omega",Ο:"Omicron",ο:"omicron","⦶":"omid","𝕆":"Oopf","𝕠":"oopf","⦷":"opar","⦹":"operp","⩔":"Or","∨":"or","⩝":"ord",ℴ:"oscr",ª:"ordf",º:"ordm","⊶":"origof","⩖":"oror","⩗":"orslope","⩛":"orv","𝒪":"Oscr",Ø:"Oslash",ø:"oslash","⊘":"osol",Õ:"Otilde",õ:"otilde","⨶":"otimesas","⨷":"Otimes",Ö:"Ouml",ö:"ouml","⌽":"ovbar","⏞":"OverBrace","⎴":"tbrk","⏜":"OverParenthesis","¶":"para","⫳":"parsim","⫽":"parsl","∂":"part",П:"Pcy",п:"pcy","%":"percnt",".":"period","‰":"permil","‱":"pertenk","𝔓":"Pfr","𝔭":"pfr",Φ:"Phi",φ:"phi",ϕ:"phiv","☎":"phone",Π:"Pi",π:"pi",ϖ:"piv",ℎ:"planckh","⨣":"plusacir","⨢":"pluscir","+":"plus","⨥":"plusdu","⩲":"pluse","±":"pm","⨦":"plussim","⨧":"plustwo","⨕":"pointint","𝕡":"popf",ℙ:"Popf","£":"pound","⪷":"prap","⪻":"Pr","≺":"pr","≼":"prcue","⪯":"pre","≾":"prsim","⪹":"prnap","⪵":"prnE","⋨":"prnsim","⪳":"prE","′":"prime","″":"Prime","∏":"prod","⌮":"profalar","⌒":"profline","⌓":"profsurf","∝":"prop","⊰":"prurel","𝒫":"Pscr","𝓅":"pscr",Ψ:"Psi",ψ:"psi"," ":"puncsp","𝔔":"Qfr","𝔮":"qfr","𝕢":"qopf",ℚ:"Qopf","⁗":"qprime","𝒬":"Qscr","𝓆":"qscr","⨖":"quatint","?":"quest",'"':"quot","⇛":"rAarr","∽̱":"race",Ŕ:"Racute",ŕ:"racute","√":"Sqrt","⦳":"raemptyv","⟩":"rang","⟫":"Rang","⦒":"rangd","⦥":"range","»":"raquo","⥵":"rarrap","⇥":"rarrb","⤠":"rarrbfs","⤳":"rarrc","→":"rarr","↠":"Rarr","⤞":"rarrfs","⥅":"rarrpl","⥴":"rarrsim","⤖":"Rarrtl","↣":"rarrtl","↝":"rarrw","⤚":"ratail","⤜":"rAtail","∶":"ratio","❳":"rbbrk","}":"rcub","]":"rsqb","⦌":"rbrke","⦎":"rbrksld","⦐":"rbrkslu",Ř:"Rcaron",ř:"rcaron",Ŗ:"Rcedil",ŗ:"rcedil","⌉":"rceil",Р:"Rcy",р:"rcy","⤷":"rdca","⥩":"rdldhar","↳":"rdsh",ℜ:"Re",ℛ:"Rscr",ℝ:"Ropf","▭":"rect","⥽":"rfisht","⌋":"rfloor","𝔯":"rfr","⥤":"rHar","⇀":"rharu","⥬":"rharul",Ρ:"Rho",ρ:"rho",ϱ:"rhov","⇄":"rlarr","⟧":"robrk","⥝":"RightDownTeeVector","⥕":"RightDownVectorBar","⇉":"rrarr","⊢":"vdash","⥛":"RightTeeVector","⋌":"rthree","⧐":"RightTriangleBar","⊳":"vrtri","⊵":"rtrie","⥏":"RightUpDownVector","⥜":"RightUpTeeVector","⥔":"RightUpVectorBar","↾":"uharr","⥓":"RightVectorBar","˚":"ring","‏":"rlm","⎱":"rmoust","⫮":"rnmid","⟭":"roang","⇾":"roarr","⦆":"ropar","𝕣":"ropf","⨮":"roplus","⨵":"rotimes","⥰":"RoundImplies",")":"rpar","⦔":"rpargt","⨒":"rppolint","›":"rsaquo","𝓇":"rscr","↱":"rsh","⋊":"rtimes","▹":"rtri","⧎":"rtriltri","⧴":"RuleDelayed","⥨":"ruluhar","℞":"rx",Ś:"Sacute",ś:"sacute","⪸":"scap",Š:"Scaron",š:"scaron","⪼":"Sc","≻":"sc","≽":"sccue","⪰":"sce","⪴":"scE",Ş:"Scedil",ş:"scedil",Ŝ:"Scirc",ŝ:"scirc","⪺":"scnap","⪶":"scnE","⋩":"scnsim","⨓":"scpolint","≿":"scsim",С:"Scy",с:"scy","⋅":"sdot","⩦":"sdote","⇘":"seArr","§":"sect",";":"semi","⤩":"tosa","✶":"sext","𝔖":"Sfr","𝔰":"sfr","♯":"sharp",Щ:"SHCHcy",щ:"shchcy",Ш:"SHcy",ш:"shcy","↑":"uarr","­":"shy",Σ:"Sigma",σ:"sigma",ς:"sigmaf","∼":"sim","⩪":"simdot","≃":"sime","⪞":"simg","⪠":"simgE","⪝":"siml","⪟":"simlE","≆":"simne","⨤":"simplus","⥲":"simrarr","⨳":"smashp","⧤":"smeparsl","⌣":"smile","⪪":"smt","⪬":"smte","⪬︀":"smtes",Ь:"SOFTcy",ь:"softcy","⌿":"solbar","⧄":"solb","/":"sol","𝕊":"Sopf","𝕤":"sopf","♠":"spades","⊓":"sqcap","⊓︀":"sqcaps","⊔":"sqcup","⊔︀":"sqcups","⊏":"sqsub","⊑":"sqsube","⊐":"sqsup","⊒":"sqsupe","□":"squ","𝒮":"Sscr","𝓈":"sscr","⋆":"Star","☆":"star","⊂":"sub","⋐":"Sub","⪽":"subdot","⫅":"subE","⊆":"sube","⫃":"subedot","⫁":"submult","⫋":"subnE","⊊":"subne","⪿":"subplus","⥹":"subrarr","⫇":"subsim","⫕":"subsub","⫓":"subsup","∑":"sum","♪":"sung","¹":"sup1","²":"sup2","³":"sup3","⊃":"sup","⋑":"Sup","⪾":"supdot","⫘":"supdsub","⫆":"supE","⊇":"supe","⫄":"supedot","⟉":"suphsol","⫗":"suphsub","⥻":"suplarr","⫂":"supmult","⫌":"supnE","⊋":"supne","⫀":"supplus","⫈":"supsim","⫔":"supsub","⫖":"supsup","⇙":"swArr","⤪":"swnwar",ß:"szlig"," ":"Tab","⌖":"target",Τ:"Tau",τ:"tau",Ť:"Tcaron",ť:"tcaron",Ţ:"Tcedil",ţ:"tcedil",Т:"Tcy",т:"tcy","⃛":"tdot","⌕":"telrec","𝔗":"Tfr","𝔱":"tfr","∴":"there4",Θ:"Theta",θ:"theta",ϑ:"thetav","  ":"ThickSpace"," ":"thinsp",Þ:"THORN",þ:"thorn","⨱":"timesbar","×":"times","⨰":"timesd","⌶":"topbot","⫱":"topcir","𝕋":"Topf","𝕥":"topf","⫚":"topfork","‴":"tprime","™":"trade","▵":"utri","≜":"trie","◬":"tridot","⨺":"triminus","⨹":"triplus","⧍":"trisb","⨻":"tritime","⏢":"trpezium","𝒯":"Tscr","𝓉":"tscr",Ц:"TScy",ц:"tscy",Ћ:"TSHcy",ћ:"tshcy",Ŧ:"Tstrok",ŧ:"tstrok",Ú:"Uacute",ú:"uacute","↟":"Uarr","⥉":"Uarrocir",Ў:"Ubrcy",ў:"ubrcy",Ŭ:"Ubreve",ŭ:"ubreve",Û:"Ucirc",û:"ucirc",У:"Ucy",у:"ucy","⇅":"udarr",Ű:"Udblac",ű:"udblac","⥮":"udhar","⥾":"ufisht","𝔘":"Ufr","𝔲":"ufr",Ù:"Ugrave",ù:"ugrave","⥣":"uHar","▀":"uhblk","⌜":"ulcorn","⌏":"ulcrop","◸":"ultri",Ū:"Umacr",ū:"umacr","⏟":"UnderBrace","⏝":"UnderParenthesis","⊎":"uplus",Ų:"Uogon",ų:"uogon","𝕌":"Uopf","𝕦":"uopf","⤒":"UpArrowBar","↕":"varr",υ:"upsi",ϒ:"Upsi",Υ:"Upsilon","⇈":"uuarr","⌝":"urcorn","⌎":"urcrop",Ů:"Uring",ů:"uring","◹":"urtri","𝒰":"Uscr","𝓊":"uscr","⋰":"utdot",Ũ:"Utilde",ũ:"utilde",Ü:"Uuml",ü:"uuml","⦧":"uwangle","⦜":"vangrt","⊊︀":"vsubne","⫋︀":"vsubnE","⊋︀":"vsupne","⫌︀":"vsupnE","⫨":"vBar","⫫":"Vbar","⫩":"vBarv",В:"Vcy",в:"vcy","⊩":"Vdash","⊫":"VDash","⫦":"Vdashl","⊻":"veebar","≚":"veeeq","⋮":"vellip","|":"vert","‖":"Vert","❘":"VerticalSeparator","≀":"wr","𝔙":"Vfr","𝔳":"vfr","𝕍":"Vopf","𝕧":"vopf","𝒱":"Vscr","𝓋":"vscr","⊪":"Vvdash","⦚":"vzigzag",Ŵ:"Wcirc",ŵ:"wcirc","⩟":"wedbar","≙":"wedgeq","℘":"wp","𝔚":"Wfr","𝔴":"wfr","𝕎":"Wopf","𝕨":"wopf","𝒲":"Wscr","𝓌":"wscr","𝔛":"Xfr","𝔵":"xfr",Ξ:"Xi",ξ:"xi","⋻":"xnis","𝕏":"Xopf","𝕩":"xopf","𝒳":"Xscr","𝓍":"xscr",Ý:"Yacute",ý:"yacute",Я:"YAcy",я:"yacy",Ŷ:"Ycirc",ŷ:"ycirc",Ы:"Ycy",ы:"ycy","¥":"yen","𝔜":"Yfr","𝔶":"yfr",Ї:"YIcy",ї:"yicy","𝕐":"Yopf","𝕪":"yopf","𝒴":"Yscr","𝓎":"yscr",Ю:"YUcy",ю:"yucy",ÿ:"yuml",Ÿ:"Yuml",Ź:"Zacute",ź:"zacute",Ž:"Zcaron",ž:"zcaron",З:"Zcy",з:"zcy",Ż:"Zdot",ż:"zdot",ℨ:"Zfr",Ζ:"Zeta",ζ:"zeta","𝔷":"zfr",Ж:"ZHcy",ж:"zhcy","⇝":"zigrarr","𝕫":"zopf","𝒵":"Zscr","𝓏":"zscr","‍":"zwj","‌":"zwnj"},j=/["'`]/g,k={'"':"&quot;","&":"&amp;","'":"&#x27;","<":"&lt;",">":"&gt;","`":"&#x60;"},l=/&#(?:[xX][^a-fA-F0-9]|[^0-9xX])/,m=/[\0-\x08\x0B\x0E-\x1F\x7F-\x9F\uFDD0-\uFDEF\uFFFE\uFFFF]|[\uD83F\uD87F\uD8BF\uD8FF\uD93F\uD97F\uD9BF\uD9FF\uDA3F\uDA7F\uDABF\uDAFF\uDB3F\uDB7F\uDBBF\uDBFF][\uDFFE\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,n=/&#([0-9]+)(;?)|&#[xX]([a-fA-F0-9]+)(;?)|&([0-9a-zA-Z]+);|&(Aacute|iacute|Uacute|plusmn|otilde|Otilde|Agrave|agrave|yacute|Yacute|oslash|Oslash|Atilde|atilde|brvbar|Ccedil|ccedil|ograve|curren|divide|Eacute|eacute|Ograve|oacute|Egrave|egrave|ugrave|frac12|frac14|frac34|Ugrave|Oacute|Iacute|ntilde|Ntilde|uacute|middot|Igrave|igrave|iquest|aacute|laquo|THORN|micro|iexcl|icirc|Icirc|Acirc|ucirc|ecirc|Ocirc|ocirc|Ecirc|Ucirc|aring|Aring|aelig|AElig|acute|pound|raquo|acirc|times|thorn|szlig|cedil|COPY|Auml|ordf|ordm|uuml|macr|Uuml|auml|Ouml|ouml|para|nbsp|Euml|quot|QUOT|euml|yuml|cent|sect|copy|sup1|sup2|sup3|Iuml|iuml|shy|eth|reg|not|yen|amp|AMP|REG|uml|ETH|deg|gt|GT|LT|lt)([=a-zA-Z0-9])?/g,o={Aacute:"Á",aacute:"á",Abreve:"Ă",abreve:"ă",ac:"∾",acd:"∿",acE:"∾̳",Acirc:"Â",acirc:"â",acute:"´",Acy:"А",acy:"а",AElig:"Æ",aelig:"æ",af:"⁡",Afr:"𝔄",afr:"𝔞",Agrave:"À",agrave:"à",alefsym:"ℵ",aleph:"ℵ",Alpha:"Α",alpha:"α",Amacr:"Ā",amacr:"ā",amalg:"⨿",amp:"&",AMP:"&",andand:"⩕",And:"⩓",and:"∧",andd:"⩜",andslope:"⩘",andv:"⩚",ang:"∠",ange:"⦤",angle:"∠",angmsdaa:"⦨",angmsdab:"⦩",angmsdac:"⦪",angmsdad:"⦫",angmsdae:"⦬",angmsdaf:"⦭",angmsdag:"⦮",angmsdah:"⦯",angmsd:"∡",angrt:"∟",angrtvb:"⊾",angrtvbd:"⦝",angsph:"∢",angst:"Å",angzarr:"⍼",Aogon:"Ą",aogon:"ą",Aopf:"𝔸",aopf:"𝕒",apacir:"⩯",ap:"≈",apE:"⩰",ape:"≊",apid:"≋",apos:"'",ApplyFunction:"⁡",approx:"≈",approxeq:"≊",Aring:"Å",aring:"å",Ascr:"𝒜",ascr:"𝒶",Assign:"≔",ast:"*",asymp:"≈",asympeq:"≍",Atilde:"Ã",atilde:"ã",Auml:"Ä",auml:"ä",awconint:"∳",awint:"⨑",backcong:"≌",backepsilon:"϶",backprime:"‵",backsim:"∽",backsimeq:"⋍",Backslash:"∖",Barv:"⫧",barvee:"⊽",barwed:"⌅",Barwed:"⌆",barwedge:"⌅",bbrk:"⎵",bbrktbrk:"⎶",bcong:"≌",Bcy:"Б",bcy:"б",bdquo:"„",becaus:"∵",because:"∵",Because:"∵",bemptyv:"⦰",bepsi:"϶",bernou:"ℬ",Bernoullis:"ℬ",Beta:"Β",beta:"β",beth:"ℶ",between:"≬",Bfr:"𝔅",bfr:"𝔟",bigcap:"⋂",bigcirc:"◯",bigcup:"⋃",bigodot:"⨀",bigoplus:"⨁",bigotimes:"⨂",bigsqcup:"⨆",bigstar:"★",bigtriangledown:"▽",bigtriangleup:"△",biguplus:"⨄",bigvee:"⋁",bigwedge:"⋀",bkarow:"⤍",blacklozenge:"⧫",blacksquare:"▪",blacktriangle:"▴",blacktriangledown:"▾",blacktriangleleft:"◂",blacktriangleright:"▸",blank:"␣",blk12:"▒",blk14:"░",blk34:"▓",block:"█",bne:"=⃥",bnequiv:"≡⃥",bNot:"⫭",bnot:"⌐",Bopf:"𝔹",bopf:"𝕓",bot:"⊥",bottom:"⊥",bowtie:"⋈",boxbox:"⧉",boxdl:"┐",boxdL:"╕",boxDl:"╖",boxDL:"╗",boxdr:"┌",boxdR:"╒",boxDr:"╓",boxDR:"╔",boxh:"─",boxH:"═",boxhd:"┬",boxHd:"╤",boxhD:"╥",boxHD:"╦",boxhu:"┴",boxHu:"╧",boxhU:"╨",boxHU:"╩",boxminus:"⊟",boxplus:"⊞",boxtimes:"⊠",boxul:"┘",boxuL:"╛",boxUl:"╜",boxUL:"╝",boxur:"└",boxuR:"╘",boxUr:"╙",boxUR:"╚",boxv:"│",boxV:"║",boxvh:"┼",boxvH:"╪",boxVh:"╫",boxVH:"╬",boxvl:"┤",boxvL:"╡",boxVl:"╢",boxVL:"╣",boxvr:"├",boxvR:"╞",boxVr:"╟",boxVR:"╠",bprime:"‵",breve:"˘",Breve:"˘",brvbar:"¦",bscr:"𝒷",Bscr:"ℬ",bsemi:"⁏",bsim:"∽",bsime:"⋍",bsolb:"⧅",bsol:"\\",bsolhsub:"⟈",bull:"•",bullet:"•",bump:"≎",bumpE:"⪮",bumpe:"≏",Bumpeq:"≎",bumpeq:"≏",Cacute:"Ć",cacute:"ć",capand:"⩄",capbrcup:"⩉",capcap:"⩋",cap:"∩",Cap:"⋒",capcup:"⩇",capdot:"⩀",CapitalDifferentialD:"ⅅ",caps:"∩︀",caret:"⁁",caron:"ˇ",Cayleys:"ℭ",ccaps:"⩍",Ccaron:"Č",ccaron:"č",Ccedil:"Ç",ccedil:"ç",Ccirc:"Ĉ",ccirc:"ĉ",Cconint:"∰",ccups:"⩌",ccupssm:"⩐",Cdot:"Ċ",cdot:"ċ",cedil:"¸",Cedilla:"¸",cemptyv:"⦲",cent:"¢",centerdot:"·",CenterDot:"·",cfr:"𝔠",Cfr:"ℭ",CHcy:"Ч",chcy:"ч",check:"✓",checkmark:"✓",Chi:"Χ",chi:"χ",circ:"ˆ",circeq:"≗",circlearrowleft:"↺",circlearrowright:"↻",circledast:"⊛",circledcirc:"⊚",circleddash:"⊝",CircleDot:"⊙",circledR:"®",circledS:"Ⓢ",CircleMinus:"⊖",CirclePlus:"⊕",CircleTimes:"⊗",cir:"○",cirE:"⧃",cire:"≗",cirfnint:"⨐",cirmid:"⫯",cirscir:"⧂",ClockwiseContourIntegral:"∲",CloseCurlyDoubleQuote:"”",CloseCurlyQuote:"’",clubs:"♣",clubsuit:"♣",colon:":",Colon:"∷",Colone:"⩴",colone:"≔",coloneq:"≔",comma:",",commat:"@",comp:"∁",compfn:"∘",complement:"∁",complexes:"ℂ",cong:"≅",congdot:"⩭",Congruent:"≡",conint:"∮",Conint:"∯",ContourIntegral:"∮",copf:"𝕔",Copf:"ℂ",coprod:"∐",Coproduct:"∐",copy:"©",COPY:"©",copysr:"℗",CounterClockwiseContourIntegral:"∳",crarr:"↵",cross:"✗",Cross:"⨯",Cscr:"𝒞",cscr:"𝒸",csub:"⫏",csube:"⫑",csup:"⫐",csupe:"⫒",ctdot:"⋯",cudarrl:"⤸",cudarrr:"⤵",cuepr:"⋞",cuesc:"⋟",cularr:"↶",cularrp:"⤽",cupbrcap:"⩈",cupcap:"⩆",CupCap:"≍",cup:"∪",Cup:"⋓",cupcup:"⩊",cupdot:"⊍",cupor:"⩅",cups:"∪︀",curarr:"↷",curarrm:"⤼",curlyeqprec:"⋞",curlyeqsucc:"⋟",curlyvee:"⋎",curlywedge:"⋏",curren:"¤",curvearrowleft:"↶",curvearrowright:"↷",cuvee:"⋎",cuwed:"⋏",cwconint:"∲",cwint:"∱",cylcty:"⌭",dagger:"†",Dagger:"‡",daleth:"ℸ",darr:"↓",Darr:"↡",dArr:"⇓",dash:"‐",Dashv:"⫤",dashv:"⊣",dbkarow:"⤏",dblac:"˝",Dcaron:"Ď",dcaron:"ď",Dcy:"Д",dcy:"д",ddagger:"‡",ddarr:"⇊",DD:"ⅅ",dd:"ⅆ",DDotrahd:"⤑",ddotseq:"⩷",deg:"°",Del:"∇",Delta:"Δ",delta:"δ",demptyv:"⦱",dfisht:"⥿",Dfr:"𝔇",dfr:"𝔡",dHar:"⥥",dharl:"⇃",dharr:"⇂",DiacriticalAcute:"´",DiacriticalDot:"˙",DiacriticalDoubleAcute:"˝",DiacriticalGrave:"`",DiacriticalTilde:"˜",diam:"⋄",diamond:"⋄",Diamond:"⋄",diamondsuit:"♦",diams:"♦",die:"¨",DifferentialD:"ⅆ",digamma:"ϝ",disin:"⋲",div:"÷",divide:"÷",divideontimes:"⋇",divonx:"⋇",DJcy:"Ђ",djcy:"ђ",dlcorn:"⌞",dlcrop:"⌍",dollar:"$",Dopf:"𝔻",dopf:"𝕕",Dot:"¨",dot:"˙",DotDot:"⃜",doteq:"≐",doteqdot:"≑",DotEqual:"≐",dotminus:"∸",dotplus:"∔",dotsquare:"⊡",doublebarwedge:"⌆",DoubleContourIntegral:"∯",DoubleDot:"¨",DoubleDownArrow:"⇓",DoubleLeftArrow:"⇐",DoubleLeftRightArrow:"⇔",DoubleLeftTee:"⫤",DoubleLongLeftArrow:"⟸",DoubleLongLeftRightArrow:"⟺",DoubleLongRightArrow:"⟹",DoubleRightArrow:"⇒",DoubleRightTee:"⊨",DoubleUpArrow:"⇑",DoubleUpDownArrow:"⇕",DoubleVerticalBar:"∥",DownArrowBar:"⤓",downarrow:"↓",DownArrow:"↓",Downarrow:"⇓",DownArrowUpArrow:"⇵",DownBreve:"̑",downdownarrows:"⇊",downharpoonleft:"⇃",downharpoonright:"⇂",DownLeftRightVector:"⥐",DownLeftTeeVector:"⥞",DownLeftVectorBar:"⥖",DownLeftVector:"↽",DownRightTeeVector:"⥟",DownRightVectorBar:"⥗",DownRightVector:"⇁",DownTeeArrow:"↧",DownTee:"⊤",drbkarow:"⤐",drcorn:"⌟",drcrop:"⌌",Dscr:"𝒟",dscr:"𝒹",DScy:"Ѕ",dscy:"ѕ",dsol:"⧶",Dstrok:"Đ",dstrok:"đ",dtdot:"⋱",dtri:"▿",dtrif:"▾",duarr:"⇵",duhar:"⥯",dwangle:"⦦",DZcy:"Џ",dzcy:"џ",dzigrarr:"⟿",Eacute:"É",eacute:"é",easter:"⩮",Ecaron:"Ě",ecaron:"ě",Ecirc:"Ê",ecirc:"ê",ecir:"≖",ecolon:"≕",Ecy:"Э",ecy:"э",eDDot:"⩷",Edot:"Ė",edot:"ė",eDot:"≑",ee:"ⅇ",efDot:"≒",Efr:"𝔈",efr:"𝔢",eg:"⪚",Egrave:"È",egrave:"è",egs:"⪖",egsdot:"⪘",el:"⪙",Element:"∈",elinters:"⏧",ell:"ℓ",els:"⪕",elsdot:"⪗",Emacr:"Ē",emacr:"ē",empty:"∅",emptyset:"∅",EmptySmallSquare:"◻",emptyv:"∅",EmptyVerySmallSquare:"▫",emsp13:" ",emsp14:" ",emsp:" ",ENG:"Ŋ",eng:"ŋ",ensp:" ",Eogon:"Ę",eogon:"ę",Eopf:"𝔼",eopf:"𝕖",epar:"⋕",eparsl:"⧣",eplus:"⩱",epsi:"ε",Epsilon:"Ε",epsilon:"ε",epsiv:"ϵ",eqcirc:"≖",eqcolon:"≕",eqsim:"≂",eqslantgtr:"⪖",eqslantless:"⪕",Equal:"⩵",equals:"=",EqualTilde:"≂",equest:"≟",Equilibrium:"⇌",equiv:"≡",equivDD:"⩸",eqvparsl:"⧥",erarr:"⥱",erDot:"≓",escr:"ℯ",Escr:"ℰ",esdot:"≐",Esim:"⩳",esim:"≂",Eta:"Η",eta:"η",ETH:"Ð",eth:"ð",Euml:"Ë",euml:"ë",euro:"€",excl:"!",exist:"∃",Exists:"∃",expectation:"ℰ",exponentiale:"ⅇ",ExponentialE:"ⅇ",fallingdotseq:"≒",Fcy:"Ф",fcy:"ф",female:"♀",ffilig:"ffi",fflig:"ff",ffllig:"ffl",Ffr:"𝔉",ffr:"𝔣",filig:"fi",FilledSmallSquare:"◼",FilledVerySmallSquare:"▪",fjlig:"fj",flat:"♭",fllig:"fl",fltns:"▱",fnof:"ƒ",Fopf:"𝔽",fopf:"𝕗",forall:"∀",ForAll:"∀",fork:"⋔",forkv:"⫙",Fouriertrf:"ℱ",fpartint:"⨍",frac12:"½",frac13:"⅓",frac14:"¼",frac15:"⅕",frac16:"⅙",frac18:"⅛",frac23:"⅔",frac25:"⅖",frac34:"¾",frac35:"⅗",frac38:"⅜",frac45:"⅘",frac56:"⅚",frac58:"⅝",frac78:"⅞",frasl:"⁄",frown:"⌢",fscr:"𝒻",Fscr:"ℱ",gacute:"ǵ",Gamma:"Γ",gamma:"γ",Gammad:"Ϝ",gammad:"ϝ",gap:"⪆",Gbreve:"Ğ",gbreve:"ğ",Gcedil:"Ģ",Gcirc:"Ĝ",gcirc:"ĝ",Gcy:"Г",gcy:"г",Gdot:"Ġ",gdot:"ġ",ge:"≥",gE:"≧",gEl:"⪌",gel:"⋛",geq:"≥",geqq:"≧",geqslant:"⩾",gescc:"⪩",ges:"⩾",gesdot:"⪀",gesdoto:"⪂",gesdotol:"⪄",gesl:"⋛︀",gesles:"⪔",Gfr:"𝔊",gfr:"𝔤",gg:"≫",Gg:"⋙",ggg:"⋙",gimel:"ℷ",GJcy:"Ѓ",gjcy:"ѓ",gla:"⪥",gl:"≷",glE:"⪒",glj:"⪤",gnap:"⪊",gnapprox:"⪊",gne:"⪈",gnE:"≩",gneq:"⪈",gneqq:"≩",gnsim:"⋧",Gopf:"𝔾",gopf:"𝕘",grave:"`",GreaterEqual:"≥",GreaterEqualLess:"⋛",GreaterFullEqual:"≧",GreaterGreater:"⪢",GreaterLess:"≷",GreaterSlantEqual:"⩾",GreaterTilde:"≳",Gscr:"𝒢",gscr:"ℊ",gsim:"≳",gsime:"⪎",gsiml:"⪐",gtcc:"⪧",gtcir:"⩺",gt:">",GT:">",Gt:"≫",gtdot:"⋗",gtlPar:"⦕",gtquest:"⩼",gtrapprox:"⪆",gtrarr:"⥸",gtrdot:"⋗",gtreqless:"⋛",gtreqqless:"⪌",gtrless:"≷",gtrsim:"≳",gvertneqq:"≩︀",gvnE:"≩︀",Hacek:"ˇ",hairsp:" ",half:"½",hamilt:"ℋ",HARDcy:"Ъ",hardcy:"ъ",harrcir:"⥈",harr:"↔",hArr:"⇔",harrw:"↭",Hat:"^",hbar:"ℏ",Hcirc:"Ĥ",hcirc:"ĥ",hearts:"♥",heartsuit:"♥",hellip:"…",hercon:"⊹",hfr:"𝔥",Hfr:"ℌ",HilbertSpace:"ℋ",hksearow:"⤥",hkswarow:"⤦",hoarr:"⇿",homtht:"∻",hookleftarrow:"↩",hookrightarrow:"↪",hopf:"𝕙",Hopf:"ℍ",horbar:"―",HorizontalLine:"─",hscr:"𝒽",Hscr:"ℋ",hslash:"ℏ",Hstrok:"Ħ",hstrok:"ħ",HumpDownHump:"≎",HumpEqual:"≏",hybull:"⁃",hyphen:"‐",Iacute:"Í",iacute:"í",ic:"⁣",Icirc:"Î",icirc:"î",Icy:"И",icy:"и",Idot:"İ",IEcy:"Е",iecy:"е",iexcl:"¡",iff:"⇔",ifr:"𝔦",Ifr:"ℑ",Igrave:"Ì",igrave:"ì",ii:"ⅈ",iiiint:"⨌",iiint:"∭",iinfin:"⧜",iiota:"℩",IJlig:"IJ",ijlig:"ij",Imacr:"Ī",imacr:"ī",image:"ℑ",ImaginaryI:"ⅈ",imagline:"ℐ",imagpart:"ℑ",imath:"ı",Im:"ℑ",imof:"⊷",imped:"Ƶ",Implies:"⇒",incare:"℅","in":"∈",infin:"∞",infintie:"⧝",inodot:"ı",intcal:"⊺","int":"∫",Int:"∬",integers:"ℤ",Integral:"∫",intercal:"⊺",Intersection:"⋂",intlarhk:"⨗",intprod:"⨼",InvisibleComma:"⁣",InvisibleTimes:"⁢",IOcy:"Ё",iocy:"ё",Iogon:"Į",iogon:"į",Iopf:"𝕀",iopf:"𝕚",Iota:"Ι",iota:"ι",iprod:"⨼",iquest:"¿",iscr:"𝒾",Iscr:"ℐ",isin:"∈",isindot:"⋵",isinE:"⋹",isins:"⋴",isinsv:"⋳",isinv:"∈",it:"⁢",Itilde:"Ĩ",itilde:"ĩ",Iukcy:"І",iukcy:"і",Iuml:"Ï",iuml:"ï",Jcirc:"Ĵ",jcirc:"ĵ",Jcy:"Й",jcy:"й",Jfr:"𝔍",jfr:"𝔧",jmath:"ȷ",Jopf:"𝕁",jopf:"𝕛",Jscr:"𝒥",jscr:"𝒿",Jsercy:"Ј",jsercy:"ј",Jukcy:"Є",jukcy:"є",Kappa:"Κ",kappa:"κ",kappav:"ϰ",Kcedil:"Ķ",kcedil:"ķ",Kcy:"К",kcy:"к",Kfr:"𝔎",kfr:"𝔨",kgreen:"ĸ",KHcy:"Х",khcy:"х",KJcy:"Ќ",kjcy:"ќ",Kopf:"𝕂",kopf:"𝕜",Kscr:"𝒦",kscr:"𝓀",lAarr:"⇚",Lacute:"Ĺ",lacute:"ĺ",laemptyv:"⦴",lagran:"ℒ",Lambda:"Λ",lambda:"λ",lang:"⟨",Lang:"⟪",langd:"⦑",langle:"⟨",lap:"⪅",Laplacetrf:"ℒ",laquo:"«",larrb:"⇤",larrbfs:"⤟",larr:"←",Larr:"↞",lArr:"⇐",larrfs:"⤝",larrhk:"↩",larrlp:"↫",larrpl:"⤹",larrsim:"⥳",larrtl:"↢",latail:"⤙",lAtail:"⤛",lat:"⪫",late:"⪭",lates:"⪭︀",lbarr:"⤌",lBarr:"⤎",lbbrk:"❲",lbrace:"{",lbrack:"[",lbrke:"⦋",lbrksld:"⦏",lbrkslu:"⦍",Lcaron:"Ľ",lcaron:"ľ",Lcedil:"Ļ",lcedil:"ļ",lceil:"⌈",lcub:"{",Lcy:"Л",lcy:"л",ldca:"⤶",ldquo:"“",ldquor:"„",ldrdhar:"⥧",ldrushar:"⥋",ldsh:"↲",le:"≤",lE:"≦",LeftAngleBracket:"⟨",LeftArrowBar:"⇤",leftarrow:"←",LeftArrow:"←",Leftarrow:"⇐",LeftArrowRightArrow:"⇆",leftarrowtail:"↢",LeftCeiling:"⌈",LeftDoubleBracket:"⟦",LeftDownTeeVector:"⥡",LeftDownVectorBar:"⥙",LeftDownVector:"⇃",LeftFloor:"⌊",leftharpoondown:"↽",leftharpoonup:"↼",leftleftarrows:"⇇",leftrightarrow:"↔",LeftRightArrow:"↔",Leftrightarrow:"⇔",leftrightarrows:"⇆",leftrightharpoons:"⇋",leftrightsquigarrow:"↭",LeftRightVector:"⥎",LeftTeeArrow:"↤",LeftTee:"⊣",LeftTeeVector:"⥚",leftthreetimes:"⋋",LeftTriangleBar:"⧏",LeftTriangle:"⊲",LeftTriangleEqual:"⊴",LeftUpDownVector:"⥑",LeftUpTeeVector:"⥠",LeftUpVectorBar:"⥘",LeftUpVector:"↿",LeftVectorBar:"⥒",LeftVector:"↼",lEg:"⪋",leg:"⋚",leq:"≤",leqq:"≦",leqslant:"⩽",lescc:"⪨",les:"⩽",lesdot:"⩿",lesdoto:"⪁",lesdotor:"⪃",lesg:"⋚︀",lesges:"⪓",lessapprox:"⪅",lessdot:"⋖",lesseqgtr:"⋚",lesseqqgtr:"⪋",LessEqualGreater:"⋚",LessFullEqual:"≦",LessGreater:"≶",lessgtr:"≶",LessLess:"⪡",lesssim:"≲",LessSlantEqual:"⩽",LessTilde:"≲",lfisht:"⥼",lfloor:"⌊",Lfr:"𝔏",lfr:"𝔩",lg:"≶",lgE:"⪑",lHar:"⥢",lhard:"↽",lharu:"↼",lharul:"⥪",lhblk:"▄",LJcy:"Љ",ljcy:"љ",llarr:"⇇",ll:"≪",Ll:"⋘",llcorner:"⌞",Lleftarrow:"⇚",llhard:"⥫",lltri:"◺",Lmidot:"Ŀ",lmidot:"ŀ",lmoustache:"⎰",lmoust:"⎰",lnap:"⪉",lnapprox:"⪉",lne:"⪇",lnE:"≨",lneq:"⪇",lneqq:"≨",lnsim:"⋦",loang:"⟬",loarr:"⇽",lobrk:"⟦",longleftarrow:"⟵",LongLeftArrow:"⟵",Longleftarrow:"⟸",longleftrightarrow:"⟷",LongLeftRightArrow:"⟷",Longleftrightarrow:"⟺",longmapsto:"⟼",longrightarrow:"⟶",LongRightArrow:"⟶",Longrightarrow:"⟹",looparrowleft:"↫",looparrowright:"↬",lopar:"⦅",Lopf:"𝕃",lopf:"𝕝",loplus:"⨭",lotimes:"⨴",lowast:"∗",lowbar:"_",LowerLeftArrow:"↙",LowerRightArrow:"↘",loz:"◊",lozenge:"◊",lozf:"⧫",lpar:"(",lparlt:"⦓",lrarr:"⇆",lrcorner:"⌟",lrhar:"⇋",lrhard:"⥭",lrm:"‎",lrtri:"⊿",lsaquo:"‹",lscr:"𝓁",Lscr:"ℒ",lsh:"↰",Lsh:"↰",lsim:"≲",lsime:"⪍",lsimg:"⪏",lsqb:"[",lsquo:"‘",lsquor:"‚",Lstrok:"Ł",lstrok:"ł",ltcc:"⪦",ltcir:"⩹",lt:"<",LT:"<",Lt:"≪",ltdot:"⋖",lthree:"⋋",ltimes:"⋉",ltlarr:"⥶",ltquest:"⩻",ltri:"◃",ltrie:"⊴",ltrif:"◂",ltrPar:"⦖",lurdshar:"⥊",luruhar:"⥦",lvertneqq:"≨︀",lvnE:"≨︀",macr:"¯",male:"♂",malt:"✠",maltese:"✠",Map:"⤅",map:"↦",mapsto:"↦",mapstodown:"↧",mapstoleft:"↤",mapstoup:"↥",marker:"▮",mcomma:"⨩",Mcy:"М",mcy:"м",mdash:"—",mDDot:"∺",measuredangle:"∡",MediumSpace:" ",Mellintrf:"ℳ",Mfr:"𝔐",mfr:"𝔪",mho:"℧",micro:"µ",midast:"*",midcir:"⫰",mid:"∣",middot:"·",minusb:"⊟",minus:"−",minusd:"∸",minusdu:"⨪",MinusPlus:"∓",mlcp:"⫛",mldr:"…",mnplus:"∓",models:"⊧",Mopf:"𝕄",mopf:"𝕞",mp:"∓",mscr:"𝓂",Mscr:"ℳ",mstpos:"∾",Mu:"Μ",mu:"μ",multimap:"⊸",mumap:"⊸",nabla:"∇",Nacute:"Ń",nacute:"ń",nang:"∠⃒",nap:"≉",napE:"⩰̸",napid:"≋̸",napos:"ʼn",napprox:"≉",natural:"♮",naturals:"ℕ",natur:"♮",nbsp:" ",nbump:"≎̸",nbumpe:"≏̸",ncap:"⩃",Ncaron:"Ň",ncaron:"ň",Ncedil:"Ņ",ncedil:"ņ",ncong:"≇",ncongdot:"⩭̸",ncup:"⩂",Ncy:"Н",ncy:"н",ndash:"–",nearhk:"⤤",nearr:"↗",neArr:"⇗",nearrow:"↗",ne:"≠",nedot:"≐̸",NegativeMediumSpace:"​",NegativeThickSpace:"​",NegativeThinSpace:"​",NegativeVeryThinSpace:"​",nequiv:"≢",nesear:"⤨",nesim:"≂̸",NestedGreaterGreater:"≫",NestedLessLess:"≪",NewLine:"\n",nexist:"∄",nexists:"∄",Nfr:"𝔑",nfr:"𝔫",ngE:"≧̸",nge:"≱",ngeq:"≱",ngeqq:"≧̸",ngeqslant:"⩾̸",nges:"⩾̸",nGg:"⋙̸",ngsim:"≵",nGt:"≫⃒",ngt:"≯",ngtr:"≯",nGtv:"≫̸",nharr:"↮",nhArr:"⇎",nhpar:"⫲",ni:"∋",nis:"⋼",nisd:"⋺",niv:"∋",NJcy:"Њ",njcy:"њ",nlarr:"↚",nlArr:"⇍",nldr:"‥",nlE:"≦̸",nle:"≰",nleftarrow:"↚",nLeftarrow:"⇍",nleftrightarrow:"↮",nLeftrightarrow:"⇎",nleq:"≰",nleqq:"≦̸",nleqslant:"⩽̸",nles:"⩽̸",nless:"≮",nLl:"⋘̸",nlsim:"≴",nLt:"≪⃒",nlt:"≮",nltri:"⋪",nltrie:"⋬",nLtv:"≪̸",nmid:"∤",NoBreak:"⁠",NonBreakingSpace:" ",nopf:"𝕟",Nopf:"ℕ",Not:"⫬",not:"¬",NotCongruent:"≢",NotCupCap:"≭",NotDoubleVerticalBar:"∦",NotElement:"∉",NotEqual:"≠",NotEqualTilde:"≂̸",NotExists:"∄",NotGreater:"≯",NotGreaterEqual:"≱",NotGreaterFullEqual:"≧̸",NotGreaterGreater:"≫̸",NotGreaterLess:"≹",NotGreaterSlantEqual:"⩾̸",NotGreaterTilde:"≵",NotHumpDownHump:"≎̸",NotHumpEqual:"≏̸",notin:"∉",notindot:"⋵̸",notinE:"⋹̸",notinva:"∉",notinvb:"⋷",notinvc:"⋶",NotLeftTriangleBar:"⧏̸",NotLeftTriangle:"⋪",NotLeftTriangleEqual:"⋬",NotLess:"≮",NotLessEqual:"≰",NotLessGreater:"≸",NotLessLess:"≪̸",NotLessSlantEqual:"⩽̸",NotLessTilde:"≴",NotNestedGreaterGreater:"⪢̸",NotNestedLessLess:"⪡̸",notni:"∌",notniva:"∌",notnivb:"⋾",notnivc:"⋽",NotPrecedes:"⊀",NotPrecedesEqual:"⪯̸",NotPrecedesSlantEqual:"⋠",NotReverseElement:"∌",NotRightTriangleBar:"⧐̸",NotRightTriangle:"⋫",NotRightTriangleEqual:"⋭",NotSquareSubset:"⊏̸",NotSquareSubsetEqual:"⋢",NotSquareSuperset:"⊐̸",NotSquareSupersetEqual:"⋣",NotSubset:"⊂⃒",NotSubsetEqual:"⊈",NotSucceeds:"⊁",NotSucceedsEqual:"⪰̸",NotSucceedsSlantEqual:"⋡",NotSucceedsTilde:"≿̸",NotSuperset:"⊃⃒",NotSupersetEqual:"⊉",NotTilde:"≁",NotTildeEqual:"≄",NotTildeFullEqual:"≇",NotTildeTilde:"≉",NotVerticalBar:"∤",nparallel:"∦",npar:"∦",nparsl:"⫽⃥",npart:"∂̸",npolint:"⨔",npr:"⊀",nprcue:"⋠",nprec:"⊀",npreceq:"⪯̸",npre:"⪯̸",nrarrc:"⤳̸",nrarr:"↛",nrArr:"⇏",nrarrw:"↝̸",nrightarrow:"↛",nRightarrow:"⇏",nrtri:"⋫",nrtrie:"⋭",nsc:"⊁",nsccue:"⋡",nsce:"⪰̸",Nscr:"𝒩",nscr:"𝓃",nshortmid:"∤",nshortparallel:"∦",nsim:"≁",nsime:"≄",nsimeq:"≄",nsmid:"∤",nspar:"∦",nsqsube:"⋢",nsqsupe:"⋣",nsub:"⊄",nsubE:"⫅̸",nsube:"⊈",nsubset:"⊂⃒",nsubseteq:"⊈",nsubseteqq:"⫅̸",nsucc:"⊁",nsucceq:"⪰̸",nsup:"⊅",nsupE:"⫆̸",nsupe:"⊉",nsupset:"⊃⃒",nsupseteq:"⊉",nsupseteqq:"⫆̸",ntgl:"≹",Ntilde:"Ñ",ntilde:"ñ",ntlg:"≸",ntriangleleft:"⋪",ntrianglelefteq:"⋬",ntriangleright:"⋫",ntrianglerighteq:"⋭",Nu:"Ν",nu:"ν",num:"#",numero:"№",numsp:" ",nvap:"≍⃒",nvdash:"⊬",nvDash:"⊭",nVdash:"⊮",nVDash:"⊯",nvge:"≥⃒",nvgt:">⃒",nvHarr:"⤄",nvinfin:"⧞",nvlArr:"⤂",nvle:"≤⃒",nvlt:"<⃒",nvltrie:"⊴⃒",nvrArr:"⤃",nvrtrie:"⊵⃒",nvsim:"∼⃒",nwarhk:"⤣",nwarr:"↖",nwArr:"⇖",nwarrow:"↖",nwnear:"⤧",Oacute:"Ó",oacute:"ó",oast:"⊛",Ocirc:"Ô",ocirc:"ô",ocir:"⊚",Ocy:"О",ocy:"о",odash:"⊝",Odblac:"Ő",odblac:"ő",odiv:"⨸",odot:"⊙",odsold:"⦼",OElig:"Œ",oelig:"œ",ofcir:"⦿",Ofr:"𝔒",ofr:"𝔬",ogon:"˛",Ograve:"Ò",ograve:"ò",ogt:"⧁",ohbar:"⦵",ohm:"Ω",oint:"∮",olarr:"↺",olcir:"⦾",olcross:"⦻",oline:"‾",olt:"⧀",Omacr:"Ō",omacr:"ō",Omega:"Ω",omega:"ω",Omicron:"Ο",omicron:"ο",omid:"⦶",ominus:"⊖",Oopf:"𝕆",oopf:"𝕠",opar:"⦷",OpenCurlyDoubleQuote:"“",OpenCurlyQuote:"‘",operp:"⦹",oplus:"⊕",orarr:"↻",Or:"⩔",or:"∨",ord:"⩝",order:"ℴ",orderof:"ℴ",ordf:"ª",ordm:"º",origof:"⊶",oror:"⩖",orslope:"⩗",orv:"⩛",oS:"Ⓢ",Oscr:"𝒪",oscr:"ℴ",Oslash:"Ø",oslash:"ø",osol:"⊘",Otilde:"Õ",otilde:"õ",otimesas:"⨶",Otimes:"⨷",otimes:"⊗",Ouml:"Ö",ouml:"ö",ovbar:"⌽",OverBar:"‾",OverBrace:"⏞",OverBracket:"⎴",OverParenthesis:"⏜",para:"¶",parallel:"∥",par:"∥",parsim:"⫳",parsl:"⫽",part:"∂",PartialD:"∂",Pcy:"П",pcy:"п",percnt:"%",period:".",permil:"‰",perp:"⊥",pertenk:"‱",Pfr:"𝔓",pfr:"𝔭",Phi:"Φ",phi:"φ",phiv:"ϕ",phmmat:"ℳ",phone:"☎",Pi:"Π",pi:"π",pitchfork:"⋔",piv:"ϖ",planck:"ℏ",planckh:"ℎ",plankv:"ℏ",plusacir:"⨣",plusb:"⊞",pluscir:"⨢",plus:"+",plusdo:"∔",plusdu:"⨥",pluse:"⩲",PlusMinus:"±",plusmn:"±",plussim:"⨦",plustwo:"⨧",pm:"±",Poincareplane:"ℌ",pointint:"⨕",popf:"𝕡",Popf:"ℙ",pound:"£",prap:"⪷",Pr:"⪻",pr:"≺",prcue:"≼",precapprox:"⪷",prec:"≺",preccurlyeq:"≼",Precedes:"≺",PrecedesEqual:"⪯",PrecedesSlantEqual:"≼",PrecedesTilde:"≾",preceq:"⪯",precnapprox:"⪹",precneqq:"⪵",precnsim:"⋨",pre:"⪯",prE:"⪳",precsim:"≾",prime:"′",Prime:"″",primes:"ℙ",prnap:"⪹",prnE:"⪵",prnsim:"⋨",prod:"∏",Product:"∏",profalar:"⌮",profline:"⌒",profsurf:"⌓",prop:"∝",Proportional:"∝",Proportion:"∷",propto:"∝",prsim:"≾",prurel:"⊰",Pscr:"𝒫",pscr:"𝓅",Psi:"Ψ",psi:"ψ",puncsp:" ",Qfr:"𝔔",qfr:"𝔮",qint:"⨌",qopf:"𝕢",Qopf:"ℚ",qprime:"⁗",Qscr:"𝒬",qscr:"𝓆",quaternions:"ℍ",quatint:"⨖",quest:"?",questeq:"≟",quot:'"',QUOT:'"',rAarr:"⇛",race:"∽̱",Racute:"Ŕ",racute:"ŕ",radic:"√",raemptyv:"⦳",rang:"⟩",Rang:"⟫",rangd:"⦒",range:"⦥",rangle:"⟩",raquo:"»",rarrap:"⥵",rarrb:"⇥",rarrbfs:"⤠",rarrc:"⤳",rarr:"→",Rarr:"↠",rArr:"⇒",rarrfs:"⤞",rarrhk:"↪",rarrlp:"↬",rarrpl:"⥅",rarrsim:"⥴",Rarrtl:"⤖",rarrtl:"↣",rarrw:"↝",ratail:"⤚",rAtail:"⤜",ratio:"∶",rationals:"ℚ",rbarr:"⤍",rBarr:"⤏",RBarr:"⤐",rbbrk:"❳",rbrace:"}",rbrack:"]",rbrke:"⦌",rbrksld:"⦎",rbrkslu:"⦐",Rcaron:"Ř",rcaron:"ř",Rcedil:"Ŗ",rcedil:"ŗ",rceil:"⌉",rcub:"}",Rcy:"Р",rcy:"р",rdca:"⤷",rdldhar:"⥩",rdquo:"”",rdquor:"”",rdsh:"↳",real:"ℜ",realine:"ℛ",realpart:"ℜ",reals:"ℝ",Re:"ℜ",rect:"▭",reg:"®",REG:"®",ReverseElement:"∋",ReverseEquilibrium:"⇋",ReverseUpEquilibrium:"⥯",rfisht:"⥽",rfloor:"⌋",rfr:"𝔯",Rfr:"ℜ",rHar:"⥤",rhard:"⇁",rharu:"⇀",rharul:"⥬",Rho:"Ρ",rho:"ρ",rhov:"ϱ",RightAngleBracket:"⟩",RightArrowBar:"⇥",rightarrow:"→",RightArrow:"→",Rightarrow:"⇒",RightArrowLeftArrow:"⇄",rightarrowtail:"↣",RightCeiling:"⌉",RightDoubleBracket:"⟧",RightDownTeeVector:"⥝",RightDownVectorBar:"⥕",RightDownVector:"⇂",RightFloor:"⌋",rightharpoondown:"⇁",rightharpoonup:"⇀",rightleftarrows:"⇄",rightleftharpoons:"⇌",rightrightarrows:"⇉",rightsquigarrow:"↝",RightTeeArrow:"↦",RightTee:"⊢",RightTeeVector:"⥛",rightthreetimes:"⋌",RightTriangleBar:"⧐",RightTriangle:"⊳",RightTriangleEqual:"⊵",RightUpDownVector:"⥏",RightUpTeeVector:"⥜",RightUpVectorBar:"⥔",RightUpVector:"↾",RightVectorBar:"⥓",RightVector:"⇀",ring:"˚",risingdotseq:"≓",rlarr:"⇄",rlhar:"⇌",rlm:"‏",rmoustache:"⎱",rmoust:"⎱",rnmid:"⫮",roang:"⟭",roarr:"⇾",robrk:"⟧",ropar:"⦆",ropf:"𝕣",Ropf:"ℝ",roplus:"⨮",rotimes:"⨵",RoundImplies:"⥰",rpar:")",rpargt:"⦔",rppolint:"⨒",rrarr:"⇉",Rrightarrow:"⇛",rsaquo:"›",rscr:"𝓇",Rscr:"ℛ",rsh:"↱",Rsh:"↱",rsqb:"]",rsquo:"’",rsquor:"’",rthree:"⋌",rtimes:"⋊",rtri:"▹",rtrie:"⊵",rtrif:"▸",rtriltri:"⧎",RuleDelayed:"⧴",ruluhar:"⥨",rx:"℞",Sacute:"Ś",sacute:"ś",sbquo:"‚",scap:"⪸",Scaron:"Š",scaron:"š",Sc:"⪼",sc:"≻",sccue:"≽",sce:"⪰",scE:"⪴",Scedil:"Ş",scedil:"ş",Scirc:"Ŝ",scirc:"ŝ",scnap:"⪺",scnE:"⪶",scnsim:"⋩",scpolint:"⨓",scsim:"≿",Scy:"С",scy:"с",sdotb:"⊡",sdot:"⋅",sdote:"⩦",searhk:"⤥",searr:"↘",seArr:"⇘",searrow:"↘",sect:"§",semi:";",seswar:"⤩",setminus:"∖",setmn:"∖",sext:"✶",Sfr:"𝔖",sfr:"𝔰",sfrown:"⌢",sharp:"♯",SHCHcy:"Щ",shchcy:"щ",SHcy:"Ш",shcy:"ш",ShortDownArrow:"↓",ShortLeftArrow:"←",shortmid:"∣",shortparallel:"∥",ShortRightArrow:"→",ShortUpArrow:"↑",shy:"­",Sigma:"Σ",sigma:"σ",sigmaf:"ς",sigmav:"ς",sim:"∼",simdot:"⩪",sime:"≃",simeq:"≃",simg:"⪞",simgE:"⪠",siml:"⪝",simlE:"⪟",simne:"≆",simplus:"⨤",simrarr:"⥲",slarr:"←",SmallCircle:"∘",smallsetminus:"∖",smashp:"⨳",smeparsl:"⧤",smid:"∣",smile:"⌣",smt:"⪪",smte:"⪬",smtes:"⪬︀",SOFTcy:"Ь",softcy:"ь",solbar:"⌿",solb:"⧄",sol:"/",Sopf:"𝕊",sopf:"𝕤",spades:"♠",spadesuit:"♠",spar:"∥",sqcap:"⊓",sqcaps:"⊓︀",sqcup:"⊔",sqcups:"⊔︀",Sqrt:"√",sqsub:"⊏",sqsube:"⊑",sqsubset:"⊏",sqsubseteq:"⊑",sqsup:"⊐",sqsupe:"⊒",sqsupset:"⊐",sqsupseteq:"⊒",square:"□",Square:"□",SquareIntersection:"⊓",SquareSubset:"⊏",SquareSubsetEqual:"⊑",SquareSuperset:"⊐",SquareSupersetEqual:"⊒",SquareUnion:"⊔",squarf:"▪",squ:"□",squf:"▪",srarr:"→",Sscr:"𝒮",sscr:"𝓈",ssetmn:"∖",ssmile:"⌣",sstarf:"⋆",Star:"⋆",star:"☆",starf:"★",straightepsilon:"ϵ",straightphi:"ϕ",strns:"¯",sub:"⊂",Sub:"⋐",subdot:"⪽",subE:"⫅",sube:"⊆",subedot:"⫃",submult:"⫁",subnE:"⫋",subne:"⊊",subplus:"⪿",subrarr:"⥹",subset:"⊂",Subset:"⋐",subseteq:"⊆",subseteqq:"⫅",SubsetEqual:"⊆",subsetneq:"⊊",subsetneqq:"⫋",subsim:"⫇",subsub:"⫕",subsup:"⫓",succapprox:"⪸",succ:"≻",succcurlyeq:"≽",Succeeds:"≻",SucceedsEqual:"⪰",SucceedsSlantEqual:"≽",SucceedsTilde:"≿",succeq:"⪰",succnapprox:"⪺",succneqq:"⪶",succnsim:"⋩",succsim:"≿",SuchThat:"∋",sum:"∑",Sum:"∑",sung:"♪",sup1:"¹",sup2:"²",sup3:"³",sup:"⊃",Sup:"⋑",supdot:"⪾",supdsub:"⫘",supE:"⫆",supe:"⊇",supedot:"⫄",Superset:"⊃",SupersetEqual:"⊇",suphsol:"⟉",suphsub:"⫗",suplarr:"⥻",supmult:"⫂",supnE:"⫌",supne:"⊋",supplus:"⫀",supset:"⊃",Supset:"⋑",supseteq:"⊇",supseteqq:"⫆",supsetneq:"⊋",supsetneqq:"⫌",supsim:"⫈",supsub:"⫔",supsup:"⫖",swarhk:"⤦",swarr:"↙",swArr:"⇙",swarrow:"↙",swnwar:"⤪",szlig:"ß",Tab:" ",target:"⌖",Tau:"Τ",tau:"τ",tbrk:"⎴",Tcaron:"Ť",tcaron:"ť",Tcedil:"Ţ",tcedil:"ţ",Tcy:"Т",tcy:"т",tdot:"⃛",telrec:"⌕",Tfr:"𝔗",tfr:"𝔱",there4:"∴",therefore:"∴",Therefore:"∴",Theta:"Θ",theta:"θ",thetasym:"ϑ",thetav:"ϑ",thickapprox:"≈",thicksim:"∼",ThickSpace:"  ",ThinSpace:" ",thinsp:" ",thkap:"≈",thksim:"∼",THORN:"Þ",thorn:"þ",tilde:"˜",Tilde:"∼",TildeEqual:"≃",TildeFullEqual:"≅",TildeTilde:"≈",timesbar:"⨱",timesb:"⊠",times:"×",timesd:"⨰",tint:"∭",toea:"⤨",topbot:"⌶",topcir:"⫱",top:"⊤",Topf:"𝕋",topf:"𝕥",topfork:"⫚",tosa:"⤩",tprime:"‴",trade:"™",TRADE:"™",triangle:"▵",triangledown:"▿",triangleleft:"◃",trianglelefteq:"⊴",triangleq:"≜",triangleright:"▹",trianglerighteq:"⊵",tridot:"◬",trie:"≜",triminus:"⨺",TripleDot:"⃛",triplus:"⨹",trisb:"⧍",tritime:"⨻",trpezium:"⏢",Tscr:"𝒯",tscr:"𝓉",TScy:"Ц",tscy:"ц",TSHcy:"Ћ",tshcy:"ћ",Tstrok:"Ŧ",tstrok:"ŧ",twixt:"≬",twoheadleftarrow:"↞",twoheadrightarrow:"↠",Uacute:"Ú",uacute:"ú",uarr:"↑",Uarr:"↟",uArr:"⇑",Uarrocir:"⥉",Ubrcy:"Ў",ubrcy:"ў",Ubreve:"Ŭ",ubreve:"ŭ",Ucirc:"Û",ucirc:"û",Ucy:"У",ucy:"у",udarr:"⇅",Udblac:"Ű",udblac:"ű",udhar:"⥮",ufisht:"⥾",Ufr:"𝔘",ufr:"𝔲",Ugrave:"Ù",ugrave:"ù",uHar:"⥣",uharl:"↿",uharr:"↾",uhblk:"▀",ulcorn:"⌜",ulcorner:"⌜",ulcrop:"⌏",ultri:"◸",Umacr:"Ū",umacr:"ū",uml:"¨",UnderBar:"_",UnderBrace:"⏟",UnderBracket:"⎵",UnderParenthesis:"⏝",Union:"⋃",UnionPlus:"⊎",Uogon:"Ų",uogon:"ų",Uopf:"𝕌",uopf:"𝕦",UpArrowBar:"⤒",uparrow:"↑",UpArrow:"↑",Uparrow:"⇑",UpArrowDownArrow:"⇅",updownarrow:"↕",UpDownArrow:"↕",Updownarrow:"⇕",UpEquilibrium:"⥮",upharpoonleft:"↿",upharpoonright:"↾",uplus:"⊎",UpperLeftArrow:"↖",UpperRightArrow:"↗",upsi:"υ",Upsi:"ϒ",upsih:"ϒ",Upsilon:"Υ",upsilon:"υ",UpTeeArrow:"↥",UpTee:"⊥",upuparrows:"⇈",urcorn:"⌝",urcorner:"⌝",urcrop:"⌎",Uring:"Ů",uring:"ů",urtri:"◹",Uscr:"𝒰",uscr:"𝓊",utdot:"⋰",Utilde:"Ũ",utilde:"ũ",utri:"▵",utrif:"▴",uuarr:"⇈",Uuml:"Ü",uuml:"ü",uwangle:"⦧",vangrt:"⦜",varepsilon:"ϵ",varkappa:"ϰ",varnothing:"∅",varphi:"ϕ",varpi:"ϖ",varpropto:"∝",varr:"↕",vArr:"⇕",varrho:"ϱ",varsigma:"ς",varsubsetneq:"⊊︀",varsubsetneqq:"⫋︀",varsupsetneq:"⊋︀",varsupsetneqq:"⫌︀",vartheta:"ϑ",vartriangleleft:"⊲",vartriangleright:"⊳",vBar:"⫨",Vbar:"⫫",vBarv:"⫩",Vcy:"В",vcy:"в",vdash:"⊢",vDash:"⊨",Vdash:"⊩",VDash:"⊫",Vdashl:"⫦",veebar:"⊻",vee:"∨",Vee:"⋁",veeeq:"≚",vellip:"⋮",verbar:"|",Verbar:"‖",vert:"|",Vert:"‖",VerticalBar:"∣",VerticalLine:"|",VerticalSeparator:"❘",VerticalTilde:"≀",VeryThinSpace:" ",Vfr:"𝔙",vfr:"𝔳",vltri:"⊲",vnsub:"⊂⃒",vnsup:"⊃⃒",Vopf:"𝕍",vopf:"𝕧",vprop:"∝",vrtri:"⊳",Vscr:"𝒱",vscr:"𝓋",vsubnE:"⫋︀",vsubne:"⊊︀",vsupnE:"⫌︀",vsupne:"⊋︀",Vvdash:"⊪",vzigzag:"⦚",Wcirc:"Ŵ",wcirc:"ŵ",wedbar:"⩟",wedge:"∧",Wedge:"⋀",wedgeq:"≙",weierp:"℘",Wfr:"𝔚",wfr:"𝔴",Wopf:"𝕎",wopf:"𝕨",wp:"℘",wr:"≀",wreath:"≀",Wscr:"𝒲",wscr:"𝓌",xcap:"⋂",xcirc:"◯",xcup:"⋃",xdtri:"▽",Xfr:"𝔛",xfr:"𝔵",xharr:"⟷",xhArr:"⟺",Xi:"Ξ",xi:"ξ",xlarr:"⟵",xlArr:"⟸",xmap:"⟼",xnis:"⋻",xodot:"⨀",Xopf:"𝕏",xopf:"𝕩",xoplus:"⨁",xotime:"⨂",xrarr:"⟶",xrArr:"⟹",Xscr:"𝒳",xscr:"𝓍",xsqcup:"⨆",xuplus:"⨄",xutri:"△",xvee:"⋁",xwedge:"⋀",Yacute:"Ý",yacute:"ý",YAcy:"Я",yacy:"я",Ycirc:"Ŷ",ycirc:"ŷ",Ycy:"Ы",ycy:"ы",yen:"¥",Yfr:"𝔜",yfr:"𝔶",YIcy:"Ї",yicy:"ї",Yopf:"𝕐",yopf:"𝕪",Yscr:"𝒴",yscr:"𝓎",YUcy:"Ю",yucy:"ю",yuml:"ÿ",Yuml:"Ÿ",Zacute:"Ź",zacute:"ź",Zcaron:"Ž",zcaron:"ž",Zcy:"З",zcy:"з",Zdot:"Ż",zdot:"ż",zeetrf:"ℨ",ZeroWidthSpace:"​",Zeta:"Ζ",zeta:"ζ",zfr:"𝔷",Zfr:"ℨ",ZHcy:"Ж",zhcy:"ж",zigrarr:"⇝",zopf:"𝕫",Zopf:"ℤ",Zscr:"𝒵",zscr:"𝓏",zwj:"‍",zwnj:"‌"},p={Aacute:"Á",aacute:"á",Acirc:"Â",acirc:"â",acute:"´",AElig:"Æ",aelig:"æ",Agrave:"À",agrave:"à",amp:"&",AMP:"&",Aring:"Å",aring:"å",Atilde:"Ã",atilde:"ã",Auml:"Ä",auml:"ä",brvbar:"¦",Ccedil:"Ç",ccedil:"ç",cedil:"¸",cent:"¢",copy:"©",COPY:"©",curren:"¤",deg:"°",divide:"÷",Eacute:"É",eacute:"é",Ecirc:"Ê",ecirc:"ê",Egrave:"È",egrave:"è",ETH:"Ð",eth:"ð",Euml:"Ë",euml:"ë",frac12:"½",frac14:"¼",frac34:"¾",gt:">",GT:">",Iacute:"Í",iacute:"í",Icirc:"Î",icirc:"î",iexcl:"¡",Igrave:"Ì",igrave:"ì",iquest:"¿",Iuml:"Ï",iuml:"ï",laquo:"«",lt:"<",LT:"<",macr:"¯",micro:"µ",middot:"·",nbsp:" ",not:"¬",Ntilde:"Ñ",ntilde:"ñ",Oacute:"Ó",oacute:"ó",Ocirc:"Ô",ocirc:"ô",Ograve:"Ò",ograve:"ò",ordf:"ª",ordm:"º",Oslash:"Ø",oslash:"ø",Otilde:"Õ",otilde:"õ",Ouml:"Ö",ouml:"ö",para:"¶",plusmn:"±",pound:"£",quot:'"',QUOT:'"',raquo:"»",reg:"®",REG:"®",sect:"§",shy:"­",sup1:"¹",sup2:"²",sup3:"³",szlig:"ß",THORN:"Þ",thorn:"þ",times:"×",Uacute:"Ú",uacute:"ú",Ucirc:"Û",ucirc:"û",Ugrave:"Ù",ugrave:"ù",uml:"¨",Uuml:"Ü",uuml:"ü",Yacute:"Ý",yacute:"ý",yen:"¥",yuml:"ÿ"},q={0:"�",128:"€",130:"‚",131:"ƒ",132:"„",133:"…",134:"†",135:"‡",136:"ˆ",137:"‰",138:"Š",139:"‹",140:"Œ",142:"Ž",145:"‘",146:"’",147:"“",148:"”",149:"•",150:"–",151:"—",152:"˜",153:"™",154:"š",155:"›",156:"œ",158:"ž",159:"Ÿ"},r=[1,2,3,4,5,6,7,8,11,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,64976,64977,64978,64979,64980,64981,64982,64983,64984,64985,64986,64987,64988,64989,64990,64991,64992,64993,64994,64995,64996,64997,64998,64999,65e3,65001,65002,65003,65004,65005,65006,65007,65534,65535,131070,131071,196606,196607,262142,262143,327678,327679,393214,393215,458750,458751,524286,524287,589822,589823,655358,655359,720894,720895,786430,786431,851966,851967,917502,917503,983038,983039,1048574,1048575,1114110,1114111],s=String.fromCharCode,t={},u=t.hasOwnProperty,v=function(a,b){return u.call(a,b) },w=function(a,b){for(var c=-1,d=a.length;++c<d;)if(a[c]==b)return!0;return!1},x=function(a,b){if(!a)return b;var c,d={};for(c in b)d[c]=v(a,c)?a[c]:b[c];return d},y=function(a,b){var c="";return a>=55296&&57343>=a||a>1114111?(b&&A("character reference outside the permissible Unicode range"),"�"):v(q,a)?(b&&A("disallowed character reference"),q[a]):(b&&w(r,a)&&A("disallowed character reference"),a>65535&&(a-=65536,c+=s(a>>>10&1023|55296),a=56320|1023&a),c+=s(a))},z=function(a){return"&#x"+a.charCodeAt(0).toString(16).toUpperCase()+";"},A=function(a){throw Error("Parse error: "+a)},B=function(a,b){b=x(b,B.options);var c=b.strict;c&&m.test(a)&&A("forbidden code point");var d=b.encodeEverything,k=b.useNamedReferences,l=b.allowUnsafeSymbols;return d?(a=a.replace(f,function(a){return k&&v(i,a)?"&"+i[a]+";":z(a)}),k&&(a=a.replace(/&gt;\u20D2/g,"&nvgt;").replace(/&lt;\u20D2/g,"&nvlt;").replace(/&#x66;&#x6A;/g,"&fjlig;")),k&&(a=a.replace(h,function(a){return"&"+i[a]+";"}))):k?(l||(a=a.replace(j,function(a){return"&"+i[a]+";"})),a=a.replace(/&gt;\u20D2/g,"&nvgt;").replace(/&lt;\u20D2/g,"&nvlt;"),a=a.replace(h,function(a){return"&"+i[a]+";"})):l||(a=a.replace(j,z)),a.replace(e,function(a){var b=a.charCodeAt(0),c=a.charCodeAt(1),d=1024*(b-55296)+c-56320+65536;return"&#x"+d.toString(16).toUpperCase()+";"}).replace(g,z)};B.options={allowUnsafeSymbols:!1,encodeEverything:!1,strict:!1,useNamedReferences:!1};var C=function(a,b){b=x(b,C.options);var c=b.strict;return c&&l.test(a)&&A("malformed character reference"),a.replace(n,function(a,d,e,f,g,h,i,j){var k,l,m,n,q;return d?(k=d,l=e,c&&!l&&A("character reference was not terminated by a semicolon"),y(k,c)):f?(m=f,l=g,c&&!l&&A("character reference was not terminated by a semicolon"),k=parseInt(m,16),y(k,c)):h?(n=h,v(o,n)?o[n]:(c&&A("named character reference was not terminated by a semicolon"),a)):(n=i,q=j,q&&b.isAttributeValue?(c&&"="==q&&A("`&` did not start a character reference"),a):(c&&A("named character reference was not terminated by a semicolon"),p[n]+(q||"")))})};C.options={isAttributeValue:!1,strict:!1};var D=function(a){return a.replace(j,function(a){return k[a]})},E={version:"0.5.0",encode:B,decode:C,escape:D,unescape:C};if("function"==typeof define&&"object"==typeof define.amd&&define.amd)define(function(){return E});else if(b&&!b.nodeType)if(c)c.exports=E;else for(var F in E)v(E,F)&&(b[F]=E[F]);else a.he=E}(this),!function(a){function b(a){var b=a.length,d=c.type(a);return"function"===d||c.isWindow(a)?!1:1===a.nodeType&&b?!0:"array"===d||0===b||"number"==typeof b&&b>0&&b-1 in a}if(!a.jQuery){var c=function(a,b){return new c.fn.init(a,b)};c.isWindow=function(a){return null!=a&&a==a.window},c.type=function(a){return null==a?a+"":"object"==typeof a||"function"==typeof a?e[g.call(a)]||"object":typeof a},c.isArray=Array.isArray||function(a){return"array"===c.type(a)},c.isPlainObject=function(a){var b;if(!a||"object"!==c.type(a)||a.nodeType||c.isWindow(a))return!1;try{if(a.constructor&&!f.call(a,"constructor")&&!f.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(d){return!1}for(b in a);return void 0===b||f.call(a,b)},c.each=function(a,c,d){var e,f=0,g=a.length,h=b(a);if(d){if(h)for(;g>f&&(e=c.apply(a[f],d),e!==!1);f++);else for(f in a)if(e=c.apply(a[f],d),e===!1)break}else if(h)for(;g>f&&(e=c.call(a[f],f,a[f]),e!==!1);f++);else for(f in a)if(e=c.call(a[f],f,a[f]),e===!1)break;return a},c.data=function(a,b,e){if(void 0===e){var f=a[c.expando],g=f&&d[f];if(void 0===b)return g;if(g&&b in g)return g[b]}else if(void 0!==b){var f=a[c.expando]||(a[c.expando]=++c.uuid);return d[f]=d[f]||{},d[f][b]=e,e}},c.removeData=function(a,b){var e=a[c.expando],f=e&&d[e];f&&c.each(b,function(a,b){delete f[b]})},c.extend=function(){var a,b,d,e,f,g,h=arguments[0]||{},i=1,j=arguments.length,k=!1;for("boolean"==typeof h&&(k=h,h=arguments[i]||{},i++),"object"!=typeof h&&"function"!==c.type(h)&&(h={}),i===j&&(h=this,i--);j>i;i++)if(null!=(f=arguments[i]))for(e in f)a=h[e],d=f[e],h!==d&&(k&&d&&(c.isPlainObject(d)||(b=c.isArray(d)))?(b?(b=!1,g=a&&c.isArray(a)?a:[]):g=a&&c.isPlainObject(a)?a:{},h[e]=c.extend(k,g,d)):void 0!==d&&(h[e]=d));return h},c.queue=function(a,d,e){function f(a,c){var d=c||[];return null!=a&&(b(Object(a))?!function(a,b){for(var c=+b.length,d=0,e=a.length;c>d;)a[e++]=b[d++];if(c!==c)for(;void 0!==b[d];)a[e++]=b[d++];return a.length=e,a}(d,"string"==typeof a?[a]:a):[].push.call(d,a)),d}if(a){d=(d||"fx")+"queue";var g=c.data(a,d);return e?(!g||c.isArray(e)?g=c.data(a,d,f(e)):g.push(e),g):g||[]}},c.dequeue=function(a,b){c.each(a.nodeType?[a]:a,function(a,d){b=b||"fx";var e=c.queue(d,b),f=e.shift();"inprogress"===f&&(f=e.shift()),f&&("fx"===b&&e.unshift("inprogress"),f.call(d,function(){c.dequeue(d,b)}))})},c.fn=c.prototype={init:function(a){if(a.nodeType)return this[0]=a,this;throw new Error("Not a DOM node.")},offset:function(){var b=this[0].getBoundingClientRect?this[0].getBoundingClientRect():{top:0,left:0};return{top:b.top+(a.pageYOffset||document.scrollTop||0)-(document.clientTop||0),left:b.left+(a.pageXOffset||document.scrollLeft||0)-(document.clientLeft||0)}},position:function(){function a(){for(var a=this.offsetParent||document;a&&"html"===!a.nodeType.toLowerCase&&"static"===a.style.position;)a=a.offsetParent;return a||document}var b=this[0],a=a.apply(b),d=this.offset(),e=/^(?:body|html)$/i.test(a.nodeName)?{top:0,left:0}:c(a).offset();return d.top-=parseFloat(b.style.marginTop)||0,d.left-=parseFloat(b.style.marginLeft)||0,a.style&&(e.top+=parseFloat(a.style.borderTopWidth)||0,e.left+=parseFloat(a.style.borderLeftWidth)||0),{top:d.top-e.top,left:d.left-e.left}}};var d={};c.expando="velocity"+(new Date).getTime(),c.uuid=0;for(var e={},f=e.hasOwnProperty,g=e.toString,h="Boolean Number String Function Array Date RegExp Object Error".split(" "),i=0;i<h.length;i++)e["[object "+h[i]+"]"]=h[i].toLowerCase();c.fn.init.prototype=c.fn,a.Velocity={Utilities:c}}}(window),function(a){"object"==typeof module&&"object"==typeof module.exports?module.exports=a():"function"==typeof define&&define.amd?define(a):a()}(function(){return function(a,b,c,d){function e(a){for(var b=-1,c=a?a.length:0,d=[];++b<c;){var e=a[b];e&&d.push(e)}return d}function f(a){return p.isWrapped(a)?a=[].slice.call(a):p.isNode(a)&&(a=[a]),a}function g(a){var b=m.data(a,"velocity");return null===b?d:b}function h(a){return function(b){return Math.round(b*a)*(1/a)}}function i(a,c,d,e){function f(a,b){return 1-3*b+3*a}function g(a,b){return 3*b-6*a}function h(a){return 3*a}function i(a,b,c){return((f(b,c)*a+g(b,c))*a+h(b))*a}function j(a,b,c){return 3*f(b,c)*a*a+2*g(b,c)*a+h(b)}function k(b,c){for(var e=0;p>e;++e){var f=j(c,a,d);if(0===f)return c;var g=i(c,a,d)-b;c-=g/f}return c}function l(){for(var b=0;t>b;++b)x[b]=i(b*u,a,d)}function m(b,c,e){var f,g,h=0;do g=c+(e-c)/2,f=i(g,a,d)-b,f>0?e=g:c=g;while(Math.abs(f)>r&&++h<s);return g}function n(b){for(var c=0,e=1,f=t-1;e!=f&&x[e]<=b;++e)c+=u;--e;var g=(b-x[e])/(x[e+1]-x[e]),h=c+g*u,i=j(h,a,d);return i>=q?k(b,h):0==i?h:m(b,c,c+u)}function o(){y=!0,(a!=c||d!=e)&&l()}var p=4,q=.001,r=1e-7,s=10,t=11,u=1/(t-1),v="Float32Array"in b;if(4!==arguments.length)return!1;for(var w=0;4>w;++w)if("number"!=typeof arguments[w]||isNaN(arguments[w])||!isFinite(arguments[w]))return!1;a=Math.min(a,1),d=Math.min(d,1),a=Math.max(a,0),d=Math.max(d,0);var x=v?new Float32Array(t):new Array(t),y=!1,z=function(b){return y||o(),a===c&&d===e?b:0===b?0:1===b?1:i(n(b),c,e)};z.getControlPoints=function(){return[{x:a,y:c},{x:d,y:e}]};var A="generateBezier("+[a,c,d,e]+")";return z.toString=function(){return A},z}function j(a,b){var c=a;return p.isString(a)?t.Easings[a]||(c=!1):c=p.isArray(a)&&1===a.length?h.apply(null,a):p.isArray(a)&&2===a.length?u.apply(null,a.concat([b])):p.isArray(a)&&4===a.length?i.apply(null,a):!1,c===!1&&(c=t.Easings[t.defaults.easing]?t.defaults.easing:s),c}function k(a){if(a)for(var b=(new Date).getTime(),c=0,e=t.State.calls.length;e>c;c++)if(t.State.calls[c]){var f=t.State.calls[c],h=f[0],i=f[2],j=f[3],n=!!j;j||(j=t.State.calls[c][3]=b-16);for(var o=Math.min((b-j)/i.duration,1),q=0,r=h.length;r>q;q++){var s=h[q],u=s.element;if(g(u)){var w=!1;if(i.display!==d&&null!==i.display&&"none"!==i.display){if("flex"===i.display){var y=["-webkit-box","-moz-box","-ms-flexbox","-webkit-flex"];m.each(y,function(a,b){v.setPropertyValue(u,"display",b)})}v.setPropertyValue(u,"display",i.display)}i.visibility!==d&&"hidden"!==i.visibility&&v.setPropertyValue(u,"visibility",i.visibility);for(var z in s)if("element"!==z){var A,B=s[z],C=p.isString(B.easing)?t.Easings[B.easing]:B.easing;if(1===o)A=B.endValue;else if(A=B.startValue+(B.endValue-B.startValue)*C(o),!n&&A===B.currentValue)continue;if(B.currentValue=A,v.Hooks.registered[z]){var D=v.Hooks.getRoot(z),E=g(u).rootPropertyValueCache[D];E&&(B.rootPropertyValue=E)}var F=v.setPropertyValue(u,z,B.currentValue+(0===parseFloat(A)?"":B.unitType),B.rootPropertyValue,B.scrollData);v.Hooks.registered[z]&&(g(u).rootPropertyValueCache[D]=v.Normalizations.registered[D]?v.Normalizations.registered[D]("extract",null,F[1]):F[1]),"transform"===F[0]&&(w=!0)}i.mobileHA&&g(u).transformCache.translate3d===d&&(g(u).transformCache.translate3d="(0px, 0px, 0px)",w=!0),w&&v.flushTransformCache(u)}}i.display!==d&&"none"!==i.display&&(t.State.calls[c][2].display=!1),i.visibility!==d&&"hidden"!==i.visibility&&(t.State.calls[c][2].visibility=!1),i.progress&&i.progress.call(f[1],f[1],o,Math.max(0,j+i.duration-b),j),1===o&&l(c)}t.State.isTicking&&x(k)}function l(a,b){if(!t.State.calls[a])return!1;for(var c=t.State.calls[a][0],e=t.State.calls[a][1],f=t.State.calls[a][2],h=t.State.calls[a][4],i=!1,j=0,k=c.length;k>j;j++){var l=c[j].element;if(b||f.loop||("none"===f.display&&v.setPropertyValue(l,"display",f.display),"hidden"===f.visibility&&v.setPropertyValue(l,"visibility",f.visibility)),f.loop!==!0&&(m.queue(l)[1]===d||!/\.velocityQueueEntryFlag/i.test(m.queue(l)[1]))&&g(l)){g(l).isAnimating=!1,g(l).rootPropertyValueCache={};var n=!1;m.each(v.Lists.transforms3D,function(a,b){var c=/^scale/.test(b)?1:0,e=g(l).transformCache[b];g(l).transformCache[b]!==d&&new RegExp("^\\("+c+"[^.]").test(e)&&(n=!0,delete g(l).transformCache[b])}),f.mobileHA&&(n=!0,delete g(l).transformCache.translate3d),n&&v.flushTransformCache(l),v.Values.removeClass(l,"velocity-animating")}if(!b&&f.complete&&!f.loop&&j===k-1)try{f.complete.call(e,e)}catch(o){setTimeout(function(){throw o},1)}h&&f.loop!==!0&&h(e),f.loop!==!0||b||(m.each(g(l).tweensContainer,function(a,b){/^rotate/.test(a)&&360===parseFloat(b.endValue)&&(b.endValue=0,b.startValue=360)}),t(l,"reverse",{loop:!0,delay:f.delay})),f.queue!==!1&&m.dequeue(l,f.queue)}t.State.calls[a]=!1;for(var p=0,q=t.State.calls.length;q>p;p++)if(t.State.calls[p]!==!1){i=!0;break}i===!1&&(t.State.isTicking=!1,delete t.State.calls,t.State.calls=[])}var m,n=function(){if(c.documentMode)return c.documentMode;for(var a=7;a>4;a--){var b=c.createElement("div");if(b.innerHTML="<!--[if IE "+a+"]><span></span><![endif]-->",b.getElementsByTagName("span").length)return b=null,a}return d}(),o=function(){var a=0;return b.webkitRequestAnimationFrame||b.mozRequestAnimationFrame||function(b){var c,d=(new Date).getTime();return c=Math.max(0,16-(d-a)),a=d+c,setTimeout(function(){b(d+c)},c)}}(),p={isString:function(a){return"string"==typeof a},isArray:Array.isArray||function(a){return"[object Array]"===Object.prototype.toString.call(a)},isFunction:function(a){return"[object Function]"===Object.prototype.toString.call(a)},isNode:function(a){return a&&a.nodeType},isNodeList:function(a){return"object"==typeof a&&/^\[object (HTMLCollection|NodeList|Object)\]$/.test(Object.prototype.toString.call(a))&&a.length!==d&&(0===a.length||"object"==typeof a[0]&&a[0].nodeType>0)},isWrapped:function(a){return a&&(a.jquery||b.Zepto&&b.Zepto.zepto.isZ(a))},isSVG:function(a){return b.SVGElement&&a instanceof b.SVGElement},isEmptyObject:function(a){for(var b in a)return!1;return!0}},q=!1;if(a.fn&&a.fn.jquery?(m=a,q=!0):m=b.Velocity.Utilities,8>=n&&!q)throw new Error("Velocity: IE8 and below require jQuery to be loaded before Velocity.");if(7>=n)return void(jQuery.fn.velocity=jQuery.fn.animate);var r=400,s="swing",t={State:{isMobile:/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent),isAndroid:/Android/i.test(navigator.userAgent),isGingerbread:/Android 2\.3\.[3-7]/i.test(navigator.userAgent),isChrome:b.chrome,isFirefox:/Firefox/i.test(navigator.userAgent),prefixElement:c.createElement("div"),prefixMatches:{},scrollAnchor:null,scrollPropertyLeft:null,scrollPropertyTop:null,isTicking:!1,calls:[]},CSS:{},Utilities:m,Redirects:{},Easings:{},Promise:b.Promise,defaults:{queue:"",duration:r,easing:s,begin:d,complete:d,progress:d,display:d,visibility:d,loop:!1,delay:!1,mobileHA:!0,_cacheValues:!0},init:function(a){m.data(a,"velocity",{isSVG:p.isSVG(a),isAnimating:!1,computedStyle:null,tweensContainer:null,rootPropertyValueCache:{},transformCache:{}})},hook:null,mock:!1,version:{major:1,minor:1,patch:0},debug:!1};b.pageYOffset!==d?(t.State.scrollAnchor=b,t.State.scrollPropertyLeft="pageXOffset",t.State.scrollPropertyTop="pageYOffset"):(t.State.scrollAnchor=c.documentElement||c.body.parentNode||c.body,t.State.scrollPropertyLeft="scrollLeft",t.State.scrollPropertyTop="scrollTop");var u=function(){function a(a){return-a.tension*a.x-a.friction*a.v}function b(b,c,d){var e={x:b.x+d.dx*c,v:b.v+d.dv*c,tension:b.tension,friction:b.friction};return{dx:e.v,dv:a(e)}}function c(c,d){var e={dx:c.v,dv:a(c)},f=b(c,.5*d,e),g=b(c,.5*d,f),h=b(c,d,g),i=1/6*(e.dx+2*(f.dx+g.dx)+h.dx),j=1/6*(e.dv+2*(f.dv+g.dv)+h.dv);return c.x=c.x+i*d,c.v=c.v+j*d,c}return function d(a,b,e){var f,g,h,i={x:-1,v:0,tension:null,friction:null},j=[0],k=0,l=1e-4,m=.016;for(a=parseFloat(a)||500,b=parseFloat(b)||20,e=e||null,i.tension=a,i.friction=b,f=null!==e,f?(k=d(a,b),g=k/e*m):g=m;h=c(h||i,g),j.push(1+h.x),k+=16,Math.abs(h.x)>l&&Math.abs(h.v)>l;);return f?function(a){return j[a*(j.length-1)|0]}:k}}();t.Easings={linear:function(a){return a},swing:function(a){return.5-Math.cos(a*Math.PI)/2},spring:function(a){return 1-Math.cos(4.5*a*Math.PI)*Math.exp(6*-a)}},m.each([["ease",[.25,.1,.25,1]],["ease-in",[.42,0,1,1]],["ease-out",[0,0,.58,1]],["ease-in-out",[.42,0,.58,1]],["easeInSine",[.47,0,.745,.715]],["easeOutSine",[.39,.575,.565,1]],["easeInOutSine",[.445,.05,.55,.95]],["easeInQuad",[.55,.085,.68,.53]],["easeOutQuad",[.25,.46,.45,.94]],["easeInOutQuad",[.455,.03,.515,.955]],["easeInCubic",[.55,.055,.675,.19]],["easeOutCubic",[.215,.61,.355,1]],["easeInOutCubic",[.645,.045,.355,1]],["easeInQuart",[.895,.03,.685,.22]],["easeOutQuart",[.165,.84,.44,1]],["easeInOutQuart",[.77,0,.175,1]],["easeInQuint",[.755,.05,.855,.06]],["easeOutQuint",[.23,1,.32,1]],["easeInOutQuint",[.86,0,.07,1]],["easeInExpo",[.95,.05,.795,.035]],["easeOutExpo",[.19,1,.22,1]],["easeInOutExpo",[1,0,0,1]],["easeInCirc",[.6,.04,.98,.335]],["easeOutCirc",[.075,.82,.165,1]],["easeInOutCirc",[.785,.135,.15,.86]]],function(a,b){t.Easings[b[0]]=i.apply(null,b[1])});var v=t.CSS={RegEx:{isHex:/^#([A-f\d]{3}){1,2}$/i,valueUnwrap:/^[A-z]+\((.*)\)$/i,wrappedValueAlreadyExtracted:/[0-9.]+ [0-9.]+ [0-9.]+( [0-9.]+)?/,valueSplit:/([A-z]+\(.+\))|(([A-z0-9#-.]+?)(?=\s|$))/gi},Lists:{colors:["fill","stroke","stopColor","color","backgroundColor","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outlineColor"],transformsBase:["translateX","translateY","scale","scaleX","scaleY","skewX","skewY","rotateZ"],transforms3D:["transformPerspective","translateZ","scaleZ","rotateX","rotateY"]},Hooks:{templates:{textShadow:["Color X Y Blur","black 0px 0px 0px"],boxShadow:["Color X Y Blur Spread","black 0px 0px 0px 0px"],clip:["Top Right Bottom Left","0px 0px 0px 0px"],backgroundPosition:["X Y","0% 0%"],transformOrigin:["X Y Z","50% 50% 0px"],perspectiveOrigin:["X Y","50% 50%"]},registered:{},register:function(){for(var a=0;a<v.Lists.colors.length;a++){var b="color"===v.Lists.colors[a]?"0 0 0 1":"255 255 255 1";v.Hooks.templates[v.Lists.colors[a]]=["Red Green Blue Alpha",b]}var c,d,e;if(n)for(c in v.Hooks.templates){d=v.Hooks.templates[c],e=d[0].split(" ");var f=d[1].match(v.RegEx.valueSplit);"Color"===e[0]&&(e.push(e.shift()),f.push(f.shift()),v.Hooks.templates[c]=[e.join(" "),f.join(" ")])}for(c in v.Hooks.templates){d=v.Hooks.templates[c],e=d[0].split(" ");for(var a in e){var g=c+e[a],h=a;v.Hooks.registered[g]=[c,h]}}},getRoot:function(a){var b=v.Hooks.registered[a];return b?b[0]:a},cleanRootPropertyValue:function(a,b){return v.RegEx.valueUnwrap.test(b)&&(b=b.match(v.RegEx.valueUnwrap)[1]),v.Values.isCSSNullValue(b)&&(b=v.Hooks.templates[a][1]),b},extractValue:function(a,b){var c=v.Hooks.registered[a];if(c){var d=c[0],e=c[1];return b=v.Hooks.cleanRootPropertyValue(d,b),b.toString().match(v.RegEx.valueSplit)[e]}return b},injectValue:function(a,b,c){var d=v.Hooks.registered[a];if(d){var e,f,g=d[0],h=d[1];return c=v.Hooks.cleanRootPropertyValue(g,c),e=c.toString().match(v.RegEx.valueSplit),e[h]=b,f=e.join(" ")}return c}},Normalizations:{registered:{clip:function(a,b,c){switch(a){case"name":return"clip";case"extract":var d;return v.RegEx.wrappedValueAlreadyExtracted.test(c)?d=c:(d=c.toString().match(v.RegEx.valueUnwrap),d=d?d[1].replace(/,(\s+)?/g," "):c),d;case"inject":return"rect("+c+")"}},blur:function(a,b,c){switch(a){case"name":return"-webkit-filter";case"extract":var d=parseFloat(c);if(!d&&0!==d){var e=c.toString().match(/blur\(([0-9]+[A-z]+)\)/i);d=e?e[1]:0}return d;case"inject":return parseFloat(c)?"blur("+c+")":"none"}},opacity:function(a,b,c){if(8>=n)switch(a){case"name":return"filter";case"extract":var d=c.toString().match(/alpha\(opacity=(.*)\)/i);return c=d?d[1]/100:1;case"inject":return b.style.zoom=1,parseFloat(c)>=1?"":"alpha(opacity="+parseInt(100*parseFloat(c),10)+")"}else switch(a){case"name":return"opacity";case"extract":return c;case"inject":return c}}},register:function(){9>=n||t.State.isGingerbread||(v.Lists.transformsBase=v.Lists.transformsBase.concat(v.Lists.transforms3D));for(var a=0;a<v.Lists.transformsBase.length;a++)!function(){var b=v.Lists.transformsBase[a];v.Normalizations.registered[b]=function(a,c,e){switch(a){case"name":return"transform";case"extract":return g(c)===d||g(c).transformCache[b]===d?/^scale/i.test(b)?1:0:g(c).transformCache[b].replace(/[()]/g,"");case"inject":var f=!1;switch(b.substr(0,b.length-1)){case"translate":f=!/(%|px|em|rem|vw|vh|\d)$/i.test(e);break;case"scal":case"scale":t.State.isAndroid&&g(c).transformCache[b]===d&&1>e&&(e=1),f=!/(\d)$/i.test(e);break;case"skew":f=!/(deg|\d)$/i.test(e);break;case"rotate":f=!/(deg|\d)$/i.test(e)}return f||(g(c).transformCache[b]="("+e+")"),g(c).transformCache[b]}}}();for(var a=0;a<v.Lists.colors.length;a++)!function(){var b=v.Lists.colors[a];v.Normalizations.registered[b]=function(a,c,e){switch(a){case"name":return b;case"extract":var f;if(v.RegEx.wrappedValueAlreadyExtracted.test(e))f=e;else{var g,h={black:"rgb(0, 0, 0)",blue:"rgb(0, 0, 255)",gray:"rgb(128, 128, 128)",green:"rgb(0, 128, 0)",red:"rgb(255, 0, 0)",white:"rgb(255, 255, 255)"};/^[A-z]+$/i.test(e)?g=h[e]!==d?h[e]:h.black:v.RegEx.isHex.test(e)?g="rgb("+v.Values.hexToRgb(e).join(" ")+")":/^rgba?\(/i.test(e)||(g=h.black),f=(g||e).toString().match(v.RegEx.valueUnwrap)[1].replace(/,(\s+)?/g," ")}return 8>=n||3!==f.split(" ").length||(f+=" 1"),f;case"inject":return 8>=n?4===e.split(" ").length&&(e=e.split(/\s+/).slice(0,3).join(" ")):3===e.split(" ").length&&(e+=" 1"),(8>=n?"rgb":"rgba")+"("+e.replace(/\s+/g,",").replace(/\.(\d)+(?=,)/g,"")+")"}}}()}},Names:{camelCase:function(a){return a.replace(/-(\w)/g,function(a,b){return b.toUpperCase()})},SVGAttribute:function(a){var b="width|height|x|y|cx|cy|r|rx|ry|x1|x2|y1|y2";return(n||t.State.isAndroid&&!t.State.isChrome)&&(b+="|transform"),new RegExp("^("+b+")$","i").test(a)},prefixCheck:function(a){if(t.State.prefixMatches[a])return[t.State.prefixMatches[a],!0];for(var b=["","Webkit","Moz","ms","O"],c=0,d=b.length;d>c;c++){var e;if(e=0===c?a:b[c]+a.replace(/^\w/,function(a){return a.toUpperCase()}),p.isString(t.State.prefixElement.style[e]))return t.State.prefixMatches[a]=e,[e,!0]}return[a,!1]}},Values:{hexToRgb:function(a){var b,c=/^#?([a-f\d])([a-f\d])([a-f\d])$/i,d=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i;return a=a.replace(c,function(a,b,c,d){return b+b+c+c+d+d}),b=d.exec(a),b?[parseInt(b[1],16),parseInt(b[2],16),parseInt(b[3],16)]:[0,0,0]},isCSSNullValue:function(a){return 0==a||/^(none|auto|transparent|(rgba\(0, ?0, ?0, ?0\)))$/i.test(a)},getUnitType:function(a){return/^(rotate|skew)/i.test(a)?"deg":/(^(scale|scaleX|scaleY|scaleZ|alpha|flexGrow|flexHeight|zIndex|fontWeight)$)|((opacity|red|green|blue|alpha)$)/i.test(a)?"":"px"},getDisplayType:function(a){var b=a&&a.tagName.toString().toLowerCase();return/^(b|big|i|small|tt|abbr|acronym|cite|code|dfn|em|kbd|strong|samp|var|a|bdo|br|img|map|object|q|script|span|sub|sup|button|input|label|select|textarea)$/i.test(b)?"inline":/^(li)$/i.test(b)?"list-item":/^(tr)$/i.test(b)?"table-row":"block"},addClass:function(a,b){a.classList?a.classList.add(b):a.className+=(a.className.length?" ":"")+b},removeClass:function(a,b){a.classList?a.classList.remove(b):a.className=a.className.toString().replace(new RegExp("(^|\\s)"+b.split(" ").join("|")+"(\\s|$)","gi")," ")}},getPropertyValue:function(a,c,e,f){function h(a,c){function e(){j&&v.setPropertyValue(a,"display","none")}var i=0;if(8>=n)i=m.css(a,c);else{var j=!1;if(/^(width|height)$/.test(c)&&0===v.getPropertyValue(a,"display")&&(j=!0,v.setPropertyValue(a,"display",v.Values.getDisplayType(a))),!f){if("height"===c&&"border-box"!==v.getPropertyValue(a,"boxSizing").toString().toLowerCase()){var k=a.offsetHeight-(parseFloat(v.getPropertyValue(a,"borderTopWidth"))||0)-(parseFloat(v.getPropertyValue(a,"borderBottomWidth"))||0)-(parseFloat(v.getPropertyValue(a,"paddingTop"))||0)-(parseFloat(v.getPropertyValue(a,"paddingBottom"))||0);return e(),k}if("width"===c&&"border-box"!==v.getPropertyValue(a,"boxSizing").toString().toLowerCase()){var l=a.offsetWidth-(parseFloat(v.getPropertyValue(a,"borderLeftWidth"))||0)-(parseFloat(v.getPropertyValue(a,"borderRightWidth"))||0)-(parseFloat(v.getPropertyValue(a,"paddingLeft"))||0)-(parseFloat(v.getPropertyValue(a,"paddingRight"))||0);return e(),l}}var o;o=g(a)===d?b.getComputedStyle(a,null):g(a).computedStyle?g(a).computedStyle:g(a).computedStyle=b.getComputedStyle(a,null),(n||t.State.isFirefox)&&"borderColor"===c&&(c="borderTopColor"),i=9===n&&"filter"===c?o.getPropertyValue(c):o[c],(""===i||null===i)&&(i=a.style[c]),e()}if("auto"===i&&/^(top|right|bottom|left)$/i.test(c)){var p=h(a,"position");("fixed"===p||"absolute"===p&&/top|left/i.test(c))&&(i=m(a).position()[c]+"px")}return i}var i;if(v.Hooks.registered[c]){var j=c,k=v.Hooks.getRoot(j);e===d&&(e=v.getPropertyValue(a,v.Names.prefixCheck(k)[0])),v.Normalizations.registered[k]&&(e=v.Normalizations.registered[k]("extract",a,e)),i=v.Hooks.extractValue(j,e)}else if(v.Normalizations.registered[c]){var l,o;l=v.Normalizations.registered[c]("name",a),"transform"!==l&&(o=h(a,v.Names.prefixCheck(l)[0]),v.Values.isCSSNullValue(o)&&v.Hooks.templates[c]&&(o=v.Hooks.templates[c][1])),i=v.Normalizations.registered[c]("extract",a,o)}return/^[\d-]/.test(i)||(i=g(a)&&g(a).isSVG&&v.Names.SVGAttribute(c)?/^(height|width)$/i.test(c)?a.getBBox()[c]:a.getAttribute(c):h(a,v.Names.prefixCheck(c)[0])),v.Values.isCSSNullValue(i)&&(i=0),t.debug>=2&&console.log("Get "+c+": "+i),i},setPropertyValue:function(a,c,d,e,f){var h=c;if("scroll"===c)f.container?f.container["scroll"+f.direction]=d:"Left"===f.direction?b.scrollTo(d,f.alternateValue):b.scrollTo(f.alternateValue,d);else if(v.Normalizations.registered[c]&&"transform"===v.Normalizations.registered[c]("name",a))v.Normalizations.registered[c]("inject",a,d),h="transform",d=g(a).transformCache[c];else{if(v.Hooks.registered[c]){var i=c,j=v.Hooks.getRoot(c);e=e||v.getPropertyValue(a,j),d=v.Hooks.injectValue(i,d,e),c=j}if(v.Normalizations.registered[c]&&(d=v.Normalizations.registered[c]("inject",a,d),c=v.Normalizations.registered[c]("name",a)),h=v.Names.prefixCheck(c)[0],8>=n)try{a.style[h]=d}catch(k){t.debug&&console.log("Browser does not support ["+d+"] for ["+h+"]")}else g(a)&&g(a).isSVG&&v.Names.SVGAttribute(c)?a.setAttribute(c,d):a.style[h]=d;t.debug>=2&&console.log("Set "+c+" ("+h+"): "+d)}return[h,d]},flushTransformCache:function(a){function b(b){return parseFloat(v.getPropertyValue(a,b))}var c="";if((n||t.State.isAndroid&&!t.State.isChrome)&&g(a).isSVG){var d={translate:[b("translateX"),b("translateY")],skewX:[b("skewX")],skewY:[b("skewY")],scale:1!==b("scale")?[b("scale"),b("scale")]:[b("scaleX"),b("scaleY")],rotate:[b("rotateZ"),0,0]};m.each(g(a).transformCache,function(a){/^translate/i.test(a)?a="translate":/^scale/i.test(a)?a="scale":/^rotate/i.test(a)&&(a="rotate"),d[a]&&(c+=a+"("+d[a].join(" ")+") ",delete d[a])})}else{var e,f;m.each(g(a).transformCache,function(b){return e=g(a).transformCache[b],"transformPerspective"===b?(f=e,!0):(9===n&&"rotateZ"===b&&(b="rotate"),void(c+=b+e+" "))}),f&&(c="perspective"+f+" "+c)}v.setPropertyValue(a,"transform",c)}};v.Hooks.register(),v.Normalizations.register(),t.hook=function(a,b,c){var e=d;return a=f(a),m.each(a,function(a,f){if(g(f)===d&&t.init(f),c===d)e===d&&(e=t.CSS.getPropertyValue(f,b));else{var h=t.CSS.setPropertyValue(f,b,c);"transform"===h[0]&&t.CSS.flushTransformCache(f),e=h}}),e};var w=function(){function a(){return i?C.promise||null:n}function h(){function a(){function a(a,b){var c=d,e=d,f=d;return p.isArray(a)?(c=a[0],!p.isArray(a[1])&&/^[\d-]/.test(a[1])||p.isFunction(a[1])||v.RegEx.isHex.test(a[1])?f=a[1]:(p.isString(a[1])&&!v.RegEx.isHex.test(a[1])||p.isArray(a[1]))&&(e=b?a[1]:j(a[1],i.duration),a[2]!==d&&(f=a[2]))):c=a,b||(e=e||i.easing),p.isFunction(c)&&(c=c.call(h,z,y)),p.isFunction(f)&&(f=f.call(h,z,y)),[c||0,e,f]}function n(a,b){var c,d;return d=(b||"0").toString().toLowerCase().replace(/[%A-z]+$/,function(a){return c=a,""}),c||(c=v.Values.getUnitType(a)),[d,c]}function o(){var a={myParent:h.parentNode||c.body,position:v.getPropertyValue(h,"position"),fontSize:v.getPropertyValue(h,"fontSize")},d=a.position===J.lastPosition&&a.myParent===J.lastParent,e=a.fontSize===J.lastFontSize;J.lastParent=a.myParent,J.lastPosition=a.position,J.lastFontSize=a.fontSize;var f=100,i={};if(e&&d)i.emToPx=J.lastEmToPx,i.percentToPxWidth=J.lastPercentToPxWidth,i.percentToPxHeight=J.lastPercentToPxHeight;else{var j=g(h).isSVG?c.createElementNS("http://www.w3.org/2000/svg","rect"):c.createElement("div");t.init(j),a.myParent.appendChild(j),m.each(["overflow","overflowX","overflowY"],function(a,b){t.CSS.setPropertyValue(j,b,"hidden")}),t.CSS.setPropertyValue(j,"position",a.position),t.CSS.setPropertyValue(j,"fontSize",a.fontSize),t.CSS.setPropertyValue(j,"boxSizing","content-box"),m.each(["minWidth","maxWidth","width","minHeight","maxHeight","height"],function(a,b){t.CSS.setPropertyValue(j,b,f+"%")}),t.CSS.setPropertyValue(j,"paddingLeft",f+"em"),i.percentToPxWidth=J.lastPercentToPxWidth=(parseFloat(v.getPropertyValue(j,"width",null,!0))||1)/f,i.percentToPxHeight=J.lastPercentToPxHeight=(parseFloat(v.getPropertyValue(j,"height",null,!0))||1)/f,i.emToPx=J.lastEmToPx=(parseFloat(v.getPropertyValue(j,"paddingLeft"))||1)/f,a.myParent.removeChild(j)}return null===J.remToPx&&(J.remToPx=parseFloat(v.getPropertyValue(c.body,"fontSize"))||16),null===J.vwToPx&&(J.vwToPx=parseFloat(b.innerWidth)/100,J.vhToPx=parseFloat(b.innerHeight)/100),i.remToPx=J.remToPx,i.vwToPx=J.vwToPx,i.vhToPx=J.vhToPx,t.debug>=1&&console.log("Unit ratios: "+JSON.stringify(i),h),i}if(i.begin&&0===z)try{i.begin.call(q,q)}catch(r){setTimeout(function(){throw r},1)}if("scroll"===D){var w,x,A,B=/^x$/i.test(i.axis)?"Left":"Top",E=parseFloat(i.offset)||0;i.container?p.isWrapped(i.container)||p.isNode(i.container)?(i.container=i.container[0]||i.container,w=i.container["scroll"+B],A=w+m(h).position()[B.toLowerCase()]+E):i.container=null:(w=t.State.scrollAnchor[t.State["scrollProperty"+B]],x=t.State.scrollAnchor[t.State["scrollProperty"+("Left"===B?"Top":"Left")]],A=m(h).offset()[B.toLowerCase()]+E),l={scroll:{rootPropertyValue:!1,startValue:w,currentValue:w,endValue:A,unitType:"",easing:i.easing,scrollData:{container:i.container,direction:B,alternateValue:x}},element:h},t.debug&&console.log("tweensContainer (scroll): ",l.scroll,h)}else if("reverse"===D){if(!g(h).tweensContainer)return void m.dequeue(h,i.queue);"none"===g(h).opts.display&&(g(h).opts.display="auto"),"hidden"===g(h).opts.visibility&&(g(h).opts.visibility="visible"),g(h).opts.loop=!1,g(h).opts.begin=null,g(h).opts.complete=null,u.easing||delete i.easing,u.duration||delete i.duration,i=m.extend({},g(h).opts,i);var F=m.extend(!0,{},g(h).tweensContainer);for(var G in F)if("element"!==G){var H=F[G].startValue;F[G].startValue=F[G].currentValue=F[G].endValue,F[G].endValue=H,p.isEmptyObject(u)||(F[G].easing=i.easing),t.debug&&console.log("reverse tweensContainer ("+G+"): "+JSON.stringify(F[G]),h)}l=F}else if("start"===D){var F;g(h).tweensContainer&&g(h).isAnimating===!0&&(F=g(h).tweensContainer),m.each(s,function(b,c){if(RegExp("^"+v.Lists.colors.join("$|^")+"$").test(b)){var e=a(c,!0),f=e[0],g=e[1],h=e[2];if(v.RegEx.isHex.test(f)){for(var i=["Red","Green","Blue"],j=v.Values.hexToRgb(f),k=h?v.Values.hexToRgb(h):d,l=0;l<i.length;l++){var m=[j[l]];g&&m.push(g),k!==d&&m.push(k[l]),s[b+i[l]]=m}delete s[b]}}});for(var I in s){var L=a(s[I]),M=L[0],N=L[1],O=L[2];I=v.Names.camelCase(I);var P=v.Hooks.getRoot(I),Q=!1;if(g(h).isSVG||v.Names.prefixCheck(P)[1]!==!1||v.Normalizations.registered[P]!==d){(i.display!==d&&null!==i.display&&"none"!==i.display||i.visibility!==d&&"hidden"!==i.visibility)&&/opacity|filter/.test(I)&&!O&&0!==M&&(O=0),i._cacheValues&&F&&F[I]?(O===d&&(O=F[I].endValue+F[I].unitType),Q=g(h).rootPropertyValueCache[P]):v.Hooks.registered[I]?O===d?(Q=v.getPropertyValue(h,P),O=v.getPropertyValue(h,I,Q)):Q=v.Hooks.templates[P][1]:O===d&&(O=v.getPropertyValue(h,I));var R,S,T,U=!1;if(R=n(I,O),O=R[0],T=R[1],R=n(I,M),M=R[0].replace(/^([+-\/*])=/,function(a,b){return U=b,""}),S=R[1],O=parseFloat(O)||0,M=parseFloat(M)||0,"%"===S&&(/^(fontSize|lineHeight)$/.test(I)?(M/=100,S="em"):/^scale/.test(I)?(M/=100,S=""):/(Red|Green|Blue)$/i.test(I)&&(M=M/100*255,S="")),/[\/*]/.test(U))S=T;else if(T!==S&&0!==O)if(0===M)S=T;else{f=f||o();var V=/margin|padding|left|right|width|text|word|letter/i.test(I)||/X$/.test(I)||"x"===I?"x":"y";switch(T){case"%":O*="x"===V?f.percentToPxWidth:f.percentToPxHeight;break;case"px":break;default:O*=f[T+"ToPx"]}switch(S){case"%":O*=1/("x"===V?f.percentToPxWidth:f.percentToPxHeight);break;case"px":break;default:O*=1/f[S+"ToPx"]}}switch(U){case"+":M=O+M;break;case"-":M=O-M;break;case"*":M=O*M;break;case"/":M=O/M}l[I]={rootPropertyValue:Q,startValue:O,currentValue:O,endValue:M,unitType:S,easing:N},t.debug&&console.log("tweensContainer ("+I+"): "+JSON.stringify(l[I]),h)}else t.debug&&console.log("Skipping ["+P+"] due to a lack of browser support.")}l.element=h}l.element&&(v.Values.addClass(h,"velocity-animating"),K.push(l),""===i.queue&&(g(h).tweensContainer=l,g(h).opts=i),g(h).isAnimating=!0,z===y-1?(t.State.calls.length>1e4&&(t.State.calls=e(t.State.calls)),t.State.calls.push([K,q,i,null,C.resolver]),t.State.isTicking===!1&&(t.State.isTicking=!0,k())):z++)}var f,h=this,i=m.extend({},t.defaults,u),l={};switch(g(h)===d&&t.init(h),parseFloat(i.delay)&&i.queue!==!1&&m.queue(h,i.queue,function(a){t.velocityQueueEntryFlag=!0,g(h).delayTimer={setTimeout:setTimeout(a,parseFloat(i.delay)),next:a}}),i.duration.toString().toLowerCase()){case"fast":i.duration=200;break;case"normal":i.duration=r;break;case"slow":i.duration=600;break;default:i.duration=parseFloat(i.duration)||1}t.mock!==!1&&(t.mock===!0?i.duration=i.delay=1:(i.duration*=parseFloat(t.mock)||1,i.delay*=parseFloat(t.mock)||1)),i.easing=j(i.easing,i.duration),i.begin&&!p.isFunction(i.begin)&&(i.begin=null),i.progress&&!p.isFunction(i.progress)&&(i.progress=null),i.complete&&!p.isFunction(i.complete)&&(i.complete=null),i.display!==d&&null!==i.display&&(i.display=i.display.toString().toLowerCase(),"auto"===i.display&&(i.display=t.CSS.Values.getDisplayType(h))),i.visibility!==d&&null!==i.visibility&&(i.visibility=i.visibility.toString().toLowerCase()),i.mobileHA=i.mobileHA&&t.State.isMobile&&!t.State.isGingerbread,i.queue===!1?i.delay?setTimeout(a,i.delay):a():m.queue(h,i.queue,function(b,c){return c===!0?(C.promise&&C.resolver(q),!0):(t.velocityQueueEntryFlag=!0,void a(b)) }),""!==i.queue&&"fx"!==i.queue||"inprogress"===m.queue(h)[0]||m.dequeue(h)}var i,n,o,q,s,u,x=arguments[0]&&(m.isPlainObject(arguments[0].properties)&&!arguments[0].properties.names||p.isString(arguments[0].properties));if(p.isWrapped(this)?(i=!1,o=0,q=this,n=this):(i=!0,o=1,q=x?arguments[0].elements:arguments[0]),q=f(q)){x?(s=arguments[0].properties,u=arguments[0].options):(s=arguments[o],u=arguments[o+1]);var y=q.length,z=0;if("stop"!==s&&!m.isPlainObject(u)){var A=o+1;u={};for(var B=A;B<arguments.length;B++)p.isArray(arguments[B])||!/^(fast|normal|slow)$/i.test(arguments[B])&&!/^\d/.test(arguments[B])?p.isString(arguments[B])||p.isArray(arguments[B])?u.easing=arguments[B]:p.isFunction(arguments[B])&&(u.complete=arguments[B]):u.duration=arguments[B]}var C={promise:null,resolver:null,rejecter:null};i&&t.Promise&&(C.promise=new t.Promise(function(a,b){C.resolver=a,C.rejecter=b}));var D;switch(s){case"scroll":D="scroll";break;case"reverse":D="reverse";break;case"stop":m.each(q,function(a,b){g(b)&&g(b).delayTimer&&(clearTimeout(g(b).delayTimer.setTimeout),g(b).delayTimer.next&&g(b).delayTimer.next(),delete g(b).delayTimer)});var E=[];return m.each(t.State.calls,function(a,b){b&&m.each(b[1],function(c,e){var f=p.isString(u)?u:"";return u!==d&&b[2].queue!==f?!0:void m.each(q,function(b,c){c===e&&(u!==d&&(m.each(m.queue(c,f),function(a,b){p.isFunction(b)&&b(null,!0)}),m.queue(c,f,[])),g(c)&&""===f&&m.each(g(c).tweensContainer,function(a,b){b.endValue=b.currentValue}),E.push(a))})})}),m.each(E,function(a,b){l(b,!0)}),C.promise&&C.resolver(q),a();default:if(!m.isPlainObject(s)||p.isEmptyObject(s)){if(p.isString(s)&&t.Redirects[s]){var F=m.extend({},u),G=F.duration,H=F.delay||0;return F.backwards===!0&&(q=m.extend(!0,[],q).reverse()),m.each(q,function(a,b){parseFloat(F.stagger)?F.delay=H+parseFloat(F.stagger)*a:p.isFunction(F.stagger)&&(F.delay=H+F.stagger.call(b,a,y)),F.drag&&(F.duration=parseFloat(G)||(/^(callout|transition)/.test(s)?1e3:r),F.duration=Math.max(F.duration*(F.backwards?1-a/y:(a+1)/y),.75*F.duration,200)),t.Redirects[s].call(b,b,F||{},a,y,q,C.promise?C:d)}),a()}var I="Velocity: First argument ("+s+") was not a property map, a known action, or a registered redirect. Aborting.";return C.promise?C.rejecter(new Error(I)):console.log(I),a()}D="start"}var J={lastParent:null,lastPosition:null,lastFontSize:null,lastPercentToPxWidth:null,lastPercentToPxHeight:null,lastEmToPx:null,remToPx:null,vwToPx:null,vhToPx:null},K=[];m.each(q,function(a,b){p.isNode(b)&&h.call(b)});var L,F=m.extend({},t.defaults,u);if(F.loop=parseInt(F.loop),L=2*F.loop-1,F.loop)for(var M=0;L>M;M++){var N={delay:F.delay,progress:F.progress};M===L-1&&(N.display=F.display,N.visibility=F.visibility,N.complete=F.complete),w(q,"reverse",N)}return a()}};t=m.extend(w,t),t.animate=w;var x=b.requestAnimationFrame||o;return t.State.isMobile||c.hidden===d||c.addEventListener("visibilitychange",function(){c.hidden?(x=function(a){return setTimeout(function(){a(!0)},16)},k()):x=b.requestAnimationFrame||o}),a.Velocity=t,a!==b&&(a.fn.velocity=w,a.fn.velocity.defaults=t.defaults),m.each(["Down","Up"],function(a,b){t.Redirects["slide"+b]=function(a,c,e,f,g,h){var i=m.extend({},c),j=i.begin,k=i.complete,l={height:"",marginTop:"",marginBottom:"",paddingTop:"",paddingBottom:""},n={};i.display===d&&(i.display="Down"===b?"inline"===t.CSS.Values.getDisplayType(a)?"inline-block":"block":"none"),i.begin=function(){j&&j.call(g,g);for(var c in l){n[c]=a.style[c];var d=t.CSS.getPropertyValue(a,c);l[c]="Down"===b?[d,0]:[0,d]}n.overflow=a.style.overflow,a.style.overflow="hidden"},i.complete=function(){for(var b in n)a.style[b]=n[b];k&&k.call(g,g),h&&h.resolver(g)},t(a,l,i)}}),m.each(["In","Out"],function(a,b){t.Redirects["fade"+b]=function(a,c,e,f,g,h){var i=m.extend({},c),j={opacity:"In"===b?1:0},k=i.complete;i.complete=e!==f-1?i.begin=null:function(){k&&k.call(g,g),h&&h.resolver(g)},i.display===d&&(i.display="In"===b?"auto":"none"),t(this,j,i)}}),t}(window.jQuery||window.Zepto||window,window,document)}),!function(a){"function"==typeof require&&"object"==typeof exports?module.exports=a():"function"==typeof define&&define.amd?define(["velocity"],a):a()}(function(){return function(a,b,c,d){function e(a,b){var c=[];return a&&b?(g.each([a,b],function(a,b){var d=[];g.each(b,function(a,b){for(;b.toString().length<5;)b="0"+b;d.push(b)}),c.push(d.join(""))}),parseFloat(c[0])>parseFloat(c[1])):!1}if(!a.Velocity||!a.Velocity.Utilities)return void(b.console&&console.log("Velocity UI Pack: Velocity must be loaded first. Aborting."));var f=a.Velocity,g=f.Utilities,h=f.version,i={major:1,minor:1,patch:0};if(e(i,h)){var j="Velocity UI Pack: You need to update Velocity (jquery.velocity.js) to a newer version. Visit http://github.com/julianshapiro/velocity.";throw alert(j),new Error(j)}f.RegisterEffect=f.RegisterUI=function(a,b){function c(a,b,c,d){var e,h=0;g.each(a.nodeType?[a]:a,function(a,b){d&&(c+=a*d),e=b.parentNode,g.each(["height","paddingTop","paddingBottom","marginTop","marginBottom"],function(a,c){h+=parseFloat(f.CSS.getPropertyValue(b,c))})}),f.animate(e,{height:("In"===b?"+":"-")+"="+h},{queue:!1,easing:"ease-in-out",duration:c*("In"===b?.6:1)})}return f.Redirects[a]=function(e,h,i,j,k,l){function m(){h.display!==d&&"none"!==h.display||!/Out$/.test(a)||g.each(k.nodeType?[k]:k,function(a,b){f.CSS.setPropertyValue(b,"display","none")}),h.complete&&h.complete.call(k,k),l&&l.resolver(k||e)}var n=i===j-1;b.defaultDuration="function"==typeof b.defaultDuration?b.defaultDuration.call(k,k):parseFloat(b.defaultDuration);for(var o=0;o<b.calls.length;o++){var p=b.calls[o],q=p[0],r=h.duration||b.defaultDuration||1e3,s=p[1],t=p[2]||{},u={};if(u.duration=r*(s||1),u.queue=h.queue||"",u.easing=t.easing||"ease",u.delay=parseFloat(t.delay)||0,u._cacheValues=t._cacheValues||!0,0===o){if(u.delay+=parseFloat(h.delay)||0,0===i&&(u.begin=function(){h.begin&&h.begin.call(k,k);var b=a.match(/(In|Out)$/);b&&"In"===b[0]&&q.opacity!==d&&g.each(k.nodeType?[k]:k,function(a,b){f.CSS.setPropertyValue(b,"opacity",0)}),h.animateParentHeight&&b&&c(k,b[0],r+u.delay,h.stagger)}),null!==h.display)if(h.display!==d&&"none"!==h.display)u.display=h.display;else if(/In$/.test(a)){var v=f.CSS.Values.getDisplayType(e);u.display="inline"===v?"inline-block":v}h.visibility&&"hidden"!==h.visibility&&(u.visibility=h.visibility)}o===b.calls.length-1&&(u.complete=function(){if(b.reset){for(var a in b.reset){var c=b.reset[a];f.CSS.Hooks.registered[a]!==d||"string"!=typeof c&&"number"!=typeof c||(b.reset[a]=[b.reset[a],b.reset[a]])}var g={duration:0,queue:!1};n&&(g.complete=m),f.animate(e,b.reset,g)}else n&&m()},"hidden"===h.visibility&&(u.visibility=h.visibility)),f.animate(e,q,u)}},f},f.RegisterEffect.packagedEffects={"callout.bounce":{defaultDuration:550,calls:[[{translateY:-30},.25],[{translateY:0},.125],[{translateY:-15},.125],[{translateY:0},.25]]},"callout.shake":{defaultDuration:800,calls:[[{translateX:-11},.125],[{translateX:11},.125],[{translateX:-11},.125],[{translateX:11},.125],[{translateX:-11},.125],[{translateX:11},.125],[{translateX:-11},.125],[{translateX:0},.125]]},"callout.flash":{defaultDuration:1100,calls:[[{opacity:[0,"easeInOutQuad",1]},.25],[{opacity:[1,"easeInOutQuad"]},.25],[{opacity:[0,"easeInOutQuad"]},.25],[{opacity:[1,"easeInOutQuad"]},.25]]},"callout.pulse":{defaultDuration:825,calls:[[{scaleX:1.1,scaleY:1.1},.5],[{scaleX:1,scaleY:1},.5]]},"callout.swing":{defaultDuration:950,calls:[[{rotateZ:15},.2],[{rotateZ:-10},.2],[{rotateZ:5},.2],[{rotateZ:-5},.2],[{rotateZ:0},.2]]},"callout.tada":{defaultDuration:1e3,calls:[[{scaleX:.9,scaleY:.9,rotateZ:-3},.1],[{scaleX:1.1,scaleY:1.1,rotateZ:3},.1],[{scaleX:1.1,scaleY:1.1,rotateZ:-3},.1],["reverse",.125],["reverse",.125],["reverse",.125],["reverse",.125],["reverse",.125],[{scaleX:1,scaleY:1,rotateZ:0},.2]]},"transition.fadeIn":{defaultDuration:500,calls:[[{opacity:[1,0]}]]},"transition.fadeOut":{defaultDuration:500,calls:[[{opacity:[0,1]}]]},"transition.flipXIn":{defaultDuration:700,calls:[[{opacity:[1,0],transformPerspective:[800,800],rotateY:[0,-55]}]],reset:{transformPerspective:0}},"transition.flipXOut":{defaultDuration:700,calls:[[{opacity:[0,1],transformPerspective:[800,800],rotateY:55}]],reset:{transformPerspective:0,rotateY:0}},"transition.flipYIn":{defaultDuration:800,calls:[[{opacity:[1,0],transformPerspective:[800,800],rotateX:[0,-45]}]],reset:{transformPerspective:0}},"transition.flipYOut":{defaultDuration:800,calls:[[{opacity:[0,1],transformPerspective:[800,800],rotateX:25}]],reset:{transformPerspective:0,rotateX:0}},"transition.flipBounceXIn":{defaultDuration:900,calls:[[{opacity:[.725,0],transformPerspective:[400,400],rotateY:[-10,90]},.5],[{opacity:.8,rotateY:10},.25],[{opacity:1,rotateY:0},.25]],reset:{transformPerspective:0}},"transition.flipBounceXOut":{defaultDuration:800,calls:[[{opacity:[.9,1],transformPerspective:[400,400],rotateY:-10},.5],[{opacity:0,rotateY:90},.5]],reset:{transformPerspective:0,rotateY:0}},"transition.flipBounceYIn":{defaultDuration:850,calls:[[{opacity:[.725,0],transformPerspective:[400,400],rotateX:[-10,90]},.5],[{opacity:.8,rotateX:10},.25],[{opacity:1,rotateX:0},.25]],reset:{transformPerspective:0}},"transition.flipBounceYOut":{defaultDuration:800,calls:[[{opacity:[.9,1],transformPerspective:[400,400],rotateX:-15},.5],[{opacity:0,rotateX:90},.5]],reset:{transformPerspective:0,rotateX:0}},"transition.swoopIn":{defaultDuration:850,calls:[[{opacity:[1,0],transformOriginX:["100%","50%"],transformOriginY:["100%","100%"],scaleX:[1,0],scaleY:[1,0],translateX:[0,-700],translateZ:0}]],reset:{transformOriginX:"50%",transformOriginY:"50%"}},"transition.swoopOut":{defaultDuration:850,calls:[[{opacity:[0,1],transformOriginX:["50%","100%"],transformOriginY:["100%","100%"],scaleX:0,scaleY:0,translateX:-700,translateZ:0}]],reset:{transformOriginX:"50%",transformOriginY:"50%",scaleX:1,scaleY:1,translateX:0}},"transition.whirlIn":{defaultDuration:850,calls:[[{opacity:[1,0],transformOriginX:["50%","50%"],transformOriginY:["50%","50%"],scaleX:[1,0],scaleY:[1,0],rotateY:[0,160]},1,{easing:"easeInOutSine"}]]},"transition.whirlOut":{defaultDuration:750,calls:[[{opacity:[0,"easeInOutQuint",1],transformOriginX:["50%","50%"],transformOriginY:["50%","50%"],scaleX:0,scaleY:0,rotateY:160},1,{easing:"swing"}]],reset:{scaleX:1,scaleY:1,rotateY:0}},"transition.shrinkIn":{defaultDuration:750,calls:[[{opacity:[1,0],transformOriginX:["50%","50%"],transformOriginY:["50%","50%"],scaleX:[1,1.5],scaleY:[1,1.5],translateZ:0}]]},"transition.shrinkOut":{defaultDuration:600,calls:[[{opacity:[0,1],transformOriginX:["50%","50%"],transformOriginY:["50%","50%"],scaleX:1.3,scaleY:1.3,translateZ:0}]],reset:{scaleX:1,scaleY:1}},"transition.expandIn":{defaultDuration:700,calls:[[{opacity:[1,0],transformOriginX:["50%","50%"],transformOriginY:["50%","50%"],scaleX:[1,.625],scaleY:[1,.625],translateZ:0}]]},"transition.expandOut":{defaultDuration:700,calls:[[{opacity:[0,1],transformOriginX:["50%","50%"],transformOriginY:["50%","50%"],scaleX:.5,scaleY:.5,translateZ:0}]],reset:{scaleX:1,scaleY:1}},"transition.bounceIn":{defaultDuration:800,calls:[[{opacity:[1,0],scaleX:[1.05,.3],scaleY:[1.05,.3]},.4],[{scaleX:.9,scaleY:.9,translateZ:0},.2],[{scaleX:1,scaleY:1},.5]]},"transition.bounceOut":{defaultDuration:800,calls:[[{scaleX:.95,scaleY:.95},.35],[{scaleX:1.1,scaleY:1.1,translateZ:0},.35],[{opacity:[0,1],scaleX:.3,scaleY:.3},.3]],reset:{scaleX:1,scaleY:1}},"transition.bounceUpIn":{defaultDuration:800,calls:[[{opacity:[1,0],translateY:[-30,1e3]},.6,{easing:"easeOutCirc"}],[{translateY:10},.2],[{translateY:0},.2]]},"transition.bounceUpOut":{defaultDuration:1e3,calls:[[{translateY:20},.2],[{opacity:[0,"easeInCirc",1],translateY:-1e3},.8]],reset:{translateY:0}},"transition.bounceDownIn":{defaultDuration:800,calls:[[{opacity:[1,0],translateY:[30,-1e3]},.6,{easing:"easeOutCirc"}],[{translateY:-10},.2],[{translateY:0},.2]]},"transition.bounceDownOut":{defaultDuration:1e3,calls:[[{translateY:-20},.2],[{opacity:[0,"easeInCirc",1],translateY:1e3},.8]],reset:{translateY:0}},"transition.bounceLeftIn":{defaultDuration:750,calls:[[{opacity:[1,0],translateX:[30,-1250]},.6,{easing:"easeOutCirc"}],[{translateX:-10},.2],[{translateX:0},.2]]},"transition.bounceLeftOut":{defaultDuration:750,calls:[[{translateX:30},.2],[{opacity:[0,"easeInCirc",1],translateX:-1250},.8]],reset:{translateX:0}},"transition.bounceRightIn":{defaultDuration:750,calls:[[{opacity:[1,0],translateX:[-30,1250]},.6,{easing:"easeOutCirc"}],[{translateX:10},.2],[{translateX:0},.2]]},"transition.bounceRightOut":{defaultDuration:750,calls:[[{translateX:-30},.2],[{opacity:[0,"easeInCirc",1],translateX:1250},.8]],reset:{translateX:0}},"transition.slideUpIn":{defaultDuration:900,calls:[[{opacity:[1,0],translateY:[0,20],translateZ:0}]]},"transition.slideUpOut":{defaultDuration:900,calls:[[{opacity:[0,1],translateY:-20,translateZ:0}]],reset:{translateY:0}},"transition.slideDownIn":{defaultDuration:900,calls:[[{opacity:[1,0],translateY:[0,-20],translateZ:0}]]},"transition.slideDownOut":{defaultDuration:900,calls:[[{opacity:[0,1],translateY:20,translateZ:0}]],reset:{translateY:0}},"transition.slideLeftIn":{defaultDuration:1e3,calls:[[{opacity:[1,0],translateX:[0,-20],translateZ:0}]]},"transition.slideLeftOut":{defaultDuration:1050,calls:[[{opacity:[0,1],translateX:-20,translateZ:0}]],reset:{translateX:0}},"transition.slideRightIn":{defaultDuration:1e3,calls:[[{opacity:[1,0],translateX:[0,20],translateZ:0}]]},"transition.slideRightOut":{defaultDuration:1050,calls:[[{opacity:[0,1],translateX:20,translateZ:0}]],reset:{translateX:0}},"transition.slideUpBigIn":{defaultDuration:850,calls:[[{opacity:[1,0],translateY:[0,75],translateZ:0}]]},"transition.slideUpBigOut":{defaultDuration:800,calls:[[{opacity:[0,1],translateY:-75,translateZ:0}]],reset:{translateY:0}},"transition.slideDownBigIn":{defaultDuration:850,calls:[[{opacity:[1,0],translateY:[0,-75],translateZ:0}]]},"transition.slideDownBigOut":{defaultDuration:800,calls:[[{opacity:[0,1],translateY:75,translateZ:0}]],reset:{translateY:0}},"transition.slideLeftBigIn":{defaultDuration:800,calls:[[{opacity:[1,0],translateX:[0,-75],translateZ:0}]]},"transition.slideLeftBigOut":{defaultDuration:750,calls:[[{opacity:[0,1],translateX:-75,translateZ:0}]],reset:{translateX:0}},"transition.slideRightBigIn":{defaultDuration:800,calls:[[{opacity:[1,0],translateX:[0,75],translateZ:0}]]},"transition.slideRightBigOut":{defaultDuration:750,calls:[[{opacity:[0,1],translateX:75,translateZ:0}]],reset:{translateX:0}},"transition.perspectiveUpIn":{defaultDuration:800,calls:[[{opacity:[1,0],transformPerspective:[800,800],transformOriginX:[0,0],transformOriginY:["100%","100%"],rotateX:[0,-180]}]]},"transition.perspectiveUpOut":{defaultDuration:850,calls:[[{opacity:[0,1],transformPerspective:[800,800],transformOriginX:[0,0],transformOriginY:["100%","100%"],rotateX:-180}]],reset:{transformPerspective:0,transformOriginX:"50%",transformOriginY:"50%",rotateX:0}},"transition.perspectiveDownIn":{defaultDuration:800,calls:[[{opacity:[1,0],transformPerspective:[800,800],transformOriginX:[0,0],transformOriginY:[0,0],rotateX:[0,180]}]],reset:{transformPerspective:0,transformOriginX:"50%",transformOriginY:"50%"}},"transition.perspectiveDownOut":{defaultDuration:850,calls:[[{opacity:[0,1],transformPerspective:[800,800],transformOriginX:[0,0],transformOriginY:[0,0],rotateX:180}]],reset:{transformPerspective:0,transformOriginX:"50%",transformOriginY:"50%",rotateX:0}},"transition.perspectiveLeftIn":{defaultDuration:950,calls:[[{opacity:[1,0],transformPerspective:[2e3,2e3],transformOriginX:[0,0],transformOriginY:[0,0],rotateY:[0,-180]}]],reset:{transformPerspective:0,transformOriginX:"50%",transformOriginY:"50%"}},"transition.perspectiveLeftOut":{defaultDuration:950,calls:[[{opacity:[0,1],transformPerspective:[2e3,2e3],transformOriginX:[0,0],transformOriginY:[0,0],rotateY:-180}]],reset:{transformPerspective:0,transformOriginX:"50%",transformOriginY:"50%",rotateY:0}},"transition.perspectiveRightIn":{defaultDuration:950,calls:[[{opacity:[1,0],transformPerspective:[2e3,2e3],transformOriginX:["100%","100%"],transformOriginY:[0,0],rotateY:[0,180]}]],reset:{transformPerspective:0,transformOriginX:"50%",transformOriginY:"50%"}},"transition.perspectiveRightOut":{defaultDuration:950,calls:[[{opacity:[0,1],transformPerspective:[2e3,2e3],transformOriginX:["100%","100%"],transformOriginY:[0,0],rotateY:180}]],reset:{transformPerspective:0,transformOriginX:"50%",transformOriginY:"50%",rotateY:0}}};for(var k in f.RegisterEffect.packagedEffects)f.RegisterEffect(k,f.RegisterEffect.packagedEffects[k]);f.RunSequence=function(a){var b=g.extend(!0,[],a);b.length>1&&(g.each(b.reverse(),function(a,c){var d=b[a+1];if(d){var e=c.options&&c.options.sequenceQueue===!1?"begin":"complete",h=d.options&&d.options[e],i={};i[e]=function(){var a=d.elements.nodeType?[d.elements]:d.elements;h&&h.call(a,a),f(c)},d.options=g.extend({},d.options,i)}}),b.reverse()),f(b[0])}}(window.jQuery||window.Zepto||window,window,document)});var P=function(a,b,c){return function d(e,f){function g(){var a=this instanceof g?this:new h;return a.init.apply(a,arguments),a}function h(){}f===c&&(f=e,e=Object),g.Bare=h;var i,j=h[a]=e[a],k=h[a]=g[a]=g.p=new h;return k.constructor=g,g.extend=function(a){return d(g,a)},(g.open=function(a){if("function"==typeof a&&(a=a.call(g,k,j,g,e)),"object"==typeof a)for(i in a)b.call(a,i)&&(k[i]=a[i]);return"init"in k||(k.init=e),g})(f)}}("prototype",{}.hasOwnProperty);!function(a){function b(a){return new RegExp("(^|\\s+)"+a+"(\\s+|$)")}function c(a,b){var c=d(a,b)?f:e;c(a,b)}var d,e,f;"classList"in document.documentElement?(d=function(a,b){return a.classList.contains(b)},e=function(a,b){a.classList.add(b)},f=function(a,b){a.classList.remove(b)}):(d=function(a,c){return b(c).test(a.className)},e=function(a,b){d(a,b)||(a.className=a.className+" "+b)},f=function(a,c){a.className=a.className.replace(b(c)," ")});var g={hasClass:d,addClass:e,removeClass:f,toggleClass:c,has:d,add:e,remove:f,toggle:c};"function"==typeof define&&define.amd?define("classie/classie",g):a.classie=g}(window),function(){function a(){}function b(a,b){for(var c=a.length;c--;)if(a[c].listener===b)return c;return-1}function c(a){return function(){return this[a].apply(this,arguments)}}var d=a.prototype;d.getListeners=function(a){var b,c,d=this._getEvents();if("object"==typeof a){b={};for(c in d)d.hasOwnProperty(c)&&a.test(c)&&(b[c]=d[c])}else b=d[a]||(d[a]=[]);return b},d.flattenListeners=function(a){var b,c=[];for(b=0;b<a.length;b+=1)c.push(a[b].listener);return c},d.getListenersAsObject=function(a){var b,c=this.getListeners(a);return c instanceof Array&&(b={},b[a]=c),b||c},d.addListener=function(a,c){var d,e=this.getListenersAsObject(a),f="object"==typeof c;for(d in e)e.hasOwnProperty(d)&&-1===b(e[d],c)&&e[d].push(f?c:{listener:c,once:!1});return this},d.on=c("addListener"),d.addOnceListener=function(a,b){return this.addListener(a,{listener:b,once:!0})},d.once=c("addOnceListener"),d.defineEvent=function(a){return this.getListeners(a),this},d.defineEvents=function(a){for(var b=0;b<a.length;b+=1)this.defineEvent(a[b]);return this},d.removeListener=function(a,c){var d,e,f=this.getListenersAsObject(a);for(e in f)f.hasOwnProperty(e)&&(d=b(f[e],c),-1!==d&&f[e].splice(d,1));return this},d.off=c("removeListener"),d.addListeners=function(a,b){return this.manipulateListeners(!1,a,b)},d.removeListeners=function(a,b){return this.manipulateListeners(!0,a,b)},d.manipulateListeners=function(a,b,c){var d,e,f=a?this.removeListener:this.addListener,g=a?this.removeListeners:this.addListeners;if("object"!=typeof b||b instanceof RegExp)for(d=c.length;d--;)f.call(this,b,c[d]);else for(d in b)b.hasOwnProperty(d)&&(e=b[d])&&("function"==typeof e?f.call(this,d,e):g.call(this,d,e));return this},d.removeEvent=function(a){var b,c=typeof a,d=this._getEvents();if("string"===c)delete d[a];else if("object"===c)for(b in d)d.hasOwnProperty(b)&&a.test(b)&&delete d[b];else delete this._events;return this},d.emitEvent=function(a,b){var c,d,e,f,g=this.getListenersAsObject(a);for(e in g)if(g.hasOwnProperty(e))for(d=g[e].length;d--;)c=g[e][d],f=c.listener.apply(this,b||[]),(f===this._getOnceReturnValue()||c.once===!0)&&this.removeListener(a,c.listener);return this},d.trigger=c("emitEvent"),d.emit=function(a){var b=Array.prototype.slice.call(arguments,1);return this.emitEvent(a,b)},d.setOnceReturnValue=function(a){return this._onceReturnValue=a,this},d._getOnceReturnValue=function(){return this.hasOwnProperty("_onceReturnValue")?this._onceReturnValue:!0},d._getEvents=function(){return this._events||(this._events={})},"function"==typeof define&&define.amd?define("eventEmitter/EventEmitter",[],function(){return a}):"object"==typeof module&&module.exports?module.exports=a:this.EventEmitter=a}.call(this),function(a){var b=document.documentElement,c=function(){};b.addEventListener?c=function(a,b,c){a.addEventListener(b,c,!1)}:b.attachEvent&&(c=function(b,c,d){b[c+d]=d.handleEvent?function(){var b=a.event;b.target=b.target||b.srcElement,d.handleEvent.call(d,b)}:function(){var c=a.event;c.target=c.target||c.srcElement,d.call(b,c)},b.attachEvent("on"+c,b[c+d])});var d=function(){};b.removeEventListener?d=function(a,b,c){a.removeEventListener(b,c,!1)}:b.detachEvent&&(d=function(a,b,c){a.detachEvent("on"+b,a[b+c]);try{delete a[b+c]}catch(d){a[b+c]=void 0}});var e={bind:c,unbind:d};"function"==typeof define&&define.amd?define("eventie/eventie",e):a.eventie=e}(this),function(a){function b(a){if(a){if("string"==typeof d[a])return a;a=a.charAt(0).toUpperCase()+a.slice(1);for(var b,e=0,f=c.length;f>e;e++)if(b=c[e]+a,"string"==typeof d[b])return b}}var c="Webkit Moz ms Ms O".split(" "),d=document.documentElement.style;"function"==typeof define&&define.amd?define("get-style-property/get-style-property",[],function(){return b}):a.getStyleProperty=b}(window),function(a){function b(a){var b=parseFloat(a),c=-1===a.indexOf("%")&&!isNaN(b);return c&&b}function c(){for(var a={width:0,height:0,innerWidth:0,innerHeight:0,outerWidth:0,outerHeight:0},b=0,c=g.length;c>b;b++){var d=g[b];a[d]=0}return a}function d(a){function d(a){if("string"==typeof a&&(a=document.querySelector(a)),a&&"object"==typeof a&&a.nodeType){var d=f(a);if("none"===d.display)return c();var i={};i.width=a.offsetWidth,i.height=a.offsetHeight;for(var j=i.isBorderBox=!(!h||!d[h]||"border-box"!==d[h]),k=0,l=g.length;l>k;k++){var m=g[k],n=d[m],o=parseFloat(n);i[m]=isNaN(o)?0:o}var p=i.paddingLeft+i.paddingRight,q=i.paddingTop+i.paddingBottom,r=i.marginLeft+i.marginRight,s=i.marginTop+i.marginBottom,t=i.borderLeftWidth+i.borderRightWidth,u=i.borderTopWidth+i.borderBottomWidth,v=j&&e,w=b(d.width);w!==!1&&(i.width=w+(v?0:p+t));var x=b(d.height);return x!==!1&&(i.height=x+(v?0:q+u)),i.innerWidth=i.width-(p+t),i.innerHeight=i.height-(q+u),i.outerWidth=i.width+r,i.outerHeight=i.height+s,i}}var e,h=a("boxSizing");return function(){if(h){var a=document.createElement("div");a.style.width="200px",a.style.padding="1px 2px 3px 4px",a.style.borderStyle="solid",a.style.borderWidth="1px 2px 3px 4px",a.style[h]="border-box";var c=document.body||document.documentElement;c.appendChild(a);var d=f(a);e=200===b(d.width),c.removeChild(a)}}(),d}var e=document.defaultView,f=e&&e.getComputedStyle?function(a){return e.getComputedStyle(a,null)}:function(a){return a.currentStyle},g=["paddingLeft","paddingRight","paddingTop","paddingBottom","marginLeft","marginRight","marginTop","marginBottom","borderLeftWidth","borderRightWidth","borderTopWidth","borderBottomWidth"];"function"==typeof define&&define.amd?define("get-size/get-size",["get-style-property/get-style-property"],d):a.getSize=d(a.getStyleProperty)}(window),function(a){function b(a,b){for(var c in b)a[c]=b[c];return a}function c(){}function d(d,e,g,j,k){function m(a,c){this.element="string"==typeof a?f.querySelector(a):a,this.options=b({},this.options),b(this.options,c),this._create()}function n(){return!1}function o(a,b){a.x=void 0!==b.pageX?b.pageX:b.clientX,a.y=void 0!==b.pageY?b.pageY:b.clientY}function p(a,b,c){return c=c||"round",b?Math[c](a/b)*b:a}var q=j("transform"),r=!!j("perspective");b(m.prototype,e.prototype),m.prototype.options={},m.prototype._create=function(){this.position={},this._getPosition(),this.startPoint={x:0,y:0},this.dragPoint={x:0,y:0},this.startPosition=b({},this.position);var a=h(this.element);"relative"!==a.position&&"absolute"!==a.position&&(this.element.style.position="relative"),this.enable(),this.setHandles()},m.prototype.setHandles=function(){this.handles=this.options.handle?this.element.querySelectorAll(this.options.handle):[this.element],this.bindHandles(!0)},m.prototype.bindHandles=function(b){var c;c=a.navigator.pointerEnabled?this.bindPointer:a.navigator.msPointerEnabled?this.bindMSPointer:this.bindMouseTouch,b=void 0===b?!0:!!b;for(var d=0,e=this.handles.length;e>d;d++){var f=this.handles[d];c.call(this,f,b)}},m.prototype.bindPointer=function(a,b){var c=b?"bind":"unbind";g[c](a,"pointerdown",this),a.style.touchAction=b?"none":""},m.prototype.bindMSPointer=function(a,b){var c=b?"bind":"unbind";g[c](a,"MSPointerDown",this),a.style.msTouchAction=b?"none":""},m.prototype.bindMouseTouch=function(a,b){var c=b?"bind":"unbind";g[c](a,"mousedown",this),g[c](a,"touchstart",this),b&&t(a)};var s="attachEvent"in f.documentElement,t=s?function(a){"IMG"===a.nodeName&&(a.ondragstart=n);for(var b=a.querySelectorAll("img"),c=0,d=b.length;d>c;c++){var e=b[c];e.ondragstart=n}}:c;m.prototype._getPosition=function(){var a=h(this.element),b=parseInt(a.left,10),c=parseInt(a.top,10);this.position.x=isNaN(b)?0:b,this.position.y=isNaN(c)?0:c,this._addTransformPosition(a)},m.prototype._addTransformPosition=function(a){if(q){var b=a[q];if(0===b.indexOf("matrix")){var c=b.split(","),d=0===b.indexOf("matrix3d")?12:4,e=parseInt(c[d],10),f=parseInt(c[d+1],10);this.position.x+=e,this.position.y+=f}}},m.prototype.handleEvent=function(a){var b="on"+a.type;this[b]&&this[b](a)},m.prototype.getTouch=function(a){for(var b=0,c=a.length;c>b;b++){var d=a[b];if(d.identifier===this.pointerIdentifier)return d}},m.prototype.onmousedown=function(a){var b=a.button;b&&0!==b&&1!==b||!$(a.target).hasClass("jn-pointer")&&0==$(a.target).parents(".jn-pointer").length&&this.dragStart(a,a)},m.prototype.ontouchstart=function(a){this.isDragging||this.dragStart(a,a.changedTouches[0])},m.prototype.onMSPointerDown=m.prototype.onpointerdown=function(a){this.isDragging||this.dragStart(a,a)};var u={mousedown:["mousemove","mouseup"],touchstart:["touchmove","touchend","touchcancel"],pointerdown:["pointermove","pointerup","pointercancel"],MSPointerDown:["MSPointerMove","MSPointerUp","MSPointerCancel"]};m.prototype.dragStart=function(b,c){this.isEnabled&&(b.preventDefault?b.preventDefault():b.returnValue=!1,this.pointerIdentifier=void 0!==c.pointerId?c.pointerId:c.identifier,this._getPosition(),this.measureContainment(),o(this.startPoint,c),this.startPosition.x=this.position.x,this.startPosition.y=this.position.y,this.setLeftTop(),this.dragPoint.x=0,this.dragPoint.y=0,this._bindEvents({events:u[b.type],node:b.preventDefault?a:f}),d.add(this.element,"is-dragging"),this.isDragging=!0,this.emitEvent("dragStart",[this,b,c]),this.animate())},m.prototype._bindEvents=function(a){for(var b=0,c=a.events.length;c>b;b++){var d=a.events[b];g.bind(a.node,d,this)}this._boundEvents=a},m.prototype._unbindEvents=function(){var a=this._boundEvents;if(a&&a.events){for(var b=0,c=a.events.length;c>b;b++){var d=a.events[b];g.unbind(a.node,d,this)}delete this._boundEvents}},m.prototype.measureContainment=function(){var a=this.options.containment;if(a){this.size=k(this.element);var b=this.element.getBoundingClientRect(),c=i(a)?a:"string"==typeof a?f.querySelector(a):this.element.parentNode;this.containerSize=k(c);var d=c.getBoundingClientRect();this.relativeStartPosition={x:b.left-d.left,y:b.top-d.top}}},m.prototype.onmousemove=function(a){this.dragMove(a,a)},m.prototype.onMSPointerMove=m.prototype.onpointermove=function(a){a.pointerId===this.pointerIdentifier&&this.dragMove(a,a)},m.prototype.ontouchmove=function(a){var b=this.getTouch(a.changedTouches);b&&this.dragMove(a,b)},m.prototype.dragMove=function(a,b){o(this.dragPoint,b);var c=this.dragPoint.x-this.startPoint.x,d=this.dragPoint.y-this.startPoint.y,e=this.options.grid,f=e&&e[0],g=e&&e[1];c=p(c,f),d=p(d,g),c=this.containDrag("x",c,f),d=this.containDrag("y",d,g),c="y"===this.options.axis?0:c,d="x"===this.options.axis?0:d,this.position.x=this.startPosition.x+c,this.position.y=this.startPosition.y+d,this.dragPoint.x=c,this.dragPoint.y=d,this.emitEvent("dragMove",[this,a,b])},m.prototype.containDrag=function(a,b,c){if(!this.options.containment)return b;var d="x"===a?"width":"height",e=this.relativeStartPosition[a],f=p(-e,c,"ceil"),g=this.containerSize[d]-e-this.size[d];return g=p(g,c,"floor"),Math.min(g,Math.max(f,b))},m.prototype.onmouseup=function(a){this.dragEnd(a,a)},m.prototype.onMSPointerUp=m.prototype.onpointerup=function(a){a.pointerId===this.pointerIdentifier&&this.dragEnd(a,a)},m.prototype.ontouchend=function(a){var b=this.getTouch(a.changedTouches);b&&this.dragEnd(a,b)},m.prototype.dragEnd=function(a,b){this.isDragging=!1,delete this.pointerIdentifier,q&&(this.element.style[q]="",this.setLeftTop()),this._unbindEvents(),d.remove(this.element,"is-dragging"),this.emitEvent("dragEnd",[this,a,b])},m.prototype.onMSPointerCancel=m.prototype.onpointercancel=function(a){a.pointerId===this.pointerIdentifier&&this.dragEnd(a,a)},m.prototype.ontouchcancel=function(a){var b=this.getTouch(a.changedTouches);this.dragEnd(a,b)},m.prototype.animate=function(){if(this.isDragging){this.positionDrag();var a=this;l(function(){a.animate()})}};var v=r?function(a,b){return"translate3d( "+a+"px, "+b+"px, 0)"}:function(a,b){return"translate( "+a+"px, "+b+"px)"};return m.prototype.setLeftTop=function(){this.element.style.left=this.position.x+"px",this.element.style.top=this.position.y+"px"},m.prototype.positionDrag=q?function(){this.element.style[q]=v(this.dragPoint.x,this.dragPoint.y)}:m.prototype.setLeftTop,m.prototype.enable=function(){this.isEnabled=!0},m.prototype.disable=function(){this.isEnabled=!1,this.isDragging&&this.dragEnd()},m.prototype.destroy=function(){this.disable(),q&&(this.element.style[q]=""),this.element.style.left="",this.element.style.top="",this.element.style.position="",this.bindHandles(!1)},m}for(var e,f=a.document,g=f.defaultView,h=g&&g.getComputedStyle?function(a){return g.getComputedStyle(a,null)}:function(a){return a.currentStyle},i="object"==typeof HTMLElement?function(a){return a instanceof HTMLElement}:function(a){return a&&"object"==typeof a&&1===a.nodeType&&"string"==typeof a.nodeName},j=0,k="webkit moz ms o".split(" "),l=a.requestAnimationFrame,m=a.cancelAnimationFrame,n=0;n<k.length&&(!l||!m);n++)e=k[n],l=l||a[e+"RequestAnimationFrame"],m=m||a[e+"CancelAnimationFrame"]||a[e+"CancelRequestAnimationFrame"];l&&m||(l=function(b){var c=(new Date).getTime(),d=Math.max(0,16-(c-j)),e=a.setTimeout(function(){b(c+d)},d);return j=c+d,e},m=function(b){a.clearTimeout(b)}),"function"==typeof define&&define.amd?define(["classie/classie","eventEmitter/EventEmitter","eventie/eventie","get-style-property/get-style-property","get-size/get-size"],d):"object"==typeof exports?module.exports=d(require("desandro-classie"),require("wolfy87-eventemitter"),require("eventie"),require("desandro-get-style-property"),require("get-size")):a.Draggabilly=d(a.classie,a.EventEmitter,a.eventie,a.getStyleProperty,a.getSize)}(window),function(a,b){function c(b){b.preventDefault(),a.event.remove(v,"click",c)}function d(a,b){return(q?b.originalEvent.touches[0]:b)["page"+a.toUpperCase()]}function e(b,d,e){var f=a.Event(d,x);a.event.trigger(f,{originalEvent:b},b.target),f.isDefaultPrevented()&&(~d.indexOf("tap")&&!q?a.event.add(v,"click",c):b.preventDefault()),e&&(a.event.remove(v,t+"."+u,g),a.event.remove(v,s+"."+u,h))}function f(b){var f=b.timeStamp||+new Date;k!=f&&(k=f,w.x=x.x=d("x",b),w.y=x.y=d("y",b),w.time=f,w.target=b.target,x.orientation=null,x.end=!1,i=!1,j=!1,l=setTimeout(function(){j=!0,e(b,"press") },a.Finger.pressDuration),a.event.add(v,t+"."+u,g),a.event.add(v,s+"."+u,h),y.preventDefault&&(b.preventDefault(),a.event.add(v,"click",c)))}function g(b){if(x.x=d("x",b),x.y=d("y",b),x.dx=x.x-w.x,x.dy=x.y-w.y,x.adx=Math.abs(x.dx),x.ady=Math.abs(x.dy),i=x.adx>y.motionThreshold||x.ady>y.motionThreshold){for(clearTimeout(l),x.orientation||(x.adx>x.ady?(x.orientation="horizontal",x.direction=x.dx>0?1:-1):(x.orientation="vertical",x.direction=x.dy>0?1:-1));b.target&&b.target!==w.target;)b.target=b.target.parentNode;return b.target!==w.target?(b.target=w.target,void h.call(this,a.Event(s+"."+u,b))):void e(b,"drag")}}function h(a){var b,c=a.timeStamp||+new Date,d=c-w.time;if(clearTimeout(l),i||j||a.target!==w.target)a.target=w.target,y.flickDuration>d&&e(a,"flick"),x.end=!0,b="drag";else{var f=m===a.target&&y.doubleTapInterval>c-n;b=f?"doubletap":"tap",m=f?null:w.target,n=c}e(a,b,!0)}var i,j,k,l,m,n,o=/chrome/i.exec(b),p=/android/i.exec(b),q="ontouchstart"in window&&!(o&&!p),r=q?"touchstart":"mousedown",s=q?"touchend touchcancel":"mouseup mouseleave",t=q?"touchmove":"mousemove",u="finger",v=a("html")[0],w={},x={},y=a.Finger={pressDuration:300,doubleTapInterval:300,flickDuration:150,motionThreshold:5};a.event.add(v,r+"."+u,f)}(jQuery,navigator.userAgent),function(a){var b=/iphone|ipad/i.test(navigator.userAgent);a.fn.nodoubletapzoom=function(){b&&a(this).bind("touchstart",function(b){var c=b.timeStamp,d=a(this).data("lastTouch")||c,e=c-d,f=b.originalEvent.touches.length;a(this).data("lastTouch",c),!e||e>500||f>1||(b.preventDefault(),a(this).trigger("click").trigger("click"))})}}(jQuery),function(a){function b(b){if("string"==typeof b.data&&(b.data={keys:b.data}),b.data&&b.data.keys&&"string"==typeof b.data.keys){var c=b.handler,d=b.data.keys.toLowerCase().split(" ");b.handler=function(b){if(this===b.target||!(a.hotkeys.options.filterInputAcceptingElements&&a.hotkeys.textInputTypes.test(b.target.nodeName)||a.hotkeys.options.filterContentEditable&&a(b.target).attr("contenteditable")||a.hotkeys.options.filterTextInputs&&a.inArray(b.target.type,a.hotkeys.textAcceptingInputTypes)>-1)){var e="keypress"!==b.type&&a.hotkeys.specialKeys[b.which],f=String.fromCharCode(b.which).toLowerCase(),g="",h={};a.each(["alt","ctrl","shift"],function(a,c){b[c+"Key"]&&e!==c&&(g+=c+"+")}),b.metaKey&&!b.ctrlKey&&"meta"!==e&&(g+="meta+"),b.metaKey&&"meta"!==e&&g.indexOf("alt+ctrl+shift+")>-1&&(g=g.replace("alt+ctrl+shift+","hyper+")),e?h[g+e]=!0:(h[g+f]=!0,h[g+a.hotkeys.shiftNums[f]]=!0,"shift+"===g&&(h[a.hotkeys.shiftNums[f]]=!0));for(var i=0,j=d.length;j>i;i++)if(h[d[i]])return c.apply(this,arguments)}}}}a.hotkeys={version:"0.8",specialKeys:{8:"backspace",9:"tab",10:"return",13:"return",16:"shift",17:"ctrl",18:"alt",19:"pause",20:"capslock",27:"esc",32:"space",33:"pageup",34:"pagedown",35:"end",36:"home",37:"left",38:"up",39:"right",40:"down",45:"insert",46:"del",59:";",61:"=",96:"0",97:"1",98:"2",99:"3",100:"4",101:"5",102:"6",103:"7",104:"8",105:"9",106:"*",107:"+",109:"-",110:".",111:"/",112:"f1",113:"f2",114:"f3",115:"f4",116:"f5",117:"f6",118:"f7",119:"f8",120:"f9",121:"f10",122:"f11",123:"f12",144:"numlock",145:"scroll",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'"},shiftNums:{"`":"~",1:"!",2:"@",3:"#",4:"$",5:"%",6:"^",7:"&",8:"*",9:"(",0:")","-":"_","=":"+",";":": ","'":'"',",":"<",".":">","/":"?","\\":"|"},textAcceptingInputTypes:["text","password","number","email","url","range","date","month","week","time","datetime","datetime-local","search","color","tel"],textInputTypes:/textarea|input|select/i,options:{filterInputAcceptingElements:!0,filterTextInputs:!0,filterContentEditable:!0}},a.each(["keydown","keyup","keypress"],function(){a.event.special[this]={add:b}})}(jQuery||this.jQuery||window.jQuery); //# sourceMappingURL=library.min.map
20,748.444444
54,257
0.647069
c4db5d53598e6a3b8661d2804d485e0809c8e30b
803
js
JavaScript
src/tagpress/model/search/searchresult.js
IsuraManchanayake/tagem
997754afa5f31efd9b8a9dea3185f4c5946de8cc
[ "MIT" ]
null
null
null
src/tagpress/model/search/searchresult.js
IsuraManchanayake/tagem
997754afa5f31efd9b8a9dea3185f4c5946de8cc
[ "MIT" ]
null
null
null
src/tagpress/model/search/searchresult.js
IsuraManchanayake/tagem
997754afa5f31efd9b8a9dea3185f4c5946de8cc
[ "MIT" ]
null
null
null
import { global } from '../../global/global' import { File } from '../fileinformation/file' import { Tag } from '../fileinformation/tag' import { Category } from '../fileinformation/category' export class SearchResult { constructor(rawDataList) { this.rawDataList = rawDataList; } simplify() { var results = []; this.rawDataList.forEach(function(row) { // row {filename, filid, tid, cname, tname, color, fpath} if (row.filid in results) {} else { results[row.filid] = new File(row.fpath + row.filename, []); } }); this.rawDataList.forEach(function(row) { results[row.filid].tags.push(new Tag(row.tname, new Category(row.cname, row.color))); }); return results; } }
32.12
97
0.582814
c4dc58cc3c198959ec8b7cd62844d99e77d5eaef
1,612
js
JavaScript
test/index.js
genarot/npm-lib-project-1b-api-github
0ab167c80836744f214afd71a96a1b489c717b03
[ "MIT" ]
null
null
null
test/index.js
genarot/npm-lib-project-1b-api-github
0ab167c80836744f214afd71a96a1b489c717b03
[ "MIT" ]
null
null
null
test/index.js
genarot/npm-lib-project-1b-api-github
0ab167c80836744f214afd71a96a1b489c717b03
[ "MIT" ]
null
null
null
const fetchUserData = require("./../index").fetchUserData; const genarotResponse = require('./responses/genarot'); const jperezResponse = require('./responses/jperez'); const { expect } = require("chai"); const nock = require('nock') describe("Data test from different github users", () => { before(() => { nock('https://api.github.com') .log(console.log) .get('/users/genarot') .reply(200, genarotResponse) }); describe('Fetch data from user "genarot"', async () => { // To check the variable type of the response of the function. let response before( async () => { response = await fetchUserData("genarot"); }) // It must be an object. it('should return an object', () => { expect(response).to.be.an("object"); }) // To check that the user fetched from the API be genarot it('should has a login property equals to "genarot"', () => { expect(response).to.have.deep.property("login", "genarot"); }) // To check that user Id is a number it('should has "id" property as a number', () => { expect(response.id).to.be.a('number') }) // To check that followers and following are numbers it('should has "following" and "followers" properties as number', () => { expect(response.followers).to.be.a('number') expect(response.following).to.be.a('number') }) // The property locaction must be Nicaragua it('should return "location" equals to Nicaragua', () => { expect(response).to.have.deep.property('location', 'Nicaragua') }) }).timeout(5000); });
31.607843
77
0.617866
c4dcc94b1f12db0d7695e4489c180776ca5a4dbd
2,845
js
JavaScript
app/assets/javascripts/categories.js
hebersandoval/hs_website
65a72326d5837161ec190a02b1c17a5cc8b8eae0
[ "MIT" ]
null
null
null
app/assets/javascripts/categories.js
hebersandoval/hs_website
65a72326d5837161ec190a02b1c17a5cc8b8eae0
[ "MIT" ]
null
null
null
app/assets/javascripts/categories.js
hebersandoval/hs_website
65a72326d5837161ec190a02b1c17a5cc8b8eae0
[ "MIT" ]
null
null
null
// class Category { // constructor(attributes) { // this.id = attributes.id; // this.name = attributes.name; // } // // // Render handlebars template // renderIndexCategory() { // return indexCategoryTemplate(this); // } // // compileIndexCategoryTemplate() { // indexCategorySource = $("#indexCategoryTemplate").html(); // if (indexCategorySource !== undefined) { // indexCategoryTemplate = Handlebars.compile(indexCategorySource); // } // } // // // Get all categories via AJAX GET request // indexCategories() { // var url = window.location.pathname; // $.get(url, function(data) { // $.each(data, function(index, category) { // var indexCategory = new Category(category); // var indexCategoryRender = indexCategory.renderIndexCategory(); // $(".categories-block").prepend(indexCategoryRender); // }); // }, "json"); // } // } // $(document).ready(function() { // compileIndexCategoryTemplate(); // indexCategories(); // compileNewCategoryTemplate(); // newCategory(); // }); // // function Category(attributes) { // this.id = attributes.id; // this.name = attributes.name; // } // // // // Render handlebars template // Category.prototype.renderIndexCategory = function() { // return indexCategoryTemplate({id: this.id, name: this.name}); // } // // Category.prototype.renderNewCategory = function() { // return newCategoryTemplate({id: this.id, name: this.name}); // } // // // Compile stuff // function compileIndexCategoryTemplate() { // var indexCategorySource = $("#indexCategoryTemplate").html(); // if (indexCategorySource !== undefined) { // indexCategoryTemplate = Handlebars.compile(indexCategorySource); // } // } // // function compileNewCategoryTemplate(){ // newCategorySource = $("#newCategoryTemplate").html(); // if ( newCategorySource !== undefined ) { // newCategoryTemplate = Handlebars.compile(newCategorySource); // } // } // // // Get all categories via AJAX GET request // function indexCategories() { // var url = window.location.pathname; // $.get(url, function(data) { // $.each(data, function(index, category) { // var indexCategory = new Category(category); // var indexCategoryRender = indexCategory.renderIndexCategory(); // $(".categories-block").prepend(indexCategoryRender); // }) // }, "json"); // } // // // Get the new category form via AJAX GET request // function newCategory() { // $(document).on("click", '.js-new-category', function(event) { // event.preventDefault(); // $.get( $(event.target).attr('href'), function( data ) { // var category = new Category(data); // var categoryRender = category.renderNewCategory(); // $("#new-category").html(""); // $("#new-category").append(categoryRender); // }); // }); // }
30.923913
73
0.632689
c4dd18ae5f5ae13a6e1e4e958ca3c0aaa13ee776
318
js
JavaScript
src/components/shopping-item/ShoppingItem.js
mr-shan/practice-react-routes
9b64789bd8bc1929ef8208f4ddb7da5bc393f98d
[ "MIT" ]
null
null
null
src/components/shopping-item/ShoppingItem.js
mr-shan/practice-react-routes
9b64789bd8bc1929ef8208f4ddb7da5bc393f98d
[ "MIT" ]
null
null
null
src/components/shopping-item/ShoppingItem.js
mr-shan/practice-react-routes
9b64789bd8bc1929ef8208f4ddb7da5bc393f98d
[ "MIT" ]
null
null
null
import React from "react"; import styles from "./ShoppingItem.module.css"; export default props => { return ( <div className={styles.shoppingItemContainer}> <label> {props.name} - ₹ {props.price} </label> <button onClick={props.clicked}>Qty: {props.count}</button> </div> ); };
21.2
65
0.616352
c4e00048e67ccd6e6c0b73fe4e59f7d8b8006357
13,480
js
JavaScript
dist/jobq.js
adleroliveira/jobQ
35e1a7473b96d336a52fbee9e81a75ae00f748fa
[ "MIT" ]
4
2016-11-20T16:33:02.000Z
2020-05-24T14:34:48.000Z
dist/jobq.js
adleroliveira/jobQ
35e1a7473b96d336a52fbee9e81a75ae00f748fa
[ "MIT" ]
1
2016-11-17T22:23:29.000Z
2016-11-20T16:33:23.000Z
dist/jobq.js
adleroliveira/jobQ
35e1a7473b96d336a52fbee9e81a75ae00f748fa
[ "MIT" ]
2
2016-11-17T21:59:33.000Z
2020-05-24T14:35:22.000Z
var JobQ = /******/ (function(modules) { // webpackBootstrap /******/ // The module cache /******/ var installedModules = {}; /******/ // The require function /******/ function __webpack_require__(moduleId) { /******/ // Check if module is in cache /******/ if(installedModules[moduleId]) /******/ return installedModules[moduleId].exports; /******/ // Create a new module (and put it into the cache) /******/ var module = installedModules[moduleId] = { /******/ exports: {}, /******/ id: moduleId, /******/ loaded: false /******/ }; /******/ // Execute the module function /******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); /******/ // Flag the module as loaded /******/ module.loaded = true; /******/ // Return the exports of the module /******/ return module.exports; /******/ } /******/ // expose the modules object (__webpack_modules__) /******/ __webpack_require__.m = modules; /******/ // expose the module cache /******/ __webpack_require__.c = installedModules; /******/ // __webpack_public_path__ /******/ __webpack_require__.p = ""; /******/ // Load entry module and return exports /******/ return __webpack_require__(0); /******/ }) /************************************************************************/ /******/ ([ /* 0 */ /***/ (function(module, exports) { 'use strict'; var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } // Error constants var CONFIG_REQUIRED = 'Configuration Object Required'; var PROCESS_REQUIRED = 'required paramenter [process] must be a function'; var SOURCE_REQUIRED = 'Source is required to be an array, function, promise or stream'; var TYPE_PROCEED_ON_ERROR = 'parameter stopOnError must be a boolean'; var TYPE_EVENT_HANDLER = 'Event handlers must be functions'; var POOLING_REQUIRES_FUNCTION_SOURCE = 'Only Function source can be used with pooling'; var JobQueuer = function () { function JobQueuer(config) { _classCallCheck(this, JobQueuer); if (!config) throw new Error(CONFIG_REQUIRED); if (!config.process || typeof config.process !== 'function') throw new Error(PROCESS_REQUIRED); if (!config.source || this.getType(config.source) === 'invalid') throw new Error(SOURCE_REQUIRED); if (config.stopOnError && typeof config.stopOnError !== 'boolean') throw new Error(TYPE_PROCEED_ON_ERROR); this.events = {}; this.debug = config.debug; this.maxProceses = config.maxProceses >= 0 ? config.maxProceses : 1; this.process = config.process; this.stopOnError = config.stopOnError || false; this.sourceType = this.getType(config.source); if (this.sourceType === 'array') { this.source = config.source.slice(0); } else { this.source = config.source; } this.running = 0; this.jobsFinished = 0; this.jobErrors = 0; this.fillingJobs = false; this.autoincrementId = 0; this.status = 'stoped'; this.paused = false; this.poolingInterval = config.pooling >= 0 ? config.pooling : false; if (this.sourceType !== 'function' && this.sourceType !== 'promise' && this.poolingInterval !== false) throw new Error(POOLING_REQUIRES_FUNCTION_SOURCE); } _createClass(JobQueuer, [{ key: 'data', value: function data(_data) { var obj = { startTime: this.startTime, processed: this.jobsFinished, errors: this.jobErrors, maxProceses: this.maxProceses, stopOnError: this.stopOnError, sourceType: this.sourceType, status: this.status }; if (_data) { for (var key in _data) { if (_data.hasOwnProperty(key)) obj[key] = _data[key]; } } return obj; } }, { key: 'start', value: function start() { this.status = 'running'; this.startTime = new Date(); this.emit('start', this.data()); this.init(); } }, { key: 'pause', value: function pause() { if (this.status === 'running' || this.status === 'pooling') { this.paused = true; this.status = 'paused'; this.emit('pause', this.data()); } } }, { key: 'resume', value: function resume() { if (this.status !== 'running') { this.paused = false; this.status = 'running'; this.emit('resume', this.data()); this.fillJobs(); } } }, { key: 'getType', value: function getType(source) { return source ? Array.isArray(source) ? 'array' : source.then ? 'promise' : _typeof(source._readableState) === 'object' && typeof source.on === 'function' ? 'stream' : typeof source === 'function' ? 'function' : 'invalid' : 'invalid'; } }, { key: 'init', value: function init() { var _this = this; if (this.sourceType === 'promise') { this.log("Got promise source. Resolving"); this.source.then(function (data) { _this.sourceType = _this.getType(data); if (_this.sourceType === 'invalid') { throw new Error(SOURCE_REQUIRED); } else if (_this.sourceType !== 'function' && _this.sourceType !== 'promise') { if (_this.poolingInterval !== false) throw new Error(POOLING_REQUIRES_FUNCTION_SOURCE); _this.source = data.slice(0); } else { _this.source = data; } _this.init(); }).catch(function (err) { _this.processFinish(err); }); } else if (this.sourceType === 'stream') { this.log("Got stream source. Initializing"); this.initializeStream(); } else { this.log('Got ' + this.sourceType + ' source. Starting'); this.fillJobs(); } } }, { key: 'processFinish', value: function processFinish(err) { var _this2 = this; if (err) { this.emit('error', err); this.status = 'error'; } else { this.status = 'finished'; } if (this.poolingInterval === false) { this.emit('processFinish', this.data({ endTime: new Date() })); } else { this.status = 'pooling'; this.empty = false; this.emit('pooling', this.data()); setTimeout(function () { _this2.status = 'running'; _this2.fillJobs(); }, this.poolingInterval); } } }, { key: 'on', value: function on(event, handler) { this.events[event] = handler; return this; } }, { key: 'emit', value: function emit(event, payload) { if (event === 'error' && this.stopOnError) this.status = 'error'; this.log(event, payload); if (this.events[event]) this.events[event](payload); } }, { key: 'log', value: function log(type, data) { if (this.debug && console) console.log('[' + new Date() + '][' + type + ']', data); } }, { key: 'runningJobsCount', value: function runningJobsCount() { return this.running; } }, { key: 'runJob', value: function runJob(jobPromise) { var _this3 = this; this.running++; var jobId = ++this.autoincrementId; this.emit('jobRun', jobId); var next = function next() { var runningCount = --_this3.running; if (!runningCount && _this3.status === 'empty' || _this3.status === 'error') { _this3.status = 'finished'; return _this3.processFinish(); } _this3.fillJobs(); }; var jobStartTime = new Date(); jobPromise(function (err, result) { if (err) { _this3.emit('error', err); _this3.jobErrors++; } else if (result) { var jobEndTime = new Date(); _this3.emit('jobFinish', { jobId: jobId, jobStartTime: jobStartTime, jobEndTime: jobEndTime, result: result, jobsRunning: _this3.running }); _this3.jobsFinished++; } next(); }); } }, { key: 'fillJobs', value: function fillJobs() { var _this4 = this; if (this.fillingJobs) return; this.fillingJobs = true; var resolveJobValue = function resolveJobValue(jobValue, done) { try { var resolved = false; if (jobValue !== null) { var jobPromise = _this4.process(jobValue, function (err, value) { if (!resolved) done(err, value); }); if (jobPromise) { resolved = true; if (typeof jobPromise.then === 'function') { return jobPromise.then(function (data) { done(null, data); }).catch(done); } done(null, jobPromise); } } else { _this4.status = 'empty'; done(); } } catch (e) { done(e); } }; while (!this.paused && (this.maxProceses === 0 || this.running < this.maxProceses) && this.status === 'running' && (this.sourceType === 'array' && this.source.length || this.sourceType !== 'array')) { this.emit('jobFetch', { jobsRunning: this.running }); var job = function job(done) { var item = void 0; var resolved = false; if (_this4.sourceType === 'array') { item = _this4.source.splice(0, 1)[0]; if (!_this4.source.length) _this4.status = 'empty'; } else if (_this4.sourceType === 'stream') { _this4.waitForStreamData(function (err, jobValue) { // TODO: Error resolveJobValue(jobValue, done); }); } else { item = _this4.source(function (err, jobValue) { if (!resolved) { if (err) return done(err); resolveJobValue(jobValue, done); } }); } if (undefined !== item) { if (item && item.then && typeof item.then === 'function') { item.then(function (jobValue) { resolveJobValue(jobValue, done); }).catch(done); } else { if (item !== null) { resolved = true; resolveJobValue(item, done); } else { _this4.status = 'empty'; resolved = true; done(); } } } }; this.runJob(job); } this.fillingJobs = false; } }, { key: 'initializeStream', value: function initializeStream() { var _this5 = this; this.source.on('readable', function () { _this5.log('Stream ready. Starting'); _this5.streamEnded = false; _this5.fillJobs(); }); this.source.on('end', function () { _this5.streamEnded = true; }); // this.source.on('error', (err) => { // // TODO: Error handling // }) } }, { key: 'waitForStreamData', value: function waitForStreamData(done) { var _this6 = this; if (!this.streamEnded) { setTimeout(function () { var item = _this6.source.read(); if (item) { done(null, item); } else { _this6.waitForStreamData(done); } }, 0); } else { done(null, null); } } }]); return JobQueuer; }(); var JobQ = function () { function JobQ(options) { _classCallCheck(this, JobQ); this.instance = new JobQueuer(options); } _createClass(JobQ, [{ key: 'on', value: function on(event, handler) { this.instance.on(event, handler); return this; } }, { key: 'start', value: function start() { this.instance.start(); return this; } }, { key: 'pause', value: function pause() { this.instance.pause(); return this; } }, { key: 'resume', value: function resume() { this.instance.resume(); return this; } }, { key: 'runningJobsCount', value: function runningJobsCount() { return this.instance.runningJobsCount(); } }]); return JobQ; }(); module.exports = JobQ; /***/ }) /******/ ]);
32.326139
565
0.534941
c4e0f8aa8b47edaa7e930e9cee1c0710c201b77d
370
js
JavaScript
tests/window.js
drart/Kassemets
ee8a73eaca95b47d4746904f724f3ddf94bab5df
[ "MIT" ]
null
null
null
tests/window.js
drart/Kassemets
ee8a73eaca95b47d4746904f724f3ddf94bab5df
[ "MIT" ]
null
null
null
tests/window.js
drart/Kassemets
ee8a73eaca95b47d4746904f724f3ddf94bab5df
[ "MIT" ]
null
null
null
var mywindow = new JitterObject("jit.window","KassWindow"); // turn off depth testing... we're using blending instead: mywindow.depthbuffer = 0; mywindow.fsmenubar = 0; mywindow.hidecursor = 1; function fullscreen(v) // function to send the [jit.window] into fullscreen mode { messnamed("jitter", "cursor", !v); // turns the cursor off :) mywindow.fullscreen = v; }
30.833333
62
0.718919
c4e244e9aebd69c35652d14b1277239d1f01ce55
269
js
JavaScript
test/index.js
uriegel/web-pie-progress
00700205314d1e48a4d6c93219530aab5318d01a
[ "MIT" ]
null
null
null
test/index.js
uriegel/web-pie-progress
00700205314d1e48a4d6c93219530aab5318d01a
[ "MIT" ]
null
null
null
test/index.js
uriegel/web-pie-progress
00700205314d1e48a4d6c93219530aab5318d01a
[ "MIT" ]
null
null
null
import '../src/index.js'; const progress = document.getElementById("progress"); let value = 0.0; setInterval(() => { //progress.setAttribute("progress", (value++ / 10.0).toString()) progress.setProgress(value++ / 10.0); }, 30); //# sourceMappingURL=index.js.map
33.625
68
0.665428
c4e3360d7c7367a4a7c46404fa0a708bc18907fb
622
js
JavaScript
uiux/challenge-1/src/utils/axionsConfig.js
MehdiHamidi/amaze-us
ccefc6f157712c2cad47d869bdefa4bcd2868255
[ "Apache-2.0" ]
null
null
null
uiux/challenge-1/src/utils/axionsConfig.js
MehdiHamidi/amaze-us
ccefc6f157712c2cad47d869bdefa4bcd2868255
[ "Apache-2.0" ]
null
null
null
uiux/challenge-1/src/utils/axionsConfig.js
MehdiHamidi/amaze-us
ccefc6f157712c2cad47d869bdefa4bcd2868255
[ "Apache-2.0" ]
null
null
null
import axios from 'axios'; //Musixmatch.com does not support Access-Control-Allow-Origin const corsProxy = "https://cors-anywhere.herokuapp.com/"; const API_KEY = "&apikey=ac03815403318dc10776b6a4af982e89"; const PAGE_SIZE = "&page_size=50"; const baseURL = corsProxy + "http://api.musixmatch.com/ws/1.1"; const headers = { 'Access-Control-Allow-Origin': '*', }; const instance = axios.create({ headers, baseURL, }); instance.interceptors.request.use((request) => { request.url += PAGE_SIZE + API_KEY; return request; }, (error) => { return Promise.reject(error); }); export default instance;
24.88
63
0.697749
c4e3f705f9a5e2e5cbaa8442f6ddc6b7cf3950db
489
js
JavaScript
src/app/components/Featured.js
mabearnews/machronicle-react
141ee626071fc37d30a734534fef38118c57eaf8
[ "MIT" ]
null
null
null
src/app/components/Featured.js
mabearnews/machronicle-react
141ee626071fc37d30a734534fef38118c57eaf8
[ "MIT" ]
null
null
null
src/app/components/Featured.js
mabearnews/machronicle-react
141ee626071fc37d30a734534fef38118c57eaf8
[ "MIT" ]
null
null
null
import React from 'react/addons'; /* * @class Featured * @extends React.Component */ class Featured extends React.Component { /* * @method render * @returns {JSX} */ render () { // A set of four featured articles is passed in as "articles" var featuredArr = this.props.articles; return <div className="jumbotron"> <h1>Featured Articles go Here</h1> <p>This will be much more interesting in the future:wq</p> </div> } } export default Featured
18.807692
65
0.654397
c4e44d2238ca59eac98c30f1eec759ae5c1c1778
806
js
JavaScript
app/templates/main.controller.spec.js
dinodsaurus/generator-cobe-angular
502165ca532ef08f732d33c195d7a08563755192
[ "MIT" ]
8
2015-02-16T04:10:39.000Z
2017-01-29T13:50:15.000Z
app/templates/main.controller.spec.js
dinodsaurus/generator-cobe-angular
502165ca532ef08f732d33c195d7a08563755192
[ "MIT" ]
1
2015-08-18T18:40:07.000Z
2015-08-19T14:18:40.000Z
app/templates/main.controller.spec.js
dinodsaurus/generator-cobe-angular
502165ca532ef08f732d33c195d7a08563755192
[ "MIT" ]
null
null
null
"use strict"; describe("Main Conttroller tests", function(){ var scope,controller; beforeEach(module("<%= appname %>")); describe("List of awesome things", function () { beforeEach(inject(function($rootScope, $controller) { scope = $rootScope.$new(); controller = $controller("MainController as main", { $scope: scope }); })); it("should define more than 5 awesome things", inject(function() { expect(angular.isArray(scope.main.awesomeThings)).toBeTruthy(); expect(scope.main.awesomeThings.length > 5).toBeTruthy(); })); it("should have rank defined ", inject(function() { var rand = Math.floor((Math.random() * scope.main.awesomeThings.length)); expect(scope.main.awesomeThings[rand].rank).toBeDefined(); })); }); });
29.851852
79
0.640199
c4e50eb5039d254cf5d730e619859bb9a8729e64
253
js
JavaScript
src/repositories/UserRepository.js
MiguelS007/real-world
f2e695957c9b4a1e46714331d59fd575a8b45b52
[ "MIT" ]
null
null
null
src/repositories/UserRepository.js
MiguelS007/real-world
f2e695957c9b4a1e46714331d59fd575a8b45b52
[ "MIT" ]
null
null
null
src/repositories/UserRepository.js
MiguelS007/real-world
f2e695957c9b4a1e46714331d59fd575a8b45b52
[ "MIT" ]
null
null
null
import Client from "./Clients/AxiosClient"; export default { get() { return Client.get(`/user`); }, login(payload) { return Client.post(`/users/login`, payload); }, create(payload) { return Client.post(`/users/`, payload); } };
18.071429
48
0.612648
c4e59c5400a04b56b100b0af5d8462609e17dd55
647
js
JavaScript
luwut-site/src/main.js
Binlu/myFunc
9f9b9c81852fd77e6ddf2986dd12255771bd8151
[ "Apache-2.0" ]
null
null
null
luwut-site/src/main.js
Binlu/myFunc
9f9b9c81852fd77e6ddf2986dd12255771bd8151
[ "Apache-2.0" ]
null
null
null
luwut-site/src/main.js
Binlu/myFunc
9f9b9c81852fd77e6ddf2986dd12255771bd8151
[ "Apache-2.0" ]
null
null
null
'use strict'; import Vue from 'vue'; import routes from '@/router/routes'; import header from '@/components/header'; import footer from '@/components/footer'; import 'bootstrap/dist/js/bootstrap.min'; import 'bootstrap/dist/css/bootstrap.min.css'; // 共用 import common from '@/assets/js/common/common'; Vue.config.productionTip = false; new Vue({ el: '.js-app-box', router:routes, data(){ return { content_style:{ height:'400px' }, is_loaded:true } }, components:{ 'header-template':header, 'footer-template':footer }, mounted: function () { this.is_loaded = false; this.init(); }, methods:common })
17.486486
47
0.666151
c4e6769157e313733a2598fda765021284c03b60
1,987
js
JavaScript
packages/meeting-core-electron/src/meetingRoom/analytical/index.js
jjldxz/MeetingSample-Web
2ed086d40887a02ad59b55f324a25db2dfb97c49
[ "MIT" ]
8
2021-11-11T09:29:12.000Z
2021-11-16T06:54:02.000Z
packages/meeting-core-electron/src/meetingRoom/analytical/index.js
jjldxz/MeetingWeb
2ed086d40887a02ad59b55f324a25db2dfb97c49
[ "MIT" ]
null
null
null
packages/meeting-core-electron/src/meetingRoom/analytical/index.js
jjldxz/MeetingWeb
2ed086d40887a02ad59b55f324a25db2dfb97c49
[ "MIT" ]
4
2021-11-15T02:45:13.000Z
2021-11-15T03:43:41.000Z
import EventEmitter from 'wolfy87-eventemitter' import { ANALYTICAL_INTERVAL } from '../../common' export default class AnalyticalParser extends EventEmitter { constructor() { super() this._rtm = null this._rtc = null this._timer = null this._info = {} this._userInfo = null this._roomInfo = null this._sysInfo = null } init(opts = {}) { this._userInfo = opts.userInfo this._roomInfo = opts.roomInfo this._rtc = opts.rtc this._rtm = opts.rtm } getCommonInfo() { return { userInfo: { ...this._userInfo }, systemInfo: { ...this._sysInfo }, ...this._roomInfo } } setSystemInfo(info) { this._sysInfo = info const ret = this.getCommonInfo() this._rtm.sendMonitorData(ret) this.start() } getInfo() { let ret = this.getCommonInfo() if (this._rtc.networkQuality) { ret.networkState = { ...this._rtc.networkQuality } } if (this._rtc.clientState) { ret.clientState = { ...this._rtc.clientState } } if (this._rtc.appState) { ret.appState = { ...this._rtc.appState } } if (this._rtc.localVideoState) { ret.localVideoState = this._rtc.localVideoState } if (this._rtc.localAudioState) { ret.localAudioState = this._rtc.localAudioState } if (this._rtc.remoteVideoState) { ret.remoteVideoState = Object.keys(this._rtc.remoteVideoState).map( (k) => this._rtc.remoteVideoState[k] ) } if (this._rtc.remoteAudioState) { ret.remoteAudioState = Object.keys(this._rtc.remoteAudioState).map( (k) => this._rtc.remoteAudioState[k] ) } this._rtm.sendMonitorData(ret) } start() { if (!this._timer) { this._timer = setInterval(() => { this.getInfo() }, ANALYTICAL_INTERVAL) } } stop() { if (this._timer) { clearInterval(this._timer) this._timer = null } this._init = false } destroy() { this.stop() } }
24.530864
73
0.609965
c4e7269029f214514e3cf8b779292b1760d45112
1,153
js
JavaScript
core/cli/repl.js
aileen/Ghost
c46303cb2b0b18751f5043cb8c04c1422a684e9a
[ "MIT" ]
null
null
null
core/cli/repl.js
aileen/Ghost
c46303cb2b0b18751f5043cb8c04c1422a684e9a
[ "MIT" ]
null
null
null
core/cli/repl.js
aileen/Ghost
c46303cb2b0b18751f5043cb8c04c1422a684e9a
[ "MIT" ]
1
2021-10-11T09:24:59.000Z
2021-10-11T09:24:59.000Z
const Command = require('./command'); const chalk = require('chalk'); module.exports = class REPL extends Command { setup() { this.help('Launches a REPL environment with access to a configured db instance and models'); // this is only here to demo how to set a default value for an arg :) this.argument('--color', {type: 'string', defaultValue: 'yellow', hidden: true}); } initializeContext(context) { const models = require('../server/models'); const knex = require('../server/data/db/connection'); models.init(); context.models = models; context.m = models; context.knex = knex; context.k = knex; } async handle(argv = {}) { this.debug(chalk[argv.color]('== Ghost development REPL ==')); this.info(`a knex database instance is available as ${chalk.magenta('knex')}`); this.info(`bookshelf models are available as ${chalk.magenta('models')}`); const repl = require('repl'); const cli = repl.start('> '); this.initializeContext(cli.context); cli.on('reset', this.initializeContext); } };
34.939394
100
0.606245
c4e752abf2c0ea69d08ebf60b94db9904ec996ce
22
js
JavaScript
init.js
amariszi/amariszi-online
d0169722285d58f1b5733917cbe81b012f3138b0
[ "CC-BY-3.0" ]
null
null
null
init.js
amariszi/amariszi-online
d0169722285d58f1b5733917cbe81b012f3138b0
[ "CC-BY-3.0" ]
null
null
null
init.js
amariszi/amariszi-online
d0169722285d58f1b5733917cbe81b012f3138b0
[ "CC-BY-3.0" ]
null
null
null
File.eval("blink.js");
22
22
0.681818
c4e7dc51b98c054446a78c61dccfcb2f71cf16af
824
js
JavaScript
src/GfxTablet.js
jzitelli/WebVRApplication
73aa1ec807429997e239a55c171b96c2c605fb66
[ "MIT" ]
3
2016-12-09T06:30:10.000Z
2017-11-23T09:13:26.000Z
src/GfxTablet.js
jzitelli/WebVRApplication
73aa1ec807429997e239a55c171b96c2c605fb66
[ "MIT" ]
null
null
null
src/GfxTablet.js
jzitelli/WebVRApplication
73aa1ec807429997e239a55c171b96c2c605fb66
[ "MIT" ]
2
2017-11-13T11:24:33.000Z
2017-11-23T09:13:27.000Z
/* global THREE, GFXTABLET */ module.exports = ( function () { "use strict"; const INCH2METERS = 0.0254; function GfxTablet(xRes, yRes, width, height) { xRes = xRes || 2560; yRes = yRes || 1600; width = width || 8.5 * INCH2METERS; height = height || 5.25 * INCH2METERS; // set up WebSocket, paintable surface for GfxTablet: var gfxTabletStuff = GFXTABLET.addGfxTablet(xRes, yRes); // create VR visuals: var mesh = new THREE.Mesh(new THREE.PlaneBufferGeometry(1, 1), gfxTabletStuff.paintableMaterial); mesh.scale.x = width; mesh.scale.y = height; var cursor = gfxTabletStuff.cursor; cursor.scale.x = 0.002 / width; cursor.scale.y = 0.002 / height; cursor.position.z = 0.005; cursor.updateMatrix(); mesh.add(cursor); this.mesh = mesh; this.cursor = cursor; } return GfxTablet; } )();
29.428571
99
0.677184
c4e7e4ca58394cd5420a447460db67cc48d938fe
5,420
js
JavaScript
bundles/statistics/statsgrid2016/components/IndicatorParameters.js
okauppinen/oskari
225e0064b70b4699e1483d5a6473b417ba4263ff
[ "MIT" ]
null
null
null
bundles/statistics/statsgrid2016/components/IndicatorParameters.js
okauppinen/oskari
225e0064b70b4699e1483d5a6473b417ba4263ff
[ "MIT" ]
null
null
null
bundles/statistics/statsgrid2016/components/IndicatorParameters.js
okauppinen/oskari
225e0064b70b4699e1483d5a6473b417ba4263ff
[ "MIT" ]
null
null
null
// parses and shows indicator metadata/selectors /* { "id": "5", "regionsets": [6, 7], "source": { "fi": "Terveyden ja hyvinvoinnin laitos (THL)", "sv": "Institutet för hälsa och välfärd (THL)", "en": "Institute for Health and Welfare (THL)" }, "selectors": [{ "id": "sex", "allowedValues": ["male", "female", "total"] }, { "id": "year", "allowedValues": ["1991", "1992", "1993", "1994", "1995", "1996", "1997", "1998", "1999", "2000", "2001", "2002", "2003", "2004", "2005", "2006", "2007", "2008", "2009", "2010", "2011", "2012", "2013", "2014"] }], "description": { "fi": "Indikaattori ilmaisee kalenterivuoden aikana toimeentulotukea saaneiden 25-64-vuotiaiden osuuden prosentteina vastaavanikäisestä väestöstä. Väestötietona käytetään vuoden viimeisen päivän tietoa.<br /><br />Vuodesta 1991 lähtien tiedonkeruussa on kysytty viitehenkilön lisäksi myös puolison henkilötunnusta eli sukupuolittaiset tiedot saadaan vuodesta 1991alkaen. Viitehenkilöllä tarkoitetaan henkilöä, joka pääasiallisesti vastaa kotitalouden toimeentulosta.<p id=suhteutus>Väestösuhteutus on tehty THL:ssä käyttäen Tilastokeskuksen Väestötilaston tietoja.<\/p>", "sv": "Indikatorn visar den procentuella andelen 25-64-åriga mottagare av utkomststöd under kalenderåret av befolkningen i samma ålder (31.12).<p id=suhteutus>THL har relaterat uppgifterna till hela befolkningen på basis av uppgifterna i statistikcentralens befolkningsstatistik.<\/p>", "en": "The indicator gives the percentage of those who have received social assistance during the calendar year in the 25-64 age group. Population figures refer to the last day of the year. Since 1991, data have been collected on the spouse's personal identity code in addition to that of the reference person. In other words, data broken down by sex are available from 1991 onwards. Reference person is the person primarily responsible for the economic support of the household.<p id=suhteutus>Population proportions are calculated at THL based on the Population Statistics of Statistics Finland.<\/p>" }, "name": { "fi": "Toimeentulotukea saaneet 25 - 64-vuotiaat, % vastaavanikäisestä väestöstä", "sv": "25-64-åriga mottagare av utkomststöd, % av befolkningen i samma ålder", "en": "Social assistance recipients aged 25-64, as % of total population of same age" }, "public": true } */ Oskari.clazz.define('Oskari.statistics.statsgrid.IndicatorParameters', function(sandbox) { this.sb = sandbox; this.service = sandbox.getService('Oskari.statistics.statsgrid.StatisticsService'); }, { __templates : { main : _.template('<div class="stats-ind-params"></div>'), select : _.template('<div><label>${name}<select name="${name}" class="${clazz}"></select></label></div>'), option : _.template('<option value="${id}">${name}</option>'), data : _.template('<div><label style="font-weight:bold;">${name}</label><span style="display: inline-block; float: right; clear:both;">${data}</span></div>') }, clean : function() { if(!this.container) { return; } this.container.remove(); this.container = null; }, addMetadata : function(el, label, value) { if(!value) { // Nothing to show return; } el.append(this.__templates.data({ name : label, data : value })); }, indicatorSelected : function(el, datasrc, indId) { var me = this; this.clean(); var cont = jQuery(this.__templates.main()); this.container = cont; el.append(cont); var spinner = Oskari.clazz.create('Oskari.userinterface.component.ProgressSpinner'); spinner.insertTo(cont); spinner.start(); this.service.getIndicatorMetadata(datasrc, indId, function(err, indicator) { if(err) { // notify error!! return; } // show description for indicator me.addMetadata(cont, 'Name', Oskari.getLocalized(indicator.name)); me.addMetadata(cont, 'Source', Oskari.getLocalized(indicator.source)); me.addMetadata(cont, 'Description', Oskari.getLocalized(indicator.description)); // usable regions sets var availableSets = me.service.getRegionsets(indicator.regionsets); var regionsValue = _.map(availableSets, function(item) { return item.name; }).join(', '); if(!regionsValue) { regionsValue = 'No regions available for dataset'; } cont.append(me.__templates.data({ name : 'Regionsets', data : regionsValue })); // selections var selections = []; indicator.selectors.forEach(function(selector) { var select = me.__templates.select({ name : selector.id, clazz : 'stats-select-param-' + selector.id }); cont.append(select); var jqSelect = cont.find('.stats-select-param-' + selector.id); selector.allowedValues.forEach(function(val) { var opt = me.__templates.option({ id : val, name : val }); jqSelect.append(opt); }); jqSelect.chosen({ disable_search_threshold: 10 }); selections.push(jqSelect); }); var btn = Oskari.clazz.create('Oskari.userinterface.component.buttons.AddButton'); btn.setHandler(function() { var values = { datasource : datasrc, indicator : indId, selections : {} }; selections.forEach(function(select) { values.selections[select.attr('name')] = select.val() }); me.service.getStateService().addIndicator(datasrc, indId, values.selections); }); btn.insertTo(cont); spinner.stop(); }); } });
43.015873
605
0.689483
c4e7fa227ea476cdb6bfbe8f383b51f474b7e089
1,168
js
JavaScript
gulpfile/extra/wp/theme.js
ndinc/starter
713914bb6ebe39c40221add327393cdd9e8699bc
[ "MIT" ]
null
null
null
gulpfile/extra/wp/theme.js
ndinc/starter
713914bb6ebe39c40221add327393cdd9e8699bc
[ "MIT" ]
null
null
null
gulpfile/extra/wp/theme.js
ndinc/starter
713914bb6ebe39c40221add327393cdd9e8699bc
[ "MIT" ]
null
null
null
var config = require('../../config') var options = require('./options') var gulp = require('gulp') var exec = require('gulp-exec'); var package = require('../../../package.json') var gulpSequence = require('gulp-sequence') var themeTask = function() { return gulp.src('') .pipe(exec('rm -rf ' + options.download.path + '/wp-content/themes/twenty*' , config.tasks.exec)) .pipe(exec('rm -rf ' + options.download.path + '/wp-content/themes/' + package.name , config.tasks.exec)) .pipe(exec('cp -rf ./gulpfile/extra/wp/starter-theme ' + options.download.path + '/wp-content/themes', config.tasks.exec)) .pipe(exec('mv -f ' + options.download.path + '/wp-content/themes/starter-theme ' + options.download.path + '/wp-content/themes/' + package.name , config.tasks.exec)) .pipe(exec('wp theme activate ' + package.name + ' --path=' + options.download.path, config.tasks.exec)) .on('end', function(){ console.log('end'); }) } gulp.task('wp:theme', themeTask) var starterTask = function(cb) { gulpSequence('wp:theme','wp:production','develop', cb) } gulp.task('wp:starter', starterTask) module.exports = themeTask
41.714286
170
0.651541
c4e82e7cc9f65b0aafd8b172278e514f21c3ec45
1,125
js
JavaScript
lib/browsers-binaries-standalone/test.js
DenisKudelin/browsers-binaries-standalone
3a26933b9938459c5629449b1cb671c2d5d660e3
[ "MIT" ]
null
null
null
lib/browsers-binaries-standalone/test.js
DenisKudelin/browsers-binaries-standalone
3a26933b9938459c5629449b1cb671c2d5d660e3
[ "MIT" ]
null
null
null
lib/browsers-binaries-standalone/test.js
DenisKudelin/browsers-binaries-standalone
3a26933b9938459c5629449b1cb671c2d5d660e3
[ "MIT" ]
null
null
null
"use strict"; var Browsers_1 = require("./Browsers/Browsers"); exports.Platform = Browsers_1.Platform; exports.Chromium = Browsers_1.Chromium; exports.Firefox = Browsers_1.Firefox; /*install({ firefox: { version: "47.0.1", platform: "Win_x64", language: "en-US" // default; }, chromium: { version: "54.0.2840.71", platform: "Win_x64" } });*/ /*let chromeTest = [(() => { let browser = new Chromium(Platform.Win_x64, "54.0.2840.71"); return browser.install(); }), (() => { let browser = new Chromium(Platform.Linux_x64, "54.0.2840.71"); return browser.install(); }), (() => { let browser = new Chromium(Platform.Mac, "54.0.2840.71"); return browser.install(); })]; let firefoxTest = [(() => { let browser = new Firefox(Platform.Win_x64, "49.0"); return browser.install(); }), (() => { let browser = new Firefox(Platform.Linux_x64, "40.0"); return browser.install(); }), (() => { let browser = new Firefox(Platform.Mac, "30.0"); return browser.install(); })];*/ //Promise.each(firefoxTest, x => x()); //firefoxTest[2]();
25.568182
67
0.593778
c4e8564ec8a6979eb4d5e7ee27edc806fa956ed7
475
js
JavaScript
packages/classnames-loader/src/index.js
myntra/uikit
740fc3a2b8140d9d4b16920ba6183ae207117a84
[ "MIT" ]
8
2021-11-03T12:15:02.000Z
2022-03-30T11:09:30.000Z
packages/classnames-loader/src/index.js
myntra/uikit
740fc3a2b8140d9d4b16920ba6183ae207117a84
[ "MIT" ]
null
null
null
packages/classnames-loader/src/index.js
myntra/uikit
740fc3a2b8140d9d4b16920ba6183ae207117a84
[ "MIT" ]
1
2022-03-30T07:03:00.000Z
2022-03-30T07:03:00.000Z
function ClassNamesLoader(source) { return source } ClassNamesLoader.pitch = function(remainingRequest) { if (this.cacheable) this.cacheable() return ` const { classnames } = require('@myntra/uikit-utils'); const locals = require(${JSON.stringify('-!' + remainingRequest)}); function css() { return classnames.apply(null, arguments).use(locals); } module.exports = { default: css } module.exports.__esModule = true `.trimLeft() } module.exports = ClassNamesLoader
23.75
72
0.730526
c4e9b99a103e78c0f01800ce646fc98fec6e40bb
69
js
JavaScript
__tests__/integration/setup.js
XcooBee/xcoobee-js-sdk
a3dae976f1e19c77ec8032333a83e72e44b944ed
[ "Apache-2.0" ]
null
null
null
__tests__/integration/setup.js
XcooBee/xcoobee-js-sdk
a3dae976f1e19c77ec8032333a83e72e44b944ed
[ "Apache-2.0" ]
73
2019-01-17T17:02:38.000Z
2022-03-21T08:05:38.000Z
__tests__/integration/setup.js
XcooBee/xcoobee-js-sdk
a3dae976f1e19c77ec8032333a83e72e44b944ed
[ "Apache-2.0" ]
3
2019-04-11T12:15:14.000Z
2020-06-02T17:35:39.000Z
const Utils = require('../lib/Utils'); Utils.loadEnv(__dirname);
17.25
39
0.666667
c4edfc2981373625554303e94730e9116df70c3a
1,043
js
JavaScript
research/2018-assets/2018-11-prototype/stacks/src/module/evocate.js
joel-ld-esdc/wet-boew-documentation
13ec6b8cc30381ede6e939625ac913cb58785980
[ "MIT" ]
4
2017-12-31T23:42:16.000Z
2021-04-01T04:21:36.000Z
research/2018-assets/2018-11-prototype/stacks/src/module/evocate.js
joel-ld-esdc/wet-boew-documentation
13ec6b8cc30381ede6e939625ac913cb58785980
[ "MIT" ]
19
2017-01-23T17:37:13.000Z
2020-11-06T03:07:23.000Z
research/2018-assets/2018-11-prototype/stacks/src/module/evocate.js
joel-ld-esdc/wet-boew-documentation
13ec6b8cc30381ede6e939625ac913cb58785980
[ "MIT" ]
25
2016-07-18T14:51:21.000Z
2020-10-15T03:36:32.000Z
/** * timer.js - a timer module that will create a repetative timer on an element * @returns {void} */ define( [ "module/core/object", "module/element" ], function( ObjectUtil , ElementUtil) { function a11yClick( event ) { if ( event.type === "click" ) { return true; } if ( event.type === "keypress" ) { let code = event.charCode || event.keyCode; if ( ( code === 32 ) || ( code === 13 ) ) { return true; } } return false; } function handle( $elm, selector, options ) { let properties = Object.assign({ func: "show" }, options ), children = ElementUtil.nodes( $elm, selector ); ElementUtil.addListener( $elm, "click keypress",function( event ){ if ( a11yClick( event ) ) { for(let i = 0, length = children.length; i < length; i++){ console.log( children[i] ); children[i][ properties.func ](); } } }); } return { handle: handle }; } );
22.191489
89
0.516779
c4ee605bd7c12d4acc965c488281b77f0632bd0e
363
js
JavaScript
Helm/Routes/Post.js
Jash271/Cloud
1e1a3d87cfbdfc55bf192239dc314b3a3a6f8d56
[ "Apache-2.0" ]
null
null
null
Helm/Routes/Post.js
Jash271/Cloud
1e1a3d87cfbdfc55bf192239dc314b3a3a6f8d56
[ "Apache-2.0" ]
null
null
null
Helm/Routes/Post.js
Jash271/Cloud
1e1a3d87cfbdfc55bf192239dc314b3a3a6f8d56
[ "Apache-2.0" ]
null
null
null
const express = require('express'); const router = express.Router(); const { Update_Post, create_post, Get_Posts, Get_One_Post, Delete_Post, } = require('../Controller/Post'); router.route('/post').post(create_post).get(Get_Posts); router .route('/post/:id') .put(Update_Post) .get(Get_One_Post) .delete(Delete_Post); module.exports = router;
19.105263
55
0.699725
c4ee9bf97c4e629aed61a60ff65d3ca16ed3633b
3,984
js
JavaScript
test/index.js
MightyAlex200/hc-social-collaboration-example
03506835875d403f741f435d2dbd3b083b3809cd
[ "MIT" ]
1
2019-04-27T15:17:30.000Z
2019-04-27T15:17:30.000Z
test/index.js
MightyAlex200/hc-social-collaboration-example
03506835875d403f741f435d2dbd3b083b3809cd
[ "MIT" ]
12
2019-04-30T02:18:27.000Z
2022-02-26T10:53:48.000Z
test/index.js
MightyAlex200/hc-social-collaboration-example
03506835875d403f741f435d2dbd3b083b3809cd
[ "MIT" ]
1
2019-04-20T19:35:36.000Z
2019-04-20T19:35:36.000Z
// This test file uses the tape testing framework. // To learn more, go here: https://github.com/substack/tape const { Config, Scenario } = require('@holochain/holochain-nodejs'); Scenario.setTape(require('tape')); const dnaPath = './dist/hc-social-collaboration-example.dna.json'; const agentAlice = Config.agent('alice'); const dna = Config.dna(dnaPath); const instanceAlice = Config.instance(agentAlice, dna); const scenario = new Scenario([instanceAlice]); scenario.runTape('test', async (t, { alice }) => { // Test `add_skill` const skill_addr = await alice.callSync('socialcollaboration', 'add_skill', { skill: 'programming' }); t.deepEquals(skill_addr, { Ok: 'QmVDar5WaMc4af2sCzrx2i3LxttAddLeTw19qW8oRL2buK' }, 'skills can be added'); // Test `get_my_skills` (also tests `get_skills`) const skills = await alice.callSync('socialcollaboration', 'get_my_skills', {}); t.deepEquals(skills, { Ok: ['programming'] }, 'skills are stored'); // Test `create_thread` const thread_addr = await alice.callSync('socialcollaboration', 'create_thread', { title: 'test thread', utc_unix_time: 0, required_skills: ['programming'] }); t.deepEquals(thread_addr, { Ok: 'QmUWrNGG9ZMX4D3BFxPbVTTFFKZn8veVb7LP6ETV8o6reM' }, 'threads can be made'); // Test `get_thread` const thread = await alice.callSync('socialcollaboration', 'get_thread', { address: thread_addr.Ok, }); t.deepEquals( thread, { Ok: { title: 'test thread', timestamp: '1970-01-01T00:00:00+00:00', creator: 'HcScjwO9ji9633ZYxa6IYubHJHW6ctfoufv5eq4F7ZOxay8wR76FP4xeG9pY3ui' } }, 'threads can be read' ); // Test `get_required_skills` const required_skills = await alice.callSync('socialcollaboration', 'get_required_skills', { thread: thread_addr.Ok, }); t.deepEquals(required_skills, { Ok: ['programming'] }, 'threads have required skills'); // Test `create_post` const post_addr = await alice.callSync('socialcollaboration', 'create_post', { content: 'test post', utc_unix_time: 0, thread: thread_addr.Ok, }); t.deepEquals(post_addr, { Ok: 'QmZiFNrgtukQED6x7SF6yFNXYsU8x8WFoQhVXuDbSqEhPd' }, 'posts can be made on threads'); // Test `get_thread_posts` const thread_posts = await alice.callSync('socialcollaboration', 'get_thread_posts', { thread: thread_addr.Ok, }); t.deepEquals( thread_posts, { Ok: [ { content: 'test post', timestamp: '1970-01-01T00:00:00+00:00', creator: 'HcScjwO9ji9633ZYxa6IYubHJHW6ctfoufv5eq4F7ZOxay8wR76FP4xeG9pY3ui' } ] }, 'posts can be read from threads', ); // Test `get_threads` const threads = await alice.callSync('socialcollaboration', 'get_threads', {}); t.deepEquals( threads, { Ok: { links: [{ address: thread_addr.Ok, headers: [], tag: '' }] } }, 'threads can be found' ); // Test `get_relevant_threads` const relevant_threads = await alice.callSync('socialcollaboration', 'get_relevant_threads', {}); t.deepEquals( relevant_threads, { Ok: [thread_addr.Ok] }, 'relevant threads can be found' ); // Test `remove_skill` const skill_removed = await alice.callSync('socialcollaboration', 'remove_skill', { skill: 'programming' }); t.deepEquals(skill_removed, { Ok: null }, 'skills can be removed'); // Test `get_username` const username = await alice.callSync( 'socialcollaboration', 'get_username', { agent_address: 'HcScjwO9ji9633ZYxa6IYubHJHW6ctfoufv5eq4F7ZOxay8wR76FP4xeG9pY3ui' } ); t.deepEquals(username, { Ok: 'alice' }, 'usernames can be retrieved from agent addresses') });
36.888889
118
0.630271
c4eea65791a6515aa6e60f30fceb0e7cbee7c59d
284
js
JavaScript
frontend/src/config.js
sl/mbta-analysis
e75e89e68428c49c945564395a5524e830454819
[ "MIT" ]
null
null
null
frontend/src/config.js
sl/mbta-analysis
e75e89e68428c49c945564395a5524e830454819
[ "MIT" ]
null
null
null
frontend/src/config.js
sl/mbta-analysis
e75e89e68428c49c945564395a5524e830454819
[ "MIT" ]
null
null
null
const configurations = { development: { backendAPI: 'http://localhost:5000/api' }, production: { backendAPI: 'https://mbta-analysis.herokuapp.com/api' }, }; const env = process.env.NODE_ENV || 'development'; const config = configurations[env]; export default config;
21.846154
57
0.690141
c4efd71e4a1cc11d4af0d9f06df900c709a1c762
656
js
JavaScript
lib/relations/HtmlMetaRefresh.js
vineetit1991/assetgraph
30181f2f38c4a3a5f2e36715a1311d75b1b3d1df
[ "BSD-3-Clause" ]
null
null
null
lib/relations/HtmlMetaRefresh.js
vineetit1991/assetgraph
30181f2f38c4a3a5f2e36715a1311d75b1b3d1df
[ "BSD-3-Clause" ]
6
2021-03-09T10:50:59.000Z
2022-02-26T14:46:21.000Z
lib/relations/HtmlMetaRefresh.js
vineetit1991/assetgraph
30181f2f38c4a3a5f2e36715a1311d75b1b3d1df
[ "BSD-3-Clause" ]
null
null
null
const HtmlRelation = require('./HtmlRelation'); class HtmlMetaRefresh extends HtmlRelation { get href() { const content = this.node.getAttribute('content'); const matchContent = typeof content === 'string' && content.match(/url=\s*(.*?)\s*$/i); if (matchContent) { return matchContent[1]; } } set href(href) { this.node.setAttribute( 'content', this.node.getAttribute('content').replace(/url=.*?/i, `url=${href}`) ); } attach(position, adjacentRelation) { throw new Error('Not implemented'); } detach() { throw new Error('Not implemented'); } } module.exports = HtmlMetaRefresh;
21.866667
74
0.623476
c4f0554dbd63637e4623008f2bc5aad8e98117cb
984
js
JavaScript
frontend/soccer-manager/src/transfer/Transfer.js
FabiCorp/soccer-manager
17326d264e6cb7344f9a97124f927c0c8d44ab01
[ "MIT" ]
1
2020-08-28T09:10:56.000Z
2020-08-28T09:10:56.000Z
frontend/soccer-manager/src/transfer/Transfer.js
FabiCorp/soccer-manager
17326d264e6cb7344f9a97124f927c0c8d44ab01
[ "MIT" ]
null
null
null
frontend/soccer-manager/src/transfer/Transfer.js
FabiCorp/soccer-manager
17326d264e6cb7344f9a97124f927c0c8d44ab01
[ "MIT" ]
null
null
null
import React from 'react'; import Button from '@material-ui/core/Button'; import { makeStyles } from '@material-ui/core/styles'; import LeftSearchContainer from './LeftSearchContainer'; import MidSearchContainer from './MidSearchContainer'; import RightSearchContainer from './RightSearchContainer'; const useStyles = makeStyles(() => ({ startSearchContainer: { gridRow: '3', gridColumn: '10', marginTop: '20px', marginLeft: '20px', }, startSearchButton: { width: '100px', height: '40px', } })); const Transfer = _ => { const classes = useStyles(); return ( <> <LeftSearchContainer/> <MidSearchContainer/> <RightSearchContainer/> <div className={classes.startSearchContainer}> <Button variant="contained" color="secondary" className={classes.startSearchButton}> Search </Button> </div> </> ) } export default Transfer;
25.894737
96
0.619919
c4f1e5c32b116e350d35a0d9bc5619e46f9d4c3f
20,554
js
JavaScript
platforms/ios/www/js/services.js
jlagr/EnRed
d37131ab155bb1520b6ad7b6d1bd377abe58cfcb
[ "Apache-2.0" ]
null
null
null
platforms/ios/www/js/services.js
jlagr/EnRed
d37131ab155bb1520b6ad7b6d1bd377abe58cfcb
[ "Apache-2.0" ]
null
null
null
platforms/ios/www/js/services.js
jlagr/EnRed
d37131ab155bb1520b6ad7b6d1bd377abe58cfcb
[ "Apache-2.0" ]
null
null
null
angular.module('EnRed.services', []) .service('AuthService', function($q, $http, USER_ROLES, API_ENDPOINT) { var LOCAL_TOKEN_KEY = 'EnRedToken'; var LOCAL_USER_EMAIL = 'EnRedUserEmail'; var useremail = ''; var username = ''; var userempresa = ''; var usermovil = ''; var userproveedorMovil = ''; var isAuthenticated = false; var role = ''; var authToken; function loadUserCredentials() { var token = window.localStorage.getItem(LOCAL_TOKEN_KEY); if (token) { useCredentials(token); } } function storeUserCredentials(data, token) { window.localStorage.setItem(LOCAL_TOKEN_KEY, token); if(data != undefined){ window.localStorage.setItem(LOCAL_USER_EMAIL, data.email) } useCredentials(data, token); } function useCredentials(data, token) { isAuthenticated = true; authToken = token; useremail = data.email; username = data.nombre; userempresa = data.empresa; usermovil = data.movil; userproveedorMovil = data.proveedorMovil; if (data.rol == 'admin') { role = USER_ROLES.admin } if (data.rol == 'worker') { role = USER_ROLES.worker } if (data.rol == 'user') { role = USER_ROLES.user } // Set the token as header for all requests $http.defaults.headers.common['X-Auth-Token'] = token; } function updateUserData(nombre, email, movil, proveedorMovil){ //Cuando el usuario actualiza sus datos, se refrescan en los valores globales useremail = email; username = nombre; usermovil = movil; userproveedorMovil = proveedorMovil; } function destroyUserCredentials() { authToken = undefined; username = ''; useremail = ''; usermovil = ''; userproveedorMovil = ''; userempresa = ''; isAuthenticated = false; $http.defaults.headers.common['X-Auth-Token'] = undefined; window.localStorage.removeItem(LOCAL_TOKEN_KEY); } var login = function(email, pw) { return $q(function(resolve, reject) { //Crea el JSON con el formulario var formData = {'p' : 'login', 'email' : email, 'password' : pw}; $http.post(API_ENDPOINT.url,formData).then( function (response) { //console.log(response); if (!response.data.success) { reject(response.data.msg); } else { storeUserCredentials(response.data.data, response.data.token); resolve(true); }; }, function (err) { console.error(err.data.msg); reject(err.data.msg); }); }); }; var logout = function() { destroyUserCredentials(); }; var isAuthorized = function(authorizedRoles) { if (!angular.isArray(authorizedRoles)) { authorizedRoles = [authorizedRoles]; } return (isAuthenticated && authorizedRoles.indexOf(role) !== -1); }; loadUserCredentials(); return { login: login, logout: logout, isAuthorized: isAuthorized, updateUserData: updateUserData, isAuthenticated: function() {return isAuthenticated;}, username: function() {return username;}, useremail: function() {return useremail;}, role: function() {return role;}, userempresa: function() {return userempresa;}, usermovil: function() {return usermovil;}, userproveedorMovil: function() {return userproveedorMovil;} }; }) .service('AdminService', function ($q, $http, API_ENDPOINT, AuthService, $state) { var loadAllUsers = function() { return $q(function(resolve, reject) { //Crea el JSON con el formulario var formData = {'p' : 'users', 'command' : 'getAll'}; $http.post(API_ENDPOINT.url,formData).then( function (response) { if (!response.data.success) { reject(response.data.msg); } else { resolve(response.data.result); }; }, function (err) { if(err.status == 401){ //Sesion expiró AuthService.logout(); $state.go('login'); reject("Su sesión ha caducado.");HTMLQuoteElement } else{ reject(err.data.msg); } }); }); }; var addUser = function (nombre,email,movil,proveedorMovil,pw){ return $q(function(resolve, reject) { //Crea el JSON con el formulario var formData = {'p' : 'public', 'command':'add','nombre':nombre, 'email' : email, 'movil':movil, 'proveedorMovil':proveedorMovil, 'password' : pw}; $http.post(API_ENDPOINT.url,formData).then( function (response) { //console.log(response); if (!response.data.success) { reject(response.data.msg); } else { resolve(true); } }, function (err) { if(err.data.msg != undefined){ reject(err.data.msg); return false; } if(err.status == 401){ //Sesion expiró AuthService.logout(); $state.go('login'); reject("Su sesión ha caducado."); } else{ reject(err.data.msg); } }); }); } var getAppUser = function(userId) { return $q(function(resolve, reject) { //Crea el JSON con el formulario var formData = {'p' : 'users', 'command':'getUser', 'id':userId}; $http.post(API_ENDPOINT.url,formData).then( function (response) { //console.log(response); if (!response.data.success) { reject(response.data.msg); } else { resolve(response.data.result); } }, function (err) { if(err.status == 401){ //Sesion expiró AuthService.logout(); $state.go('login'); reject("Su sesión ha caducado."); } else{ reject(err.data.msg); } }); }); } var getEmpresas = function() { return $q(function(resolve, reject) { //Crea el JSON con el formulario var formData = {'p' : 'users', 'command':'getEmpresas'}; $http.post(API_ENDPOINT.url,formData).then( function (response) { if (!response.data.success) { reject(response.data.msg); } else { resolve(response.data.result); } }, function (err) { if(err.status == 401){ //Sesion expiró AuthService.logout(); $state.go('login'); reject("Su sesión ha caducado."); } else{ reject(err.data.msg); } }); }); } var updateUser = function(id, empresa, rol, activo, email, nombre){ var valRol = 3; var valActivo = 0; return $q(function(resolve, reject) { //Crea el JSON con el formulario switch (rol){ case "Administrador": valRol = 1; break; case "Trabajador": valRol = 2; break; } if(activo){ valActivo = 1; } var formData = {'p' : 'users', 'command':'updateFromAdmin','id':id,'empresa':empresa,'rol':valRol, 'activo':valActivo, 'email': email, 'nombre': nombre}; $http.post(API_ENDPOINT.url,formData).then( function (response) { if (!response.data.success) { reject(false); } else { resolve(true); } }, function (err) { if(err.status == 401){ //Sesion expiró AuthService.logout(); $state.go('login'); reject("Su sesión ha caducado."); } else{ reject(err.data); } }); }); }; var validaEmail = function validaEmail(email) { var re = /^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/; var result = re.test(email.toLowerCase()); return result; }; var validaPassword = function validaPassword(password) { var passw = /^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)[a-zA-Z\d]{8,}$/; var result = passw.test(password); return result; } var resetPassword = function(email){ return $q(function(resolve, reject) { //Crea el JSON con el formulario var formData = {'p' : 'public', 'command':'requestPasswordChange','email':email}; $http.post(API_ENDPOINT.url,formData).then( function (response) { if (!response.data.success) { reject(false); } else { resolve(true); } }, function (err) { if(err.status == 401){ //Sesion expiró AuthService.logout(); $state.go('login'); reject("Su sesión ha caducado."); } else{ reject(err.data); } }); }); }; var changePassword = function(password,token){ return $q(function(resolve, reject) { //Crea el JSON con el formulario var formData = {'p' : 'public', 'command':'updatePassword','password':password,'token':token}; $http.post(API_ENDPOINT.url,formData).then( function (response) { if (!response.data.success) { reject(false); } else { resolve(true); } }, function (err) { if(err.data.msg != undefined){ reject(err.data.msg); } if(err.status == 401){ //Sesion expiró reject("El código no es válido, solicite uno nuevo."); } else{ reject(err.data); } }); }); } return { loadAllUsers: loadAllUsers, addUser: addUser, getAppUser: getAppUser, getEmpresas: getEmpresas, updateUser: updateUser, validaEmail: validaEmail, validaPassword: validaPassword, resetPassword: resetPassword, changePassword: changePassword }; }) //End AdminService .service('UserService', function ($q, $http, API_ENDPOINT){ var updateAccount = function(nombre, email, movil, proveedorMovil){ return $q(function(resolve, reject) { //Crea el JSON con el formulario var formData = {'p' : 'users', 'command':'updateAccount','nombre':nombre, 'email' : email, 'movil':movil, 'proveedorMovil':proveedorMovil}; $http.post(API_ENDPOINT.url,formData).then( function (response) { //console.log(response); if (!response.data.success) { reject(response.data.msg); } else { resolve(true); } }, function (err) { if(err.data.msg != undefined){ reject(err.data.msg); return false; } if(err.status == 401){ //Sesion expiró AuthService.logout(); $state.go('login'); reject("Su sesión ha caducado."); } else{ reject(err.data.msg); } }); }); } //End updateAccount return { updateAccount: updateAccount }; }) //End UserService .service('MsgService', function () { return { all: function ($http) { //var deferred = $q.defer(); //var promise = deferred.promise; var mensajes = []; var endpoint = 'http://enreddgo.com.mx/api/notificaciones.php'; $http.get(endpoint).then( function (response) { console.log('get', response); if (response.data[0] === 'error') { //User.message = response.data[1]; //deferred.reject(response.data[1]); } else { //Mensajes = response.data; mensajes = response.data; //deferred.resolve(response.data); }; }, function (data) { // Handle error console.log('get error', data); //deferred.reject('Error de login'); }) //promise.success = function (fn) { // promise.then(fn); // return promise; //} //promise.error = function (fn) { // promise.then(null, fn); // return promise; //} return mensajes; } } }) .factory('testFac', function ($http) { var endpoint = 'http://enreddgo.com.mx/api/notificaciones.php'; return { all: function() {$http.get(endpoint)} } }) .factory('Tickets', function() { // Some fake testing data var tickets = [{ id: 1, titulo: 'Cable desconectado', fecha: '01/Ene/2018', reporto: 'jlagr', estatus: 'abierto', update: '01/Ene/2018', descripcion: 'Esta es la descripción detallada del problema', comentarios: 'Aquí van los comentarios de quien atendió el ticket' }, { id: 2, titulo: 'Poste caido', fecha: '05/Ene/2018', reporto: 'Juan Pérez', estatus: 'En Proceso', update: '06/Ene/2018', descripcion: 'Esta es la descripción detallada del problema', comentarios: 'Aquí van los comentarios de quien atendió el ticket' }, { id: 3, titulo: 'No responde el enlace', fecha: '06/Ene/2018', reporto: 'Agustín González', estatus: 'Cerrado', update: '08/Ene/2018', descripcion: 'Esta es la descripción detallada del problema', comentarios: 'Aquí van los comentarios de quien atendió el ticket' }, { id: 4, titulo: 'Reporte de prueba', fecha: '10/Ene/2018', reporto: 'Javier Ramírez', estatus: 'abierto', update: '10/Ene/2018', descripcion: 'Esta es la descripción detallada del problema', comentarios: 'Aquí van los comentarios de quien atendió el ticket' }, { id: 5, titulo: 'No tengo nada que hacer', fecha: '01/Febrero/2018', reporto: 'Daniel López', estatus: 'abierto', update: '01/Feb/2018', descripcion: 'Esta es la descripción detallada del problema', comentarios: 'Aquí van los comentarios de quien atendió el ticket' }]; return { all: function() { return tickets; }, get: function (ticketId) { for (var i = 0; i < tickets.length; i++) { if (tickets[i].id === parseInt(ticketId)) { return tickets[i]; } } return null; } }; }) .factory('User', function () { return { data: { empresa: '', nombre: '', mail: '', movil: '', rol: '' } } }) .factory('appUsers', function(){ var appUser = [{ id: 1, nombre: 'Usuario1', email: 'usuario1@enreddgo.com.mx', empresa: 'Una Empresa', movil: '6188253763', proveedorMovil: 'AT&T', rol: 'worker', activo: '0' }, { id: 2, nombre: 'Usuario2', email: 'usuario2@enreddgo.com.mx', empresa: 'Otra Empresa', movil: '3332014498', proveedorMovil: 'Telcel', rol: 'user', activo: '1' }, { id: 3, nombre: 'Usuario3', email: 'usuario3@enreddgo.com.mx', empresa: 'Mas Empresas', movil: '3332409877', proveedorMovil: 'Otro', rol: 'admin', activo: '0' }]; return { all: function() { return appUser; }, get: function (Id) { for (var i = 0; i < appUser.length; i++) { if (appUser[i].id === parseInt(Id)) { return appUser[i]; } } return null; } }; }) .factory('Mensajes', function () { var mensajes = [{ id: 1, titulo: 'Titulo del primer mensaje', mensaje: 'Primer mensaje de prueba', url: 'google.com', fecha: '01/Ene/2018' }, { id: 2, titulo: 'Segundo mensaje', mensaje: 'Este es el texto del segundo mensaje', url: '', fecha: '01/Ene/2018' }, { id: 3, titulo: 'Invitación', mensaje: 'Visita nuestro sitio web en', url: 'enreddgo.com.mx', fecha: '01/Ene/2018' }]; return { all: function () { return mensajes; }, remove: function (mensaje) { chats.splice(chats.indexOf(mensaje), 1); }, get: function (mensajeId) { for (var i = 0; i < mensajes.length; i++) { if (mensajes[i].id === parseInt(mensajeId)) { return mensajes[i]; } } return null; } }; }) .factory('Chats', function() { // Might use a resource here that returns a JSON array // Some fake testing data var chats = [{ id: 0, name: 'Ben Sparrow', lastText: 'You on your way?', face: 'img/ben.png' }, { id: 1, name: 'Max Lynx', lastText: 'Hey, it\'s me', face: 'img/max.png' }, { id: 2, name: 'Adam Bradleyson', lastText: 'I should buy a boat', face: 'img/adam.jpg' }, { id: 3, name: 'Perry Governor', lastText: 'Look at my mukluks!', face: 'img/perry.png' }, { id: 4, name: 'Mike Harrington', lastText: 'This is wicked good ice cream.', face: 'img/mike.png' }]; return { all: function() { return chats; }, remove: function(chat) { chats.splice(chats.indexOf(chat), 1); }, get: function(chatId) { for (var i = 0; i < chats.length; i++) { if (chats[i].id === parseInt(chatId)) { return chats[i]; } } return null; } }; });
31.670262
172
0.45271
c4f217acbc2a5e47a1ea679c1a2d9475b7ca3c70
5,792
js
JavaScript
public/projects/JavaScript_Avance_my_maps/js/map.js
tao-key/portfolio
bb5e00731e0a1d8d4b01cde63a490cdfb66fde58
[ "MIT" ]
null
null
null
public/projects/JavaScript_Avance_my_maps/js/map.js
tao-key/portfolio
bb5e00731e0a1d8d4b01cde63a490cdfb66fde58
[ "MIT" ]
null
null
null
public/projects/JavaScript_Avance_my_maps/js/map.js
tao-key/portfolio
bb5e00731e0a1d8d4b01cde63a490cdfb66fde58
[ "MIT" ]
null
null
null
var map; var panel; var initMap; var calculate; var direction; var google; initMap = function(){ var latLng = new google.maps.LatLng(50.6371834, 3.063017400000035); // Correspond au coordonnées de Lille var myOptions = { zoom : 14, // Zoom par défaut center : latLng, // Coordonnées de départ de la carte de type latLng mapTypeId : google.maps.MapTypeId.ROADMAP, // Type de carte, différentes valeurs possible HYBRID, ROADMAP, SATELLITE, TERRAIN maxZoom : 20 }; map = new google.maps.Map(document.getElementById('map'), myOptions); panel = document.getElementById('panel'); var marker = new google.maps.Marker({ position : latLng, map : map, title : "Position", draggable: true, animation: google.maps.Animation.DROP }); marker.addListener('click', toggleBounce); google.maps.event.addListener(map, 'click', function (event) { new google.maps.Marker({ map: map, position: event.latLng, animation: google.maps.Animation.DROP }); }); var infoWindow = new google.maps.InfoWindow({ position : latLng, map : map }); var request = { location: latLng, radius: '1000', types: ['amusement_park' ,'aquarium' , 'bar' ,'casino' ,'city_hall' , 'night_club'] }; service = new google.maps.places.PlacesService(map); service.nearbySearch(request, callback); google.maps.event.addListener(infoWindow, 'domready', function() { // infoWindow est bien sûr notre info-bulle jQuery("#tabs").tabs(); }); direction = new google.maps.DirectionsRenderer({ map : map, panel : panel // Dom element pour afficher les instructions d'itinéraire }); if (navigator.geolocation) { navigator.geolocation.getCurrentPosition(function(position) { var pos = { lat: position.coords.latitude, lng: position.coords.longitude }; infoWindow.setPosition(pos); infoWindow.setContent('&dArr; Vous êtes ici &dArr;'); map.setCenter(pos); }, function() { handleLocationError(true, infoWindow, map.getCenter()); }); } else { // Browser doesn't support Geolocation handleLocationError(false, infoWindow, map.getCenter()); } map.controls[google.maps.ControlPosition.TOP_RIGHT].push(FullScreenControl(map)); var directionsDisplay = new google.maps.DirectionsRenderer(); directionsDisplay.setMap(map); var inputOrigin = document.getElementById('origin'); var autocomplete = new google.maps.places.Autocomplete(inputOrigin); var inputDst = document.getElementById('destination'); var autocomplete = new google.maps.places.Autocomplete(inputDst); // Create the search box and link it to the UI element. var input = document.getElementById('pac-input'); var searchBox = new google.maps.places.SearchBox(input); map.controls[google.maps.ControlPosition.TOP_LEFT].push(input); // Bias the SearchBox results towards current map's viewport. map.addListener('bounds_changed', function() { searchBox.setBounds(map.getBounds()); }); var markers = []; // Listen for the event fired when the user selects a prediction and retrieve // more details for that place. searchBox.addListener('places_changed', function() { var places = searchBox.getPlaces(); if (places.length == 0) { return; } // Clear out the old markers. markers.forEach(function(marker) { marker.setMap(null); }); markers = []; // For each place, get the icon, name and location. var bounds = new google.maps.LatLngBounds(); places.forEach(function(place) { var icon = { url: place.icon, size: new google.maps.Size(71, 71), origin: new google.maps.Point(0, 0), anchor: new google.maps.Point(17, 34), scaledSize: new google.maps.Size(25, 25) }; // Create a marker for each place. markers.push(new google.maps.Marker({ map: map, icon: icon, title: place.name, position: place.geometry.location })); if (place.geometry.viewport) { // Only geocodes have viewport. bounds.union(place.geometry.viewport); } else { bounds.extend(place.geometry.location); } }); map.fitBounds(bounds); }); }; function handleLocationError(browserHasGeolocation, infoWindow, pos) { infoWindow.setPosition(pos); infoWindow.setContent(browserHasGeolocation ? 'ERREUR: La Géolocalisation à échoué.' : 'ERREUR: Your browser doesn\'t support geolocation.'); } function toggleBounce() { if (marker.getAnimation() !== null) { marker.setAnimation(null); } else { marker.setAnimation(google.maps.Animation.BOUNCE); } } function callback(results, status) { if (status == google.maps.places.PlacesServiceStatus.OK) { for (var i = 0; i < results.length; i++) { var place = results[i]; createMarker(results[i]); } } } calculate = function(){ var origin = document.getElementById('origin').value; // Le point départ var destination = document.getElementById('destination').value; // Le point d'arrivé if(origin && destination){ var request = { origin : origin, destination : destination, travelMode : google.maps.DirectionsTravelMode.DRIVING // Mode de conduite }; var directionsService = new google.maps.DirectionsService(); // Service de calcul d'itinéraire directionsService.route(request, function(response, status){ // Envoie de la requéte pour calculer le parcours //console.log(response); if(status == google.maps.DirectionsStatus.OK){ direction.setDirections(response); // Trace l'itinéraire sur la carte et les différentes étapes du parcours } }); } }; initMap();
30.166667
129
0.66471
c4f2c8a9ec4e8541b3e732933d6e6642b1b6f098
752
js
JavaScript
src/maintenance/pruneFailRecords.js
666kato/Discord.RSS
d7b447bd256b969cfd5aadb877316c3576e03f10
[ "MIT" ]
1
2020-05-13T18:04:05.000Z
2020-05-13T18:04:05.000Z
src/maintenance/pruneFailRecords.js
666kato/Discord.RSS
d7b447bd256b969cfd5aadb877316c3576e03f10
[ "MIT" ]
null
null
null
src/maintenance/pruneFailRecords.js
666kato/Discord.RSS
d7b447bd256b969cfd5aadb877316c3576e03f10
[ "MIT" ]
null
null
null
const FailRecord = require('../structs/db/FailRecord.js') /** * Remove all fail records with URLS that no feed has * @param {import('../structs/db/Feed.js')[]} feeds * @returns {number} */ async function pruneFailRecords (feeds) { const records = await FailRecord.getAll() const feedsLength = feeds.length const activeURLs = new Set() for (var i = feedsLength - 1; i >= 0; --i) { activeURLs.add(feeds[i].url) } const deletions = [] const recordsLength = records.length for (var j = recordsLength - 1; j >= 0; --j) { const record = records[j] if (!activeURLs.has(record.url)) { deletions.push(record.delete()) } } await Promise.all(deletions) return deletions.length } module.exports = pruneFailRecords
26.857143
57
0.662234
c4f2d2f7d1a06a49e89e3ae8836f57dfb6d77d39
728
js
JavaScript
src/Services/sessionService.js
Craig-Fisk/WeatherTest
0a17a7304c74899785e5ae9ced824efeaa392981
[ "Unlicense" ]
null
null
null
src/Services/sessionService.js
Craig-Fisk/WeatherTest
0a17a7304c74899785e5ae9ced824efeaa392981
[ "Unlicense" ]
null
null
null
src/Services/sessionService.js
Craig-Fisk/WeatherTest
0a17a7304c74899785e5ae9ced824efeaa392981
[ "Unlicense" ]
null
null
null
export default class SessionService { // eslint-disable-next-line constructor(){}; static storeWeather(newData) { const stored = window.sessionStorage.getItem('weather'); if(stored) { const data = JSON.parse(stored); if(data.length === 5) { data.shift(); } data.unshift(newData); window.sessionStorage.setItem('weather', JSON.stringify(data)); } else { window.sessionStorage.setItem('weather', JSON.stringify([newData])); } } static retrieveWeather() { const stored = window.sessionStorage.getItem('weather'); const data = JSON.parse(stored); return data; } }
31.652174
80
0.570055
c4f2d5a3484d2ef82a9b719a055a48eaee8dadf9
507
js
JavaScript
solution/172.1.js
flowmemo/leetcode-in-js
495483fd1565599d8830d40e6a03228e890eb296
[ "WTFPL" ]
1
2017-03-04T04:12:39.000Z
2017-03-04T04:12:39.000Z
solution/172.1.js
flowmemo/leetcode-in-js
495483fd1565599d8830d40e6a03228e890eb296
[ "WTFPL" ]
null
null
null
solution/172.1.js
flowmemo/leetcode-in-js
495483fd1565599d8830d40e6a03228e890eb296
[ "WTFPL" ]
null
null
null
/* 172. Factorial Trailing Zeroes Given an integer n, return the number of trailing zeroes in n!. Note: Your solution should be in logarithmic time complexity. Credits: Special thanks to @ts for adding this problem and creating all test cases. */ /** * @param {number} n * @return {number} */ var trailingZeroes = function (n) { 'use strict' let count5 = 0 let base = 5 while (base <= n) { count5 += n / base | 0 n = n / base | 0 } return count5 } module.exports = trailingZeroes
18.777778
74
0.666667
c4f3005fcf466faa57638ec5f91c4f0b0654719f
3,255
js
JavaScript
src/newcanvas/js/functions/anbt/unpackPlayback.js
iBryguy/Drawception-ANBT
cf98e829ae5d64ea6344f88000790591b888d25d
[ "Unlicense" ]
2
2020-08-31T20:25:55.000Z
2021-01-24T10:37:23.000Z
src/newcanvas/js/functions/anbt/unpackPlayback.js
iBryguy/Drawception-ANBT
cf98e829ae5d64ea6344f88000790591b888d25d
[ "Unlicense" ]
null
null
null
src/newcanvas/js/functions/anbt/unpackPlayback.js
iBryguy/Drawception-ANBT
cf98e829ae5d64ea6344f88000790591b888d25d
[ "Unlicense" ]
2
2019-12-10T23:30:43.000Z
2020-12-23T01:11:49.000Z
import { buildSmoothPath } from '../buildSmoothPath' import { stringToBytes } from '../conversions/stringToBytes' import { createSvgElement } from '../createSvgElement' import { int16be } from '../int16be' export function unpackPlayback(bytes) { const { pako } = window const version = bytes[0] let start if (version === 4) { bytes = pako.inflate(bytes.subarray(1)) start = 0 } else if (version === 3) { bytes = stringToBytes(pako.inflate(bytes.subarray(1), { to: 'string' })) start = 0 } else if (version === 2) { start = 1 } else { throw new Error(`Unsupported version: ${version}`) } const svg = createSvgElement('svg', { xmlns: 'http://www.w3.org/2000/svg', version: '1.1', width: 600, height: 500 }) const last = { color: '#000000', size: 14, x: 0, y: 0, pattern: 0 } let points = [] // Ignore background alpha const background = `rgb(${bytes[start]}, ${bytes[start + 1]}, ${ bytes[start + 2] })` svg.background = background svg.appendChild( createSvgElement('rect', { class: 'eraser', x: 0, y: 0, width: 600, height: 500, fill: background }) ) for (let i = start + 4; i < bytes.length; ) { let x = int16be(bytes[i], bytes[i + 1]) i += 2 let y = int16be(bytes[i], bytes[i + 1]) i += 2 if (points.length) { if (!x && !y) { const path = createSvgElement('path', { class: last.color === 'eraser' ? last.color : null, stroke: last.color === 'eraser' ? background : last.color, 'stroke-width': last.size, 'stroke-linejoin': 'round', 'stroke-linecap': 'round', fill: 'none' }) // Restore blots if (points.length === 1) { path.pathSegList.appendItem( path.createSVGPathSegMovetoAbs(last.x, last.y) ) path.pathSegList.appendItem( path.createSVGPathSegLinetoAbs(last.x, last.y + 0.001) ) } else { buildSmoothPath(points, path) } path.orig = points path.pattern = last.pattern svg.appendChild(path) points = [] } else { last.x = x += last.x last.y = y += last.y points.push({ x, y }) } } else { if (x < 0) { if (x === -1 || x === -2) { last.color = `rgba(${bytes[i]}, ${bytes[i + 1]}, ${ bytes[i + 2] }, ${bytes[i + 3] / 255}` // TODO: fix ugly code if (last.color === 'rgba(255,255,255,0)') last.color = 'eraser' i += 4 if (x === -1) { last.size = y / 100 } else { svg.appendChild( createSvgElement('rect', { class: last.color === 'eraser' ? last.color : null, x: 0, y: 0, width: 600, height: 500, fill: last.color === 'eraser' ? background : last.color }) ) } } else if (x === -3) { last.pattern = y i += 4 } } else { points.push({ x, y }) last.x = x last.y = y } } } return svg }
26.463415
76
0.482335
c4f3dbce9489c5f8fd7e14751cdfa6804b72ffff
1,487
js
JavaScript
problem_4.js
cs-fullstack-2019-spring/javascript-functions-cw-tdude0175
edb592ab74511705e913a4a7ce5630c8de8a6681
[ "Apache-2.0" ]
null
null
null
problem_4.js
cs-fullstack-2019-spring/javascript-functions-cw-tdude0175
edb592ab74511705e913a4a7ce5630c8de8a6681
[ "Apache-2.0" ]
null
null
null
problem_4.js
cs-fullstack-2019-spring/javascript-functions-cw-tdude0175
edb592ab74511705e913a4a7ce5630c8de8a6681
[ "Apache-2.0" ]
null
null
null
//Create a function called checkPassword. // Send two string variables to the checkPassword function to check if the strings are equal. // Return true if they are equal and false if they are not equal. // Print the function's return value. /* you can set password goal [var] inside or outside function. you could save password to a list for safe keeping for later. hide access to password list behind function. else if can work for simple access. [do,while] loop for repetitive check. */ var usr1Pas = "C0d3Cr3w"; function checkPassword(usrPasIpt) { do { usrPasIpt = prompt("please input password."); if (usrPasIpt === usr1Pas) { console.log(usrPasIpt); alert("welcome User 1."); usrPasIpt = true; } else if(usrPasIpt !== usr1Pas) { console.log(usrPasIpt); alert("Password is incorrect"); usrPasIpt = prompt("Would you like to continue? Y = yes N = no"); if(usrPasIpt === "y" || usrPasIpt ==="Y") { console.log(usrPasIpt); } else { console.log(usrPasIpt) alert("have a nice day"); break } } } while (usrPasIpt !== true); } checkPassword(123);
29.74
93
0.509079
c4f454214983ed1f950a9da8b765ca1aa338cf3e
382
js
JavaScript
src/client/app/containers/app.js
mingderwang/react-redux-kibana-app-plugin
670f6d36c2ff74bbcf1d40775ead69579afbc8df
[ "MIT" ]
null
null
null
src/client/app/containers/app.js
mingderwang/react-redux-kibana-app-plugin
670f6d36c2ff74bbcf1d40775ead69579afbc8df
[ "MIT" ]
null
null
null
src/client/app/containers/app.js
mingderwang/react-redux-kibana-app-plugin
670f6d36c2ff74bbcf1d40775ead69579afbc8df
[ "MIT" ]
null
null
null
import React from 'react' import Counter from '../components/counter_mapping' import Adder from '../components/add_mapping' import DevTools from '../utils/DevTools' import Gmap from '../components/map' const App = () => { return ( <div className="container"> <Counter/> <Adder/> <DevTools/> <Gmap/> </div> ); }; export default App;
20.105263
51
0.612565
c4f4fb29ba641f36b38fd1758340ef63e516cf62
536
js
JavaScript
commands/discord/fun/flip.js
Vulcan-Discord-Bot/Vulcan
5c17d6a371886e27af527eca9c9f00ed9888cb39
[ "MIT" ]
2
2020-11-01T19:48:45.000Z
2020-11-01T19:56:58.000Z
commands/discord/fun/flip.js
Vulcan-Discord-Bot/Vulcan
5c17d6a371886e27af527eca9c9f00ed9888cb39
[ "MIT" ]
2
2021-04-09T10:30:21.000Z
2021-08-31T21:02:34.000Z
commands/discord/fun/flip.js
Vulcan-Discord-Bot/Vulcan
5c17d6a371886e27af527eca9c9f00ed9888cb39
[ "MIT" ]
1
2021-04-08T09:39:00.000Z
2021-04-08T09:39:00.000Z
const filp = module.exports; const messageEmbeds = xrequire('./modules/messageEmbeds'); filp.load = (descriptor, packages) => { const { MersenneTwister } = packages; this.generator = new MersenneTwister(); }; filp.execute = async message => { const randomNumber = this.generator.random(); const resultantProbability = randomNumber; await message.channel.send( messageEmbeds.reply({ message, description: `Flipped a coin and landed on: **${resultantProbability >= 0.5 ? 'HEADS' : 'TAILS'}**` }) ); };
25.52381
105
0.677239
c4f63efc75f8d754a788ab182bc4317aa57b928b
132
js
JavaScript
recipe-frontend/src/components/Ingredient.js
andrewjford/recipe1
ebd0f5fae4af04654dde0c065e7303f78ea0d6ce
[ "MIT" ]
null
null
null
recipe-frontend/src/components/Ingredient.js
andrewjford/recipe1
ebd0f5fae4af04654dde0c065e7303f78ea0d6ce
[ "MIT" ]
null
null
null
recipe-frontend/src/components/Ingredient.js
andrewjford/recipe1
ebd0f5fae4af04654dde0c065e7303f78ea0d6ce
[ "MIT" ]
null
null
null
import React from 'react'; const Ingredient = (props) => { return <li>{props.ingredient.name}</li> } export default Ingredient;
16.5
41
0.69697
c4f6684a322e5052eb96939ca8593c0f419fe98b
4,889
js
JavaScript
libs/engine/Horde.js
Laboralphy/o876-raycaster-engine
61d0b8b66867d376bb44ff21ea063b68e993af7f
[ "MIT" ]
12
2019-06-11T08:01:43.000Z
2022-03-06T10:30:12.000Z
libs/engine/Horde.js
Laboralphy/o876-raycaster-engine
61d0b8b66867d376bb44ff21ea063b68e993af7f
[ "MIT" ]
3
2020-05-01T14:24:37.000Z
2020-09-18T16:34:00.000Z
libs/engine/Horde.js
Laboralphy/o876-raycaster-engine
61d0b8b66867d376bb44ff21ea063b68e993af7f
[ "MIT" ]
1
2021-08-23T01:19:21.000Z
2021-08-23T01:19:21.000Z
import Geometry from "../geometry"; import * as CONSTS from "./consts"; import ArrayHelper from "../array-helper"; import SectorRegistry from "../sector-registry/SectorRegistry"; const {SPRITE_DIRECTION_COUNT} = CONSTS; class Horde { constructor() { this._entities = []; this._sectors = new SectorRegistry(); } setMapSize(w) { const g = this._sectors.grid; g.width = w; g.height = w; } setSectorSize(n) { this ._sectors .setCellWidth(n) .setCellHeight(n); } /** * checks if an entity is linked into the engine. * only linked entities are thinked and rendered * @param entity {Entity} * @returns {boolean} */ isEntityLinked(entity) { return this._entities.indexOf(entity) >= 0; } /** * Add an entity into the engine * only linked entities are thinked and rendered * @param entity {Entity} */ linkEntity(entity) { if (!this.isEntityLinked(entity)) { this._entities.push(entity); } } /** * Remove an entity from the engine * only linked entities are thinked and rendered * @param entity {Entity} */ unlinkEntity(entity) { entity._sector.remove(entity); entity._sector = null; const aEntities = this._entities; const iEntity = aEntities.indexOf(entity); if (iEntity >= 0) { aEntities.splice(iEntity, 1); } } /** * This will change the animation according to the angle between entity.position.angle and visor.position.angle */ updateLookingAngle(entity, camera) { if (entity === camera) { return; } const oEntityLoc = entity.position; const oCameraLoc = camera.position; const fTarget = Geometry.angle(oCameraLoc.x, oCameraLoc.y, oEntityLoc.x, oEntityLoc.y); // backup let fAngle1 = oEntityLoc.angle + (Math.PI / SPRITE_DIRECTION_COUNT) - fTarget; if (fAngle1 < 0) { fAngle1 = 2 * Math.PI + fAngle1; } const nDirection = ((SPRITE_DIRECTION_COUNT * fAngle1 / (2 * Math.PI)) | 0) & (SPRITE_DIRECTION_COUNT - 1); if (nDirection !== entity.data.backupDirection) { entity.data.backupDirection = nDirection; entity.sprite.setDirection(nDirection); } } getDeadEntities() { return this._entities.filter(e => e.dead); } get entities() { return this._entities; } process(engine) { const entities = this._entities; const rc = engine.raycaster; const sr = this._sectors; const ps = sr.getCellWidth(); for (let i = 0, l = entities.length; i < l; ++i) { const e = entities[i]; const s = e.sprite; const bHasSprite = !!s; const eloc = e.position; this.updateLookingAngle(e, engine.camera); e.think(engine); let bChangeLoc = false; if (bHasSprite) { if (s.x !== eloc.x) { s.x = eloc.x; bChangeLoc = true; } if (s.y !== eloc.y) { s.y = eloc.y; bChangeLoc = true; } if (s.z !== eloc.z) { s.h = eloc.z; bChangeLoc = true; } } // si le sprite a changé de position ou si c'est la visor // mettre a jou les autre donnée de position // (lumière, secteur) if (bChangeLoc || !bHasSprite) { // update light source if (!!e.lightsource) { const ls = e.lightsource; ls.x = eloc.x; ls.y = eloc.y; } // update grid sector // get the sector coords const xSector = eloc.x / ps | 0; const ySector = eloc.y / ps | 0; const eds = e._sector; if (!!eds) { eds.remove(e); } const sector = sr.sector(xSector, ySector); e._sector = sector; sector.add(e); } // compute animation from angle } } /** * Get a list of entities at specified sector * @param xSector {number} * @param ySector {number} * @return {Array} */ getEntitiesAt(xSector, ySector) { const g = this._sectors; const nSize = g.grid.width; if (xSector > 0 && ySector > 0 && xSector < nSize && ySector < nSize) { return g.sector(xSector, ySector).objects; } else { return []; } } } export default Horde;
29.451807
115
0.504807
c4f675d716c822b1e64ed90d48be9acc5b92030a
7,874
js
JavaScript
app/assets/js/vendor/widget.min.js
tutumenezes/hub9-tapume
c03b4022d2225f665ef20400be4b4ab96b60d018
[ "MIT", "Unlicense" ]
null
null
null
app/assets/js/vendor/widget.min.js
tutumenezes/hub9-tapume
c03b4022d2225f665ef20400be4b4ab96b60d018
[ "MIT", "Unlicense" ]
null
null
null
app/assets/js/vendor/widget.min.js
tutumenezes/hub9-tapume
c03b4022d2225f665ef20400be4b4ab96b60d018
[ "MIT", "Unlicense" ]
null
null
null
/*! sendgrid-subscription-widget - v0.2.0 - 2014-06-20 */ var jsonParse=function(){function a(a,b,c){return b?g[b]:String.fromCharCode(parseInt(c,16))}var b="(?:-?\\b(?:0|[1-9][0-9]*)(?:\\.[0-9]+)?(?:[eE][+-]?[0-9]+)?\\b)",c='(?:[^\\0-\\x08\\x0a-\\x1f"\\\\]|\\\\(?:["/\\\\bfnrt]|u[0-9A-Fa-f]{4}))',d='(?:"'+c+'*")',e=new RegExp("(?:false|true|null|[\\{\\}\\[\\]]|"+b+"|"+d+")","g"),f=new RegExp("\\\\(?:([^u])|u(.{4}))","g"),g={'"':'"',"/":"/","\\":"\\",b:"\b",f:"\f",n:"\n",r:"\r",t:" "},h=new String(""),i="\\",j=Object.hasOwnProperty;return function(b,c){var d,g=b.match(e),k=g[0],l=!1;"{"===k?d={}:"["===k?d=[]:(d=[],l=!0);for(var m,n=[d],o=1-l,p=g.length;p>o;++o){k=g[o];var q;switch(k.charCodeAt(0)){default:q=n[0],q[m||q.length]=+k,m=void 0;break;case 34:if(k=k.substring(1,k.length-1),-1!==k.indexOf(i)&&(k=k.replace(f,a)),q=n[0],!m){if(!(q instanceof Array)){m=k||h;break}m=q.length}q[m]=k,m=void 0;break;case 91:q=n[0],n.unshift(q[m||q.length]=[]),m=void 0;break;case 93:n.shift();break;case 102:q=n[0],q[m||q.length]=!1,m=void 0;break;case 110:q=n[0],q[m||q.length]=null,m=void 0;break;case 116:q=n[0],q[m||q.length]=!0,m=void 0;break;case 123:q=n[0],n.unshift(q[m||q.length]={}),m=void 0;break;case 125:n.shift()}}if(l){if(1!==n.length)throw new Error;d=d[0]}else if(n.length)throw new Error;if(c){var r=function(a,b){var d=a[b];if(d&&"object"==typeof d){var e=null;for(var f in d)if(j.call(d,f)&&d!==a){var g=r(d,f);void 0!==g?d[f]=g:(e||(e=[]),e.push(f))}if(e)for(var h=e.length;--h>=0;)delete d[e[h]]}return c.call(a,b,d)};d=r({"":d},"")}return d}}();!function(){var a={css:!0,messages:!0};"undefined"==typeof window.hasOwnProperty&&(window.hasOwnProperty=function(a){return this[a]?!0:!1});var b=function(a){return"undefined"!=typeof JSON?JSON.parse(a):jsonParse(a)},c="sendgrid-subscription-widget",d=Object.keys||function(a){if(a!==Object(a))throw new TypeError("Invalid object");var b=[];for(var c in a)window.hasOwnProperty.call(a,c)&&b.push(c);return b},e=function(a){return a},f=function(a,b,c){if(null!=a)if(Array.prototype.forEach&&a.forEach===Array.prototype.forEach)a.forEach(b,c);else if(a.length===+a.length){for(var e=0,f=a.length;f>e;e++)if(b.call(c,a[e],e,a)==={})return}else for(var g=d(a),e=0,f=g.length;f>e;e++)if(b.call(c,a[g[e]],g[e],a)==={})return},g=function(a){return"function"==typeof a?a:function(b){return b[a]}},h=function(a,b,c,d){c=null==c?e:g(c);for(var f=c.call(d,b),h=0,i=a.length;i>h;){var j=h+i>>>1;c.call(d,a[j])<f?h=j+1:i=j}return h},i=function(a,b,c){if(null==a)return-1;var d=0,e=a.length;if(c){if("number"!=typeof c)return d=h(a,b),a[d]===b?d:-1;d=0>c?Math.max(0,e+c):c}if(Array.prototype.indexOf&&a.indexOf===Array.prototype.indexOf)return a.indexOf(b,c);for(;e>d;d++)if(a[d]===b)return d;return-1},j=function(a){return f(Array.prototype.slice.call(arguments,1),function(b){if(b)for(var c in b)a[c]=b[c]}),a},k={onload:1,onunload:1,onblur:1,onchange:1,onfocus:1,onreset:1,onselect:1,onsubmit:1,onabort:1,onkeydown:1,onkeypress:1,onkeyup:1,onclick:1,ondblclick:1,onmousedown:1,onmousemove:1,onmouseout:1,onmouseover:1,onmouseup:1},l=function(a,b){a.dispatchEvent?a.dispatchEvent(b):a.fireEvent&&k["on"+b.eventName]?a.fireEvent("on"+b.eventType,b):a[b.eventName]?a[b.eventName]():a["on"+b.eventName]&&a["on"+b.eventName]()};if(window.CustomEvent){var m=function(a,b){b=b||{bubbles:!1,cancelable:!1,detail:void 0};var c=document.createEvent("CustomEvent");return c.initCustomEvent(a,b.bubbles,b.cancelable,b.detail),c};m.prototype=window.CustomEvent.prototype}else{var m=function(a){var b;return document.createEvent?(b=document.createEvent("HTMLEvents"),b.initEvent(a,!0,!0)):document.createEventObject&&(b=document.createEventObject(),b.eventType=a),b.eventName=a,b};if(!window.Element){Element=function(){};var n=document.createElement;document.createElement=function(a){var b=n(a);if(null==b)return null;for(var c in Element.prototype)b[c]=Element.prototype[c];return b};var o=document.getElementById;document.getElementById=function(a){var b=o(a);if(null==b)return null;for(var c in Element.prototype)b[c]=Element.prototype[c];return b}}}j(Element.prototype,{addCustomEventListener:function(a,b){this.addEventListener?this.addEventListener(a,b,!1):this.attachEvent&&k["on"+a]?this.attachEvent("on"+a,b):this["on"+a]=b}}),sendRequest=function(a,b,c){a="https://"+a;var d=createXMLHTTPObject();if(d){var e=c?"POST":"GET";if("undefined"!=typeof XDomainRequest)d.open("GET",a+"?"+c,!0),d.onload=function(){return b(d)},d.send();else{if(c&&d.open(e,a,!0),d.setRequestHeader("Content-type","application/x-www-form-urlencoded"),d.onreadystatechange=function(){4==d.readyState&&(200==d.status||304==d.status)&&b(d)},4==d.readyState)return;d.send(c)}}},XMLHttpFactories=[function(){return new XMLHttpRequest},function(){return new ActiveXObject("Msxml2.XMLHTTP")},function(){return new ActiveXObject("Msxml3.XMLHTTP")},function(){return new ActiveXObject("Microsoft.XMLHTTP")}],createXMLHTTPObject=function(){if("withCredentials"in new XMLHttpRequest){for(var a=!1,b=0;b<XMLHttpFactories.length;b++){try{a=XMLHttpFactories[b]()}catch(c){continue}break}return a}if("undefined"!=typeof XDomainRequest){usingXdr=!0;var a=new XDomainRequest;return a}},textToBool=function(a){return"true"===a||"1"===a},checkDefault=function(a,b,c){return b.getAttribute("data-"+a)?textToBool(b.getAttribute("data-"+a)):c[a]},widgets=[],f(document.getElementsByTagName("div"),function(a){var b=a.className.split(" ");-1!==i(b,c)&&widgets.push(a)}),f(widgets,function(d){if("true"!==d.getAttribute("data-executed")){if(d.setAttribute("data-executed","true"),checkDefault("css",d,a)&&!document.getElementById(c+"-css")){var e=document.createElement("link");e.setAttribute("id",c+"-css"),e.setAttribute("rel","stylesheet"),e.setAttribute("type","text/css"),e.setAttribute("href","//s3.amazonaws.com/subscription-cdn/0.2/widget.min.css"),document.getElementsByTagName("head")[0].appendChild(e)}var g=d.innerHTML;d.innerHTML="";var h=document.createElement("form"),k=d.getAttribute("data-submit-text")||"Subscribe";h.innerHTML='<div class="response"></div>'+g+'<label><span>Email</span><input type="email" name="email" placeholder="you@example.com"></label><input type="submit" value="'+k+'">',d.appendChild(h);var n={"Your request cannot be processed.":d.getAttribute("data-message-unprocessed")||"Unfortunately, an error occurred. Please contact us to subscribe.","The email address is invalid.":d.getAttribute("data-message-invalid")||"The email you provided is not a valid email address. Please fix it and try again.","You have subscribed to this Marketing Email.":d.getAttribute("data-message-success")||"Thanks for subscribing."};h.addCustomEventListener("submit",function(c){h=c.srcElement?c.srcElement:c.target;var d=j({},c),e=m("sent",d),g=h.parentNode;c.stopPropagation?c.stopPropagation():null,c.preventDefault?c.preventDefault():null,"undefined"!=typeof event&&(event.preventDefault?event.preventDefault():event.returnValue=!1),l(g,e);var k=decodeURIComponent(g.getAttribute("data-token")),o=document.location.href,p=h.getElementsByTagName("input"),q={};f(p,function(a){var b=a.getAttribute("name"),c="SG_widget["+b+"]";q[c]=a.value}),q.p=k,q.r=o;var r="";f(q,function(a,b){r+="&"+b+"="+encodeURIComponent(a)}),r=r.substr(1),sendRequest("sendgrid.com/newsletter/addRecipientFromWidget",function(c){var d,e,h=b(c.responseText),j={message:h.message,detail:h.detail||h.message},k=g.getElementsByTagName("div"),o=k[0];f(k,function(a){var b=a.className.split(" ");-1!==i(b,"response")&&(o=a)},r),d=h.success===!1?"error":"success",j.type=d,e=m(d,j),checkDefault("messages",g,a)&&(o.className=o.className.replace("error","").replace("success","")+" "+d,o.innerHTML=n[j.message].replace(/&/g,"&amp;").replace(/"/g,"&quot;").replace(/'/g,"&#39;").replace(/</g,"&lt;").replace(/>/g,"&gt;")),l(g,e)},r)});var o=m("ready",{info:"ready"});l(d,o)}})}();
3,937
7,816
0.68669
c4f6edf86d0213c0f4086b0994cf9b9722f32a6a
430
js
JavaScript
php/js/eye_hide_show.js
MartyLocke/14B_Projekt_Bazy
5691b76c8c38dfeb1c4ba3b30a1f94b0ffdab9f7
[ "MIT" ]
3
2021-12-07T18:48:13.000Z
2022-03-17T19:54:55.000Z
php/js/eye_hide_show.js
MartyLocke/14B_Projekt_Bazy
5691b76c8c38dfeb1c4ba3b30a1f94b0ffdab9f7
[ "MIT" ]
null
null
null
php/js/eye_hide_show.js
MartyLocke/14B_Projekt_Bazy
5691b76c8c38dfeb1c4ba3b30a1f94b0ffdab9f7
[ "MIT" ]
null
null
null
let showFlag = false; let passwordField; function passwd_show(passwdId) { passwordField = document.getElementById(passwdId); console.log(passwordField); let hide = document.querySelector('.hide'); hide.onclick = function() { const type = passwordField.getAttribute("type") === "password" ? "text" : "password"; passwordField.setAttribute('type' , type); this.classList.toggle('bi-eye'); } }
22.631579
64
0.676744
c4f7772b0fd9276f154f3ba59bea146d18d0b54e
666
js
JavaScript
src/store/ducks/search/market.js
toastyboost/coinrate-gatsby
89ec72ba18f14559a0b903c64f1216e7a3062e00
[ "MIT" ]
3
2019-10-11T08:30:31.000Z
2019-11-17T02:57:06.000Z
src/store/ducks/search/market.js
toastyboost/coinrate-gatsby
89ec72ba18f14559a0b903c64f1216e7a3062e00
[ "MIT" ]
null
null
null
src/store/ducks/search/market.js
toastyboost/coinrate-gatsby
89ec72ba18f14559a0b903c64f1216e7a3062e00
[ "MIT" ]
1
2021-05-24T11:51:25.000Z
2021-05-24T11:51:25.000Z
import { createAction, handleActions } from 'redux-actions'; import { fetchMarketData } from 'store/api'; // SYNC ACTIONS export const setSearchData = createAction('setSearchData'); // ASYNC ACTIONS export const getSearchData = () => async dispatch => { const res = await fetchMarketData(); dispatch(setSearchData({ ...res })); }; const initialState = {}; export default handleActions( { [setSearchData]: (state, { payload }) => { const { data } = payload; const { result } = data; return { ...state, ...result, }; }, }, initialState ); export const selectSearchData = state => state.search.market;
19.588235
61
0.627628
c4f89596d80b528c84d0be248e17b7b492ef262b
285
js
JavaScript
addons/theme/stv1/_static/ts2/js/editor/editor/core/htmlparser/text-min.js
AojiaoZero/ThinkSNS-4
5fd5d912ba441d556e2ff1de938fe189ec960907
[ "BSD-3-Clause" ]
1
2019-09-06T11:17:34.000Z
2019-09-06T11:17:34.000Z
_static/ts2/js/editor/editor/core/htmlparser/text-min.js
zhiyicx/thinksns-theme-stv1
e250d1eb7a6af9390cc657bc1c2f9072b81ac0c9
[ "MIT" ]
135
2021-11-04T08:29:02.000Z
2022-03-31T08:33:26.000Z
addons/theme/stv1/_static/ts2/js/editor/editor/core/htmlparser/text-min.js
AojiaoZero/ThinkSNS-4
5fd5d912ba441d556e2ff1de938fe189ec960907
[ "BSD-3-Clause" ]
4
2017-01-20T16:16:56.000Z
2019-03-21T03:12:56.000Z
KISSY.Editor.add("htmlparser-text",function(){function a(b){this.value=b;this._={isBlockLike:g}}var e=KISSY,c=e.Editor,g=false;e.augment(a,{type:c.NODE.NODE_TEXT,writeHtml:function(b,f){var d=this.value;f&&!(d=f.onText(d,this))||b.text(d)}});c.HtmlParser.Text=a;c.HtmlParser.Text=a});
142.5
284
0.726316
c4fa5a08d9e1ea29ba481474f3336e86c2aea5c8
4,637
js
JavaScript
public/js/locations.js
ElasticOrange/issue-monitoring
902687ba7e6e27c8d53e8d130a7739c9f1d57fe2
[ "MIT" ]
null
null
null
public/js/locations.js
ElasticOrange/issue-monitoring
902687ba7e6e27c8d53e8d130a7739c9f1d57fe2
[ "MIT" ]
null
null
null
public/js/locations.js
ElasticOrange/issue-monitoring
902687ba7e6e27c8d53e8d130a7739c9f1d57fe2
[ "MIT" ]
null
null
null
(function(){ var tree; var LocationForm; $(document).ready(function () { tree = $('#locationTree'); var source = null; $.ajax({ async: false, url: "/getLocationTree", success: function (data, status, xhr) { source = (data); } }); var dataAdapter = new $.jqx.dataAdapter(source); dataAdapter.dataBind(); var records = dataAdapter.getRecordsHierarchy('id', 'parent_id', 'items', [{name: 'name', map: 'label'}]); records[0].expanded = true; tree.jqxTree({source: records, height: '600px', width: '100%', allowDrag: true, allowDrop: true , dragStart: function (item) { if (item.id == 1) return false; } }); tree.on('dragEnd', function () { var item = getSelectedLocation(); var request = $.ajax({ async: false, type: "GET", url: "/backend/location/" + item.id + "/change-parent", data: {parent_id: item.parentId} }); request.done(function(data) { tree.jqxTree('selectItem', getTreeItemById(tree, item.id)); tree.jqxTree('expandItem', item); }) }); $(document).on('click', '#editLocation', function (event) { $('#myModal').modal('show'); ajaxGetLocationNameForEdit(); }); $(document).on('click', '#addLocation', function(ev) { ev.preventDefault(); setLocationFormForCreate(); }); $(document).on('click', '#deleteLocation', function(ev) { setIdForDeleteAction(); }); var locationAutocomplete = $('#location-autocomplete'); var locationsList = new Bloodhound({ queryTokenizer: Bloodhound.tokenizers.whitespace, datumTokenizer: Bloodhound.tokenizers.whitespace, remote: { url: locationAutocomplete.attr('source-url'), wildcard: '{name}', transform: function (response) { return _.filter(response, function(item){ return $('[location-id=' + item.id + ']').length === 0; }); } } }); locationAutocomplete.typeahead( null, { name: 'location', display: 'name', source: locationsList } ); typeaheadAutocomplete(locationAutocomplete); locationAutocomplete.bind( 'typeahead:select', function(event, suggestion) { tree.jqxTree('selectItem', getTreeItemById(tree, suggestion.id)); var element = tree.jqxTree('getSelectedItem'); tree.jqxTree('expandItem', element); }); }); function setIdForDeleteAction() { var location = getSelectedLocation(); if (!location) { return false; } if (location.level == 0) { return false; } $.ajax({ async: false, type: "GET", url: "/backend/location/" + location.id + "/delete", success: function (data) { tree.jqxTree('removeItem', location.element); } }); } function ajaxGetLocationNameForEdit() { var location = getSelectedLocation(); if (!location) { alert("Nu se poate modifica"); $('#myModal').modal('hide'); return false; } if (location.level == 0) { alert("Nu se poate modifica"); $('#myModal').modal('hide'); return false; } $.ajax({ async: false, type: "GET", url: "/backend/location/" + location.id + "/edit", success: function (data) { $('.modal-content').html(data); $('input[name=parent_id]').attr("value", parseInt(location.parentId)); preventEnterToSubmit('form'); } }); } function getSelectedLocation() { var element = tree.jqxTree('getSelectedItem'); return element; } function setLocationFormForCreate() { var location = getSelectedLocation(); $.ajax({ async: false, type: "GET", url: "/backend/location/create", success: function (data) { $('.modal-content').html(data); $('input[name=parent_id]').attr("value", parseInt(location.id)); preventEnterToSubmit('form'); } }); } window.getTreeItemById = function (tree, id) { var items = tree.jqxTree('getItems'); var item = _.find(items, {id: id.toString()}); return item; }; window.onLocationCreated = function(location) { var currentLocation = getSelectedLocation(); tree.jqxTree('addTo', { label: location['name'], id: parseInt(location['id']) }, currentLocation); tree.jqxTree('selectItem', getTreeItemById(tree, location.id)); tree.jqxTree('expandItem', currentLocation); $('#myModal').modal('hide'); }; window.onLocationUpdated = function(location) { var currentLocation = getSelectedLocation(); tree.jqxTree('updateItem', currentLocation.element, {label: location['name'], id: parseInt(location['id'])}); tree.jqxTree('selectItem', getTreeItemById(tree, location.id)); tree.jqxTree('expandItem', currentLocation); $('#myModal').modal('hide'); }; })();
24.664894
111
0.629717
c4fa7d29addd93dd298fb2f9f920b3366e64d0fc
819
js
JavaScript
status.js
whymarrh/mattress
e74a8cb56f7c630d5970c395cd6418b35e3a379c
[ "0BSD" ]
1
2021-12-26T23:51:35.000Z
2021-12-26T23:51:35.000Z
status.js
whymarrh/mattress
e74a8cb56f7c630d5970c395cd6418b35e3a379c
[ "0BSD" ]
1
2015-05-03T18:36:27.000Z
2015-05-03T18:36:27.000Z
status.js
whymarrh/mattress
e74a8cb56f7c630d5970c395cd6418b35e3a379c
[ "0BSD" ]
null
null
null
"use strict"; module.exports = { success: { OK: { statusCode: 200 } }, client: { BAD_REQUEST: { message: "The request was malformed", statusCode: 400 }, UNAUTHORIZED: { message: "Authentication is required for that request", statusCode: 401 }, FORBIDDEN: { message: "This is not the request you are looking for", statusCode: 403 }, NOT_FOUND: { message: "I do not know what you are looking for", statusCode: 404 }, METHOD_NOT_ALLOWED: { message: "The specified message is not allowed for the requested resource", statusCode: 405 }, NOT_ACCEPTABLE: { message: "The specified Accept header is not appropriate or is invalid", statusCode: 406 } }, server: { INTERNAL_SERVER_ERROR: { message: "The server is broken", statusCode: 500 } } };
19.5
78
0.655678
c4fa9b7e8ffe072ac1eda6364da26a472cf42af3
867
js
JavaScript
cursoJS/modulo7promises/aula6/index.js
nathan-slv017/Aulas
7393ecb03902f572ad7cd3e154f35cfd797dd57b
[ "MIT" ]
null
null
null
cursoJS/modulo7promises/aula6/index.js
nathan-slv017/Aulas
7393ecb03902f572ad7cd3e154f35cfd797dd57b
[ "MIT" ]
null
null
null
cursoJS/modulo7promises/aula6/index.js
nathan-slv017/Aulas
7393ecb03902f572ad7cd3e154f35cfd797dd57b
[ "MIT" ]
null
null
null
/*fetch('pessoas.json') .then(resultado => resultado.json()) .then(json => gerarTabela(json)); */ axios('pessoas.json') .then(resultado => gerarTabela(resultado.data)); function gerarTabela(json){ const table = document.createElement('table'); for(pessoa of json){ const tr = document.createElement('tr'); const td1 = document.createElement('td'); td1.innerHTML = `nome: ${pessoa.nome}` tr.appendChild(td1) const td2 = document.createElement('td'); td2.innerHTML = `email: ${pessoa.email}` tr.appendChild(td2) const td3 = document.createElement('td1'); td3.innerHTML = `salário: R$${pessoa.salario}.00` tr.appendChild(td3) table.appendChild(tr) } const resultado = document.querySelector('.resultado'); resultado.appendChild(table) }
28.9
59
0.622837
c4fadc9ddef0f3633acaec9c38a483be44b4ff9c
327
js
JavaScript
src/utils/auth.js
yayxs/react-cra-admin
dce43a3f083568a5ee524cba6a9c5f103423c72a
[ "MIT" ]
6
2020-12-18T14:11:02.000Z
2021-08-19T01:32:19.000Z
src/utils/auth.js
yayxs/react-cra-admin
dce43a3f083568a5ee524cba6a9c5f103423c72a
[ "MIT" ]
null
null
null
src/utils/auth.js
yayxs/react-cra-admin
dce43a3f083568a5ee524cba6a9c5f103423c72a
[ "MIT" ]
2
2021-04-28T06:56:16.000Z
2021-06-19T08:25:32.000Z
export function getToken() { return localStorage.getItem("token"); } export function setToken(token) { localStorage.setItem("token", token); } export function clearToken() { localStorage.removeItem("token"); } export function isLogined() { if (localStorage.getItem("token")) { return true; } return false; }
17.210526
39
0.700306
c4fadf6aa21609b1fdde7ef186acd35caf700535
3,595
js
JavaScript
src/components/seo.js
tarotum/gbwp
aea9d97cdf65d15debcfc0b0c5e170d8c318d622
[ "MIT" ]
2
2020-01-30T20:07:19.000Z
2020-01-30T20:07:23.000Z
src/components/seo.js
tarotum/gbwp
aea9d97cdf65d15debcfc0b0c5e170d8c318d622
[ "MIT" ]
48
2020-10-27T17:34:35.000Z
2022-02-27T22:02:22.000Z
src/components/seo.js
tarotum/gbwp
aea9d97cdf65d15debcfc0b0c5e170d8c318d622
[ "MIT" ]
null
null
null
/** * SEO component that queries for data with * Gatsby's useStaticQuery React hook * * See: https://www.gatsbyjs.org/docs/use-static-query/ */ import React from "react" import PropTypes from "prop-types" import { Helmet } from "react-helmet" import { useStaticQuery, graphql } from "gatsby" import { escapeHtml } from "../utils/htmlHelpers" import metaLogo from "../images/meta-logo.jpg" function SEO({ description, lang, meta, title, pathname, langsMenu, schemaOrg, disableSiteNameInTitle, }) { const { site } = useStaticQuery( graphql` query { site { siteMetadata { title description author siteUrl } } } ` ) const schema = schemaOrg ? schemaOrg : {} const metaDescription = description || site.siteMetadata.description /** * remove noindex */ const metaProp = [ { name: `description`, content: metaDescription, }, { property: `og:title`, content: title ? title : site.siteMetadata.title, }, { property: `og:site_name`, content: site.siteMetadata.title, }, { property: `og:description`, content: metaDescription, }, { property: `og:image`, content: `${site.siteMetadata.siteUrl}${metaLogo}`, }, { property: `og:image:width`, content: 500, }, { property: `og:image:height`, content: 500, }, { property: `og:type`, content: `website`, }, { name: `twitter:card`, content: `summary`, }, { name: `twitter:title`, content: title ? title : site.siteMetadata.title, }, { name: `twitter:description`, content: metaDescription, }, ].concat(meta) const alternateHreflangs = { uk: "uk-ua", ru: "ru", en: "en", "x-default": "x-default", } let langs = langsMenu const hasEnTranslation = langs.some( ({ langKey, disabled }) => langKey === "en" && !disabled ) if (hasEnTranslation) { const enTranslation = langsMenu.find(({ langKey }) => langKey === "en") langs = [...langsMenu, { ...enTranslation, langKey: "x-default" }] } return ( <Helmet htmlAttributes={{ lang, }} title={escapeHtml(title)} titleTemplate={ !disableSiteNameInTitle ? `%s | ${site.siteMetadata.title}` : null } defaultTitle={site.siteMetadata.title} meta={metaProp} link={[ { rel: "canonical", key: `${site.siteMetadata.siteUrl}${pathname.replace(/\/$/, "")}`, href: `${site.siteMetadata.siteUrl}${pathname.replace(/\/$/, "")}`, }, ...langs .filter(item => !item.disabled) .map(lang => ({ rel: "alternate", hreflang: alternateHreflangs[lang.langKey], key: lang.langKey, href: `${site.siteMetadata.siteUrl}${lang.link.replace(/\/$/, "")}`, })), ]} > <script type="application/ld+json">{JSON.stringify(schema)}</script> </Helmet> ) } SEO.defaultProps = { meta: [], description: ``, title: ``, langsMenu: [], schemaOrg: null, disableSiteNameInTitle: false, } SEO.propTypes = { description: PropTypes.string, lang: PropTypes.string.isRequired, meta: PropTypes.arrayOf(PropTypes.object), title: PropTypes.string, pathname: PropTypes.string.isRequired, langsMenu: PropTypes.array, schemaOrg: PropTypes.object, disableSiteNameInTitle: PropTypes.bool, } export default SEO
21.656627
80
0.570236
c4fd2cc3a25b2d44cbf0991d87ffac9a33f0e86e
673
js
JavaScript
__tests__/boards/models/future-board.js
WeTransfer/wetransfer-js-sdk
c05c16281ae700f065055ff697c2637a34cc5e6c
[ "MIT" ]
36
2018-04-16T09:32:34.000Z
2021-11-21T06:42:29.000Z
__tests__/boards/models/future-board.js
WeTransfer/wetransfer-js-sdk
c05c16281ae700f065055ff697c2637a34cc5e6c
[ "MIT" ]
81
2018-04-16T07:37:11.000Z
2020-07-07T19:51:01.000Z
__tests__/boards/models/future-board.js
WeTransfer/wetransfer-js-sdk
c05c16281ae700f065055ff697c2637a34cc5e6c
[ "MIT" ]
11
2018-10-12T15:12:58.000Z
2021-04-09T01:39:47.000Z
const { futureBoard } = require('../../../src/boards/models'); describe('Future board normalizer', () => { describe('normalizeBoard function', () => { let board = {}; beforeEach(() => { board = { name: 'WeTransfer rocks', description: '', }; }); it('should return a normalized board', () => { const normalized = futureBoard(board); expect(normalized).toMatchSnapshot(); }); it('should remove extra properties', () => { const extraProps = Object.assign({}, board, { date: new Date() }); const normalized = futureBoard(extraProps); expect(normalized).toMatchSnapshot(); }); }); });
26.92
72
0.566122
c4fdc89a2f5ea580fdb7684d8473283a6386aa71
2,019
js
JavaScript
scripts/create-vote-proposals.js
vedant-11/ideaDAO
f3b52f60b3039d02ce8965c8a4c7dea5bdcaad02
[ "MIT" ]
1
2022-02-03T14:09:05.000Z
2022-02-03T14:09:05.000Z
scripts/create-vote-proposals.js
vedant-11/ideaDAO
f3b52f60b3039d02ce8965c8a4c7dea5bdcaad02
[ "MIT" ]
null
null
null
scripts/create-vote-proposals.js
vedant-11/ideaDAO
f3b52f60b3039d02ce8965c8a4c7dea5bdcaad02
[ "MIT" ]
null
null
null
import dotenv from "dotenv"; import { ethers } from "ethers"; import sdk from "./1-initialize-sdk.js"; dotenv.config(); if (!process.env.WALLET_ADDRESS || process.env.WALLET_ADDRESS == "") { throw new Error("🛑 Wallet address not found."); } const voteModule = sdk.getVoteModule( "0xB998d77F182222344d584b7a3B19b25d2735E273" ); const tokenModule = sdk.getTokenModule( "0xFF4714AEa7D2CE3358ec45f40fB35A6bc2A0a40B" ); (async () => { try { await tokenModule.delegateTo(process.env.WALLET_ADDRESS); const amount = 12345; await voteModule.propose( "Should the DAO invest " + amount + " in idea related to solidification of carbondioxide from atmosphere ", [ { nativeTokenValue: 0, transactionData: tokenModule.contract.interface.encodeFunctionData( "mint", [voteModule.address, ethers.utils.parseUnits(amount.toString(), 18)] ), toAddress: tokenModule.address, }, ] ); console.log("✅ Successfully created proposal to mint tokens"); } catch (error) { console.error("failed to create first proposal", error); process.exit(1); } try { const amount = 69420; await voteModule.propose( "Should the DAO transfer " + amount + " tokens from the treasury to " + process.env.WALLET_ADDRESS + " for idea related to biodegradable caps", [ { nativeTokenValue: 0, transactionData: tokenModule.contract.interface.encodeFunctionData( "transfer", [ process.env.WALLET_ADDRESS, ethers.utils.parseUnits(amount.toString(), 18), ] ), toAddress: tokenModule.address, }, ] ); console.log( "✅ Successfully created proposal to reward ourselves from the treasury, let's hope people vote for it!" ); } catch (error) { console.error("failed to create first proposal", error); } })();
26.92
109
0.614165
c4fe3d1d2af2d7e66c7c5bc0a437bdb6299da0c7
1,239
js
JavaScript
docs/html/search/all_c.js
AbsCoDes/fmt
5eda88271553037cc93d097b9432d83ff1e23aca
[ "Apache-2.0" ]
null
null
null
docs/html/search/all_c.js
AbsCoDes/fmt
5eda88271553037cc93d097b9432d83ff1e23aca
[ "Apache-2.0" ]
null
null
null
docs/html/search/all_c.js
AbsCoDes/fmt
5eda88271553037cc93d097b9432d83ff1e23aca
[ "Apache-2.0" ]
null
null
null
var searchData= [ ['operator_28_29',['operator()',['../classarg__formatter.html#ac8ddd9b78934fc951916a30d46114ab1',1,'arg_formatter::operator()()'],['../classprintf__arg__formatter.html#a4e462c5b70ceef75a41261472aa56313',1,'printf_arg_formatter::operator()(const char *value)'],['../classprintf__arg__formatter.html#a880170cd3e3ace7546cb01268586ac77',1,'printf_arg_formatter::operator()(const wchar_t *value)'],['../classprintf__arg__formatter.html#a22c7d349112400ecf9a66005b1a0229e',1,'printf_arg_formatter::operator()(const void *value)'],['../classprintf__arg__formatter.html#a57ded50a248eab9775966e05330dfcb5',1,'printf_arg_formatter::operator()(typename basic_format_arg&lt; context_type &gt;::handle handle)']]], ['operator_3d',['operator=',['../classbasic__memory__buffer.html#ae03c16a826d5ebaf1754467f40d0b7ba',1,'basic_memory_buffer']]], ['out',['out',['../structformat__to__n__result.html#a90597c6c1d23c7301aef16e756c6263b',1,'format_to_n_result']]], ['output_5frange',['output_range',['../classoutput__range.html',1,'']]], ['output_5frange_3c_20std_3a_3aback_5finsert_5fiterator_3c_20container_20_3e_20_3e',['output_range&lt; std::back_insert_iterator&lt; Container &gt; &gt;',['../classoutput__range.html',1,'']]] ];
137.666667
702
0.788539
c4fe966c35f008fa9440b3e3b7d6bd59fcac19fb
3,125
js
JavaScript
app/templates/plan/automatic_edit.js
wuxuemin110/P2PAdmin
05b5a6e92a6d61cb27eb2d1426a4472567514237
[ "MIT" ]
1
2019-01-02T01:54:16.000Z
2019-01-02T01:54:16.000Z
app/templates/plan/automatic_edit.js
wuxuemin110/P2PAdmin
05b5a6e92a6d61cb27eb2d1426a4472567514237
[ "MIT" ]
null
null
null
app/templates/plan/automatic_edit.js
wuxuemin110/P2PAdmin
05b5a6e92a6d61cb27eb2d1426a4472567514237
[ "MIT" ]
null
null
null
'use strict'; angular.module('myApp.automatic_edit', ['ngRoute']) .config(['$routeProvider', function ($routeProvider) { $routeProvider.when('/plan/automatic_edit', { templateUrl: 'templates/plan/automatic_edit.html', controller: 'automatic_editCtrl' }); }]) .controller('automatic_editCtrl', function ($http,$filter, $mdDialog,$scope, $rootScope, automatic_editService) { var message; // 检测登录 var userId = localStorage.userId; var token = localStorage.token; if (token == undefined) { alert("您尚未登录!"); self.location = "/manageSystem/#/login"; } $scope.automatic = {}; $scope.automatic.aname = $rootScope.plan.name; $scope.automatic.planId = $rootScope.plan.planId; $scope.selectVoucherId=function (name,money) { $scope.automatic.voucherId = '0' if(name==''||money==''||money=='0'||money==0||name==null||money==null){ $mdDialog.show( $mdDialog.alert() .clickOutsideToClose(true) .title('发生错误,错误信息如下:') .textContent("账号或金额不能为空!") .ok('确定') ); }else { $http.get(HOST_URL + "/user/voucherList?name="+name+"&money="+money*100).success(function (responseData) { $scope.voucherId = responseData }).error(function (responseData) { $mdDialog.show( $mdDialog.alert() .clickOutsideToClose(true) .title('发生错误,错误信息如下:') .textContent(responseData.error) .ok('确定') ); }); } } $scope.update = function() { automatic_editService.Automatic(token,$scope.automatic.planId,$scope.automatic.name,$scope.automatic.money,$scope.automatic.voucherId); }; }) .factory('automatic_editService', function ($http, $mdDialog) { return { Automatic: function (token,planId,name,money,voucherId) { return $http.get(HOST_URL + "/plan/automatic?token=" + token+"&planId="+planId+"&name="+name+"&money="+money*100+"&voucherId="+voucherId).success(function (responseData) { $mdDialog.show( $mdDialog.alert() .clickOutsideToClose(true) .title('提示') .textContent(responseData.message) .ok('确定') ); }).error(function (responseData) { $mdDialog.show( $mdDialog.alert() .clickOutsideToClose(true) .title('提示') .textContent(responseData.error) .ok('确定') ); }); } } });
42.22973
187
0.4688
c4fee28fb9645c98ca878ae92dc7835e62ccb724
4,460
js
JavaScript
src/page/approval/approval-add/main.js
maying0505/erp_pc
e3a399630fa5ceadc634e41247dcd3092158549a
[ "MIT" ]
null
null
null
src/page/approval/approval-add/main.js
maying0505/erp_pc
e3a399630fa5ceadc634e41247dcd3092158549a
[ "MIT" ]
1
2020-07-19T22:14:57.000Z
2020-07-19T22:14:57.000Z
src/page/approval/approval-add/main.js
maying0505/erp_pc
e3a399630fa5ceadc634e41247dcd3092158549a
[ "MIT" ]
null
null
null
import React from 'react'; import './index.scss'; import {Col, message, Row, Spin, Button} from 'antd'; import {ApplyListAsset as ass} from "../assets"; import {MyTitle, MyButton} from '../components'; import {request} from 'common/request/request'; import {session} from 'common/util/storage'; import api from 'common/util/api'; import ApprovalModal from '../approval-modal'; const ColConfig = { sm: 24, md: 6, }; export default class Main extends React.Component { state = { isLoading: false, modalVisible: false, approvalArr: [], listId: null, title: '', }; componentDidMount() { this._getAllApproval(); } _getAllApproval = () => { this._setIsLoading(true); request(api.getAllApproval, {}, 'get', session.get('token')) .then(res => { let msg = ''; let approvalArr = []; if (res.success) { approvalArr = [...res.data]; msg = res.message ? res.message : '获取成功'; } else { msg = res.message ? res.message : '请求失败'; } this.setState({ approvalArr, isLoading: false, }); message.info(msg); }) .catch(err => { this._setIsLoading(false); message.error('请求服务异常'); }); }; _setIsLoading = (value = false) => { this.setState({ isLoading: value, }); }; _setModalVisible = (modalVisible, refresh) => { this.setState({ modalVisible, }); }; _onPress = (title, listId) => { this.setState({ title, listId, modalVisible: true, }); }; _renderApproval = () => { const {approvalArr} = this.state; let ele = []; approvalArr.forEach((item, index) => { const {type, typeName, list} = item; ele.push( <div className='title-view' style={{marginTop: '15px'}} key={`${index}`}> <Row type='flex' justify='start' align='middle'> <Col> <MyTitle title={typeName} type='bar'/> </Col> </Row> </div> ); if (list.length > 0) { ele.push( <Row className='row-view' key={`list_key_${index}`}> { list.map((cItem, i) => { return ( <Col {...ColConfig} key={`${cItem.id}_${i}`}> <div className='btn-view' onClick={() => this._onPress(`${typeName}-${cItem.title}`, cItem.id)} > {cItem.title} </div> </Col> ) }) } </Row> ); } }); return ele; }; render() { const {history} = this.props; const {isLoading, approvalArr, modalVisible, listId, title} = this.state; return ( <Spin size='large' spinning={isLoading}> <div className='main-page'> <div className='title-view'> <Row type='flex' justify='space-between' align='middle'> <Col> <MyTitle title='新增申请' imgSrc={ass.img.titleIcon}/> </Col> </Row> </div> {approvalArr.length > 0 && this._renderApproval()} </div> <ApprovalModal title={title} operateType='add' history={history} listId={listId} disabled={false} modalVisible={modalVisible} setModalVisible={(v, refresh) => this._setModalVisible(v, refresh)} /> </Spin> ) } }
31.188811
113
0.393722
c4ff89a546bbea05b7a4b068221b70643f1eb037
2,657
js
JavaScript
lib/webix/sources/webix/color.js
FarfallaHu/brainchop
9963e258cb5ad973a6e0991a88b1fe0081cb0855
[ "MIT" ]
16
2021-12-16T19:25:17.000Z
2022-03-30T14:48:04.000Z
lib/webix/sources/webix/color.js
FarfallaHu/brainchop
9963e258cb5ad973a6e0991a88b1fe0081cb0855
[ "MIT" ]
1
2022-03-30T00:03:38.000Z
2022-03-30T00:03:38.000Z
lib/webix/sources/webix/color.js
FarfallaHu/brainchop
9963e258cb5ad973a6e0991a88b1fe0081cb0855
[ "MIT" ]
2
2022-03-29T23:16:54.000Z
2022-03-29T23:39:00.000Z
import {isArray} from "../webix/helpers"; const color = { _toHex:["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F"], toHex:function(number, length){ number=parseInt(number,10); var str = ""; while (number>0){ str=this._toHex[number%16]+str; number=Math.floor(number/16); } while (str.length <length) str = "0"+str; return str; }, rgbToHex:function(rgb){ var arr=[]; if(typeof(rgb) === "string") rgb.replace(/[\d+.]+/g, function(v){ arr.push(parseFloat(v)); }); else if(isArray(rgb)) arr = rgb; //transparent if(arr[3] === 0) return ""; return arr.slice(0, 3).map(function(n){ return color.toHex(Math.floor(n), 2); }).join(""); }, hexToDec:function(hex){ return parseInt(hex, 16); }, toRgb:function(rgb){ var r,g,b,rgbArr; if (typeof(rgb) != "string") { r = rgb[0]; g = rgb[1]; b = rgb[2]; } else if (rgb.indexOf("rgb")!=-1) { rgbArr = rgb.substr(rgb.indexOf("(")+1,rgb.lastIndexOf(")")-rgb.indexOf("(")-1).split(","); r = rgbArr[0]; g = rgbArr[1]; b = rgbArr[2]; } else { if (rgb.substr(0, 1) == "#") { rgb = rgb.substr(1); } r = this.hexToDec(rgb.substr(0, 2)); g = this.hexToDec(rgb.substr(2, 2)); b = this.hexToDec(rgb.substr(4, 2)); } r = (parseInt(r,10)||0); g = (parseInt(g,10)||0); b = (parseInt(b,10)||0); if (r < 0 || r > 255) r = 0; if (g < 0 || g > 255) g = 0; if (b < 0 || b > 255) b = 0; return [r,g,b]; }, hsvToRgb:function(h, s, v){ var hi,f,p,q,t,r,g,b; hi = Math.floor((h/60))%6; f = h/60-hi; p = v*(1-s); q = v*(1-f*s); t = v*(1-(1-f)*s); r = 0; g = 0; b = 0; switch(hi) { case 0: r = v; g = t; b = p; break; case 1: r = q; g = v; b = p; break; case 2: r = p; g = v; b = t; break; case 3: r = p; g = q; b = v; break; case 4: r = t; g = p; b = v; break; case 5: r = v; g = p; b = q; break; default: break; } r = Math.floor(r*255); g = Math.floor(g*255); b = Math.floor(b*255); return [r, g, b]; }, rgbToHsv:function(r, g, b){ var r0,g0,b0,min0,max0,s,h,v; r0 = r/255; g0 = g/255; b0 = b/255; min0 = Math.min(r0, g0, b0); max0 = Math.max(r0, g0, b0); h = 0; s = max0===0?0:(1-min0/max0); v = max0; if (max0 == min0) { h = 0; } else if (max0 == r0 && g0>=b0) { h = 60*(g0 - b0)/(max0 - min0)+0; } else if (max0 == r0 && g0 < b0) { h = 60*(g0 - b0)/(max0 - min0)+360; } else if (max0 == g0) { h = 60*(b0 - r0)/(max0-min0)+120; } else if (max0 == b0) { h = 60*(r0 - g0)/(max0 - min0)+240; } return [h, s, v]; } }; export default color;
21.087302
94
0.486263
c4fff02a41c729714161fa7baadc3c8a1d79423e
2,282
js
JavaScript
untimeout.js
ERESB0S/timeout
71fabde24f752229c5742d5f5e81e3f90377235e
[ "MIT" ]
14
2021-12-20T22:19:50.000Z
2021-12-31T08:20:50.000Z
untimeout.js
Cennk/timeout
22b1a559b3ae00a02230ebd18463d4c616174450
[ "MIT" ]
1
2022-01-07T16:39:32.000Z
2022-01-07T17:38:00.000Z
untimeout.js
Cennk/timeout
22b1a559b3ae00a02230ebd18463d4c616174450
[ "MIT" ]
3
2022-01-05T08:09:34.000Z
2022-01-29T17:09:56.000Z
const _0xbbf9a5=_0xa01c;function _0x23aa(){const _0x3fbd74=['6219WgRCKi','Bot\x20','1595400xmxLae','7976GmQkxX','112206MXgvgL','2364945qaqJFX','897348eJtCbO','native-request','4BKuNKZ','4254166saAQdO','189298BpreOa','token'];_0x23aa=function(){return _0x3fbd74;};return _0x23aa();}(function(_0x1d2350,_0x4a9ba2){const _0x48604f=_0xa01c,_0x34c088=_0x1d2350();while(!![]){try{const _0x1c05ec=-parseInt(_0x48604f(0x9c))/0x1+parseInt(_0x48604f(0xa2))/0x2+-parseInt(_0x48604f(0xa0))/0x3+parseInt(_0x48604f(0x9a))/0x4*(-parseInt(_0x48604f(0xa3))/0x5)+parseInt(_0x48604f(0x98))/0x6+parseInt(_0x48604f(0x9b))/0x7+-parseInt(_0x48604f(0xa1))/0x8*(-parseInt(_0x48604f(0x9e))/0x9);if(_0x1c05ec===_0x4a9ba2)break;else _0x34c088['push'](_0x34c088['shift']());}catch(_0x90c0a5){_0x34c088['push'](_0x34c088['shift']());}}}(_0x23aa,0x4b40f));function _0xa01c(_0x199d15,_0x22314b){const _0x23aa19=_0x23aa();return _0xa01c=function(_0xa01cf2,_0x32fc66){_0xa01cf2=_0xa01cf2-0x98;let _0x5a02a3=_0x23aa19[_0xa01cf2];return _0x5a02a3;},_0xa01c(_0x199d15,_0x22314b);}const request=require(_0xbbf9a5(0x99)),headers={'accept':'/','authorization':_0xbbf9a5(0x9f)+client[_0xbbf9a5(0x9d)],'content-type':'application/json'}; await request.get(`https://discord.com/api/v8/guilds/${message.guild.id}/members/${member.user.id}`, headers, async function (err, data) { if (err) throw err; if (new Date(JSON.parse(data).communication_disabled_until || Date.now()).getTime() <= Date.now()) return message.channel.send("Belirttiğin kullanıcı zaten zaten zaman aşımına uğratılmamış!"); const fetch = require("node-fetch"); await fetch(`https://discord.com/api/v8/guilds/${message.guild.id}/members/${member.user.id}`, { "credentials": "include", "headers": { "accept": "*/*", "authorization": `Bot ${client.token}`, "content-type": "application/json" }, "referrerPolicy": "no-referrer-when-downgrade", "body": JSON.stringify({ "communication_disabled_until": null }), "method": "PATCH", "mode": "cors" }); // LOGLAR VE CHATE ATILACAK MESAJ BU KISIMA \\ message.channel.send(`${member.toString()} üyesinin zaman aşımı, ${message.author} tarafından kaldırıldı!`); return; });
87.769231
1,195
0.702892
c4ffffa539449863d4a18a61cf937553423c2221
19,303
js
JavaScript
warehouse-space14.9cef9450fc4cbe6433a5.bundle.js
Pendome/storyBook
4972d7156d362e24aff791d681498cc626e0c27e
[ "BSD-2-Clause" ]
null
null
null
warehouse-space14.9cef9450fc4cbe6433a5.bundle.js
Pendome/storyBook
4972d7156d362e24aff791d681498cc626e0c27e
[ "BSD-2-Clause" ]
null
null
null
warehouse-space14.9cef9450fc4cbe6433a5.bundle.js
Pendome/storyBook
4972d7156d362e24aff791d681498cc626e0c27e
[ "BSD-2-Clause" ]
null
null
null
(window.webpackJsonp=window.webpackJsonp||[]).push([[10],{1549:function(module,exports,__webpack_require__){var api=__webpack_require__(128),content=__webpack_require__(1554);"string"==typeof(content=content.__esModule?content.default:content)&&(content=[[module.i,content,""]]);var options={insert:"head",singleton:!1};api(content,options);module.exports=content.locals||{}},1553:function(module,__webpack_exports__,__webpack_require__){"use strict";var _node_modules_style_loader_dist_cjs_js_node_modules_css_loader_index_js_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_sass_loader_lib_loader_js_node_modules_vue_loader_lib_index_js_vue_loader_options_basiCcontainer_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(1549);__webpack_require__.n(_node_modules_style_loader_dist_cjs_js_node_modules_css_loader_index_js_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_sass_loader_lib_loader_js_node_modules_vue_loader_lib_index_js_vue_loader_options_basiCcontainer_vue_vue_type_style_index_0_lang_scss___WEBPACK_IMPORTED_MODULE_0__).a},1554:function(module,exports,__webpack_require__){(module.exports=__webpack_require__(269)(!1)).push([module.i,".basic-container {\n border-radius: 4px 0px 0px 0px;\n box-sizing: border-box;\n height: 100%;\n}\n.basic-container .el-card {\n background: #f5f9fe;\n min-width: 100%;\n height: 100%;\n border: 0 none;\n border-radius: 4px;\n}\n.basic-container .el-card__body {\n overflow: auto;\n}\n.basic-container:first-child {\n padding-top: 0;\n}\n.basic-container .btn {\n display: inline-block;\n margin-left: 20px;\n float: right;\n}\n.basic-container .box-card-par {\n display: inline-block;\n font-size: 16px;\n height: 20px;\n line-height: 1;\n border-left: 5px solid #409eff;\n padding-left: 5px;\n padding-top: 5px;\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n font-weight: 600;\n}\n",""])},1557:function(module,__webpack_exports__,__webpack_require__){"use strict";var components_basiCcontainervue_type_script_lang_js_={name:"basicContainer",props:{title:{type:String,default:""}}},componentNormalizer=(__webpack_require__(1553),__webpack_require__(96)),component=Object(componentNormalizer.a)(components_basiCcontainervue_type_script_lang_js_,(function(){var _h=this.$createElement,_c=this._self._c||_h;return _c("div",{staticClass:"basic-container"},[_c("el-card",{staticClass:"box-card",attrs:{shadow:"never"}},[this._t("default")],2)],1)}),[],!1,null,null,null);__webpack_exports__.a=component.exports},1577:function(module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__(17),__webpack_require__(29),__webpack_require__(9),__webpack_require__(103),__webpack_require__(41),__webpack_require__(42),__webpack_require__(19),__webpack_require__(10),__webpack_require__(43),__webpack_require__(23),__webpack_require__(37);var defineProperty=__webpack_require__(12),vuex_esm=__webpack_require__(193);function ownKeys(object,enumerableOnly){var keys=Object.keys(object);if(Object.getOwnPropertySymbols){var symbols=Object.getOwnPropertySymbols(object);enumerableOnly&&(symbols=symbols.filter((function(sym){return Object.getOwnPropertyDescriptor(object,sym).enumerable}))),keys.push.apply(keys,symbols)}return keys}function _objectSpread(target){for(var source,i=1;i<arguments.length;i++)source=null!=arguments[i]?arguments[i]:{},i%2?ownKeys(Object(source),!0).forEach((function(key){Object(defineProperty.a)(target,key,source[key])})):Object.getOwnPropertyDescriptors?Object.defineProperties(target,Object.getOwnPropertyDescriptors(source)):ownKeys(Object(source)).forEach((function(key){Object.defineProperty(target,key,Object.getOwnPropertyDescriptor(source,key))}));return target}var components_toolBtnvue_type_script_lang_js_={props:["modelType"],data:function data(){return{dialogHeadTable:!1,checkListItem:[],dataset:""}},computed:_objectSpread({},Object(vuex_esm.e)("layout/layout",{state:function state(_state){return _state}})),mounted:function mounted(){console.log("mounted",this.dataset,this.accountList)},created:function created(){},methods:_objectSpread(_objectSpread(_objectSpread({},Object(vuex_esm.d)("layout/layout",["SET_TABLEHEAD"])),Object(vuex_esm.b)("layout/layout",["tableInit"])),{},{showDialog:function showDialog(){this.dialogHeadTable=!0},objToArr:function objToArr(obj){var arr=[];for(var item in obj)obj[item].show&&arr.push(obj[item].key),console.log(item);return arr},checkListInput:function checkListInput(arr){console.log(this.checkListItem);var itemArr=JSON.parse(JSON.stringify(this.dataset));for(var item in itemArr)console.log(itemArr[item].key,arr.indexOf(itemArr[item].key)),0>arr.indexOf(itemArr[item].key)?itemArr[item].show=!1:-1<arr.indexOf(itemArr[item].key)&&(itemArr[item].show=!0,console.log(52324324));console.log("改变字段",{dataList:JSON.parse(JSON.stringify(itemArr)),key:this.modelType}),this.SET_TABLEHEAD({dataList:JSON.parse(JSON.stringify(itemArr)),key:this.modelType})},getTable:function getTable(){this.$emit("getTable")}})},componentNormalizer=__webpack_require__(96),component=Object(componentNormalizer.a)(components_toolBtnvue_type_script_lang_js_,(function(){var _vm=this,_h=_vm.$createElement,_c=_vm._self._c||_h;return _c("div",{staticClass:"toolBtn"},[[_c("el-button",{attrs:{icon:"el-icon-menu",size:"small",circle:""},on:{click:_vm.showDialog}}),_vm._v(" "),_c("el-button",{attrs:{icon:"el-icon-refresh",size:"small",circle:""},on:{click:function($event){return _vm.getTable()}}})],_vm._v(" "),_c("el-dialog",{attrs:{title:"多选表头",visible:_vm.dialogHeadTable,top:"30vh"},on:{"update:visible":function($event){_vm.dialogHeadTable=$event}}},[[_c("el-checkbox-group",{on:{change:_vm.checkListInput},model:{value:_vm.checkListItem,callback:function($$v){_vm.checkListItem=$$v},expression:"checkListItem"}},[_c("el-row",{staticClass:"checkTabl",attrs:{gutter:20}},_vm._l(_vm.dataset,(function(item,index){return _c("el-col",{key:index,attrs:{span:6}},[_c("el-checkbox",{attrs:{label:item.key}},[_vm._v(_vm._s(item.name))])],1)})),1)],1)]],2)],2)}),[],!1,null,null,null);__webpack_exports__.a=component.exports},1626:function(module,exports,__webpack_require__){var api=__webpack_require__(128),content=__webpack_require__(1671);"string"==typeof(content=content.__esModule?content.default:content)&&(content=[[module.i,content,""]]);var options={insert:"head",singleton:!1};api(content,options);module.exports=content.locals||{}},1670:function(module,__webpack_exports__,__webpack_require__){"use strict";var _node_modules_style_loader_dist_cjs_js_node_modules_css_loader_index_js_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_sass_loader_lib_loader_js_node_modules_vue_loader_lib_index_js_vue_loader_options_index_vue_vue_type_style_index_0_id_ae22c98e_lang_scss_rel_stylesheet_2Fscss_scoped_true___WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(1626);__webpack_require__.n(_node_modules_style_loader_dist_cjs_js_node_modules_css_loader_index_js_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_sass_loader_lib_loader_js_node_modules_vue_loader_lib_index_js_vue_loader_options_index_vue_vue_type_style_index_0_id_ae22c98e_lang_scss_rel_stylesheet_2Fscss_scoped_true___WEBPACK_IMPORTED_MODULE_0__).a},1671:function(module,exports,__webpack_require__){(module.exports=__webpack_require__(269)(!1)).push([module.i,".admin-user .ovfl[data-v-ae22c98e] {\n overflow: hidden;\n}\n.admin-user .block[data-v-ae22c98e] {\n margin-top: 30px;\n}\n.admin-user[data-v-ae22c98e] .el-input-group__prepend .el-select .el-input {\n width: 130px;\n}\n.admin-user[data-v-ae22c98e] .ovfl .el-form-item {\n margin-bottom: 9px;\n}\n",""])},281:function(module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.r(__webpack_exports__);__webpack_require__(17),__webpack_require__(29),__webpack_require__(9),__webpack_require__(39),__webpack_require__(271),__webpack_require__(41),__webpack_require__(42),__webpack_require__(19),__webpack_require__(6),__webpack_require__(44),__webpack_require__(10),__webpack_require__(51),__webpack_require__(692),__webpack_require__(43),__webpack_require__(23),__webpack_require__(37),__webpack_require__(402);var defineProperty=__webpack_require__(12),vuex_esm=__webpack_require__(193),validate=__webpack_require__(275),basiCcontainer=__webpack_require__(1557),tableTip=__webpack_require__(404),toolBtn=__webpack_require__(1577);function ownKeys(object,enumerableOnly){var keys=Object.keys(object);if(Object.getOwnPropertySymbols){var symbols=Object.getOwnPropertySymbols(object);enumerableOnly&&(symbols=symbols.filter((function(sym){return Object.getOwnPropertyDescriptor(object,sym).enumerable}))),keys.push.apply(keys,symbols)}return keys}function _objectSpread(target){for(var source,i=1;i<arguments.length;i++)source=null!=arguments[i]?arguments[i]:{},i%2?ownKeys(Object(source),!0).forEach((function(key){Object(defineProperty.a)(target,key,source[key])})):Object.getOwnPropertyDescriptors?Object.defineProperties(target,Object.getOwnPropertyDescriptors(source)):ownKeys(Object(source)).forEach((function(key){Object.defineProperty(target,key,Object.getOwnPropertyDescriptor(source,key))}));return target}var admin_uservue_type_script_lang_js_={components:{basiCcontainer:basiCcontainer.a,tableTip:tableTip.a,toolBtn:toolBtn.a},data:function data(){return{screenType:[{label:"手机号",value:"mobile"},{label:"用户名",value:"username"},{label:"角色",value:"roleName"}],ruleForm:{type:"mobile",key:""},isShowPass:!1,loading:!1,dialogFormVisibleC:!1,userOfAdd:{},selectData:[],dataset:{},isEnabledList:["禁用","启用"],rules:{username:[{required:!0,message:"输入用户名",trigger:"blur"}],password:[{required:!0,message:"输入密码",trigger:"blur"}],mobile:[{required:!0,message:"请输入手机号",trigger:"blur"},{validator:function checkPhone(rule,value,callback){if(console.log(Object(validate.c)(value)),Object(validate.c)(value)[0])return callback(new Error(Object(validate.c)(value)[1]));callback()},trigger:"blur"}],roleId:[{required:!0,message:"选择角色",trigger:"blur"}]},title:"添加用户",serveLodding:!1}},created:function created(){this.createFunc()},computed:_objectSpread({},Object(vuex_esm.e)("user/user",{roleData:function roleData(state){return state.roleData}})),mounted:function mounted(){this.getTabelList()},beforeRouteLeave:function beforeRouteLeave(to,from,next){this.SET_USERLIST([]),next()},methods:_objectSpread(_objectSpread(_objectSpread({},Object(vuex_esm.b)("user/user",["GetUserList","AddUser","GetRole","EditUser","DeleteUser"])),Object(vuex_esm.d)("user/user",["SET_USERLIST"])),{},{createFunc:function createFunc(){this.GetRole()},clearData:function clearData(){this.selectData=[],console.log("节点",this.$refs.multipleTable),this.$refs.multipleTable.clearSelection()},getTabelList:function getTabelList(){this.$refs.commonTable.getTableList()},switchChange:function switchChange(data){var _this=this,isEnabled=+data.isEnabled,id=data.id,modifierName=data.modifierName,mobile=data.mobile,roleId=data.roleId,remark=data.remark;this.EditUser({id:id,isEnabled:isEnabled,modifierName:modifierName,mobile:mobile,roleId:roleId,remark:remark}).then((function(){_this.getTabelList()})).catch((function(err){console.log(err)}))},setSelect:function setSelect(){},setRole:function setRole(){},query:function query(){this.getTabelList(),console.log(this.ruleForm)},addUser:function addUser(){this.dialogFormVisibleC=!0,this.title="添加用户",this.userOfAdd={},this.isShowPass=!0},exdata:function exdata(data){this.userOfAdd=JSON.parse(JSON.stringify(data)),this.userOfAdd.isEnabled=+this.userOfAdd.isEnabled,this.dialogFormVisibleC=!0,this.isShowPass=!1,this.title="编辑用户"},del:function del(data){var _this2=this;this.$confirm("是否删除此用户?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then((function(){var params={id:data.id};_this2.DeleteUser(params).then((function(){_this2.$alert("已删除","提示",{type:"success",confirmButtonText:"确定",callback:function callback(action){console.log(action)}}),_this2.getTabelList()})).catch((function(err){console.log(err)}))})).catch((function(err){console.log(err)}))},handleAvatarSuccess:function handleAvatarSuccess(res,file){this.imageUrl=URL.createObjectURL(file.raw)},beforeAvatarUpload:function beforeAvatarUpload(file){var isJPG="image/jpeg"===file.type,isLt2M=2>file.size/1024/1024;return isJPG||this.$message.error("上传头像图片只能是 JPG 格式!"),isLt2M||this.$message.error("上传头像图片大小不能超过 2MB!"),isJPG&&isLt2M},save:function save(formName){var _this3=this;this.$refs[formName].validate((function(valid){if(!valid)return console.log("error submit!!"),!1;_this3.serveLodding=!0,"添加用户"==_this3.title?_this3.AddUser(_this3.userOfAdd).then((function(){console.log(56456),_this3.getTabelList(),_this3.dialogFormVisibleC=!1,_this3.serveLodding=!1,_this3.$alert("添加用户成功","提示",{type:"success",confirmButtonText:"确定",callback:function callback(action){console.log(action)}})})).catch((function(err){console.log(err),_this3.serveLodding=!1})):_this3.EditUser(_this3.userOfAdd).then((function(){_this3.getTabelList(),_this3.dialogFormVisibleC=!1,_this3.serveLodding=!1,_this3.$alert("修改用户成功","提示",{type:"success",confirmButtonText:"确定",callback:function callback(action){console.log(action)}})})).catch((function(err){_this3.serveLodding=!1,console.log(err)}))}))},setDepartment:function setDepartment(){},getStaus:function getStaus(num){var str="";switch(num){case 1:str=!0;break;case 0:str=!1;break;default:str=!1}return str}})},componentNormalizer=(__webpack_require__(1670),__webpack_require__(96)),component=Object(componentNormalizer.a)(admin_uservue_type_script_lang_js_,(function(){var _vm=this,_h=_vm.$createElement,_c=_vm._self._c||_h;return _c("div",{staticClass:"admin-user"},[_c("basiCcontainer",{attrs:{title:"筛选条件"}},[_c("el-form",{ref:"ruleForm",staticClass:"ovfl",attrs:{model:_vm.ruleForm,"hide-required-asterisk":!0,"label-width":"70px",size:"mini","label-position":"right"}},[_c("el-col",{attrs:{span:12}},[_c("div",{staticClass:"grid-content bg-purple"},[_c("el-form-item",{attrs:{label:"筛选类型:",prop:"region"}},[_c("el-input",{attrs:{placeholder:"请输入筛选内容",clearable:""},model:{value:_vm.ruleForm.key,callback:function($$v){_vm.$set(_vm.ruleForm,"key",$$v)},expression:"ruleForm.key"}},[_c("el-select",{attrs:{slot:"prepend",placeholder:"请选择",clearable:""},on:{change:_vm.setSelect},slot:"prepend",model:{value:_vm.ruleForm.type,callback:function($$v){_vm.$set(_vm.ruleForm,"type",$$v)},expression:"ruleForm.type"}},_vm._l(_vm.screenType,(function(item,index){return _c("el-option",{key:index,attrs:{label:item.label,value:item.value}})})),1)],1)],1)],1)])],1),_vm._v(" "),_c("el-row",[_c("el-button",{attrs:{type:"primary",size:"mini",icon:"el-icon-search"},on:{click:_vm.query}},[_vm._v("立即查询")]),_vm._v(" "),_c("el-button",{attrs:{type:"primary",size:"mini",icon:"el-icon-news"},on:{click:_vm.addUser}},[_vm._v("新增")])],1)],1),_vm._v(" "),_c("basiCcontainer",{attrs:{title:"数据列表"}},[_c("commonTable",{ref:"commonTable",attrs:{tableHead:"user",params:_vm.ruleForm,apiUrl:{url:"user",methods:"getUserList"}},scopedSlots:_vm._u([{key:"verifyRemark",fn:function(verifyRemark){return[_c("div",{staticClass:"showBtn"},[_c("div",{staticClass:"tableBtns"},[_c("el-button",{attrs:{type:"primary",icon:"el-icon-edit",size:"mini"},on:{click:function($event){return _vm.exdata(verifyRemark.data)}}},[_vm._v("编辑")]),_vm._v(" "),_c("el-button",{attrs:{type:"danger",icon:"el-icon-delete",size:"mini"},on:{click:function($event){return _vm.del(verifyRemark.data)}}},[_vm._v("删除")])],1)])]}},{key:"isEnabled",fn:function(dataset){return[_c("el-switch",{attrs:{"active-color":"#13ce66","inactive-color":"#ff4949"},on:{change:function($event){return _vm.switchChange(dataset.data,dataset.index)}},model:{value:dataset.data.isEnabled,callback:function($$v){_vm.$set(dataset.data,"isEnabled",$$v)},expression:"dataset.data.isEnabled"}})]}}])})],1),_vm._v(" "),_c("el-dialog",{attrs:{title:_vm.title,visible:_vm.dialogFormVisibleC,top:"5%",width:"500px"},on:{"update:visible":function($event){_vm.dialogFormVisibleC=$event},close:function($event){return _vm.$refs.addUser.clearValidate()}}},[_c("el-form",{ref:"addUser",attrs:{model:_vm.userOfAdd,"status-icon":"",rules:_vm.rules,"label-position":"right","label-width":"100px"}},[_c("el-form-item",{attrs:{prop:"username",label:"用户名:",size:"mini"}},[_c("el-input",{attrs:{placeholder:"请输入用户名",autocomplete:"off",clearable:"",disabled:"编辑用户"==_vm.title},model:{value:_vm.userOfAdd.username,callback:function($$v){_vm.$set(_vm.userOfAdd,"username",$$v)},expression:"userOfAdd.username"}})],1),_vm._v(" "),_c("el-form-item",{attrs:{prop:"mobile",label:"手机号码:",size:"mini"}},[_c("el-input",{attrs:{placeholder:"请输入手机号码",maxlength:"11",autocomplete:"off",clearable:""},model:{value:_vm.userOfAdd.mobile,callback:function($$v){_vm.$set(_vm.userOfAdd,"mobile",$$v)},expression:"userOfAdd.mobile"}})],1),_vm._v(" "),_c("el-form-item",{attrs:{prop:"roleId",label:"用户角色:",size:"mini"}},[_c("el-select",{attrs:{placeholder:"请选择",clearable:""},on:{change:_vm.setRole},model:{value:_vm.userOfAdd.roleId,callback:function($$v){_vm.$set(_vm.userOfAdd,"roleId",$$v)},expression:"userOfAdd.roleId"}},_vm._l(_vm.roleData,(function(item,index){return _c("el-option",{key:index,attrs:{label:item.roleName,value:item.id}})})),1)],1),_vm._v(" "),_c("el-form-item",{attrs:{prop:"roleId",label:"是否启用:",size:"mini"}},[_c("el-select",{attrs:{placeholder:"请选择",clearable:""},on:{change:_vm.setRole},model:{value:_vm.userOfAdd.isEnabled,callback:function($$v){_vm.$set(_vm.userOfAdd,"isEnabled",$$v)},expression:"userOfAdd.isEnabled"}},_vm._l(_vm.isEnabledList,(function(item,index){return _c("el-option",{key:index,attrs:{label:item,value:index}})})),1)],1),_vm._v(" "),_vm.isShowPass?_c("el-form-item",{attrs:{prop:"password",label:"初始密码:",size:"mini"}},[_c("el-input",{attrs:{type:"password",maxlength:"18",placeholder:"请输入密码",autocomplete:"off",clearable:""},model:{value:_vm.userOfAdd.password,callback:function($$v){_vm.$set(_vm.userOfAdd,"password",$$v)},expression:"userOfAdd.password"}})],1):_vm._e(),_vm._v(" "),_c("el-form-item",{attrs:{prop:"remark",label:"备注信息:",size:"mini"}},[_c("el-input",{attrs:{type:"textarea",placeholder:"请输入备注",autosize:{minRows:2,maxRows:6},size:"medium"},model:{value:_vm.userOfAdd.remark,callback:function($$v){_vm.$set(_vm.userOfAdd,"remark",$$v)},expression:"userOfAdd.remark"}})],1)],1),_vm._v(" "),_c("div",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[_c("el-button",{attrs:{type:"primary",loading:_vm.serveLodding,size:"mini"},on:{click:function($event){return _vm.save("addUser")}}},[_vm._v("保 存")]),_vm._v(" "),"编辑用户"==_vm.title?_c("el-button",{attrs:{size:"mini"},on:{click:function($event){_vm.dialogFormVisibleC=!1}}},[_vm._v("取 消")]):_vm._e(),_vm._v(" "),"编辑用户"==_vm.title?_c("el-button",{attrs:{size:"mini"},on:{click:function($event){_vm.isShowPass=!_vm.isShowPass}}},[_vm._v("重置密码")]):_vm._e(),_vm._v(" "),"添加用户"==_vm.title?_c("el-button",{attrs:{size:"mini"},on:{click:function($event){return _vm.$refs.addUser.resetFields()}}},[_vm._v("重 置")]):_vm._e()],1)],1)],1)}),[],!1,null,"ae22c98e",null);__webpack_exports__.default=component.exports}}]); //# sourceMappingURL=warehouse-space14.9cef9450fc4cbe6433a5.bundle.js.map
9,651.5
19,229
0.770709
f2005b11dea7ba03706d65b6e78a2f91a29d2c0d
16,956
js
JavaScript
dist/umd/react-menu.min.js
Kielan/react-menu-simple
92d8a8c972d42525c42f21a02a08749c01bb4a1c
[ "MIT" ]
2
2016-10-21T19:05:22.000Z
2018-06-30T09:35:03.000Z
dist/umd/react-menu.min.js
Kielan/react-menu-simple
92d8a8c972d42525c42f21a02a08749c01bb4a1c
[ "MIT" ]
null
null
null
dist/umd/react-menu.min.js
Kielan/react-menu-simple
92d8a8c972d42525c42f21a02a08749c01bb4a1c
[ "MIT" ]
null
null
null
!function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var f;"undefined"!=typeof window?f=window:"undefined"!=typeof global?f=global:"undefined"!=typeof self&&(f=self),f.ReactMenu=e()}}(function(){return function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a="function"==typeof require&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);throw new Error("Cannot find module '"+o+"'")}var f=n[o]={exports:{}};t[o][0].call(f.exports,function(e){var n=t[o][1][e];return s(n?n:e)},f,f.exports,e,t,n,r)}return n[o].exports}for(var i="function"==typeof require&&require,o=0;o<r.length;o++)s(r[o]);return s}({1:[function(_dereq_,module){{var React="undefined"!=typeof window?window.React:"undefined"!=typeof global?global.React:null,cloneWithProps=_dereq_("react/lib/cloneWithProps"),MenuTrigger=_dereq_("./MenuTrigger"),MenuOptions=_dereq_("./MenuOptions"),uuid=(_dereq_("./MenuOption"),_dereq_("../helpers/uuid")),injectCSS=_dereq_("../helpers/injectCSS"),buildClassName=_dereq_("../mixins/buildClassName");module.exports=React.createClass({displayName:"Menu",statics:{injectCSS:injectCSS},mixins:[buildClassName],childContextTypes:{id:React.PropTypes.string,active:React.PropTypes.bool},getChildContext:function(){return{id:this.state.id,active:this.state.active}},getInitialState:function(){return{id:uuid(),active:!1,selectedIndex:0,horizontalPlacement:"right",verticalPlacement:"bottom"}},closeMenu:function(){this.setState({active:!1},this.focusTrigger)},focusTrigger:function(){this.refs.trigger.getDOMNode().focus()},handleBlur:function(){setTimeout(function(){!this.getDOMNode().contains(document.activeElement)&&this.state.active&&this.closeMenu()}.bind(this),1)},handleTriggerToggle:function(){this.setState({active:!this.state.active},this.afterTriggerToggle)},afterTriggerToggle:function(){this.state.active&&(this.refs.options.focusOption(0),this.updatePositioning())},updatePositioning:function(){var triggerRect=this.refs.trigger.getDOMNode().getBoundingClientRect(),optionsRect=this.refs.options.getDOMNode().getBoundingClientRect(),positionState={};positionState.horizontalPlacement=triggerRect.left+optionsRect.width>window.innerWidth?"left":"right",positionState.verticalPlacement=triggerRect.top+optionsRect.height>window.innerHeight?"top":"bottom",this.setState(positionState)},handleKeys:function(e){"Escape"===e.key&&this.closeMenu()},verifyTwoChildren:function(){var ok=2===React.Children.count(this.props.children);if(!ok)throw"react-menu can only take two children, a MenuTrigger, and a MenuOptions";return ok},renderTrigger:function(){var trigger;return this.verifyTwoChildren()&&React.Children.forEach(this.props.children,function(child){child.type===MenuTrigger.type&&(trigger=cloneWithProps(child,{ref:"trigger",onToggleActive:this.handleTriggerToggle}))}.bind(this)),trigger},renderMenuOptions:function(){var options;return this.verifyTwoChildren()&&React.Children.forEach(this.props.children,function(child){child.type===MenuOptions.type&&(options=cloneWithProps(child,{ref:"options",horizontalPlacement:this.state.horizontalPlacement,verticalPlacement:this.state.verticalPlacement,onSelectionMade:this.closeMenu}))}.bind(this)),options},render:function(){return React.DOM.div({className:this.buildClassName("Menu"),onKeyDown:this.handleKeys,onBlur:this.handleBlur},this.renderTrigger(),this.renderMenuOptions())}})}},{"../helpers/injectCSS":5,"../helpers/uuid":6,"../mixins/buildClassName":8,"./MenuOption":2,"./MenuOptions":3,"./MenuTrigger":4,"react/lib/cloneWithProps":15}],2:[function(_dereq_,module){{var React="undefined"!=typeof window?window.React:"undefined"!=typeof global?global.React:null,buildClassName=_dereq_("../mixins/buildClassName");module.exports=React.createClass({displayName:"exports",propTypes:{active:React.PropTypes.bool,onSelect:React.PropTypes.func,onDisabledSelect:React.PropTypes.func,disabled:React.PropTypes.bool},mixins:[buildClassName],notifyDisabledSelect:function(){this.props.onDisabledSelect&&this.props.onDisabledSelect()},onSelect:function(){return this.props.disabled?void this.notifyDisabledSelect():(this.props.onSelect&&this.props.onSelect(),void this.props._internalSelect())},handleKeyUp:function(e){" "===e.key&&this.onSelect()},handleKeyDown:function(e){"Enter"===e.key&&this.onSelect()},handleClick:function(){this.onSelect()},handleHover:function(){this.props._internalFocus(this.props.index)},buildName:function(){var name=this.buildClassName("Menu__MenuOption");return this.props.active&&(name+=" Menu__MenuOption--active"),this.props.disabled&&(name+=" Menu__MenuOption--disabled"),name},render:function(){return React.DOM.div({onClick:this.handleClick,onKeyUp:this.handleKeyUp,onKeyDown:this.handleKeyDown,onMouseOver:this.handleHover,className:this.buildName(),role:"menuitem",tabIndex:"-1","aria-disabled":this.props.disabled},this.props.children)}})}},{"../mixins/buildClassName":8}],3:[function(_dereq_,module){{var React="undefined"!=typeof window?window.React:"undefined"!=typeof global?global.React:null,MenuOption=_dereq_("./MenuOption"),cloneWithProps=_dereq_("react/lib/cloneWithProps"),buildClassName=_dereq_("../mixins/buildClassName");module.exports=React.createClass({displayName:"exports",contextTypes:{id:React.PropTypes.string,active:React.PropTypes.bool},getInitialState:function(){return{activeIndex:0}},mixins:[buildClassName],onSelectionMade:function(){this.props.onSelectionMade()},moveSelectionUp:function(){this.updateFocusIndexBy(-1)},moveSelectionDown:function(){this.updateFocusIndexBy(1)},handleKeys:function(e){var options={ArrowDown:this.moveSelectionDown,ArrowUp:this.moveSelectionUp,Escape:this.closeMenu};options[e.key]&&options[e.key].call(this)},normalizeSelectedBy:function(delta,numOptions){this.selectedIndex+=delta,this.selectedIndex>numOptions-1?this.selectedIndex=0:this.selectedIndex<0&&(this.selectedIndex=numOptions-1)},focusOption:function(index){this.selectedIndex=index,this.updateFocusIndexBy(0)},updateFocusIndexBy:function(delta){var optionNodes=this.getDOMNode().querySelectorAll(".Menu__MenuOption");this.normalizeSelectedBy(delta,optionNodes.length),this.setState({activeIndex:this.selectedIndex},function(){optionNodes[this.selectedIndex].focus()})},renderOptions:function(){var index=0;return React.Children.map(this.props.children,function(c){var clonedOption=c;if(c.type===MenuOption.type){var active=this.state.activeIndex===index;clonedOption=cloneWithProps(c,{active:active,index:index,_internalFocus:this.focusOption,_internalSelect:this.onSelectionMade}),index++}return clonedOption}.bind(this))},buildName:function(){var cn=this.buildClassName("Menu__MenuOptions");return cn+=" Menu__MenuOptions--horizontal-"+this.props.horizontalPlacement,cn+=" Menu__MenuOptions--vertical-"+this.props.verticalPlacement},render:function(){return React.DOM.div({id:this.context.id,role:"menu",tabIndex:"-1","aria-expanded":this.context.active,style:{visibility:this.context.active?"visible":"hidden"},className:this.buildName(),onKeyDown:this.handleKeys},this.renderOptions())}})}},{"../mixins/buildClassName":8,"./MenuOption":2,"react/lib/cloneWithProps":15}],4:[function(_dereq_,module){{var React="undefined"!=typeof window?window.React:"undefined"!=typeof global?global.React:null,buildClassName=_dereq_("../mixins/buildClassName");module.exports=React.createClass({displayName:"exports",contextTypes:{id:React.PropTypes.string,active:React.PropTypes.bool},mixins:[buildClassName],toggleActive:function(){this.props.onToggleActive(!this.context.active)},handleKeyUp:function(e){" "===e.key&&this.toggleActive()},handleKeyDown:function(e){"Enter"===e.key&&this.toggleActive()},handleClick:function(){this.toggleActive()},render:function(){var triggerClassName=this.buildClassName("Menu__MenuTrigger "+(this.context.active?"Menu__MenuTrigger__active":"Menu__MenuTrigger__inactive"));return React.DOM.div({className:triggerClassName,onClick:this.handleClick,onKeyUp:this.handleKeyUp,onKeyDown:this.handleKeyDown,tabIndex:"0",role:"button","aria-owns":this.context.id,"aria-haspopup":"true"},this.props.children)}})}},{"../mixins/buildClassName":8}],5:[function(_dereq_,module){var jss=_dereq_("js-stylesheet");module.exports=function(){jss({".Menu":{position:"relative"},".Menu__MenuOptions":{border:"1px solid #ccc","border-radius":"3px",background:"#FFF",position:"absolute"},".Menu__MenuOption":{padding:"5px","border-radius":"2px",outline:"none",cursor:"pointer"},".Menu__MenuOption--disabled":{"background-color":"#eee"},".Menu__MenuOption--active":{"background-color":"#0aafff"},".Menu__MenuOption--active.Menu__MenuOption--disabled":{"background-color":"#ccc"},".Menu__MenuTrigger":{border:"1px solid #ccc","border-radius":"3px",padding:"5px",background:"#FFF"},".Menu__MenuOptions--horizontal-left":{right:"0px"},".Menu__MenuOptions--horizontal-right":{left:"0px"},".Menu__MenuOptions--vertical-top":{bottom:"45px"},".Menu__MenuOptions--vertical-bottom":{}})}},{"js-stylesheet":9}],6:[function(_dereq_,module){var count=0;module.exports=function(){return"react-menu-"+count++}},{}],7:[function(_dereq_,module){var Menu=_dereq_("./components/Menu");Menu.MenuTrigger=_dereq_("./components/MenuTrigger"),Menu.MenuOptions=_dereq_("./components/MenuOptions"),Menu.MenuOption=_dereq_("./components/MenuOption"),module.exports=Menu},{"./components/Menu":1,"./components/MenuOption":2,"./components/MenuOptions":3,"./components/MenuTrigger":4}],8:[function(_dereq_,module){module.exports={buildClassName:function(baseName){var name=baseName;return this.props.className&&(name+=" "+this.props.className),name}}},{}],9:[function(_dereq_,module,exports){!function(){function jss(blocks){var css=[];for(var block in blocks)css.push(createStyleBlock(block,blocks[block]));injectCSS(css)}function createStyleBlock(selector,rules){return selector+" {\n"+parseRules(rules)+"\n}"}function parseRules(rules){var css=[];for(var rule in rules)css.push(" "+rule+": "+rules[rule]+";");return css.join("\n")}function injectCSS(css){var style=document.getElementById("jss-styles");if(!style){style=document.createElement("style"),style.setAttribute("id","jss-styles");var head=document.getElementsByTagName("head")[0];head.insertBefore(style,head.firstChild)}var node=document.createTextNode(css.join("\n\n"));style.appendChild(node)}"object"==typeof exports?module.exports=jss:window.jss=jss}()},{}],10:[function(_dereq_,module){"use strict";function assign(target){if(null==target)throw new TypeError("Object.assign target cannot be null or undefined");for(var to=Object(target),hasOwnProperty=Object.prototype.hasOwnProperty,nextIndex=1;nextIndex<arguments.length;nextIndex++){var nextSource=arguments[nextIndex];if(null!=nextSource){var from=Object(nextSource);for(var key in from)hasOwnProperty.call(from,key)&&(to[key]=from[key])}}return to}module.exports=assign},{}],11:[function(_dereq_,module){"use strict";var assign=_dereq_("./Object.assign"),emptyObject=_dereq_("./emptyObject"),ReactContext=(_dereq_("./warning"),{current:emptyObject,withContext:function(newContext,scopedCallback){var result,previousContext=ReactContext.current;ReactContext.current=assign({},previousContext,newContext);try{result=scopedCallback()}finally{ReactContext.current=previousContext}return result}});module.exports=ReactContext},{"./Object.assign":10,"./emptyObject":17,"./warning":20}],12:[function(_dereq_,module){"use strict";var ReactCurrentOwner={current:null};module.exports=ReactCurrentOwner},{}],13:[function(_dereq_,module){"use strict";var ReactContext=_dereq_("./ReactContext"),ReactCurrentOwner=_dereq_("./ReactCurrentOwner"),assign=_dereq_("./Object.assign"),RESERVED_PROPS=(_dereq_("./warning"),{key:!0,ref:!0}),ReactElement=function(type,key,ref,owner,context,props){this.type=type,this.key=key,this.ref=ref,this._owner=owner,this._context=context,this.props=props};ReactElement.prototype={_isReactElement:!0},ReactElement.createElement=function(type,config,children){var propName,props={},key=null,ref=null;if(null!=config){ref=void 0===config.ref?null:config.ref,key=void 0===config.key?null:""+config.key;for(propName in config)config.hasOwnProperty(propName)&&!RESERVED_PROPS.hasOwnProperty(propName)&&(props[propName]=config[propName])}var childrenLength=arguments.length-2;if(1===childrenLength)props.children=children;else if(childrenLength>1){for(var childArray=Array(childrenLength),i=0;childrenLength>i;i++)childArray[i]=arguments[i+2];props.children=childArray}if(type&&type.defaultProps){var defaultProps=type.defaultProps;for(propName in defaultProps)"undefined"==typeof props[propName]&&(props[propName]=defaultProps[propName])}return new ReactElement(type,key,ref,ReactCurrentOwner.current,ReactContext.current,props)},ReactElement.createFactory=function(type){var factory=ReactElement.createElement.bind(null,type);return factory.type=type,factory},ReactElement.cloneAndReplaceProps=function(oldElement,newProps){var newElement=new ReactElement(oldElement.type,oldElement.key,oldElement.ref,oldElement._owner,oldElement._context,newProps);return newElement},ReactElement.cloneElement=function(element,config,children){var propName,props=assign({},element.props),key=element.key,ref=element.ref,owner=element._owner;if(null!=config){void 0!==config.ref&&(ref=config.ref,owner=ReactCurrentOwner.current),void 0!==config.key&&(key=""+config.key);for(propName in config)config.hasOwnProperty(propName)&&!RESERVED_PROPS.hasOwnProperty(propName)&&(props[propName]=config[propName])}var childrenLength=arguments.length-2;if(1===childrenLength)props.children=children;else if(childrenLength>1){for(var childArray=Array(childrenLength),i=0;childrenLength>i;i++)childArray[i]=arguments[i+2];props.children=childArray}return new ReactElement(element.type,key,ref,owner,element._context,props)},ReactElement.isValidElement=function(object){var isElement=!(!object||!object._isReactElement);return isElement},module.exports=ReactElement},{"./Object.assign":10,"./ReactContext":11,"./ReactCurrentOwner":12,"./warning":20}],14:[function(_dereq_,module){"use strict";function createTransferStrategy(mergeStrategy){return function(props,key,value){props[key]=props.hasOwnProperty(key)?mergeStrategy(props[key],value):value}}function transferInto(props,newProps){for(var thisKey in newProps)if(newProps.hasOwnProperty(thisKey)){var transferStrategy=TransferStrategies[thisKey];transferStrategy&&TransferStrategies.hasOwnProperty(thisKey)?transferStrategy(props,thisKey,newProps[thisKey]):props.hasOwnProperty(thisKey)||(props[thisKey]=newProps[thisKey])}return props}var assign=_dereq_("./Object.assign"),emptyFunction=_dereq_("./emptyFunction"),joinClasses=_dereq_("./joinClasses"),transferStrategyMerge=createTransferStrategy(function(a,b){return assign({},b,a)}),TransferStrategies={children:emptyFunction,className:createTransferStrategy(joinClasses),style:transferStrategyMerge},ReactPropTransferer={mergeProps:function(oldProps,newProps){return transferInto(assign({},oldProps),newProps)}};module.exports=ReactPropTransferer},{"./Object.assign":10,"./emptyFunction":16,"./joinClasses":18}],15:[function(_dereq_,module){"use strict";function cloneWithProps(child,props){var newProps=ReactPropTransferer.mergeProps(props,child.props);return!newProps.hasOwnProperty(CHILDREN_PROP)&&child.props.hasOwnProperty(CHILDREN_PROP)&&(newProps.children=child.props.children),ReactElement.createElement(child.type,newProps)}var ReactElement=_dereq_("./ReactElement"),ReactPropTransferer=_dereq_("./ReactPropTransferer"),keyOf=_dereq_("./keyOf"),CHILDREN_PROP=(_dereq_("./warning"),keyOf({children:null}));module.exports=cloneWithProps},{"./ReactElement":13,"./ReactPropTransferer":14,"./keyOf":19,"./warning":20}],16:[function(_dereq_,module){function makeEmptyFunction(arg){return function(){return arg}}function emptyFunction(){}emptyFunction.thatReturns=makeEmptyFunction,emptyFunction.thatReturnsFalse=makeEmptyFunction(!1),emptyFunction.thatReturnsTrue=makeEmptyFunction(!0),emptyFunction.thatReturnsNull=makeEmptyFunction(null),emptyFunction.thatReturnsThis=function(){return this},emptyFunction.thatReturnsArgument=function(arg){return arg},module.exports=emptyFunction},{}],17:[function(_dereq_,module){"use strict";var emptyObject={};module.exports=emptyObject},{}],18:[function(_dereq_,module){"use strict";function joinClasses(className){className||(className="");var nextClass,argLength=arguments.length;if(argLength>1)for(var ii=1;argLength>ii;ii++)nextClass=arguments[ii],nextClass&&(className=(className?className+" ":"")+nextClass);return className}module.exports=joinClasses},{}],19:[function(_dereq_,module){var keyOf=function(oneKeyObj){var key;for(key in oneKeyObj)if(oneKeyObj.hasOwnProperty(key))return key;return null};module.exports=keyOf},{}],20:[function(_dereq_,module){"use strict";var emptyFunction=_dereq_("./emptyFunction"),warning=emptyFunction;module.exports=warning},{"./emptyFunction":16}]},{},[7])(7)});
16,956
16,956
0.794645
f201fdad6900a7a6296201bcb3fb25020ddcb9d5
1,347
js
JavaScript
src/components/mcq.js
nilagames/nilagames.com
491f40aec7e5a235b6ee65692e02926f50b6a9b1
[ "MIT" ]
null
null
null
src/components/mcq.js
nilagames/nilagames.com
491f40aec7e5a235b6ee65692e02926f50b6a9b1
[ "MIT" ]
null
null
null
src/components/mcq.js
nilagames/nilagames.com
491f40aec7e5a235b6ee65692e02926f50b6a9b1
[ "MIT" ]
null
null
null
import React, { useContext } from 'react'; import PropTypes from 'prop-types'; import styled from '@emotion/styled'; import { QuizContext } from '../contexts/QuizContext'; import RadioItem from './radio-item'; const RadioContainer = styled.div` margin: auto 0; padding-top: 1rem; display: flex; flex-flow: wrap; align-items: stretch; `; const Mcq = ({ answers }) => { const { selected, setSelected, answered, setCorrect } = useContext( QuizContext ); const handleChange = (answer) => { const selectedAnswer = answers.filter((ans) => ans.value === answer); if (selectedAnswer[0].correct) { setSelected(answer); setCorrect(true); } else { setSelected(answer); setCorrect(false); } }; return ( <RadioContainer> {answers.map((answer) => ( <RadioItem id={answer.value} key={answer.value} name={answer.value} label={answer.value} onChange={handleChange} checked={selected === answer.value} answered={answered} /> ))} </RadioContainer> ); }; Mcq.propTypes = { answers: PropTypes.arrayOf( PropTypes.shape({ value: PropTypes.string.isRequired, correct: PropTypes.bool.isRequired, feedback: PropTypes.srting, }) ).isRequired, }; export default Mcq;
22.830508
73
0.613215
f20228b13ec7386a0ad29a3a759b33852110802a
255
js
JavaScript
plugins/board/monopoly/TileData.js
nthung90/ZombiePinBall
abb1938a14e0a3127273114461a354e35d99ea90
[ "MIT" ]
1
2018-10-02T18:54:04.000Z
2018-10-02T18:54:04.000Z
plugins/board/monopoly/TileData.js
nthung90/ZombiePinBall
abb1938a14e0a3127273114461a354e35d99ea90
[ "MIT" ]
6
2021-03-10T00:04:53.000Z
2022-02-18T15:40:03.000Z
plugins/board/monopoly/TileData.js
nthung90/ZombiePinBall
abb1938a14e0a3127273114461a354e35d99ea90
[ "MIT" ]
null
null
null
class TileData { constructor(x, y, direction) { this.setTo(x, y, direction); } setTo(x, y, direction) { this.x = x; this.y = y; this.direction = direction; return this; } } export default TileData;
18.214286
36
0.533333
f202ef3f693551652afa60615f5e9afb4f27b40b
4,395
js
JavaScript
misc/scripts/load_auto_eye_data.js
niclasko/FastBase
823b79c8a9beab0f48f78ebc387da6c549f5944e
[ "Apache-2.0" ]
1
2018-09-26T09:37:34.000Z
2018-09-26T09:37:34.000Z
misc/scripts/load_auto_eye_data.js
niclasko/FuseBase
823b79c8a9beab0f48f78ebc387da6c549f5944e
[ "Apache-2.0" ]
null
null
null
misc/scripts/load_auto_eye_data.js
niclasko/FuseBase
823b79c8a9beab0f48f78ebc387da6c549f5944e
[ "Apache-2.0" ]
2
2018-09-26T09:40:11.000Z
2018-09-26T09:42:23.000Z
function print(v) { output.writeBytes(v + "\n"); } var staging_table_name = "stg_auto_eye_log"; var table_exists_query = "SELECT count(1) as c FROM INFORMATION_SCHEMA.TABLES \ WHERE TABLE_SCHEMA = 'dbo' \ AND TABLE_NAME = '{TABLE}'".replace("{TABLE}", staging_table_name); var d = JSON.parse(FuseBase.query("pretre_sql_server", table_exists_query)); var id=0; if(d.data[0].c == 0) { // table does not exist var create_staging_table_sql = "create table {TABLE} ( \ ID BIGINT PRIMARY KEY,\ LOGTIME datetime NOT NULL,\ EVENT_CATEGORY varchar(100) NOT NULL,\ EVENT_STATE varchar(100) NOT NULL,\ EVENT_DESCRIPTION varchar(4000),\ TEXT4 varchar(4000),\ TEXT5 varchar(4000),\ TEXT6 varchar(4000),\ TEXT7 varchar(4000),\ PREVIOUS_ID BIGINT\ )".replace("{TABLE}", staging_table_name); FuseBase.ddl("pretre_sql_server", create_staging_table_sql); print("created table {TABLE}".replace("{TABLE}", staging_table_name)); } else if(d.data[0].c == 1) { var id_query = "select case when max_id is null then 0 else max_id end as max_id from \ (select max(id) as max_id from {TABLE}) a\n".replace("{TABLE}", staging_table_name); var r = JSON.parse(FuseBase.query("pretre_sql_server", id_query)); id = r.data[0].max_id+1; } FuseBase.ddl("pretre_sql_server", "truncate table {TABLE}".replace("{TABLE}", staging_table_name)); var files = FuseBase.command("ls /Users/niclas/Documents/data/hundegger-datafetcher/data/autoeye/alldata/").split("\n"); var tables = []; for(var i=0; i<files.length; i++) { if(files[i].indexOf("_event") > -1) { tables.push(files[i].replace(".log", "")); } } var state_transitions = { "WORKING_ON": "WORKING_OFF", "STARTED_ON": "STARTED_OFF", "IDLE_ON": "IDLE_OFF", "DOWN_ON": "DOWN_OFF", "JOB_STARTED": "JOB_DONE", "APP_STARTED": "APP_ENDED", "ALARM_ON": "ALARM_OFF" }; var expected_states = {}; var totalRows = 0; var ps = FuseBase.getPreparedStatement("pretre_sql_server", "insert into {TABLE} values(?, cast(? as datetime),?,?,?,?,?,?,?,?)".replace( "{TABLE}", staging_table_name)); ps.getConnection().setAutoCommit(false); for(var i=0; i<tables.length; i++) { try { var rs = FuseBase.getQueryObject("auto_eye", "select * from " + tables[i]); var rows=0; var event_state, expected_state; while (rs.next()) { rows++; event_state = rs.getString(3); if(event_state.indexOf("ALARM_ON") == 0 && event_state.length > "ALARM_ON".length) { var alarm_number = event_state.match(/\d+/g)[0]; expected_states["ALARM_OFF" + alarm_number] = {previous_id: id}; } ps.setString(1, id); for(var j=1; j<=rs.getColumnCount(); j++) { ps.setString(j+1, rs.getString(j)); } if(event_state in expected_states) { ps.setString(rs.getColumnCount()+2, expected_states[event_state].previous_id); delete expected_states[event_state]; } else if(!(event_state in expected_states)) { ps.setString(rs.getColumnCount()+2, null); } if(event_state in state_transitions) { expected_state = state_transitions[event_state]; if(!(expected_state in expected_states)) { expected_states[expected_state] = { previous_id: id } } } id++; ps.addBatch(); } ps.executeBatch(); ps.getConnection().commit(); totalRows += rows; print("Added " + rows + " rows from " + tables[i] + " to " + staging_table_name); rs.close(); } catch(e) { print("Error for file " + tables[i] + ". Error: " + e); } } print("Rows inserted: " + totalRows);
36.932773
112
0.532423
f203acfd48976af6130f67b33dd24f54f1953f93
27,187
js
JavaScript
src/common/musicHelpers.js
kcazthemighty/Smoosic
977b1fbb09490cd45cb59f51f9cfbaa87a6ce7ee
[ "MIT" ]
null
null
null
src/common/musicHelpers.js
kcazthemighty/Smoosic
977b1fbb09490cd45cb59f51f9cfbaa87a6ce7ee
[ "MIT" ]
null
null
null
src/common/musicHelpers.js
kcazthemighty/Smoosic
977b1fbb09490cd45cb59f51f9cfbaa87a6ce7ee
[ "MIT" ]
null
null
null
// [Smoosic](https://github.com/AaronDavidNewman/Smoosic) // Copyright (c) Aaron David Newman 2021. // ## smoMusic // Helper functions that build on the VX music theory routines, and other // utilities I wish were in VF.Music but aren't // ### Note on pitch and duration format // We use some VEX music theory routines and frequently need to convert // formats from SMO format. // // `Smo` uses pitch JSON: // ``javascript`` // {note:'c',accidental:'#',octave:4} // `Vex` usually uses a canonical string: // 'c#/4' // Depending on the operation, the octave might be omitted // // `Smo` uses a JSON for duration always: // ``javascript`` // {numerator:4096,denominator:1,remainder:0} // // `VexFlow` uses a letter duration ('4' for 1/4 note) and 'd' for dot. // I try to indicate whether I am using vex or smo notation // Duration methods start around line 600 // --- class smoMusic { // ### vexToCannonical // return Vex canonical note enharmonic - e.g. Bb to A# // Get the canonical form static vexToCannonical(vexKey) { vexKey = smoMusic.stripVexOctave(vexKey); return VF.Music.canonical_notes[VF.Music.noteValues[vexKey].int_val]; } // ### circleOfFifths // A note array in key-signature order static get circleOfFifths() { return [{ letter: 'c', accidental: 'n' }, { letter: 'g', accidental: 'n' }, { letter: 'd', accidental: 'n' }, { letter: 'a', accidental: 'n' }, { letter: 'e', accidental: 'n' }, { letter: 'b', accidental: 'n' }, { letter: 'f', accidental: '#' }, { letter: 'c', accidental: '#' }, { letter: 'a', accidental: 'b' }, { letter: 'e', accidental: 'b' }, { letter: 'b', accidental: 'b' }, { letter: 'f', accidental: 'n' } ]; } // ### circleOfFifthsIndex // gives the index into circle-of-fifths array for a pitch, considering enharmonics. static circleOfFifthsIndex(smoPitch) { const en1 = smoMusic.vexToSmoKey(smoMusic.getEnharmonic(smoMusic.pitchToVexKey(smoPitch))); const en2 = smoMusic.vexToSmoKey(smoMusic.getEnharmonic(smoMusic.getEnharmonic(smoMusic.pitchToVexKey(smoPitch)))); const ix = smoMusic.circleOfFifths.findIndex((el) => (el.letter === smoPitch.letter && el.accidental === smoPitch.accidental) || (el.letter === en1.letter && el.accidental === en1.accidental) || (el.letter === en2.letter && el.accidental === en2.accidental) ); return ix; } // ### addSharp // Get pitch to the right in circle of fifths static addSharp(smoPitch) { let rv = smoMusic.circleOfFifths[ (smoMusic.circleOfFifthsIndex(smoPitch) + 1) % smoMusic.circleOfFifths.length]; rv = JSON.parse(JSON.stringify(rv)); rv.octave = smoPitch.octave; return rv; } // ### addFlat // Get pitch to the left in circle of fifths static addFlat(smoPitch) { let rv = smoMusic.circleOfFifths[ ((smoMusic.circleOfFifths.length - 1) + smoMusic.circleOfFifthsIndex(smoPitch)) % smoMusic.circleOfFifths.length]; rv = JSON.parse(JSON.stringify(rv)); rv.octave = smoPitch.octave; return rv; } // ### addSharps // Add *distance* sharps/flats to given key static addSharps(smoPitch, distance) { let i = 0; let rv = {}; if (distance === 0) { return JSON.parse(JSON.stringify(smoPitch)); } rv = smoMusic.addSharp(smoPitch); for (i = 1; i < distance; ++i) { rv = smoMusic.addSharp(rv); } const octaveAdj = smoMusic.letterPitchIndex[smoPitch.letter] > smoMusic.letterPitchIndex[rv.letter] ? 1 : 0; rv.octave += octaveAdj; return rv; } // ### addFlats // Add *distance* sharps/flats to given key static addFlats(smoPitch, distance) { let i = 0; let rv = {}; if (distance === 0) { return JSON.parse(JSON.stringify(smoPitch)); } rv = smoMusic.addFlat(smoPitch); for (i = 1; i < distance; ++i) { rv = smoMusic.addFlat(rv); } const octaveAdj = smoMusic.letterPitchIndex[smoPitch.letter] > smoMusic.letterPitchIndex[rv.letter] ? 1 : 0; rv.octave += octaveAdj; return rv; } // ### smoPitchesToVexKeys // Transpose and convert from SMO to VEX format so we can use the VexFlow tables and methods static smoPitchesToVexKeys(pitchAr, keyOffset, noteHead) { const noopFunc = keyOffset > 0 ? 'addSharps' : 'addFlats'; const rv = []; pitchAr.forEach((pitch) => { rv.push(smoMusic.pitchToVexKey(smoMusic[noopFunc](pitch, keyOffset), noteHead)); }); return rv; } static get scaleIntervals() { return { up: [2, 2, 1, 2, 2, 2, 1], down: [1, 2, 2, 2, 1, 2, 2] }; } // ### smoScalePitchMatch // return true if the pitches match, but maybe not in same octave static smoScalePitchMatch(p1, p2) { const pp1 = JSON.parse(JSON.stringify(p1)); const pp2 = JSON.parse(JSON.stringify(p2)); pp1.octave = 0; pp2.octave = 0; return smoMusic.smoPitchToInt(pp1) === smoMusic.smoPitchToInt(pp2); } // ### pitchToLedgerLineInt static pitchToLedgerLine(clef, pitch) { // return the distance from the top ledger line, as 0.5 per line/space return -1.0 * (VF.keyProperties(smoMusic.pitchToVexKey(pitch, clef)).line - 4.5) - VF.clefProperties.values[clef].line_shift; } // ### flagStateFromNote // return hard-coded flag state, or flag state as based on pitch and clef static flagStateFromNote(clef, note) { let fs = note.flagState; if (fs === SmoNote.flagStates.auto) { fs = smoMusic.pitchToLedgerLine(clef, note.pitches[0]) >= 2 ? SmoNote.flagStates.up : SmoNote.flagStates.down; } return fs; } // ### pitchToVexKey // convert from SMO to VEX format so we can use the VexFlow tables and methods // example: // `{letter,octave,accidental}` object to vexKey string `'f#'` static _pitchToVexKey(smoPitch) { // Convert to vex keys, where f# is a string like 'f#'. let vexKey = smoPitch.letter.toLowerCase(); if (smoPitch.accidental.length === 0) { vexKey = vexKey + 'n'; } else { vexKey = vexKey + smoPitch.accidental; } if (smoPitch.octave) { vexKey = vexKey + '/' + smoPitch.octave; } return vexKey; } static pitchToEasyScore(smoPitch) { let vexKey = smoPitch.letter.toLowerCase(); vexKey = vexKey + smoPitch.accidental; return vexKey + smoPitch.octave; } static smoPitchToMidiString(smoPitch) { const midiPitch = smoMusic.smoIntToPitch(smoMusic.smoPitchToInt(smoPitch)); let rv = midiPitch.letter.toUpperCase(); if (midiPitch.accidental !== 'n') { rv += midiPitch.accidental; } rv += midiPitch.octave; return rv; } static smoPitchesToMidiStrings(smoPitches) { const rv = []; smoPitches.forEach((pitch) => { rv.push(smoMusic.smoPitchToMidiString(pitch)); }); return rv; } static midiPitchToSmoPitch(midiPitch) { const smoPitch = {}; smoPitch.letter = midiPitch[0].toLowerCase(); if (isNaN(midiPitch[1])) { smoPitch.accidental = midiPitch[1]; smoPitch.octave = parseInt(midiPitch[2], 10); } else { smoPitch.accidental = 'n'; smoPitch.octave = parseInt(midiPitch[1], 10); } return smoPitch; } static midiPitchToMidiNumber(midiPitch) { return smoMusic.smoPitchToInt(smoMusic.midiPitchToSmoPitch(midiPitch)) + 12; } static pitchToVexKey(smoPitch, head) { if (!head) { return smoMusic._pitchToVexKey(smoPitch); } return smoMusic._pitchToVexKey(smoPitch) + '/' + head; } // ### vexToSmoPitch // Turns vex pitch string into smo pitch, e.g. // cn/4 => {'c','n',4} static vexToSmoPitch(vexPitch) { let octave = 0; const po = vexPitch.split('/'); const rv = smoMusic.vexToSmoKey(po[0]); if (po.length > 1) { octave = parseInt(po[1], 10); octave = isNaN(octave) ? 4 : octave; } else { octave = 4; } rv.octave = octave; return rv; } // ### vexToSmoKey // Convert to smo pitch, without octave // ``['f#'] => [{letter:'f',accidental:'#'}]`` static vexToSmoKey(vexPitch) { var accidental = vexPitch.length < 2 ? 'n' : vexPitch.substring(1, vexPitch.length); var pp = vexPitch.split('/')[0]; return { letter: pp[0].toLowerCase(), accidental: accidental }; } // ### smoPitchToVes // {letter:'f',accidental:'#'} => [f#/ static smoPitchesToVex(pitchAr) { var rv = []; pitchAr.forEach((p) => { rv.push(smoMusic.pitchToVexKey(p)); }); return rv; } static stripVexOctave(vexKey) { if (vexKey.indexOf('/') > 0) { vexKey = vexKey.substring(0, vexKey.indexOf('/')) } return vexKey; } static pitchArraysMatch(ar1, ar2) { var matches = 0; const ir1 = smoMusic.smoPitchesToIntArray(ar1); const ir2 = smoMusic.smoPitchesToIntArray(ar2); if (ir1.length !== ir2.length) { return; } ir1.forEach((num) => { if (ir2.indexOf(num) >= 0) { matches += 1; } }); return matches === ir1.length; } static smoPitchesToIntArray(pitches) { const rv = []; pitches.forEach((pitch) => { rv.push(smoMusic.smoPitchToInt(pitch)); }); return rv.sort(); } static smoPitchToInt(pitch) { if (typeof(pitch.octave) === 'undefined') { pitch.octave = 0; } var intVal = VF.Music.noteValues[ smoMusic.stripVexOctave(smoMusic.pitchToVexKey(pitch))].int_val; var octave = (pitch.letter === 'c' && pitch.accidental === 'b' && pitch.octave > 0) ? pitch.octave - 1 : pitch.octave; return octave * 12 + intVal; } static smoIntToPitch(intValue) { let octave = 0; let accidental = ''; let noteKey = ''; const letterInt = intValue >= 0 ? intValue % 12 : 12 - (Math.abs(intValue) % 12); noteKey = Object.keys(VF.Music.noteValues).find((key) => VF.Music.noteValues[key].int_val === letterInt && key.length === 1 ); if (!noteKey) { noteKey = Object.keys(VF.Music.noteValues).find((key) => VF.Music.noteValues[key].int_val === letterInt && key.length === 2 ); } octave = Math.floor(intValue / 12); octave = octave >= 0 ? octave : 0; accidental = noteKey.substring(1, noteKey.length); accidental = accidental ? accidental : 'n'; return { letter: noteKey[0], accidental: accidental, octave: octave }; } // ### vexKeySigWithOffset // Consider instrument transpose when setting key - // e.g. Eb for Bb instruments is F. static vexKeySigWithOffset(vexKey, offset) { let newKey = smoMusic.pitchToVexKey(smoMusic.smoIntToPitch( smoMusic.smoPitchToInt( smoMusic.vexToSmoKey(vexKey)) + offset)); newKey = smoMusic.toValidKeySignature(newKey); // handle equivalent ks if (newKey === 'c#' && vexKey.indexOf('b') >=0) { newKey = 'db'; } return newKey; } // ### get enharmonics // return a map of enharmonics for choosing or cycling. notes are in vexKey form. static get enharmonics() { let i = 0; const rv = {}; const keys = Object.keys(VF.Music.noteValues); for (i = 0; i < keys.length; ++i) { const key = keys[i]; const int_val = VF.Music.noteValues[key].int_val; if (typeof(rv[int_val.toString()]) == 'undefined') { rv[int_val.toString()] = []; } // only consider natural note 1 time. It is in the list twice for some reason. if (key.indexOf('n') === -1) { rv[int_val.toString()].push(key); } } return rv; } static getEnharmonics(vexKey) { const proto = smoMusic.stripVexOctave(vexKey); const rv = []; let ne = smoMusic.getEnharmonic(vexKey); rv.push(proto); while (ne[0] !== proto[0]) { rv.push(ne); ne = smoMusic.getEnharmonic(ne); } return rv; } // ### getEnharmonic(noteProp) // cycle through the enharmonics for a note. static getEnharmonic(vexKey) { vexKey = smoMusic.stripVexOctave(vexKey); const intVal = VF.Music.noteValues[vexKey.toLowerCase()].int_val; const ar = smoMusic.enharmonics[intVal.toString()]; const len = ar.length; // 'n' for natural in key but not in value vexKey = vexKey.length > 1 && vexKey[1] === 'n' ? vexKey[0] : vexKey; const ix = ar.indexOf(vexKey); vexKey = ar[(ix + 1) % len]; return vexKey; } // ### getKeyFriendlyEnharmonic // fix the enharmonic to match the key, if possible // `getKeyFriendlyEnharmonic('b','eb'); => returns 'bb' static getKeyFriendlyEnharmonic(letter, keySignature) { var rv = letter; var muse = new VF.Music(); var scale = Object.values(muse.createScaleMap(keySignature)); var prop = smoMusic.getEnharmonic(letter.toLowerCase()); while (prop.toLowerCase() != letter.toLowerCase()) { for (var i = 0; i < scale.length; ++i) { var skey = scale[i]; if ((skey[0] == prop && skey[1] == 'n') || (skey.toLowerCase() == prop.toLowerCase())) { rv = skey; break; } } prop = (prop[1] == 'n' ? prop[0] : prop); prop = smoMusic.getEnharmonic(prop); } return rv; } static closestTonic(smoPitch, vexKey, direction) { direction = Math.sign(direction) < 0 ? -1 : 1; var tonic = smoMusic.vexToSmoKey(vexKey); tonic.octave=smoPitch.octave; var iix = smoMusic.smoPitchToInt(smoPitch); var smint=smoMusic.smoPitchToInt(tonic); if (Math.sign(smint - iix) != direction) { tonic.octave += direction } return tonic; } // ### toValidKeySignature // When transposing, make sure key signature is valid, e.g. g# should be // Ab static toValidKeySignature(vexKey) { let strlen = 0; var map = {'a#':'bb','g#':'ab','cb':'b','d#':'eb'} if (map[vexKey.toLowerCase()]) { return map[vexKey.toLowerCase()]; } strlen = (vexKey.length > 2 ? 2 : vexKey.length); // Vex doesn't like 'n' in key signatures. if (strlen === 2 && vexKey[1].toLowerCase() === 'n') { strlen = 1; } return vexKey.substr(0, strlen); } // ### getEnharmonicInKey // Get the enharmonic equivalent that most closely matches // a given key static getEnharmonicInKey(smoPitch, keySignature) { if (typeof(smoPitch.octave) === 'undefined') { smoPitch.octave = 1; } var sharpKey = keySignature.indexOf('#') >= 0 ? true : false; var flatKey = keySignature.indexOf('b') >= 0 ? true : false; var ar = smoMusic.getEnharmonics(smoMusic.pitchToVexKey(smoPitch)); var rv = smoMusic.stripVexOctave(smoMusic.pitchToVexKey(smoPitch)); var scaleMap = new VF.Music().createScaleMap(keySignature); var match = false; ar.forEach((vexKey) => { if (vexKey.length === 1) { vexKey += 'n'; } if (vexKey === scaleMap[vexKey[0]]) { rv = vexKey; match = true; } else if (!match) { // In the absence of a match of a key tone, we bias towards more // 'common', like Bb is more common than A#, esp. as a chord. This maybe // just be my horn player bias towards flat keys if (vexKey === 'a#' && !sharpKey) { rv = 'bb'; } else if (vexKey === 'g#' && !sharpKey) { rv = 'ab'; } else if (vexKey === 'c#' && !sharpKey) { rv = 'db'; } else if (vexKey === 'd#' && !sharpKey) { rv = 'eb'; } else if (vexKey === 'f#' && flatKey) { rv = 'gb'; } } }); var smoRv = smoMusic.vexToSmoKey(rv); smoRv.octave = smoPitch.octave; var rvi = smoMusic.smoPitchToInt(smoRv); var ori = smoMusic.smoPitchToInt(smoPitch); // handle the case of c0 < b0, pitch-wise smoRv.octave += Math.sign(ori - rvi); return smoRv; } // ### getIntervalInKey // give a pitch and a key signature, return another pitch at the given // diatonic interval. Similar to getKeyOffset but diatonic. static getIntervalInKey(pitch, keySignature, interval) { if (interval === 0) return JSON.parse(JSON.stringify(pitch)); var delta = interval > 0 ? 1 : -1; var inv = -1 * delta; var tonic = smoMusic.closestTonic(pitch, keySignature, inv); var intervals = delta > 0 ? smoMusic.scaleIntervals.up : smoMusic.scaleIntervals.down; var pitchInt = smoMusic.smoPitchToInt(pitch); var scaleIx = 0; var diatonicIx=0; var nkey = tonic; var nkeyInt = smoMusic.smoPitchToInt(nkey); while (Math.sign(nkeyInt - pitchInt) != delta && Math.sign(nkeyInt - pitchInt) != 0) { nkey = smoMusic.smoIntToPitch(smoMusic.smoPitchToInt(nkey) + delta * intervals[scaleIx]); scaleIx = (scaleIx + 1) % 7; nkeyInt = smoMusic.smoPitchToInt(nkey); } while (diatonicIx != interval) { nkey = smoMusic.smoIntToPitch(smoMusic.smoPitchToInt(nkey) + delta * intervals[scaleIx]); scaleIx = (scaleIx + 1) % 7; diatonicIx += delta; } return smoMusic.getEnharmonicInKey(nkey,keySignature); } static getLetterNotePitch(prevPitch, letter, key) { const pitch = JSON.parse(JSON.stringify(prevPitch)); pitch.letter = letter; // Make the key 'a' make 'Ab' in the key of Eb, for instance const vexKsKey = smoMusic.getKeySignatureKey(letter, key); if (vexKsKey.length > 1) { pitch.accidental = vexKsKey[1]; } else { pitch.accidental = 'n'; } // make the octave of the new note as close to previous (or next) note as possible. const upv = ['bc', 'ac', 'bd', 'da', 'be', 'gc']; const downv = ['cb', 'ca', 'db', 'da', 'eb', 'cg']; const delta = prevPitch.letter + pitch.letter; if (upv.indexOf(delta) >= 0) { pitch.octave += 1; } if (downv.indexOf(delta) >= 0) { pitch.octave -= 1; } return pitch; } static vexKeySignatureTranspose(key, transposeIndex) { var key = smoMusic.vexToSmoKey(key); key = smoMusic.smoPitchesToVexKeys([key], transposeIndex)[0]; key = smoMusic.stripVexOctave(key); key = key[0].toUpperCase() + key.substring(1, key.length); if (key.length > 1 && key[1] === 'n') { key = key[0]; } return key; } static get frequencyMap() { return suiAudioPitch.pitchFrequencyMap; } // ### get letterPitchIndex // Used to adjust octave when transposing. // Pitches are measured from c, so that b0 is higher than c0, c1 is 1 note higher etc. static get letterPitchIndex() { return { 'c': 0, 'd': 1, 'e': 2, 'f': 3, 'g': 4, 'a': 5, 'b': 6 }; } // ### letterChangedOctave // Indicate if a change from letter note 'one' to 'two' needs us to adjust the // octave due to the `smoMusic.letterPitchIndex` (b0 is higher than c0) static letterChangedOctave(one, two) { var p1 = smoMusic.letterPitchIndex[one]; var p2 = smoMusic.letterPitchIndex[two]; if (p1 < p2 && p2 - p1 > 2) return -1; if (p1 > p2 && p1 - p2 > 2) return 1; return 0; } // ### getKeyOffset // Given a vex noteProp and an offset, offset that number // of 1/2 steps. // #### Input: smoPitch // #### Output: smoPitch offset, not key-adjusted. static getKeyOffset(pitch, offset) { var canon = VF.Music.canonical_notes; // Convert to vex keys, where f# is a string like 'f#'. var vexKey = smoMusic.pitchToVexKey(pitch); vexKey = smoMusic.vexToCannonical(vexKey); var rootIndex = canon.indexOf(vexKey); var index = (rootIndex + canon.length + offset) % canon.length; var octave = pitch.octave; if (Math.abs(offset) >= 12) { var octaveOffset = Math.sign(offset) * Math.floor(Math.abs(offset) / 12); octave += octaveOffset; offset = offset % 12; } if (rootIndex + offset >= canon.length) { octave += 1; } if (rootIndex + offset < 0) { octave -= 1; } var rv = JSON.parse(JSON.stringify(pitch)); vexKey = canon[index]; if (vexKey.length > 1) { rv.accidental = vexKey.substring(1); vexKey = vexKey[0]; } else { rv.accidental = ''; } rv.letter = vexKey; rv.octave = octave; return rv; } // ### keySignatureLength // return the number of sharp/flat in a key signature for sizing guess. static get keySignatureLength() { return { 'C': 0, 'B': 5, 'A': 3, 'F#': 6, 'Bb': 2, 'Ab': 4, 'Gg': 6, 'G': 1, 'F': 1, 'Eb': 3, 'Db': 5, 'Cb': 7, 'C#': 7, 'F#': 6, 'E': 4, 'D': 2 }; } static getSharpsInKeySignature(key) { let sharpKeys = ['B', 'G', 'D', 'A', 'E', 'B', 'F#', 'C#']; if (sharpKeys.indexOf(key.toUpperCase()) < 0) { return 0; } return smoMusic.keySignatureLength[key.toUpperCase()]; } static getFlatsInKeySignature(key) { var flatKeys = ['F', 'Bb', 'Eb', 'Ab', 'Db', 'Gb', 'Cb']; let caseKey = key[0].toUpperCase(); if (key.length > 0) { caseKey += key.substr(1, key.length); } if (flatKeys.indexOf(caseKey) < 0) { return 0; } return smoMusic.keySignatureLength[caseKey]; } static timeSignatureToTicks(timeSignature) { var nd = timeSignature.split('/'); var num = parseInt(nd[0]); var den = parseInt(nd[1]); var base = 2048 * (8 / den); return base*num; } static smoTicksToVexDots(ticks) { var vd = smoMusic.ticksToDuration[ticks]; var dots = (vd.match(/d/g) || []).length; return dots; } // ## closestVexDuration // ## Description: // return the closest vex duration >= to the actual number of ticks. Used in beaming // triplets which have fewer ticks then their stem would normally indicate. static closestVexDuration(ticks) { var stemTicks = VF.RESOLUTION; // The stem value is the type on the non-tuplet note, e.g. 1/8 note // for a triplet. while (ticks <= stemTicks) { stemTicks = stemTicks / 2; } stemTicks = stemTicks * 2; return smoMusic.ticksToDuration[stemTicks]; var ix = Object.keys(smoMusic.ticksToDuration).findIndex((x) => { return x >= ticks }); return smoMusic.ticksToDuration[durations[ix]]; } // ### closestDurationTickLtEq // Price is right style, closest tick value without going over. Used to pad // rests when reading musicXML. static closestDurationTickLtEq(ticks) { const sorted = Object.keys(smoMusic.ticksToDuration) .map((key) => parseInt(key, 10)) .filter((key) => key <= ticks); return sorted[sorted.length - 1]; } static splitIntoValidDurations(ticks) { const rv = []; let closest = 0; while (ticks > 128) { closest = smoMusic.closestDurationTickLtEq(ticks); ticks -= closest; rv.push(closest); } return rv; } // ### vexStemType // return the vex stem type (no dots) static vexStemType(ticks) { const str = smoMusic.ticksToDuration[smoMusic.splitIntoValidDurations(ticks)[0]]; if (str.indexOf('d') >= 0) { return str.substr(0,str.indexOf('d')); } return str; } // ### getKeySignatureKey // given a letter pitch (a,b,c etc.), and a key signature, return the actual note // that you get without accidentals // ### Usage: // smoMusic.getKeySignatureKey('F','G'); // returns f# static getKeySignatureKey(letter, keySignature) { var km = new VF.KeyManager(keySignature); return km.scaleMap[letter]; } static getAccidentalForKeySignature(smoPitch, keySignature) { var vexKey = smoMusic.getKeySignatureKey(smoPitch.letter,keySignature); return vexKey.length == 1 ? 'n' : vexKey.substr(1,vexKey.length - 1); } // ### isPitchInKeySignature // Return true if the pitch is not an accidental in the give key, e.g. // f# in 'g' or c in 'Bb' static isPitchInKeySignature(smoPitch,keySignature) { var vexKey = smoMusic.getKeySignatureKey(smoPitch.letter,keySignature); return (vexKey.length == 1 && smoPitch.accidental == 'n' || (vexKey[1]==smoPitch.accidental)); } // ### Description: // Get ticks for this note with an added dot. Return // identity if that is not a supported value. static getNextDottedLevel(ticks) { var ttd = smoMusic.ticksToDuration; var vals = Object.values(ttd); var ix = vals.indexOf(ttd[ticks]); if (ix >= 0 && ix < vals.length && vals[ix][0] == vals[ix + 1][0]) { return smoMusic.durationToTicks(vals[ix + 1]); } return ticks; } // ### Description: // Get ticks for this note with one fewer dot. Return // identity if that is not a supported value. static getPreviousDottedLevel(ticks) { var ttd = smoMusic.ticksToDuration; var vals = Object.values(ttd); var ix = vals.indexOf(ttd[ticks]); if (ix > 0 && vals[ix][0] == vals[ix - 1][0]) { return smoMusic.durationToTicks(vals[ix - 1]); } return ticks; } // ### ticksToDuration // Frequently we double/halve a note duration, and we want to find the vex tick duration that goes with that. static get ticksToDuration() { var durations = ["1/2", "1", "2", "4", "8", "16", "32", "64", "128", "256"]; smoMusic._ticksToDuration = smoMusic['_ticksToDuration'] ? smoMusic._ticksToDuration : null; var _ticksToDurationsF = function () { var ticksToDuration = smoMusic._ticksToDuration = {}; for (var i = 0; i < durations.length - 1; ++i) { var dots = ''; var ticks = 0; // We support up to 4 'dots' for (var j = 0; j <= 4 && j + i < durations.length; ++j) { ticks += VF.durationToTicks.durations[durations[i + j]]; ticksToDuration[ticks.toString()] = durations[i] + dots; dots += 'd' } } return ticksToDuration; } if (!smoMusic._ticksToDuration) { _ticksToDurationsF(); } return smoMusic._ticksToDuration; }; // ### durationToTicks // Uses VF.durationToTicks, but handles dots. static durationToTicks(duration) { var dots = duration.indexOf('d'); if (dots < 0) { return VF.durationToTicks(duration); } else { var vfDuration = VF.durationToTicks(duration.substring(0, dots)); dots = duration.length - dots; // number of dots var split = vfDuration / 2; for (var i = 0; i < dots; ++i) { vfDuration += split; split = split / 2; } return vfDuration; } } static gcdMap(duration) { var keys = Object.keys(smoMusic.ticksToDuration).map((x) => parseInt(x)); var dar = []; var gcd = function(td) { var rv = keys[0]; for (var k = 1 ;k < keys.length; ++k) { if (td % keys[k] === 0) { rv = keys[k]; } } return rv; } while (duration > 0 && !smoMusic.ticksToDuration[duration]) { var div = gcd(duration); duration = duration - div; dar.push(div); } if (duration > 0) { dar.push(duration); } return dar.sort((a,b) => a > b ? -1 : 1); } }
31
122
0.602531
f203db39f55c0697654d9ff97185fd7a07374283
772
js
JavaScript
test/index.js
ideyuta/yugo
8d71e9f5f47241e7dc28fd23519c55177b987c5d
[ "MIT" ]
null
null
null
test/index.js
ideyuta/yugo
8d71e9f5f47241e7dc28fd23519c55177b987c5d
[ "MIT" ]
null
null
null
test/index.js
ideyuta/yugo
8d71e9f5f47241e7dc28fd23519c55177b987c5d
[ "MIT" ]
null
null
null
import assert from 'assert'; import yugo from '../src/index'; /** @test {yugo} */ describe('yugo', () => { it('is function', () => { assert(typeof yugo === 'function'); }); it('should return object', () => { assert.deepEqual(yugo({a: 'a'}), {a: 'a'}); }); it('should return join object', () => { assert.deepEqual(yugo({a: 'a'}, {b: 'b'}), {a: 'a', b: 'b'}); }); it('should overwrite', () => { assert.deepEqual(yugo({a: 'a'}, {a: 'b'}), {a: 'b'}); }); it('should conditionally join', () => { assert.deepEqual(yugo({a: 'a'}, [{a: 'b'}, false]), {a: 'a'}); }); it('should through except typeof object', () => { const num = 3; assert.deepEqual(yugo('hoge', num, {a: 'a'}, [{b: 'b'}, true]), {a: 'a', b: 'b'}); }); });
24.903226
86
0.48057
f203e5b00489c5d4098cb4f2bdfddde0b9aceda3
182
js
JavaScript
input/releases/qpid-cpp-master/messaging-api/cpp/api/structqpid_1_1messaging_1_1InvalidOptionString.js
gemmellr/qpid-site
d915206e030ab7fc3a2329eb45d4e804dd7e4c2e
[ "Apache-2.0" ]
2
2019-05-20T17:57:24.000Z
2021-11-06T23:01:16.000Z
input/releases/qpid-cpp-master/messaging-api/cpp/api/structqpid_1_1messaging_1_1InvalidOptionString.js
gemmellr/qpid-site
d915206e030ab7fc3a2329eb45d4e804dd7e4c2e
[ "Apache-2.0" ]
null
null
null
input/releases/qpid-cpp-master/messaging-api/cpp/api/structqpid_1_1messaging_1_1InvalidOptionString.js
gemmellr/qpid-site
d915206e030ab7fc3a2329eb45d4e804dd7e4c2e
[ "Apache-2.0" ]
7
2017-11-02T23:13:56.000Z
2021-11-06T23:01:05.000Z
var structqpid_1_1messaging_1_1InvalidOptionString = [ [ "InvalidOptionString", "structqpid_1_1messaging_1_1InvalidOptionString.html#a347270baa28c2c3f9681a56e5cfd8302", null ] ];
45.5
124
0.851648
f2054aaab13d8bc182d5adf5b1d82df90bc3506e
486
js
JavaScript
src/pages/InventoryPage.js
olpeh/pdp-huvi-proto
ee83b7a175b293c9b7d74ed232a576217761e47f
[ "MIT" ]
null
null
null
src/pages/InventoryPage.js
olpeh/pdp-huvi-proto
ee83b7a175b293c9b7d74ed232a576217761e47f
[ "MIT" ]
null
null
null
src/pages/InventoryPage.js
olpeh/pdp-huvi-proto
ee83b7a175b293c9b7d74ed232a576217761e47f
[ "MIT" ]
null
null
null
import React from 'react'; import './InventoryPage.scss'; import Inventory from '../components/Inventory'; import { Link } from 'react-router-dom'; const InventoryPage = () => ( <div className="InventoryPage"> <div className="QR-code-info"> <Link className="image" to="scan" /> <div className="text"> You can scan QR-code on the clothing tag or search from the list below </div> </div> <Inventory /> </div> ); export default InventoryPage;
23.142857
78
0.646091
f2055dd1ae64e3da39300513eead6f75fce90120
223
js
JavaScript
src/internal/_isString.js
imjaroiswebdev/curry-remap-keys
ace415dc5ba3b83941f382b83bceba8de78fc174
[ "MIT" ]
3
2018-11-28T20:40:59.000Z
2019-05-24T19:05:06.000Z
src/internal/_isString.js
imjaroiswebdev/curry-remap-keys
ace415dc5ba3b83941f382b83bceba8de78fc174
[ "MIT" ]
null
null
null
src/internal/_isString.js
imjaroiswebdev/curry-remap-keys
ace415dc5ba3b83941f382b83bceba8de78fc174
[ "MIT" ]
null
null
null
/** * Checks if its entry is an string. * * @private * @param {object} arg - Entry that will be checked as string */ export default function (arg) { return Object.prototype.toString.call(arg) === '[object String]' }
22.3
66
0.668161
f205de05c3e036337746b58c10b9f87248c53bda
12,232
js
JavaScript
scripts/noisegen.js
ssell/noisegen
27f8b72519b4ea0541fb01ddf91e86c0838063da
[ "Apache-2.0" ]
2
2019-04-03T20:03:47.000Z
2020-03-05T20:43:28.000Z
scripts/noisegen.js
ssell/noisegen
27f8b72519b4ea0541fb01ddf91e86c0838063da
[ "Apache-2.0" ]
40
2017-01-19T07:44:02.000Z
2017-03-14T06:32:09.000Z
scripts/noisegen.js
ssell/noisegen
27f8b72519b4ea0541fb01ddf91e86c0838063da
[ "Apache-2.0" ]
null
null
null
/** * Copyright 2017 Steven T Sell (ssell@vertexfragment.com) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ /** * noisegen.js * * This script is responsible for the general behavior of the noisegen page. * This includes, but is not limited to, the following: * * - Initiating UI creation * - Responding to UI events * - Initiating noise generation * - Filling surface * - Reszing surface */ var gSurface = null; var gGrayMultiRange = null; var gColorMultiRange = null; /** * Populates the #noise_algorithms select element with all * available noise algorithms that can be used to generate the image. */ function populateAlgorithmList() { $("#noise_algorithms").append( "<option value='" + NoisePerlin.type + "'>" + NoisePerlin.type + "</option>" + "<option value='" + NoiseSimplex.type + "' selected>" + NoiseSimplex.type + "</option>" + "<option value='" + NoiseWorley.type + "'>" + NoiseWorley.type + "</option>" + "<option value='" + NoiseRandom.type + "'>" + NoiseRandom.type + "</option>"); } /** * Returns the selected noise algorithm string. */ function getSelectedAlgorithm() { return $("#noise_algorithms").val(); } /** * */ function getNormalized() { return $("#noise_normalized").is(':checked'); } /** * Builds the noise properties parameters list used in image generation. */ function buildNoiseParamsList() { var params = ""; $("#noise_content .noise_property_value").each(function() { var id = $(this).attr('id'); var name = id.substr(0, (id.length - 6)); // Remove the '_value' var value = ""; if($(this).is("input")) { value = $(this).val(); } else { value = $(this).text(); } params += name + ":" + value + ";"; }); params += "seed:" + uint32(Number($("#noise_seed").val())) + ";"; return params; } /** * Rounds the provided number down to the nearest even integer. */ function roundDownToEven(value) { return (2.0 * Math.floor(value * 0.5)); } /** * Updates the dimensions of the surface canvas. */ function updateDimensions() { // First check if there is a set dimension. // If not, we default to the document dimensions. var width_element = $("#surface_width"); var height_element = $("#surface_height"); var width = Number(width_element.val()); var height = Number(height_element.val()); if(width == 0) { width = $(document).width(); } if(height == 0) { height = $(document).height(); } width = roundDownToEven(width); height = roundDownToEven(height); width_element.val(width); height_element.val(height); gSurface.resize(width, height); gSurface.clear(51, 51, 51); } /** * Updates the id_value display on input change. * This is used by different ui elements such as the range sliders. */ function updateInput(id) { var sourceObj = $("#" + id); var destObj = $("#" + id + "_value"); if(sourceObj && destObj) { if(destObj.is("input")) { destObj.val(sourceObj.val()); } else { destObj.html(sourceObj.val()); } } } /** * */ function toggleGenerateButton() { $("#generate_button").prop('disabled', function(i, v) { return !v; }); } /** * */ function toggleApplyButton() { $("#color_apply_button").prop('disabled', function(i, v) { return !v; }); } /** * */ function enableExportButton() { $("#export_button").prop('disabled', ''); } /** * */ function triggerExport() { var a = $("<a>").attr("href", gSurface.getURL()).attr("download", "noise.png").appendTo("body"); a[0].click(); a.remove(); } /** * */ function triggerUIRebuild() { buildUI(getUIParams(getSelectedAlgorithm())); $("#noise_content .ui_element").change(function(){ updateInput($(this).attr('id')); }); $("#noise_content .noise_property_value").change(function() { // If the user has manually modified the noise value, update the associated .ui_element. var parent = $(this).parent().parent().find(".ui_element").val($(this).val()); }) } /** * */ function enableColorModeGray() { gSurface.gray = true; $("#grayscale_button").addClass("color_button_selected"); $("#color_button").removeClass("color_button_selected"); $("#ui_color_grayscale").removeClass("hidden"); $("#ui_color_color").addClass("hidden"); gGrayMultiRange.update(); } /** * */ function enableColorModeColor() { gSurface.gray = false; $("#color_button").addClass("color_button_selected"); $("#grayscale_button").removeClass("color_button_selected"); $("#ui_color_color").removeClass("hidden"); $("#ui_color_grayscale").addClass("hidden"); gColorMultiRange.update(); } /** * */ function toggleColorMode() { if(gSurface.gray) { enableColorModeColor(); } else { enableColorModeGray(); } } /** * */ function generateStop() { NoiseProgressBar.stop(); toggleGenerateButton(); toggleApplyButton(); enableExportButton(); } /** * Generates the noise image. */ function generateStart() { toggleGenerateButton(); toggleApplyButton(); updateDimensions(); NoiseProgressBar.start(gSurface.size(), "Generating ..."); generateNoiseMultithreaded(gSurface, getSelectedAlgorithm(), getNormalized(), buildNoiseParamsList(), 2, generateStop); } /** * */ function applyColorPropertiesStop() { NoiseProgressBar.stop(); toggleApplyButton(); toggleGenerateButton(); } /** * */ function applyColorPropertiesStart() { var descriptor = ""; if(gSurface.gray) { descriptor = toPaletteDescriptor(gGrayMultiRange); } else { descriptor = toPaletteDescriptor(gColorMultiRange); } gSurface.setPalette(descriptor, gSurface.gray); NoiseProgressBar.start(gSurface.size(), "Applying Palette ..."); toggleApplyButton(); toggleGenerateButton(); applyPaletteMultithreaded(gSurface, 2, applyColorPropertiesStop); } function isValidHexChar(char) { return ((char >= '0') && (char <= '9')) || ((char >= 'a') && (char <= 'f')) || ((char >= 'A') && (char <= 'F')); } function isValidHexString(string) { if(string.length != 7) { return false; } for(var i = 1; i < string.length; ++i) { if(!isValidHexChar(string[i])) { return false; } } return true; } /** * */ function applyPaletteString() { var result = true; var descriptor = $("#color_templates").val(); var segments = descriptor.split(";"); const numSegments = segments.length - 1; if(numSegments > 0) { var thumbValues = new Array(numSegments - 1); var segmentColors = new Array(numSegments); var segmentModes = new Array(numSegments); //-------------------------------------------------------------------- // Parse the segment information from the string for(var i = 0; i < numSegments; ++i) { // - 1: do not include split from final ';' var segmentSplit = segments[i].split(","); if(segmentSplit.length != 5) { result = false; break; } if(i != 0) { // The first thumb value (always 0) is not needed as there is not a true thumb there. thumbValues[i - 1] = Number(segmentSplit[0]); } segmentColors[i] = rgbToHex(Number(segmentSplit[1]), Number(segmentSplit[2]), Number(segmentSplit[3])); segmentModes[i] = segmentSplit[4]; } if(result) { //------------------------------------------------------------ // Validate each thumb value for(var i = 0; i < thumbValues.length; ++i) { if(thumbValues[i] < 0 || thumbValues[i] > 255) { console.log("thumbValues[" + i + "] invalid (" + thumbValues[i] + ")"); result = false; break; } } //------------------------------------------------------------ // Validate segment colors for(var i = 0; i < segmentColors.length; ++i) { if(!isValidHexString(segmentColors[i])) { console.log("segmentColors[" + i + "] invalid (" + segmentColors[i] + ")"); result = false; break; } } //------------------------------------------------------------ // Validate segment modes for(var i = 0; i < segmentModes.length; ++i) { const upper = segmentModes[i].toUpperCase(); if((upper !== "SOLID") && (upper !== "SMOOTH RGB") && (upper !== "SMOOTH HSV") && (upper !== "NONE")) { console.log("segmentModes[" + i + "] invalid (" + segmentModes[i] + ")"); result = false; break; } } } } else { result = false; } if(result) { gColorMultiRange.load(thumbValues, segmentColors, segmentModes); $("#color_templates").css("border-bottom", "1px solid transparent"); } else { $("#color_templates").css("border-bottom", "1px solid #AA3333"); } } /** * */ function updatePaletteString() { var paletteString = ""; var descriptor; if(gSurface.gray) { descriptor = toPaletteDescriptor(gGrayMultiRange); } else { descriptor = toPaletteDescriptor(gColorMultiRange); } for(var i = 0; i < descriptor.length; ++i) { paletteString += descriptor[i] + ";" } $("#color_templates").val(paletteString); $("#color_templates").css("border-bottom", "1px solid transparent"); } /** * */ function multirangeUpdateCallback() { updatePaletteString(); } /** * */ function buildColorPropertiesGray() { var multiranges = buildMultiRanges($("#ui_color_grayscale"), multirangeUpdateCallback); if(multiranges.length) { gGrayMultiRange = multiranges[0]; } } /** * */ function buildColorPropertiesColor() { var multiranges = buildMultiRanges($("#ui_color_color"), multirangeUpdateCallback); if(multiranges.length) { gColorMultiRange = multiranges[0]; } } /** * */ function buildColorProperties() { buildColorPropertiesGray(); buildColorPropertiesColor(); } /** * */ function handleMinimize(id) { const section = id.split("_")[1] + "_content"; const content = $("#" + section); if(content) { if(content.hasClass("hidden")) { content.removeClass("hidden"); $("#" + id).html("<a>&#x25BE;</a>"); } else { content.addClass("hidden"); $("#" + id).html("<a>&#x25C2;</a>"); } } } $(document).ready(function() { gSurface = new Surface(); buildColorProperties(); populateAlgorithmList(); updateDimensions(); triggerUIRebuild(); updatePaletteString(); $("#set_palette").click(function() { applyPaletteString(); }); $("#generate_button").click(function() { generateStart(); }); $("#export_button").click(function() { triggerExport(); }); $("#noise_algorithms").change(function() { triggerUIRebuild(); }); $(".color_button").click(function() { toggleColorMode(); }); $("#color_apply_button").click(function() { applyColorPropertiesStart(); }); $(".minimize").click(function() { handleMinimize($(this).attr("id")); }); });
24.861789
123
0.566629
f2061813d94500c501115899b9860f60aaeba819
740
js
JavaScript
packages/react-scripts/scripts/utils/readTypescriptConfig.js
mikew/create-react-app
48df474dd00d39ad28a836fd55311ab695465045
[ "MIT" ]
1
2022-02-07T19:38:16.000Z
2022-02-07T19:38:16.000Z
packages/react-scripts/scripts/utils/readTypescriptConfig.js
mikew/create-react-app
48df474dd00d39ad28a836fd55311ab695465045
[ "MIT" ]
null
null
null
packages/react-scripts/scripts/utils/readTypescriptConfig.js
mikew/create-react-app
48df474dd00d39ad28a836fd55311ab695465045
[ "MIT" ]
null
null
null
/** * Copyright (c) 2015-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ 'use strict'; const getTypescriptCompilerPath = require('./getTypescriptCompilerPath'); const paths = require('../../config/paths'); let existingConfig = null; function readTypescriptConfig() { if (existingConfig == null) { const typescriptCompilerPath = getTypescriptCompilerPath(); const typescript = require(typescriptCompilerPath); existingConfig = typescript.getParsedCommandLineOfConfigFile( paths.appTsConfig, undefined, typescript.sys ); } return existingConfig; } module.exports = readTypescriptConfig;
25.517241
73
0.72973
f206ab5b04088ef9345ca85056e4926023860cca
570
js
JavaScript
src/Components/CardList.js
EagleAngelo/pokesearch
f3552bd9f3821f8be16838bf5f27c78c9b5e8840
[ "MIT" ]
null
null
null
src/Components/CardList.js
EagleAngelo/pokesearch
f3552bd9f3821f8be16838bf5f27c78c9b5e8840
[ "MIT" ]
null
null
null
src/Components/CardList.js
EagleAngelo/pokesearch
f3552bd9f3821f8be16838bf5f27c78c9b5e8840
[ "MIT" ]
null
null
null
import React from "react"; import Card from "./Card"; const cardList = ({ pokeman }) => { /* if (true) { throw new Error("nooo"); } */ return ( <div> {pokeman.map((x, i) => { return ( <Card key={pokeman[i].id} //key is jsx id={pokeman[i].id} name={pokeman[i].name} type={pokeman[i].type} /> ); })} </div> ); }; export default cardList;
22.8
56
0.352632
f2073c4f9b7c8fb848d00e7cd7aae4bd66b2a358
341
js
JavaScript
frontend/src/services/server/intents.js
shikdernyc/parrot
8bcb03ab55390d97fa06ad2987bfb7c3656b41b5
[ "MIT" ]
null
null
null
frontend/src/services/server/intents.js
shikdernyc/parrot
8bcb03ab55390d97fa06ad2987bfb7c3656b41b5
[ "MIT" ]
null
null
null
frontend/src/services/server/intents.js
shikdernyc/parrot
8bcb03ab55390d97fa06ad2987bfb7c3656b41b5
[ "MIT" ]
null
null
null
const createIntent = (id, name, domain, examples) => { return { id, name, domain, examples }; }; export const getAllIntents = () => { let intentList = []; let counter = 0; for (let i = 0; i < 10; i++) { intentList.push(createIntent(counter++, `Intent ${i}`, 'Example Domain', 24)); } return intentList; };
18.944444
82
0.568915
f20841001243054208174e05fea400cf431ccc79
1,094
js
JavaScript
src/Generator/SSE/ScriptFragmentsQuest.js
matortheeternal/esp.json
3ec1effa3f2e83ea82fcfd812ebd8e645b1f7d98
[ "MIT" ]
9
2019-05-23T14:22:38.000Z
2022-01-31T10:55:21.000Z
src/Generator/SSE/ScriptFragmentsQuest.js
matortheeternal/esp.json
3ec1effa3f2e83ea82fcfd812ebd8e645b1f7d98
[ "MIT" ]
5
2019-06-24T21:02:11.000Z
2021-12-22T02:18:45.000Z
src/Generator/SSE/ScriptFragmentsQuest.js
matortheeternal/esp.json
3ec1effa3f2e83ea82fcfd812ebd8e645b1f7d98
[ "MIT" ]
2
2019-06-23T20:47:35.000Z
2019-06-29T17:24:19.000Z
let { addDef, int8, uint16, conflictType, string, prefix, int16, int32, sortKey, struct, sorted, array, customCounter, opts } = require('../helpers'); module.exports = () => { addDef('ScriptFragmentsQuest', opts(struct('Script Fragments', [ int8('Unknown'), conflictType('Benign', uint16('FragmentCount')), prefix(2, string('FileName')), opts(customCounter('ScriptFragmentsQuestCounter', sorted(array('Fragments', sortKey([0, 2], struct('Fragment', [ uint16('Quest Stage'), int16('Unknown'), int32('Quest Stage Index'), int8('Unknown'), prefix(2, string('ScriptName')), prefix(2, string('FragmentName')) ])) )) ), { "afterSet": "ScriptFragmentsQuestFragmentsAfterSet" }) ]), { "afterSet": "ScriptFragmentsQuestAfterSet" }) ); };
35.290323
67
0.471664
f2086bf92212be8f18b170c75d07439b8b01893e
4,819
js
JavaScript
test/dom/FeaturesViewerExclusionTest.js
NCHlab/ProtVista-Modified
e41de956118da841c58a8dc76d9a759282871402
[ "Apache-2.0" ]
30
2016-10-12T01:12:22.000Z
2022-02-22T17:34:48.000Z
test/dom/FeaturesViewerExclusionTest.js
NCHlab/ProtVista-Modified
e41de956118da841c58a8dc76d9a759282871402
[ "Apache-2.0" ]
23
2016-07-11T09:27:22.000Z
2022-01-18T10:28:07.000Z
test/dom/FeaturesViewerExclusionTest.js
NCHlab/ProtVista-Modified
e41de956118da841c58a8dc76d9a759282871402
[ "Apache-2.0" ]
18
2016-07-12T10:04:26.000Z
2019-05-08T06:29:09.000Z
/* * ProtVista * https://github.com/ebi-uniprot/ProtVista * * Copyright (c) 2014 ebi-uniprot * Licensed under the Apache 2 license. */ // chai is an assertion library var chai = require('chai'); var sinon = require('sinon'); // @see http://chaijs.com/api/assert/ var assert = chai.assert; // register alternative styles // @see http://chaijs.com/api/bdd/ var expect = chai.expect; // this is your global div instance (see index.html) var yourDiv = document.getElementById('mocha'); // requires your main app (specified in index.js) var FeaturesViewer = require('../..'); var Constants = require('../../src/Constants'); var FeaturesData = require('./FeaturesData'); var jQuery = require('jquery'); describe('FeaturesViewerExclusionTest', function() { var instance; before(function() { sinon.stub(Constants, 'getDataSources', function() { return [{ url: '', type: 'basic' }]; }); sinon.stub(jQuery, 'getJSON', function() { var deferred = jQuery.Deferred(); setTimeout(function() { return deferred.resolve(FeaturesData.features); }, 5); return deferred; }); }); after(function() { Constants.getDataSources.restore(); jQuery.getJSON.restore(); }); it('should create 1 category container with 1 category "Domains and Sites"', function(done) { var opts = { el: yourDiv, uniprotacc: '', exclusions: ['MOLECULE_PROCESSING', 'PTM', 'SEQUENCE_INFORMATION', 'STRUCTURAL', 'TOPOLOGY', 'MUTAGENESIS', 'PROTEOMICS', 'VARIATION'] }; var instance = new FeaturesViewer(opts); instance.getDispatcher().on("ready", function() { var catContainer = document.querySelectorAll('.up_pftv_container .up_pftv_category-container'); assert.equal(catContainer.length, 1, 'only one up_pftv_category-container'); assert.equal(catContainer[0].childElementCount, Constants.getCategoryNamesInOrder().length + 1, 'up_pftv_category-container children count'); assert.equal(catContainer[0].children[0].className, 'up_pftv_category_on_the_fly', 'one for on the fly' + ' categories'); assert.equal(catContainer[0].children[1].className, 'up_pftv_category_DOMAINS_AND_SITES', 'one for' + ' domains'); var catWithName = document.querySelectorAll('.up_pftv_container .up_pftv_category-name'); assert.equal(catWithName.length, 1, 'only one category with name'); var children = document.querySelectorAll('.up_pftv_category-container .up_pftv_category'); assert.equal(children.length, 1, 'category count'); var catTitle = document.querySelector('.up_pftv_category-container .up_pftv_category-name'); assert.equal(catTitle.text.toUpperCase(), "DOMAINS & SITES", 'first category title'); var categoryFeatures = document.querySelector('.up_pftv_category-container .up_pftv_category-viewer-group'); assert.equal(categoryFeatures.childElementCount, instance.data[0][1].length, 'first category' + ' features count'); done(); }); }); it('should create 2 categories "Topology" and "Mutagenesis", in that order', function(done) { var opts = { el: yourDiv, uniprotacc: 'P05067', exclusions: ['DOMAINS_AND_SITES', 'MOLECULE_PROCESSING', 'PTM', 'SEQUENCE_INFORMATION', 'STRUCTURAL', 'VARIATION', 'PROTEOMICS'] }; var instance = new FeaturesViewer(opts); instance.getDispatcher().on("ready", function() { var children = document.querySelectorAll('.up_pftv_category-container .up_pftv_category'); assert.equal(children.length, 2, 'category count'); var catTitle = document.querySelectorAll('.up_pftv_category-container .up_pftv_category-name'); assert.equal(catTitle[0].text.toUpperCase(), "TOPOLOGY", 'second category title'); assert.equal(catTitle[1].text.toUpperCase(), "MUTAGENESIS", 'first category title'); var categoryFeatures = document.querySelectorAll('.up_pftv_category-container' + ' .up_pftv_category-viewer-group'); assert.equal(categoryFeatures.length, 5, 'category and type tracks number'); assert.equal(categoryFeatures[0].childElementCount, instance.data[0][1].length, 'second category' + ' features count'); assert.equal(categoryFeatures[3].childElementCount, instance.data[1][1].length, 'first category' + ' features count'); done(); }); }); });
41.543103
120
0.626686
f208a744931ce5c5e73154865990aa9f8bfdd420
71
js
JavaScript
src/components/range-analyzer/index.js
spitzgoby/my-poker-review
d6ae0633d2a019af6fa44d4e02c5f197a26bdadb
[ "MIT" ]
null
null
null
src/components/range-analyzer/index.js
spitzgoby/my-poker-review
d6ae0633d2a019af6fa44d4e02c5f197a26bdadb
[ "MIT" ]
3
2020-07-17T08:45:34.000Z
2022-02-12T12:09:08.000Z
src/components/range-analyzer/index.js
spitzgoby/my-poker-review
d6ae0633d2a019af6fa44d4e02c5f197a26bdadb
[ "MIT" ]
null
null
null
import EquityAnalyzer from './container' export default EquityAnalyzer
23.666667
40
0.84507
f20ac390dba92fbd4a9015854740832cc3ad17d8
194
js
JavaScript
index.test.js
web3data/iso4217-js
c37a22edb669036b8d29183c12a209f4d03eba70
[ "Apache-2.0" ]
null
null
null
index.test.js
web3data/iso4217-js
c37a22edb669036b8d29183c12a209f4d03eba70
[ "Apache-2.0" ]
null
null
null
index.test.js
web3data/iso4217-js
c37a22edb669036b8d29183c12a209f4d03eba70
[ "Apache-2.0" ]
null
null
null
const assert = require("assert"); const ISO4217 = require("./index"); assert(ISO4217.isCurrencyCode("USD")); try { ISO4217.isCurrencyCode("FAKE") assert(false); } catch { assert(true); }
17.636364
38
0.680412
f20bebf7051be7790572dc96265b8f46aa4404c8
195
js
JavaScript
d0/dd7/class_ext_1_1_net_1_1_negative_id_generator_1_1_config.js
extnet/docs5.ext.net
e99e4d3894640fb1f66882443fe7348fc3181f55
[ "Apache-2.0" ]
null
null
null
d0/dd7/class_ext_1_1_net_1_1_negative_id_generator_1_1_config.js
extnet/docs5.ext.net
e99e4d3894640fb1f66882443fe7348fc3181f55
[ "Apache-2.0" ]
null
null
null
d0/dd7/class_ext_1_1_net_1_1_negative_id_generator_1_1_config.js
extnet/docs5.ext.net
e99e4d3894640fb1f66882443fe7348fc3181f55
[ "Apache-2.0" ]
null
null
null
var class_ext_1_1_net_1_1_negative_id_generator_1_1_config = [ [ "Increment", "d0/dd7/class_ext_1_1_net_1_1_negative_id_generator_1_1_config.html#a396a4ce1c127f8bca54acfa891ce84ce", null ] ];
48.75
129
0.851282
f20bfeeee6dfd13ac18a7455817b97161a815e59
3,708
js
JavaScript
js/app.js
Our-Passion/library
1b0ca1a8f95693ceb3a42d5b481e32e3d138216e
[ "MIT" ]
null
null
null
js/app.js
Our-Passion/library
1b0ca1a8f95693ceb3a42d5b481e32e3d138216e
[ "MIT" ]
2
2021-08-13T10:31:20.000Z
2021-08-15T23:07:59.000Z
js/app.js
Our-Passion/library
1b0ca1a8f95693ceb3a42d5b481e32e3d138216e
[ "MIT" ]
4
2021-08-17T18:14:18.000Z
2021-11-24T20:04:38.000Z
let galaryArray = [ 'the_idiot.jpg', 'ARE-WE-THERE.jpg', 'HTML and CSS.jpg', 'The-Testaments.jpg', 'The-Handmaid-Tale.jpg', 'IT.jpg', 'Misery.jpg', 'Practical-Magic.jpg', 'The-World-That-We-Knew.jpg', 'Morality-for-Beautiful-Girls.jpg', 'The-Miracle-at-Speedy-Motors.jpg', 'Murder-a-the-Vicarage.jpg', 'The-Murder-of-Roger-Ackroyd.jpg', ]; let allImg = []; let previousImg = []; const sectionOfImg = document.getElementById('imgHome'); let book1 = document.getElementById('book1'); let book2 = document.getElementById('book2'); let book3 = document.getElementById('book3'); let book4 = document.getElementById('book4'); let book5 = document.getElementById('book5'); function ImgSrc(name, srcOfImg) { this.name = name; this.img = srcOfImg; ImgSrc.allImg.push(this); } ImgSrc.allImg = []; for (let i = 0; i < galaryArray.length; i++) { new ImgSrc(galaryArray[i].split('.')[0], galaryArray[i]); } function getRandomNumber(min, max) { return Math.floor(Math.random() * (max - min + 1) + min); } let book1random ; let book2random; let book3random; let book4random; let book5random; //let book6random; //let book7random; function render() { do { book1random = getRandomNumber(0, galaryArray.length - 1); book2random = getRandomNumber(0, galaryArray.length - 1); book3random = getRandomNumber(0, galaryArray.length - 1); book4random = getRandomNumber(0, galaryArray.length - 1); book5random = getRandomNumber(0, galaryArray.length - 1); //book6random = getRandomNumber(0, galaryArray.length - 1); //book7random = getRandomNumber(0, galaryArray.length - 1); } while (book1random === book2random || book1random === book3random || book1random === book4random ||book1random === book5random || book2random === book3random ||book2random === book4random || book2random === book5random || book3random === book4random || book3random === book5random ||book4random === book5random || previousImg.includes(book1random) || previousImg.includes(book2random)|| previousImg.includes(book4random)|| previousImg.includes(book5random)|| previousImg.includes(book3random)); previousImg=[book1random,book2random,book3random,book4random,book5random]; book1.src =`./img/${ImgSrc.allImg[book1random].img}` ; book2.src = `./img/${ImgSrc.allImg[book2random].img}` ; book3.src = `./img/${ImgSrc.allImg[book3random].img}` ; book4.src = `./img/${ImgSrc.allImg[book4random].img}` ; book5.src = `./img/${ImgSrc.allImg[book5random].img}` ; //book6.src = `./img/${ImgSrc.allImg[book6random].img}` ; //book7.src = `./img/${ImgSrc.allImg[book7random].img}` ; //e.target.id === 'book6' || e.target.id === 'book7' } render(); console.log(render); sectionOfImg.addEventListener('click', clickOnimg); function clickOnimg(e) { if((e.target.id === 'book1' || e.target.id === 'book2' || e.target.id === 'book3'|| e.target.id === 'book4' || e.target.id === 'book5') ) { if (e.target.id === 'book1'){ ImgSrc.allImg[book1random]; console.log(ImgSrc.allImg); } else if ( e.target.id === 'book2') { ImgSrc.allImg[book2random]; } else if ( e.target.id === 'book3') { ImgSrc.allImg[book3random]; } else if ( e.target.id === 'book4') { ImgSrc.allImg[book4random]; } else if ( e.target.id === 'book5') { ImgSrc.allImg[book5random]; } //else if ( e.target.id === 'book6') { // ImgSrc.allImg[book6random]; //} //else if ( e.target.id === 'book7') { // ImgSrc.allImg[book7random]; //} render(); } }
27.466667
76
0.630259
f20d0da68f020d80c9d155ad02abbe06c7035c93
2,404
js
JavaScript
test/package.test.js
CoverBuilder/zxp-builder
19c7703fb8489ee4d1449c6124f82ccd04d3d4cb
[ "MIT" ]
1
2019-09-07T20:38:35.000Z
2019-09-07T20:38:35.000Z
test/package.test.js
CoverBuilder/zxp-builder
19c7703fb8489ee4d1449c6124f82ccd04d3d4cb
[ "MIT" ]
5
2019-01-08T09:04:27.000Z
2019-02-05T04:17:41.000Z
test/package.test.js
CoverBuilder/zxp-builder
19c7703fb8489ee4d1449c6124f82ccd04d3d4cb
[ "MIT" ]
1
2021-01-10T09:28:54.000Z
2021-01-10T09:28:54.000Z
/* globals beforeEach, it, describe */ 'use strict'; var path = require('path'), zxpSignCmd = require('zxp-sign-cmd'), expect = require('chai').expect, cmd = require('node-cmd'), exec = require('child_process').exec, testPassword = 'testPs', testCertName = 'testCert', testCertLoc = path.join(__dirname, '..', 'bin', testCertName + '.p12'), testZxpName = 'test', testZxpLoc = path.join(__dirname, '..', 'bin', testZxpName + '.zxp'); describe('zxpbuild tests', function () { this.timeout(15000); var options = []; var testCommand = ''; beforeEach(function () { testCommand = 'zxpbuild package '; options = [ '--input', path.join(__dirname, 'ext'), '--output', testZxpLoc, '--cert', testCertLoc, '--password', testPassword ]; }); it('Should throw an error because input is not provided', function (done) { options.splice(0, 2); testCommand += options.join(' '); cmd.get( testCommand, function(err, data, stderr){ expect(data).to.match(/input property is required/); done(); } ); }); it('Should throw an error because output is not provided', function (done) { options.splice(2, 2); testCommand += options.join(' '); console.log(testCommand); cmd.get( testCommand, function(err, data, stderr){ expect(data).to.match(/output property is required/); done(); } ); }); it('Should throw an error because cert is not provided', function (done) { options.splice(4, 2); testCommand += options.join(' '); cmd.get( testCommand, function(err, data, stderr){ expect(data).to.match(/cert property is required/); done(); } ); }); it('Should throw an error because password is not provided', function (done) { options.splice(6, 2); testCommand += options.join(' '); cmd.get( testCommand, function(err, data, stderr){ expect(data).to.match(/password property is required/); done(); } ); }); });
27.632184
82
0.507072