Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@hikarix/core

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@hikarix/core - npm Package Compare versions

Comparing version 0.4.4 to 0.4.5

4

app/app.module.d.ts
import { DynamicModule } from '@nestjs/common';
import { IPlatformResourceProvider } from "../proto/platform-resource";
import { HiKariCoreHostConfig } from "../proto/config";
export declare type HiKariAppModulePlatResOptType = IPlatformResourceProvider[] | ((cfg: HiKariCoreHostConfig) => (IPlatformResourceProvider[]));
export interface HiKariAppModuleConfig {
repoItemControllers?: any[];
platformResources?: IPlatformResourceProvider[];
platformResources?: HiKariAppModulePlatResOptType;
}

@@ -7,0 +9,0 @@ export declare class HiKariAppModule {

@@ -19,2 +19,3 @@ "use strict";

const platform_resource_1 = require("../proto/platform-resource");
const config_1 = require("../proto/config");
let HiKariAppModule = HiKariAppModule_1 = class HiKariAppModule {

@@ -21,0 +22,0 @@ static forRoot(appModuleConfig) {

@@ -1,2 +0,2 @@

import { DynamicModule } from "@nestjs/common";
import { DynamicModule } from '@nestjs/common';
import { HiKariAppModuleConfig } from "./app.module";

@@ -3,0 +3,0 @@ export declare class HiKariAppPlatformResourcesModule {

@@ -14,11 +14,30 @@ "use strict";

const app_module_1 = require("./app.module");
const config_1 = require("../proto/config");
const platform_resource_2 = require("../proto/platform-resource");
const app_config_module_1 = require("./app.config.module");
function platformResourcesIsFunction(provider) {
return provider instanceof Function;
}
let HiKariAppPlatformResourcesModule = HiKariAppPlatformResourcesModule_1 = class HiKariAppPlatformResourcesModule {
static forModuleConfig(appModuleConfig) {
let managerProvider;
const resourcesProvider = appModuleConfig.platformResources;
if (platformResourcesIsFunction(resourcesProvider)) {
managerProvider = {
provide: platform_resource_1.HiKariPlatformResourceManager,
useFactory: (cfg) => platform_resource_1.HiKariPlatformResourceManager.create(resourcesProvider(cfg)),
inject: ['host-config'],
};
}
else {
managerProvider = {
provide: platform_resource_1.HiKariPlatformResourceManager,
useValue: platform_resource_1.HiKariPlatformResourceManager.create(resourcesProvider || []),
};
}
return {
module: HiKariAppPlatformResourcesModule_1,
imports: [app_config_module_1.HiKariAppHostConfigModule],
providers: [
{
provide: platform_resource_1.HiKariPlatformResourceManager,
useValue: platform_resource_1.HiKariPlatformResourceManager.create(appModuleConfig.platformResources || []),
},
managerProvider,
],

@@ -25,0 +44,0 @@ exports: [platform_resource_1.HiKariPlatformResourceManager]

import { HiKariRepoKeyDto } from "./repoKeyDto";
import { ObjectDict } from "../../../proto/generic";
export declare class HiKariGetRepoItemsRequest extends HiKariRepoKeyDto {
searchString: string;
query: string;
constraints: ObjectDict<any>;

@@ -6,0 +6,0 @@ }

@@ -9,3 +9,3 @@ "use strict";

super(...arguments);
this.searchString = '';
this.query = '';
this.constraints = {};

@@ -12,0 +12,0 @@ }

@@ -44,3 +44,3 @@ "use strict";

data: yield client.searchClient.search({
query: req.searchString,
query: req.query,
get: k => req[k]

@@ -47,0 +47,0 @@ }, undefined)

@@ -28,3 +28,3 @@ "use strict";

function getConfiguration() {
let port = process.env["HIKARI_BACKEND_PORT"];
let port = process.env['HIKARI_BACKEND_PORT'];
if (port === undefined) {

@@ -36,3 +36,3 @@ port = 11301;

}
let logs_path = process.env["HIKARI_BACKEND_LOGS_PATH"];
let logs_path = process.env['HIKARI_BACKEND_LOGS_PATH'];
if (logs_path === undefined) {

@@ -39,0 +39,0 @@ logs_path = "logs";

@@ -1,1 +0,1 @@

export declare const hiKariAppVersion = "0.4.4";
export declare const hiKariAppVersion = "0.4.5";

@@ -9,3 +9,5 @@ "use strict";

const defaultHiKariCoreHostConfig = {
repo: {}
repo: {},
platformResource: {},
global: {}
};

@@ -12,0 +14,0 @@ function readHiKariHostConfig(hostCfgPath) {

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.hiKariAppVersion = void 0;
exports.hiKariAppVersion = '0.4.4';
exports.hiKariAppVersion = '0.4.5';
//# sourceMappingURL=config.js.map
{
"name": "@hikarix/core",
"version": "0.4.4",
"version": "0.4.5",
"description": "hikari-core is the backend of HiKari",

@@ -5,0 +5,0 @@ "repository": "https://github.com/Myriad-Dreamin/hikari-core",

import { ObjectDict } from "./generic";
export interface HiKariCoreHostConfig<T = unknown> {
export interface HiKariCoreHostConfig<T = unknown, P = unknown, G = unknown> {
repo: T | ObjectDict<any>;
platformResource: P | ObjectDict<any>;
global: G | ObjectDict<any>;
}

@@ -38,7 +38,7 @@ /// <reference types="node" />

export interface IAlbumName {
source: AlbumNameSource;
source: string;
name: string;
}
export interface IAccessPath {
type: AccessPathType;
type: string;
path: string;

@@ -58,3 +58,3 @@ }

mainName: string;
mainNameSource: AlbumNameSource;
mainNameSource: string;
alternativeNames: IAlbumName[];

@@ -61,0 +61,0 @@ accessPaths: IAccessPath[];

@@ -42,2 +42,5 @@ import { EnumRepoEntitiesKey, EnumRepoEntitiesMeta, EnumRepoEntityLoadMethodKey, EnumRepoEntityLoadMethodsMeta } from "./repo-item";

forceUpdate?: boolean;
part?: string[];
page_number?: number;
page_size?: number;
get(key: string): any | undefined;

@@ -56,3 +59,3 @@ }

}
export interface ImportAlbumContext<Env = ObjectDict<any>, K extends EnumRepoEntitiesKey = EnumRepoEntitiesKey, M extends EnumRepoEntitiesMeta = EnumRepoEntitiesMeta> extends IHiKariRepoWorkContext<Env> {
export interface IHiKariImportItemsContext<Env = ObjectDict<any>, K extends EnumRepoEntitiesKey = EnumRepoEntitiesKey, M extends EnumRepoEntitiesMeta = EnumRepoEntitiesMeta> extends IHiKariRepoWorkContext<Env> {
sourceManager: IHiKariSourceManager<K, M>;

@@ -62,4 +65,4 @@ }

export interface IHiKariRepositoryImportClient<T, Opts = any, Res = any> {
import(items: T[], opts: Opts, importContext: ImportAlbumContext): Promise<Res>;
importOne(items: T, opts: Opts, importContext: ImportAlbumContext): Promise<Res>;
import(items: T[], opts: Opts, importContext: IHiKariImportItemsContext): Promise<Res>;
importOne(items: T, opts: Opts, importContext: IHiKariImportItemsContext): Promise<Res>;
}

@@ -108,10 +111,11 @@ export interface IHiKariRepositoryReadClient<T> {

}
export interface RepoServiceOps<T> {
readonly description: string;
export declare abstract class RepoServiceOps<T> {
readonly protocolPrefixedUUID: string;
readonly protocolKey: string;
readonly description: string;
readonly managingEntity: EnumRepoEntitiesKey | string;
accessDoc(language: string): RepoServiceOpsDoc | undefined;
normalizeScopeId(scope: string, scopeId: string): string;
createClient(scope: string, scopeId: string, opts: HiKariCoreHostConfig, resourceManager: IPlatformResourceManager): Promise<IHiKariRepositoryClient<T>>;
protected constructor(protocolPrefixedUUID: string, protocolKey: string, description: string);
accessDoc(): RepoServiceOpsDoc | undefined;
abstract normalizeScopeId(scope: string, scopeId: string): string;
abstract createClient(scope: string, scopeId: string, opts: HiKariCoreHostConfig, resourceManager: IPlatformResourceManager): Promise<IHiKariRepositoryClient<T>>;
returnClient(client: IHiKariRepositoryClient<T>): Promise<void>;

@@ -118,0 +122,0 @@ }

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.HiKariSourceManagerCreateItemFromIIdApis = void 0;
exports.RepoServiceOps = exports.HiKariSourceManagerCreateItemFromIIdApis = void 0;
const repo_item_1 = require("./repo-item");

@@ -17,2 +17,18 @@ const generic_1 = require("./generic");

exports.HiKariSourceManagerCreateItemFromIIdApis = HiKariSourceManagerCreateItemFromIIdApis;
class RepoServiceOps {
constructor(protocolPrefixedUUID, protocolKey, description) {
this.protocolPrefixedUUID = protocolPrefixedUUID;
this.protocolKey = protocolKey;
this.description = description;
this.managingEntity = 'unknownEntity';
}
accessDoc() {
return undefined;
}
returnClient(client) {
semantic_1.used(client);
return Promise.resolve(undefined);
}
}
exports.RepoServiceOps = RepoServiceOps;
//# sourceMappingURL=rsi.js.map

@@ -1,2 +0,2 @@

import { IHiKariRepositoryClient, IHiKariRepositorySearchClient, IHiKariRepositorySearchResult, RepoClientSearchItemsOpts, RepoServiceOps, RepoServiceOpsDoc } from "../../proto/rsi";
import { IHiKariRepositoryClient, IHiKariRepositorySearchClient, IHiKariRepositorySearchResult, RepoClientSearchItemsOpts, RepoServiceOps } from "../../proto/rsi";
import { EnumRepoEntitiesKey, EnumRepoEntitiesMeta } from "../../proto/repo-item";

@@ -20,3 +20,3 @@ import { IHiKariSearchContext } from "../../proto/rsi";

}
export declare class RepoTransformService<K extends EnumRepoEntitiesKey, T = EnumRepoEntitiesMeta[K]> implements RepoServiceOps<T> {
export declare class RepoTransformService<K extends EnumRepoEntitiesKey, T = EnumRepoEntitiesMeta[K]> extends RepoServiceOps<T> implements RepoServiceOps<T> {
private readonly transformsDict;

@@ -33,6 +33,4 @@ readonly description: string;

});
accessDoc(): RepoServiceOpsDoc | undefined;
normalizeScopeId(scope: string, scopeId: string): string;
createClient(scope: string, scopeId: string): Promise<IHiKariRepositoryClient<T>>;
returnClient(): Promise<void>;
}

@@ -39,0 +37,0 @@ declare function createHiKariTransformSearchClient<T>(firstTransformation: IRepoItemSearchTransformation<T>, restTransformations?: IRepoItemSearchTransformation[]): TransformSearchClient<T>;

@@ -40,7 +40,6 @@ "use strict";

}
class RepoTransformService {
class RepoTransformService extends rsi_1.RepoServiceOps {
constructor(managingEntity, overrideProtocolKey = undefined, transformsDict) {
super('', '', description);
this.transformsDict = transformsDict;
this.description = description;
this.protocolPrefixedUUID = '';
if (overrideProtocolKey) {

@@ -55,7 +54,3 @@ this.protocolKey = overrideProtocolKey;

}
this.managingEntity = managingEntity;
}
accessDoc() {
return undefined;
}
normalizeScopeId(scope, scopeId) {

@@ -75,5 +70,2 @@ return scopeId;

}
returnClient() {
return Promise.resolve(undefined);
}
}

@@ -80,0 +72,0 @@ exports.RepoTransformService = RepoTransformService;

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc