@alauda-fe/dynamic-plugin-shared 0.0.1-alpha.13 → 0.0.1-alpha.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/index.d.ts +0 -2
- package/components/resource-multi-select/component.d.ts +2 -2
- package/esm2022/array-form-table/form/component.mjs +2 -2
- package/esm2022/array-form-table/key-value-form/component.mjs +2 -2
- package/esm2022/array-form-table/key-value-table/component.mjs +2 -2
- package/esm2022/async-data/async-data-loader.mjs +2 -2
- package/esm2022/async-data/page-state/component.mjs +2 -3
- package/esm2022/code-editor/resource-yaml-display/component.mjs +2 -2
- package/esm2022/components/current-time/component.mjs +2 -2
- package/esm2022/components/date-range-picker/component.mjs +2 -2
- package/esm2022/components/disabled-container/disabled-container.component.mjs +2 -2
- package/esm2022/components/foldable-item-in-table/component.mjs +2 -2
- package/esm2022/components/help-document/component.mjs +2 -2
- package/esm2022/components/index.mjs +1 -3
- package/esm2022/components/list-display/component.mjs +2 -2
- package/esm2022/components/multi-search/action-input/component.mjs +3 -3
- package/esm2022/components/multi-search/form/component.mjs +2 -2
- package/esm2022/components/multi-search/multi-search-tags/component.mjs +2 -2
- package/esm2022/components/mutable/mosaic/component.mjs +2 -2
- package/esm2022/components/page-guard/component/component.mjs +2 -3
- package/esm2022/components/password-input/component.mjs +2 -2
- package/esm2022/components/pod-status/component.mjs +2 -2
- package/esm2022/components/relative-time/component.mjs +2 -2
- package/esm2022/components/resource-label/component.mjs +2 -2
- package/esm2022/components/resource-multi-select/component.mjs +3 -3
- package/esm2022/components/select-prefix-label/directive.mjs +2 -2
- package/esm2022/components/status-icon/status-icon.component.mjs +2 -2
- package/esm2022/components/table/component.mjs +4 -3
- package/esm2022/components/tags-label/component.mjs +3 -3
- package/esm2022/components/text-with-url/component.mjs +2 -2
- package/esm2022/components/workload-status/component.mjs +2 -2
- package/esm2022/components/zero-state/zero-state.component.mjs +2 -3
- package/esm2022/directives/disabled.directive.mjs +2 -2
- package/esm2022/directives/effect-directive/event.directive.mjs +2 -2
- package/esm2022/directives/readonly-field.directive.mjs +3 -3
- package/esm2022/directives/value-trace.directive.mjs +2 -2
- package/esm2022/form/base-form-container.mjs +2 -3
- package/esm2022/form/errors-mapper/errors-mapper-component/component.mjs +2 -2
- package/esm2022/form/errors-mapper/errors-mapper.directive.mjs +2 -2
- package/esm2022/form/validators/async-function-validator.directive.mjs +2 -2
- package/esm2022/form/validators/function-validator.directive.mjs +2 -2
- package/esm2022/form/validators/not-be-validator.directive.mjs +2 -2
- package/esm2022/form/validators/one-of-validator.directive.mjs +2 -2
- package/esm2022/form/validators/utils.mjs +3 -2
- package/esm2022/k8s-resource-list/footer/component.mjs +2 -2
- package/esm2022/k8s-resource-list/k8s-resource-list.mjs +2 -2
- package/esm2022/k8s-resource-list/k8s-resource-paged-list.mjs +2 -2
- package/esm2022/page-deactivate/deactivate.directive.mjs +2 -2
- package/esm2022/page-deactivate/deactivate.service.mjs +2 -2
- package/esm2022/pipes/index.mjs +1 -10
- package/esm2022/services/form-row-duplicate/form-row-duplicate.service.mjs +2 -2
- package/esm2022/services/yaml-util.service.mjs +3 -2
- package/esm2022/types/common.mjs +1 -1
- package/esm2022/utils/common.mjs +3 -60
- package/esm2022/utils/disabled-state.mjs +2 -2
- package/esm2022/utils/index.mjs +1 -7
- package/esm2022/utils/unit.mjs +3 -2
- package/esm2022/utils/workspace.mjs +1 -1
- package/esm2022/utils/yaml.mjs +1 -16
- package/fesm2022/alauda-fe-dynamic-plugin-shared.mjs +66 -1080
- package/fesm2022/alauda-fe-dynamic-plugin-shared.mjs.map +1 -1
- package/package.json +1 -1
- package/pipes/index.d.ts +0 -9
- package/styles/lib.scss +1 -1
- package/styles/mixins.scss +2 -2
- package/styles/var.scss +1 -1
- package/types/common.d.ts +1 -5
- package/utils/common.d.ts +1 -13
- package/utils/index.d.ts +0 -6
- package/utils/workspace.d.ts +1 -1
- package/utils/yaml.d.ts +0 -5
- package/components/loading-mask/loading-mask.component.d.ts +0 -13
- package/components/namespace-selector/component.d.ts +0 -28
- package/components/namespace-selector/constants.d.ts +0 -2
- package/components/namespace-selector/index.d.ts +0 -3
- package/components/namespace-selector/namespace-list/component.d.ts +0 -46
- package/components/namespace-selector/types.d.ts +0 -5
- package/esm2022/components/loading-mask/loading-mask.component.mjs +0 -35
- package/esm2022/components/namespace-selector/component.mjs +0 -126
- package/esm2022/components/namespace-selector/constants.mjs +0 -3
- package/esm2022/components/namespace-selector/index.mjs +0 -4
- package/esm2022/components/namespace-selector/namespace-list/component.mjs +0 -191
- package/esm2022/components/namespace-selector/types.mjs +0 -2
- package/esm2022/pipes/field-not-available.pipe.mjs +0 -25
- package/esm2022/pipes/img-header.pipe.mjs +0 -18
- package/esm2022/pipes/img-theme.pipe.mjs +0 -38
- package/esm2022/pipes/keyvalue.pipe.mjs +0 -20
- package/esm2022/pipes/parse-json.pipe.mjs +0 -22
- package/esm2022/pipes/pure.pipe.mjs +0 -26
- package/esm2022/pipes/safe.pipe.mjs +0 -49
- package/esm2022/pipes/sanitize.pipe.mjs +0 -31
- package/esm2022/pipes/time.pipe.mjs +0 -113
- package/esm2022/utils/browser.mjs +0 -21
- package/esm2022/utils/cache-store.mjs +0 -83
- package/esm2022/utils/decorators.mjs +0 -137
- package/esm2022/utils/observable.mjs +0 -32
- package/esm2022/utils/operators.mjs +0 -38
- package/esm2022/utils/router.mjs +0 -20
- package/pipes/field-not-available.pipe.d.ts +0 -13
- package/pipes/img-header.pipe.d.ts +0 -7
- package/pipes/img-theme.pipe.d.ts +0 -13
- package/pipes/keyvalue.pipe.d.ts +0 -9
- package/pipes/parse-json.pipe.d.ts +0 -7
- package/pipes/pure.pipe.d.ts +0 -17
- package/pipes/safe.pipe.d.ts +0 -10
- package/pipes/sanitize.pipe.d.ts +0 -10
- package/pipes/time.pipe.d.ts +0 -40
- package/utils/browser.d.ts +0 -4
- package/utils/cache-store.d.ts +0 -35
- package/utils/decorators.d.ts +0 -14
- package/utils/observable.d.ts +0 -5
- package/utils/operators.d.ts +0 -22
- package/utils/router.d.ts +0 -3
package/pipes/sanitize.pipe.d.ts
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { PipeTransform } from '@angular/core';
|
|
2
|
-
import { DomSanitizer, SafeHtml } from '@angular/platform-browser';
|
|
3
|
-
import * as i0 from "@angular/core";
|
|
4
|
-
export declare class SanitizePipe implements PipeTransform {
|
|
5
|
-
private readonly sanitizer;
|
|
6
|
-
constructor(sanitizer: DomSanitizer);
|
|
7
|
-
transform(value: string, type?: 'html' | 'url'): SafeHtml;
|
|
8
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<SanitizePipe, never>;
|
|
9
|
-
static ɵpipe: i0.ɵɵPipeDeclaration<SanitizePipe, "aclSanitize", true>;
|
|
10
|
-
}
|
package/pipes/time.pipe.d.ts
DELETED
|
@@ -1,40 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @packageDocumentation
|
|
3
|
-
* @module utils
|
|
4
|
-
*/
|
|
5
|
-
import { TimeService, TranslateService } from '@alauda-fe/dynamic-plugin-sdk';
|
|
6
|
-
import { ChangeDetectorRef, OnDestroy, PipeTransform } from '@angular/core';
|
|
7
|
-
import { ConfigType } from 'dayjs';
|
|
8
|
-
import * as i0 from "@angular/core";
|
|
9
|
-
export declare class RelativeTimePipe implements PipeTransform, OnDestroy {
|
|
10
|
-
private readonly cdr;
|
|
11
|
-
private readonly time;
|
|
12
|
-
private readonly translate;
|
|
13
|
-
private readonly destroy$$;
|
|
14
|
-
private timerId;
|
|
15
|
-
constructor(cdr: ChangeDetectorRef, time: TimeService, translate: TranslateService);
|
|
16
|
-
ngOnDestroy(): void;
|
|
17
|
-
transform(value: ConfigType): string;
|
|
18
|
-
protected checkDistance(distance: number): void;
|
|
19
|
-
private startTimer;
|
|
20
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<RelativeTimePipe, never>;
|
|
21
|
-
static ɵpipe: i0.ɵɵPipeDeclaration<RelativeTimePipe, "aclRelativeTime", true>;
|
|
22
|
-
}
|
|
23
|
-
export declare abstract class DateTimePipe implements PipeTransform {
|
|
24
|
-
private readonly time;
|
|
25
|
-
abstract format: string;
|
|
26
|
-
constructor(time: TimeService);
|
|
27
|
-
transform(value: ConfigType, utc?: boolean): string;
|
|
28
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<DateTimePipe, never>;
|
|
29
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<DateTimePipe>;
|
|
30
|
-
}
|
|
31
|
-
export declare class StandardTimePipe extends DateTimePipe implements PipeTransform {
|
|
32
|
-
format: string;
|
|
33
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<StandardTimePipe, never>;
|
|
34
|
-
static ɵpipe: i0.ɵɵPipeDeclaration<StandardTimePipe, "aclStandardTime", true>;
|
|
35
|
-
}
|
|
36
|
-
export declare class StandardDatePipe extends DateTimePipe implements PipeTransform {
|
|
37
|
-
format: string;
|
|
38
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<StandardDatePipe, never>;
|
|
39
|
-
static ɵpipe: i0.ɵɵPipeDeclaration<StandardDatePipe, "aclStandardDate", true>;
|
|
40
|
-
}
|
package/utils/browser.d.ts
DELETED
package/utils/cache-store.d.ts
DELETED
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import { MonoTypeOperatorFunction, Observable } from 'rxjs';
|
|
2
|
-
export declare class CacheStore<P, V> {
|
|
3
|
-
private readonly fetcher;
|
|
4
|
-
private readonly share;
|
|
5
|
-
private readonly validator;
|
|
6
|
-
private readonly store;
|
|
7
|
-
constructor({ fetcher, share, validator }: CacheStoreOptions<P, V>);
|
|
8
|
-
fetchState(params: P): Observable<CacheLoadState<V>>;
|
|
9
|
-
fetch(params: P): Observable<V>;
|
|
10
|
-
refetch(params: P): void;
|
|
11
|
-
refetchAll(): void;
|
|
12
|
-
get(params: P): Cache<V>;
|
|
13
|
-
has(params: P): boolean;
|
|
14
|
-
delete(params: P): void;
|
|
15
|
-
clear(): void;
|
|
16
|
-
forEach: (callbackfn: (value: Cache<V>, key: P, map: Map<P, Cache<V>>) => void, thisArg?: any) => void;
|
|
17
|
-
entries: () => IterableIterator<[P, Cache<V>]>;
|
|
18
|
-
values: () => IterableIterator<Cache<V>>;
|
|
19
|
-
keys: () => IterableIterator<P>;
|
|
20
|
-
}
|
|
21
|
-
export interface CacheStoreOptions<P, V> {
|
|
22
|
-
fetcher: (params: P) => Observable<V>;
|
|
23
|
-
share?: <T>() => MonoTypeOperatorFunction<T>;
|
|
24
|
-
validator?: (loadState: CacheLoadState<V>) => boolean;
|
|
25
|
-
}
|
|
26
|
-
export interface CacheLoadState<V> {
|
|
27
|
-
state: 'loading' | 'loaded' | 'loadFailed';
|
|
28
|
-
result?: V;
|
|
29
|
-
error?: unknown;
|
|
30
|
-
}
|
|
31
|
-
export interface Cache<V> {
|
|
32
|
-
loadState: Observable<CacheLoadState<V>>;
|
|
33
|
-
refetch: () => void;
|
|
34
|
-
finish: () => void;
|
|
35
|
-
}
|
package/utils/decorators.d.ts
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @packageDocumentation
|
|
3
|
-
* @module utils
|
|
4
|
-
*/
|
|
5
|
-
import { DebounceSettings, DebouncedFunc } from 'lodash-es';
|
|
6
|
-
import { ObservableType } from '../types';
|
|
7
|
-
export declare function ValueHook<T = any, K extends keyof T = any>(setter?: (this: T, value?: T[K]) => boolean | void, getter?: (this: T, value?: T[K]) => T[K], afterSetter?: (this: T, value?: T[K]) => void): (target: T, propertyKey: K) => void;
|
|
8
|
-
export type ObservableInputPropertyKey<T> = T extends `${infer R}$` ? ObservableInputPropertyKey<R> : T;
|
|
9
|
-
export declare function ObservableInput<T = any, OK extends keyof T = any, K extends keyof T = ObservableInputPropertyKey<OK> & keyof T>(propertyKey?: K | boolean, initialValue?: ObservableType<T[OK]>): (target: T, oPropertyKey: OK) => void;
|
|
10
|
-
/**
|
|
11
|
-
* @see https://github.com/NoHomey/bind-decorator
|
|
12
|
-
*/
|
|
13
|
-
export declare function bind<T extends Function>(_target: object, propertyKey: string, descriptor: TypedPropertyDescriptor<T>): TypedPropertyDescriptor<T> | void;
|
|
14
|
-
export declare function debounceFn<T extends (...args: any) => any>(delay?: number, options?: DebounceSettings): (_target: object, propertyKey: string, descriptor: TypedPropertyDescriptor<T>) => TypedPropertyDescriptor<DebouncedFunc<T>> | void;
|
package/utils/observable.d.ts
DELETED
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import { DestroyRef } from '@angular/core';
|
|
2
|
-
import { Observable } from 'rxjs';
|
|
3
|
-
export declare const createPollObservable: <TResult>(fetch$: Observable<TResult>, pollIn: number | Observable<number>) => Observable<TResult>;
|
|
4
|
-
export declare function onDestroy(destroyRef?: DestroyRef): Observable<void>;
|
|
5
|
-
export declare const tapSkip: <T>(nEmissions: number, callback: (args: T) => void) => (source$: Observable<T>) => Observable<T>;
|
package/utils/operators.d.ts
DELETED
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @packageDocumentation
|
|
3
|
-
* @module utils
|
|
4
|
-
*/
|
|
5
|
-
import { DestroyRef } from '@angular/core';
|
|
6
|
-
import { MonoTypeOperatorFunction, Observable, SchedulerLike, TimestampProvider } from 'rxjs';
|
|
7
|
-
export type PublishRefConfig<T> = number | (import('rxjs/internal/operators/share').ShareConfig<T> & {
|
|
8
|
-
bufferSize?: number;
|
|
9
|
-
windowTime?: number;
|
|
10
|
-
timestampProvider?: TimestampProvider;
|
|
11
|
-
});
|
|
12
|
-
export declare const publishRef: <T>(bufferSizeOrConfig?: PublishRefConfig<T>) => MonoTypeOperatorFunction<T>;
|
|
13
|
-
export declare const shareUntil: <T>(destroy$: Observable<unknown>, bufferSize?: number, windowTime?: number, scheduler?: SchedulerLike) => import("rxjs").UnaryFunction<Observable<T>, Observable<T>>;
|
|
14
|
-
export declare const skipError: <T, R = never>(mapped?: R | Observable<R>, debug?: boolean) => import("rxjs").OperatorFunction<T, T | R>;
|
|
15
|
-
export declare const catchPromise: <T, R = never>(promise: Promise<T>, mapped?: R | Observable<R>) => Observable<T | R>;
|
|
16
|
-
declare const NULL: unique symbol;
|
|
17
|
-
export declare const startWithCondition: <T>(condition: boolean, value: T) => (source: Observable<T>) => Observable<typeof NULL | T>;
|
|
18
|
-
export declare const shareUntilDestroyed: <T>(destroyRef?: DestroyRef, bufferSize?: number, windowTime?: number, scheduler?: SchedulerLike) => import("rxjs").UnaryFunction<Observable<T>, Observable<T>>;
|
|
19
|
-
export declare const safePluck: (...properties: Array<string | number>) => import("rxjs").UnaryFunction<Observable<unknown>, Observable<any>>;
|
|
20
|
-
export declare function switchTap<T, R>(next: (x: T) => Observable<R>): MonoTypeOperatorFunction<T>;
|
|
21
|
-
export declare function switchTap<R>(observable: Observable<R>): MonoTypeOperatorFunction<R>;
|
|
22
|
-
export {};
|
package/utils/router.d.ts
DELETED