id stringlengths 26 1.14k | sliced_code stringlengths 14 19.8M | type stringlengths 1 1.35M |
|---|---|---|
0b5vr_automaton/packages/automaton-with-gui/src/view/components/FxSpawnerEntry.tsx#Root#var#22 | import { Colors } from '../constants/Colors';
import React from 'react';
import styled from 'styled-components';
export interface FxSpawnerEntryProps {
className?: string;
name?: string;
id: string;
description?: string;
isSelected?: boolean;
onClick?: (event: React.MouseEvent<HTMLDivElement>) =... | StyledComponent<"div", any, {
isSelected?: boolean | undefined;
}, never> |
0b5vr_automaton/packages/automaton-fxs-v2compat/src/sine.ts#func#ret#11 | import type { FxDefinition } from '@0b5vr/automaton';
v = context.value
context
p = context.progress * context.params.freq + context.params.phase
TAU = Math.PI * 2.0
func(context): <mask> {
const v = context.value;
const p = context.progress * context.params.freq + context.params.phase;
return v... | number |
0b5vr_automaton/packages/automaton-fxs-v2compat/src/sine.ts#p#var#13 | import type { FxDefinition } from '@0b5vr/automaton';
v = context.value
return v + context.params.amp * Math.sin(p * TAU);
context.progress * context.params.freq
const p: <mask> = context.progress * context.params.freq + context.params.phase
context.params.freq
context.params.phase
context.params.amp
context
| number |
0b5vr_automaton/packages/automaton-with-gui/src/view/components/FxSpawnerEntry.tsx#Id#var#4 | import { Colors } from '../constants/Colors';
import React from 'react';
import styled from 'styled-components';
export interface FxSpawnerEntryProps {
className?: string;
name?: string;
id: string;
description?: string;
isSelected?: boolean;
onClick?: (event: React.MouseEvent<HTMLDivElement>) =... | StyledComponent<"div", any, {}, never> |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/arraySet.ts#out#var#30 | const out: <mask> = [...from]
function arraySetDelete(array,value): boolean
arraySetDelete(out, v)
return out;
| T[] |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/arraySet.ts#out#var#21 | const out: <mask> = [...a]
function arraySetHas(array,value): boolean
arraySetHas(out, v)
out.push(v)
out.push(v);
return out;
| T[] |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/arraySet.ts#index#var#13 | const index: <mask> = array.indexOf(value)
index !== -1
array.indexOf(value)
array.push(value)
array.push(value);
| number |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/arraySet.ts#index#var#2 | const index: <mask> = array.indexOf(value)
index === -1
array.splice(index, 1)
array.indexOf(value)
array.splice(index, 1);
| number |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/useRect.ts#ref#arg#28 | import { useCallback, useLayoutEffect, useState } from 'react';
import { useElement } from './useElement';
import ResizeObserver from 'resize-observer-polyfill';
export function useRect<T extends HTMLElement | SVGElement>(ref: <mask>) {
const element = useElement(ref);
const [rect, setRect] = useState<RectResul... | React.RefObject<T> |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/useRect.ts#getRect#ret#20 | import { useCallback, useLayoutEffect, useState } from 'react';
import { useElement } from './useElement';
import ResizeObserver from 'resize-observer-polyfill';
element?
function getRect<T extends HTMLElement | SVGElement>(element?): <mask> {
if (element) {
return element.getBoundingClientRect();
}
... | RectResult |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/genGrid.ts#t0#arg#11 | export function genGrid(t0: <mask>, t1, options = {}) {
const base = options.base ?? 10;
const details = options.details ?? 0;
const delta = t1 - t0;
const logDelta = Math.log(delta) / Math.log(base);
const div = Math.pow(base, Math.floor(logDelta) - details);
const begin = Math.ceil(t0 / div) *... | number |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/arraySet.ts#arraySetAdd#ret#12 | export function arraySetAdd<T>(array, value): <mask> {
const index = array.indexOf(value);
if (index !== -1) {
return false;
}
array.push(value);
return true;
}
| boolean |
0b5vr_automaton/packages/automaton-with-gui/src/view/components/ChannelEditor.tsx#data#var#265 | import { Colors } from '../constants/Colors';
import { Labels } from './Labels';
import { MouseComboBit, mouseCombo } from '../utils/mouseCombo';
import { RangeBar } from './RangeBar';
import { RectSelectView } from './RectSelectView';
import { Resolution } from '../utils/Resolution';
import { TimeLoopRegion } from './... | StateChannelItem | null |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/arraySet.ts#array#arg#12 | export function arraySetAdd<T>(array: <mask>, value) {
const index = array.indexOf(value);
if (index !== -1) {
return false;
}
array.push(value);
return true;
}
array.indexOf(value)
index = array.indexOf(value)
index !== -1
array.push(value)
array.push(value);
| T[] |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/genGrid.ts#x#arg#4 | function mod(x: <mask>, d) {
return x - Math.floor(x / d) * d;
}
return x - Math.floor(x / d) * d;
function mod(x,d): number
d = (mod(value + 0.5 * importanceRaw, importanceRaw)) - 0.5 * importanceRaw
function closeToZero(a): boolean
closeToZero(d)
d = (mod(value + 0.5 * importanceRaw, importanceRaw)) - 0.5 * impor... | number |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/genGrid.ts#options#arg#11 | export function genGrid(t0, t1, options: <mask> = {}) {
const base = options.base ?? 10;
const details = options.details ?? 0;
const delta = t1 - t0;
const logDelta = Math.log(delta) / Math.log(base);
const div = Math.pow(base, Math.floor(logDelta) - details);
const begin = Math.ceil(t0 / div) *... | {
base?: number | undefined;
details?: number | undefined;
} |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/genGrid.ts#t1#arg#11 | export function genGrid(t0, t1: <mask>, options = {}) {
const base = options.base ?? 10;
const details = options.details ?? 0;
const delta = t1 - t0;
const logDelta = Math.log(delta) / Math.log(base);
const div = Math.pow(base, Math.floor(logDelta) - details);
const begin = Math.ceil(t0 / div) *... | number |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/arraySet.ts#value#arg#12 | export function arraySetAdd<T>(array, value: <mask>) {
const index = array.indexOf(value);
if (index !== -1) {
return false;
}
array.push(value);
return true;
}
index = array.indexOf(value)
index !== -1
array.push(value)
| T |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/useAnimationFrame.ts#callback#arg#2 | import { DependencyList, useEffect, useRef } from 'react';
export function useAnimationFrame(callback: <mask>, deps) {
const refPrev = useRef<number>(0);
useEffect(() => {
let halt = false;
const update = (): void => {
if (halt) {
return;
}
con... | (delta: number) => void |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/binarySearch.ts#elementOrCompare#arg#3 | export function binarySearch<T>(array, elementOrCompare: <mask>) {
if (typeof elementOrCompare !== 'function') {
return binarySearch(array, (element) => (element <= elementOrCompare));
}
const compare = elementOrCompare as (element: T) => boolean;
let start = 0;
let end = array.length;
w... | T | ((element: T) => boolean) |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/useAnimationFrame.ts#deps#arg#2 | import { DependencyList, useEffect, useRef } from 'react';
export function useAnimationFrame(callback, deps: <mask>) {
const refPrev = useRef<number>(0);
useEffect(() => {
let halt = false;
const update = (): void => {
if (halt) {
return;
}
con... | DependencyList |
0b5vr_automaton/packages/automaton-with-gui/src/compat/v1Compat.ts#oldParam#var#4 | newData = data
const oldParam: <mask> = newData.params[name]
oldParam.map((node, i) => ({
time: node.time,
value: node.value,
in: i === 0 ? undefined : { time: 0.0, value: 0.0 },
out: (i === oldParam.length - 1) ? undefined : { time: 0.0, value: 0.0 }
... | any[] |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/genGrid.ts#d#arg#4 | function mod(x, d: <mask>) {
return x - Math.floor(x / d) * d;
}
return x - Math.floor(x / d) * d;
function mod(x,d): number
d = (mod(value + 0.5 * importanceRaw, importanceRaw)) - 0.5 * importanceRaw
function closeToZero(a): boolean
closeToZero(d)
d = (mod(value + 0.5 * importanceRaw, importanceRaw)) - 0.5 * impor... | number |
0b5vr_automaton/packages/automaton-with-gui/src/compat/v1Compat.ts#newParam#var#5 | oldParam = newData.params[name]
time: node.time
const newParam: <mask> = {
nodes: oldParam.map((node, i) => ({
time: node.time,
value: node.value,
in: i === 0 ? undefined : { time: 0.0, value: 0.0 },
out: (i === oldParam.length - 1) ? undefined... | {
nodes: {
time: any;
value: any;
in: {
time: number;
value: number;
} | undefined;
out: {
time: number;
value: number;
} | undefine... |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/genGrid.ts#genGrid#ret#11 | function closeToZero(a:any): boolean
function mod(x:any, d:any): number
result = []
export function genGrid(t0, t1, options = {}): <mask> {
const base = options.base ?? 10;
const details = options.details ?? 0;
const delta = t1 - t0;
const logDelta = Math.log(delta) / Math.log(base);
const div = Mat... | GridEntry[] |
0b5vr_automaton/packages/automaton-with-gui/src/compat/v1Compat.ts#head#var#14 | let head: <mask> = 0
newParam = {
nodes: oldParam.map((node, i) => ({
time: node.time,
value: node.value,
in: i === 0 ? undefined : { time: 0.0, value: 0.0 },
out: (i === oldParam.length - 1) ? undefined : { time: 0.0, value: 0.0 }
... | number |
0b5vr_automaton/packages/automaton-with-gui/src/compat/v1Compat.ts#l#var#29 | newParam.nodes[head]
const l: <mask> = newParam.nodes[head].time - newParam.nodes[head - 1].time
newParam.nodes[head - 1]
newParam.nodes[head - 1].out = { time: l * 0.37, value: 0.0 };
newParam.nodes[head].in = { time: -l * 0.37, value: 0.0 };
newParam = {
nodes: oldParam.map((node, i) => ({
... | number |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/binarySearch.ts#array#arg#1 | export function binarySearch<T>(array: <mask>, element);
function binarySearch(array,element)
function binarySearch(array,compare)
function binarySearch(array,elementOrCompare): number
binarySearch(array, (element) => (element <= elementOrCompare))
protected __items: ChannelItem[] = [];
protected __items!: Array<Chann... | ArrayLike<T> |
0xProject_0x-starter-project/src/configs.ts#ROPSTEN_CONFIGS#var#13 | import * as dotenv from 'dotenv';
import { GANACHE_NETWORK_ID, ROPSTEN_NETWORK_ID } from './constants';
import { NetworkSpecificConfigs } from './types';
const ROPSTEN_CONFIGS: <mask> = {
rpcUrl: process.env.ROPSTEN_RPC_URL || '',
networkId: ROPSTEN_NETWORK_ID,
chainId: ROPSTEN_NETWORK_ID,
}
| NetworkSpecificConfigs |
0xProject_0x-starter-project/src/configs.ts#GANACHE_CONFIGS#var#8 | import * as dotenv from 'dotenv';
import { GANACHE_NETWORK_ID, ROPSTEN_NETWORK_ID } from './constants';
import { NetworkSpecificConfigs } from './types';
const GANACHE_CONFIGS: <mask> = {
rpcUrl: 'http://127.0.0.1:8545',
networkId: GANACHE_NETWORK_ID,
chainId: 1337,
}
| NetworkSpecificConfigs |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/binarySearch.ts#binarySearch#ret#1 | export function binarySearch<T>(array, element): <mask>;
function binarySearch(array,element)
function binarySearch(array,compare)
function binarySearch(array,elementOrCompare): number
binarySearch(array, (element) => (element <= elementOrCompare))
protected __items: ChannelItem[] = [];
protected __items!: Array<Chann... | number |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/binarySearch.ts#compare#arg#2 | export function binarySearch<T>(array, compare: <mask>);
function binarySearch(array,element)
function binarySearch(array,compare)
function binarySearch(array,elementOrCompare): number
binarySearch(array, (element) => (element <= elementOrCompare))
protected __items: ChannelItem[] = [];
protected __items!: Array<Chann... | (element: T) => boolean |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/useAnimationFrame.ts#useAnimationFrame#ret#2 | import { DependencyList, useEffect, useRef } from 'react';
Automaton.update(time:any): void
AutomatonWithGUI.update(time:any): void
halt = false
export function useAnimationFrame(callback, deps): <mask> {
const refPrev = useRef<number>(0);
useEffect(() => {
let halt = false;
const update = (): v... | void |
0b5vr_automaton/packages/automaton-with-gui/src/ThrottledJSONStorage.ts#key#arg#12 | import { Throttle } from './utils/Throttle';
public get<TKey extends keyof T>(key: <mask>) {
return get.values[key];
}
return get.values[key];
| TKey |
0b5vr_automaton/packages/automaton-with-gui/src/ThrottledJSONStorage.ts#key#arg#15 | import { Throttle } from './utils/Throttle';
public set<TKey extends keyof T>(key: <mask>, value) {
set.values[key] = value;
set.__throttle.do(() => set.__write());
}
| TKey |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/binarySearch.ts#array#arg#2 | export function binarySearch<T>(array: <mask>, compare);
function binarySearch(array,element)
function binarySearch(array,compare)
function binarySearch(array,elementOrCompare): number
binarySearch(array, (element) => (element <= elementOrCompare))
protected __items: ChannelItem[] = [];
protected __items!: Array<Chann... | ArrayLike<T> |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/genGrid.ts#mod#ret#4 | function mod(x, d): <mask> {
return x - Math.floor(x / d) * d;
}
function mod(x,d): number
d = (mod(value + 0.5 * importanceRaw, importanceRaw)) - 0.5 * importanceRaw
function closeToZero(a): boolean
closeToZero(d)
d = (mod(value + 0.5 * importanceRaw, importanceRaw)) - 0.5 * importanceRaw;
importanceRaw *= base;
i... | number |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/genGrid.ts#a#arg#1 | function closeToZero(a: <mask>) {
return Math.abs(a) < 1E-9;
}
Math.abs(a)
function closeToZero(a): boolean
d = (mod(value + 0.5 * importanceRaw, importanceRaw)) - 0.5 * importanceRaw
d = (mod(value + 0.5 * importanceRaw, importanceRaw)) - 0.5 * importanceRaw;
value = begin + i * div;
value = begin
closeToZero(valu... | number |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/genGrid.ts#closeToZero#ret#1 | function closeToZero(a): <mask> {
return Math.abs(a) < 1E-9;
}
function closeToZero(a): boolean
d = (mod(value + 0.5 * importanceRaw, importanceRaw)) - 0.5 * importanceRaw
d = (mod(value + 0.5 * importanceRaw, importanceRaw)) - 0.5 * importanceRaw;
value = begin + i * div;
value = begin
closeToZero(value)
function ... | boolean |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/arraySet.ts#array#arg#1 | export function arraySetDelete<T>(array: <mask>, value) {
const index = array.indexOf(value);
if (index === -1) {
return false;
}
array.splice(index, 1);
return true;
}
array.indexOf(value)
index = array.indexOf(value)
array.splice(index, 1)
array.splice(index, 1);
function arraySetDelete(ar... | T[] |
0b5vr_automaton/packages/automaton-with-gui/src/view/components/InspectorChannelItem.tsx#itemId#var#126 | import { BoolParam } from './BoolParam';
import { ChannelWithGUI } from '../../ChannelWithGUI';
import { InspectorHeader } from './InspectorHeader';
import { InspectorHr } from './InspectorHr';
import { InspectorItem } from './InspectorItem';
import { NumberParam } from './NumberParam';
import { useDispatch, useSelecto... | string |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/binarySearch.ts#binarySearch#ret#3 | function binarySearch(array:any, elementOrCompare:any): number
element
elementOrCompare
start = 0
export function binarySearch<T>(array, elementOrCompare): <mask> {
if (typeof elementOrCompare !== 'function') {
return binarySearch(array, (element) => (element <= elementOrCompare));
}
const compare =... | number |
0b5vr_automaton/packages/automaton-with-gui/src/view/components/InspectorChannelItem.tsx#dispatch#var#20 | import { BoolParam } from './BoolParam';
import { ChannelWithGUI } from '../../ChannelWithGUI';
import { InspectorHeader } from './InspectorHeader';
import { InspectorHr } from './InspectorHr';
import { InspectorItem } from './InspectorItem';
import { NumberParam } from './NumberParam';
import { useDispatch, useSelecto... | Dispatch<Action> |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/binarySearch.ts#binarySearch#ret#2 | export function binarySearch<T>(array, compare): <mask>;
function binarySearch(array,element)
function binarySearch(array,compare)
function binarySearch(array,elementOrCompare): number
binarySearch(array, (element) => (element <= elementOrCompare))
protected __items: ChannelItem[] = [];
protected __items!: Array<Chann... | number |
0b5vr_automaton/packages/automaton-with-gui/src/view/components/InspectorChannelItem.tsx#InspectorChannelItemCurveParams#var#14 | import { BoolParam } from './BoolParam';
import { ChannelWithGUI } from '../../ChannelWithGUI';
import { InspectorHeader } from './InspectorHeader';
import { InspectorHr } from './InspectorHr';
import { InspectorItem } from './InspectorItem';
import { NumberParam } from './NumberParam';
import { useDispatch, useSelecto... | (props: {
channel: ChannelWithGUI;
channelName: string;
stateItem: StateChannelItem;
itemId: string;
}) => JSX.Element | null |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/arraySet.ts#value#arg#1 | export function arraySetDelete<T>(array, value: <mask>) {
const index = array.indexOf(value);
if (index === -1) {
return false;
}
array.splice(index, 1);
return true;
}
index = array.indexOf(value)
index === -1
array.splice(index, 1)
function arraySetDelete(array,value): boolean
out = [...fr... | T |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/binarySearch.ts#array#arg#3 | export function binarySearch<T>(array: <mask>, elementOrCompare) {
if (typeof elementOrCompare !== 'function') {
return binarySearch(array, (element) => (element <= elementOrCompare));
}
const compare = elementOrCompare as (element: T) => boolean;
let start = 0;
let end = array.length;
w... | ArrayLike<T> |
0b5vr_automaton/packages/automaton-with-gui/src/view/components/InspectorChannelItem.tsx#Root#var#115 | import { BoolParam } from './BoolParam';
import { ChannelWithGUI } from '../../ChannelWithGUI';
import { InspectorHeader } from './InspectorHeader';
import { InspectorHr } from './InspectorHr';
import { InspectorItem } from './InspectorItem';
import { NumberParam } from './NumberParam';
import { useDispatch, useSelecto... | StyledComponent<"div", any, {}, never> |
0b5vr_automaton/packages/automaton-with-gui/src/view/components/InspectorChannelItem.tsx#stateItem#var#26 | import { BoolParam } from './BoolParam';
import { ChannelWithGUI } from '../../ChannelWithGUI';
import { InspectorHeader } from './InspectorHeader';
import { InspectorHr } from './InspectorHr';
import { InspectorItem } from './InspectorItem';
import { NumberParam } from './NumberParam';
import { useDispatch, useSelecto... | StateChannelItem |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/arraySet.ts#b#arg#20 | export function arraySetUnion<T>(a, b: <mask>) {
const out = [...a];
b.forEach((v) => {
if (!arraySetHas(out, v)) {
out.push(v);
}
});
return out;
}
b.forEach((v) => {
if (!arraySetHas(out, v)) {
out.push(v);
}
})
b.forEach((v) => {
if ... | T[] |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/arraySet.ts#from#arg#29 | export function arraySetDiff<T>(from: <mask>, diff) {
const out = [...from];
diff.forEach((v) => {
arraySetDelete(out, v);
});
return out;
}
newState.selected.nodes = arraySetDiff(state.selected.nodes, action.nodes);
action
arraySetDiff(state.selected.nodes, action.nodes)
newState.selected.fxs ... | T[] |
0b5vr_automaton/packages/automaton-with-gui/src/view/components/GUIRemoconListener.tsx#dispatch#var#13 | import { GUIRemocon } from '../../GUIRemocon';
import { performRedo, performUndo } from '../history/HistoryCommand';
import { showToasty } from '../states/Toasty';
import { useDispatch, useSelector } from '../states/store';
import React, { useEffect } from 'react';
import styled from 'styled-components';
function expor... | Dispatch<Action> |
0b5vr_automaton/packages/automaton-with-gui/src/ThrottledJSONStorage.ts#valuesStr#var#8 | import { Throttle } from './utils/Throttle';
ChannelWithGUI.getItem(id:any): { $id: any; time: any; length: any; value: any; repeat: any; reset: any; offset: any; speed: any; amp: any; curveId: any; }
const valuesStr: <mask> = localStorage.getItem(key)
this.values = valuesStr != null ? JSON.parse(valuesStr) : {};
JSON.... | string | null |
0b5vr_automaton/packages/automaton-with-gui/src/ThrottledJSONStorage.ts#value#arg#15 | import { Throttle } from './utils/Throttle';
public set<TKey extends keyof T>(key, value: <mask>) {
set.values[key] = value;
set.__throttle.do(() => set.__write());
}
| T[TKey] |
0b5vr_automaton/packages/automaton-with-gui/src/ThrottledJSONStorage.ts#set#ret#15 | import { Throttle } from './utils/Throttle';
Throttle.do(func:any): Promise<T>
ThrottledJSONStorage.__write(): void
public set<TKey extends keyof T>(key, value): <mask> {
this.values[key] = value;
this.__throttle.do(() => this.__write());
}
| void |
0xProject_0x-starter-project/src/constants.ts#ONE_SECOND_MS#var#2 | import { BigNumber } from '@0x/utils';
const ONE_SECOND_MS: <mask> = 1000
ONE_MINUTE_MS = ONE_SECOND_MS * 60
| number |
0b5vr_automaton/packages/automaton-with-gui/src/view/components/InspectorChannelItem.tsx#channelName#var#127 | import { BoolParam } from './BoolParam';
import { ChannelWithGUI } from '../../ChannelWithGUI';
import { InspectorHeader } from './InspectorHeader';
import { InspectorHr } from './InspectorHr';
import { InspectorItem } from './InspectorItem';
import { NumberParam } from './NumberParam';
import { useDispatch, useSelecto... | string |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/arraySet.ts#arraySetDiff#ret#29 | function arraySetDelete(array:any, value:any): boolean
out = [...from]
export function arraySetDiff<T>(from, diff): <mask> {
const out = [...from];
diff.forEach((v) => {
arraySetDelete(out, v);
});
return out;
}
newState.selected.nodes = arraySetDiff(state.selected.nodes, action.nodes);
action
a... | T[] |
0xProject_0x-starter-project/src/constants.ts#DECIMALS#var#6 | import { BigNumber } from '@0x/utils';
const DECIMALS: <mask> = 18
| number |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/arraySet.ts#a#arg#20 | export function arraySetUnion<T>(a: <mask>, b) {
const out = [...a];
b.forEach((v) => {
if (!arraySetHas(out, v)) {
out.push(v);
}
});
return out;
}
newState.selected.nodes = arraySetUnion(state.selected.nodes, action.nodes);
action
arraySetUnion(state.selected.nodes, action.... | T[] |
0xProject_0x-starter-project/src/constants.ts#NULL_ADDRESS#var#7 | import { BigNumber } from '@0x/utils';
const NULL_ADDRESS: <mask> = '0x0000000000000000000000000000000000000000'
| string |
0xProject_0x-starter-project/src/constants.ts#ETH_ADDRESS#var#8 | import { BigNumber } from '@0x/utils';
const ETH_ADDRESS: <mask> = '0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee'
| string |
0b5vr_automaton/packages/automaton-with-gui/src/ThrottledJSONStorage.ts#value#var#20 | import { Throttle } from './utils/Throttle';
const value: <mask> = JSON.stringify(this.values)
localStorage.setItem(this.key, value)
JSON.stringify(this.values)
public readonly values: T;
| string |
0xProject_0x-starter-project/src/constants.ts#NULL_BYTES#var#9 | import { BigNumber } from '@0x/utils';
const NULL_BYTES: <mask> = '0x'
| string |
0xProject_0x-starter-project/src/constants.ts#GANACHE_NETWORK_ID#var#11 | import { BigNumber } from '@0x/utils';
const GANACHE_NETWORK_ID: <mask> = 50
| number |
0xProject_0x-starter-project/src/constants.ts#KOVAN_NETWORK_ID#var#12 | import { BigNumber } from '@0x/utils';
const KOVAN_NETWORK_ID: <mask> = 42
| number |
0b5vr_automaton/packages/automaton-with-gui/src/ThrottledJSONStorage.ts#get#ret#12 | import { Throttle } from './utils/Throttle';
public readonly values: T;
public get<TKey extends keyof T>(key): <mask> {
return this.values[key];
}
| T[TKey] | undefined |
0xProject_0x-starter-project/src/constants.ts#RINKEBY_NETWORK_ID#var#14 | import { BigNumber } from '@0x/utils';
const RINKEBY_NETWORK_ID: <mask> = 4
| number |
0xProject_0x-starter-project/src/constants.ts#ROPSTEN_NETWORK_ID#var#13 | import { BigNumber } from '@0x/utils';
const ROPSTEN_NETWORK_ID: <mask> = 3
| number |
0xProject_0x-starter-project/src/constants.ts#MOCK_0x_API_BASE_URL#var#15 | import { BigNumber } from '@0x/utils';
const MOCK_0x_API_BASE_URL: <mask> = 'https://mock.api.0x.org'
| string |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/arraySet.ts#diff#arg#29 | export function arraySetDiff<T>(from, diff: <mask>) {
const out = [...from];
diff.forEach((v) => {
arraySetDelete(out, v);
});
return out;
}
diff.forEach((v) => {
arraySetDelete(out, v);
})
diff.forEach((v) => {
arraySetDelete(out, v);
});
newState.selected.nodes = arrayS... | T[] |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/binarySearch.ts#element#arg#1 | export function binarySearch<T>(array, element: <mask>);
function binarySearch(array,element)
function binarySearch(array,compare)
function binarySearch(array,elementOrCompare): number
binarySearch(array, (element) => (element <= elementOrCompare))
protected __items: ChannelItem[] = [];
protected __items!: Array<Chann... | T |
0b5vr_automaton/packages/automaton-with-gui/src/view/components/InspectorChannelItem.tsx#InspectorChannelItem#var#124 | import { BoolParam } from './BoolParam';
import { ChannelWithGUI } from '../../ChannelWithGUI';
import { InspectorHeader } from './InspectorHeader';
import { InspectorHr } from './InspectorHr';
import { InspectorItem } from './InspectorItem';
import { NumberParam } from './NumberParam';
import { useDispatch, useSelecto... | (props: Props) => JSX.Element | null |
0b5vr_automaton/packages/automaton-with-gui/src/view/components/GUIRemoconListener.tsx#Root#var#7 | import { GUIRemocon } from '../../GUIRemocon';
import { performRedo, performUndo } from '../history/HistoryCommand';
import { showToasty } from '../states/Toasty';
import { useDispatch, useSelector } from '../states/store';
import React, { useEffect } from 'react';
import styled from 'styled-components';
const Root: <m... | StyledComponent<"div", any, {}, never> |
0b5vr_automaton/packages/automaton-with-gui/src/view/components/InspectorChannelItem.tsx#dispatch#var#128 | import { BoolParam } from './BoolParam';
import { ChannelWithGUI } from '../../ChannelWithGUI';
import { InspectorHeader } from './InspectorHeader';
import { InspectorHr } from './InspectorHr';
import { InspectorItem } from './InspectorItem';
import { NumberParam } from './NumberParam';
import { useDispatch, useSelecto... | Dispatch<Action> |
0b5vr_automaton/packages/automaton-with-gui/src/view/history/HistoryCommand.ts#commands#arg#483 | import { AutomatonWithGUI } from '../../AutomatonWithGUI';
import { BezierNode, FxSection, SerializedChannel, SerializedCurve } from '@0b5vr/automaton';
import { WithBypass } from '../../types/WithBypass';
import { WithID } from '../../types/WithID';
import type { StateChannelItem } from '../../types/StateChannelItem';... | HistoryCommand[] |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/arraySet.ts#arraySetDelete#ret#1 | export function arraySetDelete<T>(array, value): <mask> {
const index = array.indexOf(value);
if (index === -1) {
return false;
}
array.splice(index, 1);
return true;
}
function arraySetDelete(array,value): boolean
out = [...from]
arraySetDelete(out, v)
arraySetDelete(newState.channelNames, ... | boolean |
0b5vr_automaton/packages/automaton-with-gui/src/view/components/GUIRemoconListener.tsx#GUIRemoconListener#var#10 | import { GUIRemocon } from '../../GUIRemocon';
import { performRedo, performUndo } from '../history/HistoryCommand';
import { showToasty } from '../states/Toasty';
import { useDispatch, useSelector } from '../states/store';
import React, { useEffect } from 'react';
import styled from 'styled-components';
dispatch = use... | ({ guiRemocon }: {
guiRemocon: GUIRemocon;
}) => JSX.Element |
0b5vr_automaton/packages/automaton-with-gui/src/view/history/HistoryCommand.ts#commands#arg#488 | import { AutomatonWithGUI } from '../../AutomatonWithGUI';
import { BezierNode, FxSection, SerializedChannel, SerializedCurve } from '@0b5vr/automaton';
import { WithBypass } from '../../types/WithBypass';
import { WithID } from '../../types/WithID';
import type { StateChannelItem } from '../../types/StateChannelItem';... | HistoryCommand[] |
0b5vr_automaton/packages/automaton/src/ChannelItem.ts#repeat#var#26 | import { Automaton, Curve } from '.';
import type { SerializedChannelItem } from './types/SerializedChannelItem';
public length!: number;
const repeat: <mask> = (0.0 < this.repeat && this.repeat < this.length) ? this.repeat : Infinity
t = this.offset + (time % repeat) * this.speed
| number |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/arraySet.ts#arraySetUnion#ret#20 | function arraySetHas(array:any, value:any): boolean
out = [...a]
export function arraySetUnion<T>(a, b): <mask> {
const out = [...a];
b.forEach((v) => {
if (!arraySetHas(out, v)) {
out.push(v);
}
});
return out;
}
newState.selected.nodes = arraySetUnion(state.selected.nodes, ... | T[] |
0xProject_0x-starter-project/src/constants.ts#TEN_MINUTES_MS#var#4 | import { BigNumber } from '@0x/utils';
ONE_MINUTE_MS = ONE_SECOND_MS * 60
const TEN_MINUTES_MS: <mask> = ONE_MINUTE_MS * 10
| number |
0b5vr_automaton/packages/automaton/src/ChannelItem.ts#t#var#27 | import { Automaton, Curve } from '.';
import type { SerializedChannelItem } from './types/SerializedChannelItem';
public offset!: number;
const t: <mask> = this.offset + (time % repeat) * this.speed
repeat = (0.0 < this.repeat && this.repeat < this.length) ? this.repeat : Infinity
public speed!: number;
Channel.getValu... | number |
0b5vr_automaton/packages/automaton-with-gui/src/ThrottledJSONStorage.ts#__write#ret#19 | import { Throttle } from './utils/Throttle';
private __write(): <mask> {
const value = JSON.stringify(this.values);
localStorage.setItem(this.key, value);
}
this.__write()
| void |
0b5vr_automaton/packages/automaton/src/ChannelItem.ts#data#arg#34 | import { Automaton, Curve } from '.';
import type { SerializedChannelItem } from './types/SerializedChannelItem';
public deserialize(data: <mask>) {
deserialize.time = data.time ?? 0.0;
deserialize.length = data.length ?? 0.0;
deserialize.repeat = data.repeat ?? deserialize.length;
deser... | SerializedChannelItem |
0b5vr_automaton/packages/automaton/src/ChannelItem.ts#time#arg#21 | import { Automaton, Curve } from '.';
import type { SerializedChannelItem } from './types/SerializedChannelItem';
public getValue(time: <mask>) {
if (getValue.reset && getValue.length <= time) {
return 0.0;
}
if (getValue.curve) {
const repeat = (0.0 < getValue.repeat && ... | number |
0b5vr_automaton/packages/automaton-with-gui/src/compat/v3Compat.ts#channels#var#6 | import { defaultGUISettings } from '../types/GUISettings';
import type { SerializedAutomatonWithGUI } from '../types/SerializedAutomatonWithGUI';
import type { SerializedBezierNode, SerializedChannel, SerializedCurve } from '@0b5vr/automaton';
import type { V3SerializedAutomatonWithGUI } from './v3types/V3SerializedAut... | [
name: string,
channel: SerializedChannel
][] |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/useTimeValueRange.ts#range#arg#5 | import { Resolution } from './Resolution';
import { TimeValueRange } from './TimeValueRange';
import { useCallback } from 'react';
import { useSelector } from '../states/store';
export function useTimeValueRangeFuncs(range: <mask>, size) {
const { snapTimeActive, snapBeatActive, snapTimeInterval, bpm, beatOffset, s... | TimeValueRange |
0xProject_0x-starter-project/src/constants.ts#ZERO#var#10 | import { BigNumber } from '@0x/utils';
const ZERO: <mask> = new BigNumber(0)
| default |
0b5vr_automaton/packages/automaton-with-gui/src/view/utils/useTimeValueRange.ts#size#arg#5 | import { Resolution } from './Resolution';
import { TimeValueRange } from './TimeValueRange';
import { useCallback } from 'react';
import { useSelector } from '../states/store';
export function useTimeValueRangeFuncs(range, size: <mask>) {
const { snapTimeActive, snapBeatActive, snapTimeInterval, bpm, beatOffset, s... | Resolution |
0xProject_0x-starter-project/src/constants.ts#ONE_MINUTE_MS#var#3 | import { BigNumber } from '@0x/utils';
ONE_SECOND_MS = 1000
const ONE_MINUTE_MS: <mask> = ONE_SECOND_MS * 60
TEN_MINUTES_MS = ONE_MINUTE_MS * 10
| number |
0b5vr_automaton/packages/automaton-with-gui/src/view/history/HistoryCommand.ts#performUndo#ret#483 | import { AutomatonWithGUI } from '../../AutomatonWithGUI';
import { BezierNode, FxSection, SerializedChannel, SerializedCurve } from '@0b5vr/automaton';
import { WithBypass } from '../../types/WithBypass';
import { WithID } from '../../types/WithID';
import type { StateChannelItem } from '../../types/StateChannelItem';... | void |
0xProject_0x-starter-project/src/contracts.ts#dummyERC721TokenContracts#var#9 | import { DummyERC721TokenContract } from '@0x/contracts-erc721';
import { GANACHE_CONFIGS, NETWORK_CONFIGS } from './configs';
import { ROPSTEN_NETWORK_ID } from './constants';
import { providerEngine } from './provider_engine';
const dummyERC721TokenContracts: <mask> = []
dummyERC721TokenContracts.push(new DummyERC721... | DummyERC721TokenContract[] |
0b5vr_automaton/packages/automaton/src/tests/Channel.test.ts#data#var#4 | import { Automaton } from '../Automaton';
import { Channel } from '../Channel';
import type { SerializedAutomaton } from '../types/SerializedAutomaton';
const data: <mask> = {
resolution: 100.0,
curves: [
{ nodes: [[0.0, 0.0], [0.6, 1.0]] },
{ nodes: [[0.0, 2.0], [0.6, 2.0]] }
],
channel... | {
resolution: number;
curves: {
nodes: number[][];
}[];
channels: Channel[];
} |
0b5vr_automaton/packages/automaton/src/tests/Channel.test.ts#channel#var#57 | import { Automaton } from '../Automaton';
import { Channel } from '../Channel';
import type { SerializedAutomaton } from '../types/SerializedAutomaton';
automaton = new Automaton(data)
const channel: <mask> = new Channel(automaton, {
items: [{ curve: 0, time: 0.1, length: 2.0, repeat: 1.0 }],
... | Channel |
0b5vr_automaton/packages/automaton/src/tests/Channel.test.ts#automaton#var#13 | import { Automaton } from '../Automaton';
import { Channel } from '../Channel';
import type { SerializedAutomaton } from '../types/SerializedAutomaton';
data = {
resolution: 100.0,
curves: [
{ nodes: [[0.0, 0.0], [0.6, 1.0]] },
{ nodes: [[0.0, 2.0], [0.6, 2.0]] }
],
channels: []
}
let au... | Automaton |
0b5vr_automaton/packages/automaton/src/Channel.ts#ret#var#47 | import { Automaton } from './Automaton';
import { ChannelItem } from './ChannelItem';
import { binarySearch } from './utils/binarySearch';
import type { ChannelUpdateEvent } from './types/ChannelUpdateEvent';
import type { SerializedChannel } from './types/SerializedChannel';
const ret: <mask> = []
ret.push([begin + el... | [
number,
() => void
][] |
0xProject_0x-starter-project/src/constants.ts#UNLIMITED_ALLOWANCE_IN_BASE_UNITS#var#5 | import { BigNumber } from '@0x/utils';
const UNLIMITED_ALLOWANCE_IN_BASE_UNITS: <mask> = new BigNumber(2).pow(256).minus(1)
| default |
0b5vr_automaton/packages/automaton/src/Channel.ts#init#var#58 | import { Automaton } from './Automaton';
import { ChannelItem } from './ChannelItem';
import { binarySearch } from './utils/binarySearch';
import type { ChannelUpdateEvent } from './types/ChannelUpdateEvent';
import type { SerializedChannel } from './types/SerializedChannel';
let init: <mask>
init = true;
| true | undefined |
0b5vr_automaton/packages/automaton/src/tests/Channel.test.ts#channel#var#68 | import { Automaton } from '../Automaton';
import { Channel } from '../Channel';
import type { SerializedAutomaton } from '../types/SerializedAutomaton';
automaton = new Automaton(data)
const channel: <mask> = new Channel(automaton, {
items: [{ curve: 0, time: 0.1, length: 1.8, repeat: 1.0, offset: -0.3 ... | Channel |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.