c596a5e342
## Description Promotes the next-gen UI library (formerly `twenty-new-ui`) to the name **`twenty-ui`** (v0.1.0, publishable) and renames the old package to **`twenty-ui-deprecated`**. Rewrites ~1,730 `twenty-ui` imports → `twenty-ui-deprecated`, updates all configs/CI/Docker/deps, and migrates twenty-front's `Toggle` to the new package (first consumer) as a drop-in. ## Next steps - Wire the `ui/v*` publish dispatch (`cd-deploy-tag.yaml` + `.yarnrc.yml`), then tag `ui/v0.1.0` to publish. - Continue migrating components from `twenty-ui-deprecated` → `twenty-ui`.
52 lines
1.7 KiB
TypeScript
52 lines
1.7 KiB
TypeScript
import { argosVitestPlugin } from '@argos-ci/storybook/vitest-plugin';
|
|
import { storybookTest } from '@storybook/addon-vitest/vitest-plugin';
|
|
import { playwright } from '@vitest/browser-playwright';
|
|
import path from 'node:path';
|
|
import { fileURLToPath } from 'node:url';
|
|
import { defineConfig } from 'vitest/config';
|
|
|
|
const MINUTES_IN_MS = 60 * 1000;
|
|
|
|
const dirname =
|
|
typeof __dirname !== 'undefined'
|
|
? __dirname
|
|
: path.dirname(fileURLToPath(import.meta.url));
|
|
|
|
export default defineConfig({
|
|
test: {
|
|
projects: [
|
|
{
|
|
extends: './vite.config.ts',
|
|
plugins: [
|
|
storybookTest({
|
|
configDir: path.join(dirname, '.storybook'),
|
|
...(process.env.STORYBOOK_URL
|
|
? { storybookUrl: process.env.STORYBOOK_URL }
|
|
: { storybookScript: 'yarn storybook --no-open --port 6008' }),
|
|
}),
|
|
argosVitestPlugin({
|
|
uploadToArgos: !!process.env.ARGOS_TOKEN,
|
|
token: process.env.ARGOS_TOKEN,
|
|
apiBaseUrl: process.env.ARGOS_API_BASE_URL,
|
|
buildName: process.env.ARGOS_BUILD_NAME || undefined,
|
|
branch: process.env.ARGOS_BRANCH || undefined,
|
|
commit: process.env.ARGOS_COMMIT || undefined,
|
|
referenceCommit: process.env.ARGOS_REFERENCE_COMMIT || undefined,
|
|
}),
|
|
],
|
|
test: {
|
|
name: 'storybook',
|
|
browser: {
|
|
enabled: true,
|
|
headless: true,
|
|
provider: playwright({}),
|
|
instances: [{ browser: 'chromium' }],
|
|
},
|
|
setupFiles: ['./.storybook/vitest.setup.ts'],
|
|
testTimeout: 5 * MINUTES_IN_MS,
|
|
},
|
|
},
|
|
],
|
|
},
|
|
});
|