Skip to content

Commit

Permalink
Merge pull request #682 from kitsuyui/cleanup-turbo-tasks
Browse files Browse the repository at this point in the history
Clean up turbo tasks
  • Loading branch information
kitsuyui authored Dec 9, 2024
2 parents 0c62ac4 + f062dfe commit d9c1730
Show file tree
Hide file tree
Showing 23 changed files with 377 additions and 349 deletions.
24 changes: 9 additions & 15 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@ jobs:
wavebox,
measure,
treemap,
editablelabel,
tab,
biticon,
physical-size,
editablelabel,
components,
style-bulma,
]
Expand Down Expand Up @@ -59,22 +59,16 @@ jobs:
git config user.name "dummy"
pnpm version from-git --allow-same-version --no-git-tag-version || true
- working-directory: packages/${{ matrix.package_name }}
run: pnpm pack

- name: Test installation
- name: deploy
run: pnpm publish --access=public --no-git-checks --recursive
working-directory: packages/${{ matrix.package_name }}
run: |
set -eu
built_dir=$(pwd)
tempdir=$(mktemp -d)
cd $tempdir
pnpm add $built_dir/*.tgz
cd $built_dir
rm -rf $tempdir
if: github.event_name == 'release' && !github.event.release.prerelease
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

- run: pnpm publish --access=public --no-git-checks
- name: deploy (dry-run)
run: pnpm publish --access=public --no-git-checks --dry-run --recursive
working-directory: packages/${{ matrix.package_name }}
if: github.event_name == 'release' && !github.event.release.prerelease
if: github.event_name != 'release' || github.event.release.prerelease
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
2 changes: 1 addition & 1 deletion biome.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
"files": {
"ignore": [
"**/node_modules/**",
"**/dist/**",
"**/dist/**/*",
"**/build/**",
"**/storybook-static/**",
"**/coverage/**",
Expand Down
32 changes: 16 additions & 16 deletions examples/storybook/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,21 +5,6 @@
"license": "MIT",
"private": true,
"devDependencies": {
"@kitsuyui/react-binary": "workspace:^",
"@kitsuyui/react-biticon": "workspace:^",
"@kitsuyui/react-clock": "workspace:^",
"@kitsuyui/react-components": "workspace:^",
"@kitsuyui/react-dekamoji": "workspace:^",
"@kitsuyui/react-editablelabel": "workspace:^",
"@kitsuyui/react-measure": "workspace:^",
"@kitsuyui/react-physical-size": "workspace:^",
"@kitsuyui/react-stopwatch": "workspace:^",
"@kitsuyui/react-style-bulma": "workspace:^",
"@kitsuyui/react-tab": "workspace:^",
"@kitsuyui/react-textfield": "workspace:^",
"@kitsuyui/react-timer": "workspace:^",
"@kitsuyui/react-treemap": "workspace:^",
"@kitsuyui/react-wavebox": "workspace:^",
"@playwright/test": "^1.49.0",
"@storybook/addon-essentials": "^8.4.7",
"@storybook/addon-interactions": "^8.4.7",
Expand All @@ -31,7 +16,7 @@
"@storybook/test": "^8.4.7",
"@storybook/test-runner": "^0.20.1",
"@swc/cli": "^0.5.2",
"@swc/core": "^1.10.0",
"@swc/core": "^1.10.1",
"@types/node": "^22.10.1",
"@types/react": "^19.0.1",
"prop-types": "^15.8.1",
Expand All @@ -48,6 +33,21 @@
"build": "storybook build"
},
"dependencies": {
"@kitsuyui/react-binary": "workspace:*",
"@kitsuyui/react-biticon": "workspace:*",
"@kitsuyui/react-clock": "workspace:*",
"@kitsuyui/react-components": "workspace:*",
"@kitsuyui/react-dekamoji": "workspace:*",
"@kitsuyui/react-editablelabel": "workspace:*",
"@kitsuyui/react-measure": "workspace:*",
"@kitsuyui/react-physical-size": "workspace:*",
"@kitsuyui/react-stopwatch": "workspace:*",
"@kitsuyui/react-style-bulma": "workspace:*",
"@kitsuyui/react-tab": "workspace:*",
"@kitsuyui/react-textfield": "workspace:*",
"@kitsuyui/react-timer": "workspace:*",
"@kitsuyui/react-treemap": "workspace:*",
"@kitsuyui/react-wavebox": "workspace:*",
"use-sound": "^4.0.3"
}
}
4 changes: 4 additions & 0 deletions jest.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,10 @@ export default {
},
moduleNameMapper: {
'^.+\\.(css|scss)$': 'identity-obj-proxy',
"@kitsuyui/react-textfield": "<rootDir>/packages/textfield/dist/",
"@kitsuyui/react-clock": "<rootDir>/packages/clock/dist/",
"@kitsuyui/react-stopwatch": "<rootDir>/packages/stopwatch/dist/",
"@kitsuyui/react-timer": "<rootDir>/packages/timer/dist/",
},
collectCoverageFrom: ['packages/*/src/**/*.(tsx|ts)'],
}
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"examples/*"
],
"scripts": {
"build": "turbo build",
"build": "turbo build --concurrency=1",
"dev": "turbo run dev --parallel",
"format": "concurrently pnpm:format:*",
"format:biome": "biome lint --write ./",
Expand All @@ -28,7 +28,7 @@
},
"devDependencies": {
"@biomejs/biome": "^1.9.4",
"@swc/core": "^1.10.0",
"@swc/core": "^1.10.1",
"@swc/jest": "^0.2.37",
"@testing-library/jest-dom": "^6.6.3",
"@testing-library/react": "^16.1.0",
Expand Down
11 changes: 8 additions & 3 deletions packages/binary/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,14 @@
"author": "Yui Kitsu <kitsuyui@kitsuyui.com>",
"exports": {
".": {
"require": "./dist/index.js",
"import": "./dist/index.mjs",
"types": "./dist/index.d.ts"
"require": {
"type": "./dist/index.d.mts",
"default": "./dist/index.cjs"
},
"import": {
"type": "./dist/index.d.mts",
"default": "./dist/index.mjs"
}
}
},
"main": "./dist/index.js",
Expand Down
11 changes: 8 additions & 3 deletions packages/biticon/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,14 @@
"author": "Yui Kitsu <kitsuyui@kitsuyui.com>",
"exports": {
".": {
"require": "./dist/index.js",
"import": "./dist/index.mjs",
"types": "./dist/index.d.ts"
"require": {
"type": "./dist/index.d.mts",
"default": "./dist/index.cjs"
},
"import": {
"type": "./dist/index.d.mts",
"default": "./dist/index.mjs"
}
}
},
"main": "./dist/index.js",
Expand Down
13 changes: 9 additions & 4 deletions packages/clock/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,14 @@
"author": "Yui Kitsu <kitsuyui@kitsuyui.com>",
"exports": {
".": {
"require": "./dist/index.js",
"import": "./dist/index.mjs",
"types": "./dist/index.d.ts"
"require": {
"type": "./dist/index.d.mts",
"default": "./dist/index.cjs"
},
"import": {
"type": "./dist/index.d.mts",
"default": "./dist/index.mjs"
}
}
},
"main": "./dist/index.js",
Expand Down Expand Up @@ -36,4 +41,4 @@
"react-dom": "*",
"react-use": "*"
}
}
}
44 changes: 19 additions & 25 deletions packages/components/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,14 @@
"author": "Yui Kitsu <kitsuyui@kitsuyui.com>",
"exports": {
".": {
"require": "./dist/index.js",
"import": "./dist/index.mjs",
"types": "./dist/index.d.ts"
"require": {
"type": "./dist/index.d.mts",
"default": "./dist/index.cjs"
},
"import": {
"type": "./dist/index.d.mts",
"default": "./dist/index.mjs"
}
}
},
"main": "./dist/index.js",
Expand All @@ -23,35 +28,24 @@
"dev": "tsup --config ../../tsup.config.mjs --watch"
},
"devDependencies": {
"@kitsuyui/react-binary": "workspace:^",
"@kitsuyui/react-biticon": "workspace:^",
"@kitsuyui/react-clock": "workspace:^",
"@kitsuyui/react-dekamoji": "workspace:^",
"@kitsuyui/react-editablelabel": "workspace:^",
"@kitsuyui/react-measure": "workspace:^",
"@kitsuyui/react-stopwatch": "workspace:^",
"@kitsuyui/react-tab": "workspace:^",
"@kitsuyui/react-textfield": "workspace:^",
"@kitsuyui/react-timer": "workspace:^",
"@kitsuyui/react-treemap": "workspace:^",
"@types/react": "^19.0.1",
"@types/react-dom": "^19.0.1",
"react": "^19.0.0",
"react-dom": "^19.0.0",
"react-use": "^17.5.1"
},
"peerDependencies": {
"@kitsuyui/react-binary": "workspace:latest",
"@kitsuyui/react-biticon": "workspace:latest",
"@kitsuyui/react-clock": "workspace:latest",
"@kitsuyui/react-dekamoji": "workspace:latest",
"@kitsuyui/react-editablelabel": "workspace:latest",
"@kitsuyui/react-measure": "workspace:latest",
"@kitsuyui/react-stopwatch": "workspace:latest",
"@kitsuyui/react-tab": "workspace:latest",
"@kitsuyui/react-textfield": "workspace:latest",
"@kitsuyui/react-timer": "workspace:latest",
"@kitsuyui/react-treemap": "workspace:latest",
"@kitsuyui/react-binary": "workspace:*",
"@kitsuyui/react-biticon": "workspace:*",
"@kitsuyui/react-clock": "workspace:*",
"@kitsuyui/react-dekamoji": "workspace:*",
"@kitsuyui/react-editablelabel": "workspace:*",
"@kitsuyui/react-measure": "workspace:*",
"@kitsuyui/react-stopwatch": "workspace:*",
"@kitsuyui/react-tab": "workspace:*",
"@kitsuyui/react-textfield": "workspace:*",
"@kitsuyui/react-timer": "workspace:*",
"@kitsuyui/react-treemap": "workspace:*",
"react": "*",
"react-dom": "*",
"react-use": "*"
Expand Down
13 changes: 9 additions & 4 deletions packages/dekamoji/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,14 @@
"author": "Yui Kitsu <kitsuyui@kitsuyui.com>",
"exports": {
".": {
"require": "./dist/index.js",
"import": "./dist/index.mjs",
"types": "./dist/index.d.ts"
"require": {
"type": "./dist/index.d.mts",
"default": "./dist/index.cjs"
},
"import": {
"type": "./dist/index.d.mts",
"default": "./dist/index.mjs"
}
}
},
"main": "./dist/index.js",
Expand All @@ -35,4 +40,4 @@
"react-dom": "*",
"react-use": "*"
}
}
}
17 changes: 11 additions & 6 deletions packages/editablelabel/package.json
Original file line number Diff line number Diff line change
@@ -1,14 +1,19 @@
{
"name": "@kitsuyui/react-editablelabel",
"version": "0.0.0",
"version": "0.1.6",
"description": "A component that can edit label",
"license": "MIT",
"author": "Yui Kitsu <kitsuyui@kitsuyui.com>",
"exports": {
".": {
"require": "./dist/index.js",
"import": "./dist/index.mjs",
"types": "./dist/index.d.ts"
"require": {
"type": "./dist/index.d.mts",
"default": "./dist/index.cjs"
},
"import": {
"type": "./dist/index.d.mts",
"default": "./dist/index.mjs"
}
}
},
"main": "./dist/index.js",
Expand All @@ -31,9 +36,9 @@
"react-use": "^17.5.1"
},
"peerDependencies": {
"@kitsuyui/react-textfield": "workspace:latest",
"@kitsuyui/react-textfield": "workspace:*",
"react": "*",
"react-dom": "*",
"react-use": "*"
}
}
}
11 changes: 8 additions & 3 deletions packages/measure/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,14 @@
"author": "Yui Kitsu <kitsuyui@kitsuyui.com>",
"exports": {
".": {
"require": "./dist/index.js",
"import": "./dist/index.mjs",
"types": "./dist/index.d.ts"
"require": {
"type": "./dist/index.d.mts",
"default": "./dist/index.cjs"
},
"import": {
"type": "./dist/index.d.mts",
"default": "./dist/index.mjs"
}
}
},
"main": "./dist/index.js",
Expand Down
5 changes: 3 additions & 2 deletions packages/measure/src/base.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,10 @@ export const MeasureBase = (props: { width: number, height: number, styles: Meas
strokeDasharray={stroke.dasharray}
/>
{
lines.map((line) => (
// biome-ignore lint/correctness/useJsxKeyInIterable: lines are always 4 items, so no need to add key
lines.map((line, index) => (
<line
// biome-ignore lint/suspicious/noArrayIndexKey: lines are always 4 items, so no need to add key
key={index}
x1={line.start.x}
y1={line.start.y}
x2={line.end.x}
Expand Down
11 changes: 8 additions & 3 deletions packages/physical-size/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,14 @@
"author": "Yui Kitsu <kitsuyui@kitsuyui.com>",
"exports": {
".": {
"require": "./dist/index.js",
"import": "./dist/index.mjs",
"types": "./dist/index.d.ts"
"require": {
"type": "./dist/index.d.mts",
"default": "./dist/index.cjs"
},
"import": {
"type": "./dist/index.d.mts",
"default": "./dist/index.mjs"
}
}
},
"main": "./dist/index.js",
Expand Down
11 changes: 8 additions & 3 deletions packages/stopwatch/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,14 @@
"author": "Yui Kitsu <kitsuyui@kitsuyui.com>",
"exports": {
".": {
"require": "./dist/index.js",
"import": "./dist/index.mjs",
"types": "./dist/index.d.ts"
"require": {
"type": "./dist/index.d.mts",
"default": "./dist/index.cjs"
},
"import": {
"type": "./dist/index.d.mts",
"default": "./dist/index.mjs"
}
}
},
"main": "./dist/index.js",
Expand Down
Loading

0 comments on commit d9c1730

Please sign in to comment.