diff --git a/stories/src/helpers.tsx b/stories/src/helpers.tsx index 7b3caf1c..f62703d1 100644 --- a/stories/src/helpers.tsx +++ b/stories/src/helpers.tsx @@ -98,6 +98,9 @@ export const xKnob = (table: Table, initial?: string) => export const yKnob = (table: Table, initial?: string) => select('y', findXYColumns(table), initial || '_value' || 'cpu') +export const yKnobString = (table: Table, initial?: string) => + select('y', findStringColumns(table), initial || 'cpu') + export const fillKnob = (table: Table, initial?: string) => multiSelect('fill', findStringColumns(table), initial || 'cpu') diff --git a/stories/src/index.stories.tsx b/stories/src/index.stories.tsx index 538b2e01..99ec0e01 100644 --- a/stories/src/index.stories.tsx +++ b/stories/src/index.stories.tsx @@ -18,6 +18,7 @@ import { PlotContainer, xKnob, yKnob, + yKnobString, xScaleKnob, yScaleKnob, fillKnob, @@ -417,7 +418,7 @@ storiesOf('XY Plot', module) const table = tableKnob() const colors = colorSchemeKnob() const x = xKnob(table) - const y = yKnob(table, 'cpu') + const y = yKnobString(table, 'cpu') const fill = ['_value'] const symbol = symbolKnob(table, 'host')