Skip to content

Commit 8c6bccd

Browse files
authored
docs(tabs): improvements to storybook for tabs (#2424)
1 parent 0ee537e commit 8c6bccd

12 files changed

+276
-540
lines changed

components/picker/stories/template.js

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -202,22 +202,23 @@ export const Template = ({
202202
hideIcon: true,
203203
})
204204
: ""}
205-
${Popover({
206-
...globals,
207-
isOpen: isOpen && !isDisabled,
208-
withTip: false,
209-
position: "bottom",
210-
isQuiet,
211-
customStyles: customPopoverStyles,
212-
content,
213-
})}
205+
${when(content.length !== 0, () =>
206+
Popover({
207+
...globals,
208+
isOpen: isOpen && !isDisabled,
209+
withTip: false,
210+
position: "bottom",
211+
isQuiet,
212+
customStyles: customPopoverStyles,
213+
content,
214+
}))}
214215
${when (withSwitch, () => Switch({
215216
...globals,
216217
size,
217218
label: "Toggle switch",
218219
customStyles: {
219220
"padding-inline-start": "15px"
220221
}
221-
})) }
222+
}))}
222223
`;
223224
};

components/tabs/stories/index.js

Lines changed: 0 additions & 141 deletions
This file was deleted.

components/tabs/stories/tabs-horizontal-compact.stories.js

Lines changed: 0 additions & 57 deletions
This file was deleted.

components/tabs/stories/tabs-horizontal-emphasized.stories.js

Lines changed: 0 additions & 40 deletions
This file was deleted.

components/tabs/stories/tabs-horizontal-quiet.stories.js

Lines changed: 0 additions & 46 deletions
This file was deleted.

components/tabs/stories/tabs-horizontal.stories.js

Lines changed: 0 additions & 40 deletions
This file was deleted.

0 commit comments

Comments
 (0)