question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Global backgrounds not working in 6.4-alpha

See original GitHub issue

Describe the bug The backgrounds values in preview.js appear to be ignored in the 6.4 alpha builds.

To Reproduce

With the following preview.js file, the backgrounds still only show the standard light and dark options

export const parameters = {
  actions: { argTypesRegex: "^on[A-Z].*" },
  controls: {
    matchers: {
      color: /(background|color)$/i,
      date: /Date$/,
    },
  },
  backgrounds: {
    default: 'dark paper',
    grid: {
      disable: true
    },
    values: [
      {name: 'dark paper', value: '#252525', },
      {name: 'dark background', value: '#171717', },
      {name: 'light paper', value: '#d9d9d9', },
      {name: 'light background', value: '#ffffff', },
    ],
  },
}

The option to disable the grid is working as expected.

Additionally, adding the backgrounds settings to the parameters for a story also works as expected (i.e. the background colour options appear as expected)

System Environment Info:

System: OS: Windows 10 10.0.19042 CPU: (16) x64 Intel® Core™ i9-10885H CPU @ 2.40GHz Binaries: Node: 16.3.0 - C:\Program Files\nodejs\node.EXE npm: 7.15.1 - C:\Program Files\nodejs\npm.CMD Browsers: Edge: Spartan (44.19041.964.0), Chromium (92.0.902.62) npmPackages: @storybook/addon-actions: ^6.4.0-alpha.18 => 6.4.0-alpha.18 @storybook/addon-essentials: ^6.4.0-alpha.18 => 6.4.0-alpha.18 @storybook/addon-links: ^6.4.0-alpha.18 => 6.4.0-alpha.18 @storybook/react: ^6.4.0-alpha.18 => 6.4.0-alpha.18

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:6
  • Comments:10 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
rbanks-willowcommented, Nov 29, 2021

Just did the upgrade to 6.4.0 and everything looks good now!

I updated a few times during and alpha and early beta phases and it wasn’t working, but it looks good now so I assume a recent(ish) resolved it.

1reaction
yannbfcommented, Sep 24, 2021

@yannbf is this something you can take a look at?

So sorry, I’m currently on holidays and not really able to use the computer! Will be easier to check this by the end of the month, in case no one else checks it out

Read more comments on GitHub >

github_iconTop Results From Across the Web

Global backgrounds not working in 6.4-alpha #15738
Describe the bug The backgrounds values in preview. js appear to be ignored in the 6.4 alpha builds. The option to disable the...
Read more >
Release Notes - Zabbix
Explore the list of new features and improvements of every Zabbix release.
Read more >
Particle Editor - Bohemia Interactive Community Wiki
The Particle Editor serves as a tool for creating/editing particle effects used in the game. Effects such as explosions, muzzle flashes, ...
Read more >
Monthly Archives: September 2011 - 4DO
To try out 4DO 1.0.6.4 alpha, head to to the download page: ... Fixed bug where selecting the “None” void area background would...
Read more >
Terms - Alpha Grid
For the avoidance of doubt, the Deliverables do not include any background or draft work products. 2.7 If Alpha Grid's performance of its...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found