20 Commits

Author SHA1 Message Date
f4d7754f6b Merge branch 'main' into feature/remove-fleet
All checks were successful
Release / build_test (pull_request) Successful in 26s
2025-11-30 13:57:03 +01:00
78a6176342 feat: trigger build on pull request edits
All checks were successful
Release / build_test (pull_request) Successful in 27s
2025-11-30 13:51:45 +01:00
d224f139b4 Refactor tooltip and reviews-stars libraries; update CI workflow
- Updated the CI workflow to build and test only the "reviews-stars" project.
- Removed unnecessary test files for the "reviews-stars" and "tooltip" libraries.
- Changed the export of TooltipComponent from default to named export.
2025-11-30 13:49:38 +01:00
3f4d611a18 Merge pull request 'feature/remove-fleet' (#2) from feature/remove-fleet into main
Reviewed-on: #2
2025-11-29 23:29:17 +01:00
5ddd6501b6 feat: add release workflow for pull requests
Some checks failed
Release / build_test (pull_request) Failing after 39s
2025-11-29 23:28:56 +01:00
268e0a767c remove onedev 2025-11-29 22:56:42 +01:00
44b51ca055 Edit .onedev-buildspec.yml 2025-11-28 20:54:43 +01:00
8863ffd1f7 feat: add initial build specification for publishing 2025-11-28 20:52:29 +01:00
0a179ec3dc Delete .onedev-buildspec.yml 2025-11-28 20:44:59 +01:00
16965d779f Edit .onedev-buildspec.yml 2025-11-28 20:39:47 +01:00
141c2a0a16 chore: update build job steps in build specification 2025-11-28 20:38:49 +01:00
9815ade65a fix: add build job to the build specification 2025-11-28 20:37:23 +01:00
ec7f0c2f4f Merge branch 'feature/remove-fleet' of https://onedev.hijlkema.codes/z-elements into feature/remove-fleet 2025-11-28 20:28:14 +01:00
301f32b39c chore: remove staging deployment script from build specification 2025-11-28 20:27:10 +01:00
249c00e90c Edit .onedev-buildspec.yml 2025-11-28 20:25:08 +01:00
21238c5d41 Edit .onedev-buildspec.yml 2025-11-28 20:24:58 +01:00
c709ce9e8d chore: add deployment script for staging environment 2025-11-28 20:23:25 +01:00
f3c8d121ae chore: add initial build specification file 2025-11-28 20:17:40 +01:00
ce0e1742d2 chore: update dependencies and devDependencies in package.json
- Updated lit to version 3.3.1
- Upgraded react and react-dom to version 19.2.0
- Updated tslib to version 2.8.1
- Upgraded zod to version 4.1.13
- Updated @babel/plugin-proposal-decorators to version 7.28.0
- Upgraded @playwright/test to version 1.57.0
- Updated @storybook/test-runner to version 0.24.2
- Updated @swc-node/register to version 1.11.1
- Updated @swc/core to version 1.15.3
- Updated @swc/helpers to version 0.5.17
- Upgraded @trivago/prettier-plugin-sort-imports to version 6.0.0
- Updated @types/node to version 24.10.1
- Upgraded @typescript-eslint/eslint-plugin and parser to version 8.48.0
- Updated @vitest/ui to version 4.0.14
- Upgraded eslint to version 9.39.1
- Updated eslint-config-prettier to version 10.1.8
- Upgraded eslint-plugin-playwright to version 2.3.0
- Updated jest and related packages to version 30.2.0
- Updated jiti to version 2.6.1
- Updated jsdom to version 27.2.0
- Updated prettier to version 3.7.1
- Updated rxjs to version 7.8.2
- Upgraded storybook to version 10.1.2
- Updated verdaccio to version 6.2.3
- Updated vite to version 7.2.4
- Updated vitest to version 4.0.14
2025-11-28 20:02:46 +01:00
62d24417d4 update dependencies 2025-11-28 19:49:30 +01:00
14 changed files with 20584 additions and 14952 deletions

View File

@@ -0,0 +1,37 @@
name: Release
concurrency:
cancel-in-progress: true
group: test-pr-${{ github.event.pull_request.number }}
env:
ACT_OWNER: ${{ github.repository_owner }}
ACT_REPOSITORY: ${{ github.repository }}
CGO_ENABLED: 0
on:
pull_request:
types:
- opened
- synchronize
- reopened
- edited
jobs:
build_test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- run: git fetch --force --tags
- name: Set up Node.js
uses: actions/setup-node@v6
with:
node-version: 22
- name: Install dependencies
run: npm ci --legacy-peer-deps
- name: Build libraries
run: npx nx run-many -t build --projects="reviews-stars"
- name: Run tests
run: npx nx run-many -t test --code-coverage --passWithNoTests --projects="reviews-stars"

4
.gitignore vendored
View File

@@ -41,3 +41,7 @@ Thumbs.db
.nx/cache
.nx/workspace-data
vite.config.*.timestamp*
.cursor/rules/nx-rules.mdc
.github/instructions/nx.instructions.md
act_runner*

View File

@@ -0,0 +1,175 @@
# Instructions for LLM: Transform Storybook Config Files from CommonJS to ESM
## Task Overview
Find all .storybook/main.ts and .storybook/main.js files in the workspace and transform
any CommonJS (CJS) configurations to ES Modules (ESM).
### Step 1: Find All Storybook Config Files
Use glob patterns to locate all Storybook main configuration files:
**/.storybook/main.js
**/.storybook/main.ts
### Step 2: Identify CommonJS vs ESM
For each file found, read its contents and determine if it uses CommonJS syntax by
checking for:
CommonJS indicators:
- `module.exports =` or `module.exports.`
- `exports.`
- `require()` function calls
ESM indicators (already correct):
- export default
- export const/export function
- import statements
### Step 3: Transform CJS to ESM
For each file identified as CommonJS, perform the following transformations:
A. Convert `module.exports`
// FROM (CJS):
```
module.exports = {
stories: ['../src/**/*.stories.@(js|jsx|ts|tsx|mdx)'],
addons: ['@storybook/addon-essentials']
};
```
// TO (ESM):
```
export default {
stories: ['../src/**/*.stories.@(js|jsx|ts|tsx|mdx)'],
addons: ['@storybook/addon-essentials']
};
```
B. Convert `require()` to import
// FROM (CJS):
```
const { nxViteTsPaths } = require('@nx/vite/plugins/nx-tsconfig-paths.plugin');
const { mergeConfig } = require('vite');
```
// TO (ESM):
```
import { nxViteTsPaths } from '@nx/vite/plugins/nx-tsconfig-paths.plugin';
import { mergeConfig } from 'vite';
```
C. Handle `path.join()` patterns
// FROM (CJS):
```
const path = require('path');
const rootMain = require(path.join(__dirname, '../../.storybook/main'));
```
// TO (ESM):
```
import { join } from 'path';
import rootMain from '../../.storybook/main';
```
D. Handle Dynamic Requires in Config Functions
// FROM (CJS):
```
module.exports = {
viteFinal: async (config) => {
const { mergeConfig } = require('vite');
return mergeConfig(config, {});
}
};
```
// TO (ESM):
```
import { mergeConfig } from 'vite';
export default {
viteFinal: async (config) => {
return mergeConfig(config, {});
}
};
```
### Step 4: Validation Checks
After transformation, verify:
1. All require() calls have been converted to import statements at the top of the file
2. All module.exports have been converted to export default or named exports
3. Imports are at the top of the file (before the export)
4. The file maintains proper TypeScript typing if it's a .ts file
### Step 5: Report Results
Provide a summary of:
- Total files found
- Files that were already ESM (no changes needed)
- Files that were transformed from CJS to ESM
- List the specific files that were modified
### Example Complete Transformation
Before (CJS):
```
const path = require('path');
const { mergeConfig } = require('vite');
module.exports = {
stories: ['../src/**/*.stories.@(js|jsx|ts|tsx|mdx)'],
addons: ['@storybook/addon-essentials'],
viteFinal: async (config) => {
return mergeConfig(config, {
resolve: {
alias: {}
}
});
}
};
```
After (ESM):
```
import { join } from 'path';
import { mergeConfig } from 'vite';
export default {
stories: ['../src/**/*.stories.@(js|jsx|ts|tsx|mdx)'],
addons: ['@storybook/addon-essentials'],
viteFinal: async (config) => {
return mergeConfig(config, {
resolve: {
alias: {}
}
});
}
};
```
## Important Notes
- Preserve all comments in the original files
- Maintain the same indentation and formatting style
- For TypeScript files (.ts), ensure type imports use import type when appropriate
- Test that the transformations don't break the Storybook configuration

View File

@@ -1,5 +1,5 @@
import { getJestProjects } from '@nx/jest';
import { getJestProjectsAsync } from '@nx/jest';
export default {
projects: getJestProjects(),
};
export default async () => ({
projects: await getJestProjectsAsync(),
});

View File

@@ -3,38 +3,28 @@
"$schema": "../../../node_modules/nx/schemas/project-schema.json",
"sourceRoot": "libs/_internal/styles/src",
"projectType": "library",
"tags": [],
"targets": {
"build": {
"executor": "@nx/js:tsc",
"outputs": [
"{options.outputPath}"
],
"outputs": ["{options.outputPath}"],
"options": {
"outputPath": "dist/libs/_internal/styles",
"main": "libs/_internal/styles/src/index.ts",
"tsConfig": "libs/_internal/styles/tsconfig.lib.json",
"assets": [
"libs/_internal/styles/*.md"
]
"assets": ["libs/_internal/styles/*.md"]
}
},
"lint": {
"executor": "@nx/linter:eslint",
"outputs": [
"{options.outputFile}"
],
"outputs": ["{options.outputFile}"],
"options": {
"lintFilePatterns": [
"libs/_internal/styles/**/*.ts",
"libs/_internal/styles/package.json"
]
"lintFilePatterns": ["libs/_internal/styles/**/*.ts", "libs/_internal/styles/package.json"]
}
},
"test": {
"executor": "@nx/jest:jest",
"outputs": [
"{workspaceRoot}/coverage/{projectRoot}"
],
"outputs": ["{workspaceRoot}/coverage/{projectRoot}"],
"options": {
"jestConfig": "libs/_internal/styles/jest.config.ts",
"passWithNoTests": true
@@ -46,6 +36,5 @@
}
}
}
},
"tags": []
}
}

