mirror of
https://github.com/Unleash/unleash.git
synced 2024-11-01 19:07:38 +01:00
92f3f8af08
* feat: add env * fix: create environment form * feat: create environment * feat: add deletion protection * fix: lift up state * feat: add ability to update environment * fix: remove env reset * fix: remove link * feat: add drag and drop sorting * fix: remove unused imports * feat: add methods to toggle env on/off * feat: only make api call on drop * fix: disabled text * fix: add disabled indicator * fix: add edit env payload * fix: add E flag * fix: cleanup * fix: update snapshots * fix: remove useFeature * fix: change property to errorText * fix: update tests * fix: change menu * fix: update snapshots * feat: toggle view v2 * fix: handle error on sort order api call * fix: remove unused import * fix: useFeature * fix: update tests * fix: console logs * fix: use try catch * fix: update snapshots
52 lines
974 B
TypeScript
52 lines
974 B
TypeScript
import { IStrategy } from './strategy';
|
|
|
|
export interface IFeatureToggleListItem {
|
|
type: string;
|
|
name: string;
|
|
environments: IEnvironments[];
|
|
}
|
|
|
|
export interface IEnvironments {
|
|
name: string;
|
|
displayName: string;
|
|
enabled: boolean;
|
|
}
|
|
|
|
export interface IFeatureToggle {
|
|
stale: boolean;
|
|
archived: boolean;
|
|
createdAt: string;
|
|
lastSeenAt: string;
|
|
description: string;
|
|
environments: IFeatureEnvironment[];
|
|
name: string;
|
|
project: string;
|
|
type: string;
|
|
variants: IFeatureVariant[];
|
|
}
|
|
|
|
export interface IFeatureEnvironment {
|
|
name: string;
|
|
enabled: boolean;
|
|
strategies: IStrategy[];
|
|
}
|
|
|
|
export interface IFeatureVariant {
|
|
name: string;
|
|
stickiness: string;
|
|
weight: number;
|
|
weightType: string;
|
|
overrides: IOverride[];
|
|
payload?: IPayload;
|
|
}
|
|
|
|
export interface IOverride {
|
|
contextName: string;
|
|
values: string[];
|
|
}
|
|
|
|
export interface IPayload {
|
|
name: string;
|
|
value: string;
|
|
}
|