text stringlengths 10 953k |
|---|
class Feature {
id: string;
name:string;
code:string;
limit: number;
} |
import { Component, OnInit, Inject } from '@angular/core';
import { MatDialogRef, MAT_DIALOG_DATA, MatSnackBar } from '@angular/material';
import { FormGroup, FormBuilder, Validators } from '@angular/forms';
import { Employee } from '../../shared/employee';
import { EmployeeService } from '../../shared/employee.service... |
import {Frustum, Matrix4, Vector3} from 'three';
import {MapNode} from '../nodes/MapNode';
import {MapHeightNode} from '../nodes/MapHeightNode';
import {MapView} from '../MapView';
import {LODControl} from './LODControl';
const projection = new Matrix4();
const pov = new Vector3();
const frustum = new Frustum();
cons... |
/*
* Copyright 2020 The Backstage Authors
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or ... |
import { browser, logging } from 'protractor';
import { AppPage } from './app.po';
describe('workspace-project App', () => {
let page: AppPage;
beforeEach(() => {
page = new AppPage();
});
it('should display welcome message', async () => {
await page.navigateTo();
expect(await page.getTitleText()... |
import * as _ from 'lodash';
import { createColumnNumber, createLineNumber, LineNumber } from '../core-v2/chrome/internal/locations/subtypes';
import { utils } from 'vscode-chrome-debug-core';
import { Position } from '../core-v2/chrome/internal/locations/location';
export async function findPositionOfTextInFile(fileP... |
export * from './TeamRoute';
export * from './ClientsRoute';
export * from './ProjectsRoute'; |
import path = require('path');
import fs = require('fs');
const { appNative } = require('../bindings');
let appPath = path.join(process.resourcesPath, 'app');
const envEntry = process.env['DESKGAP_ENTRY'];
if (envEntry != null && fs.existsSync(path.join(appPath, 'DESKGAP_DEFAULT_APP'))) {
appPath = envEntry;
}
exp... |
import { Injectable, NestMiddleware, UnauthorizedException } from '@nestjs/common';
import { OpenIdClient } from '../auth/open-id-client';
/**
* Simple middleware function that will fetch the user's claims from the IdP.
* Only works if you have a "user" property in req.
*/
@Injectable()
export class ClaimsMiddlewa... |
import { default as BigNumber } from 'bignumber.js';
export class AmountFormatter {
format(
amount: BigNumber,
precision: number,
thousandSeparator: string,
decimalSeparator: string,
roundingMode?: BigNumber.RoundingMode
) {
return amount.toFormat(
precision,
roundingMode === un... |
import * as core from "@actions/core";
import * as io from "@actions/io";
import * as exec from "@actions/exec";
import * as process from "process";
import * as cache from "@actions/cache";
// based on https://cristianadam.eu/20200113/speeding-up-c-plus-plus-github-actions-using-ccache/
async function install() {
i... |
import { isReactive, isReadonly, readonly, shallowReadonly } from '../reactive'
import { mockWarn } from 'jest-mock-warn'
describe('reactivity/shallowReadonly', () => {
mockWarn()
test('should not make non-reactive properties reactive', () => {
const props = shallowReadonly({ n: { foo: 1 } })
expect(isReac... |
import { BadgeNameInitialsModule } from './lib/badge-name-initials.module';
export { BadgeNameInitialsModule } from './lib/badge-name-initials.module';
export { BadgeNameInitialsComponent } from './lib/badge-name-initials.component'; |
/**
* @license
* Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
* This code may only be used under the BSD style license found at
* http://polymer.github.io/LICENSE.txt
* The complete set of authors may be found at
* http://polymer.github.io/AUTHORS.txt
* The complete set of contributors ma... |
import {
Checkbox,
CheckboxOptions,
checkboxTemplate as template,
} from "@microsoft/fast-foundation";
import { checkboxStyles as styles } from "./checkbox.styles";
/**
* A function that returns a {@link @microsoft/fast-foundation#Checkbox} registration for configuring the component with a DesignSystem.
... |
import * as types from "./types";
import * as common from "./common";
import child_process = require('child_process');
import crypto = require('crypto');
import path = require('path');
import fs = require('fs');
import os = require('os');
import tty = require('tty');
declare const ESBUILD_VERSION: string;
// This fi... |
import { INIT_CODE_HASH } from '../src/constants'
// this _could_ go in constants, except that it would cost every consumer of the sdk the CPU to compute the hash
// and load the JSON
const COMPUTED_INIT_CODE_HASH = '0xbc919ae6f6f95dca1e223fc957286afa1da81529418e9f187db8a0b2d2e963bc'
describe('constants', () => {
d... |
/********************************************************************************
* Copyright (C) 2018 Ericsson and others.
*
* 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:... |
import { Component, EventEmitter, Input, Output } from '@angular/core';
import { AbstractEmptyDirective } from '../../../object';
import { EmptyComponent } from '../../../object/helper';
import { provideParent } from '../../../util';
@Component({
selector: 'atft-layer-actor',
providers: [provideParent(LayerActorC... |
const models = require('../../../../db/mysqldb/index')
import moment from 'moment'
const { resClientJson } = require('../../utils/resData')
const Op = require('sequelize').Op
const sequelize = require('sequelize')
const cheerio = require('cheerio')
const clientWhere = require('../../utils/clientWhere')
const xss = requ... |
import react, { useState, useEffect } from 'react';
import {
Box,
Typography,
TextField
} from '@material-ui/core';
import { useSMART } from '../../../../subscribers/SMART'
import { useWeightsState } from '../../../../subscribers/weights'
interface Criteria {
id: number
name: string
}
interface P... |
import { BadRequestException, Injectable, InternalServerErrorException, NotAcceptableException, NotFoundException } from '@nestjs/common';
import { InjectModel,InjectConnection } from '@nestjs/mongoose';
import {connection, Connection, Model} from "mongoose";
import {getTicketBody, ticketBody,ticketInterface, updateTic... |
export = VisualizationFactory;
declare function VisualizationFactory(): void;
declare namespace VisualizationFactory {
export { register, create, getVisualizationPath, Visualization };
}
declare function register(typeName: string, constructor: (arg0: any) => any): void;
declare function create(typeOrKey: string | n... |
import {caseOp, orThrow} from 'op/Op'
import {Funs} from '../ast/Fun'
import {Break, For, ForAsync, ForBag, Iteratee} from '../ast/Loop'
import {check, fail} from '../context'
import {assert} from '../util'
import {funKind, isInSwitch, opLoop, results, withFun, withLoop} from './context'
import SK from './SK'
import {v... |
/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
*---------------------------------------------------------------... |
import { DateTime } from 'luxon'
import { BaseModel, column, beforeCreate, BelongsTo, belongsTo } from '@ioc:Adonis/Lucid/Orm'
import UUIDHook from 'App/Models/Hooks/UUIDHook'
import Customer from 'App/Models/Customer'
import Country from 'App/Models/Country'
import State from 'App/Models/State'
export default class C... |
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import { Routes, RouterModule } from '@angular/router';
import { IonicModule } from '@ionic/angular';
import { ThemingPage } from './theming.page';
const routes: Routes = [
{
... |
/**
* @description list api
* @author 阿怪
* @date 2022/4/24 21:57
* @version v1.0.0
*
* 江湖的业务千篇一律,复杂的代码好几百行。
*/
import { WCOPO } from "../../dependents/_types";
import { ListProps } from "./index";
export const props: WCOPO<ListProps> = {
data: { type: Array, default: () => [] },
autoActive: { type: Boolean,... |
import { ComponentStory, ComponentMeta } from '@storybook/react'
import Pagination from './Pagination'
export default {
title: 'Elements/ Pagination',
component: Pagination,
argTypes: {
backgroundColor: { control: 'color' },
},
} as ComponentMeta<typeof Pagination>
const Template: ComponentStory<typeof P... |
/**
* DevExtreme (events/pointer.d.ts)
* Version: 19.2.4
* Build date: Tue Nov 19 2019
*
* Copyright (c) 2012 - 2019 Developer Express Inc. ALL RIGHTS RESERVED
* Read about DevExtreme licensing here: https://js.devexpress.com/Licensing/
*/
import DevExpress from '../bundles/dx.all'; |
import MessageInterface from "../message";
import Value from "@dikac/t-value/value";
import MessageParameters from "./message-parameters";
/**
* return {@param value} is compatible with {@link MessageInterface}
*
* @param value
*
* @param error
* throw {@link Error} from {@param error} if {@param value} is not c... |
import { useColorMode } from '@chakra-ui/color-mode'
import { Box, Flex } from '@chakra-ui/layout'
import { Select } from '@chakra-ui/select'
import Image from 'next/image'
import React from 'react'
import { ProtocolDropDownTypes } from './types'
const ProtocolDropDown: React.FC<ProtocolDropDownTypes> = ({
onProtoco... |
import { OnChange } from '@jdfed/utils'
const changeUse12Hours: OnChange = ({ dispatch, val, getKey }) => {
dispatch({
type: 'setUi',
action: {
set: {
[getKey('ui.default', 'uiSchema') + '.use12Hours']: val,
[getKey('ui.default', 'uiSchema') + '.format']: val
? 'h:mm:ss a'
... |
import { Injectable } from '@angular/core';
import { HttpRequest, HttpHandler, HttpEvent, HttpInterceptor } from '@angular/common/http';
import { Observable, throwError } from 'rxjs';
import { catchError } from 'rxjs/operators';
import { AuthenticationService } from '@/_services';
@Injectable()
export class ErrorInte... |
/**
* @license
* Copyright Google Inc. All Rights Reserved.
*
* Use of this source code is governed by an MIT-style license that can be
* found in the LICENSE file at https://angular.io/license
*/
import {Injectable, InjectionToken, Injector, NgModule, createInjector, forwardRef} from '@angular/core';
import {AO... |
import * as BABYLON from 'babylonjs';
import * as Pusher from 'pusher-js';
import * as React from 'react';
import './App.css';
import { AppState } from './AppState';
import IContext from './IContext';
import IState from './IState';
import IStateManager from './IStateManager';
import LoginState from './LoginState';
impo... |
// THIS FILE IS AUTO GENERATED
import { IconTree, IconType } from '../lib'
export declare const RiFocus3Fill: IconType; |
// Prints to browser console
console.log("Hello world") |
import { Component, Prop, Element } from '@stencil/core';
@Component({
tag: 'my-progress-bar',
styleUrl: 'my-progress-bar.scss',
shadow: true
})
export class MyProgressBar {
@Prop() value: number;
@Prop() max: number = 100;
@Prop() showValue: boolean = false;
@Element() el: HTMLElement;
render() {
... |
import React from 'react'
import Top from '.'
export default {
title: 'Top',
component: Top,
}
const Template = () => <Top />
export const Default = Template.bind({}) |
import { reactive } from "Vucript";
import axios from "axios";
let yesno: reactive<string> = "thinking";
const onMounted = async () => {
try {
const response = await axios.get("https://yesno.wtf/api");
yesno = response.data["answer"];
} catch (error) {
console.error(error);
}
}; |
import { createStyles, Divider, Drawer, IconButton, List, ListItem, ListItemIcon, ListItemText, Link, makeStyles, Theme, useTheme } from '@material-ui/core'
import MailIcon from '@material-ui/icons/Mail';
import InboxIcon from '@material-ui/icons/Inbox';
import React from 'react'
import ChevronLeftIcon from'@material-u... |
/**
* @license
* Copyright 2018 Google LLC
*
* 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
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or a... |
import React from 'react';
import { MenuButton, useEMirrorContext } from '@emirror/react';
import { isMarkActive } from '@emirror/core-helpers';
import icon from './assets/icon.svg';
const UnderlineBtn = () => {
const emirror = useEMirrorContext();
return (
<MenuButton
activated={isMarkActive(
e... |
import * as React from 'react';
interface ExpansionContextType {
historyExpanded?: any;
toggleEditVisibility?: any;
}
const context: ExpansionContextType = {
historyExpanded: {},
toggleEditVisibility: () => {},
};
const ExpansionContext = React.createContext(context);
export default ExpansionContext; |
import styled from '@emotion/styled'
import Title from './Title'
import Nav from './Nav'
const Header = styled('header')`
padding: 12px 0;
background: ${(props) => props.theme.palette.primary.main};
`
type HeaderProps = typeof Header & {
Title: typeof Title
Nav: typeof Nav
}
const HeaderBlock = Header as He... |
export { Version } from './Version';
export { Time } from './Time';
export { FileBinary } from './FileBinary';
export { Law } from './Law';
export { Earth } from './Earth';
export * from './DevsIcons'; |
import * as AceBuilds from "ace-builds";
type EditorOption =
| "minLines"
| "maxLines"
| "readOnly"
| "highlightActiveLine"
| "tabSize"
| "enableBasicAutocompletion"
| "enableLiveAutocompletion"
| "enableSnippets";
const editorOptions: EditorOption[] = [
"minLines",
"maxLines",
"readOnly",
"hi... |
//# sourceMappingURL=es-SV.d.ts.map |
import { AppEvents, ExploreQueryFieldProps, TraceData, TraceSpan } from '@grafana/data';
import { selectors } from '@grafana/e2e-selectors';
import { ButtonCascader, CascaderOption } from '@grafana/ui';
import React from 'react';
import { appEvents } from '../../../core/core';
import { JaegerDatasource, JaegerQuery } f... |
// #docregion
import { Component, OnInit } from '@bangular/core';
import { ActivatedRoute } from '@bangular/router';
import { Observable } from 'rxjs/Observable';
import 'rxjs/add/operator/map';
@Component({
template: `
<p>Dashboard</p>
<p>Session ID: {{ sessionId | async }}</p>
<a id="anc... |
import React from 'react';
import { DimError } from 'app/bungie-api/bungie-service-helper';
import { AppIcon, twitterIcon, refreshIcon } from '../shell/icons';
import ExternalLink from 'app/dim-ui/ExternalLink';
import { t } from 'app/i18next-t';
import styles from './ErrorPanel.m.scss';
const bungieHelpLink = 'http:/... |
import {Notebook} from '../../../../../models/';
import {createNotebookFromDiscriminatorValue} from '../../../../../models/createNotebookFromDiscriminatorValue';
import {ODataError} from '../../../../../models/oDataErrors/';
import {createODataErrorFromDiscriminatorValue} from '../../../../../models/oDataErrors/createO... |
import {
IHookFunctions,
IWebhookFunctions,
} from 'n8n-core';
import {
IDataObject,
ILoadOptionsFunctions,
INodePropertyOptions,
INodeType,
INodeTypeDescription,
IWebhookResponseData,
} from 'n8n-workflow';
import {
keapApiRequest,
} from './GenericFunctions';
import {
capitalCase,
} from 'change-case';
... |
import React from 'react';
import { Link } from 'react-router-dom';
import './SearchItem.scss';
const SearchItem = (props: any) => {
return(
<Link to={'/details/' + props.item.imdbID}>
<div className="item">
<div className="image">
<img src={props.item.Poster}... |
/* eslint-disable no-console */
import React, { Component, ReactElement } from 'react';
import {
Row, Col, Form, Input, Button, Card, DatePicker, Icon,
} from 'antd';
import { WrappedFormUtils } from 'antd/lib/form/Form';
const { MonthPicker } = DatePicker;
type Props = {
onSubmit: (any) => void;
form: WrappedF... |
import { ButtonTagPlain } from "@/components/atoms/buttons/ButtonTag";
import type { TTag } from "@/types";
type Props = {
tags: TTag[];
hasLink?: boolean;
};
export const TagListPlain: React.VFC<Props> = ({ tags, hasLink = false }) => {
return (
<ul className="flex flex-wrap gap-x-2 gap-y-1">
{(tags ... |
import { Meta } from '@storybook/react';
import { identitiesMock } from '../../utilities/identities/IdentitiesProvider.mock';
import { W3NCreateForm } from './W3NCreateForm';
export default {
title: 'Views/W3NCreateForm',
component: W3NCreateForm,
} as Meta;
const identity =
identitiesMock['4pNXuxPWhMxhRctgB4... |
/*
* Copyright 2020 Spotify AB
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to i... |
// Copyright 2020-2021 the AloeDB authors. All rights reserved. MIT license.
/**
* Database initialization config
*/
export interface DatabaseConfig {
/** Path to the database file. If undefined, data will be stored only in-memory. _(Default: undefined)_ */
path?: string;
/** Save data in easy-to-read format. _(... |
/**
* @license
* Copyright 2018 Google Inc.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or... |
import { MockEntity } from '../Mock/MockEntity';
import { MockValueObject } from '../Mock/MockValueObject';
describe('Entity', () => {
describe('equals', () => {
it('returns true when the same instance given', () => {
expect.assertions(1);
const vo: MockValueObject<boolean> = new MockValueObject<boo... |
import { combineReducers, createStore } from 'redux';
import columnsReducer from './redux/columns';
import itemsReducer from './redux/items';
import modalReducer from './redux/modal';
const reducers = combineReducers({
columns: columnsReducer,
items: itemsReducer,
modal: modalReducer,
});
const store = cr... |
import {
IPlugin as IPluginBase,
IFastHookRegister,
IArgs,
IRawArgs,
IPluginAPI as IPluginAPIBase,
IPathManager,
IConfigManager,
IEnvManager,
IPluginManager,
IProjectConfig
} from '@xus/core'
import type { IEsbuildRegister, IRunCmdMessage } from '@xus/cli-shared'
// preset api
import type { IRollupC... |
import {Component, OnDestroy, OnInit} from "@angular/core";
import {FormBuilder, FormGroup} from "@angular/forms";
import {ActivatedRoute, Router} from "@angular/router";
import {CabirTokenService} from "../../../cabir/cabir-token/cabir-token.service";
import {fadeInAnimation} from "../../../route.animation";
import {C... |
import { StructureSearchingGate } from './searching/structure-searching.gate';
import { StructureColumnHeaderGate } from './column/header/structure-column-header.gate';
import { StructurePagingGate } from './paging/structure-paging.gate';
import { StructureSelectionGate } from './source/structure-selection.gate';
impor... |
import { Message, RichEmbed } from 'discord.js';
import { Bot } from '../core/BotInterface';
import { ParsedMessage } from '../core/BotCommandParser';
const { Pool } = require('pg');
const give = async (cmd: ParsedMessage, msg: Message, bot: Bot): Promise<void> => {
const args = cmd.arguments.filter(str => /\S/.te... |
import React from 'react';
import styled from 'styled-components';
import { ColorProps } from '@heathmont/moon-themes';
import { themed } from '@heathmont/moon-utils';
const Svg = (props: React.SVGProps<SVGSVGElement>) => (
<svg
width="1em"
height="1em"
viewBox="0 0 32 32"
fill="none"
xmlns="http... |
import { Commit, Repository } from 'nodegit';
import { findCommitByReference, findReferenceByTagName, openRepository } from 'src/functions';
interface FindCommitByTagName {
repository?: Repository;
}
export async function findCommitByTagName(
tagName: string,
options: FindCommitByTagName = {}
): Promise<Commit... |
import { constTrue } from "@tsplus/stdlib/data/Function"
describe.concurrent("Stream", () => {
describe.concurrent("drop", () => {
it("drop", async () => {
const n = 2
const stream = Stream(1, 2, 3, 4, 5)
const program = Effect.struct({
actual: stream.drop(n).runCollect(),
expec... |
import {
GlobalAcceleratorClientResolvedConfig,
ServiceInputTypes,
ServiceOutputTypes,
} from "../GlobalAcceleratorClient";
import { DescribeAcceleratorAttributesRequest, DescribeAcceleratorAttributesResponse } from "../models/models_0";
import {
deserializeAws_json1_1DescribeAcceleratorAttributesCommand,
ser... |
import {IBookOwner} from '../owner';
import {IChildComment} from '../child-comment/child';
export interface IRootComment {
id?: number;
text: string;
date: Date;
bookId: number;
owner: IBookOwner;
isDeleted: boolean;
comments: IChildComment[];
} |
export type MenuItem = {
id: string;
icon: string;
path: string;
}; |
import * as React from 'react';
import { View } from 'react-native';
export interface Props {
children: any
}
export default function FloatingButtonWrapper(props: Props) {
return (
<View
style={{
position: 'absolute',
left: 0,
right: 0,
bottom: 0,
backgroundColor:... |
/* tslint:disable:no-unused-variable */
import { NO_ERRORS_SCHEMA } from '@angular/core';
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { empty as observableEmpty, Observable, of as observableOf } from 'rxjs';
import { APIsStore } from '../../../store/apis.store';
import { BuildStore... |
import { Component, Prop, State } from "@stencil/core";
import { load } from "../../utils/utils";
import Tunnel from "../../data/pack"
import { Pack} from "../../data/pack"
@Component({
tag: "winfun-data",
shadow: false
})
export class WFData {
/**
* URL to toprateddata.xml
*/
@Prop() src: string = "http... |
import { Body, Controller, Delete, Get, HttpStatus, Inject, Param, Post, Put, Res, UseGuards } from '@nestjs/common';
import { CreateTaskLessonDto, UpdateTaskLessonDto } from './task-lesson.dto';
import { ITaskLesson, ITaskLessonService } from './task-lesson.interface';
import { I_TASK_LESSON_SERVICE } from './task-le... |
import { lazyWithPreload } from '../../../src';
export default lazyWithPreload(() => import('./HomeScreen')); |
import 'reflect-metadata';
import AppError from '@shared/errors/AppError';
import UpdateProductService from './UpdateProductService';
import FakeCreateProductRepository from '../repositories/fakes/FakeProductRepository';
let fakeCreateExpenseRepository: FakeCreateProductRepository;
let updateProduct: UpdateProductSer... |
import React, { FC } from "react";
import { keyframes } from "styled-components";
import { AnimationProps } from "../Animation/Animation.types";
import { AnimationStyled } from "../Animation/Animation.styles";
export const FadeStyled = keyframes`
from {
opacity: 0;
}
to {
opacity: 1;
}`;
export const Fa... |
import { baseDecoratorFunction } from "./base-decorator.function"
import { NumberConfig } from "../models/config/number-config";
import { AnnotationTypes } from "../core/validator.static";
export function minNumber(config:NumberConfig) {
return baseDecoratorFunction (AnnotationTypes.minNumber, config)
} |
import React from 'react';
import styled from 'styled-components/macro';
import { Chat as ChatIcon } from '@styled-icons/heroicons-solid/Chat';
import { Contact } from 'models/Contact';
import { colours } from 'constants/colours';
import Avatar from './components/Avatar';
import Button from './components/Button';
inte... |
import { getViewById, View, Page, Button, SegmentedBar, SegmentedBarItem, Label, Animation, AnimationDefinition } from '@nativescript/core';
export function easeAnimate(args) {
const clicked = args.object as Button;
const page: Page = clicked.page;
const target = getViewById(page, 'target') as Label;
const select ... |
import { Injectable } from '@angular/core';
import { HttpClient, HttpHeaders } from '@angular/common/http';
import { environment } from '../../environments/environment';
export interface User {
name:string
last_name:string
email:string
role:string
photo:string
}
@Injectable({
providedIn: 'root'
})
expor... |
import { Component } from '@angular/core';
import { LoadingController, Loading } from 'ionic-angular';
@Component({
templateUrl: 'loading.html'
})
export class AppLoading {
public loading: Loading;
constructor(public loadingCtrl: LoadingController) {
}
ionViewDidLoad() {
this.loading = this.loadingCtrl.create(... |
import { contacts as model } from '../../model/contacts.model';
export const contacts = function(data: any) {
for (let i=0; i<model.length; i++) {
if (model[i].name === data.name) {
model.splice(i, 1);
return { status: 200 };
}
}
return { status: 404, data: { error: 'Contact not found!?' } }... |
import { Injectable } from '@nestjs/common'
import config from '@root/app/config/appConfig'
import { NotFoundException, UnauthorizedException, NotAcceptableException } from '@root/app/exception/httpException'
import { httpFlags } from '@root/constant/flags'
import { IBook } from '@root/database/models/book.model'
imp... |
<TS language="ja" version="2.1">
<context>
<name>AddressBookPage</name>
<message>
<source>Right-click to edit address or label</source>
<translation>右クリックでアドレスまたはラベルを編集</translation>
</message>
<message>
<source>Create a new address</source>
<translation>新しいアドレスを作成</trans... |
import { Component, OnInit, ChangeDetectionStrategy } from '@angular/core';
@Component({
selector: 'landing-alert',
templateUrl: './landing-alert.component.html',
changeDetection: ChangeDetectionStrategy.OnPush
})
export class LandingAlertComponent implements OnInit {
constructor() { }
ngOnInit(): void {
... |
import { ExpressionNode, NodeBase } from './shared/Node';
import { ExecutionPathOptions } from '../ExecutionPathOptions';
import FunctionExpression from './FunctionExpression';
import CallOptions from '../CallOptions';
import * as NodeType from './NodeType';
import { EMPTY_PATH, ObjectPath } from '../values';
export d... |
import { ErrorFormatRule } from '../parser/errorformatrule';
export const PlaceHolders: ErrorFormatRule[] = [
{
errorKey: 'minlength',
placeholders: {
':min': 'requiredLength'
}
},
{
errorKey: 'maxlength',
placeholders: {
':max': 'requiredLeng... |
import { Component, OnInit } from '@angular/core';
import { FormGroup, Validators, FormBuilder } from '@angular/forms';
import { Router } from '@angular/router';
import { GlobalService } from '../shared/services/global.service';
import { ApiService } from '../shared/services/fullnode.api.service';
import { WalletLoad }... |
import { EntityHeader } from "@artsy/palette"
import { CollectionsFixture } from "v2/Apps/__tests__/Fixtures/Collections"
import { mount } from "enzyme"
import React from "react"
import { CollectionsGrid } from "../CollectionsGrid"
describe("CollectionsGrid", () => {
const getWrapper = passedProps => {
return mo... |
import { TileType } from "./TileType";
const _ = require('lodash');
/**
* 麻将牌墙
*/
export class TileWall {
private totalTiles: number[] = [];
private tableTiles: number[] = [];
constructor() {
let tiles = [];
[TileType.Bing, TileType.Wan, TileType.Tiao, TileType.Dong].forEach(el => {
... |
import { Component, OnInit } from '@angular/core';
import {routerTransition} from '../../router.animations';
@Component({
selector: 'app-Blog',
templateUrl: './blog.component.html',
styleUrls: ['./blog.component.scss'],
animations: [routerTransition()]
})
export class BlogComponent implements OnIn... |
// Type definitions for correlation-id 2.1
// Project: https://github.com/toboid/correlation-id#readme
// Definitions by: Nate <https://github.com/natemara>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
export function withId(id: string, work: () => void): void;
export function withId(work: () => ... |
/* eslint-disable */
/* tslint:disable */
// @ts-ignore
import icon from 'vue-svgicon'
icon.register({
'edit': {
width: 128,
height: 128,
viewBox: '0 0 128 128',
data: '<path pid="0" d="M106.1 67.2a4.8 4.8 0 0 0-4.8 4.8v46.4H9.6V26.7h50.1a4.8 4.8 0 1 0 0-9.6H9.6A9.6 9.6 0 0 0 0 26.7v91.7c0 5.3 4.3 9.6... |
import * as TypeGraphQL from "type-graphql";
import * as GraphQLScalars from "graphql-scalars";
import { Prisma } from "@prisma/client";
import { DecimalJSScalar } from "../../scalars";
import { DateTimeFieldUpdateOperationsInput } from "../inputs/DateTimeFieldUpdateOperationsInput";
import { IntFieldUpdateOperationsIn... |
import React from 'react';
import CircularProgress from '@material-ui/core/CircularProgress';
interface CircularProgressIndicatorProps {
size?: string;
margin?: string;
}
const CircularProgressIndicator: React.FC<CircularProgressIndicatorProps> = ({
size,
margin,
}) => (
<CircularProgress
style={{
... |
import { Injectable } from '@angular/core';
import {HttpClient, HttpHeaders} from '@angular/common/http';
import {Observable, of} from 'rxjs';
import { catchError } from 'rxjs/operators';
import {User} from '../Models/User';
import {Autorisation} from '../Models/Autorisation';
@Injectable({
providedIn: 'root'
})
exp... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.