View File

@@ -3,39 +3,29 @@
"$schema": "../../node_modules/nx/schemas/project-schema.json",
"sourceRoot": "libs/accordion/src",
"projectType": "library",
"tags": ["type:component", ""],
"targets": {
"build": {
"executor": "@nx/vite:build",
"outputs": [
"{options.outputPath}"
],
"outputs": ["{options.outputPath}"],
"options": {
"outputPath": "dist/libs/accordion"
}
},
"publish": {
"command": "node tools/scripts/publish.mjs accordion {args.ver} {args.tag}",
"dependsOn": [
"build"
]
"dependsOn": ["build"]
},
"lint": {
"executor": "@nx/linter:eslint",
"outputs": [
"{options.outputFile}"
],
"outputs": ["{options.outputFile}"],
"options": {
"lintFilePatterns": [
"libs/accordion/**/*.ts",
"libs/accordion/package.json"
]
"lintFilePatterns": ["libs/accordion/**/*.ts", "libs/accordion/package.json"]
}
},
"test": {
"executor": "@nx/jest:jest",
"outputs": [
"{workspaceRoot}/coverage/{projectRoot}"
],
"outputs": ["{workspaceRoot}/coverage/{projectRoot}"],
"options": {
"jestConfig": "libs/accordion/jest.config.ts",
"passWithNoTests": true
@@ -47,9 +37,5 @@
}
}
}
},
"tags": [
"type:component",
""
]
}
}

