Skip to content

Commit

Permalink
1792: v0.6.14
Browse files Browse the repository at this point in the history
  • Loading branch information
MuTsunTsai committed May 13, 2024
2 parents b091432 + 21767db commit f46dc00
Show file tree
Hide file tree
Showing 29 changed files with 8,498 additions and 7,627 deletions.
4 changes: 1 addition & 3 deletions .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -218,9 +218,7 @@
],
"@typescript-eslint/no-namespace": "off",
"@typescript-eslint/no-non-null-assertion": "off",
"@typescript-eslint/no-shadow": [
"warn"
],
"@typescript-eslint/no-shadow": "warn",
"@typescript-eslint/no-this-alias": [
"warn",
{
Expand Down
1 change: 0 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,6 @@
},
"files.exclude": {
"**/debug.log": true,
"**/node_modules": true,
"test-results/": true,
".nyc_output": true
},
Expand Down
14 changes: 8 additions & 6 deletions e2e/specs/bpstudio.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,29 +11,31 @@ test("Basic UI", async ({ page }) => {
await expect(page).toHaveTitle(/Box Pleating Studio/);
const menu = page.getByRole("menubar");
await expect(menu).toBeInViewport();
await expect(menu.getByRole("menu").first()).not.toBeDisabled();
await expect(menu.getByRole("menuitem").first()).not.toBeDisabled();
await expect(page.getByRole("toolbar")).toBeInViewport();
await expect(page.getByRole("form")).toBeAttached();
await expect(page.getByRole("complementary")).toBeAttached(); // <aside>
await expect(page.getByRole("contentinfo")).toBeAttached(); // <footer>
await expect(page.locator(".noscript")).not.toBeAttached();
});

test("Project creation", async ({ page }) => {
await page.getByRole("menu", { name: "File" }).click();
await page.getByRole("menuitem", { name: "File" }).click();
await page.getByRole("menuitem", { name: "New" }).click();
const locator = page.getByRole("tab");
await expect(locator).toBeAttached();
await expect(locator).toContainText("Untitled");
});

test("Basic vertex dragging", async ({ page }) => {
await page.getByRole("menu", { name: "File" }).click();
await page.getByRole("menuitem", { name: "File" }).click();
await page.getByRole("menuitem", { name: "New" }).click();
await expect(page.getByRole("tab")).toBeAttached();
await page.mouse.move(514, 282);
await page.mouse.down();
const bpHandle = await page.evaluateHandle<typeof Studio>("bp");
expect(await page.evaluate(([bp]) => (bp.selection.selections[0] as Vertex).$location.x, [bpHandle])).toBe(10);
const getX = () => page.evaluate(bp => (bp.selection.selections[0] as Vertex).$location.x, bpHandle);
expect(await getX()).toBe(10);
await page.mouse.move(601, 282);
await page.mouse.up();
expect(await page.evaluate(([bp]) => (bp.selection.selections[0] as Vertex).$location.x, [bpHandle])).toBe(13);
expect(await getX()).toBe(13);
});
7 changes: 6 additions & 1 deletion gulp/tasks/ftp.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,12 @@ async function ftpFactory(folder, additionalGlobs, pipeFactory) {
].concat(additionalGlobs);

const base = `/public_html/${folder}`;
const pipe = gulp.src(globs, { base: config.dest.dist, buffer: false });
const pipe = gulp.src(globs, {
base: config.dest.dist,
buffer: false,
dot: true, // Gulp v5, for .htaccess
encoding: false, // Gulp v5
});
await streamToPromise(
(pipeFactory ? pipeFactory(pipe) : pipe)
.pipe(conn.newer(base))
Expand Down
6 changes: 5 additions & 1 deletion gulp/tasks/static.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,11 @@ const copyStatic = () => gulp.src([
"!index.htm",
"!log/*",
"!assets/bps/**/*",
], { cwd: config.src.public, base: config.src.public })
], {
cwd: config.src.public,
base: config.src.public,
encoding: false, // Gulp v5
})
.pipe(newer(config.dest.dist)) // Use 1:1 comparison
.pipe($.if(file => file.extname == ".js", $.terser({
compress: {
Expand Down
4 changes: 3 additions & 1 deletion gulp/tasks/static/icon.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ const woff2 = require("../../plugins/woff2");

/** Build BPS icon set */
module.exports = () =>
gulp.src(config.src.public + "/assets/bps/**/*")
gulp.src(config.src.public + "/assets/bps/**/*", {
encoding: false, // Gulp v5
})
.pipe(newer({
dest: config.dest.dist + "/assets/bps/style.css",
extra: [__filename, "gulp/plugins/woff2.js"],
Expand Down
112 changes: 53 additions & 59 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "box-pleating-studio",
"version": "0.6.13",
"app_version": "1782",
"version": "0.6.14",
"app_version": "1792",
"description": "Super-complex origami design made easy!",
"keywords": [
"origami",
Expand Down Expand Up @@ -39,128 +39,122 @@
"@intlify/vue-i18n-extensions": "^5.0.1",
"@makeomatic/gulp-wrap-js": "^1.0.2",
"@mutsuntsai/esbuild-plugin-vue": "^0.1.6",
"@playwright/test": "^1.42.1",
"@stylistic/eslint-plugin": "^1.6.3",
"@swc/core": "^1.4.5",
"@playwright/test": "^1.44.0",
"@stylistic/eslint-plugin": "^1.8.1",
"@swc/core": "^1.5.5",
"@types/bootstrap": "^5.2.10",
"@types/chai": "^4.3.12",
"@types/chai": "^4.3.16",
"@types/gtag.js": "^0.0.19",
"@types/gulp": "^4.0.17",
"@types/gulp-load-plugins": "^0.0.37",
"@types/mocha": "^10.0.6",
"@types/node": "^20.11.25",
"@types/wicg-file-system-access": "^2023.10.4",
"@typescript-eslint/eslint-plugin": "^7.1.1",
"@typescript-eslint/parser": "^7.1.1",
"@vue/compiler-sfc": "^3.4.21",
"@vue/eslint-config-typescript": "12.0.0",
"chai": "^5.1.0",
"@types/node": "^20.12.11",
"@types/wicg-file-system-access": "^2023.10.5",
"@typescript-eslint/eslint-plugin": "^7.8.0",
"@typescript-eslint/parser": "^7.8.0",
"@vue/compiler-sfc": "^3.4.27",
"@vue/eslint-config-typescript": "13.0.0",
"chai": "^5.1.1",
"del": "7.1.0",
"esbuild": "^0.20.1",
"esbuild": "^0.21.2",
"esbuild-ifdef": "^0.2.0",
"esbuild-sass-plugin": "^3.1.0",
"esbuild-sass-plugin": "^3.2.0",
"eslint": "^8.57.0",
"eslint-import-resolver-typescript": "^3.6.1",
"eslint-plugin-compat": "^4.2.0",
"eslint-plugin-html": "^8.0.0",
"eslint-plugin-html": "^8.1.1",
"eslint-plugin-import": "^2.29.1",
"eslint-plugin-jsdoc": "^48.2.1",
"eslint-plugin-jsdoc": "^48.2.4",
"eslint-plugin-local-rules": "^2.0.1",
"eslint-plugin-mocha": "^10.4.0",
"eslint-plugin-mocha": "^10.4.3",
"eslint-plugin-typescript-compat": "^1.0.2",
"eslint-plugin-vue": "^9.22.0",
"eslint-plugin-vue": "^9.26.0",
"fancy-log": "^2.0.0",
"global-jsdom": "^24.0.0",
"gulp": "^4.0.2",
"gulp": "^5.0.0",
"gulp-all": "^1.1.0",
"gulp-clean-css": "^4.3.0",
"gulp-concat": "^2.6.1",
"gulp-esbuild": "^0.12.0",
"gulp-filter": "^9.0.1",
"gulp-fontawesome": "^1.0.2",
"gulp-fontawesome": "^1.0.4",
"gulp-html-minifier-terser": "7.1.0",
"gulp-if": "^3.0.0",
"gulp-load-plugins": "^2.0.8",
"gulp-newer": "^1.4.0",
"gulp-postcss": "^10.0.0",
"gulp-purgecss": "5.0.0",
"gulp-purgecss": "6.0.0",
"gulp-replace": "^1.1.4",
"gulp-sass": "^5.1.0",
"gulp-terser": "^2.1.0",
"gulp-through2": "^1.0.2",
"gulp-vue-ssg": "^1.2.2",
"gulp-vue-ssg": "^1.2.4",
"gulp-workbox": "^1.0.6",
"http-server": "^14.1.1",
"inquirer": "^9.2.15",
"inquirer": "^9.2.20",
"jsdom": "^24.0.0",
"lazypipe": "^1.0.2",
"marked": "^12.0.1",
"mocha": "^10.3.0",
"marked": "^12.0.2",
"mocha": "^10.4.0",
"mocha-suppress-logs": "^0.5.1",
"nyc": "^15.1.0",
"postcss": "^8.4.35",
"postcss-html": "^1.6.0",
"postcss-preset-env": "^9.5.0",
"postcss": "^8.4.38",
"postcss-html": "^1.7.0",
"postcss-preset-env": "^9.5.12",
"require-dir": "^1.2.0",
"resolve": "^1.22.8",
"sass": "^1.71.1",
"stylelint": "^16.2.1",
"stylelint-config-clean-order": "^5.4.1",
"sass": "^1.77.1",
"stylelint": "^16.5.0",
"stylelint-config-clean-order": "^5.4.2",
"stylelint-config-recommended-vue": "^1.5.0",
"stylelint-config-standard-scss": "^13.0.0",
"stylelint-config-standard-scss": "^13.1.0",
"stylelint-no-unsupported-browser-features": "^8.0.1",
"through2": "^4.0.2",
"ts-node": "^10.9.2",
"tsconfig-paths": "^4.2.0",
"ttf2woff2": "^5.0.0",
"typescript": "5.3.3",
"typescript": "^5.4.5",
"vinyl-ftp": "^0.6.1",
"vue-eslint-parser": "^9.4.2",
"workbox-build": "^7.0.0",
"workbox-build": "^7.1.0",
"yargs": "^17.7.2"
},
"dependencies": {
"@fortawesome/fontawesome-free": "^6.5.1",
"@paypal/paypal-js": "^8.0.2",
"@pixi/constants": "^7.4.0",
"@pixi/core": "^7.4.0",
"@pixi/display": "^7.4.0",
"@pixi/events": "^7.4.0",
"@pixi/filter-alpha": "^7.4.0",
"@pixi/graphics": "^7.4.0",
"@fortawesome/fontawesome-free": "^6.5.2",
"@paypal/paypal-js": "^8.0.5",
"@pixi/constants": "^7.4.2",
"@pixi/core": "^7.4.2",
"@pixi/display": "^7.4.2",
"@pixi/events": "^7.4.2",
"@pixi/filter-alpha": "^7.4.2",
"@pixi/graphics": "^7.4.2",
"@pixi/graphics-smooth": "^1.1.0",
"@pixi/math": "^7.4.0",
"@pixi/sprite": "^7.4.0",
"@pixi/text": "^7.4.0",
"@pixi/utils": "^7.4.0",
"@pixi/math": "^7.4.2",
"@pixi/sprite": "^7.4.2",
"@pixi/text": "^7.4.2",
"@pixi/utils": "^7.4.2",
"@popperjs/core": "^2.11.8",
"bootstrap": "^5.3.3",
"idb-keyval": "^6.2.1",
"jszip": "^3.10.1",
"lzma": "^2.3.2",
"vue": "^3.4.21",
"vue-i18n": "^9.10.1",
"vue": "^3.4.27",
"vue-i18n": "^9.13.1",
"vue-slicksort": "^2.0.5",
"workbox-broadcast-update": "^7.0.0",
"workbox-precaching": "^7.0.0",
"workbox-routing": "^7.0.0",
"workbox-strategies": "^7.0.0"
"workbox-broadcast-update": "^7.1.0",
"workbox-precaching": "^7.1.0",
"workbox-routing": "^7.1.0",
"workbox-strategies": "^7.1.0"
},
"pnpm": {
"overrides": {
"glob-watcher": "^6.0.0",
"micromatch": "^4.0.0",
"magic-string": "^0.27.0",
"glob-parent": "^6.0.0",
"node-gyp": "^10.0.0"
},
"peerDependencyRules": {
"allowAny": [
"esbuild"
]
},
"allowedDeprecatedVersions": {
"rollup-plugin-terser": "*"
}
}
}
Loading

0 comments on commit f46dc00

Please sign in to comment.