From 3246bd4be35c87e99be5e32efd8cddaac91ce911 Mon Sep 17 00:00:00 2001 From: Mike Donnalley Date: Fri, 16 Aug 2024 12:26:03 -0600 Subject: [PATCH] fix: remove jsonEnabled prop --- src/index.ts | 2 +- src/multi-stage-output.tsx | 12 +----------- 2 files changed, 2 insertions(+), 12 deletions(-) diff --git a/src/index.ts b/src/index.ts index 284ca4a..5e14703 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1 +1 @@ -export {MultiStageOutput} from './multi-stage-output.js' +export {MultiStageOutput, MultiStageOutputOptions} from './multi-stage-output.js' diff --git a/src/multi-stage-output.tsx b/src/multi-stage-output.tsx index 16eb7ab..415911d 100644 --- a/src/multi-stage-output.tsx +++ b/src/multi-stage-output.tsx @@ -23,7 +23,7 @@ const isInCi = env.CI !== 'false' && ('CI' in env || 'CONTINUOUS_INTEGRATION' in env || Object.keys(env).some((key) => key.startsWith('CI_'))) -type MultiStageOutputOptions> = { +export type MultiStageOutputOptions> = { /** * Stages to render. */ @@ -64,12 +64,6 @@ type MultiStageOutputOptions> = { * Data to display in the stages component. This data will be passed to the get function in the info object. */ readonly data?: Partial - /** - * Whether JSON output is enabled. Defaults to false. - * - * Pass in this.jsonEnabled() from the command class to determine if JSON output is enabled. - */ - readonly jsonEnabled: boolean /** * Design options to customize the output. */ @@ -240,7 +234,6 @@ export class MultiStageOutput> implements Disp public constructor({ data, design, - jsonEnabled, postStagesBlock, preStagesBlock, showElapsedTime, @@ -262,13 +255,10 @@ export class MultiStageOutput> implements Disp this.stageTracker = new StageTracker(stages) this.stageSpecificBlock = stageSpecificBlock - if (jsonEnabled) return - if (isInCi) { this.ciInstance = new CIMultiStageOutput({ data, design, - jsonEnabled, postStagesBlock, preStagesBlock, showElapsedTime,