View File

@@ -3,38 +3,28 @@
"$schema": "../../node_modules/nx/schemas/project-schema.json",
"sourceRoot": "libs/container/src",
"projectType": "library",
"tags": [],
"targets": {
"build": {
"executor": "@nx/js:tsc",
"outputs": [
"{options.outputPath}"
],
"outputs": ["{options.outputPath}"],
"options": {
"outputPath": "dist/libs/container",
"main": "libs/container/src/index.ts",
"tsConfig": "libs/container/tsconfig.lib.json",
"assets": [
"libs/container/*.md"
]
"assets": ["libs/container/*.md"]
}
},
"lint": {
"executor": "@nx/linter:eslint",
"outputs": [
"{options.outputFile}"
],
"outputs": ["{options.outputFile}"],
"options": {
"lintFilePatterns": [
"libs/container/**/*.ts",
"libs/container/package.json"
]
"lintFilePatterns": ["libs/container/**/*.ts", "libs/container/package.json"]
}
},
"test": {
"executor": "@nx/jest:jest",
"outputs": [
"{workspaceRoot}/coverage/{projectRoot}"
],
"outputs": ["{workspaceRoot}/coverage/{projectRoot}"],
"options": {
"jestConfig": "libs/container/jest.config.ts",
"passWithNoTests": true
@@ -60,9 +50,7 @@
},
"build-storybook": {
"executor": "@nx/storybook:build",
"outputs": [
"{options.outputDir}"
],
"outputs": ["{options.outputDir}"],
"options": {
"outputDir": "dist/storybook/container",
"configDir": "libs/container/.storybook"
@@ -79,6 +67,5 @@
"command": "test-storybook -c libs/container/.storybook --url=http://localhost:4400"
}
}
},
"tags": []
}
}

