-
-
Notifications
You must be signed in to change notification settings - Fork 9.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #29039 from storybookjs/version-non-patch-from-8.3…
….0-beta.2 Release: Prerelease 8.3.0-beta.3
- Loading branch information
Showing
31 changed files
with
705 additions
and
382 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,4 +5,4 @@ | |
"targets": { | ||
"build": {} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
import { colors, logger } from 'storybook/internal/node-logger'; | ||
|
||
import boxen, { type Options } from 'boxen'; | ||
|
||
const fancy = | ||
process.platform !== 'win32' || process.env.CI || process.env.TERM === 'xterm-256color'; | ||
|
||
export const step = colors.gray('›'); | ||
export const info = colors.blue(fancy ? 'ℹ' : 'i'); | ||
export const success = colors.green(fancy ? '✔' : '√'); | ||
export const warning = colors.orange(fancy ? '⚠' : '‼'); | ||
export const error = colors.red(fancy ? '✖' : '×'); | ||
|
||
const baseOptions: Options = { | ||
borderStyle: 'round', | ||
padding: 1, | ||
}; | ||
|
||
export const print = (message: string, options: Options) => { | ||
logger.line(1); | ||
logger.plain(boxen(message, { ...baseOptions, ...options })); | ||
}; | ||
|
||
export const printInfo = (title: string, message: string, options?: Options) => | ||
print(message, { borderColor: 'blue', title, ...options }); | ||
|
||
export const printWarning = (title: string, message: string, options?: Options) => | ||
print(message, { borderColor: 'yellow', title, ...options }); | ||
|
||
export const printError = (title: string, message: string, options?: Options) => | ||
print(message, { borderColor: 'red', title, ...options }); | ||
|
||
export const printSuccess = (title: string, message: string, options?: Options) => | ||
print(message, { borderColor: 'green', title, ...options }); |
Oops, something went wrong.