Skip to content

Commit

Permalink
Only add deprecated CSS to deprecated components
Browse files Browse the repository at this point in the history
  • Loading branch information
jessepinho committed Jul 10, 2024
1 parent be8e391 commit c655587
Showing 1 changed file with 12 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,8 +1,19 @@
import '../styles/globals.css';
import React from 'react';
import globalsCssUrl from '../styles/globals.css?url';
import penumbraTheme from './penumbraTheme';

/** @type { import('@storybook/react').Preview } */
const preview = {
decorators: [
(Story, { title }) => (
<>
{title.startsWith('Deprecated/') && (
<link rel='stylesheet' type='text/css' href={globalsCssUrl} />
)}
<Story />
</>
),
],
parameters: {
actions: { argTypesRegex: '^on[A-Z].*' },
controls: {
Expand Down

0 comments on commit c655587

Please sign in to comment.