repo_name
stringlengths
5
122
path
stringlengths
3
232
text
stringlengths
6
1.05M
khalifagroup/vscode-docker
src/utils/platform.ts
/*--------------------------------------------------------------------------------------------- * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. See LICENSE.md in the project root for license information. *----------------------------------------------------------------...
khalifagroup/vscode-docker
src/debugging/DebugHelper.ts
<gh_stars>0 /*--------------------------------------------------------------------------------------------- * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. See LICENSE.md in the project root for license information. *-------------------------------------------------...
khalifagroup/vscode-docker
test/telemetry/TelemetryPublisher.test.ts
<gh_stars>0 /*--------------------------------------------------------------------------------------------- * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. See License.md in the project root for license information. *-------------------------------------------------------...
khalifagroup/vscode-docker
src/configureWorkspace/configurePython.ts
/*--------------------------------------------------------------------------------------------- * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. See LICENSE.md in the project root for license information. *----------------------------------------------------------------...
khalifagroup/vscode-docker
extension.bundle.ts
<gh_stars>1-10 /*--------------------------------------------------------------------------------------------- * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. See LICENSE.md in the project root for license information. *-------------------------------------------------...
khalifagroup/vscode-docker
test/telemetry/surveys/activeUseSurvey.test.ts
/*--------------------------------------------------------------------------------------------- * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. See License.md in the project root for license information. *-------------------------------------------------------------------...
thisisviniciosilva/ignite
tests/main-test-02-hook/src/types.ts
<gh_stars>1-10 export interface Product { id: number; title: string; price: number; image: string; amount: number; } export interface Stock { id: number; amount: number; }
thisisviniciosilva/ignite
tests/main-test-02-hook/src/pages/Cart/styles.ts
import styled from 'styled-components'; import { darken, lighten } from 'polished'; export const Container = styled.div` padding: 30px; background: #fff; border-radius: 4px; footer { margin-top: 30px; display: flex; justify-content: space-between; align-items: center; button { backg...
kenko-apps/oncosafe
src/validators/questionTabac.ts
import { FormGroup } from '@angular/forms'; export class TabacValidator { static isValid(group: FormGroup): any { var userTabac = group.controls.tabac_check.value; var frequenceTabac = group.controls.frequence_tabac.value; var dateTabac = group.controls.date_tabac.value; ...
kenko-apps/oncosafe
src/validators/questionTherapie.ts
<gh_stars>0 import { FormGroup } from '@angular/forms'; export class TherapieValidator { static isValid(group: FormGroup): any { var therapies = group.controls.therapies_check.value; var phytotherapie = group.controls.phytotherapie.value; var extrait = group.controls.extrait.value; ...
kenko-apps/oncosafe
src/pages/formulaire-quatre/formulaire-quatre.ts
import { FormGroup, FormBuilder, Validators } from '@angular/forms'; import { Component } from '@angular/core'; import { MenuController, NavController } from 'ionic-angular'; import { TranslateService } from '@ngx-translate/core'; import { TherapieValidator } from '../../validators/questionTherapie' import { Formula...
kenko-apps/oncosafe
src/pages/formulaire-un/formulaire-un.ts
import { FormGroup, FormBuilder, Validators } from '@angular/forms'; import { Component } from '@angular/core'; import { MenuController, NavController } from 'ionic-angular'; import { TranslateService } from '@ngx-translate/core'; import { FormulairePageDeux } from '../formulaire-deux/formulaire-deux'; @Component({ ...
kenko-apps/oncosafe
src/pages/choix/choix.ts
import { WelcomePage } from './../welcome/welcome'; import { FirstRunPage } from './../pages'; import { Component } from '@angular/core'; import { NavController } from 'ionic-angular'; /** * The Welcome Page is a splash page that quickly describes the app, * and then directs the user to create an account or log in...
kenko-apps/oncosafe
src/pages/formulaire-trois/formulaire-trois.ts
<reponame>kenko-apps/oncosafe import { FormGroup, FormBuilder, Validators } from '@angular/forms'; import { Component } from '@angular/core'; import { MenuController, NavController } from 'ionic-angular'; import { TranslateService } from '@ngx-translate/core'; import { TabacValidator } from '../../validators/question...
kenko-apps/oncosafe
src/pages/formulaire-deux/formulaire-deux.ts
<gh_stars>0 import { FormGroup, FormBuilder, Validators } from '@angular/forms'; import { Component } from '@angular/core'; import { MenuController, NavController } from 'ionic-angular'; import { TranslateService } from '@ngx-translate/core'; import { FormulairePageTrois } from '../formulaire-trois/formulaire-trois';...
kenko-apps/oncosafe
src/pages/formulaire-resultat/formulaire-resultat.ts
<filename>src/pages/formulaire-resultat/formulaire-resultat.ts import { FormGroup, FormArray, FormBuilder, Validators } from '@angular/forms'; import { Component, OnInit } from '@angular/core'; import { MenuController, NavController } from 'ionic-angular'; import { TranslateService } from '@ngx-translate/core'; @Comp...
kenko-apps/oncosafe
src/pages/formulaire-cinq/formulaire-cinq.ts
<reponame>kenko-apps/oncosafe import { FormGroup, FormArray, FormBuilder, Validators } from '@angular/forms'; import { Component, OnInit } from '@angular/core'; import { MenuController, NavController } from 'ionic-angular'; import { TranslateService } from '@ngx-translate/core'; import { FormulaireResultat } from '.....
kenko-apps/oncosafe
src/app/app.component.ts
import { Component, ViewChild } from '@angular/core'; import { Platform, Nav, Config } from 'ionic-angular'; import { StatusBar } from '@ionic-native/status-bar'; import { SplashScreen } from '@ionic-native/splash-screen'; import { CardsPage } from '../pages/cards/cards'; import { ContentPage } from '../pages/content...
ElreyB/candyhunt
src/app/welcome/welcome.component.ts
<reponame>ElreyB/candyhunt import { Component, OnInit } from '@angular/core'; import { Router } from '@angular/router'; import { Location } from '@angular/common'; import { Player } from '../player.model'; import { Storyline } from '../storyline.model'; import { STORYLINE } from '../mock-storyline'; import { PlayerServ...
ElreyB/candyhunt
src/app/app.module.ts
<reponame>ElreyB/candyhunt import { BrowserModule } from '@angular/platform-browser'; import { NgModule } from '@angular/core'; import { FormsModule } from '@angular/forms'; import { HttpModule } from '@angular/http'; import { AppComponent } from './app.component'; import { WelcomeComponent } from './welcome/welcome.c...
ElreyB/candyhunt
src/app/storyline.service.ts
<reponame>ElreyB/candyhunt import { Injectable } from '@angular/core'; import { Storyline } from './storyline.model'; import { STORYLINE } from './mock-storyline'; @Injectable() export class StorylineService { constructor() { } getStoryline() { return STORYLINE; } getStorylineById(storylineId: number) {...
ElreyB/candyhunt
src/app/house/house.component.ts
<reponame>ElreyB/candyhunt import { Component, OnInit } from '@angular/core'; import { Router, ActivatedRoute, Params } from '@angular/router'; import { Location } from '@angular/common'; import { Player } from '../player.model'; import { Storyline } from '../storyline.model'; import { STORYLINE } from '../mock-storyli...
ElreyB/candyhunt
src/app/storyline.model.ts
export class Storyline { public choiceA = 'Ring the doorbell'; public choiceB = 'Prank the house'; constructor (public description: string, public candy: string[], public id: number) { } }
ElreyB/candyhunt
src/app/player.model.ts
export class Player { public candyCount = 5; public location = 0; constructor (public name: string, public costume: string, public prank: string, public candy: string) {} }
ElreyB/candyhunt
src/app/app.routing.ts
<filename>src/app/app.routing.ts import { ModuleWithProviders } from '@angular/core'; import { Routes, RouterModule } from '@angular/router'; import { WelcomeComponent } from './welcome/welcome.component'; import { GameOverComponent } from './game-over/game-over.component'; import { SuccessComponent } from './success/s...
ElreyB/candyhunt
src/app/player.service.ts
import { Injectable } from '@angular/core'; import { Player } from './player.model'; @Injectable() export class PlayerService { player: Player; constructor() { } setPlayer() { } getPlayer() { return this.player; } }
ElreyB/candyhunt
src/app/mock-characteristics.ts
export const COSTUMES: string[] = [ "ghost", "witch", "devil", "cowboy", "princess", "black cat", "pirate" ]; export const PRANKS: string[] = [ "egg house", "toilet paper house", "ding dong ditching", "silly string the car", "soap the windows" ]; export const CANDY: string[] = [ "candy corn", "caramel apple", "...
mastermind88/portainer
app/portainer/home/HomepageFilter.tsx
import { components, OptionProps } from 'react-select'; import { Select } from '@/portainer/components/form-components/ReactSelect'; import { Filter } from '@/portainer/home/types'; interface Props { filterOptions: Filter[]; onChange: (filterOptions: Filter[]) => void; placeHolder: string; value: Filter[]; } ...
mastermind88/portainer
app/portainer/settings/edge-compute/EdgeComputeSettings/EdgeComputeSettings.tsx
import { Formik, Form } from 'formik'; import { Switch } from '@/portainer/components/form-components/SwitchField/Switch'; import { FormControl } from '@/portainer/components/form-components/FormControl'; import { Select } from '@/portainer/components/form-components/Input/Select'; import { Widget, WidgetBody, WidgetT...
mastermind88/portainer
app/portainer/environments/environment.service/index.ts
import axios, { parseAxiosError } from '@/portainer/services/axios'; import { type EnvironmentGroupId } from '@/portainer/environment-groups/types'; import { type TagId } from '@/portainer/tags/types'; import { UserId } from '@/portainer/users/types'; import { TeamId } from '@/portainer/teams/types'; import type { E...
mastermind88/portainer
app/portainer/home/EnvironmentList/EnvironmentList.tsx
<filename>app/portainer/home/EnvironmentList/EnvironmentList.tsx import { ReactNode, useEffect, useState } from 'react'; import clsx from 'clsx'; import { PaginationControls } from '@/portainer/components/pagination-controls'; import { usePaginationLimitState } from '@/portainer/hooks/usePaginationLimitState'; import ...
rytsh/repeatit
_web/src/lib/helper/code.ts
const fullScreenKeys = { "F11": (cm: CodeMirror.Editor) => cm.setOption("fullScreen", !cm.getOption("fullScreen")), "Esc": (cm: CodeMirror.Editor) => cm.setOption("fullScreen", false), }; export { fullScreenKeys };
rytsh/repeatit
_web/src/lib/helper/run.ts
<reponame>rytsh/repeatit<filename>_web/src/lib/helper/run.ts import { codes, convertConfig } from "@/lib/store"; import { get } from "svelte/store"; import update from "immutability-helper"; const run = async () => { const values = get(codes); const config = get(convertConfig); const render = window["render"];...
rytsh/repeatit
_web/src/hooks.ts
import { minify } from "html-minifier"; import type { Options as minifyOptions } from "html-minifier"; import { prerendering } from "$app/env"; const repeatitVersion = import.meta.env.VITE_REPEATIT_VERSION; const minificationOptions: minifyOptions = { collapseBooleanAttributes: true, collapseWhitespace: true, co...
rytsh/repeatit
_web/src/lib/store/versions.ts
<gh_stars>1-10 const goVersion = import.meta.env.VITE_GO_VERSION; const sprigVersion = import.meta.env.VITE_SPRIG_VERSION; const repeatitVersion = import.meta.env.VITE_REPEATIT_VERSION; const versions = [ { name: "go", version: goVersion, link: "https://golang.org/doc/devel/release.html", }, { na...
rytsh/repeatit
_web/src/lib/helper/wasm.ts
import { loading } from "@/lib/store"; import "./wasm_exec.js"; const initWasm = (wasmFile = "./wasm/repeatit.wasm") => { if (!WebAssembly.instantiateStreaming) { // polyfill WebAssembly.instantiateStreaming = async (resp, importObject) => { const source = await (await resp).arrayBuffer(); return awa...
rytsh/repeatit
_web/src/lib/helper/drag.ts
<reponame>rytsh/repeatit const moveElement = (move:HTMLElement, Y: boolean, fn: (ch: number)=>void, down: ()=>void) => { let pos = 0; let posChange = 0; move.onmousedown = dragMouseDown; function dragMouseDown(e:MouseEvent) { e.preventDefault(); // get the mouse cursor position at startup: if (Y) ...
rytsh/repeatit
_web/src/examples/hello/index.ts
<gh_stars>1-10 import input from "./input?raw"; import template from "./template?raw"; const hello = { name: "hello", template: template, input: input, }; export { hello };
rytsh/repeatit
_web/src/lib/helper/init.ts
import "codemirror/mode/yaml/yaml"; import "codemirror/addon/edit/matchbrackets"; import "codemirror/addon/edit/trailingspace"; import "codemirror/addon/selection/active-line"; import "codemirror/addon/display/fullscreen"; import "codemirror/addon/display/placeholder"; import { initWasm } from "@/lib/helper/wasm"; in...
rytsh/repeatit
_web/src/lib/helper/copy.ts
const copyClip = (text: string) => { return navigator.clipboard.writeText(text); }; export { copyClip };
rytsh/repeatit
_web/src/examples/index.ts
<gh_stars>1-10 import { hello } from "./hello"; import { planet } from "./planet"; interface IExample { template: string; input: string; } const convert = (v: {template: string, input: string}) => { return { template: v.template, input: v.input, } as IExample; }; const examples = new Map<string, IExa...
rytsh/repeatit
_web/src/lib/store/index.ts
import { fullScreenKeys } from "@/lib/helper/code"; import { writable } from "svelte/store"; const initialEditorConfig: CodeMirror.EditorConfiguration = { mode: "yaml", lineNumbers: true, tabSize: 2, lineWrapping: true, styleActiveLine: true, matchBrackets: true, showTrailingSpace: true, extraKeys: ful...
rytsh/repeatit
_web/src/examples/planet/index.ts
<filename>_web/src/examples/planet/index.ts<gh_stars>1-10 import input from "./input?raw"; import template from "./template?raw"; const planet = { name: "planet", template: template, input: input, }; export { planet };
andriyor/xlwings
xlwings/js/xlwings.ts
async function main(workbook: ExcelScript.Workbook) { // String arguments are actual values or keys in xlwings.conf sheet await runPython( workbook, "URL", "API_KEY" ); } /** * xlwings dev (for Microsoft Office Scripts) * Copyright (C) 2014 - present, Zoomer Analytics GmbH. * All rights reserved. ...
sashkopavlenko/serverless-plugin-static
src/serve.ts
import * as http from 'http'; import * as url from 'url'; import * as path from 'path'; import { promises as fs } from 'fs'; import Serverless = require('serverless'); interface ContentTypeMap { readonly [key: string]: string; } const fileExtToContentTypeMap: ContentTypeMap = { '.ico': 'image/x-icon', '.html':...
sashkopavlenko/serverless-plugin-static
src/serve.spec.ts
/* eslint-disable max-classes-per-file */ import { Server } from 'https'; import * as request from 'supertest'; import { promises as fs } from 'fs'; import serve from './serve'; import Serverless = require('serverless'); class FileNotFound extends Error { code = 'ENOENT'; } class PermissionDenied extends Error { ...
sashkopavlenko/serverless-plugin-static
src/plugin.spec.ts
import StaticPlugin from './plugin'; import * as ServerModule from './serve'; import Serverless = require('serverless'); const serveMock = jest .spyOn(ServerModule, 'default') .mockImplementation(() => Promise.resolve()); describe('Plugin without options', () => { const serverless = { service: {}, }; co...
sashkopavlenko/serverless-plugin-static
src/index.ts
import StaticPlugin from './plugin'; module.exports = StaticPlugin;
sashkopavlenko/serverless-plugin-static
src/plugin.ts
import serve from './serve'; import Serverless = require('serverless'); import Plugin = require('serverless/classes/Plugin'); interface PluginOptions extends Serverless.Options { port?: string; p?: string; folder?: string; f?: string; } const defaults = { port: 8080, folder: './static', }; export default...
mskim5383/safe-dynamicTest-generator
src/util/Ansicolors.ts
/* * Copyright (c) 2014 Samsung Electronics Co., Ltd. * * 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 app...
mskim5383/safe-dynamicTest-generator
src/Metric.ts
<reponame>mskim5383/safe-dynamicTest-generator /* * Copyright (c) 2014 Samsung Electronics Co., Ltd. * * 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/li...
mskim5383/safe-dynamicTest-generator
src/Score.ts
import Builtin = require('./Builtin') import Ansi = require('./util/Ansicolors') export function testInput(testSet) { var fName = testSet.name var f = Builtin.getFunction(fName) var score if (f === undefined) { score = -1 } else { score = test(f, testSet.inputs) } Ansi.Red...
mskim5383/safe-dynamicTest-generator
src/util/Util.ts
/* * Copyright (c) 2014 Samsung Electronics Co., Ltd. * * 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 app...
mskim5383/safe-dynamicTest-generator
src/util/Random.ts
/* * Copyright (c) 2014 Samsung Electronics Co., Ltd. * * 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 app...
mskim5383/safe-dynamicTest-generator
src/Search.ts
<filename>src/Search.ts<gh_stars>0 /* * Copyright (c) 2014 Samsung Electronics Co., Ltd. * * 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/LICEN...
mskim5383/safe-dynamicTest-generator
src/run.ts
/* * Copyright (c) 2014 Samsung Electronics Co., Ltd. * * 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 appl...
mskim5383/safe-dynamicTest-generator
src/Compile.ts
/* * Copyright (c) 2014 Samsung Electronics Co., Ltd. * * 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 app...
mskim5383/safe-dynamicTest-generator
src/main.ts
<reponame>mskim5383/safe-dynamicTest-generator<gh_stars>10-100 /* * Copyright (c) 2014 Samsung Electronics Co., Ltd. * * 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://w...
mskim5383/safe-dynamicTest-generator
src/util/difflib.ts
<reponame>mskim5383/safe-dynamicTest-generator /*** This is part of jsdifflib v1.0. <http://snowtide.com/jsdifflib> Copyright (c) 2007, Snowtide Informatics Systems, Inc. All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the followin...
mskim5383/safe-dynamicTest-generator
src/Data.ts
/* * Copyright (c) 2014 Samsung Electronics Co., Ltd. * * 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 app...
mskim5383/safe-dynamicTest-generator
src/LinkedList.ts
/* * Copyright (c) 2014 Samsung Electronics Co., Ltd. * * 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 app...
mskim5383/safe-dynamicTest-generator
src/TestGen.ts
// generate a JSON for dynamic tests // TODO extend it for functions. // TODO extend it for non-pure function. // TODO handling exception case. export function jsonGen(func, thisVal, args, name="") { // type checks if (typeof func !== "function") err("'func' should have a function type."); if (!Array.isArra...
mskim5383/safe-dynamicTest-generator
src/ProgramGen.ts
<filename>src/ProgramGen.ts /* * Copyright (c) 2014 Samsung Electronics Co., Ltd. * * 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 ...
mskim5383/safe-dynamicTest-generator
ts-decl/harmony-reflect.d.ts
<reponame>mskim5383/safe-dynamicTest-generator declare module "harmony-reflect" { //var Proxy: (target: any, handler: any) => any; interface Harmony { get: any; } export = Harmony; }
mskim5383/safe-dynamicTest-generator
src/StructureInference.ts
/* * Copyright (c) 2014 Samsung Electronics Co., Ltd. * * 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 app...
mskim5383/safe-dynamicTest-generator
src/Builtin.ts
export function getFunction(fName) { return map[fName] } var map = {} export function ToObject(v) { if (v === null || v === undefined) throw TypeError return Object(v) } export function DefineOwnProperty(O, P, Desc, Throw) { try { return Object.defineProperty(O, P, Desc) } catch (e) { ...
mskim5383/safe-dynamicTest-generator
src/Recorder.ts
<gh_stars>10-100 /* * Copyright (c) 2014 Samsung Electronics Co., Ltd. * * 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 * * Unles...
MaxKlaxxMiner/factorio_belt_simulator
FactorioTransportBeltSimulator/ts/sprites.ts
/* tslint:disable:one-line max-line-length interface-name comment-format no-bitwise */ class Sprites { tutorialGrid: HTMLImageElement; transportBelt: HTMLImageElement; splitterNorth: HTMLImageElement; splitterSouth: HTMLImageElement; splitterWestTop: HTMLImageElement; splitterWest: HTMLImageEleme...
MaxKlaxxMiner/factorio_belt_simulator
FactorioTransportBeltSimulator/ts/display.ts
<reponame>MaxKlaxxMiner/factorio_belt_simulator /* tslint:disable:one-line max-line-length interface-name comment-format no-bitwise */ class Display { gameDiv: HTMLElement; canvasElement: HTMLCanvasElement; canvasContext: CanvasRenderingContext2D; title = document.title; sprites: Sprites; map: Ma...
MaxKlaxxMiner/factorio_belt_simulator
FactorioTransportBeltSimulator/ts/displayEntities.ts
/* tslint:disable:one-line max-line-length interface-name comment-format no-bitwise */ enum BeltType { leftToRight = 0, rightToLeft = 1, bottomToTop = 2, topToBottom = 3, rightToTop = 4, topToRight = 5, leftToTop = 6, topToLeft = 7, bottomToRight = 8, rightToBottom = 9, bottomToLef...
MaxKlaxxMiner/factorio_belt_simulator
FactorioTransportBeltSimulator/ts/tools.ts
<filename>FactorioTransportBeltSimulator/ts/tools.ts /* tslint:disable:one-line max-line-length interface-name comment-format no-bitwise */ const requestAnimFrame = (() => (window.requestAnimationFrame || (<any>window).webkitRequestAnimationFrame || (<any>window).mozRequestAnimationFrame || ((cb: TimerHandler) => w...
MaxKlaxxMiner/factorio_belt_simulator
FactorioTransportBeltSimulator/ts/map.ts
<gh_stars>0 /* tslint:disable:one-line max-line-length interface-name comment-format no-bitwise */ enum EntityType { transportBelt = 0, splitter = 1, _splitterLeft = 2, _splitterRight = 3 } enum Direction { top = 0, right = 1, bottom = 2, left = 3 } class MapEntity { /** X-Posi...
MaxKlaxxMiner/factorio_belt_simulator
FactorioTransportBeltSimulator/ts/game.ts
<filename>FactorioTransportBeltSimulator/ts/game.ts /* tslint:disable:one-line max-line-length interface-name comment-format no-bitwise */ // --- globals --- const keys: { [key: number]: boolean } = {}; let mouseX = 0; let mouseY = 0; let mouseButtons = 0; let mouseWheel = 0; let game: Game; class Game { ...
MaxKlaxxMiner/factorio_belt_simulator
FactorioTransportBeltSimulator/ts/blueprint.ts
/* tslint:disable:one-line max-line-length interface-name comment-format no-bitwise */ interface BluePrintIcon { signal: { type: string, name: string }, index: number; } interface BluePrintEntity { entity_number: number, name: string, position: { x: number, y: number }, /** values: undefined...
ksurendra/jaqstack
core/ui.resources/src/app/hello/hello.component.ts
import { Component, OnInit } from '@angular/core'; import {HelloService} from "./hello.service"; @Component({ selector: 'app-hello', templateUrl: './hello.component.html', styleUrls: ['./hello.component.css'], providers: [HelloService] }) export class HelloComponent implements OnInit { helloFromJava : any; ...
ksurendra/jaqstack
examples/azureblobviewer/ui.resources/src/app/azureblobviewer/azureblobviewer.component.ts
<reponame>ksurendra/jaqstack import { Component, ElementRef, ViewChild, OnInit } from '@angular/core'; import {AzureblobService} from "../services/azureblob.service"; import { DomSanitizer, SafeUrl } from "@angular/platform-browser"; @Component({ selector: 'app-azureblobviewer', templateUrl: './azureblobviewer.com...
ksurendra/jaqstack
examples/azureblobviewer/ui.resources/src/app/services/azureblob.service.ts
import { Injectable } from '@angular/core'; import {HttpClient, HttpHeaders} from '@angular/common/http'; import { Azureblob } from '../models/azureblob'; import {environment} from "../../environments/environment"; import {Observable} from 'rxjs/Observable'; @Injectable() export class AzureblobService { constructo...
ksurendra/jaqstack
examples/azureblobviewer/ui.resources/src/environments/environment.prod.ts
export const environment = { production: true, BACKEND_URL : window.location.protocol + '//' + window.location.hostname + ':' + window.location.port + "/jaqstack-azure-blobviewer" };
ksurendra/jaqstack
core/ui.resources/src/app/hello/hello.service.ts
import { Injectable } from '@angular/core'; import { HttpClient } from '@angular/common/http'; import 'rxjs/add/operator/map'; import { Observable } from 'rxjs/Observable'; import 'rxjs/add/operator/catch'; import 'rxjs/add/operator/map'; import {environment} from '../../environments/environment'; @Injectable() expo...
ksurendra/jaqstack
core/ui.resources/src/app/app.module.ts
import { NgModule } from '@angular/core'; import { BrowserModule } from '@angular/platform-browser'; import { AppComponent } from './app.component'; import { HttpClientModule } from '@angular/common/http'; import { RouterModule } from '@angular/router'; import { HelloComponent } from './hello/hello.component'; ...
ksurendra/jaqstack
examples/azureblobviewer/ui.resources/src/app/app.component.ts
import { Component, OnInit } from '@angular/core'; import { HttpClient } from '@angular/common/http'; @Component({ selector: 'app-root', templateUrl: './app.component.html' //template: `<h1>Hello Test Angular - {{name}}</h1>` }) /*export class AppComponent implements OnInit { name = 'This Message is from Test ...
ksurendra/jaqstack
examples/azureblobviewer/ui.resources/src/app/models/azureblob.ts
export class Azureblob { blobName: string; blobURL: string; blboMimeType: string; }
ksurendra/jaqstack
examples/azureblobviewer/ui.resources/src/app/models/azurethumbnail.ts
<reponame>ksurendra/jaqstack<filename>examples/azureblobviewer/ui.resources/src/app/models/azurethumbnail.ts export class Azurethumbnail { thumbnailurl: Blob; }
ksurendra/jaqstack
examples/azureblobviewer/ui.resources/src/app/app.module.ts
<filename>examples/azureblobviewer/ui.resources/src/app/app.module.ts<gh_stars>0 import { NgModule } from '@angular/core'; import { BrowserModule } from '@angular/platform-browser'; import { AppComponent } from './app.component'; import { HttpClientModule } from '@angular/common/http'; import { RouterModule } f...
sudhakarbhra/bm
src/app/shared/services/vendors.service.ts
<filename>src/app/shared/services/vendors.service.ts import { Injectable } from '@angular/core'; import { HelperService } from './helper.service'; @Injectable({ providedIn: 'root' }) export class VendorsService { constructor(private hs: HelperService) {} findAllVendors(){ return this.hs.get('/bm/v1/admin...
sudhakarbhra/bm
src/app/shared/services/auth.service.ts
<filename>src/app/shared/services/auth.service.ts<gh_stars>0 import { Injectable } from '@angular/core'; import { HelperService } from './helper.service'; @Injectable({ providedIn: 'root' }) export class AuthService { constructor(private hs: HelperService) { } authenticateUser(payload){ return this.hs.pos...
sudhakarbhra/bm
src/app/shared/models/helper.ts
<filename>src/app/shared/models/helper.ts export interface Helper { name: String }
sudhakarbhra/bm
src/app/layout/layout.module.ts
import { CommonModule } from '@angular/common'; import { NgModule } from '@angular/core'; import { MatButtonModule, MatIconModule, MatInputModule, MatListModule, MatMenuModule, MatSidenavModule, MatToolbarModule } from '@angular/material'; import { MatTableModule } from '@angular/material/ta...
sudhakarbhra/bm
src/app/shared/services/products.service.ts
import { Injectable } from '@angular/core'; import { HelperService } from './helper.service'; @Injectable({ providedIn: 'root' }) export class ProductsService { constructor(private hs: HelperService) { } productUpload(payload){ return this.hs.post('/bm/v1/product/upload', payload); } }
sudhakarbhra/bm
src/app/shared/services/users.service.ts
import { Injectable } from '@angular/core'; import { HelperService } from './helper.service'; @Injectable({ providedIn: 'root' }) export class UsersService { constructor(private hs: HelperService) { } findAllRoles(){ return this.hs.get('/bm/v1/role/findall'); } findAllCustomers(){ return this.hs.get('/bm/v...
sudhakarbhra/bm
src/app/shared/services/helper.service.ts
<reponame>sudhakarbhra/bm import { Injectable } from '@angular/core'; import { HttpClient } from '@angular/common/http'; import { Observable } from 'rxjs'; @Injectable({ providedIn: 'root' }) export class HelperService { BASE_URI = "http://172.16.31.10:8089/"; constructor(private http: HttpClient) { } get(endp...
sudhakarbhra/bm
src/app/shared/services/index.ts
import { Injectable } from '@angular/core'; import {HttpClient} from '@angular/common/http'; @Injectable({providedIn: 'root'}) export class HelperService { url = "http://dummy.restapiexample.com/api/v1"; constructor(private http: HttpClient) { } getEmployee() { return this.http.get(this.url+'/emp...
sudhakarbhra/bm
src/app/shared/services/role.service.ts
<reponame>sudhakarbhra/bm import { Injectable } from '@angular/core'; import { HelperService } from './helper.service'; @Injectable({ providedIn: 'root' }) export class RoleService { constructor() { } }
sudhakarbhra/bm
src/app/layout/products/products.component.ts
<gh_stars>0 import { Component, OnInit } from '@angular/core'; import { HttpClient } from '@angular/common/http'; import { Observable } from 'rxjs'; import { HelperService } from '../../shared/services/helper.service'; import { Helper } from '../../shared/models/helper'; import { MatTableDataSource } from '@angular/mat...
adinvadim/vuex-orm-next
test/feature/relations/has_many_save.spec.ts
<reponame>adinvadim/vuex-orm-next import { createStore, fillState, assertState } from 'test/Helpers' import { Model, Num, Str, HasMany } from '@/index' describe('feature/relations/has_many_save', () => { class User extends Model { static entity = 'users' @Num(0) id!: number @Str('') name!: string @...
adinvadim/vuex-orm-next
test/feature/relations/has_many_insert_uid.spec.ts
<gh_stars>0 import { createStore, assertState, mockUid } from 'test/Helpers' import { Model, Attr, Uid, Str, HasMany } from '@/index' describe('feature/relations/has_many_insert_uid', () => { beforeEach(() => { Model.clearRegistries() }) it('inserts "has many" relation with parent having "uid" field as the ...
adinvadim/vuex-orm-next
src/connection/Connection.ts
<reponame>adinvadim/vuex-orm-next import { Store } from 'vuex' import { Element, Elements } from '../data/Data' import { Database } from '../database/Database' import { Model } from '../model/Model' export interface ConnectionNamespace { connection: string entity: string } export class Connection<M extends Model>...
adinvadim/vuex-orm-next
test/feature/relations/belongs_to_retrieve.spec.ts
import { createStore, fillState, assertModel } from 'test/Helpers' import { Model, Attr, Str, BelongsTo } from '@/index' describe('feature/relations/belongs_to_retrieve', () => { class User extends Model { static entity = 'users' @Attr() id!: number @Str('') name!: string } class Post extends Model...
adinvadim/vuex-orm-next
src/schema/Schema.ts
import { schema as Normalizr, Schema as NormalizrSchema } from 'normalizr' import { isNullish, isArray } from '../support/Utils' import { Uid } from '../model/attributes/types/Uid' import { Relation } from '../model/attributes/relations/Relation' import { Model } from '../model/Model' export class Schema { /** * ...
adinvadim/vuex-orm-next
test/feature/relations/has_many_by_insert_custom_key.spec.ts
import { createStore, assertState } from 'test/Helpers' import { Model, Attr, Str, HasManyBy } from '@/index' describe('feature/relations/has_many_by_insert_custom_key', () => { beforeEach(() => { Model.clearRegistries() }) it('inserts "has many by" relation with custom primary key', async () => { class...