From 7de2383c1e803066b666bb73e8a9bca327d8c4ca Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 27 Mar 2022 09:19:53 +0000 Subject: [PATCH 01/21] Bump minimist from 1.2.5 to 1.2.6 Bumps [minimist](https://github.com/substack/minimist) from 1.2.5 to 1.2.6. - [Release notes](https://github.com/substack/minimist/releases) - [Commits](https://github.com/substack/minimist/compare/1.2.5...1.2.6) --- updated-dependencies: - dependency-name: minimist dependency-type: indirect ... Signed-off-by: dependabot[bot] --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index d27eaee..408c145 100644 --- a/yarn.lock +++ b/yarn.lock @@ -8186,9 +8186,9 @@ minimatch@3.0.4, minimatch@^3.0.4: brace-expansion "^1.1.7" minimist@^1.1.1, minimist@^1.2.0, minimist@^1.2.5: - version "1.2.5" - resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.5.tgz#67d66014b66a6a8aaa0c083c5fd58df4e4e97602" - integrity sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw== + version "1.2.6" + resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.6.tgz#8637a5b759ea0d6e98702cfb3a9283323c93af44" + integrity sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q== minipass-collect@^1.0.2: version "1.0.2" From 7e6dfc3fcb8c8b9f3d631d90ce43752ae0e2e3df Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 16 May 2022 18:43:31 +0000 Subject: [PATCH 02/21] Bump cross-fetch from 2.2.3 to 2.2.6 Bumps [cross-fetch](https://github.com/lquixada/cross-fetch) from 2.2.3 to 2.2.6. - [Release notes](https://github.com/lquixada/cross-fetch/releases) - [Commits](https://github.com/lquixada/cross-fetch/compare/v2.2.3...v2.2.6) --- updated-dependencies: - dependency-name: cross-fetch dependency-type: indirect ... Signed-off-by: dependabot[bot] --- yarn.lock | 42 +++++++++++++++++++++++++++++++----------- 1 file changed, 31 insertions(+), 11 deletions(-) diff --git a/yarn.lock b/yarn.lock index d27eaee..9961a0f 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3600,12 +3600,12 @@ create-hmac@^1.1.0, create-hmac@^1.1.4, create-hmac@^1.1.7: sha.js "^2.4.8" cross-fetch@^2.2.2: - version "2.2.3" - resolved "https://registry.yarnpkg.com/cross-fetch/-/cross-fetch-2.2.3.tgz#e8a0b3c54598136e037f8650f8e823ccdfac198e" - integrity sha512-PrWWNH3yL2NYIb/7WF/5vFG3DCQiXDOVf8k3ijatbrtnwNuhMWLC7YF7uqf53tbTFDzHIUD8oITw4Bxt8ST3Nw== + version "2.2.6" + resolved "https://registry.yarnpkg.com/cross-fetch/-/cross-fetch-2.2.6.tgz#2ef0bb39a24ac034787965c457368a28730e220a" + integrity sha512-9JZz+vXCmfKUZ68zAptS7k4Nu8e2qcibe7WVZYps7sAgk5R8GYTc+T1WR0v1rlP9HxgARmOX1UTIJZFytajpNA== dependencies: - node-fetch "2.1.2" - whatwg-fetch "2.0.4" + node-fetch "^2.6.7" + whatwg-fetch "^2.0.4" cross-spawn@7.0.1: version "7.0.1" @@ -8407,11 +8407,6 @@ node-fetch-npm@^2.0.2: json-parse-better-errors "^1.0.0" safe-buffer "^5.1.1" -node-fetch@2.1.2: - version "2.1.2" - resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.1.2.tgz#ab884e8e7e57e38a944753cec706f788d1768bb5" - integrity sha1-q4hOjn5X44qUR1POxwb3iNF2i7U= - node-fetch@^1.7.3: version "1.7.3" resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-1.7.3.tgz#980f6f72d85211a5347c6b2bc18c5b84c3eb47ef" @@ -8420,6 +8415,13 @@ node-fetch@^1.7.3: encoding "^0.1.11" is-stream "^1.0.1" +node-fetch@^2.6.7: + version "2.6.7" + resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.6.7.tgz#24de9fba827e3b4ae44dc8b20256a379160052ad" + integrity sha512-ZjMPFEfVx5j+y2yF35Kzx5sF7kDzxuDj6ziH4FFbOp87zKDZNx8yExJIb05OGF4Nlt9IHFIMBkRl41VdvcNdbQ== + dependencies: + whatwg-url "^5.0.0" + node-forge@^0.10.0: version "0.10.0" resolved "https://registry.yarnpkg.com/node-forge/-/node-forge-0.10.0.tgz#32dea2afb3e9926f02ee5ce8794902691a676bf3" @@ -12269,6 +12271,11 @@ tr46@^2.0.2: dependencies: punycode "^2.1.1" +tr46@~0.0.3: + version "0.0.3" + resolved "https://registry.yarnpkg.com/tr46/-/tr46-0.0.3.tgz#8184fd347dac9cdc185992f3a6622e14b9d9ab6a" + integrity sha1-gYT9NH2snNwYWZLzpmIuFLnZq2o= + ts-jest@24.0.2: version "24.0.2" resolved "https://registry.yarnpkg.com/ts-jest/-/ts-jest-24.0.2.tgz#8dde6cece97c31c03e80e474c749753ffd27194d" @@ -12736,6 +12743,11 @@ wcwidth@^1.0.0: dependencies: defaults "^1.0.3" +webidl-conversions@^3.0.0: + version "3.0.1" + resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-3.0.1.tgz#24534275e2a7bc6be7bc86611cc16ae0a5654871" + integrity sha1-JFNCdeKnvGvnvIZhHMFq4KVlSHE= + webidl-conversions@^4.0.2: version "4.0.2" resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-4.0.2.tgz#a855980b1f0b6b359ba1d5d9fb39ae941faa63ad" @@ -12884,7 +12896,7 @@ whatwg-encoding@^1.0.1, whatwg-encoding@^1.0.3, whatwg-encoding@^1.0.5: dependencies: iconv-lite "0.4.24" -whatwg-fetch@2.0.4: +whatwg-fetch@^2.0.4: version "2.0.4" resolved "https://registry.yarnpkg.com/whatwg-fetch/-/whatwg-fetch-2.0.4.tgz#dde6a5df315f9d39991aa17621853d720b85566f" integrity sha512-dcQ1GWpOD/eEQ97k66aiEVpNnapVj90/+R+SXTPYGHpYBBypfKJEQjLrvMZ7YXbKm21gXd4NcuxUTjiv1YtLng== @@ -12899,6 +12911,14 @@ whatwg-mimetype@^2.1.0, whatwg-mimetype@^2.2.0, whatwg-mimetype@^2.3.0: resolved "https://registry.yarnpkg.com/whatwg-mimetype/-/whatwg-mimetype-2.3.0.tgz#3d4b1e0312d2079879f826aff18dbeeca5960fbf" integrity sha512-M4yMwr6mAnQz76TbJm914+gPpB/nCwvZbJU28cUD6dR004SAxDLOOSUaB1JDRqLtaOV/vi0IC5lEAGFgrjGv/g== +whatwg-url@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-5.0.0.tgz#966454e8765462e37644d3626f6742ce8b70965d" + integrity sha1-lmRU6HZUYuN2RNNib2dCzotwll0= + dependencies: + tr46 "~0.0.3" + webidl-conversions "^3.0.0" + whatwg-url@^6.4.1: version "6.5.0" resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-6.5.0.tgz#f2df02bff176fd65070df74ad5ccbb5a199965a8" From b49d1382ec56e7f79b37166435606c22aca783d5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 1 Jun 2022 20:03:53 +0000 Subject: [PATCH 03/21] Bump eventsource from 1.0.7 to 1.1.1 Bumps [eventsource](https://github.com/EventSource/eventsource) from 1.0.7 to 1.1.1. - [Release notes](https://github.com/EventSource/eventsource/releases) - [Changelog](https://github.com/EventSource/eventsource/blob/master/HISTORY.md) - [Commits](https://github.com/EventSource/eventsource/compare/v1.0.7...v1.1.1) --- updated-dependencies: - dependency-name: eventsource dependency-type: indirect ... Signed-off-by: dependabot[bot] --- yarn.lock | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/yarn.lock b/yarn.lock index d27eaee..69980cb 100644 --- a/yarn.lock +++ b/yarn.lock @@ -4889,9 +4889,9 @@ events@^3.0.0: integrity sha512-/46HWwbfCX2xTawVfkKLGxMifJYQBWMwY1mjywRtb4c9x8l5NP3KoJtnIOiL1hfdRkIuYhETxQlo62IF8tcnlg== eventsource@^1.0.7: - version "1.0.7" - resolved "https://registry.yarnpkg.com/eventsource/-/eventsource-1.0.7.tgz#8fbc72c93fcd34088090bc0a4e64f4b5cee6d8d0" - integrity sha512-4Ln17+vVT0k8aWq+t/bF5arcS3EpT9gYtW66EPacdj/mAFevznsnyoHLPy2BA8gbIQeIHoPsvwmfBftfcG//BQ== + version "1.1.1" + resolved "https://registry.yarnpkg.com/eventsource/-/eventsource-1.1.1.tgz#4544a35a57d7120fba4fa4c86cb4023b2c09df2f" + integrity sha512-qV5ZC0h7jYIAOhArFJgSfdyz6rALJyb270714o7ZtNnw2WSJ+eexhKtE0O8LYPRsHZHf2osHKZBxGPvm3kPkCA== dependencies: original "^1.0.0" @@ -12536,9 +12536,9 @@ url-parse-lax@^1.0.0: prepend-http "^1.0.1" url-parse@^1.4.3: - version "1.5.3" - resolved "https://registry.yarnpkg.com/url-parse/-/url-parse-1.5.3.tgz#71c1303d38fb6639ade183c2992c8cc0686df862" - integrity sha512-IIORyIQD9rvj0A4CLWsHkBBJuNqWpFQe224b6j9t/ABmquIS0qDU2pY6kl6AuOrL5OkCXHMCFNe1jBcuAggjvQ== + version "1.5.10" + resolved "https://registry.yarnpkg.com/url-parse/-/url-parse-1.5.10.tgz#9d3c2f736c1d75dd3bd2be507dcc111f1e2ea9c1" + integrity sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ== dependencies: querystringify "^2.1.1" requires-port "^1.0.0" From d028e411c3ee676467886f97b9551c51dcf90c91 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 21 Jul 2022 05:35:36 +0000 Subject: [PATCH 04/21] Bump terser from 4.8.0 to 4.8.1 Bumps [terser](https://github.com/terser/terser) from 4.8.0 to 4.8.1. - [Release notes](https://github.com/terser/terser/releases) - [Changelog](https://github.com/terser/terser/blob/master/CHANGELOG.md) - [Commits](https://github.com/terser/terser/commits) --- updated-dependencies: - dependency-name: terser dependency-type: indirect ... Signed-off-by: dependabot[bot] --- yarn.lock | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/yarn.lock b/yarn.lock index d27eaee..da4a946 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2786,11 +2786,16 @@ bser@2.1.1: dependencies: node-int64 "^0.4.0" -buffer-from@1.x, buffer-from@^1.0.0: +buffer-from@1.x: version "1.1.1" resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.1.tgz#32713bc028f75c02fdb710d7c7bcec1f2c6070ef" integrity sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A== +buffer-from@^1.0.0: + version "1.1.2" + resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.2.tgz#2b146a6fd72e80b4f55d255f35ed59a3a9a41bd5" + integrity sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ== + buffer-indexof@^1.0.0: version "1.1.1" resolved "https://registry.yarnpkg.com/buffer-indexof/-/buffer-indexof-1.1.1.tgz#52fabcc6a606d1a00302802648ef68f639da268c" @@ -11601,9 +11606,9 @@ source-map-resolve@^0.5.0, source-map-resolve@^0.5.2: urix "^0.1.0" source-map-support@^0.5.6, source-map-support@~0.5.12: - version "0.5.19" - resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.19.tgz#a98b62f86dcaf4f67399648c085291ab9e8fed61" - integrity sha512-Wonm7zOCIJzBGQdB+thsPar0kYuCIzYvxZwlBa87yi/Mdjv7Tip2cyVbLj5o0cFPN4EVkuTwb3GDDyUx2DGnGw== + version "0.5.21" + resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.21.tgz#04fe7c7f9e1ed2d662233c28cb2b35b9f63f6e4f" + integrity sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w== dependencies: buffer-from "^1.0.0" source-map "^0.6.0" @@ -12111,9 +12116,9 @@ terser-webpack-plugin@^1.4.3: worker-farm "^1.7.0" terser@^4.1.2, terser@^4.6.12, terser@^4.6.3: - version "4.8.0" - resolved "https://registry.yarnpkg.com/terser/-/terser-4.8.0.tgz#63056343d7c70bb29f3af665865a46fe03a0df17" - integrity sha512-EAPipTNeWsb/3wLPeup1tVPaXfIaU68xMnVdPafIL1TV05OhASArYyIfFvnvJCNrR2NIOvDVNNTFRa+Re2MWyw== + version "4.8.1" + resolved "https://registry.yarnpkg.com/terser/-/terser-4.8.1.tgz#a00e5634562de2239fd404c649051bf6fc21144f" + integrity sha512-4GnLC0x667eJG0ewJTa6z/yXrbLGv80D9Ru6HIpCQmO+Q4PfEtBFi0ObSckqwL6VyQv/7ENJieXHo2ANmdQwgw== dependencies: commander "^2.20.0" source-map "~0.6.1" From a0aa926639849231f63137ce2d0fb91e3200dcd3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Van=20Keisbelck?= Date: Fri, 2 Sep 2022 11:01:52 +0200 Subject: [PATCH 05/21] CHANGELOG --- CHANGELOG.md | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index b96c2a5..d9c3f3c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,34 @@ # Changelog +## v2.2.1 (02/09/2022) + +#### closed + +- [**closed**] support unmount [#87](https://github.com/vankeisb/react-tea-cup/pull/87) + +--- + +## v2.2.0 (10/02/2022) + +#### closed + +- [**closed**] Adding support for React 17 [#73](https://github.com/vankeisb/react-tea-cup/pull/73) +- [**closed**] eventlisteners with options [#66](https://github.com/vankeisb/react-tea-cup/pull/66) + +#### dependencies + +- [**dependencies**] Bump color-string from 1.5.3 to 1.9.0 [#76](https://github.com/vankeisb/react-tea-cup/pull/76) +- [**dependencies**] Bump ws from 5.2.2 to 5.2.3 [#74](https://github.com/vankeisb/react-tea-cup/pull/74) +- [**dependencies**] Bump tar from 4.4.13 to 4.4.19 [#75](https://github.com/vankeisb/react-tea-cup/pull/75) +- [**dependencies**] Bump merge-deep from 3.0.2 to 3.0.3 [#68](https://github.com/vankeisb/react-tea-cup/pull/68) +- [**dependencies**] Bump path-parse from 1.0.6 to 1.0.7 [#69](https://github.com/vankeisb/react-tea-cup/pull/69) +- [**dependencies**] Bump tmpl from 1.0.4 to 1.0.5 [#70](https://github.com/vankeisb/react-tea-cup/pull/70) +- [**dependencies**] Bump url-parse from 1.5.1 to 1.5.3 [#71](https://github.com/vankeisb/react-tea-cup/pull/71) +- [**dependencies**] Bump url-parse from 1.4.7 to 1.5.1 [#64](https://github.com/vankeisb/react-tea-cup/pull/64) +- [**dependencies**] Bump hosted-git-info from 2.8.8 to 2.8.9 [#65](https://github.com/vankeisb/react-tea-cup/pull/65) + +--- + ## v2.1.0 (03/05/2021) #### closed From 82d4efbced0ae0abe9dde667af23ea7844720c6c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 2 Sep 2022 09:04:26 +0000 Subject: [PATCH 06/21] Bump jsdom from 16.4.0 to 16.5.0 Bumps [jsdom](https://github.com/jsdom/jsdom) from 16.4.0 to 16.5.0. - [Release notes](https://github.com/jsdom/jsdom/releases) - [Changelog](https://github.com/jsdom/jsdom/blob/master/Changelog.md) - [Commits](https://github.com/jsdom/jsdom/compare/16.4.0...16.5.0) --- updated-dependencies: - dependency-name: jsdom dependency-type: direct:development ... Signed-off-by: dependabot[bot] --- tea-cup/package.json | 2 +- yarn.lock | 116 ++++++++++++++++++++++++++++--------------- 2 files changed, 77 insertions(+), 41 deletions(-) diff --git a/tea-cup/package.json b/tea-cup/package.json index 581bab7..53e77fd 100644 --- a/tea-cup/package.json +++ b/tea-cup/package.json @@ -27,6 +27,6 @@ "devDependencies": { "@types/jsdom": "^16.2.5", "@types/react": "^16.7.22", - "jsdom": "^16.4.0" + "jsdom": "^16.5.0" } } \ No newline at end of file diff --git a/yarn.lock b/yarn.lock index d27eaee..bc6ac92 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1870,10 +1870,10 @@ JSONStream@^1.3.4, JSONStream@^1.3.5: jsonparse "^1.2.0" through ">=2.2.7 <3" -abab@^2.0.0, abab@^2.0.3: - version "2.0.5" - resolved "https://registry.yarnpkg.com/abab/-/abab-2.0.5.tgz#c0b678fb32d60fc1219c784d6a826fe385aeb79a" - integrity sha512-9IK9EadsbHo6jLWIpxpR6pL0sazTXV6+SQv25ZB+F7Bj9mJNaOc4nCRabwd5M/JwmUa8idz6Eci6eKfJryPs6Q== +abab@^2.0.0, abab@^2.0.3, abab@^2.0.5: + version "2.0.6" + resolved "https://registry.yarnpkg.com/abab/-/abab-2.0.6.tgz#41b80f2c871d19686216b82309231cfd3cb3d291" + integrity sha512-j2afSsaIENvHZN2B8GOpF566vZ5WVk5opAiMTvWgaQT8DkbOqsTfvNAvHoRGU2zzP8cPoqys+xHTRDWW8L+/BA== abbrev@1, abbrev@~1.1.1: version "1.1.1" @@ -1934,6 +1934,11 @@ acorn@^7.1.1: resolved "https://registry.yarnpkg.com/acorn/-/acorn-7.4.0.tgz#e1ad486e6c54501634c6c397c5c121daa383607c" integrity sha512-+G7P8jJmCHr+S+cLfQxygbWhXy+8YTVGzAkpEbcLo2mLoL7tij/VG41QSHACSf5QgYRhMZYHuNc6drJaO0Da+w== +acorn@^8.0.5: + version "8.8.0" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.8.0.tgz#88c0187620435c7f6015803f5539dae05a9dbea8" + integrity sha512-QOxyigPVrpZ2GXT+PFyZTl6TtOFc5egxHIP9IlQ+RbupQuX4RkT/Bee4/kQuC02Xkzg84JcT7oLYtDIQxp+v7w== + address@1.1.2, address@^1.0.1: version "1.1.2" resolved "https://registry.yarnpkg.com/address/-/address-1.1.2.tgz#bf1116c9c758c51b7a933d296b72c221ed9428b6" @@ -3879,7 +3884,7 @@ cssstyle@^1.0.0, cssstyle@^1.1.1: dependencies: cssom "0.3.x" -cssstyle@^2.2.0: +cssstyle@^2.3.0: version "2.3.0" resolved "https://registry.yarnpkg.com/cssstyle/-/cssstyle-2.3.0.tgz#ff665a0ddbdc31864b09647f34163443d90b0852" integrity sha512-AZL67abkUzIuvcHqk7c09cezpGNcxUxU4Ioi/05xHk4DQeTkWmGYftIE6ctU6AEt+Gn4n1lDStOtj7FKycP71A== @@ -3977,10 +3982,10 @@ decamelize@^1.1.1, decamelize@^1.2.0: resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-1.2.0.tgz#f6534d15148269b20352e7bee26f501f9a191290" integrity sha1-9lNNFRSCabIDUue+4m9QH5oZEpA= -decimal.js@^10.2.0: - version "10.2.1" - resolved "https://registry.yarnpkg.com/decimal.js/-/decimal.js-10.2.1.tgz#238ae7b0f0c793d3e3cea410108b35a2c01426a3" - integrity sha512-KaL7+6Fw6i5A2XSnsbhm/6B+NuEA7TZ4vqxnd5tXz9sbKtrN9Srj8ab4vKVdK8YAqZO9P1kg45Y6YLoduPf+kw== +decimal.js@^10.2.1: + version "10.4.0" + resolved "https://registry.yarnpkg.com/decimal.js/-/decimal.js-10.4.0.tgz#97a7448873b01e92e5ff9117d89a7bca8e63e0fe" + integrity sha512-Nv6ENEzyPQ6AItkGwLE2PGKinZZ9g59vSh2BeH6NqPu0OTKZ5ruJsVqh/orbAnqXc9pBbgXAIrc2EyaCj8NpGg== decode-uri-component@^0.2.0: version "0.2.0" @@ -4643,7 +4648,7 @@ escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.5: resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" integrity sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ= -escodegen@^1.11.0, escodegen@^1.14.1, escodegen@^1.9.1: +escodegen@^1.11.0, escodegen@^1.9.1: version "1.14.3" resolved "https://registry.yarnpkg.com/escodegen/-/escodegen-1.14.3.tgz#4e7b81fba61581dc97582ed78cab7f0e8d63f503" integrity sha512-qFcX0XJkdg+PB3xjZZG/wKSuT1PnQWx57+TVSjIMmILd2yC/6ByYElPwJnslDsuWuSAp4AwJGumarAAmJch5Kw== @@ -4655,6 +4660,18 @@ escodegen@^1.11.0, escodegen@^1.14.1, escodegen@^1.9.1: optionalDependencies: source-map "~0.6.1" +escodegen@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/escodegen/-/escodegen-2.0.0.tgz#5e32b12833e8aa8fa35e1bf0befa89380484c7dd" + integrity sha512-mmHKys/C8BFUGI+MAWNcSYoORYLMdPzjrknd2Vc+bUsjN5bXcr8EhrNB+UTqfL1y3I9c4fw2ihgtMPQLBRiQxw== + dependencies: + esprima "^4.0.1" + estraverse "^5.2.0" + esutils "^2.0.2" + optionator "^0.8.1" + optionalDependencies: + source-map "~0.6.1" + eslint-config-react-app@^5.2.1: version "5.2.1" resolved "https://registry.yarnpkg.com/eslint-config-react-app/-/eslint-config-react-app-5.2.1.tgz#698bf7aeee27f0cea0139eaef261c7bf7dd623df" @@ -7283,36 +7300,36 @@ jsdom@^14.1.0: ws "^6.1.2" xml-name-validator "^3.0.0" -jsdom@^16.4.0: - version "16.4.0" - resolved "https://registry.yarnpkg.com/jsdom/-/jsdom-16.4.0.tgz#36005bde2d136f73eee1a830c6d45e55408edddb" - integrity sha512-lYMm3wYdgPhrl7pDcRmvzPhhrGVBeVhPIqeHjzeiHN3DFmD1RBpbExbi8vU7BJdH8VAZYovR8DMt0PNNDM7k8w== +jsdom@^16.5.0: + version "16.5.0" + resolved "https://registry.yarnpkg.com/jsdom/-/jsdom-16.5.0.tgz#9e453505600cc5a70b385750d35256f380730cc4" + integrity sha512-QxZH0nmDTnTTVI0YDm4RUlaUPl5dcyn62G5TMDNfMmTW+J1u1v9gCR8WR+WZ6UghAa7nKJjDOFaI00eMMWvJFQ== dependencies: - abab "^2.0.3" - acorn "^7.1.1" + abab "^2.0.5" + acorn "^8.0.5" acorn-globals "^6.0.0" cssom "^0.4.4" - cssstyle "^2.2.0" + cssstyle "^2.3.0" data-urls "^2.0.0" - decimal.js "^10.2.0" + decimal.js "^10.2.1" domexception "^2.0.1" - escodegen "^1.14.1" + escodegen "^2.0.0" html-encoding-sniffer "^2.0.1" is-potential-custom-element-name "^1.0.0" nwsapi "^2.2.0" - parse5 "5.1.1" + parse5 "6.0.1" request "^2.88.2" - request-promise-native "^1.0.8" - saxes "^5.0.0" + request-promise-native "^1.0.9" + saxes "^5.0.1" symbol-tree "^3.2.4" - tough-cookie "^3.0.1" + tough-cookie "^4.0.0" w3c-hr-time "^1.0.2" w3c-xmlserializer "^2.0.0" webidl-conversions "^6.1.0" whatwg-encoding "^1.0.5" whatwg-mimetype "^2.3.0" whatwg-url "^8.0.0" - ws "^7.2.3" + ws "^7.4.4" xml-name-validator "^3.0.0" jsesc@^2.5.1: @@ -9262,10 +9279,10 @@ parse5@5.1.0: resolved "https://registry.yarnpkg.com/parse5/-/parse5-5.1.0.tgz#c59341c9723f414c452975564c7c00a68d58acd2" integrity sha512-fxNG2sQjHvlVAYmzBZS9YlDp6PTSSDwa98vkD4QgVDDCAo84z5X1t5XyJQ62ImdLXx5NdIIfihey6xpum9/gRQ== -parse5@5.1.1: - version "5.1.1" - resolved "https://registry.yarnpkg.com/parse5/-/parse5-5.1.1.tgz#f68e4e5ba1852ac2cadc00f4555fff6c2abb6178" - integrity sha512-ugq4DFI0Ptb+WWjAdOK16+u/nHfiIrcE+sh8kZMaM0WllQKLI9rOUq6c2b7cwPkXdzfQESqvoqK6ug7U/Yyzug== +parse5@6.0.1: + version "6.0.1" + resolved "https://registry.yarnpkg.com/parse5/-/parse5-6.0.1.tgz#e1a1c085c569b3dc08321184f19a39cc27f7c30b" + integrity sha512-Ofn/CTFzRGTTxwpNEs9PP93gXShHcTq255nzRYSKe8AkVpZY7e1fpmTfOyoIvjP5HG7Z2ZM7VS9PPhQGW2pOpw== parse5@^3.0.1: version "3.0.3" @@ -10292,6 +10309,11 @@ psl@^1.1.28: resolved "https://registry.yarnpkg.com/psl/-/psl-1.8.0.tgz#9326f8bcfb013adcc005fdff056acce020e51c24" integrity sha512-RIdOzyoavK+hA18OGGWDqUTsCLhtA7IcZ/6NCs4fFJaHBDab+pDDmDIByWFRQJq2Cd7r1OoQxBGKOaztq+hjIQ== +psl@^1.1.33: + version "1.9.0" + resolved "https://registry.yarnpkg.com/psl/-/psl-1.9.0.tgz#d0df2a137f00794565fcaf3b2c00cd09f8d5a5a7" + integrity sha512-E/ZsdU4HLs/68gYzgGTkMicWTLPdAftJLfJFlLUAAKZGkStNU72sZjT66SnMDVOfOWY/YAoiD7Jxa9iHvngcag== + public-encrypt@^4.0.0: version "4.0.3" resolved "https://registry.yarnpkg.com/public-encrypt/-/public-encrypt-4.0.3.tgz#4fcc9d77a07e48ba7527e7cbe0de33d0701331e0" @@ -10907,7 +10929,7 @@ request-promise-core@1.1.4: dependencies: lodash "^4.17.19" -request-promise-native@^1.0.5, request-promise-native@^1.0.8: +request-promise-native@^1.0.5, request-promise-native@^1.0.9: version "1.0.9" resolved "https://registry.yarnpkg.com/request-promise-native/-/request-promise-native-1.0.9.tgz#e407120526a5efdc9a39b28a5679bf47b9d9dc28" integrity sha512-wcW+sIUiWnKgNY0dqCpOZkUbF/I+YPi+f09JZIDa39Ec+q82CpSYniDp+ISgTTbKmnpJWASeJBPZmoxH84wt3g== @@ -11216,7 +11238,7 @@ saxes@^3.1.9: dependencies: xmlchars "^2.1.1" -saxes@^5.0.0: +saxes@^5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/saxes/-/saxes-5.0.1.tgz#eebab953fa3b7608dbe94e5dadb15c888fa6696d" integrity sha512-5LBh1Tls8c9xgGjw3QrMwETmTMVk0oFgvrFSvWx62llR2hcEInrKNZ2GZCCuuy2lvWrdl5jhbpeqc5hRYKFOcw== @@ -12246,14 +12268,15 @@ tough-cookie@^2.3.3, tough-cookie@^2.3.4, tough-cookie@^2.5.0, tough-cookie@~2.5 psl "^1.1.28" punycode "^2.1.1" -tough-cookie@^3.0.1: - version "3.0.1" - resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-3.0.1.tgz#9df4f57e739c26930a018184887f4adb7dca73b2" - integrity sha512-yQyJ0u4pZsv9D4clxO69OEjLWYw+jbgspjTue4lTQZLfV0c5l1VmK2y1JK8E9ahdpltPOaAThPcp5nKPUgSnsg== +tough-cookie@^4.0.0: + version "4.1.2" + resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-4.1.2.tgz#e53e84b85f24e0b65dd526f46628db6c85f6b874" + integrity sha512-G9fqXWoYFZgTc2z8Q5zaHy/vJMjm+WV0AkAeHxVCQiEB1b+dGvWzFW6QV07cY5jQ5gRkeid2qIkzkxUnmoQZUQ== dependencies: - ip-regex "^2.1.0" - psl "^1.1.28" + psl "^1.1.33" punycode "^2.1.1" + universalify "^0.2.0" + url-parse "^1.5.3" tr46@^1.0.1: version "1.0.1" @@ -12463,6 +12486,11 @@ universalify@^0.1.0: resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.1.2.tgz#b646f69be3942dabcecc9d6639c80dc105efaa66" integrity sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg== +universalify@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.2.0.tgz#6451760566fa857534745ab1dde952d1b1761be0" + integrity sha512-CJ1QgKmNg3CwvAv/kOFmtnEN05f0D/cn9QntgNOQlQF9dgvVTHj3t+8JPdjqawCHk7V/KA+fbUqzZ9XWhcqPUg== + unpipe@1.0.0, unpipe@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/unpipe/-/unpipe-1.0.0.tgz#b2bf4ee8514aae6165b4817829d21b2ef49904ec" @@ -12543,6 +12571,14 @@ url-parse@^1.4.3: querystringify "^2.1.1" requires-port "^1.0.0" +url-parse@^1.5.3: + version "1.5.10" + resolved "https://registry.yarnpkg.com/url-parse/-/url-parse-1.5.10.tgz#9d3c2f736c1d75dd3bd2be507dcc111f1e2ea9c1" + integrity sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ== + dependencies: + querystringify "^2.1.1" + requires-port "^1.0.0" + url@^0.11.0: version "0.11.0" resolved "https://registry.yarnpkg.com/url/-/url-0.11.0.tgz#3838e97cfc60521eb73c525a8e55bfdd9e2e28f1" @@ -13174,10 +13210,10 @@ ws@^6.1.2, ws@^6.2.1: dependencies: async-limiter "~1.0.0" -ws@^7.2.3: - version "7.4.0" - resolved "https://registry.yarnpkg.com/ws/-/ws-7.4.0.tgz#a5dd76a24197940d4a8bb9e0e152bb4503764da7" - integrity sha512-kyFwXuV/5ymf+IXhS6f0+eAFvydbaBW3zjpT6hUdAh/hbVjTIB5EHBGi0bPoCLSK2wcuz3BrEkB9LrYv1Nm4NQ== +ws@^7.4.4: + version "7.5.9" + resolved "https://registry.yarnpkg.com/ws/-/ws-7.5.9.tgz#54fa7db29f4c7cec68b1ddd3a89de099942bb591" + integrity sha512-F+P9Jil7UiSKSkppIiD94dN07AwvFixvLIj1Og1Rl9GGMuNipJnV9JzjD6XuqmAeiswGvUmNLjr5cFuXwNS77Q== xdg-basedir@^3.0.0: version "3.0.0" From ecf789831c766795210e0788b11fdb73fca2b328 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 6 Sep 2022 11:28:12 +0000 Subject: [PATCH 07/21] Bump async from 2.6.3 to 2.6.4 Bumps [async](https://github.com/caolan/async) from 2.6.3 to 2.6.4. - [Release notes](https://github.com/caolan/async/releases) - [Changelog](https://github.com/caolan/async/blob/v2.6.4/CHANGELOG.md) - [Commits](https://github.com/caolan/async/compare/v2.6.3...v2.6.4) --- updated-dependencies: - dependency-name: async dependency-type: indirect ... Signed-off-by: dependabot[bot] --- yarn.lock | 22 +++++++--------------- 1 file changed, 7 insertions(+), 15 deletions(-) diff --git a/yarn.lock b/yarn.lock index c3451ad..36efefd 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2312,9 +2312,9 @@ async-limiter@~1.0.0: integrity sha512-csOlWGAcRFJaI6m+F2WKdnMKr4HhdhFVBk0H/QbJFMCr+uO2kwohwXQPxw/9OCxp05r5ghVBFSyioixx3gfkNQ== async@^2.6.2: - version "2.6.3" - resolved "https://registry.yarnpkg.com/async/-/async-2.6.3.tgz#d72625e2344a3656e3a3ad4fa749fa83299d82ff" - integrity sha512-zflvls11DCy+dQWzTW2dzuilv8Z5X/pjfmZOWba6TNIVDm+2UDaJmXSOXlasHKfNBs8oo3M0aT50fDEWfKZjXg== + version "2.6.4" + resolved "https://registry.yarnpkg.com/async/-/async-2.6.4.tgz#706b7ff6084664cd7eae713f6f965433b5504221" + integrity sha512-mzo5dfJYwAn29PeiJ0zvwTo04zj8HDJj0Mn8TD7sno7q12prdbnasKJHhkm2c1LgrhlJ0teaea8860oxi51mGA== dependencies: lodash "^4.17.14" @@ -7912,9 +7912,9 @@ lodash.without@~4.4.0: integrity sha1-PNRXSgC2e643OpS3SHcmQFB7eqw= "lodash@>=3.5 <5", lodash@^4.15.0, lodash@^4.17.11, lodash@^4.17.13, lodash@^4.17.14, lodash@^4.17.15, lodash@^4.17.19, lodash@^4.17.5, lodash@^4.3.0: - version "4.17.20" - resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.20.tgz#b44a9b6297bcb698f1c51a3545a2b3b368d59c52" - integrity sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA== + version "4.17.21" + resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.21.tgz#679591c564c3bffaae8454cf0b3df370c3d6911c" + integrity sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg== log-symbols@^2.1.0: version "2.2.0" @@ -12575,15 +12575,7 @@ url-parse-lax@^1.0.0: dependencies: prepend-http "^1.0.1" -url-parse@^1.4.3: - version "1.5.10" - resolved "https://registry.yarnpkg.com/url-parse/-/url-parse-1.5.10.tgz#9d3c2f736c1d75dd3bd2be507dcc111f1e2ea9c1" - integrity sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ== - dependencies: - querystringify "^2.1.1" - requires-port "^1.0.0" - -url-parse@^1.5.3: +url-parse@^1.4.3, url-parse@^1.5.3: version "1.5.10" resolved "https://registry.yarnpkg.com/url-parse/-/url-parse-1.5.10.tgz#9d3c2f736c1d75dd3bd2be507dcc111f1e2ea9c1" integrity sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ== From aae0f94193907cc3e49c737f473ef29989b01d30 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Van=20Keisbelck?= Date: Sun, 30 Oct 2022 09:14:42 +0100 Subject: [PATCH 08/21] fix undef check, doc --- doc/quickstart.md | 6 +++--- tea-cup/src/TeaCup/Program.ts | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/doc/quickstart.md b/doc/quickstart.md index aa34e19..3d89e29 100644 --- a/doc/quickstart.md +++ b/doc/quickstart.md @@ -12,19 +12,19 @@ You'll need to setup the project before you get to actual coding. You need a React project in order to start using tea-cup. In order to keep things simple, we'll use the infamous `create-react-app` : - npx create-react-app my-app --typescript + yarn create react-app my-app --template typescript cd my-app ### Add tea-cup to your dependencies - npm install react-tea-cup --save + yarn add -D react-tea-cup tea-cup-core ### Run the dev server We'll start the dev server, and let it recompile everything when we save files : - npm start + yarn start This should also open your default browser to http://localhost:3000 and show you the default generated app. diff --git a/tea-cup/src/TeaCup/Program.ts b/tea-cup/src/TeaCup/Program.ts index ca2f4c0..9341cb0 100644 --- a/tea-cup/src/TeaCup/Program.ts +++ b/tea-cup/src/TeaCup/Program.ts @@ -153,7 +153,7 @@ export class Program extends Component, nev } render(): ReactNode { - if (this.currentModel && this.bd) { + if (this.currentModel !== undefined && this.bd) { return this.props.view(this.bd, this.currentModel); } return null; From 6f27077c189a0a7ae1197a877ba5eb056296185e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Van=20Keisbelck?= Date: Sun, 30 Oct 2022 09:16:38 +0100 Subject: [PATCH 09/21] fix undef check, doc --- doc/quickstart.md | 286 +++++++++++++++++++++++----------------------- 1 file changed, 144 insertions(+), 142 deletions(-) diff --git a/doc/quickstart.md b/doc/quickstart.md index 3d89e29..501bbda 100644 --- a/doc/quickstart.md +++ b/doc/quickstart.md @@ -37,7 +37,8 @@ favourite editor, and replace its contents with this : ```typescript jsx import React from 'react'; // bare minimum to use tea-cup -import { Dispatcher, Cmd, Program, Sub } from 'react-tea-cup'; +import { Program } from 'react-tea-cup'; +import { Cmd, Dispatcher, Sub } from 'tea-cup-core'; // a Model can be anything. Here, it's simply a number... type Model = number; @@ -115,158 +116,159 @@ and Cmds. Replace the contents of `App.tsx` with the following, code : ```typescript jsx -import {Http, Cmd, Task, Result, Dispatcher, Decode, Decoder, Maybe, nothing, Sub, Program, just} from "react-tea-cup"; +import {Http, Cmd, Task, Result, Dispatcher, Decode, Decoder, Maybe, nothing, Sub, just} from "tea-cup-core"; +import {Program} from "react-tea-cup"; import * as React from 'react' interface Model { - // name of the repo - readonly repo: string - // use Maybe of Result to model state : - // * nothing : loading commits - // * just(error) : last fetch has failed, we have the error - // * just(commit[]) : last fetch succeeded, we havbe the commits - readonly commits: Maybe>> + // name of the repo + readonly repo: string + // use Maybe of Result to model state : + // * nothing : loading commits + // * just(error) : last fetch has failed, we have the error + // * just(commit[]) : last fetch succeeded, we havbe the commits + readonly commits: Maybe>> } - + interface Commit { - readonly sha: string - readonly author: string + readonly sha: string + readonly author: string } - -type Msg - // repo name changed - = { type: "repo-changed", value: string } - // trigger a fetch of commits - | { type: "fetch" } - // got fetch response, or an error - | { type: "got-commits", commits: Result> } + +type Msg +// repo name changed + = { type: "repo-changed", value: string } + // trigger a fetch of commits + | { type: "fetch" } + // got fetch response, or an error + | { type: "got-commits", commits: Result> } function init(repo: string): [Model, Cmd] { - return [ - { - repo: repo, // store initial repo name - commits: nothing // initial state is "loading" - }, - fetchCommits(repo) // initial fetch - ] + return [ + { + repo: repo, // store initial repo name + commits: nothing // initial state is "loading" + }, + fetchCommits(repo) // initial fetch + ] } function view(dispatch: Dispatcher, model: Model) { - return ( - <> -

- Fetch data using Http module -

- { - // update repo name on input change - const value = (e.target as HTMLInputElement).value; - dispatch({ - type: "repo-changed", - value: value - }) - }}/> - -
- { - model.commits - // commits are present : map the result - .map(commitsResult => - // use Result.match to map the result - // depending if it's ok, or an error - commitsResult.match( - // all good, we have commits, build the vdom - commits => -
    - { commits.map(commit => -
  • - {commit.sha} - {commit.author} -
  • - )} -
, - // in case there's an error, show it - error => -

Fetch error : {error.message}

- ) - ) - // commits == nothing, we are currently fetching - .withDefault( -

Fetching...

- ) - } - - ) + return ( + <> +

+ Fetch data using Http module +

+ { + // update repo name on input change + const value = (e.target as HTMLInputElement).value; + dispatch({ + type: "repo-changed", + value: value + }) + }}/> + +
+ { + model.commits + // commits are present : map the result + .map(commitsResult => + // use Result.match to map the result + // depending if it's ok, or an error + commitsResult.match( + // all good, we have commits, build the vdom + commits => +
    + { commits.map(commit => +
  • + {commit.sha} - {commit.author} +
  • + )} +
, + // in case there's an error, show it + error => +

Fetch error : {error.message}

+ ) + ) + // commits == nothing, we are currently fetching + .withDefault( +

Fetching...

+ ) + } + + ) } function update(msg:Msg, model:Model): [Model, Cmd] { - switch (msg.type) { - case "repo-changed": - // just change the repo in Model - return [ - { ...model, repo: msg.value }, - Cmd.none() - ] - case "fetch": - // indicate that we are fetching (set commits to nothing) - // and trigger thje fetch - return [ - { ...model, commits: nothing }, - fetchCommits(model.repo) - ] - case "got-commits": - // got the fetch response, assign it to - // the Model - return [ - { ...model, commits: just(msg.commits) }, - Cmd.none() - ] - } + switch (msg.type) { + case "repo-changed": + // just change the repo in Model + return [ + { ...model, repo: msg.value }, + Cmd.none() + ] + case "fetch": + // indicate that we are fetching (set commits to nothing) + // and trigger thje fetch + return [ + { ...model, commits: nothing }, + fetchCommits(model.repo) + ] + case "got-commits": + // got the fetch response, assign it to + // the Model + return [ + { ...model, commits: just(msg.commits) }, + Cmd.none() + ] + } } // no subs in this example function subscriptions(model:Model): Sub { - return Sub.none() + return Sub.none() } // create and return a Cmd that fetches commits // for the passed repo function fetchCommits(repo: string): Cmd { - // create a Task that fetches the commits or fails with an Error - const fetchTask: Task> = - Http.jsonBody( - // create a fetch Task - Http.fetch(`https://api.github.com/repos/${repo}/commits`), - // decode the response with this decoder - Decode.array(commitDecoder) - ); - - // Msg creator function - function gotCommits(r:Result>): Msg { - return { - type: "got-commits", - commits: r + // create a Task that fetches the commits or fails with an Error + const fetchTask: Task> = + Http.jsonBody( + // create a fetch Task + Http.fetch(`https://api.github.com/repos/${repo}/commits`), + // decode the response with this decoder + Decode.array(commitDecoder) + ); + + // Msg creator function + function gotCommits(r:Result>): Msg { + return { + type: "got-commits", + commits: r + } } - } - - // "perform" the Task, and indicate which message - // needs to be used for handling the response - return Task.attempt(fetchTask,gotCommits); + + // "perform" the Task, and indicate which message + // needs to be used for handling the response + return Task.attempt(fetchTask,gotCommits); } @@ -274,26 +276,26 @@ function fetchCommits(repo: string): Cmd { // A decoder for Commit objects const commitDecoder: Decoder = - Decode.map2( - (sha:string, author:string) => { - return { - sha: sha, - author: author - } - }, - Decode.field("sha", Decode.str), - Decode.at(["commit", "author","name"], Decode.str) - ); + Decode.map2( + (sha:string, author:string) => { + return { + sha: sha, + author: author + } + }, + Decode.field("sha", Decode.str), + Decode.at(["commit", "author","name"], Decode.str) + ); // wire the program const App = () => ( - init("Microsoft/TypeScript")} - view={view} - update={update} - subscriptions={subscriptions} - /> + init("Microsoft/TypeScript")} + view={view} + update={update} + subscriptions={subscriptions} + /> ); export default App; From 12698053a3430c679bd9c420fe7f8f10ccc0abca Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 6 Dec 2022 19:00:59 +0000 Subject: [PATCH 10/21] Bump decode-uri-component from 0.2.0 to 0.2.2 Bumps [decode-uri-component](https://github.com/SamVerschueren/decode-uri-component) from 0.2.0 to 0.2.2. - [Release notes](https://github.com/SamVerschueren/decode-uri-component/releases) - [Commits](https://github.com/SamVerschueren/decode-uri-component/compare/v0.2.0...v0.2.2) --- updated-dependencies: - dependency-name: decode-uri-component dependency-type: indirect ... Signed-off-by: dependabot[bot] --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index 9b6f982..a39fc13 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3993,9 +3993,9 @@ decimal.js@^10.2.1: integrity sha512-Nv6ENEzyPQ6AItkGwLE2PGKinZZ9g59vSh2BeH6NqPu0OTKZ5ruJsVqh/orbAnqXc9pBbgXAIrc2EyaCj8NpGg== decode-uri-component@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/decode-uri-component/-/decode-uri-component-0.2.0.tgz#eb3913333458775cb84cd1a1fae062106bb87545" - integrity sha1-6zkTMzRYd1y4TNGh+uBiEGu4dUU= + version "0.2.2" + resolved "https://registry.yarnpkg.com/decode-uri-component/-/decode-uri-component-0.2.2.tgz#e69dbe25d37941171dd540e024c444cd5188e1e9" + integrity sha512-FqUYQ+8o158GyGTrMFJms9qh3CqTKvAqgqsTnkLI8sKu0028orqBhxNMFkFen0zGyg6epACD32pjVk58ngIErQ== deep-equal-ident@^1.1.1: version "1.1.1" From d1d11d19020a1c1b7ad7fa02637d1f4574d4037e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 9 Dec 2022 00:40:03 +0000 Subject: [PATCH 11/21] Bump qs from 6.5.2 to 6.5.3 Bumps [qs](https://github.com/ljharb/qs) from 6.5.2 to 6.5.3. - [Release notes](https://github.com/ljharb/qs/releases) - [Changelog](https://github.com/ljharb/qs/blob/main/CHANGELOG.md) - [Commits](https://github.com/ljharb/qs/compare/v6.5.2...v6.5.3) --- updated-dependencies: - dependency-name: qs dependency-type: indirect ... Signed-off-by: dependabot[bot] --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index 9b6f982..e5ba3d2 100644 --- a/yarn.lock +++ b/yarn.lock @@ -10389,9 +10389,9 @@ qs@6.7.0: integrity sha512-VCdBRNFTX1fyE7Nb6FYoURo/SPe62QCaAyzJvUjwRaIsc+NePBEniHlvxFmmX56+HZphIGtV0XeCirBtpDrTyQ== qs@~6.5.2: - version "6.5.2" - resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.2.tgz#cb3ae806e8740444584ef154ce8ee98d403f3e36" - integrity sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA== + version "6.5.3" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.3.tgz#3aeeffc91967ef6e35c0e488ef46fb296ab76aad" + integrity sha512-qxXIEh4pCGfHICj1mAJQ2/2XVZkjCDTcEgfoSQxc/fYivUZxTkk7L3bDBJSoNrEzXI17oUO5Dp07ktqE5KzczA== query-string@^4.1.0: version "4.3.4" From 638cc1453afc1657c6c31c15c45fc297a32732cd Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 13 Dec 2022 11:49:04 +0000 Subject: [PATCH 12/21] Bump express from 4.17.1 to 4.18.2 Bumps [express](https://github.com/expressjs/express) from 4.17.1 to 4.18.2. - [Release notes](https://github.com/expressjs/express/releases) - [Changelog](https://github.com/expressjs/express/blob/master/History.md) - [Commits](https://github.com/expressjs/express/compare/4.17.1...4.18.2) --- updated-dependencies: - dependency-name: express dependency-type: indirect ... Signed-off-by: dependabot[bot] --- yarn.lock | 354 +++++++++++++++++++++++++++++++----------------------- 1 file changed, 203 insertions(+), 151 deletions(-) diff --git a/yarn.lock b/yarn.lock index 9b6f982..6176d1c 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1880,13 +1880,13 @@ abbrev@1, abbrev@~1.1.1: resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.1.1.tgz#f8f2c887ad10bf67f634f005b6987fed3179aac8" integrity sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q== -accepts@~1.3.4, accepts@~1.3.5, accepts@~1.3.7: - version "1.3.7" - resolved "https://registry.yarnpkg.com/accepts/-/accepts-1.3.7.tgz#531bc726517a3b2b41f850021c6cc15eaab507cd" - integrity sha512-Il80Qs2WjYlJIBNzNkK6KYqlVMTbZLXgHx2oT0pU/fjRHyEp+PEfEPY0R3WCwAGVOtauxh1hOxNgIf5bv7dQpA== +accepts@~1.3.4, accepts@~1.3.5, accepts@~1.3.8: + version "1.3.8" + resolved "https://registry.yarnpkg.com/accepts/-/accepts-1.3.8.tgz#0bf0be125b67014adcb0b0921e62db7bffe16b2e" + integrity sha512-PYAthTa2m2VKxuvSD3DPC/Gy+U+sOA1LAuT8mkmRuvw+NACSaeXEQ+NHcVF7rONl6qcaxV3Uuemwawk+7+SJLw== dependencies: - mime-types "~2.1.24" - negotiator "0.6.2" + mime-types "~2.1.34" + negotiator "0.6.3" acorn-globals@^4.1.0, acorn-globals@^4.3.0: version "4.3.4" @@ -2190,7 +2190,7 @@ array-filter@^1.0.0: array-flatten@1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/array-flatten/-/array-flatten-1.1.1.tgz#9a5f699051b1e7073328f2a008968b64ea2955d2" - integrity sha1-ml9pkFGx5wczKPKgCJaLZOopVdI= + integrity sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg== array-flatten@^2.1.0: version "2.1.2" @@ -2602,21 +2602,23 @@ bn.js@^5.1.1: resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-5.1.3.tgz#beca005408f642ebebea80b042b4d18d2ac0ee6b" integrity sha512-GkTiFpjFtUzU9CbMeJ5iazkCzGL3jrhzerzZIuqLABjbwRaFt33I9tUdSNryIptM+RxDet6OKm2WnLXzW51KsQ== -body-parser@1.19.0: - version "1.19.0" - resolved "https://registry.yarnpkg.com/body-parser/-/body-parser-1.19.0.tgz#96b2709e57c9c4e09a6fd66a8fd979844f69f08a" - integrity sha512-dhEPs72UPbDnAQJ9ZKMNTP6ptJaionhP5cBb541nXPlW60Jepo9RV/a4fX4XWW9CuFNK22krhrj1+rgzifNCsw== +body-parser@1.20.1: + version "1.20.1" + resolved "https://registry.yarnpkg.com/body-parser/-/body-parser-1.20.1.tgz#b1812a8912c195cd371a3ee5e66faa2338a5c668" + integrity sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw== dependencies: - bytes "3.1.0" + bytes "3.1.2" content-type "~1.0.4" debug "2.6.9" - depd "~1.1.2" - http-errors "1.7.2" + depd "2.0.0" + destroy "1.2.0" + http-errors "2.0.0" iconv-lite "0.4.24" - on-finished "~2.3.0" - qs "6.7.0" - raw-body "2.4.0" - type-is "~1.6.17" + on-finished "2.4.1" + qs "6.11.0" + raw-body "2.5.1" + type-is "~1.6.18" + unpipe "1.0.0" bonjour@^3.5.0: version "3.5.0" @@ -2845,10 +2847,10 @@ bytes@3.0.0: resolved "https://registry.yarnpkg.com/bytes/-/bytes-3.0.0.tgz#d32815404d689699f85a4ea4fa8755dd13a96048" integrity sha1-0ygVQE1olpn4Wk6k+odV3ROpYEg= -bytes@3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/bytes/-/bytes-3.1.0.tgz#f6cf7933a360e0588fa9fde85651cdc7f805d1f6" - integrity sha512-zauLjrfCG+xvoyaqLoV8bLVXXNGC4JqlxFCutSDWA6fJrTo2ZuvLYTqZ7aHBLZSMOopbzwv8f+wZcVzfVTI2Dg== +bytes@3.1.2: + version "3.1.2" + resolved "https://registry.yarnpkg.com/bytes/-/bytes-3.1.2.tgz#8b0beeb98605adf1b128fa4386403c009e0221a5" + integrity sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg== cacache@^12.0.0, cacache@^12.0.2, cacache@^12.0.3: version "12.0.4" @@ -2910,6 +2912,14 @@ cache-base@^1.0.1: union-value "^1.0.0" unset-value "^1.0.0" +call-bind@^1.0.0: + version "1.0.2" + resolved "https://registry.yarnpkg.com/call-bind/-/call-bind-1.0.2.tgz#b1d4e89e688119c3c9a903ad30abb2f6a919be3c" + integrity sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA== + dependencies: + function-bind "^1.1.1" + get-intrinsic "^1.0.2" + call-limit@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/call-limit/-/call-limit-1.1.1.tgz#ef15f2670db3f1992557e2d965abc459e6e358d4" @@ -3471,12 +3481,12 @@ contains-path@^0.1.0: resolved "https://registry.yarnpkg.com/contains-path/-/contains-path-0.1.0.tgz#fe8cf184ff6670b6baef01a9d4861a5cbec4120a" integrity sha1-/ozxhP9mcLa67wGp1IYaXL7EEgo= -content-disposition@0.5.3: - version "0.5.3" - resolved "https://registry.yarnpkg.com/content-disposition/-/content-disposition-0.5.3.tgz#e130caf7e7279087c5616c2007d0485698984fbd" - integrity sha512-ExO0774ikEObIAEV9kDo50o+79VCUdEB6n6lzKgGwupcVeRlhrj3qGAfwq8G6uBJjkqLrhT0qEYFcWng8z1z0g== +content-disposition@0.5.4: + version "0.5.4" + resolved "https://registry.yarnpkg.com/content-disposition/-/content-disposition-0.5.4.tgz#8b82b4efac82512a02bb0b1dcec9d2c5e8eb5bfe" + integrity sha512-FveZTNuGw04cxlAiWbzi6zTAL/lhehaWbTtgluJh4/E95DqMwTmha3KZN1aAWA8cFIhHzMZUvLevkw5Rqk+tSQ== dependencies: - safe-buffer "5.1.2" + safe-buffer "5.2.1" content-type@~1.0.4: version "1.0.4" @@ -3498,12 +3508,12 @@ convert-source-map@^0.3.3: cookie-signature@1.0.6: version "1.0.6" resolved "https://registry.yarnpkg.com/cookie-signature/-/cookie-signature-1.0.6.tgz#e303a882b342cc3ee8ca513a79999734dab3ae2c" - integrity sha1-4wOogrNCzD7oylE6eZmXNNqzriw= + integrity sha512-QADzlaHc8icV8I7vbaJXJwod9HWYp8uCqf1xa4OfNu1T7JVxQIrUgOWtHdNDtPiywmFbiS12VjotIXLrKM3orQ== -cookie@0.4.0: - version "0.4.0" - resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.4.0.tgz#beb437e7022b3b6d49019d088665303ebe9c14ba" - integrity sha512-+Hp8fLp57wnUSt0tY0tHEXh4voZRDnoIrZPqlo3DPiI4y9lwg/jqx+1Om94/W6ZaPDOUbnjOt/99w66zk+l1Xg== +cookie@0.5.0: + version "0.5.0" + resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.5.0.tgz#d1f5d71adec6558c58f389987c366aa47e994f8b" + integrity sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw== copy-concurrently@^1.0.0: version "1.0.5" @@ -4093,6 +4103,11 @@ delegates@^1.0.0: resolved "https://registry.yarnpkg.com/delegates/-/delegates-1.0.0.tgz#84c6e159b81904fdca59a0ef44cd870d31250f9a" integrity sha1-hMbhWbgZBP3KWaDvRM2HDTElD5o= +depd@2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/depd/-/depd-2.0.0.tgz#b696163cc757560d09cf22cc8fad1571b79e76df" + integrity sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw== + depd@~1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/depd/-/depd-1.1.2.tgz#9bcd52e14c097763e749b274c4346ed2e560b5a9" @@ -4106,10 +4121,10 @@ des.js@^1.0.0: inherits "^2.0.1" minimalistic-assert "^1.0.0" -destroy@~1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/destroy/-/destroy-1.0.4.tgz#978857442c44749e4206613e37946205826abd80" - integrity sha1-l4hXRCxEdJ5CBmE+N5RiBYJqvYA= +destroy@1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/destroy/-/destroy-1.2.0.tgz#4803735509ad8be552934c67df614f94e66fa015" + integrity sha512-2sJGJTaXIIaR1w4iJSNoN0hnMY7Gpc/n8D4qSCJw8QqFWXf7cuAgnEHxBpweaVcPevC2l3KpjYCx3NypQQgaJg== detect-indent@~5.0.0: version "5.0.0" @@ -4369,7 +4384,7 @@ editorconfig@^0.15.3: ee-first@1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/ee-first/-/ee-first-1.1.1.tgz#590c61156b0ae2f4f0255732a158b266bc56b21d" - integrity sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0= + integrity sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow== electron-to-chromium@^1.3.378, electron-to-chromium@^1.3.571: version "1.3.576" @@ -4412,7 +4427,7 @@ emojis-list@^3.0.0: encodeurl@~1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/encodeurl/-/encodeurl-1.0.2.tgz#ad3ff4c86ec2d029322f5a02c3a9a606c95b3f59" - integrity sha1-rT/0yG7C0CkyL1oCw6mmBslbP1k= + integrity sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w== encoding@^0.1.11: version "0.1.13" @@ -4641,7 +4656,7 @@ escalade@^3.1.0: escape-html@~1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/escape-html/-/escape-html-1.0.3.tgz#0258eae4d3d0c0974de1c169188ef0051d1d1988" - integrity sha1-Aljq5NPQwJdN4cFpGI7wBR0dGYg= + integrity sha512-NiSupZ4OeuGwr68lGIeym/ksIZMJodUGOSCZ/FSnTxcrekbvqrgdUxlJOMpijaKZVjAJrWrGs/6Jy8OMuyj9ow== escape-string-regexp@2.0.0: version "2.0.0" @@ -4898,7 +4913,7 @@ esutils@^2.0.2: etag@~1.8.1: version "1.8.1" resolved "https://registry.yarnpkg.com/etag/-/etag-1.8.1.tgz#41ae2eeb65efa62268aebfea83ac7d79299b0887" - integrity sha1-Qa4u62XvpiJorr/qg6x9eSmbCIc= + integrity sha512-aIL5Fx7mawVa300al2BnEE4iNvo1qETxLrPI/o05L7z6go7fCw1J6EQmbK4FmJ2AS7kgVF/KEZWufBfdClMcPg== eventemitter3@^4.0.0: version "4.0.7" @@ -4987,37 +5002,38 @@ expect@^24.9.0: jest-regex-util "^24.9.0" express@^4.17.1: - version "4.17.1" - resolved "https://registry.yarnpkg.com/express/-/express-4.17.1.tgz#4491fc38605cf51f8629d39c2b5d026f98a4c134" - integrity sha512-mHJ9O79RqluphRrcw2X/GTh3k9tVv8YcoyY4Kkh4WDMUYKRZUq0h1o0w2rrrxBqM7VoeUVqgb27xlEMXTnYt4g== + version "4.18.2" + resolved "https://registry.yarnpkg.com/express/-/express-4.18.2.tgz#3fabe08296e930c796c19e3c516979386ba9fd59" + integrity sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ== dependencies: - accepts "~1.3.7" + accepts "~1.3.8" array-flatten "1.1.1" - body-parser "1.19.0" - content-disposition "0.5.3" + body-parser "1.20.1" + content-disposition "0.5.4" content-type "~1.0.4" - cookie "0.4.0" + cookie "0.5.0" cookie-signature "1.0.6" debug "2.6.9" - depd "~1.1.2" + depd "2.0.0" encodeurl "~1.0.2" escape-html "~1.0.3" etag "~1.8.1" - finalhandler "~1.1.2" + finalhandler "1.2.0" fresh "0.5.2" + http-errors "2.0.0" merge-descriptors "1.0.1" methods "~1.1.2" - on-finished "~2.3.0" + on-finished "2.4.1" parseurl "~1.3.3" path-to-regexp "0.1.7" - proxy-addr "~2.0.5" - qs "6.7.0" + proxy-addr "~2.0.7" + qs "6.11.0" range-parser "~1.2.1" - safe-buffer "5.1.2" - send "0.17.1" - serve-static "1.14.1" - setprototypeof "1.1.1" - statuses "~1.5.0" + safe-buffer "5.2.1" + send "0.18.0" + serve-static "1.15.0" + setprototypeof "1.2.0" + statuses "2.0.1" type-is "~1.6.18" utils-merge "1.0.1" vary "~1.1.2" @@ -5200,17 +5216,17 @@ fill-range@^7.0.1: dependencies: to-regex-range "^5.0.1" -finalhandler@~1.1.2: - version "1.1.2" - resolved "https://registry.yarnpkg.com/finalhandler/-/finalhandler-1.1.2.tgz#b7e7d000ffd11938d0fdb053506f6ebabe9f587d" - integrity sha512-aAWcW57uxVNrQZqFXjITpW3sIUQmHGG3qSb9mUah9MgMC4NeWhNOlNjXEYq3HjRAvL6arUviZGGJsBg6z0zsWA== +finalhandler@1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/finalhandler/-/finalhandler-1.2.0.tgz#7d23fe5731b207b4640e4fcd00aec1f9207a7b32" + integrity sha512-5uXcUVftlQMFnWC9qu/svkWv3GTd2PfUhK/3PLkYNAe7FbqJMt3515HaxE6eRL74GdsriiwujiawdaB1BpEISg== dependencies: debug "2.6.9" encodeurl "~1.0.2" escape-html "~1.0.3" - on-finished "~2.3.0" + on-finished "2.4.1" parseurl "~1.3.3" - statuses "~1.5.0" + statuses "2.0.1" unpipe "~1.0.0" find-cache-dir@^0.1.1: @@ -5359,10 +5375,10 @@ form-data@~2.3.2: combined-stream "^1.0.6" mime-types "^2.1.12" -forwarded@~0.1.2: - version "0.1.2" - resolved "https://registry.yarnpkg.com/forwarded/-/forwarded-0.1.2.tgz#98c23dab1175657b8c0573e8ceccd91b0ff18c84" - integrity sha1-mMI9qxF1ZXuMBXPozszZGw/xjIQ= +forwarded@0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/forwarded/-/forwarded-0.2.0.tgz#2269936428aad4c15c7ebe9779a84bf0b2a81811" + integrity sha512-buRG0fpBtRHSTCOASe6hD258tEubFoRLb4ZNA6NxMVHNw2gOcwHo9wyablzMzOA5z9xA9L1KNjk/Nt6MT9aYow== fragment-cache@^0.2.1: version "0.2.1" @@ -5374,7 +5390,7 @@ fragment-cache@^0.2.1: fresh@0.5.2: version "0.5.2" resolved "https://registry.yarnpkg.com/fresh/-/fresh-0.5.2.tgz#3d8cadd90d976569fa835ab1f8e4b23a105605a7" - integrity sha1-PYyt2Q2XZWn6g1qx+OSyOhBWBac= + integrity sha512-zJ2mQYM18rEFOudeV4GShTGIQ7RbzA7ozbU9I/XBpm7kqgMywgmylMwXHxZJmkVoYkna9d2pVXVXPdYTP9ej8Q== from2@^1.3.0: version "1.3.0" @@ -5550,6 +5566,15 @@ get-caller-file@^2.0.1: resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-2.0.5.tgz#4f94412a82db32f36e3b0b9741f8a97feb031f7e" integrity sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg== +get-intrinsic@^1.0.2: + version "1.1.3" + resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.1.3.tgz#063c84329ad93e83893c7f4f243ef63ffa351385" + integrity sha512-QJVz1Tj7MS099PevUG5jvnt9tSkXN8K14dxQlikJuPt4uD9hHAHjLyLBiLR5zELelBdD9QNRAXZzsJx0WaDL9A== + dependencies: + function-bind "^1.1.1" + has "^1.0.3" + has-symbols "^1.0.3" + get-own-enumerable-property-symbols@^3.0.0: version "3.0.2" resolved "https://registry.yarnpkg.com/get-own-enumerable-property-symbols/-/get-own-enumerable-property-symbols-3.0.2.tgz#b5fde77f22cbe35f390b4e089922c50bce6ef664" @@ -5785,6 +5810,11 @@ has-symbols@^1.0.1: resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.1.tgz#9f5214758a44196c406d9bd76cebf81ec2dd31e8" integrity sha512-PLcsoqu++dmEIZB+6totNFKq/7Do+Z0u4oT0zKOJNl3lYK6vGwwu2hjHs+68OEZbTjiUE9bgOABXbP/GvrS0Kg== +has-symbols@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.3.tgz#bb7b2c4349251dce87b125f7bdf874aa7c8b39f8" + integrity sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A== + has-unicode@^2.0.0, has-unicode@~2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/has-unicode/-/has-unicode-2.0.1.tgz#e0e6fe6a28cf51138855e086d1691e771de2a8b9" @@ -5972,16 +6002,16 @@ http-deceiver@^1.2.7: resolved "https://registry.yarnpkg.com/http-deceiver/-/http-deceiver-1.2.7.tgz#fa7168944ab9a519d337cb0bec7284dc3e723d87" integrity sha1-+nFolEq5pRnTN8sL7HKE3D5yPYc= -http-errors@1.7.2: - version "1.7.2" - resolved "https://registry.yarnpkg.com/http-errors/-/http-errors-1.7.2.tgz#4f5029cf13239f31036e5b2e55292bcfbcc85c8f" - integrity sha512-uUQBt3H/cSIVfch6i1EuPNy/YsRSOUBXTVfZ+yR7Zjez3qjBz6i9+i4zjNaoqcoFVI4lQJ5plg63TvGfRSDCRg== +http-errors@2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/http-errors/-/http-errors-2.0.0.tgz#b7774a1486ef73cf7667ac9ae0858c012c57b9d3" + integrity sha512-FtwrG/euBzaEjYeRqOgly7G0qviiXoJWnvEH2Z1plBdXgbyjv34pHTSb9zoeHMyDy33+DWy5Wt9Wo+TURtOYSQ== dependencies: - depd "~1.1.2" - inherits "2.0.3" - setprototypeof "1.1.1" - statuses ">= 1.5.0 < 2" - toidentifier "1.0.0" + depd "2.0.0" + inherits "2.0.4" + setprototypeof "1.2.0" + statuses "2.0.1" + toidentifier "1.0.1" http-errors@~1.6.2: version "1.6.3" @@ -5993,17 +6023,6 @@ http-errors@~1.6.2: setprototypeof "1.1.0" statuses ">= 1.4.0 < 2" -http-errors@~1.7.2: - version "1.7.3" - resolved "https://registry.yarnpkg.com/http-errors/-/http-errors-1.7.3.tgz#6c619e4f9c60308c38519498c14fbb10aacebb06" - integrity sha512-ZTTX0MWrsQ2ZAhA1cejAwDLycFsd7I7nVtnkT3Ol0aqodaKW+0CTZDQ1uBv5whptCnc8e8HeRRJxRs0kmm/Qfw== - dependencies: - depd "~1.1.2" - inherits "2.0.4" - setprototypeof "1.1.1" - statuses ">= 1.5.0 < 2" - toidentifier "1.0.0" - http-parser-js@>=0.5.1: version "0.5.2" resolved "https://registry.yarnpkg.com/http-parser-js/-/http-parser-js-0.5.2.tgz#da2e31d237b393aae72ace43882dd7e270a8ff77" @@ -8057,7 +8076,7 @@ meant@^1.0.2: media-typer@0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/media-typer/-/media-typer-0.3.0.tgz#8710d7af0aa626f8fffa1ce00168545263255748" - integrity sha1-hxDXrwqmJvj/+hzgAWhUUmMlV0g= + integrity sha512-dq+qelQ9akHpcOl/gUVRTxVIOkAJ1wR3QAvb4RsVjS8oVoFjDGTc679wJYmUmknUF5HwMLOgb5O+a3KxfWapPQ== mem@^1.1.0: version "1.1.0" @@ -8094,7 +8113,7 @@ merge-deep@^3.0.2: merge-descriptors@1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/merge-descriptors/-/merge-descriptors-1.0.1.tgz#b00aaa556dd8b44568150ec9d1b953f3f90cbb61" - integrity sha1-sAqqVW3YtEVoFQ7J0blT8/kMu2E= + integrity sha512-cCi6g3/Zr1iqQi6ySbseM1Xvooa98N0w31jzUYrXPX2xqObmFGHJ0tQ5u74H3mVh7wLouTseZyYIq39g8cNp1w== merge-stream@^2.0.0: version "2.0.0" @@ -8109,7 +8128,7 @@ merge2@^1.2.3: methods@~1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/methods/-/methods-1.1.2.tgz#5529a4d67654134edcc5266656835b0f851afcee" - integrity sha1-VSmk1nZUE07cxSZmVoNbD4Ua/O4= + integrity sha512-iclAHeNqNm68zFtnZ0e+1L2yUIdvzNoauKU4WBA3VvH/vPFieF7qfRlwUZU+DA9P9bPXIS90ulxoUoCH23sV2w== microevent.ts@~0.1.1: version "0.1.1" @@ -8148,18 +8167,30 @@ mime-db@1.44.0: resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.44.0.tgz#fa11c5eb0aca1334b4233cb4d52f10c5a6272f92" integrity sha512-/NOTfLrsPBVeH7YtFPgsVWveuL+4SjjYxaQ1xtM1KMFj7HdxlBlxeyNLzhyJVx7r4rZGJAZ/6lkKCitSc/Nmpg== +mime-db@1.52.0: + version "1.52.0" + resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.52.0.tgz#bbabcdc02859f4987301c856e3387ce5ec43bf70" + integrity sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg== + "mime-db@>= 1.43.0 < 2": version "1.45.0" resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.45.0.tgz#cceeda21ccd7c3a745eba2decd55d4b73e7879ea" integrity sha512-CkqLUxUk15hofLoLyljJSrukZi8mAtgd+yE5uO4tqRZsdsAJKv0O+rFMhVDRJgozy+yG6md5KwuXhD4ocIoP+w== -mime-types@^2.1.12, mime-types@~2.1.17, mime-types@~2.1.19, mime-types@~2.1.24: +mime-types@^2.1.12, mime-types@~2.1.17, mime-types@~2.1.19: version "2.1.27" resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.27.tgz#47949f98e279ea53119f5722e0f34e529bec009f" integrity sha512-JIhqnCasI9yD+SsmkquHBxTSEuZdQX5BuQnS2Vc7puQQQ+8yiP5AY5uWhpdv4YL4VM5c6iliiYWPgJ/nJQLp7w== dependencies: mime-db "1.44.0" +mime-types@~2.1.24, mime-types@~2.1.34: + version "2.1.35" + resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.35.tgz#381a871b62a734450660ae3deee44813f70d959a" + integrity sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw== + dependencies: + mime-db "1.52.0" + mime@1.6.0: version "1.6.0" resolved "https://registry.yarnpkg.com/mime/-/mime-1.6.0.tgz#32cd9e5c64553bd58d19a568af452acff04981b1" @@ -8319,18 +8350,18 @@ move-concurrently@^1.0.1: ms@2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" - integrity sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g= - -ms@2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.1.tgz#30a5864eb3ebb0a66f2ebe6d727af06a09d86e0a" - integrity sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg== + integrity sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A== ms@2.1.2, ms@^2.0.0, ms@^2.1.1: version "2.1.2" resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== +ms@2.1.3: + version "2.1.3" + resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.3.tgz#574c8138ce1d2b5861f0b44579dbadd60c6615b2" + integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== + multicast-dns-service-types@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/multicast-dns-service-types/-/multicast-dns-service-types-1.1.0.tgz#899f11d9686e5e05cb91b35d5f0e63b773cfc901" @@ -8392,10 +8423,10 @@ nearley@^2.7.10: randexp "0.4.6" semver "^5.4.1" -negotiator@0.6.2: - version "0.6.2" - resolved "https://registry.yarnpkg.com/negotiator/-/negotiator-0.6.2.tgz#feacf7ccf525a77ae9634436a64883ffeca346fb" - integrity sha512-hZXc7K2e+PgeI1eDBe/10Ard4ekbfrrqG8Ep+8Jmf4JID2bNg7NvCPOZN+kfF574pFQI7mum2AUqDidoKqcTOw== +negotiator@0.6.3: + version "0.6.3" + resolved "https://registry.yarnpkg.com/negotiator/-/negotiator-0.6.3.tgz#58e323a72fedc0d6f9cd4d31fe49f51479590ccd" + integrity sha512-+EUsqGPLsM+j/zdChZjsnX51g4XrHFOIXwfnCVPGlQk/k5giakcKsuxCObBRu6DSm9opw/O6slWbJdghQM4bBg== neo-async@^2.5.0, neo-async@^2.6.1: version "2.6.2" @@ -8878,6 +8909,11 @@ object-inspect@^1.7.0, object-inspect@^1.8.0: resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.8.0.tgz#df807e5ecf53a609cc6bfe93eac3cc7be5b3a9d0" integrity sha512-jLdtEOB112fORuypAyl/50VRVIBIdVQOSUUGQHzJ4xBSbit81zRarz7GThkEFZy1RceYrWYcPcBFPQwHyAc1gA== +object-inspect@^1.9.0: + version "1.12.2" + resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.12.2.tgz#c0641f26394532f28ab8d796ab954e43c009a8ea" + integrity sha512-z+cPxW0QGUp0mcqcsgQyLVRDoXFQbXOwBaqyF7VIgI4TWNQsDHrBpUQslRmIfAoYWdYzs6UlKJtB2XJpTaNSpQ== + object-is@^1.0.1, object-is@^1.0.2, object-is@^1.1.2: version "1.1.3" resolved "https://registry.yarnpkg.com/object-is/-/object-is-1.1.3.tgz#2e3b9e65560137455ee3bd62aec4d90a2ea1cc81" @@ -8962,10 +8998,10 @@ obuf@^1.0.0, obuf@^1.1.2: resolved "https://registry.yarnpkg.com/obuf/-/obuf-1.1.2.tgz#09bea3343d41859ebd446292d11c9d4db619084e" integrity sha512-PX1wu0AmAdPqOL1mWhqmlOd8kOIZQwGZw6rh7uby9fTc5lhaOWFLX3I6R1hrF9k3zUY40e6igsLGkDXK92LJNg== -on-finished@~2.3.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/on-finished/-/on-finished-2.3.0.tgz#20f1336481b083cd75337992a16971aa2d906947" - integrity sha1-IPEzZIGwg811M3mSoWlxqi2QaUc= +on-finished@2.4.1: + version "2.4.1" + resolved "https://registry.yarnpkg.com/on-finished/-/on-finished-2.4.1.tgz#58c8c44116e54845ad57f14ab10b03533184ac3f" + integrity sha512-oVlzkg3ENAhCk2zdv7IJwd/QUD4z2RxRwpkcGY8psCVcCYZNq4wYnVWALHM+brtuJjePWiYF/ClmuDr8Ch5+kg== dependencies: ee-first "1.1.1" @@ -9371,7 +9407,7 @@ path-parse@^1.0.6: path-to-regexp@0.1.7: version "0.1.7" resolved "https://registry.yarnpkg.com/path-to-regexp/-/path-to-regexp-0.1.7.tgz#df604178005f522f15eb4490e7247a1bfaa67f8c" - integrity sha1-32BBeABfUi8V60SQ5yR6G/qmf4w= + integrity sha512-5DFkuoqlv1uYQKxy8omFBeJPQcdoE07Kv2sferDCrAq1ohOU+MSDswDIbnx3YAM60qIOnYa53wBhXW0EbMonrQ== path-type@^2.0.0: version "2.0.0" @@ -10293,12 +10329,12 @@ protoduck@^5.0.1: dependencies: genfun "^5.0.0" -proxy-addr@~2.0.5: - version "2.0.6" - resolved "https://registry.yarnpkg.com/proxy-addr/-/proxy-addr-2.0.6.tgz#fdc2336505447d3f2f2c638ed272caf614bbb2bf" - integrity sha512-dh/frvCBVmSsDYzw6n926jv974gddhkFPfiN8hPOi30Wax25QZyZEGveluCgliBnqmuM+UJmBErbAUFIoDbjOw== +proxy-addr@~2.0.7: + version "2.0.7" + resolved "https://registry.yarnpkg.com/proxy-addr/-/proxy-addr-2.0.7.tgz#f19fe69ceab311eeb94b42e70e8c2070f9ba1025" + integrity sha512-llQsMLSUDUPT44jdrU/O37qlnifitDP+ZwrmmZcoSKyLKvtZxpyV0n2/bD/N4tBAAZ/gJEdZU7KMraoK1+XYAg== dependencies: - forwarded "~0.1.2" + forwarded "0.2.0" ipaddr.js "1.9.1" prr@~1.0.1: @@ -10383,10 +10419,12 @@ qrcode-terminal@^0.12.0: resolved "https://registry.yarnpkg.com/qrcode-terminal/-/qrcode-terminal-0.12.0.tgz#bb5b699ef7f9f0505092a3748be4464fe71b5819" integrity sha512-EXtzRZmC+YGmGlDFbXKxQiMZNwCLEO6BANKXG4iCtSIM0yqc/pappSx3RIKr4r0uh5JsBckOXeKrB3Iz7mdQpQ== -qs@6.7.0: - version "6.7.0" - resolved "https://registry.yarnpkg.com/qs/-/qs-6.7.0.tgz#41dc1a015e3d581f1621776be31afb2876a9b1bc" - integrity sha512-VCdBRNFTX1fyE7Nb6FYoURo/SPe62QCaAyzJvUjwRaIsc+NePBEniHlvxFmmX56+HZphIGtV0XeCirBtpDrTyQ== +qs@6.11.0: + version "6.11.0" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.11.0.tgz#fd0d963446f7a65e1367e01abd85429453f0c37a" + integrity sha512-MvjoMCJwEarSbUYk5O+nmoSzSutSsTwF85zcHPQ9OrlFoZOYIjaqBAJIqIXjptyD5vThxGq52Xu/MaJzRkIk4Q== + dependencies: + side-channel "^1.0.4" qs@~6.5.2: version "6.5.2" @@ -10470,13 +10508,13 @@ range-parser@^1.2.1, range-parser@~1.2.1: resolved "https://registry.yarnpkg.com/range-parser/-/range-parser-1.2.1.tgz#3cf37023d199e1c24d1a55b84800c2f3e6468031" integrity sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg== -raw-body@2.4.0: - version "2.4.0" - resolved "https://registry.yarnpkg.com/raw-body/-/raw-body-2.4.0.tgz#a1ce6fb9c9bc356ca52e89256ab59059e13d0332" - integrity sha512-4Oz8DUIwdvoa5qMJelxipzi/iJIi40O5cGV1wNYp5hvZP8ZN0T+jiNkL0QepXs+EsQ9XJ8ipEDoiH70ySUJP3Q== +raw-body@2.5.1: + version "2.5.1" + resolved "https://registry.yarnpkg.com/raw-body/-/raw-body-2.5.1.tgz#fe1b1628b181b700215e5fd42389f98b71392857" + integrity sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig== dependencies: - bytes "3.1.0" - http-errors "1.7.2" + bytes "3.1.2" + http-errors "2.0.0" iconv-lite "0.4.24" unpipe "1.0.0" @@ -11185,7 +11223,7 @@ safe-buffer@5.1.2, safe-buffer@~5.1.0, safe-buffer@~5.1.1: resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== -safe-buffer@>=5.1.0, safe-buffer@^5.0.1, safe-buffer@^5.1.0, safe-buffer@^5.1.1, safe-buffer@^5.1.2, safe-buffer@^5.2.0, safe-buffer@^5.2.1, safe-buffer@~5.2.0: +safe-buffer@5.2.1, safe-buffer@>=5.1.0, safe-buffer@^5.0.1, safe-buffer@^5.1.0, safe-buffer@^5.1.1, safe-buffer@^5.1.2, safe-buffer@^5.2.0, safe-buffer@^5.2.1, safe-buffer@~5.2.0: version "5.2.1" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.1.tgz#1eaf9fa9bdb1fdd4ec75f58f9cdb4e6b7827eec6" integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== @@ -11317,24 +11355,24 @@ semver@^7.3.2: resolved "https://registry.yarnpkg.com/semver/-/semver-7.3.2.tgz#604962b052b81ed0786aae84389ffba70ffd3938" integrity sha512-OrOb32TeeambH6UrhtShmF7CRDqhL6/5XpPNp2DuRH6+9QLw/orhp72j87v8Qa1ScDkvrrBNpZcDejAirJmfXQ== -send@0.17.1: - version "0.17.1" - resolved "https://registry.yarnpkg.com/send/-/send-0.17.1.tgz#c1d8b059f7900f7466dd4938bdc44e11ddb376c8" - integrity sha512-BsVKsiGcQMFwT8UxypobUKyv7irCNRHk1T0G680vk88yf6LBByGcZJOTJCrTP2xVN6yI+XjPJcNuE3V4fT9sAg== +send@0.18.0: + version "0.18.0" + resolved "https://registry.yarnpkg.com/send/-/send-0.18.0.tgz#670167cc654b05f5aa4a767f9113bb371bc706be" + integrity sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg== dependencies: debug "2.6.9" - depd "~1.1.2" - destroy "~1.0.4" + depd "2.0.0" + destroy "1.2.0" encodeurl "~1.0.2" escape-html "~1.0.3" etag "~1.8.1" fresh "0.5.2" - http-errors "~1.7.2" + http-errors "2.0.0" mime "1.6.0" - ms "2.1.1" - on-finished "~2.3.0" + ms "2.1.3" + on-finished "2.4.1" range-parser "~1.2.1" - statuses "~1.5.0" + statuses "2.0.1" serialize-javascript@^4.0.0: version "4.0.0" @@ -11356,15 +11394,15 @@ serve-index@^1.9.1: mime-types "~2.1.17" parseurl "~1.3.2" -serve-static@1.14.1: - version "1.14.1" - resolved "https://registry.yarnpkg.com/serve-static/-/serve-static-1.14.1.tgz#666e636dc4f010f7ef29970a88a674320898b2f9" - integrity sha512-JMrvUwE54emCYWlTI+hGrGv5I8dEwmco/00EvkzIIsR7MqrHonbD9pO2MOfFnpFntl7ecpZs+3mW+XbQZu9QCg== +serve-static@1.15.0: + version "1.15.0" + resolved "https://registry.yarnpkg.com/serve-static/-/serve-static-1.15.0.tgz#faaef08cffe0a1a62f60cad0c4e513cff0ac9540" + integrity sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g== dependencies: encodeurl "~1.0.2" escape-html "~1.0.3" parseurl "~1.3.3" - send "0.17.1" + send "0.18.0" set-blocking@^2.0.0, set-blocking@~2.0.0: version "2.0.0" @@ -11391,10 +11429,10 @@ setprototypeof@1.1.0: resolved "https://registry.yarnpkg.com/setprototypeof/-/setprototypeof-1.1.0.tgz#d0bd85536887b6fe7c0d818cb962d9d91c54e656" integrity sha512-BvE/TwpZX4FXExxOxZyRGQQv651MSwmWKZGqvmPcRIjDqWub67kTKuIMx43cZZrS/cBBzwBcNDWoFxt2XEFIpQ== -setprototypeof@1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/setprototypeof/-/setprototypeof-1.1.1.tgz#7e95acb24aa92f5885e0abef5ba131330d4ae683" - integrity sha512-JvdAWfbXeIGaZ9cILp38HntZSFSo3mWg6xGcJJsd+d4aRMOqauag1C63dJfDw7OaMYwEbHMOxEZ1lqVRYP2OAw== +setprototypeof@1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/setprototypeof/-/setprototypeof-1.2.0.tgz#66c9a24a73f9fc28cbe66b09fed3d33dcaf1b424" + integrity sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw== sha.js@^2.4.0, sha.js@^2.4.8: version "2.4.11" @@ -11470,6 +11508,15 @@ side-channel@^1.0.2: es-abstract "^1.18.0-next.0" object-inspect "^1.8.0" +side-channel@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/side-channel/-/side-channel-1.0.4.tgz#efce5c8fdc104ee751b25c58d4290011fa5ea2cf" + integrity sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw== + dependencies: + call-bind "^1.0.0" + get-intrinsic "^1.0.2" + object-inspect "^1.9.0" + sigmund@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/sigmund/-/sigmund-1.0.1.tgz#3ff21f198cad2175f9f3b781853fd94d0d19b590" @@ -11766,7 +11813,12 @@ static-extend@^0.1.1: define-property "^0.2.5" object-copy "^0.1.0" -"statuses@>= 1.4.0 < 2", "statuses@>= 1.5.0 < 2", statuses@~1.5.0: +statuses@2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/statuses/-/statuses-2.0.1.tgz#55cb000ccf1d48728bd23c685a063998cf1a1b63" + integrity sha512-RwNA9Z/7PrK06rYLIzFMlaF+l73iwpzsqRIFgbMLbTcLD6cOao82TaWefPXQvB2fOC4AjuYSEndS7N/mTCbkdQ== + +"statuses@>= 1.4.0 < 2": version "1.5.0" resolved "https://registry.yarnpkg.com/statuses/-/statuses-1.5.0.tgz#161c7dac177659fd9811f43771fa99381478628c" integrity sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow= @@ -12262,10 +12314,10 @@ to-regex@^3.0.1, to-regex@^3.0.2: regex-not "^1.0.2" safe-regex "^1.1.0" -toidentifier@1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/toidentifier/-/toidentifier-1.0.0.tgz#7e1be3470f1e77948bc43d94a3c8f4d7752ba553" - integrity sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw== +toidentifier@1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/toidentifier/-/toidentifier-1.0.1.tgz#3be34321a88a820ed1bd80dfaa33e479fbb8dd35" + integrity sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA== tough-cookie@^2.3.3, tough-cookie@^2.3.4, tough-cookie@^2.5.0, tough-cookie@~2.5.0: version "2.5.0" @@ -12391,7 +12443,7 @@ type-fest@^0.8.1: resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.8.1.tgz#09e249ebde851d3b1e48d27c105444667f17b83d" integrity sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA== -type-is@~1.6.17, type-is@~1.6.18: +type-is@~1.6.18: version "1.6.18" resolved "https://registry.yarnpkg.com/type-is/-/type-is-1.6.18.tgz#4e552cd05df09467dcbc4ef739de89f2cf37c131" integrity sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g== @@ -12506,7 +12558,7 @@ universalify@^0.2.0: unpipe@1.0.0, unpipe@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/unpipe/-/unpipe-1.0.0.tgz#b2bf4ee8514aae6165b4817829d21b2ef49904ec" - integrity sha1-sr9O6FFKrmFltIF4KdIbLvSZBOw= + integrity sha512-pjy2bYhSsufwWlKwPc+l3cN7+wuJlK6uz0YdJEOlQDbl6jo/YlPi4mb8agUkVC8BF7V8NuzeyPNqRksA3hztKQ== unquote@~1.1.1: version "1.1.1" @@ -12658,7 +12710,7 @@ utila@^0.4.0, utila@~0.4: utils-merge@1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/utils-merge/-/utils-merge-1.0.1.tgz#9f95710f50a267947b2ccc124741c1028427e713" - integrity sha1-n5VxD1CiZ5R7LMwSR0HBAoQn5xM= + integrity sha512-pMZTvIkT1d+TFGvDOqodOclx0QWkkgi6Tdoa8gC8ffGAAqz9pzPTZWAybbsHHoED/ztMtkv/VoYTYyShUn81hA== uuid@^3.3.2, uuid@^3.3.3, uuid@^3.4.0: version "3.4.0" @@ -12693,7 +12745,7 @@ validate-npm-package-name@^3.0.0, validate-npm-package-name@~3.0.0: vary@~1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/vary/-/vary-1.1.2.tgz#2299f02c6ded30d4a5961b0b9f74524a18f634fc" - integrity sha1-IpnwLG3tMNSllhsLn3RSShj2NPw= + integrity sha512-BNGbWLfd0eUPabhkXUVm0j8uuvREyTh5ovRa/dyow/BqAbZJyC+5fU+IzQOzmAKzYqYRAISoRhdQr3eIZ/PXqg== vendors@^1.0.0: version "1.0.4" From 72efcc19515e90deaade813d8139980607f27b6a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 6 Jan 2023 22:21:49 +0000 Subject: [PATCH 13/21] Bump json5 from 1.0.1 to 1.0.2 Bumps [json5](https://github.com/json5/json5) from 1.0.1 to 1.0.2. - [Release notes](https://github.com/json5/json5/releases) - [Changelog](https://github.com/json5/json5/blob/main/CHANGELOG.md) - [Commits](https://github.com/json5/json5/compare/v1.0.1...v1.0.2) --- updated-dependencies: - dependency-name: json5 dependency-type: indirect ... Signed-off-by: dependabot[bot] --- yarn.lock | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/yarn.lock b/yarn.lock index 9b6f982..44f6a8b 100644 --- a/yarn.lock +++ b/yarn.lock @@ -7404,9 +7404,9 @@ json5@2.x, json5@^2.1.2: minimist "^1.2.5" json5@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/json5/-/json5-1.0.1.tgz#779fb0018604fa854eacbf6252180d83543e3dbe" - integrity sha512-aKS4WQjPenRxiQsC93MNfjx+nbF4PAdYzmd/1JIj8HYzqfbu86beTuNgXDzPknWk0n0uARlyewZo4s++ES36Ow== + version "1.0.2" + resolved "https://registry.yarnpkg.com/json5/-/json5-1.0.2.tgz#63d98d60f21b313b77c4d6da18bfa69d80e1d593" + integrity sha512-g1MWMLBiz8FKi1e4w0UyVL3w+iJceWAFBAaBnnGKOpNa5f8TLktkbre1+s6oICydWAm+HRUGTmI+//xv2hvXYA== dependencies: minimist "^1.2.0" @@ -8208,9 +8208,9 @@ minimatch@3.0.4, minimatch@^3.0.4: brace-expansion "^1.1.7" minimist@^1.1.1, minimist@^1.2.0, minimist@^1.2.5: - version "1.2.6" - resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.6.tgz#8637a5b759ea0d6e98702cfb3a9283323c93af44" - integrity sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q== + version "1.2.7" + resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.7.tgz#daa1c4d91f507390437c6a8bc01078e7000c4d18" + integrity sha512-bzfL1YUZsP41gmu/qjrEk0Q6i2ix/cVeAhbCbqH9u3zYutS1cLg00qhrD0M2MVdCcx4Sc0UpP2eBWo9rotpq6g== minipass-collect@^1.0.2: version "1.0.2" From 7234f5902bae0e583ace8d8fda03aa00a11f74e5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Van=20Keisbelck?= Date: Mon, 24 Apr 2023 11:29:16 +0200 Subject: [PATCH 14/21] DocSub dispatches with setTimeout to avoid canceling other batched subs --- samples/src/Samples/EventsSample.tsx | 78 +++++++++++++++++++--------- tea-cup/package.json | 1 + tea-cup/src/TeaCup/DocumentEvents.ts | 13 +++-- 3 files changed, 63 insertions(+), 29 deletions(-) diff --git a/samples/src/Samples/EventsSample.tsx b/samples/src/Samples/EventsSample.tsx index 460f329..8de1622 100644 --- a/samples/src/Samples/EventsSample.tsx +++ b/samples/src/Samples/EventsSample.tsx @@ -31,6 +31,8 @@ export type Model = { clicked: Maybe moved: Maybe scrolled: Maybe + nbResizeLeft: number + nbResizeRight: number }; type MousePosition = { @@ -47,6 +49,9 @@ export type Msg = { } | { type: 'moved', position: MousePosition +} | { + type: 'resized', + left: boolean } | { type: 'scrolled', scroll: Position @@ -56,7 +61,9 @@ export function init(): [Model, Cmd] { return noCmd({ clicked: nothing, moved: nothing, - scrolled: nothing + scrolled: nothing, + nbResizeLeft: 0, + nbResizeRight: 0, }); } @@ -75,6 +82,8 @@ export function view(dispatch: Dispatcher, model: Model) { .map(viewPosition('Scrolled')) .withDefault(
Waiting for move ...
) } +
resized left : {model.nbResizeLeft}
+
resized right : {model.nbResizeRight}
); } @@ -102,6 +111,13 @@ export function update(msg: Msg, model: Model): [Model, Cmd] { }; return [model1, Cmd.none()]; } + case 'resized': { + return noCmd({ + ...model, + nbResizeRight: msg.left ? model.nbResizeRight : model.nbResizeRight + 1, + nbResizeLeft: msg.left ? model.nbResizeLeft + 1 : model.nbResizeLeft, + }); + } } } @@ -110,30 +126,42 @@ const windowEvents = new WindowEvents(); export function subscriptions(model: Model): Sub { return Sub.batch([ - // documentEvents.on('click', (e: MouseEvent) => ( - // { - // type: 'clicked', - // position: { - // pos: [e.x, e.y], - // page: [e.pageX, e.pageY], - // offset: [e.offsetX, e.offsetY] - // } - // } as Msg - // )), - // documentEvents.on('mousemove', (e: MouseEvent) => ({ - // type: 'moved', - // position: { - // pos: [e.x, e.y], - // page: [e.pageX, e.pageY], - // offset: [e.offsetX, e.offsetY] - // } - // } as Msg)), - // windowEvents.on('scroll', (e: Event) => { - // return { - // type: 'scrolled', - // scroll: [window.scrollX, window.scrollY] - // } as Msg; - // }) + documentEvents.on('click', (e: MouseEvent) => ( + { + type: 'clicked', + position: { + pos: [e.x, e.y], + page: [e.pageX, e.pageY], + offset: [e.offsetX, e.offsetY] + } + } as Msg + )), + documentEvents.on('mousemove', (e: MouseEvent) => ({ + type: 'moved', + position: { + pos: [e.x, e.y], + page: [e.pageX, e.pageY], + offset: [e.offsetX, e.offsetY] + } + } as Msg)), + windowEvents.on('scroll', (e: Event) => { + return { + type: 'scrolled', + scroll: [window.scrollX, window.scrollY] + } as Msg; + }), + windowEvents.on('resize', () => { + return { + type: 'resized', + left: true + } as Msg; + }), + windowEvents.on('resize', () => { + return { + type: 'resized', + left: false + } as Msg; + }), ]); } diff --git a/tea-cup/package.json b/tea-cup/package.json index 53e77fd..62ec63d 100644 --- a/tea-cup/package.json +++ b/tea-cup/package.json @@ -16,6 +16,7 @@ "test-watch": "jest --watch", "prettify": "prettier --write .", "tsc": "tsc", + "compile:ts": "tsc", "compile": "rimraf dist && tsc", "samples": "tsc --outFile ./dist/Samples/index.js && cp ./src/Samples/index.html ./dist/Samples" }, diff --git a/tea-cup/src/TeaCup/DocumentEvents.ts b/tea-cup/src/TeaCup/DocumentEvents.ts index 0c3eebc..1a8ff20 100644 --- a/tea-cup/src/TeaCup/DocumentEvents.ts +++ b/tea-cup/src/TeaCup/DocumentEvents.ts @@ -42,6 +42,15 @@ class DocSub extends Sub { this.listener = (e) => this.dispatch(this.mapper(e)); } + protected dispatch(m: Msg) { + const d = this.dispatcher; + if (d !== undefined) { + setTimeout(() => { + d(m); + }); + } + } + protected onInit() { super.onInit(); this.documentEvents.doAddListener(this.key, this.listener, this.options) @@ -51,10 +60,6 @@ class DocSub extends Sub { super.onRelease(); this.documentEvents.doRemoveListener(this.key, this.listener, this.options) } - - event(e: Map[K]) { - this.dispatch(this.mapper(e)); - } } abstract class EventMapEvents { From 0674730d8daa09560b80abbfce9e22131dcb6c26 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Van=20Keisbelck?= Date: Mon, 24 Apr 2023 11:41:49 +0200 Subject: [PATCH 15/21] fix tests (async sub dispatch) --- tea-cup/src/TeaCup/DocumentEvents.test.tsx | 37 +++++++++++++++------- 1 file changed, 25 insertions(+), 12 deletions(-) diff --git a/tea-cup/src/TeaCup/DocumentEvents.test.tsx b/tea-cup/src/TeaCup/DocumentEvents.test.tsx index 3e015f4..33581eb 100644 --- a/tea-cup/src/TeaCup/DocumentEvents.test.tsx +++ b/tea-cup/src/TeaCup/DocumentEvents.test.tsx @@ -77,7 +77,7 @@ describe('DocumentEvents Test', () => { expect(removeSpy.mock.calls.length).toBe(2); }); - it('sub receives event from listener', () => { + it('sub receives event from listener', (done) => { const msgs: string[] = []; const collectMsgs = (msg: string): void => { msgs.push(msg); @@ -90,10 +90,13 @@ describe('DocumentEvents Test', () => { const listener = addSpy.mock.calls[0][1]; listener({ event: 'event' }); - expect(msgs).toEqual(['clicked1']); + setTimeout(() => { + expect(msgs).toEqual(['clicked1']); + done(); + }, 10); }); - it('each sub receive events its listener', () => { + it('each sub receive events its listener', (done) => { const msgs: string[] = []; const collectMsgs = (msg: string): void => { msgs.push(msg); @@ -114,12 +117,17 @@ describe('DocumentEvents Test', () => { const listener2 = addSpy.mock.calls[1][1]; listener({ event: 'event' }); - expect(msgs).toEqual(['clicked']); - listener2({ event: 'event' }); - expect(msgs2).toEqual(['clicked2']); + setTimeout(() => { + expect(msgs).toEqual(['clicked']); + listener2({ event: 'event' }); + setTimeout(() => { + expect(msgs2).toEqual(['clicked2']); + done(); + }, 10) + }, 10) }); - it('sub stops receiving events from listener', () => { + it('sub stops receiving events from listener', (done) => { const sub = documentEvents.on('click', (e) => 'clicked1'); const msgs: string[] = []; @@ -132,11 +140,16 @@ describe('DocumentEvents Test', () => { listener({ event: 'event' }); listener({ event: 'event' }); - expect(msgs).toEqual(['clicked1', 'clicked1']); - - sub.release(); - listener({ event: 'event' }); - expect(msgs).toEqual(['clicked1', 'clicked1']); + setTimeout(() => { + expect(msgs).toEqual(['clicked1', 'clicked1']); + + sub.release(); + listener({ event: 'event' }); + setTimeout(() => { + expect(msgs).toEqual(['clicked1', 'clicked1']); + done(); + }); + }, 10) }); }); From 2b37d679cb13aefa6514a113467cf60de43a7cd6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Van=20Keisbelck?= Date: Mon, 24 Apr 2023 13:10:14 +0200 Subject: [PATCH 16/21] Program inits/releases Subs in timeout, to allow previous dispatch to finish without side-effects on other Subs. --- core/src/TeaCup/Animation.ts | 25 +++------------ samples/src/Samples/EventsSample.tsx | 48 ++++++++++++++-------------- samples/src/Samples/Raf.tsx | 4 ++- samples/src/Samples/SelectSample.tsx | 1 - tea-cup/src/TeaCup/DocumentEvents.ts | 9 ------ tea-cup/src/TeaCup/Program.ts | 6 ++-- 6 files changed, 35 insertions(+), 58 deletions(-) diff --git a/core/src/TeaCup/Animation.ts b/core/src/TeaCup/Animation.ts index 52f73c0..3dd7acb 100644 --- a/core/src/TeaCup/Animation.ts +++ b/core/src/TeaCup/Animation.ts @@ -27,25 +27,11 @@ import { Sub } from './Sub'; let subs: Array> = []; -let ticking = false; - function tick() { - // console.log("tick()"); - if (!ticking) { - ticking = true; - const subsNow = [...subs]; - // console.log("tick() subsNow=" + subsNow); - if (subsNow.length > 0) { - requestAnimationFrame((t: number) => { - // console.log("tick() trigger subsNow=" + subsNow); - subsNow.forEach((s) => s.trigger(t)); - ticking = false; - // console.log("tick() recursing"); - tick(); - }); - } else { - ticking = false; - } + if (subs.length > 0) { + requestAnimationFrame((t: number) => { + subs.forEach((s) => s.trigger(t)); + }); } } @@ -66,9 +52,6 @@ class RafSub extends Sub { protected onRelease() { super.onRelease(); subs = subs.filter((s) => s !== this); - if (subs.length === 0) { - ticking = false; - } } trigger(t: number) { diff --git a/samples/src/Samples/EventsSample.tsx b/samples/src/Samples/EventsSample.tsx index 8de1622..b4ad4d3 100644 --- a/samples/src/Samples/EventsSample.tsx +++ b/samples/src/Samples/EventsSample.tsx @@ -126,30 +126,30 @@ const windowEvents = new WindowEvents(); export function subscriptions(model: Model): Sub { return Sub.batch([ - documentEvents.on('click', (e: MouseEvent) => ( - { - type: 'clicked', - position: { - pos: [e.x, e.y], - page: [e.pageX, e.pageY], - offset: [e.offsetX, e.offsetY] - } - } as Msg - )), - documentEvents.on('mousemove', (e: MouseEvent) => ({ - type: 'moved', - position: { - pos: [e.x, e.y], - page: [e.pageX, e.pageY], - offset: [e.offsetX, e.offsetY] - } - } as Msg)), - windowEvents.on('scroll', (e: Event) => { - return { - type: 'scrolled', - scroll: [window.scrollX, window.scrollY] - } as Msg; - }), + // documentEvents.on('click', (e: MouseEvent) => ( + // { + // type: 'clicked', + // position: { + // pos: [e.x, e.y], + // page: [e.pageX, e.pageY], + // offset: [e.offsetX, e.offsetY] + // } + // } as Msg + // )), + // documentEvents.on('mousemove', (e: MouseEvent) => ({ + // type: 'moved', + // position: { + // pos: [e.x, e.y], + // page: [e.pageX, e.pageY], + // offset: [e.offsetX, e.offsetY] + // } + // } as Msg)), + // windowEvents.on('scroll', (e: Event) => { + // return { + // type: 'scrolled', + // scroll: [window.scrollX, window.scrollY] + // } as Msg; + // }), windowEvents.on('resize', () => { return { type: 'resized', diff --git a/samples/src/Samples/Raf.tsx b/samples/src/Samples/Raf.tsx index d891df4..b6c2ebf 100644 --- a/samples/src/Samples/Raf.tsx +++ b/samples/src/Samples/Raf.tsx @@ -104,7 +104,9 @@ export function update(msg: Msg, model: Model): [Model, Cmd] { return noCmd({ ...model, started: !model.started }); case 'raf': const delta = msg.t - model.t; - const fps = 1000 / delta; + const fps = delta === 0 + ? model.fps + : 1000 / delta; return noCmd({ ...model, t: msg.t, diff --git a/samples/src/Samples/SelectSample.tsx b/samples/src/Samples/SelectSample.tsx index fc76acf..88c6c22 100644 --- a/samples/src/Samples/SelectSample.tsx +++ b/samples/src/Samples/SelectSample.tsx @@ -47,7 +47,6 @@ export function init(): [Model, Cmd] { export function view(dispatch: Dispatcher, model: Model) { const value = model.selected.withDefault("select me"); - console.log("rendering value", value) return (

(Use me with Firefox, too.)

diff --git a/tea-cup/src/TeaCup/DocumentEvents.ts b/tea-cup/src/TeaCup/DocumentEvents.ts index 1a8ff20..61d23e0 100644 --- a/tea-cup/src/TeaCup/DocumentEvents.ts +++ b/tea-cup/src/TeaCup/DocumentEvents.ts @@ -42,15 +42,6 @@ class DocSub extends Sub { this.listener = (e) => this.dispatch(this.mapper(e)); } - protected dispatch(m: Msg) { - const d = this.dispatcher; - if (d !== undefined) { - setTimeout(() => { - d(m); - }); - } - } - protected onInit() { super.onInit(); this.documentEvents.doAddListener(this.key, this.listener, this.options) diff --git a/tea-cup/src/TeaCup/Program.ts b/tea-cup/src/TeaCup/Program.ts index 9341cb0..38f73e5 100644 --- a/tea-cup/src/TeaCup/Program.ts +++ b/tea-cup/src/TeaCup/Program.ts @@ -91,8 +91,10 @@ export class Program extends Component, nev const d = this.dispatch.bind(this); - newSub.init(d); - prevSub?.release(); + setTimeout(() => { + newSub.init(d); + prevSub?.release(); + }); // perform commands in a separate timout, to // make sure that this dispatch is done From e9bf46e95e411ae4c5daa112a5c30f36ea866520 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Van=20Keisbelck?= Date: Mon, 24 Apr 2023 13:32:37 +0200 Subject: [PATCH 17/21] Fix RAF re-entry --- core/src/TeaCup/Animation.ts | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/core/src/TeaCup/Animation.ts b/core/src/TeaCup/Animation.ts index 3dd7acb..74381dc 100644 --- a/core/src/TeaCup/Animation.ts +++ b/core/src/TeaCup/Animation.ts @@ -27,34 +27,51 @@ import { Sub } from './Sub'; let subs: Array> = []; +let ticking = false; + function tick() { - if (subs.length > 0) { + console.log("tick()"); + if (!ticking) { + ticking = true; requestAnimationFrame((t: number) => { + console.log("got RAF", t, "subs", subs.length); subs.forEach((s) => s.trigger(t)); + ticking = false; }); } } +let rafSubId = 0; + class RafSub extends Sub { readonly mapper: (t: number) => M; + private readonly uuid: string; + constructor(mapper: (t: number) => M) { super(); this.mapper = mapper; + this.uuid = "rafsub-" + rafSubId; + rafSubId++; } protected onInit() { + console.log("RafSub", this.uuid ,"onInit()"); super.onInit(); subs.push(this); + console.log("RafSub", this.uuid ,"onInit()", subs.length); tick(); } protected onRelease() { + console.log("RafSub", this.uuid ,"onRelease()"); super.onRelease(); subs = subs.filter((s) => s !== this); + console.log("RafSub", this.uuid ,"onRelease()", subs.length); } trigger(t: number) { + console.log("RafSub", this.uuid ,"trigger(", t, ")"); this.dispatch(this.mapper(t)); } } From a6d4dbbe9f86a083395f0b1f65d5f031813e520e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Van=20Keisbelck?= Date: Mon, 24 Apr 2023 13:40:38 +0200 Subject: [PATCH 18/21] cleanup --- core/src/TeaCup/Animation.ts | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/core/src/TeaCup/Animation.ts b/core/src/TeaCup/Animation.ts index 74381dc..81f59df 100644 --- a/core/src/TeaCup/Animation.ts +++ b/core/src/TeaCup/Animation.ts @@ -41,37 +41,26 @@ function tick() { } } -let rafSubId = 0; - class RafSub extends Sub { readonly mapper: (t: number) => M; - private readonly uuid: string; - constructor(mapper: (t: number) => M) { super(); this.mapper = mapper; - this.uuid = "rafsub-" + rafSubId; - rafSubId++; } protected onInit() { - console.log("RafSub", this.uuid ,"onInit()"); super.onInit(); subs.push(this); - console.log("RafSub", this.uuid ,"onInit()", subs.length); tick(); } protected onRelease() { - console.log("RafSub", this.uuid ,"onRelease()"); super.onRelease(); subs = subs.filter((s) => s !== this); - console.log("RafSub", this.uuid ,"onRelease()", subs.length); } trigger(t: number) { - console.log("RafSub", this.uuid ,"trigger(", t, ")"); this.dispatch(this.mapper(t)); } } From 62281f6517df7e91b303d63558a2b68f4061501e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Van=20Keisbelck?= Date: Mon, 24 Apr 2023 13:45:19 +0200 Subject: [PATCH 19/21] cleanup --- core/src/TeaCup/Animation.ts | 2 -- 1 file changed, 2 deletions(-) diff --git a/core/src/TeaCup/Animation.ts b/core/src/TeaCup/Animation.ts index 81f59df..5437341 100644 --- a/core/src/TeaCup/Animation.ts +++ b/core/src/TeaCup/Animation.ts @@ -30,11 +30,9 @@ let subs: Array> = []; let ticking = false; function tick() { - console.log("tick()"); if (!ticking) { ticking = true; requestAnimationFrame((t: number) => { - console.log("got RAF", t, "subs", subs.length); subs.forEach((s) => s.trigger(t)); ticking = false; }); From f4b4b5b3fb9b2fb1ff1196a4966a95b63fcf6340 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Van=20Keisbelck?= Date: Mon, 24 Apr 2023 13:49:54 +0200 Subject: [PATCH 20/21] re-plug commented out doc events in samples --- samples/src/Samples/EventsSample.tsx | 48 ++++++++++++++-------------- 1 file changed, 24 insertions(+), 24 deletions(-) diff --git a/samples/src/Samples/EventsSample.tsx b/samples/src/Samples/EventsSample.tsx index b4ad4d3..8de1622 100644 --- a/samples/src/Samples/EventsSample.tsx +++ b/samples/src/Samples/EventsSample.tsx @@ -126,30 +126,30 @@ const windowEvents = new WindowEvents(); export function subscriptions(model: Model): Sub { return Sub.batch([ - // documentEvents.on('click', (e: MouseEvent) => ( - // { - // type: 'clicked', - // position: { - // pos: [e.x, e.y], - // page: [e.pageX, e.pageY], - // offset: [e.offsetX, e.offsetY] - // } - // } as Msg - // )), - // documentEvents.on('mousemove', (e: MouseEvent) => ({ - // type: 'moved', - // position: { - // pos: [e.x, e.y], - // page: [e.pageX, e.pageY], - // offset: [e.offsetX, e.offsetY] - // } - // } as Msg)), - // windowEvents.on('scroll', (e: Event) => { - // return { - // type: 'scrolled', - // scroll: [window.scrollX, window.scrollY] - // } as Msg; - // }), + documentEvents.on('click', (e: MouseEvent) => ( + { + type: 'clicked', + position: { + pos: [e.x, e.y], + page: [e.pageX, e.pageY], + offset: [e.offsetX, e.offsetY] + } + } as Msg + )), + documentEvents.on('mousemove', (e: MouseEvent) => ({ + type: 'moved', + position: { + pos: [e.x, e.y], + page: [e.pageX, e.pageY], + offset: [e.offsetX, e.offsetY] + } + } as Msg)), + windowEvents.on('scroll', (e: Event) => { + return { + type: 'scrolled', + scroll: [window.scrollX, window.scrollY] + } as Msg; + }), windowEvents.on('resize', () => { return { type: 'resized', From 18af195cfd1e67d8ed4957a07166d661509fc286 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Van=20Keisbelck?= Date: Mon, 24 Apr 2023 14:13:07 +0200 Subject: [PATCH 21/21] bump to 2.2.2 --- core/package.json | 2 +- samples/package.json | 4 ++-- tea-cup/package.json | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/core/package.json b/core/package.json index 774bf24..bd7e76a 100644 --- a/core/package.json +++ b/core/package.json @@ -1,6 +1,6 @@ { "name": "tea-cup-core", - "version": "2.2.1", + "version": "2.2.2", "description": "react-tea-cup core classes and utilities (Maybe etc)", "author": "Rémi Van Keisbelck ", "license": "MIT", diff --git a/samples/package.json b/samples/package.json index 4ccf2d4..686901e 100644 --- a/samples/package.json +++ b/samples/package.json @@ -11,8 +11,8 @@ "react": "^16.7.0", "react-dom": "^16.7.0", "react-scripts": "3.4.3", - "react-tea-cup": "2.2.1", - "tea-cup-core": "2.2.1" + "react-tea-cup": "2.2.2", + "tea-cup-core": "2.2.2" }, "scripts": { "start": "react-scripts start", diff --git a/tea-cup/package.json b/tea-cup/package.json index 62ec63d..a1d5f0d 100644 --- a/tea-cup/package.json +++ b/tea-cup/package.json @@ -1,6 +1,6 @@ { "name": "react-tea-cup", - "version": "2.2.1", + "version": "2.2.2", "description": "Put some TEA in your React.", "author": "Rémi Van Keisbelck ", "license": "MIT", @@ -23,7 +23,7 @@ "dependencies": {}, "peerDependencies": { "react": "^16.7.0 || ^17.0.1", - "tea-cup-core": "^2.2.1" + "tea-cup-core": "^2.2.2" }, "devDependencies": { "@types/jsdom": "^16.2.5",