repo_name
stringlengths
5
122
path
stringlengths
3
232
text
stringlengths
6
1.05M
mukesh-openchannel/angular-template-libraries
projects/angular-common-services/src/lib/model/api/transaction.model.ts
import { SafeResourceUrl } from '@angular/platform-browser'; export type TransactionType = 'payment' | 'refund'; export type TransactionOptions = 'View receipt' | 'Download invoice'; export type TransactionStatus = 'Successful' | 'Refunded'; export interface Transaction { transactionId: string; ownershipId:...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/common-components/oc-checkbox/oc-checkbox.component.spec.ts
<filename>projects/angular-common-components/src/lib/common-components/oc-checkbox/oc-checkbox.component.spec.ts import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { OcCheckboxComponent } from './oc-checkbox.component'; import { FormsModule } from '@angular/forms'; describe('OcChe...
mukesh-openchannel/angular-template-libraries
src/review.stories.ts
<gh_stars>0 import { moduleMetadata } from '@storybook/angular'; import { OcRatingComponent, OcReviewComponent } from '@openchannel/angular-common-components/src/lib/market-components'; import { NgbModule } from '@ng-bootstrap/ng-bootstrap'; import { AngularSvgIconModule } from 'angular-svg-icon'; import { HttpClientTe...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/form-components/model/multi-select-checkbox.model.ts
export interface DropdownItem { label: string | number; value: any; } export type DropdownItemType = number | string | DropdownItem;
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/form-components/oc-dropdown-form/oc-dropdown-form.service.ts
<gh_stars>0 import { AppFormField, DropdownFormField } from '../model/app-form-model'; import { cloneDeep } from 'lodash'; export class OcDropdownFormUtils { static getFormFields(field: DropdownFormField, oldValue?: string): AppFormField[] { const { attributes: { dropdownSetting...
mukesh-openchannel/angular-template-libraries
src/color.stories.ts
import { moduleMetadata } from '@storybook/angular'; import { OcColorComponent, OcFormComponentsModule } from '@openchannel/angular-common-components/src/lib/form-components'; const modules = { imports: [OcFormComponentsModule], }; export default { title: 'Color [BEM]', component: OcColorComponent, de...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/common-components/model/image-gallery.model.ts
/** * Gallery Item interface * @property {string} title - String value with image title * @property {string} description - String value with description for the title * @property {string} image - Image URL value, not set this value if your data is video * @property {string} video Video URL value, not set this valu...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/portal-components/oc-app-table/oc-app-table.component.ts
<reponame>mukesh-openchannel/angular-template-libraries import { AfterViewInit, ChangeDetectorRef, Component, Directive, EventEmitter, Input, Output, QueryList, TemplateRef, ViewChildren, } from '@angular/core'; import { AppGridSortChosen, AppGridSortColumn, AppGridSo...
mukesh-openchannel/angular-template-libraries
projects/angular-common-services/src/lib/service/chart-service.ts
<filename>projects/angular-common-services/src/lib/service/chart-service.ts import { Injectable } from '@angular/core'; import { HttpRequestService } from './http-request-services'; import { Observable } from 'rxjs'; import { map } from 'rxjs/operators'; import { OcHttpParams } from '../model/api/http-params-encoder-mo...
mukesh-openchannel/angular-template-libraries
src/app-getstarted.stories.ts
<gh_stars>0 import { moduleMetadata } from '@storybook/angular'; import { OcAppGetStartedComponent } from '@openchannel/angular-common-components/src/lib/market-components'; import { OcCommonLibModule } from '@openchannel/angular-common-components/src/lib/common-components'; /** List of module dependencies and compone...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/portal-components/oc-chart/oc-chart.component.spec.ts
<filename>projects/angular-common-components/src/lib/portal-components/oc-chart/oc-chart.component.spec.ts import { ComponentFixture, fakeAsync, TestBed, tick } from '@angular/core/testing'; import { OcChartComponent } from './oc-chart.component'; import { MockDropdownButtonComponent, MockSvgIconComponent } from '@open...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/common-components/oc-dropdown/oc-dropdown.component.ts
import { Component, EventEmitter, Input, Output } from '@angular/core'; import { DropdownModel } from '../model/components-basic.model'; @Component({ selector: 'oc-dropdown', templateUrl: './oc-dropdown.component.html', styleUrls: ['./oc-dropdown.component.css'], }) export class OcDropdownComponent { /...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/form-components/service/rich-text-utils/rich-text.service.ts
export class RichTextUtils { static SPACES = ['&nbsp;', ' ']; static trimRichText(htmlText: string): string { if (!htmlText || typeof htmlText !== 'string') { return htmlText; } const subString: string[] = htmlText.split(/(<[^>]*>)/g); const leftArr = []; con...
mukesh-openchannel/angular-template-libraries
src/multiSelectCheckboxList.stories.ts
<reponame>mukesh-openchannel/angular-template-libraries import { moduleMetadata } from '@storybook/angular'; import { OcCommonLibModule } from '@openchannel/angular-common-components/src/lib/common-components'; import { OcMultiSelectCheckboxListComponent } from '@openchannel/angular-common-components/src/lib/form-compo...
mukesh-openchannel/angular-template-libraries
projects/angular-common-services/src/lib/service/meta-tag.service.ts
import { Meta } from '@angular/platform-browser'; import { NavigationEnd, Router } from '@angular/router'; import { get } from 'lodash'; import { OCMetaTagConfigType, MetaTagsPageConfig } from '../model/api/meta-tag.model'; /** * Service used for updating meta-tags in html <head> by current router link. * * @exampl...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/form-components/service/rich-text-utils/rich-text.service.spec.ts
<filename>projects/angular-common-components/src/lib/form-components/service/rich-text-utils/rich-text.service.spec.ts import { RichTextUtils } from './rich-text.service'; describe('RichTextUtils', () => { it('Rich text as NULL.', () => { expect(RichTextUtils.trimRichText(null)).toBe(null); }); it(...
mukesh-openchannel/angular-template-libraries
projects/angular-common-services/src/lib/service/country.service.ts
import { Injectable } from '@angular/core'; import { Observable } from 'rxjs'; import { HttpClient, HttpHeaders } from '@angular/common/http'; import { CountriesModel, StatesModel } from '../model/api/country-state.model'; /** * Description: API service for getting countries and states list.<br> * Link - https://doc...
mukesh-openchannel/angular-template-libraries
projects/angular-common-services/src/lib/service/title.service.ts
import { Injectable } from '@angular/core'; import { Title } from '@angular/platform-browser'; import { ActivationStart, Router } from '@angular/router'; /** * * Description: Service to work with title.<br> * * @param {string} title * * Methods: * * setPrefix * * setPostfix * * setSpecialTitle * */ @Inje...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/portal-components/utils/chart.utils.ts
<reponame>mukesh-openchannel/angular-template-libraries export class ChartUtils { /** * Number of ticks that should always be on axis. */ static PERSISTING_TICKS_NUMBER = 2; /** * Calculates visible indexes for axis according to skip ratio and including first and * last ticks. * @p...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/market-components/oc-app-list-grid/oc-app-list-grid.component.ts
import { Component, EventEmitter, Input, Output, TemplateRef } from '@angular/core'; import { FullAppData } from '@openchannel/angular-common-components/src/lib/common-components'; import { get } from 'lodash'; /** * Shows vertical list of the apps */ @Component({ selector: 'oc-app-list-grid', templateUrl: '...
mukesh-openchannel/angular-template-libraries
projects/angular-common-services/src/lib/model/api/developer.model.ts
<filename>projects/angular-common-services/src/lib/model/api/developer.model.ts export interface DeveloperModel { developerId?: string; accountCount?: number; appCount?: number; created?: number; email?: string; name?: string; type?: string; roles?: string[]; permissions?: string[]; ...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/common-components/oc-profile-navbar/oc-profile-navbar.component.ts
<gh_stars>0 import { Component, Input } from '@angular/core'; /** * Profile navbar component. Used to navigate the profile pages. * Consists of a button and ngb dropdown menu with items. * @type {string}. */ @Component({ selector: 'oc-profile-navbar', templateUrl: './oc-profile-navbar.component.html', ...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/portal-components/oc-app-table/oc-app-table.component.spec.ts
import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { FormsModule, NgModel } from '@angular/forms'; import { CommonModule } from '@angular/common'; import { BrowserModule, By } from '@angular/platform-browser'; import { OcAppTableCellPattern, OcAppTableComponent } from './oc-app-tab...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/market-components/oc-app-card/oc-app-card.component.spec.ts
import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { OcAppCardComponent } from './oc-app-card.component'; import { By } from '@angular/platform-browser'; import { Location } from '@angular/common'; import { PricePipe } from '../../common-components/pipe/price.pipe'; import { FullAp...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/market-components/oc-featured-apps/oc-featured-apps.component.ts
import { Component, EventEmitter, Input, Output, TemplateRef } from '@angular/core'; import { FullAppData, HeadingTag } from '@openchannel/angular-common-components/src/lib/common-components'; import { get } from 'lodash'; /** * Featured apps component. Renders a list of applications, that are featured by a user. * ...
mukesh-openchannel/angular-template-libraries
projects/angular-common-services/src/lib/service/user-account.service.ts
<filename>projects/angular-common-services/src/lib/service/user-account.service.ts import { Injectable } from '@angular/core'; import { Observable } from 'rxjs'; import { Page } from '../model/api/page.model'; import { HttpRequestService } from './http-request-services'; import { UserAccount } from '../model/api/user.m...
mukesh-openchannel/angular-template-libraries
projects/angular-common-services/src/lib/service/invite-user.service.ts
<filename>projects/angular-common-services/src/lib/service/invite-user.service.ts import { Injectable } from '@angular/core'; import { Page } from '../model/api/page.model'; import { InviteDeveloperModel, InviteUserModel } from '../model/api/invite-user.model'; import { Observable } from 'rxjs'; import { HttpRequestSer...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/market-components/oc-text-search/oc-text-search.component.spec.ts
import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { OcTextSearchComponent } from './oc-text-search.component'; import { By } from '@angular/platform-browser'; import { FormsModule } from '@angular/forms'; import { HttpClientTestingModule } from '@angular/common/http/testing'; impo...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/common-components/oc-radio-button/oc-radio-button.component.ts
import { Component, forwardRef, Input } from '@angular/core'; import { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms'; import { TransformTextType } from '../model/text-transfrom-pipe.model'; /** * Represents the simple radio button component. It supports the `ngModel` and `formControl`. * @example ...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/common-components/model/text-transfrom-pipe.model.ts
<reponame>mukesh-openchannel/angular-template-libraries export type TransformTextType = 'titleCase';
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/common-components/oc-title/oc-title.component.ts
<gh_stars>0 import { Component, Input } from '@angular/core'; @Component({ selector: 'oc-title', templateUrl: './oc-title.component.html', styleUrls: ['./oc-title.component.css'], }) export class OcTitleComponent { /** * Sets a text for the title component. * Required. * If no title - th...
mukesh-openchannel/angular-template-libraries
projects/angular-common-services/src/lib/util/query.util.ts
export class QueryUtil { static DEFAULT_PAGE_LIMIT = 10; static getAndQuery(queries: string[]): string { if (queries && queries.length > 0) { return `{'$and': [${queries.join(',')}]}`; } return ''; } static getPaginationQuery(pageNumber: number, limit: number, defau...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/common-components/oc-dropdown-button/oc-dropdown-button.component.spec.ts
<filename>projects/angular-common-components/src/lib/common-components/oc-dropdown-button/oc-dropdown-button.component.spec.ts import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { OcDropdownButtonComponent } from './oc-dropdown-button.component'; import { NgbModule } from '@ng-boots...
mukesh-openchannel/angular-template-libraries
projects/angular-common-services/src/lib/model/api/login.model.ts
<filename>projects/angular-common-services/src/lib/model/api/login.model.ts export class LoginRequest { idToken: string; accessToken: string; constructor(idToken: string, accessToken: string) { this.idToken = idToken; this.accessToken = accessToken; } } export interface LoginResponse {...
mukesh-openchannel/angular-template-libraries
src/edit-user-form.stories.ts
import { moduleMetadata } from '@storybook/angular'; import { OcCommonLibModule } from '@openchannel/angular-common-components/src/lib/common-components'; import { RouterTestingModule } from '@angular/router/testing'; import { OcEditUserFormComponent, OcEditUserFormConfig, OCOrganization, OcFormComponen...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/common-components/model/radio-button.model.ts
<reponame>mukesh-openchannel/angular-template-libraries<gh_stars>0 export type RadioButtonLayout = 'vertical' | 'horizontal';
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/form-components/service/form-config.service.ts
<filename>projects/angular-common-components/src/lib/form-components/service/form-config.service.ts import { Inject, Injectable, InjectionToken, Optional } from '@angular/core'; import { merge } from 'lodash'; import { FormLabelPosition } from '../model/app-form-model'; import { ImageCropperOptions } from '../oc-file-u...
mukesh-openchannel/angular-template-libraries
projects/angular-common-services/src/lib/model/api/app-data-model.ts
<reponame>mukesh-openchannel/angular-template-libraries<gh_stars>0 import { SafeResourceUrl } from '@angular/platform-browser'; import { OwnershipModelResponse } from './ownership.model'; export interface AppModelResponse { type: string; price: number; trial: number; license: string; modelId: strin...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/market-components/oc-review-list/oc-review-list.component.spec.ts
<reponame>mukesh-openchannel/angular-template-libraries import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { OcReviewListComponent } from './oc-review-list.component'; import { By } from '@angular/platform-browser'; import { CommonModule } from '@angular/common'; import { MockButto...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/market-components/oc-featured-apps/oc-featured-apps.component.spec.ts
import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { OcFeaturedAppsComponent } from './oc-featured-apps.component'; import { Location } from '@angular/common'; import { Router } from '@angular/router'; import { RouterTestingModule } from '@angular/router/testing'; import { By } from...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/common-components/pipe/text-transform.pipe.ts
import { Pipe, PipeTransform } from '@angular/core'; import { TransformTextType } from '../model/text-transfrom-pipe.model'; @Pipe({ name: 'transformText', }) export class TransformTextPipe implements PipeTransform { transform(text: any, type: TransformTextType = null): string | any { if (typeof text =...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/common-components/model/oc-error.model.ts
<filename>projects/angular-common-components/src/lib/common-components/model/oc-error.model.ts import { NgForm } from '@angular/forms'; /** * All field validators for this library. */ export type FieldError = | 'required' | 'minlength' | 'maxlength' | 'minCount' | 'maxCount' | 'minElementsCou...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/public-api.ts
<gh_stars>0 export * from '@openchannel/angular-common-components/src/lib/common-components'; export * from '@openchannel/angular-common-components/src/lib/form-components'; export * from '@openchannel/angular-common-components/src/lib/auth-components'; export * from '@openchannel/angular-common-components/src/lib/mana...
mukesh-openchannel/angular-template-libraries
projects/angular-common-services/src/lib/service/developer-role.service.ts
import { Injectable } from '@angular/core'; import { Observable } from 'rxjs'; import { Page } from '../model/api/page.model'; import { HttpRequestService } from './http-request-services'; import { DeveloperRoleResponse } from '../model/api/account-role-model'; import { OcHttpParams } from '../model/api/http-params-enc...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/market-components/oc-overall-rating/oc-overall-rating.component.spec.ts
<gh_stars>0 import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { OcOverallRatingComponent } from './oc-overall-rating.component'; import { NgbModule } from '@ng-bootstrap/ng-bootstrap'; import { By } from '@angular/platform-browser'; import { OcLabelComponent } from '@openchannel/a...
mukesh-openchannel/angular-template-libraries
projects/angular-common-services/src/lib/service/auth-holder.service.ts
import { Injectable } from '@angular/core'; import jwtDecode from 'jwt-decode'; import { AccessLevel, Permission, PermissionType, UserDetails } from '../model/api/user.model'; /** * Description: * 1. Service for store JWT tokens in local browser storage. * 2. Decoding JWT accessToken and getting user data from him....
mukesh-openchannel/angular-template-libraries
projects/angular-common-services/src/lib/interceptors/http-requests-watcher.interceptor.ts
<reponame>mukesh-openchannel/angular-template-libraries import { Injectable } from '@angular/core'; import { HttpRequest, HttpHandler, HttpEvent, HttpInterceptor } from '@angular/common/http'; import { EMPTY, Observable } from 'rxjs'; import { PrerenderRequestsWatcherService } from '../service/prerender-requests-watche...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/common-components/oc-error/oc-error.component.ts
import { Component, Input, OnInit } from '@angular/core'; import { AbstractControl, AbstractControlDirective, FormArray, NgModel, ValidationErrors } from '@angular/forms'; import { OcErrorService } from './oc-error-service'; import { AbstractErrorMessageConfiguration } from '../model/oc-error.model'; import { ControlUt...
mukesh-openchannel/angular-template-libraries
src/confirmaton-modal.stories.ts
<gh_stars>0 import { moduleMetadata } from '@storybook/angular'; import { OcConfirmationModalComponent, OcCommonLibModule } from '@openchannel/angular-common-components/src/lib/common-components'; const modules = { imports: [OcCommonLibModule], }; export default { title: 'Confirmation modal [BEM]', compon...
mukesh-openchannel/angular-template-libraries
src/app-galary.stories.ts
import { moduleMetadata } from '@storybook/angular'; import { OcAppGalleryComponent, OcMarketComponentsModule } from '@openchannel/angular-common-components/src/lib/market-components'; import { BrowserAnimationsModule } from '@angular/platform-browser/animations'; import { RouterTestingModule } from '@angular/router/te...
mukesh-openchannel/angular-template-libraries
projects/angular-common-services/src/lib/service/native-login.service.ts
<filename>projects/angular-common-services/src/lib/service/native-login.service.ts import { Injectable } from '@angular/core'; import { Observable } from 'rxjs'; import { HttpRequestService } from './http-request-services'; import { OCNativeCustomSignup, OCNativeDefaultSignup, UserLoginModel } from '../model/api/user-l...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/market-components/oc-overall-rating/oc-overall-rating.component.ts
import { Component, Input } from '@angular/core'; import { OverallRatingSummary } from '../models/overall-rating-summary-model'; /** * Overall rating component. Based on ngb-rating component. Represents rating template and logic. * * Inputs: <br> * @param {string} overallReviewLabel * @param {OverallRatingSummary...
mukesh-openchannel/angular-template-libraries
src/app-list-grid.stories.ts
import { moduleMetadata } from '@storybook/angular'; import { OcAppListGridComponent, OcRatingComponent } from '@openchannel/angular-common-components/src/lib/market-components'; import { AngularSvgIconModule } from 'angular-svg-icon'; import { PricePipe, StatElement } from '@openchannel/angular-common-components/src/l...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/form-components/service/trim-text-utils/trim-text.service.ts
<filename>projects/angular-common-components/src/lib/form-components/service/trim-text-utils/trim-text.service.ts import { cloneDeep, get, set } from 'lodash'; import { AppFormField, TrimFormFieldType } from '../../model/app-form-model'; import { RichTextUtils } from '../rich-text-utils/rich-text.service'; export clas...
mukesh-openchannel/angular-template-libraries
projects/angular-common-services/src/lib/service/user-role.service.ts
import {Injectable} from '@angular/core'; import {Observable} from 'rxjs'; import {Page} from '../model/api/page.model'; import {HttpRequestService} from './http-request-services'; import {UserRoleResponse} from '../model/api/account-role-model'; import {OcHttpParams} from '../model/api/http-params-encoder-model'; impo...
mukesh-openchannel/angular-template-libraries
src/app-number.stories.ts
<reponame>mukesh-openchannel/angular-template-libraries import { OcCommonLibModule } from '@openchannel/angular-common-components'; import { moduleMetadata } from '@storybook/angular'; import { OcNumberComponent } from '@openchannel/angular-common-components/src/lib/form-components'; import { FormsModule } from '@angul...
mukesh-openchannel/angular-template-libraries
src/oc-password.stories.ts
import { OcCommonLibModule, OcPasswordComponent } from '@openchannel/angular-common-components'; import { moduleMetadata } from '@storybook/angular'; /** List of module dependencies and component declarations. Stored as separate var because they are shared among all stories */ const modules = { imports: [OcCommonL...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/form-components/oc-file-upload/oc-file-upload.component.spec.ts
import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { OcFileUploadComponent } from './oc-file-upload.component'; import { NgModel } from '@angular/forms'; import { CommonModule } from '@angular/common'; import { BrowserModule, By } from '@angular/platform-browser'; import { NgbModul...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/market-components/oc-recommended-apps/oc-recommended-apps.component.spec.ts
<filename>projects/angular-common-components/src/lib/market-components/oc-recommended-apps/oc-recommended-apps.component.spec.ts<gh_stars>0 import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { OcRecommendedAppsComponent } from './oc-recommended-apps.component'; import { By } from '@...
mukesh-openchannel/angular-template-libraries
src/select.stories.ts
import { moduleMetadata } from '@storybook/angular'; import { OcCommonLibModule, OcSelectComponent } from '@openchannel/angular-common-components/src/lib/common-components'; /** * List of module dependencies and component declarations. * Stored as separate var because they are shared among all stories */ const modu...
mukesh-openchannel/angular-template-libraries
projects/angular-common-services/src/lib/service/ownership.service.ts
<reponame>mukesh-openchannel/angular-template-libraries import { Injectable } from '@angular/core'; import { HttpRequestService } from './http-request-services'; import { Observable } from 'rxjs'; import { CreateOwnershipModel, OwnershipModelResponse } from '../model/api/ownership.model'; import { HttpHeaders } from '@...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/form-components/oc-single-form/oc-single-form.component.spec.ts
import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { OcSingleFormComponent } from './oc-single-form.component'; import { FormsModule, ReactiveFormsModule } from '@angular/forms'; import { By } from '@angular/platform-browser'; import { MockButtonComponent, MockCheckboxCompon...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/form-components/oc-dropdown-multi-app/oc-dropdown-multi-app.component.ts
<filename>projects/angular-common-components/src/lib/form-components/oc-dropdown-multi-app/oc-dropdown-multi-app.component.ts import { Component, EventEmitter, forwardRef, Input, OnDestroy, OnInit, Output, TemplateRef } from '@angular/core'; import { Observable, of, Subject } from 'rxjs'; import { remove, isString } fr...
mukesh-openchannel/angular-template-libraries
projects/angular-common-services/src/lib/model/api/custom-content.model.ts
<gh_stars>0 export interface SiteContentResponse { siteId: string; contentId: string; type: string; created: number; lastUpdated: number; customData: any; } export interface SecuritySettingsResponse { /** * The character limit for any string in the request body. * Any request will...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/form-components/oc-form/oc-form-validator.spec.ts
<reponame>mukesh-openchannel/angular-template-libraries import { OcFormValidator } from './oc-form-validator'; import { AbstractControl, FormControl, ValidatorFn } from '@angular/forms'; describe('OcFormValidator', () => { it('[Required] validator with empty objects.', () => { expect(setValidatorAndValidat...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/auth-components/models/signup-router-state.model.ts
/** * State interface to pass to Signup page using Router if we want to show signup feedback page and skip * the first step of signup. */ export interface SignupRouterState { showSignupFeedbackPage: boolean; }
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/common-components/oc-button/oc-button.component.spec.ts
import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { OcButtonComponent } from './oc-button.component'; import { NgxSpinnerModule } from 'ngx-spinner'; describe('OcButtonComponent', () => { let component: OcButtonComponent; let fixture: ComponentFixture<OcButtonComponent>; ...
mukesh-openchannel/angular-template-libraries
src/video-component.stories.ts
<reponame>mukesh-openchannel/angular-template-libraries import { moduleMetadata } from '@storybook/angular'; import { OcCommonLibModule, OcVideoComponent } from '@openchannel/angular-common-components/src/lib/common-components'; import { HttpClient, HttpClientModule } from '@angular/common/http'; import { EmbedVideoSer...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/market-components/oc-app-card/oc-app-card.component.ts
<filename>projects/angular-common-components/src/lib/market-components/oc-app-card/oc-app-card.component.ts import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core'; import { SafeResourceUrl } from '@angular/platform-browser'; import { AppModel, FullAppData } from '@openchannel/angular-common-comp...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/form-components/oc-color/oc-color.component.spec.ts
<reponame>mukesh-openchannel/angular-template-libraries import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { OcColorComponent } from './oc-color.component'; import { FormsModule } from '@angular/forms'; import { ColorPickerModule } from 'ngx-color-picker'; describe('OcColorCompone...
mukesh-openchannel/angular-template-libraries
projects/angular-common-services/src/lib/service/developer-type.service.ts
import { Injectable } from '@angular/core'; import { HttpRequestService } from './http-request-services'; import { Observable } from 'rxjs'; import { DeveloperTypeModel } from '../model/api/developer.model'; import { Page } from '../model/api/page.model'; import { OcHttpParams } from '../model/api/http-params-encoder-m...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/management-components/oc-invite-modal/oc-invite-modal.component.ts
<reponame>mukesh-openchannel/angular-template-libraries import { Component, Input, OnInit } from '@angular/core'; import { FormGroup } from '@angular/forms'; import { isString, merge } from 'lodash'; import { NgbActiveModal } from '@ng-bootstrap/ng-bootstrap'; import { ModalInviteUserModel, ModalUpdateUserModel } from ...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/form-components/model/progress-bar-item.model.ts
export interface FormProgressbarStep { title: string; state: 'pristine' | 'finished' | 'invalid'; }
mukesh-openchannel/angular-template-libraries
src/multiSelectList.stories.ts
import { moduleMetadata } from '@storybook/angular'; import { OcCommonLibModule } from '@openchannel/angular-common-components/src/lib/common-components'; import { OcMultiSelectListComponent } from '@openchannel/angular-common-components/src/lib/form-components'; const modules = { imports: [OcCommonLibModule], }; ...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/common-components/oc-label/oc-label.component.spec.ts
<filename>projects/angular-common-components/src/lib/common-components/oc-label/oc-label.component.spec.ts<gh_stars>0 import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { OcLabelComponent } from './oc-label.component'; describe('OcLabelComponent', () => { let component: OcLabe...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/common-components/oc-video/oc-video.component.spec.ts
import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { OcVideoComponent } from './oc-video.component'; import { HttpClientTestingModule } from '@angular/common/http/testing'; import { EmbedVideoService } from 'ngx-embed-video'; import { NgxSpinnerModule, NgxSpinnerService } from 'ngx...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/common-components/pipe/get-text-by-path.pipe.spec.ts
<gh_stars>0 import { GetTextByPathPipe } from '@openchannel/angular-common-components/src/lib/common-components/pipe/get-text-by-path.pipe'; describe('GetTextByPathPipe', () => { let pipe: GetTextByPathPipe; let value: any; beforeEach(() => { pipe = new GetTextByPathPipe(); value = { ...
mukesh-openchannel/angular-template-libraries
projects/angular-common-services/src/lib/model/api/review.model.ts
<filename>projects/angular-common-services/src/lib/model/api/review.model.ts import { User } from './user.model'; export interface Status { value: string; } export interface UserReviewModel extends Omit<User, 'permissions' | 'roles'> { accountCount: number; } export interface ReviewModel { rating: number...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/form-components/model/dropdown-multi-app.model.ts
import { Observable } from 'rxjs'; import { FullAppData } from '@openchannel/angular-common-components/src/lib/common-components'; export abstract class AppsSearchService { abstract loadDefaultApps(existsAppIDs: string[]): Observable<FullAppData[]>; abstract appsSearch(existsAppIDs: FullAppData[], searchText: ...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/common-components/oc-content-modal/oc-content-modal.component.ts
import { AfterViewInit, Component, ElementRef, Input, TemplateRef, ViewChild } from '@angular/core'; import { NgbActiveModal } from '@ng-bootstrap/ng-bootstrap'; @Component({ selector: 'oc-content-modal', templateUrl: './oc-content-modal.component.html', styleUrls: ['./oc-content-modal.component.css'], }) ...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/form-components/oc-video-url/oc-video-url.component.spec.ts
import { async, ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { OcVideoUrlComponent } from './oc-video-url.component'; import { FormsModule } from '@angular/forms'; import { HttpClientTestingModule } from '@angular/common/http/testing'; import { Observable, of } from 'rxjs'; import { B...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/market-components/oc-review/oc-review.component.spec.ts
import { ComponentFixture, TestBed } from '@angular/core/testing'; import { OcReviewComponent } from './oc-review.component'; import { MockButtonComponent, MockErrorComponent, MockInputComponent, MockLabelComponent, MockRatingComponent, MockTextareaComponent, } from '@openchannel/angular-common...
mukesh-openchannel/angular-template-libraries
src/consent.stories.ts
import { moduleMetadata } from '@storybook/angular'; import { OcCommonLibModule } from '@openchannel/angular-common-components/src/lib/common-components'; import { OcConsentComponent } from '@openchannel/angular-common-components'; import { action } from '@storybook/addon-actions'; const modules = { imports: [OcCo...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/common-components/validators/white-space-validator.ts
import { Directive } from '@angular/core'; import { FormControl, NG_VALIDATORS, ValidationErrors, Validator } from '@angular/forms'; @Directive({ selector: '[ocWhiteSpaceValidator]', providers: [{ provide: NG_VALIDATORS, useExisting: WhiteSpaceValidatorDirective, multi: true }], }) export class WhiteSpaceValid...
mukesh-openchannel/angular-template-libraries
projects/angular-common-services/src/lib/model/api/market.model.ts
<gh_stars>0 export interface MarketModel { marketplaceId: string; customerId: string; name: string; type: string; previewAppUrl: string; viewAppUrl: string; } export type AuthType = 'EXTERNAL' | 'AUTH_20' | 'SAML_20'; export interface SiteAuthConfig { type: AuthType; clientId: string; ...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/common-components/validators/checkbox-required.directive.ts
import { Directive } from '@angular/core'; import { FormControl, NG_VALIDATORS, ValidationErrors, Validator } from '@angular/forms'; @Directive({ selector: '[ocCheckboxRequired]', providers: [{ provide: NG_VALIDATORS, useExisting: CheckboxRequiredDirective, multi: true }], }) export class CheckboxRequiredDirec...
mukesh-openchannel/angular-template-libraries
projects/angular-common-components/src/lib/market-components/oc-app-list-grid/oc-app-list-grid.component.spec.ts
<filename>projects/angular-common-components/src/lib/market-components/oc-app-list-grid/oc-app-list-grid.component.spec.ts import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { OcAppListGridComponent } from './oc-app-list-grid.component'; import { By } from '@angular/platform-browser...
lukemwillis/koinos-as-sdk-examples
token/assembly/Token.ts
import { authority, Base58, Protobuf, System } from "koinos-as-sdk"; import { token } from "./proto/token"; import { State } from "./State"; export class Token { _name: string = "Token"; _symbol: string = "TKN"; _decimals: u32 = 8; _contractId: Uint8Array; _state: State; constructor() { this._contrac...
lukemwillis/koinos-as-sdk-examples
chat/assembly/Chat.ts
<filename>chat/assembly/Chat.ts import { Base58, StringBytes, System, value } from "koinos-as-sdk"; import { chat } from "./proto/chat"; import { State } from "./State"; export class Chat { contractId: Uint8Array; state: State; constructor() { this.contractId = System.getContractId(); this.state = new ...
lukemwillis/koinos-as-sdk-examples
calculator/assembly/Calculator.ts
import { calculator } from "./proto/calculator"; export class Calculator { add(args: calculator.add_arguments): calculator.add_result { const x = args.x; const y = args.y; const res = new calculator.add_result(); res.value = x + y; return res; } sub(args: calculator.sub_arguments): calcula...
lukemwillis/koinos-as-sdk-examples
immutable/assembly/Immutable.ts
<reponame>lukemwillis/koinos-as-sdk-examples<gh_stars>0 import { authority } from "koinos-as-sdk"; import { immutable } from "./proto/immutable"; export class Immutable { authorize(args: authority.authorize_arguments): authority.authorize_result { // return false when trying to upload a new version of the contra...
lukemwillis/koinos-as-sdk-examples
staking/assembly/Token.ts
import { Protobuf, System } from "koinos-as-sdk"; import { token } from "./proto/token"; enum entries { name_entry = 0x82a3537f, symbol_entry = 0xb76a7ca1, decimals_entry = 0xee80fd2f, total_supply_entry = 0xb0da3934, balance_of_entry = 0x5c721497, transfer_entry = 0x27f576ca, mint_entry = 0xdc6f17bb } ...
lukemwillis/koinos-as-sdk-examples
staking/assembly/Staking.ts
<filename>staking/assembly/Staking.ts import { Base58, Protobuf, System } from "koinos-as-sdk"; import { staking } from "./proto/staking"; import { State } from "./State"; import { Token } from "./Token"; const TOKEN_CONTRACT_ID = Base58.decode('19JntSm8pSNETT9aHTwAUHC5RMoaSmgZPJ'); export class Staking { _contract...
lukemwillis/koinos-as-sdk-examples
token/assembly/State.ts
import { chain, System } from "koinos-as-sdk"; import { token } from "./proto/token"; const SUPPLY_SPACE_ID = 0; const SUPPLY_KEY = new Uint8Array(0); const BALANCE_SPACE_ID = 1; export class State { contractId: Uint8Array; supplySpace: chain.object_space; balanceSpace: chain.object_space; constructor(contra...
lukemwillis/koinos-as-sdk-examples
chat/assembly/State.ts
<filename>chat/assembly/State.ts import { chain, System } from "koinos-as-sdk"; import { chat } from "./proto/chat"; const METADATA_SPACE_ID = 0; const METADATA_OBJECT_ID = "0"; const MESSAGES_SPACE_ID = 1; export class State { contractId: Uint8Array; metadataSpace: chain.object_space; messagesSpace: chain.obje...
ConclaveTeam/ConclaveFront
src/components/atoms/index.ts
export { default as Button } from './Button.vue' export { default as Link } from './Link.vue'
ConclaveTeam/ConclaveFront
tests/unit/example.spec.ts
<gh_stars>0 import { shallowMount } from '@vue/test-utils' import { Button } from '@/components/atoms' describe('Button atom', () => { it('Renders test passed into via slot', () => { const msg = 'button text' const wrapped = `<span>${msg}</span>` const wrapper = shallowMount(Button, { scopedSlots: ...
mtolley/seeker-github-actions
src/seeker-compliance-reporting.ts
// seeker-compliance-reporting // /////////////////////////// // // This action encapsulates the seeker-compliance-report and check-seeker-compliance // actions. It checks Seeker Policy compliance and depending on the input values // will do one or both of the following: // // * Generate the Compliance Report PDF and u...
mtolley/seeker-github-actions
src/check-seeker-compliance.ts
// check-seeker-compliance.ts // ////////////////////////// // // Calls the Seeker API for the specified project to determine whether that // project is currently in compliance with any assigned Compliance Policies // or not. The Compliance status is written to the action output. Optionally, // if failBuildIfNotInCompl...
mtolley/seeker-github-actions
src/download-seeker-agent.ts
<filename>src/download-seeker-agent.ts // download-seeker-agent.ts // //////////////////////// // // Downloads the Seeker agent installer script from the Seeker API and // runs it. This will download the agent binary itself and display instructions // for using it in the build output. import * as core from '@actions/c...