diff --git a/.storybook/preview.tsx b/.storybook/preview.tsx index 1067b0e041..b8b9bd385e 100644 --- a/.storybook/preview.tsx +++ b/.storybook/preview.tsx @@ -26,9 +26,10 @@ import { modes } from './modes'; import '../app/javascript/styles/application.scss'; import './styles.css'; -const localeFiles = import.meta.glob('@/mastodon/locales/*.json', { - query: { as: 'json' }, -}); +// Disabling locales in Storybook as it's breaking with Vite 8. +// const localeFiles = import.meta.glob('@/mastodon/locales/*.json', { +// query: { as: 'json' }, +// }); // Initialize MSW initialize({ @@ -39,17 +40,17 @@ const preview: Preview = { // Auto-generate docs: https://storybook.js.org/docs/writing-docs/autodocs tags: ['autodocs'], globalTypes: { - locale: { - description: 'Locale for the story', - toolbar: { - title: 'Locale', - icon: 'globe', - items: Object.keys(localeFiles).map((path) => - path.replace('/mastodon/locales/', '').replace('.json', ''), - ), - dynamicTitle: true, - }, - }, + // locale: { + // description: 'Locale for the story', + // toolbar: { + // title: 'Locale', + // icon: 'globe', + // items: Object.keys(localeFiles).map((path) => + // path.replace('/mastodon/locales/', '').replace('.json', ''), + // ), + // dynamicTitle: true, + // }, + // }, theme: { description: 'Theme for the story', toolbar: {