text stringlengths 7 3.69M |
|---|
import {CENTS_PER_STANDARD_SEMITONE, HUMAN_MAX_FREQ, HUMAN_MIN_FREQ, STANDARD_A4} from 'util/music';
export const IS_TOUCH_SCREEN = 'ontouchstart' in window;
export const DEFAULT_TRANSPOSITION = 3 * CENTS_PER_STANDARD_SEMITONE;
export const DEGREES_IN_CIRCLE = 360;
export const RADIANS_IN_CIRCLE = Math.PI * 2;
export ... |
ko.bindingHandlers.for = {
init: function (element, valueAccessor, allBindingsAccessor, viewModel, bindingContext) {
if ($(element).attr("inner-source") == undefined) {
$(element).attr("inner-source", $(element).html());
}
$(element).empty();
},
update: function (element... |
import React from 'react';
import './search.style.css';
const Search = ({onChange})=>{
const onInputChange=(e)=>{
onChange(e.target.value);
}
return (
<div className="search">
<div className="container">
<h3>Search</h3>
<input type="text" placeholder='name' onChange={onInputChange}/>
... |
import React from 'react';
import { makeStyles } from '@material-ui/core/styles';
import {
Grid, Paper, Button, Typography, Tooltip, Popover, IconButton, CssBaseline,
Dialog, DialogActions, DialogContent, TextField, DialogTitle, Snackbar
} from '@material-ui/core';
import DateFnsUtils from '@date-io/date-fns';
... |
import React from "react";
export default function ResumeBadge({ label }) {
let color = "orange";
if (label === "New Role") {
color = "green";
}
if (label === "Career Change") {
color = "purple";
}
if (label === "Industry Switch") {
color = "yellow";
}
return... |
document.write('<p>Du texte écrit en JavaScript</p>');
alert('Hello World en JavaScript')
|
import { types } from "./CommentAction"
export default function(state = [], action) {
switch (action.type) {
case types.REQUEST_COMMENTS:
return [...action.comments];
case types.ADD_COMMENT:
return [...state, action.comment];
case types.CLEAR_STATE:
return [];
default: return state... |
/**
* Сенсорное управление
*/ "use strict";
function Sensor() {
this.offsetx=0;
this.offsety=0;
}
Sensor.prototype.load = function() {
this.w=Map["arrow"].width;
this.h=Map["arrow"].height;
for (var i=1;i<4;i++) { //стороны
Map["arrow"][i]=new Image();
Map["arrow"][i]=Utils.rotateImage(Map["arrow"... |
describe('stock your logical thinking and "Algorithm of an Algorithm" here.', function() {
describe('Kaprekars Constant', function() {
var stock;
beforeEach(function() {
stock = new Kaprekars();
});
it('should work when a single digit number is passed in', function() {
expect(stock.co... |
import React, { Component } from 'react';
import { Navbar, Nav,NavItem, NavDropdown, MenuItem } from 'react-bootstrap';
import './amidairNavBar.css';
class AmidairNavBar extends Component {
constructor(props) {
super(props);
this.state = {isToggleOn: true, showExecutif: true};
// This binding is necessa... |
import React from 'react';
export function Footer(){
return(
<div id='neki'>
<p>Neki text drugi</p>
<p>Neki text drugi</p>
<p>Neki text drugi</p>
<p>Neki text drugi</p>
</div>
)
} |
import React from 'react';
import Layout from './components/Layout/Layout';
import BurgerBuilder from './containers/BurgerBuilder/BurgerBuilder';
function App() {
return (
<Layout>
<BurgerBuilder />
</Layout>
);
}
export default App;
// Discount Jonas kiest ervoor om App en Layout twee aparte dingen... |
/*EXPECTED
1
1
2
3
5
*/
class _Main {
static function main (args : string[]) : void {
function * fib () : Generator.<void,number> {
var a = 0, b = 1;
while (true) {
var t = a;
a = b;
b = t + b;
yield a;
}
}
var g = fib();
for (var i = 0; i < 5; ++i) {
log g.next().value;
}
}
}
|
import React, { useState, useEffect } from "react";
// import { TweenMax, TimelineLite, Power3 } from "gsap";
import { Link } from "react-router-dom";
import "./Home.css";
function Home() {
return (
<div className="home">
<div className="home__links">
<Link to="/about" className="link white one">
... |
import request from '@/utils/request'
import { urlPrivilege, urlCrowd } from '@/api/commUrl'
const url = urlPrivilege
// const url = 'http://192.168.0.227:8080/admin'
//李义广本地地址
//const url = 'http://192.168.0.215:8080/fwas-privilege-admin/sys'
// 左侧(一级二级)特权数据列表展示
export function getTreeData(params) {
return reques... |
import React from "react"
import {Route, Switch} from "react-router-dom"
import Home from "./pages/usersHome"
import userDetails from "./pages/UserDetails"
import userUpdate from "./pages/userUpdate"
export default function(){
return (
<Switch>
<Route exact path="/" component={Home}/>
... |
const pool = require("./database");
//fonction
module.exports.getMessage= async (userId_Receiver, userId_Sender, client) =>{
return await client.query("SELECT * FROM Messages WHERE userId_Receiver =$1 and userId_Sender = $2",[userId_Receiver,userId_Sender]);
}
module.exports.addMessage = async (userId_Rece... |
import React from "react";
import {
FaGithub,
FaTwitter,
FaLinkedin
} from "react-icons/fa";
// https://gorangajic.github.io/react-icons/fa.html
const SocialLinks = () => (
<ul className="social">
<li>
<a href="https://github.com/Wdifulvio523" target="_blank">
<FaGithub />
</a>
</li... |
import React, { Component } from 'react';
import { Gesture } from 'react-with-gesture';
import { Spring, animated, interpolate } from 'react-spring';
import styled from 'styled-components';
import { absolute } from 'Utilities';
import { Card } from './Elements/Cards';
const maxWith = '200px';
export default ... |
const path = require('path');
// const Datastore = require('nedb')
const nedbPromise = require('nedb-promise');
const { pathname } = require('../vars.cjs');
const initNedb = (dbnames = []) => {
const db = {};
for (const o of dbnames) {
const dbname = Array.isArray(o) ? o[0] : o;
const filename... |
import React from 'react';
import { Link } from "react-router-dom";
const GameItem = ({item}) => {
return (
<tr>
<td className="mdl-data-table__cell--non-numeric">{item.status}</td>
<td className="mdl-data-table__cell--non-numeric">{item.date}</td>
<td className="mdl-dat... |
/**
* Created by Administrator on 2018/4/13.
*/
import React,{Component} from 'react';
import ReactDOM from 'react-dom';
import {connect} from 'react-redux';
import {bindActionCreators} from 'redux';
import moment from 'moment';
import { Carousel,PullToRefresh } from 'antd-mobile';
import 'antd-mobile/lib/pull-to-re... |
import styled, {
css
} from "styled-components";
const sharedStyleA = css `
display: flex;
justify-content: center;
align-items: center;
color: white !important;
font-size: .94rem;
height: var(--hmenu);
padding: 1rem;
letter-spacing: 1px;
text-transform: uppercase;
text-deco... |
import React from 'react';
import Layout from '../hoc/Layout/Layout';
import * as actions from '../store/actions/general';
import axios from "../axios-site"
import SearchView from "../containers/Search/Search"
import i18n from '../i18n';
import { withTranslation } from 'react-i18next';
import PageNotFound from "../con... |
/* JavaScript Object */
/* Object Construction */
// Object Literal
var a = {}
console.log(typeof a)
// new Keyword
var b = new Object()
console.log(typeof b)
// Object.create(property)
var c = Object.create(null)
console.log(typeof c)
// new FunctionName(params)
function Man () {
return 1
}
var d = new Man()
consol... |
import React, { Component } from 'react';
import {
View,
Text,
FlatList,
StyleSheet,
Image,
ActivityIndicator,
} from 'react-native';
import { SearchBar } from 'react-native-elements';
import { connect } from 'react-redux';
import { listProducts } from './action';
class ProductList extends Co... |
import React, { Component } from 'react';
import { Jumbotron } from 'reactstrap';
class NotFound extends Component {
render() {
return (
<Jumbotron className="bg-white">
<h1>Page Not Found!</h1>
<p>The page you are trying to reach cannot be found. Make sure the address is correct or go back... |
const repeatString = function(str, times) {
if( times < 0 ) return 'ERROR';
if( times === 0 ) return '';
return str + repeatString(str, times - 1);
}
module.exports = repeatString
|
const path = require('path');
const express = require('express'); //framework
const userController = require('../controllers/user');
const router = express.Router();
//trả về home mỗi khi mở lên
router.get('/', userController.getHome);
//các đường link url và các controller tương ứng để điều khiển nó
router.get('... |
import React from 'react';
import { useLocation } from 'react-router-dom';
const Header = ({ title, onReset, expeditionsCount }) => {
const location = useLocation();
return (
<header className="row">
<nav className="navbar bg-primary col-12">
<a className="nav-link text-white h5" href="https://ww... |
const router = require("express").Router();
const Estado = require("../models/Estado");
const Pais = require("../models/Pais");
// SE USAN SOLO EN EL DASHBOARD PARA CREAR ESTADOS Y REPRESENTARLOS
router.post('/new',(req,res, next)=>{
Estado.create(req.body)
.then(estado=>{
Pais.findByIdAndUpdate(req.bo... |
'use strict'
var num = 20;
function isEven(num) {
if ( (20 % 2) == 0) {
return 'is true'
//console.log('is true')
} else {
return 'is false'
//console.log('is false')
}
}
var resultat = (isEven(20))
console.log(resultat); |
import React, { Component } from "react";
import Header from "./Header";
import PostForm from "./posts/PostForm";
import PostImg from "./posts/PostImg";
class PostNew extends Component {
state = { showConfirm: false };
render() {
return (
<div>
<Header />
<div className="container">
... |
const components ={
signUp:`<section class="sign-up-container">
<form class="form-sign-up">
<div class="form-header">
<h3>MindX Chat</h3>
</div>
<div class="form-content">
<div class="name-wrapper">
<div class="input-wrapper">
<... |
// Copyright (c) 2016-2018, BuckyCloud, Inc. and other BDT contributors.
// The BDT project is supported by the GeekChain Foundation.
// All rights reserved.
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are met:
// * Red... |
// To work correctly, these ratios need to be maintained exactly, e.g. xxSmall must be 2x tiny etc.
export default {
min: 0,
tiny: 2,
xxSmall: 4,
xSmall: 8,
small: 12,
medium: 16,
large: 24,
xLarge: 32,
xxLarge: 48,
giant: 64,
max: 88,
}
|
import { reqSpecsList} from '../../utils/request'
const state = {
list: []
}
const mutations = {
changeList(state, arr) {
state.list = arr
},
}
const actions = {
requestSpecsList(context) {
reqSpecsList({ size: 10, page: 1 }).then(res => {
res.data.list.forEach(item => {
item.attrs = JSO... |
var Accessory = require('../').Accessory;
var Service = require('../').Service;
var Characteristic = require('../').Characteristic;
var uuid = require('../').uuid;
var util = require('util');
var mqtt = require('mqtt');
var client = mqtt.connect('mqtt://localhost');
var BattleStation = {
name: "Battle Station PC",... |
const config = {
isProd: false
}
export default config
|
var pets = require('../controllers/controllers');
var path = require('path');
module.exports = function (app) {
app.get('/', function (req, res) {
// This is where we will retrieve the users from the database and include them in the view page we will be rendering.
pets.index(req, res);
})
// Below is ex... |
function logURL(requestDetails) {
var matches = requestDetails.url.match(/^https?\:\/\/([^\/?#]+)(?:[\/?#]|$)/i);
var domain = matches && matches[1];
var exeFile = Components.classes["@mozilla.org/file/local;1"].createInstance(Ci.nsILocalFile);
exeFile.initWithPath("/tmp/parse_firefox.py");
if(exeFile... |
(function () {
'use strict';
angular
.module('0908essbar')
.config(config);
function config($stateProvider) {
$stateProvider
.state('0908essbar', {
url: '/archiv-2017/09-08-essbar',
templateUrl: 'archiv-2017/09-08-essbar/views/09-08-essbar.tpl.html',
controller: 'C0908e... |
var express = require("express"),
passport = require("passport"),
signin = require("./signin");
var app = express(),
users = new Bourne("users.json"),
photos = new Bourne("photos.json"),
comments = new Bourne("comments.json");
passport.use(signin.strategy(users));
passport.serialiceUser(signin.se... |
export const SEARCH_MOVIE_REQUESTED = "SEARCH_MOVIE_REQUESTED";
export const SEARCH_MOVIE_FINISHED = "SEARCH_MOVIE_FINISHED";
export const SEARCH_STRING_CHANGED = "SEARCH_STRING_CHANGED";
export const PAGE_CHANGED = "PAGE_CHANGED";
export const VIEW_MOVIE_SELECTED = "VIEW_MOVIE_SELECTED";
export const MOVIE_DETAILS... |
import React, {Component} from 'react';
import {Grid, FABButton, Icon, Dialog, DialogTitle, DialogContent, DialogActions, Button, Textfield, Chip} from 'react-mdl';
export default class PostModal extends Component {
constructor(props) {
super(props)
this.state = { category: 'sell', title: '', description: '... |
import axios from 'axios';
class ProfileApi {
constructor() {
this.apiInstance = axios.create({
baseURL: `${process.env.REACT_APP_API_URL}`,
withCredentials: true
});
}
getUserInfo() {
return this.apiInstance.get('/profile')
.then(({ data }) => {
return data
})
}
... |
$('#submitBtn').on('click', function () {
var name = $('#nameInput').val().trim();
var phone = $('#phoneInput').val().trim();
var email = $('#emailInput').val().trim();
var time = $('#timeInput').val().trim();
var clientObj = {
"name": name,
"phone": phone,
"email": email,
"time": time
}//client obj
$.... |
Template.stub('devicesinfo');
describe("devicesinfo template", function () {
it("functions", function () {
Template.devicesinfo.created();
expect(Session.get('errorMessage')).toBe(null);
Session.set('currentdevice',1234);
var device = { _id : "1234"};
... |
import express, { json, urlencoded } from 'express';
import { join } from 'path';
import cookieParser from 'cookie-parser';
import logger from 'morgan';
import session from 'express-session';
import passport from 'passport';
import passportLocal from 'passport-local';
import apiRoutes from './routes/api';
import { in... |
module.exports = {
summary: 'The rule to demo AnyProxy plugin',
getWebFiles() {
return [
'./web.js',
'./web.css'
]
},
*beforeDealHttpsRequest(requestDetail) {
return true;
},
*beforeSendRequest(requestDetail) {
requestDetail.pluginData = {
requestPluginData: 'The data you ... |
import React from "react";
import FormPanel from "./FormPanel.jsx"
import EthClient from "../client/ethclient.js";
import PubSub from "pubsub-js"
let WorkerPanel = React.createClass({
registerWorker(worker) {
EthClient.registerWorker(worker.maxLength, worker.price,
worker.w... |
import React, { Component } from "react";
import { connect } from "react-redux";
import { getAppCustomization } from "../../lib/helpers";
import { POSITION } from './properties';
import { LayoutLeft, LayoutRight, LayoutTop, LayoutBottom } from './Positions';
import _ from 'lodash';
import "./index.css";
class SubSecti... |
var event_id = $('#event_id').val();
var event_name = $('#event_name').val();
var add_invite = $('#add_invite').val();
var invite_detail = $('#invite_detail').val();
var update_invite = $('#update_invite').val();
var delete_invite = $('#delete_invite').val();
var event_mark_incomplete = $('#event_mark_incomplete').val(... |
FvB.Sprites = (function () {
FvB.setConsts({
GFX_PATH: 'gfx'
});
// hitBoxes are relative to the entity x,y position, which is center x, bottom y
var sprites = [
{ sprite: "SPR_RYU_BACKGROUND", sheet: "RYU-STAGE.PNG", xOffset: 0, yOffset: 0, width: 640, height: 400, hitBox: null },
... |
/**
* This test should create books and its associating models, genre model must be created to calssify books.
* Author model is created to for books that have more than one author, with its associations
* User model is created to test its -belongsToMany association with user, this associations
* takes care books ... |
const path = require("path");
const express = require("express");
const mongoose = require("mongoose");
const bodyParser = require("body-parser");
const bcrypt = require("bcryptjs");
const User = require("./models/Users");
const { Client } = require("ssh2");
const port = 5555;
const app = express();
app.use(bodyParser... |
exports.currentUser = (req, res) => {
res.send(req.user);
}
exports.logout = (req, res) => {
req.logout();
res.redirect("/");
}
exports.login = (req, res) => {
res.redirect("/notes");
} |
const bcrypt = require("bcryptjs");
const jwt = require("jsonwebtoken");
const nodemailer = require("nodemailer");
import isEmail from "validator/lib/isEmail";
import isLength from "validator/lib/isLength";
import generateInline from "../../../templates/verifyEmail";
import baseUrl from "../../../utils/baseUrl";
impor... |
import { StyleSheet, Platform } from 'react-native';
import Dimensions from 'Dimensions';
export default StyleSheet.create({
feedPage:{
marginBottom: 48,
backgroundColor: '#F1F3F5',
},
feedWrapper: {
flex: 1,
backgroundColor: '#F1F3F5',
flexDirection: 'column',
justifyContent: 'space-betw... |
let color1Class = document.querySelectorAll('.color1');
const color1Length = color1Class.length;
let colorPicker = document.querySelector('.colorPicker');
let drawingColor = "black"; // initial pen lnk color
let penSize = 1; // initial pen size
// handle color picker
colorPicker.addEventListener('input', e => {
dr... |
/*
the date input is the MM/dd/yyyy and the time input is military time HH:mm
This creates a Calendar event entry with the specified name, start time, and duration
*/
function createCal(name, date, time) {
var duration = 60; //duration of event in minutes
var startTime = new Date(date + ' ' + time);
var endTime ... |
export { Layout } from "./layout/layout"
export Modal from "./modal/modal"
|
/* @flow */
import React from 'react';
import first from 'lodash/first';
import type { Element } from 'react';
type Props<T> = {
array: T[],
render: T => ?Element<*>,
container?: React$ElementType,
className?: ?string,
id?: ?string,
};
export default function First<T>({
array,
render,
container,
cl... |
import palette from 'palette';
import exif from 'exif2';
import convert from 'color-convert';
import Canvas, {Image as CanvasImage} from 'canvas';
export default class Image {
constructor(props) {
this.root = props.root;
this.path = props.path;
this.folder = props.folder;
}
getImag... |
import React from 'react'
import PropTypes from 'prop-types'
import { connect } from 'react-redux'
import { bindActionCreators } from 'redux'
import PastTraining from './training'
import axios from 'axios'
import { setPastTrainings, addPastTraining } from '../../actions/index'
import styled from 'styled-components'
co... |
var SceneOver = Director.createScene(function() {
this.count = 0;
this.score = 0;
this.distance = 0;
this.bestDistance = 0;
this.bestScore = 0;
if (UserDefault.getValueForKey('bestDistance', 0) < UserDefault.getValueForKey('distance', 0)) {
UserDefault.setValueForKey('bestDistance', U... |
const io = require('socket.io')
const _ = require('lodash')
const moment = require('moment')
const uuid = require('uuid')
const Player = require('./Entities/Player')
const Game = require('./Game')
let socketIo = null
const connect = function(server) {
socketIo = io.listen(server)
let game = new Game(socketIo)... |
const Main = (input) => {
const N = input.split('\n')[0]
const a = input.split('\n')[1].split(' ')
const numbers = a.map(str => parseInt(str)).sort((a, b) => b - a)
alice = 0;
bob = 0;
numbers.reduce((prev, current, index) => {
if (index % 2) {
bob += current
} else ... |
import { connect } from "react-redux";
import withStyles from "@material-ui/core/styles/withStyles";
import componentsStyle from "../assets/jss/material-kit-react/views/components";
import VendorComponent from "../views/VendorPage/Vendor";
import { getShopLocation } from "../routes/routingSystem";
const mapStateToProp... |
module.exports = {
'url' : 'mongodb://jeffomland:einstein@ds023560.mlab.com:23560/iceman'
} |
angular.module('favorTrip', []);
|
const express = require('express')
const webpack = require('webpack')
const webpackDevMiddleware = require('webpack-dev-middleware')
const app = express()
const config = require('./webpack.config.js')
const compiler = webpack(config)
app.use(webpackDevMiddleware(compiler, {
publicPush: config.output.publicPath
}))
... |
const getUser = cb => {
setTimeout(() => {
cb({
id: 1,
name: 'Guillermo A. Sanchez',
message: '👋',
});
}, 2000);
};
getUser(user => {
console.log(user);
});
// Talk about
// onSucces
// handleUser
|
/* eslint-disable no-console */
require('dotenv').config();
const express = require('express');
const path = require('path');
const cors = require('cors');
const bodyParser = require('body-parser');
const app = express();
const db = require('../db/index.js');
const port = process.env.PORT;
app.use(cors());
app.use(b... |
import * as React from 'react'
import * as ReactDOM from 'react-dom'
import { Application,PageLayout } from '@retool/app'
import * as standardControls from '@retool/standard-controls'
import * as controls from './controls'
var app = new Application("SampleApp");
app.controls.import(controls);
import * as templates... |
/* global $ */
$(document).ready(function(){
$('#men').click(function(event){
event.preventDefault();
$('#men').addClass('active');
$('.men').removeClass('hidden');
$('#women').removeClass('active');
$('.women').addClass('hidden');
});
$('#women').click(function(event){
event.preven... |
import React from 'react'
import {Link} from 'react-router-dom'
import './header.less'
const Header = () => {
return (
<header className="top-panel">
<div className="top-panel__container">
<div className="top-panel__title">
интернет магазин недвижимости
... |
const express = require('express'),
app = express(),
cookieParser = require('cookie-parser'),
{ config } = require('dotenv'),
logger = require('morgan'),
{ urlencoded, json } = express;
// parses incoming requests with JSON payloads
app.use(urlencoded({ extended: true }));
app.use(json());
// load env variabl... |
import React from "react";
import Link from "gatsby-link";
import "./navButton.css";
import { navigateTo } from "gatsby-link";
export default props => {
return (
<div className={`${props.position} relative`}>
<a
onClick={() => navigateTo(`${props.path}`)}
className={`bttn color-${props.sty... |
'use strict';
angular.module('oprum')
.service('loginService', ['$http', '$q',
function ($http, $q) {
function getExternalLogins() {
var deferred = $q.defer();
$http({
method: "GET",
url: "api/Account/ExternalLogins",
... |
import React, { useRef, useState } from 'react';
import { View, StyleSheet, SafeAreaView, Text, TextInput, Dimensions, Animated } from 'react-native';
import { FlatList, TouchableOpacity } from 'react-native-gesture-handler';
const PollingScreen = (props) => {
const [question, setQuestion] = useState(props.route.pa... |
describe('tests in the file test.js', () => {
test('should be a equals to strings ', () => {
// 1. Initialization
const message = 'Hello word!'
// 2. Stimulus
const message2 = `Hello word!`
// 3. Observe Behavior
expect( message ).toBe(message2)
})
})
|
Polymer.NeonAnimatableBehavior = {
properties: {
animationConfig: {
type: Object
},
entryAnimation: {
observer: "_entryAnimationChanged",
type: String
},
exitAnimation: {
observer: "_exitAnimationChanged",
type: Stri... |
import React, { useState } from "react";
import styled from "styled-components";
const defaultValue = "placeholder";
const StyledInput = styled.input`
border: none;
outline: none;
&,
&::focus,
&::active {
border: none;
outline: none;
}
`;
export const NoBorderInput = ({ value, onChange, validate,... |
var args = require('aargs')
var logger = require('./lib/logger')
var app = require('./lib/app')
// Arguments from CLI
var PORT = args.port || 1337
var HOST = args.host || '127.0.0.1'
// Start server
app.listen(PORT, HOST, () => {
logger.info(`Listening on http://${HOST}:${PORT}`)
}) |
var vertices;
var animFrame;
var zArray = false;
var zBuffer;
var val = 1;
var canCalc = false;
var stages, speeds;
var needsUpdate = true;
var values;
var smoothVal = 1;
//t = current time, b = start val, c = change in val, d= duration
var inOutQuart = function (t, b, c, d) { if ((t/=d/2) < 1) return c/2*t*t*t*t + b... |
/************ 전역변수 *************/
var datas;
var mainNow = 0;
var mainPrev, mainNext, mainLast;
var infoChk = true; // info-wrap의 애니메이션 진행여부(true면 진행, flase면 무시)
/************ 사용자 함수 *************/
function mainAjax() {
$.get("../json/banner.json", function(res){
datas = res.banners;
mainLast = datas.length - 1... |
(function () {
'use strict';
angular
.module('wizardApp')
.controller('MetricsController', MetricsController);
MetricsController.$inject = ['$scope', '$state', '$location', '$stateParams'];
function MetricsController($scope, $state, $location, $stateParams) {
var vm = this;... |
import Translator from "../containers/Translator";
import "../styles/css/styles.css";
const TranslationPage = () => {
return (
<div>
<h1 className="center-basic">Basic UI for Translation (Dev)</h1>
<Translator></Translator>
</div>
);
};
export default TranslationPage;
|
/* @flow */
/* **********************************************************
* File: containers/DeveloperContainer.js
*
* Brief: Container for holding the DeveloperPage
*
* Authors: Craig Cheney
*
* 2017.10.10 CC - Document created
*
********************************************************* */
import { bindActionCreators ... |
// returns a single tile to be used in the tile view menu
// routing, color, and title can be set via the path, backcolor, and cardTtile props
import React from 'react';
import PropTypes from 'prop-types';
import {withStyles} from '@material-ui/core/styles';
import Card from '@material-ui/core/Card';
import Car... |
var c, w, h, m, p = {},
{
min,
floor,
PI,
cos,
sin,
pow,
random,
round,
ceil
} = Math,
T_PI = PI * 2
var BOT_SPEED = 1
function roundRect(ctx, x, y, width, height, radius, fill, stroke) {
if (typeof stroke === 'undefined') {
... |
const Cropper = require('cropperjs/dist/cropper.min') ;
var $modal;
var $btnValidateCrop;
var $image;
var cropper;
var aspectRatio = 1;
module.exports = {
init: function(){
$modal = $("#modal-cropper-tool");
$btnValidateCrop = $("#validate-crop");
$image = $("#crop-image");... |
SerialPort = Npm.require('serialport');
|
/*-------------------------------------------------------------
| THE MOST FKIN BEAUTIFUL |
| THING I HAVE EVER SEEN |
| IN MY LIFE |
| THANK YOU DANC-SENPAI ... |
import React,{Component} from "react";
import "./index.css";
import axios from "axios";
import DDDD from "../dddd"
class Cinema extends Component{
constructor(){
super();
this.state = {
cinemalist:[],
ddddShow:false,
}
}
render(){
return <div>
<div className="navbg">
<span className="left">... |
import React from 'react';
import PhotoManager from './components/PhotoManager';
import './App.css';
function App() {
return (
<PhotoManager />
);
}
export default App;
|
/* @flow */
import * as React from 'react';
import { Form, Formik } from '../dist/formik';
import Mutation from './controls/Mutation';
import Input from './controls/Input';
import NumberInput from './controls/NumberInput';
import bind from './bind';
import someApiMutation from './mutations/someApiMutation';
type Props... |
X.define("model.authorityModel",function () {
//临时测试数据
var query = "js/data/mockData/purchasers.json";
var authorityModel = X.model.create("model.authorityModel",{service:{ query:query}});
return authorityModel;
});
|
var contentDoc = 'https://docs.google.com/spreadsheets/d/1Wc7hkoh0T32zDRtcJIVGw1pKqTjHASAlj92vz6Qz5zs/pubhtml';
function loadPeople() {
$(document).ready(function() {
Tabletop.init({
key: contentDoc,
wanted: ["People"],
callback: showPeople,
orderby: 'title',
parseNumbers: false
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.