#Parameters not available anymore on Docs page

5 messages · Page 1 of 1 (latest)

vivid mist
#

I've set the following parameter in my *.stories.tsx file in the default export (meta):

parameters: {
  componentStatus: 'alpha',
},

But when I try to access this in my toolbar addon it turns up empty

import { useParameter } from '@storybook/manager-api'

//...

const status = useParameter('componentStatus')

This used to work fine in v6. I'm now using 7.0.0-rc.0

#

It works fine when accessing a Story, but not on the autodocs page

#

Related to this I also notice that the grid option from the backgrounds addon is also showing for docs pages even though I disabled it in the global parameters in preview.tsx

  backgrounds: {
    disable: true,
    grid: { disable: true },
  },
gloomy moat
vivid mist
#

Yeah none of the parameters, whether on global or story level, seem to work with (auto)docs pages. They work fine whenever you switch to a story page. I haven't gotten around to set up a reproduction and file a bug on github yet unfortunately