repo_name
stringlengths
5
122
path
stringlengths
3
232
text
stringlengths
6
1.05M
blackbird014/app
webapp/src/containers/WalletPage/components/ReceivePage/CreateNewAddressPage/index.tsx
<gh_stars>0 import React, { FormEvent, useState } from 'react'; import { NavLink } from 'react-router-dom'; import uid from 'uid'; import { connect } from 'react-redux'; import { Helmet } from 'react-helmet'; import { Button, Form, FormGroup, FormText, Label, Input, Row, Col, CustomInput, } from 'reac...
blackbird014/app
electron-app/src/app.ts
import log from 'loglevel'; import * as path from 'path'; import * as url from 'url'; import { app, BrowserWindow, Menu, protocol } from 'electron'; import { autoUpdater } from 'electron-updater'; import DefiProcessManager from './services/defiprocessmanager'; import AppMenu from './menus'; import { Options, parseOpti...
blackbird014/app
webapp/src/containers/WalletPage/saga.tsx
<reponame>blackbird014/app<filename>webapp/src/containers/WalletPage/saga.tsx<gh_stars>0 import { call, put, takeLatest, select, all } from 'redux-saga/effects'; import * as log from '../../utils/electronLogger'; import { fetchTokensSuccess, fetchTokensRequest, fetchTokensFailure, fetchPaymentRequest, fetchPa...
blackbird014/app
electron-app/src/menus/index.ts
import { app, shell } from 'electron'; import Wallet from '../controllers/wallets'; import { DARWIN, WIN_32, LINUX, SITE_URL, DEBUG_LOG_FILE_PATH, CONFIG_FILE_PATH, } from '../constants'; import { logFilePath } from '../services/electronLogger'; import Logs from '../controllers/logs'; export default class ...
blackbird014/app
webapp/src/containers/WalletPage/components/PaymentRequests/index.tsx
<reponame>blackbird014/app import React, { useEffect, useState } from 'react'; import moment from 'moment'; import { Link } from 'react-router-dom'; import { Card, CardBody, Table, UncontrolledDropdown, DropdownToggle, DropdownMenu, DropdownItem, } from 'reactstrap'; import { connect } from 'react-redux';...
blackbird014/app
webapp/src/containers/ConsolePage/index.tsx
<filename>webapp/src/containers/ConsolePage/index.tsx<gh_stars>0 import React from 'react'; import { I18n } from 'react-redux-i18n'; import { Helmet } from 'react-helmet'; import Console from './ConsoleComponent'; import Header from '../HeaderComponent'; import styles from './Console.module.scss'; import { getPageTitle...
frusal/frusal-tutorial-angular
src/model/my-module.ts
/// <reference types="./my-module.rt" /> /* GENERATED STUB, remove this comment and take over development of this code. */ import { session, Entity } from '@frusal/library-for-browser'; export class NamedEntity extends Entity { // nothing yet } session.factory.registerUserClass(NamedEntity); export class Produc...
frusal/frusal-tutorial-angular
src/app/app.component.ts
<reponame>frusal/frusal-tutorial-angular<gh_stars>0 import { Component, OnInit, OnDestroy } from '@angular/core'; import { session, ActualWorkspace, Stage, Owner, Transaction, QPType } from '@frusal/library-for-browser'; import { Product } from 'src/model/my-module'; @Component({ selector: 'app-root', templateUrl:...
frusal/frusal-tutorial-angular
src/model/my-module.rt.d.ts
<filename>src/model/my-module.rt.d.ts /* GENERATED FILE - DO NOT EDIT */ import { Stage, Entity, ClassSpec, Property, PrimitiveValue, ReferenceValue, InversedSet } from '@frusal/library-for-browser'; declare module './my-module' { /** Created and maintained by deploy-my-schema.js */ interface NamedEntity ext...
jonathasdantas/jonathasdantas.com
frontend/angular/jonathasdantas.com/src/app/app.module.ts
<filename>frontend/angular/jonathasdantas.com/src/app/app.module.ts import { BrowserModule } from '@angular/platform-browser'; import { NgModule } from '@angular/core'; import { RouterModule, Routes } from '@angular/router'; import { AppComponent } from './app.component'; import { SharedModule } from "./shared"; impo...
jonathasdantas/jonathasdantas.com
frontend/angular/jonathasdantas.com/src/app/admin/admin.module.ts
<reponame>jonathasdantas/jonathasdantas.com import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; import { AdminLoginComponent } from './admin-login/admin-login.component'; import { Routes, RouterModule } from "@angular/router"; const adminRoutes: Routes = [ { path: 'admin', ...
jonathasdantas/jonathasdantas.com
frontend/angular/jonathasdantas.com/src/app/shared/services/api.service.ts
<filename>frontend/angular/jonathasdantas.com/src/app/shared/services/api.service.ts<gh_stars>0 import { Injectable } from "@angular/core"; import { Http, Headers, Response } from "@angular/http"; import { Observable } from "rxjs/Observable"; import 'rxjs/add/observable/throw'; import 'rxjs/add/operator/catch'; impor...
jonathasdantas/jonathasdantas.com
frontend/angular/jonathasdantas.com/src/app/work/work.module.ts
import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; import { WorkComponent } from './work.component'; import { RouterModule, Routes } from "@angular/router"; const workRoutes: Routes = [ { path: 'work', component: WorkComponent } ]; @NgModule({ imports: [ Router...
jonathasdantas/jonathasdantas.com
frontend/angular/jonathasdantas.com/src/app/shared/components/layout/navbar/navbar.component.ts
<reponame>jonathasdantas/jonathasdantas.com<filename>frontend/angular/jonathasdantas.com/src/app/shared/components/layout/navbar/navbar.component.ts import { Component, OnInit, Inject } from '@angular/core'; import { DOCUMENT } from '@angular/platform-browser'; @Component({ selector: 'navbar', templateUrl: './navb...
jonathasdantas/jonathasdantas.com
frontend/angular/jonathasdantas.com/src/app/shared/models/base.model.ts
/** * Shared attributes for the Models * * @export * @class BaseModel */ export class BaseModel { id: number; createdAt: Date; updatedAt: Date; }
jonathasdantas/jonathasdantas.com
frontend/angular/jonathasdantas.com/src/app/blog/blog.module.ts
<reponame>jonathasdantas/jonathasdantas.com import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; import { BlogComponent } from './blog.component'; import { RouterModule, Routes } from "@angular/router"; import { PostListComponent } from './post-list/post-list.component'; const blog...
aicacia/ts-pool
src/Pool.test.ts
import * as tape from "tape"; import { Pool } from "./Pool"; class Person { name: string; meta: { age?: number; } = {}; constructor(name: string, age: number) { this.name = name; this.meta.age = age; } static init(person: Person, name: string, age: number) { person.name = name; person....
aicacia/ts-pool
src/Pool.benchmark.ts
<filename>src/Pool.benchmark.ts import * as tape from "tape"; import { Suite, Event } from "benchmark"; import { Pool } from "./Pool"; const ITERATIONS = 100000; class Person { name: string; meta: { age?: number; } = {}; constructor(name: string, age: number) { this.name = name; this.meta.age = a...
aicacia/ts-pool
src/index.ts
<filename>src/index.ts export { Pool, DEFAULT_DECONSTRUCTOR, IPoolConstructor, IPoolDeconstructor, } from "./Pool";
aicacia/ts-pool
src/Pool.ts
<reponame>aicacia/ts-pool<gh_stars>0 import type { IConstructor } from "@aicacia/core"; export type IPoolConstructor<T, A extends any[] = any[]> = ( object: T, ...args: A ) => void; export type IPoolDeconstructor<T, A extends any[] = any[]> = ( object: T, ...args: A ) => void; export function DEFAULT_DECONST...
JeetShah10/angular-movie-list
src/app/rest.service.ts
// Rest Api service for the operations like // Get Movies, Get User, Add Movie etc. // Which will fetch data from Json-server import { Injectable } from '@angular/core'; import {HttpClient} from '@angular/common/http'; import { Movies_New } from './movies'; import { Users_New } from './users'; import { forkJoin, Obser...
JeetShah10/angular-movie-list
src/app/details/details.component.ts
<reponame>JeetShah10/angular-movie-list //This component is for each movie details where user can rate movie // make comments on movie import { Component, OnInit } from '@angular/core'; import { ActivatedRoute, Router } from '@angular/router'; import { RestService } from '../rest.service'; import { MatDialog, MatDialo...
JeetShah10/angular-movie-list
src/app/update_details/update.component.ts
<reponame>JeetShah10/angular-movie-list // This component is for the admin to update details of the movie import { Component, OnInit } from '@angular/core'; import { NgForm , FormGroup} from '@angular/forms'; import {ActivatedRoute} from '@angular/router'; import { Movies_New } from '../movies'; import { RestService }...
JeetShah10/angular-movie-list
src/app/ratings.ts
export class Ratings { id:string; movie_id: string; user_id: string; rating: string; comments: string; constructor(id,movie_id,user_id,rating,comments){ this.id=id; this.movie_id=movie_id; this.user_id=user_id; this.rating=rating; this.comments=this.comme...
JeetShah10/angular-movie-list
src/app/app.module.ts
import { NgModule } from '@angular/core'; import { BrowserAnimationsModule } from '@angular/platform-browser/animations'; import { BrowserModule } from '@angular/platform-browser'; import { ReactiveFormsModule } from '@angular/forms'; import { HttpClientModule } from '@angular/common/http'; import { AppRoutingModule ...
JeetShah10/angular-movie-list
src/app/add_movies/add_movie.component.ts
<reponame>JeetShah10/angular-movie-list //In this component admin can add movie and it's details. import { Component, OnInit } from '@angular/core'; import { NgForm , FormGroup} from '@angular/forms'; import { Router } from '@angular/router'; import { Movies_New } from '../movies'; import { RestService } from '../rest...
JeetShah10/angular-movie-list
src/app/list/list.component.ts
// This component is for the list of the movies page which is landing page import { Component, OnInit } from '@angular/core'; import {ActivatedRoute} from '@angular/router'; import { RestService } from '../rest.service'; import { Movies_New } from '../movies'; import { Users_New } from '../users'; import { Authenticat...
JeetShah10/angular-movie-list
src/app/movies.ts
export class Movies_New { id:string; title: string; description: string; ratings: string; rating_average: string; comments: string; constructor(id,title,description,ratings,rating_average,comments){ this.id=id; this.title=title; this.description=description; ...
JeetShah10/angular-movie-list
src/app/app-routing.module.ts
// This file is for the defination of the routes // which route would go to which component import { NgModule } from '@angular/core'; import { Routes, RouterModule } from '@angular/router'; import { ListComponent } from './list/list.component'; import { DetailsComponent } from './details/details.component'; import { L...
JeetShah10/angular-movie-list
src/app/header/header.component.ts
//Header component will change accordingly user login and logout import { ChangeDetectorRef } from '@angular/core'; import { Component, OnInit } from '@angular/core'; import { Router } from '@angular/router'; import { AuthenticationService } from '../authentication.service'; import { RestService } from '../rest.servic...
JeetShah10/angular-movie-list
src/app/users.ts
export class Users_New { id: string; name: string; type: string; email: string; password: string; your_rating: string token?: string; constructor(id,name,type='user',email,password,your_rating){ this.id=id; this.name=name; this.type=type; this.email=e...
seanpm2001/setup-git-for-windows-sdk
main.ts
<filename>main.ts import * as core from '@actions/core' import {get, mkdirp} from './src/downloader' import {restoreCache, saveCache} from '@actions/cache' import process from 'process' import {spawnSync} from 'child_process' async function run(): Promise<void> { try { if (process.platform !== 'win32') { c...
seanpm2001/setup-git-for-windows-sdk
src/downloader.ts
import {Readable} from 'stream' import {delimiter} from 'path' import fetch from '@adobe/node-fetch-retry' import fs from 'fs' import https from 'https' import {spawn} from 'child_process' import unzipper from 'unzipper' const gitForWindowsUsrBinPath = 'C:/Program Files/Git/usr/bin' const gitForWindowsMINGW64BinPath =...
aKaigege/Graphin
packages/graphin/src/layout/utils/graph.ts
/* eslint-disable import/prefer-default-export */ import { Edge } from '../../layout/force/Elements'; import { IUserNode as Node } from '../../typings/type'; import Utils from '../../utils/index'; const getDegree = (node: Node, edges: Edge[]) => { const nodeId = node.data.id; let degree = 0; let sDegree = 0; l...
aethelyon/productstrategy
node_modules/@ethanresnick/chai-jest-snapshot/index.d.ts
declare global { namespace Chai { interface Assertion { matchSnapshot(update?: boolean): void; matchSnapshot(propertyMatchers?: object): void; matchSnapshot(propertyMatchers: object, update: boolean): void; } } } export = chaiJestSnapshot; declare function chaiJestSnapshot(chai: any, u...
aethelyon/productstrategy
node_modules/@aws-sdk/client-sts/dist-types/STSClient.d.ts
import { EndpointsInputConfig, EndpointsResolvedConfig, RegionInputConfig, RegionResolvedConfig } from "@aws-sdk/config-resolver"; import { HostHeaderInputConfig, HostHeaderResolvedConfig } from "@aws-sdk/middleware-host-header"; import { RetryInputConfig, RetryResolvedConfig } from "@aws-sdk/middleware-retry"; import ...
aethelyon/productstrategy
node_modules/@aws-sdk/credential-provider-ini/dist-types/ts3.4/index.d.ts
import { AssumeRoleWithWebIdentityParams } from "@aws-sdk/credential-provider-web-identity"; import { CredentialProvider, Credentials } from "@aws-sdk/types"; import { SourceProfileInit } from "@aws-sdk/util-credentials"; export interface AssumeRoleParams { RoleArn: string; RoleSessionName: s...
aethelyon/productstrategy
node_modules/@aws-sdk/credential-provider-sso/dist-types/index.d.ts
import { SSOClient } from "@aws-sdk/client-sso"; import { Profile } from "@aws-sdk/shared-ini-file-loader"; import { CredentialProvider } from "@aws-sdk/types"; import { SourceProfileInit } from "@aws-sdk/util-credentials"; /** * The time window (15 mins) that SDK will treat the SSO token expires in before the defined...
aethelyon/productstrategy
node_modules/@aws-sdk/client-sso/dist-types/ts3.4/models/models_0.d.ts
import { MetadataBearer as $MetadataBearer, SmithyException as __SmithyException } from "@aws-sdk/types"; export interface AccountInfo { accountId?: string; accountName?: string; emailAddress?: string; } export declare namespace AccountInfo { const filterSensitiveLog: (o...
aethelyon/productstrategy
node_modules/@aws-sdk/credential-provider-sso/dist-types/ts3.4/index.d.ts
<filename>node_modules/@aws-sdk/credential-provider-sso/dist-types/ts3.4/index.d.ts import { SSOClient } from "@aws-sdk/client-sso"; import { Profile } from "@aws-sdk/shared-ini-file-loader"; import { CredentialProvider } from "@aws-sdk/types"; import { SourceProfileInit } from "@aws-sdk/util-credentials"; export...
aethelyon/productstrategy
node_modules/@aws-sdk/credential-provider-imds/dist-types/utils/getInstanceMetadataEndpoint.d.ts
import { Endpoint } from "@aws-sdk/types"; /** * Returns the host to use for instance metadata service call. * * The host is read from endpoint which can be set either in * {@link ENV_ENDPOINT_NAME} environment variable or {@link CONFIG_ENDPOINT_NAME} * configuration property. * * If endpoint is not set, then en...
hayes/federation
composition-js/src/hints.ts
<gh_stars>0 import { SubgraphASTNode } from "@apollo/federation-internals"; import { printLocation } from "graphql"; export class HintID { constructor( readonly code: string, readonly description: string, readonly mainElementDescription: string ) { } toString(): string { return `${this.code}: ...
hayes/federation
internals-js/src/joinSpec.ts
import { DirectiveLocation } from 'graphql'; import { FeatureDefinition, FeatureDefinitions, FeatureUrl, FeatureVersion } from "./coreSpec"; import { DirectiveDefinition, EnumType, ScalarType, Schema, NonNullType, } from "./definitions"; import { Subgraph, Subgraphs } from "./federation"; import { MultiMap } ...
hayes/federation
composition-js/src/__tests__/hints.test.ts
<gh_stars>0 import { asFed2SubgraphDocument, buildSubgraph, Subgraphs } from '@apollo/federation-internals'; import { DocumentNode } from 'graphql'; import gql from 'graphql-tag'; import { HintID, hintInconsistentArgumentType, hintInconsistentDefaultValue, hintInconsistentEntity, hintInconsistentFieldType, ...
hayes/federation
internals-js/src/definitions.ts
import { ConstArgumentNode, ASTNode, buildASTSchema as buildGraphqlSchemaFromAST, DirectiveLocation, ConstDirectiveNode, ConstValueNode, DocumentNode, GraphQLError, GraphQLSchema, Kind, ListTypeNode, NamedTypeNode, parse, TypeNode, VariableDefinitionNode, VariableNode } from "graphql"; i...
hayes/federation
internals-js/src/federationSpec.ts
import { InputType, NonNullType, Schema, } from "./definitions"; import { FeatureDefinition, FeatureDefinitions, FeatureUrl, FeatureVersion } from "./coreSpec"; import { ArgumentSpecification, createDirectiveSpecification, createScalarTypeSpecification, } from "./directiveAndTypeSpecification"; import { Dir...
ArtBlocks/alertbot
src/test/api_data.ts
import { before } from 'mocha'; import { getArtblockInfo, getOpenseaInfo } from '../api_data'; var assert = require('assert'); const nock = require('nock'); process.env.NODE_ENV = 'test'; describe('ArtBlocks api_data', () => { before(() => { process.env.IS_PBAB = 'false'; process.env.PBAB_CONTRACT = ''; ...
ArtBlocks/alertbot
src/index.ts
import { schedule } from 'node-cron'; import { mintQueue, queueClean } from './mint_queue'; import { config } from './config'; require('dotenv').config(); const express = require('express'); const app = express(); const port = process.env.PORT || 8000; app.use(express.json()); const skippedProjects = new Set([289]); ...
ArtBlocks/alertbot
src/test/server.ts
<gh_stars>1-10 import { webhookDataMint, webhookDataMint0, webhookDataSkippedProject, webhookDataUnknownContract, webhookDataChangeInImage, } from './mocks/webhook'; //During the test the env variable is set to test process.env.NODE_ENV = 'test'; //Require the dev-dependencies let chai = require('chai'); le...
ArtBlocks/alertbot
src/api_data.ts
<filename>src/api_data.ts import axios from 'axios'; import { config } from './config'; export interface ArtBlocksResponse { platform: string; name: string; description: string; external_url: string; artist: string; royaltyInfo: RoyaltyInfo; traits: Trait[]; website: string; 'is dynamic': boolean; ...
SuberCyber/boardGameSuggestion
formatting/game.model.ts
export interface game { name: string; link?: string; minPlayer: number; maxPlayer: number; bestPlayerNumber?: number; minPlayingTime: string; maxPlayingTime: string; weight : string; rank?: number; type: string; typeRank?: number; category: string []; mechanisms: stri...
it-ony/typegator
src/content.ts
<filename>src/content.ts (function () { const documentElement = document.documentElement; const CANDIDATE_CLASS = "search-candidate"; const CANDIDATE_CLASS_SELECTED = "search-candidate-selected"; if (documentElement.classList.contains('typegator')) { return; } documentElement.classL...
it-ony/typegator
src/popup.ts
<gh_stars>1-10 let form: HTMLFormElement = document.querySelector('form')!!, input: HTMLInputElement = document.querySelector('input')!!, linkResults: HTMLUListElement = document.querySelector<HTMLUListElement>('#results #links')!!, tabResults = document.querySelector('#results #tabs'), tabId: number, ...
planetsolutions/pa-front
src/app/sip/sip-form/pg-impl/sip-form-pg.component.ts
<reponame>planetsolutions/pa-front import {Component, EventEmitter} from '@angular/core'; import {FormElement, DocType, Doc, SystemDoc, CmisObject, PagedList} from '../../../index'; import {Observable} from 'rxjs/Observable'; import {SipFormI} from '../sip-form-i'; import {Application} from '../../../services/api/model...
planetsolutions/pa-front
src/app/services/util/xform-parser.service.spec.ts
import { TestBed, inject } from '@angular/core/testing'; import { XformParserService } from './xform-parser.service'; describe('XformParserService', () => { beforeEach(() => { TestBed.configureTestingModule({ providers: [XformParserService] }); }); it('should be created', inject([XformParserServi...
planetsolutions/pa-front
src/app/sip/sip-form/pg-impl/sip-form-pg-tab.component.ts
<reponame>planetsolutions/pa-front<gh_stars>0 import { Compiler, Component, ComponentRef, Injector, Input, ModuleWithComponentFactories, NgModule, OnInit, Type, ViewContainerRef } from '@angular/core'; import {SystemDoc, Doc, Application} from '../../../index'; import {ApiService} from '../../../services/api/api.se...
planetsolutions/pa-front
src/app/services/api/api.service.ts
import {Injectable} from '@angular/core'; import {Router} from '@angular/router'; import {HttpClient, HttpHeaders, HttpResponse, HttpParams} from '@angular/common/http'; import {LoginParameters, LoginResponse, Token, Application, Flag, Search, Doc, PagedList, XForm, SearchResultRow, ResultMaster, SearchComposition, I...
planetsolutions/pa-front
src/app/services/api/model/search-composition.ts
<filename>src/app/services/api/model/search-composition.ts import {HalLinkedObject} from './hal-links'; import {IAHal} from './ia-hal'; export class SearchComposition extends HalLinkedObject { public searchUUID: string; public xformUUID: string; public resultMasterUUID: string; constructor(json: any) { su...
planetsolutions/pa-front
src/app/services/api/model/form-element.ts
<gh_stars>0 export class FormElement { public name: string; public title: string; public type: string; constructor(name: string, title: string, type: string) { this.name = name; this.title = title; this.type = type; } }
planetsolutions/pa-front
src/app/users/user.service.ts
import { Injectable } from '@angular/core'; import { BsModalService } from 'ngx-bootstrap/modal'; import {Observable} from 'rxjs/Observable'; import {ApiService} from '../services/api/api.service'; import 'rxjs/add/observable/fromPromise'; import {TranslateService} from '@ngx-translate/core'; import {UserInfo} from '.....
planetsolutions/pa-front
src/app/sip/preview/preview-i.ts
<filename>src/app/sip/preview/preview-i.ts import {EventEmitter} from '@angular/core'; import {SafeUrl} from '@angular/platform-browser'; export interface PreviewI { src: SafeUrl; mimeType: string; fileName: string; onAfterCreated(): void; }
planetsolutions/pa-front
src/app/services/util/xform-parser.service.ts
<reponame>planetsolutions/pa-front import { Injectable } from '@angular/core'; import {FormElement} from '../api/model/form-element'; @Injectable() export class XformParserService { private properties: any; private layout: any[]; private formDoc: Document; constructor() { } public formToJson(xmlString: st...
planetsolutions/pa-front
src/app/services/api/model/ia-hal.ts
<filename>src/app/services/api/model/ia-hal.ts export namespace IAHal { export type IAHalName = string; export const SELF: IAHalName = 'self'; export const AIC: IAHalName = 'http://identifiers.emc.com/aic'; export const SEARCH: IAHalName = 'http://identifiers.emc.com/search'; export const SEARCH_COMPOSITIONS ...
planetsolutions/pa-front
src/app/services/util/xform-submission-serializer.ts
export class XFormSubmissionSerializer { public serialize(submission: XMLDocument) { const data = submission.getElementsByTagName('data').item(0); const criteria: SubmissionCriteria[] = []; for (let i = 0; i < data.childNodes.length; i++) { const criterion = data.childNodes.item(i); if (crit...
planetsolutions/pa-front
src/app/sip/preview/picture-impl/preview-picture.component.ts
import {Component, Input} from '@angular/core'; import {SafeUrl} from '@angular/platform-browser'; import {PreviewI} from '../preview-i'; @Component({ selector: 'app-preview-picture', templateUrl: './preview-picture.component.html' }) export class PreviewPictureComponent implements PreviewI { @Input() src: SafeU...
planetsolutions/pa-front
src/app/shared.module.ts
import {MimeIconPipe} from './pipes/mime-icon.pipe'; import {FileSizePipe} from './pipes/file-size.pipe'; import {DateTimeFormatPipe} from './pipes/date-time-format.pipe'; import {DateFormatPipe} from './pipes/date-format.pipe'; import {NgModule} from '@angular/core'; import {HttpClient} from '@angular/common/http'; im...
planetsolutions/pa-front
src/app/services/api/auth.guard.ts
<reponame>planetsolutions/pa-front<gh_stars>0 import { Injectable } from '@angular/core'; import {CanActivate, ActivatedRouteSnapshot, RouterStateSnapshot, Router} from '@angular/router'; import { Observable } from 'rxjs/Observable'; import { ApiService } from './api.service'; import 'rxjs/add/observable/of'; @Inject...
planetsolutions/pa-front
src/app/alerts/alerts.service.ts
import { Injectable } from '@angular/core'; import { BsModalService } from 'ngx-bootstrap/modal'; import {Observable} from 'rxjs/Observable'; import {AlertDialogComponent} from './alert-dialog/alert-dialog.component'; import {DomSanitizer} from "@angular/platform-browser"; import {TranslateService} from "@ngx-translate...
planetsolutions/pa-front
src/app/pipes/date-format.pipe.ts
import { Pipe, PipeTransform } from '@angular/core'; import { DatePipe } from '@angular/common'; @Pipe({ name: 'dateFormat' }) export class DateFormatPipe extends DatePipe implements PipeTransform { transform(value: any, args?: any): any { let format = 'dd/MM/yyyy'; if (args && args.format) { format...
planetsolutions/pa-front
src/app/objects-list/objects-list-cell/objects-list-cell.component.ts
import {Component, EventEmitter, Input, OnInit, Output} from '@angular/core'; import {SearchResultRow} from '../../services/api/model/search-result-row'; import {ResultMasterColumnTypes, ResultMasterPanelTabColumn} from '../../services/api/model/result-master'; import {TranslateService} from '@ngx-translate/core'; imp...
planetsolutions/pa-front
src/app/services/api/model/application.ts
<filename>src/app/services/api/model/application.ts<gh_stars>0 import {HalLinkedObject} from './hal-links'; import {Platforms} from './platforms.enum'; export class Application extends HalLinkedObject { public name: string; public createdBy?: string; public description?: string; public uuid: string; public i...
planetsolutions/pa-front
src/app/applications-list/searches/search-form/search-form.service.ts
<gh_stars>0 import { Injectable } from '@angular/core'; import { BsModalService } from 'ngx-bootstrap/modal'; import {Observable} from 'rxjs/Observable'; import 'rxjs/add/observable/fromPromise'; import {SearchFormComponent} from './search-form.component'; @Injectable() export class SearchFormService { constructor(...
planetsolutions/pa-front
src/app/applications-list/searches/searches.component.ts
<reponame>planetsolutions/pa-front import {Component, HostListener, OnDestroy, OnInit} from '@angular/core'; import {ActivatedRoute, Router} from '@angular/router'; import {animate, state, style, transition, trigger} from '@angular/animations'; import { Search, SearchComposition, Application, ResultMaster, ResultMaster...
planetsolutions/pa-front
src/app/services/api/model/result-master.ts
import {HalLinkedObject} from './hal-links'; export class ResultMaster extends HalLinkedObject { public lastModifiedBy: string; public lastModifiedDate: string; public version: number; public compositionName: string; public searchName: string; public panels: ResultMasterPanel[]; public namespaces: any[];...
planetsolutions/pa-front
src/app/services/api/http.interceptor.ts
<reponame>planetsolutions/pa-front import {HttpErrorResponse, HttpEvent, HttpHandler, HttpInterceptor, HttpRequest} from '@angular/common/http'; import {Observable} from 'rxjs/Observable'; import {Router} from '@angular/router'; import {AuthService} from './auth.service'; import {Token} from '../../index'; import {Beh...
planetsolutions/pa-front
src/environments/environment.prod.ts
<gh_stars>0 export const environment = { production: true, IAEndpoint: '', useHashLocationStrategy: true, itemsOnPage: 20, autoRefresh: 0, minScreenSize: 1100, rootId: '00000000-0000-0000-0000-000000000000', logo: 'logo.png?1', title: '<NAME>', };
planetsolutions/pa-front
src/app/form-widgets/type-select-widget.component.ts
<gh_stars>0 import { Component, Input, OnInit } from '@angular/core'; import { AbstractControl } from '@angular/forms'; import { JsonSchemaFormService } from 'angular2-json-schema-form'; import {TypeSelectService} from '../type/type.service'; import {DocType} from '../index'; @Component({ selector: 'app-type-select-...
planetsolutions/pa-front
src/app/services/communication.service.ts
<reponame>planetsolutions/pa-front import {Injectable} from '@angular/core'; import {ReplaySubject} from 'rxjs/ReplaySubject'; import {Observable} from 'rxjs/Observable'; @Injectable() export class CommunicationService { private store = new Map<string, ReplaySubject<any>>(); public set(key: string, value: any): v...
planetsolutions/pa-front
src/app/sip/sip.service.ts
import { Injectable } from '@angular/core'; import { BsModalService } from 'ngx-bootstrap/modal'; import {Application, DocType, Platforms} from '../index'; import {SipFormComponent} from './sip-form/sip-form.component'; import {TypeSelectService} from '../type/type.service'; import {Observable} from 'rxjs/Observable'; ...
planetsolutions/pa-front
src/app/sip/system.service.ts
import { Injectable } from '@angular/core'; import { BsModalService } from 'ngx-bootstrap/modal'; import {DocType} from '../index'; import {SipFormComponent} from './sip-form/sip-form.component'; import {TypeSelectService} from '../type/type.service'; import {Observable} from 'rxjs/Observable'; import 'rxjs/add/observa...
planetsolutions/pa-front
src/app/pipes/limit-to.pipe.ts
<reponame>planetsolutions/pa-front<gh_stars>0 import { Pipe, PipeTransform } from '@angular/core'; @Pipe({ name: 'limitTo' }) export class LimitToPipe implements PipeTransform { transform(arr: any[], size: number): any[] { if (!arr || arr.length < size) return arr; return size > 0 ? arr.slice(0, size) : ...
planetsolutions/pa-front
src/app/services/api/model/access-group.ts
<gh_stars>0 export class AccessGroup { public id: string; public title: string; constructor(json: any) { this.id = json.id; this.title = json.title; } }
planetsolutions/pa-front
src/app/folder/folders-manage/folders-manage.component.ts
<gh_stars>0 import { Component, OnInit } from '@angular/core'; import {CmisObject, ResultMasterColumnTypes, PagedList, SearchResultRow, CmisConstants, ResultMasterPanelTabColumn, SortOptions} from '../../index'; import {TranslateService} from '@ngx-translate/core'; import {ApiService} from '../../services/api/api.ser...
planetsolutions/pa-front
src/app/users/user-edit/user-edit.component.ts
<filename>src/app/users/user-edit/user-edit.component.ts import {Component, Input, AfterViewInit, EventEmitter, Output} from '@angular/core'; import {UserInfo, Tenant, AccessGroup} from '../../index'; import {BsModalService} from 'ngx-bootstrap'; import { BsModalRef } from 'ngx-bootstrap/modal/bs-modal-ref.service'; im...
planetsolutions/pa-front
src/app/pipes/date-time-format.pipe.ts
<reponame>planetsolutions/pa-front<filename>src/app/pipes/date-time-format.pipe.ts import { Pipe, PipeTransform } from '@angular/core'; import { DatePipe } from '@angular/common'; @Pipe({ name: 'dateTimeFormat' }) export class DateTimeFormatPipe extends DatePipe implements PipeTransform { transform(value: any, ar...
planetsolutions/pa-front
src/app/services/api/model/search-result-row.ts
export class SearchResultRow implements Iterable<SearchResultRowColumn> { public columns: Map<string, SearchResultRowColumn>; public id: string; constructor({id, columns}) { this.columns = new Map<string, SearchResultRowColumn>(columns.map((c, idx, arr) => { const col = new SearchResultRowColumn(c); ...
planetsolutions/pa-front
src/app/services/api/model/token.spec.ts
import {Token} from './token'; describe('Token', () => { it('should serialize and deserialize correctly', () => { const accessToken = 'access'; const refreshToken = 'refresh'; const tokenType = 'tokenType'; const expireTime: Date = new Date(); const token = new Token(accessToken, refreshToken, to...
planetsolutions/pa-front
src/app/type/type-select/type-select.component.spec.ts
<filename>src/app/type/type-select/type-select.component.spec.ts import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { TypeSelectComponent } from './type-select.component'; describe('TypeSelectComponent', () => { let component: TypeSelectComponent; let fixture: ComponentFixture<TypeSe...
planetsolutions/pa-front
src/app/objects-list/sticky-header.directive.ts
<filename>src/app/objects-list/sticky-header.directive.ts import {Directive, ElementRef, HostListener} from '@angular/core'; import {ResizeService} from '../services/util/resize.service'; @Directive({ selector: '[appStickyHeader]' }) export class StickyHeaderDirective { private resizingElement; private redrawTi...
planetsolutions/pa-front
src/app/objects-list/setup/objects-list-setup.service.ts
<gh_stars>0 import { Injectable } from '@angular/core'; import {ResultMasterPanelTabColumn} from '../../index'; import {Observable} from 'rxjs/Observable'; import {AuthService} from '../../services/api/auth.service'; import {Subject} from 'rxjs/Subject'; import {BsModalService} from 'ngx-bootstrap'; import {ObjectsList...
planetsolutions/pa-front
src/app/alerts/alert-dialog/alert-dialog.component.ts
import {Component, EventEmitter, Input, OnInit} from '@angular/core'; import {BsModalRef} from 'ngx-bootstrap'; import {SafeHtml} from "@angular/platform-browser"; @Component({ selector: 'app-alert-dialog', templateUrl: './alert-dialog.component.html', styleUrls: ['./alert-dialog.component.css'] }) export class ...
planetsolutions/pa-front
src/app/services/api/model/content-data.ts
export class ContentData { public mimeType: string; public url?: string; public blob?: Blob; public fileName?: string constructor(fileName: string) { this.fileName = fileName; } }
planetsolutions/pa-front
src/app/folder/folder-edit-dialog/folder-edit-dialog.component.ts
<filename>src/app/folder/folder-edit-dialog/folder-edit-dialog.component.ts import {Component, EventEmitter, Input, OnInit, ViewChild} from '@angular/core'; import {BsModalRef} from 'ngx-bootstrap'; import {CmisObject, Doc} from '../../index'; import {ApiService} from '../../services/api/api.service'; import {SipServic...
planetsolutions/pa-front
src/app/services/util/flag.ts
<filename>src/app/services/util/flag.ts<gh_stars>0 import { Subject } from 'rxjs/Subject'; import { Subscriber } from 'rxjs/Subscriber'; import { Observable } from 'rxjs/Observable'; /** * Monitor-like subject, have 3 states. * 1. Right after creation will throw error for any subscriber. * 2. After startWaiting() m...
planetsolutions/pa-front
src/app/services/api/model/paged-list.ts
export class PagedList<T> { public data: T[]; public total: number; public isLast: boolean; constructor(data: T[], total: number, isLast = false) { this.data = data; this.total = total; this.isLast = isLast; } }
planetsolutions/pa-front
src/app/services/api/model/tenant.ts
<gh_stars>0 import {HalLinkedObject} from './hal-links'; import {Platforms} from './platforms.enum'; export class Tenant extends HalLinkedObject { public name: string; constructor(json: any) { super(json); this.name = json.name; } }
planetsolutions/pa-front
src/app/services/api/model/doc.ts
<gh_stars>0 export class Doc { public title: string; public id: string; public author: string; public description: string; public type: string; public baseType: string; public data: any; public fileName: string; public fileLength: number; public lastModified: Date; public creationTime: Date; pub...
planetsolutions/pa-front
src/app/users/group.service.ts
<reponame>planetsolutions/pa-front import { Injectable } from '@angular/core'; import { BsModalService } from 'ngx-bootstrap/modal'; import {Observable} from 'rxjs/Observable'; import {ApiService} from '../services/api/api.service'; import 'rxjs/add/observable/fromPromise'; import {TranslateService} from '@ngx-translat...
planetsolutions/pa-front
src/app/services/communication.service.spec.ts
<reponame>planetsolutions/pa-front<gh_stars>0 import { TestBed, inject } from '@angular/core/testing'; import { CommunicationService } from './communication.service'; describe('CommunicationService', () => { let service: CommunicationService; beforeEach(() => { TestBed.configureTestingModule({ provider...
planetsolutions/pa-front
src/app/services/util/resize.service.ts
import { Injectable } from '@angular/core'; import * as elementResizeDetectorMaker from 'element-resize-detector'; @Injectable() export class ResizeService { private resizeDetector: any; constructor() { this.resizeDetector = elementResizeDetectorMaker({ strategy: 'scroll' }); } addResizeEventListener(ele...