Skip to content

Commit

Permalink
Merge pull request #25009 from storybookjs/release-8-0
Browse files Browse the repository at this point in the history
Build: Updates from merged PRS unto 8-0
  • Loading branch information
ndelangen authored Nov 28, 2023
2 parents d2a7bd6 + 80ffedb commit 362408f
Show file tree
Hide file tree
Showing 2 changed files with 49 additions and 0 deletions.
9 changes: 9 additions & 0 deletions MIGRATION.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@
- [7.0 feature flags removed](#70-feature-flags-removed)
- [Story context is prepared before for supporting fine grained updates](#story-context-is-prepared-before-for-supporting-fine-grained-updates)
- [Changed decorator order between preview.js and addons/frameworks](#changed-decorator-order-between-previewjs-and-addonsframeworks)
- [Dark mode detection](#dark-mode-detection)
- [7.0 core addons changes](#70-core-addons-changes)
- [Removed auto injection of @storybook/addon-actions decorator](#removed-auto-injection-of-storybookaddon-actions-decorator)
- [Addon-backgrounds: Removed deprecated grid parameter](#addon-backgrounds-removed-deprecated-grid-parameter)
Expand Down Expand Up @@ -1206,6 +1207,14 @@ export default {
};
```

#### Dark mode detection

Storybook 7 uses `prefers-color-scheme` to detects your system's dark mode preference if a theme is not set.

Earlier versions used the light theme by default, so if you don't set a theme and your system's settings are in dark mode, this could surprise you.

To learn more about theming, read our [documentation](https://storybook.js.org/docs/react/configure/theming).

### 7.0 core addons changes

#### Removed auto injection of @storybook/addon-actions decorator
Expand Down
40 changes: 40 additions & 0 deletions code/addons/essentials/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,55 @@ import { logger } from '@storybook/node-logger';
import { serverRequire } from '@storybook/core-common';

interface PresetOptions {
/**
* Allow to use @storybook/addon-actions
* @see https://storybook.js.org/addons/@storybook/addon-actions
* @default true
*/
actions?: boolean;
/**
* Allow to use @storybook/addon-backgrounds
* @see https://storybook.js.org/addons/@storybook/addon-backgrounds
* @default true
*/
backgrounds?: boolean;
configDir: string;
/**
* Allow to use @storybook/addon-controls
* @see https://storybook.js.org/addons/@storybook/addon-controls
* @default true
*/
controls?: boolean;
/**
* Allow to use @storybook/addon-docs
* @see https://storybook.js.org/addons/@storybook/addon-docs
* @default true
*/
docs?: boolean;
/**
* Allow to use @storybook/addon-measure
* @see https://storybook.js.org/addons/@storybook/addon-measure
* @default true
*/
measure?: boolean;
/**
* Allow to use @storybook/addon-outline
* @see https://storybook.js.org/addons/@storybook/addon-outline
* @default true
*/
outline?: boolean;
themes?: boolean;
/**
* Allow to use @storybook/addon-toolbars
* @see https://storybook.js.org/addons/@storybook/addon-toolbars
* @default true
*/
toolbars?: boolean;
/**
* Allow to use @storybook/addon-viewport
* @see https://storybook.js.org/addons/@storybook/addon-viewport
* @default true
*/
viewport?: boolean;
}

Expand Down

0 comments on commit 362408f

Please sign in to comment.