View File

@@ -1,7 +0,0 @@
import { reviewsStars } from './reviews-stars';
describe('reviewsStars', () => {
it('should work', () => {
expect(reviewsStars()).toEqual('reviews-stars');
});
});

View File

@@ -13,7 +13,7 @@ import { Placement } from './models/placement.enum';
import { basicStyles, positioning, variables } from './styles';
@customElement('z-tooltip')
export default class TooltipComponent extends LitElement {
export class TooltipComponent extends LitElement {
/** Private variables */
private readonly _visibilityController = new VisibilityController(this);
private readonly _positionController = new PositionController(this);

View File

@@ -1,7 +0,0 @@
import { tooltip } from './tooltip.component';
describe('tooltip', () => {
it('should work', () => {
expect(tooltip()).toEqual('tooltip');
});
});

View File

@@ -1,74 +0,0 @@
{
"migrations": [
{
"cli": "nx",
"version": "17.3.0-beta.6",
"description": "Updates the nx wrapper.",
"implementation": "./src/migrations/update-17-3-0/update-nxw",
"package": "nx",
"name": "17.3.0-update-nx-wrapper"
},
{
"cli": "nx",
"version": "18.0.0-beta.2",
"description": "Updates nx.json to disabled adding plugins when generating projects in an existing Nx workspace",
"implementation": "./src/migrations/update-18-0-0/disable-crystal-for-existing-workspaces",
"x-repair-skip": true,
"package": "nx",
"name": "18.0.0-disable-adding-plugins-for-existing-workspaces"
},
{
"version": "18.1.0-beta.3",
"description": "Moves affected.defaultBase to defaultBase in `nx.json`",
"implementation": "./src/migrations/update-17-2-0/move-default-base",
"package": "nx",
"name": "move-default-base-to-nx-json-root"
},
{
"cli": "nx",
"version": "19.2.0-beta.2",
"description": "Updates the default workspace data directory to .nx/workspace-data",
"implementation": "./src/migrations/update-19-2-0/move-workspace-data-directory",
"package": "nx",
"name": "19-2-0-move-graph-cache-directory"
},
{
"cli": "nx",
"version": "19.2.2-beta.0",
"description": "Updates the nx wrapper.",
"implementation": "./src/migrations/update-17-3-0/update-nxw",
"package": "nx",
"name": "19-2-2-update-nx-wrapper"
},
{
"version": "19.2.4-beta.0",
"description": "Set project name in nx.json explicitly",
"implementation": "./src/migrations/update-19-2-4/set-project-name",
"x-repair-skip": true,
"package": "nx",
"name": "19-2-4-set-project-name"
},
{
"version": "17.3.0-beta.0",
"description": "Move the vitest coverage thresholds in their own object if exists and add reporters.",
"implementation": "./src/migrations/update-17-3-0/vitest-coverage-and-reporters",
"package": "@nx/vite",
"name": "vitest-coverage-and-reporters"
},
{
"version": "17.2.9",
"description": "Move executor options to target defaults",
"implementation": "./src/migrations/update-17-2-9/move-options-to-target-defaults",
"package": "@nx/linter",
"name": "move-options-to-target-defaults"
},
{
"cli": "nx",
"version": "19.1.0-beta.6",
"description": "Migrate no-extra-semi rules into user config, out of nx extendable configs",
"implementation": "./src/migrations/update-19-1-0-migrate-no-extra-semi/migrate-no-extra-semi",
"package": "@nx/eslint-plugin",
"name": "update-19-1-0-rename-no-extra-semi"
}
]
}

20292
package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -5,64 +5,61 @@
"scripts": {},
"private": true,
"dependencies": {
"lit": "^3.2.0",
"react": "^18.3.1",
"react-dom": "^18.3.1",
"tslib": "^2.6.3",
"zod": "^3.23.8"
"lit": "3.3.1",
"react": "^19.2.0",
"react-dom": "^19.2.0",
"tslib": "^2.8.1",
"zod": "^4.1.13"
},
"devDependencies": {
"@babel/plugin-proposal-decorators": "^7.24.7",
"@nx/devkit": "19.5.7",
"@nx/eslint-plugin": "19.5.7",
"@nx/jest": "19.5.7",
"@nx/js": "19.5.7",
"@nx/linter": "19.5.7",
"@nx/playwright": "19.5.7",
"@nx/storybook": "19.5.7",
"@nx/vite": "19.5.7",
"@nx/web": "19.5.7",
"@nx/workspace": "19.5.7",
"@playwright/test": "^1.46.0",
"@storybook/addon-essentials": "8.2.8",
"@storybook/addon-interactions": "8.2.8",
"@storybook/core-server": "8.2.8",
"@babel/plugin-proposal-decorators": "^7.28.0",
"@nx/devkit": "22.1.3",
"@nx/eslint-plugin": "22.1.3",
"@nx/jest": "22.1.3",
"@nx/js": "22.1.3",
"@nx/playwright": "22.1.3",
"@nx/storybook": "22.1.3",
"@nx/vite": "22.1.3",
"@nx/web": "22.1.3",
"@nx/workspace": "22.1.3",
"@playwright/test": "^1.57.0",
"@storybook/jest": "0.2.3",
"@storybook/test-runner": "0.19.1",
"@storybook/test-runner": "0.24.2",
"@storybook/testing-library": "0.2.2",
"@storybook/web-components": "^8.2.8",
"@storybook/web-components-vite": "8.2.8",
"@storybook/web-components-webpack5": "8.2.8",
"@swc-node/register": "~1.10.9",
"@swc/core": "~1.7.10",
"@swc/helpers": "~0.5.12",
"@swc/jest": "~0.2.36",
"@trivago/prettier-plugin-sort-imports": "^4.3.0",
"@types/jest": "^29.5.12",
"@types/node": "22.2.0",
"@typescript-eslint/eslint-plugin": "8.0.1",
"@typescript-eslint/parser": "8.0.1",
"@storybook/web-components": "^10",
"@storybook/web-components-vite": "^10",
"@swc-node/register": "~1.11.1",
"@swc/core": "~1.15.3",
"@swc/helpers": "~0.5.17",
"@swc/jest": "0.2.39",
"@trivago/prettier-plugin-sort-imports": "^6.0.0",
"@types/jest": "30.0.0",
"@types/node": "24.10.1",
"@typescript-eslint/eslint-plugin": "8.48.0",
"@typescript-eslint/parser": "8.48.0",
"@vitest/coverage-c8": "~0.33.0",
"@vitest/ui": "2.0.5",
"eslint": "9.9.0",
"eslint-config-prettier": "9.1.0",
"eslint-plugin-playwright": "^1.6.2",
"jest": "^29.7.0",
"jest-environment-jsdom": "^29.7.0",
"jest-environment-node": "^29.7.0",
"jsdom": "~24.1.1",
"nx": "19.5.7",
"prettier": "^3.3.3",
"rxjs": "^7.8.1",
"storybook": "^8.2.8",
"@vitest/ui": "4.0.14",
"eslint": "9.39.1",
"eslint-config-prettier": "10.1.8",
"eslint-plugin-playwright": "^2.3.0",
"jest": "30.2.0",
"jest-environment-jsdom": "30.2.0",
"jest-environment-node": "^30.2.0",
"jest-util": "30.2.0",
"jiti": "2.6.1",
"jsdom": "~27.2.0",
"nx": "22.1.3",
"prettier": "^3.7.1",
"rxjs": "^7.8.2",
"storybook": "10.1.2",
"swc-loader": "0.2.6",
"ts-jest": "^29.2.4",
"ts-jest": "29.4.5",
"ts-node": "10.9.2",
"typescript": "5.5.4",
"verdaccio": "^5.32.1",
"vite": "5.4.0",
"vite-plugin-dts": "4.0.2",
"vitest": "2.0.5"
"typescript": "5.9.3",
"verdaccio": "6.2.3",
"vite": "7.2.4",
"vite-plugin-dts": "4.5.4",
"vitest": "4.0.14"
},
"nx": {
"includedScripts": []

14747
pnpm-lock.yaml generated

File diff suppressed because it is too large Load Diff