Skip to content

Commit

Permalink
fix: Make regular expression case-insensitive to resolve storybookjs#…
Browse files Browse the repository at this point in the history
…24120

Description:
- Resolved the bug reported in issue storybookjs#24120, where the regular expression `/Date$/` wasn't matching properties that end with "date" or "Date" due to case sensitivity.
- Changed the regular expression to `/Date$/i` in the configuration file to make it case-insensitive, allowing it to match both "Date" and "date."

Issue: storybookjs#24120
  • Loading branch information
amarnathgupta committed Sep 17, 2023
1 parent 04ced71 commit be74eb7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion code/lib/cli/src/generators/configure.ts
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ export async function configurePreview(options: ConfigurePreviewOptions) {
controls: {
matchers: {
color: /(background|color)$/i,
date: /Date$/,
date: /Date$/i,
},
},
},
Expand Down

0 comments on commit be74eb7

Please sign in to comment.