From 116e2966abe6961b371ec5480281c18308b1bd43 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 13 Sep 2024 10:38:46 +0100 Subject: [PATCH 01/13] chore(deps-dev): Bump express from 4.19.2 to 4.21.0 (#2707) Bumps [express](https://github.com/expressjs/express) from 4.19.2 to 4.21.0. - [Release notes](https://github.com/expressjs/express/releases) - [Changelog](https://github.com/expressjs/express/blob/4.21.0/History.md) - [Commits](https://github.com/expressjs/express/compare/4.19.2...4.21.0) --- updated-dependencies: - dependency-name: express dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- yarn.lock | 110 +++++++++++++++++++++++++++++------------------------- 1 file changed, 59 insertions(+), 51 deletions(-) diff --git a/yarn.lock b/yarn.lock index bdb47413c..986fa00e3 100644 --- a/yarn.lock +++ b/yarn.lock @@ -9498,10 +9498,10 @@ bluebird@*, bluebird@3.7.2, bluebird@^3.7.2: resolved "https://registry.yarnpkg.com/bluebird/-/bluebird-3.7.2.tgz#9f229c15be272454ffa973ace0dbee79a1b0c36f" integrity sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg== -body-parser@1.20.2: - version "1.20.2" - resolved "https://registry.yarnpkg.com/body-parser/-/body-parser-1.20.2.tgz#6feb0e21c4724d06de7ff38da36dad4f57a747fd" - integrity sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA== +body-parser@1.20.3: + version "1.20.3" + resolved "https://registry.yarnpkg.com/body-parser/-/body-parser-1.20.3.tgz#1953431221c6fb5cd63c4b36d53fab0928e548c6" + integrity sha512-7rAxByjUMqQ3/bHJy7D6OGXvx/MMc4IqBn/X0fcM1QUcAItpZrBEYhWGem+tzXH90c+G01ypMcYJBO9Y30203g== dependencies: bytes "3.1.2" content-type "~1.0.5" @@ -9511,7 +9511,7 @@ body-parser@1.20.2: http-errors "2.0.0" iconv-lite "0.4.24" on-finished "2.4.1" - qs "6.11.0" + qs "6.13.0" raw-body "2.5.2" type-is "~1.6.18" unpipe "1.0.0" @@ -11634,6 +11634,11 @@ encodeurl@~1.0.2: resolved "https://registry.yarnpkg.com/encodeurl/-/encodeurl-1.0.2.tgz#ad3ff4c86ec2d029322f5a02c3a9a606c95b3f59" integrity sha1-rT/0yG7C0CkyL1oCw6mmBslbP1k= +encodeurl@~2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/encodeurl/-/encodeurl-2.0.0.tgz#7b8ea898077d7e409d3ac45474ea38eaf0857a58" + integrity sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg== + encoding@^0.1.13: version "0.1.13" resolved "https://registry.yarnpkg.com/encoding/-/encoding-0.1.13.tgz#56574afdd791f54a8e9b2785c0582a2d26210fa9" @@ -12504,36 +12509,36 @@ exponential-backoff@^3.1.1: integrity sha512-dX7e/LHVJ6W3DE1MHWi9S1EYzDESENfLrYohG2G++ovZrYOkm4Knwa0mc1cn84xJOR4KEU0WSchhLbd0UklbHw== express@^4.17.3: - version "4.19.2" - resolved "https://registry.yarnpkg.com/express/-/express-4.19.2.tgz#e25437827a3aa7f2a827bc8171bbbb664a356465" - integrity sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q== + version "4.21.0" + resolved "https://registry.yarnpkg.com/express/-/express-4.21.0.tgz#d57cb706d49623d4ac27833f1cbc466b668eb915" + integrity sha512-VqcNGcj/Id5ZT1LZ/cfihi3ttTn+NJmkli2eZADigjq29qTlWi/hAQ43t/VLPq8+UX06FCEx3ByOYet6ZFblng== dependencies: accepts "~1.3.8" array-flatten "1.1.1" - body-parser "1.20.2" + body-parser "1.20.3" content-disposition "0.5.4" content-type "~1.0.4" cookie "0.6.0" cookie-signature "1.0.6" debug "2.6.9" depd "2.0.0" - encodeurl "~1.0.2" + encodeurl "~2.0.0" escape-html "~1.0.3" etag "~1.8.1" - finalhandler "1.2.0" + finalhandler "1.3.1" fresh "0.5.2" http-errors "2.0.0" - merge-descriptors "1.0.1" + merge-descriptors "1.0.3" methods "~1.1.2" on-finished "2.4.1" parseurl "~1.3.3" - path-to-regexp "0.1.7" + path-to-regexp "0.1.10" proxy-addr "~2.0.7" - qs "6.11.0" + qs "6.13.0" range-parser "~1.2.1" safe-buffer "5.2.1" - send "0.18.0" - serve-static "1.15.0" + send "0.19.0" + serve-static "1.16.2" setprototypeof "1.2.0" statuses "2.0.1" type-is "~1.6.18" @@ -12778,13 +12783,13 @@ fill-range@^7.1.1: dependencies: to-regex-range "^5.0.1" -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== +finalhandler@1.3.1: + version "1.3.1" + resolved "https://registry.yarnpkg.com/finalhandler/-/finalhandler-1.3.1.tgz#0c575f1d1d324ddd1da35ad7ece3df7d19088019" + integrity sha512-6BN9trH7bp3qvnrRyzsBz+g3lZxTNZTbVO2EV1CS0WIcDbawYVdYvGflME/9QP0h0pYlCDBCTjYa9nZzMDpyxQ== dependencies: debug "2.6.9" - encodeurl "~1.0.2" + encodeurl "~2.0.0" escape-html "~1.0.3" on-finished "2.4.1" parseurl "~1.3.3" @@ -16965,10 +16970,10 @@ meow@^8.1.2: type-fest "^0.18.0" yargs-parser "^20.2.3" -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= +merge-descriptors@1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/merge-descriptors/-/merge-descriptors-1.0.3.tgz#d80319a65f3c7935351e5cfdac8f9318504dbed5" + integrity sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ== merge-stream@^2.0.0: version "2.0.0" @@ -18652,10 +18657,10 @@ path-scurry@^1.11.1: lru-cache "^10.2.0" minipass "^5.0.0 || ^6.0.2 || ^7.0.0" -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= +path-to-regexp@0.1.10: + version "0.1.10" + resolved "https://registry.yarnpkg.com/path-to-regexp/-/path-to-regexp-0.1.10.tgz#67e9108c5c0551b9e5326064387de4763c4d5f8b" + integrity sha512-7lf7qcQidTku0Gu3YDPc8DJ1q7OOucfa/BSsIwjuh56VU7katFvuM8hULfkwB3Fns/rsVF7PwPKVw1sl5KQS9w== path-to-regexp@^1.7.0: version "1.8.0" @@ -19456,19 +19461,12 @@ qs@6.10.4: dependencies: side-channel "^1.0.4" -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== +qs@6.13.0, qs@^6.10.0: + version "6.13.0" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.13.0.tgz#6ca3bd58439f7e245655798997787b0d88a51906" + integrity sha512-+38qI9SOr8tfZ4QmJNplMUxqjbe7LKvvZgWdExBOmd+egZTtjLB67Gu0HRX3u/XOq7UU2Nx6nsjvS16Z9uwfpg== dependencies: - side-channel "^1.0.4" - -qs@^6.10.0: - version "6.11.1" - resolved "https://registry.yarnpkg.com/qs/-/qs-6.11.1.tgz#6c29dff97f0c0060765911ba65cbc9764186109f" - integrity sha512-0wsrzgTz/kAVIeuxSjnpGC56rzYtr6JT/2BwEvMaPhFIoYa1aGO8LbzuU1R0uUYQkLpWBTOj0l/CLAJB64J6nQ== - dependencies: - side-channel "^1.0.4" + side-channel "^1.0.6" querystring@0.2.0: version "0.2.0" @@ -20600,10 +20598,10 @@ semver@^6.0.0, semver@^6.3.0, semver@^6.3.1: resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.1.tgz#556d2ef8689146e46dcea4bfdd095f3434dffcb4" integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== -send@0.18.0: - version "0.18.0" - resolved "https://registry.yarnpkg.com/send/-/send-0.18.0.tgz#670167cc654b05f5aa4a767f9113bb371bc706be" - integrity sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg== +send@0.19.0: + version "0.19.0" + resolved "https://registry.yarnpkg.com/send/-/send-0.19.0.tgz#bbc5a388c8ea6c048967049dbeac0e4a3f09d7f8" + integrity sha512-dW41u5VfLXu8SJh5bwRmyYUbAoSB3c9uQh6L8h/KtsFREPWpbX1lrljJo186Jc4nmci/sGUZ9a0a0J2zgfq2hw== dependencies: debug "2.6.9" depd "2.0.0" @@ -20648,15 +20646,15 @@ serve-index@^1.9.1: mime-types "~2.1.17" parseurl "~1.3.2" -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== +serve-static@1.16.2: + version "1.16.2" + resolved "https://registry.yarnpkg.com/serve-static/-/serve-static-1.16.2.tgz#b6a5343da47f6bdd2673848bf45754941e803296" + integrity sha512-VqpjJZKadQB/PEbEwvFdO43Ax5dFBZ2UECszz8bQ7pi7wt//PWe1P6MN7eCnjsatYtBT6EuiClbjSWP2WrIoTw== dependencies: - encodeurl "~1.0.2" + encodeurl "~2.0.0" escape-html "~1.0.3" parseurl "~1.3.3" - send "0.18.0" + send "0.19.0" set-blocking@^2.0.0: version "2.0.0" @@ -20759,6 +20757,16 @@ side-channel@^1.0.4: get-intrinsic "^1.0.2" object-inspect "^1.9.0" +side-channel@^1.0.6: + version "1.0.6" + resolved "https://registry.yarnpkg.com/side-channel/-/side-channel-1.0.6.tgz#abd25fb7cd24baf45466406b1096b7831c9215f2" + integrity sha512-fDW/EZ6Q9RiO8eFG8Hj+7u/oW+XrPTIChwCOM2+th2A6OblDtYYIpve9m+KvI9Z4C9qSEXlaGR6bTEYHReuglA== + dependencies: + call-bind "^1.0.7" + es-errors "^1.3.0" + get-intrinsic "^1.2.4" + object-inspect "^1.13.1" + signal-exit@3.0.7, signal-exit@^3.0.7: version "3.0.7" resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.7.tgz#a9a1767f8af84155114eaabd73f99273c8f59ad9" From 77a3a002ca9d3c7c7c8fdc2d8cd65bb553cc454d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 25 Sep 2024 16:23:06 +0100 Subject: [PATCH 02/13] chore(deps): Bump rollup from 4.18.0 to 4.22.4 (#2715) Bumps [rollup](https://github.com/rollup/rollup) from 4.18.0 to 4.22.4. - [Release notes](https://github.com/rollup/rollup/releases) - [Changelog](https://github.com/rollup/rollup/blob/master/CHANGELOG.md) - [Commits](https://github.com/rollup/rollup/compare/v4.18.0...v4.22.4) --- updated-dependencies: - dependency-name: rollup dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- yarn.lock | 196 +++++++++++++++++++++++++++--------------------------- 1 file changed, 98 insertions(+), 98 deletions(-) diff --git a/yarn.lock b/yarn.lock index 986fa00e3..61dbf6fad 100644 --- a/yarn.lock +++ b/yarn.lock @@ -5341,85 +5341,85 @@ estree-walker "^2.0.2" picomatch "^2.3.1" -"@rollup/rollup-android-arm-eabi@4.18.0": - version "4.18.0" - resolved "https://registry.yarnpkg.com/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.18.0.tgz#bbd0e616b2078cd2d68afc9824d1fadb2f2ffd27" - integrity sha512-Tya6xypR10giZV1XzxmH5wr25VcZSncG0pZIjfePT0OVBvqNEurzValetGNarVrGiq66EBVAFn15iYX4w6FKgQ== - -"@rollup/rollup-android-arm64@4.18.0": - version "4.18.0" - resolved "https://registry.yarnpkg.com/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.18.0.tgz#97255ef6384c5f73f4800c0de91f5f6518e21203" - integrity sha512-avCea0RAP03lTsDhEyfy+hpfr85KfyTctMADqHVhLAF3MlIkq83CP8UfAHUssgXTYd+6er6PaAhx/QGv4L1EiA== - -"@rollup/rollup-darwin-arm64@4.18.0": - version "4.18.0" - resolved "https://registry.yarnpkg.com/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.18.0.tgz#b6dd74e117510dfe94541646067b0545b42ff096" - integrity sha512-IWfdwU7KDSm07Ty0PuA/W2JYoZ4iTj3TUQjkVsO/6U+4I1jN5lcR71ZEvRh52sDOERdnNhhHU57UITXz5jC1/w== - -"@rollup/rollup-darwin-x64@4.18.0": - version "4.18.0" - resolved "https://registry.yarnpkg.com/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.18.0.tgz#e07d76de1cec987673e7f3d48ccb8e106d42c05c" - integrity sha512-n2LMsUz7Ynu7DoQrSQkBf8iNrjOGyPLrdSg802vk6XT3FtsgX6JbE8IHRvposskFm9SNxzkLYGSq9QdpLYpRNA== - -"@rollup/rollup-linux-arm-gnueabihf@4.18.0": - version "4.18.0" - resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.18.0.tgz#9f1a6d218b560c9d75185af4b8bb42f9f24736b8" - integrity sha512-C/zbRYRXFjWvz9Z4haRxcTdnkPt1BtCkz+7RtBSuNmKzMzp3ZxdM28Mpccn6pt28/UWUCTXa+b0Mx1k3g6NOMA== - -"@rollup/rollup-linux-arm-musleabihf@4.18.0": - version "4.18.0" - resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.18.0.tgz#53618b92e6ffb642c7b620e6e528446511330549" - integrity sha512-l3m9ewPgjQSXrUMHg93vt0hYCGnrMOcUpTz6FLtbwljo2HluS4zTXFy2571YQbisTnfTKPZ01u/ukJdQTLGh9A== - -"@rollup/rollup-linux-arm64-gnu@4.18.0": - version "4.18.0" - resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.18.0.tgz#99a7ba5e719d4f053761a698f7b52291cefba577" - integrity sha512-rJ5D47d8WD7J+7STKdCUAgmQk49xuFrRi9pZkWoRD1UeSMakbcepWXPF8ycChBoAqs1pb2wzvbY6Q33WmN2ftw== - -"@rollup/rollup-linux-arm64-musl@4.18.0": - version "4.18.0" - resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.18.0.tgz#f53db99a45d9bc00ce94db8a35efa7c3c144a58c" - integrity sha512-be6Yx37b24ZwxQ+wOQXXLZqpq4jTckJhtGlWGZs68TgdKXJgw54lUUoFYrg6Zs/kjzAQwEwYbp8JxZVzZLRepQ== - -"@rollup/rollup-linux-powerpc64le-gnu@4.18.0": - version "4.18.0" - resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.18.0.tgz#cbb0837408fe081ce3435cf3730e090febafc9bf" - integrity sha512-hNVMQK+qrA9Todu9+wqrXOHxFiD5YmdEi3paj6vP02Kx1hjd2LLYR2eaN7DsEshg09+9uzWi2W18MJDlG0cxJA== - -"@rollup/rollup-linux-riscv64-gnu@4.18.0": - version "4.18.0" - resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.18.0.tgz#8ed09c1d1262ada4c38d791a28ae0fea28b80cc9" - integrity sha512-ROCM7i+m1NfdrsmvwSzoxp9HFtmKGHEqu5NNDiZWQtXLA8S5HBCkVvKAxJ8U+CVctHwV2Gb5VUaK7UAkzhDjlg== - -"@rollup/rollup-linux-s390x-gnu@4.18.0": - version "4.18.0" - resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.18.0.tgz#938138d3c8e0c96f022252a28441dcfb17afd7ec" - integrity sha512-0UyyRHyDN42QL+NbqevXIIUnKA47A+45WyasO+y2bGJ1mhQrfrtXUpTxCOrfxCR4esV3/RLYyucGVPiUsO8xjg== - -"@rollup/rollup-linux-x64-gnu@4.18.0": - version "4.18.0" - resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.18.0.tgz#1a7481137a54740bee1ded4ae5752450f155d942" - integrity sha512-xuglR2rBVHA5UsI8h8UbX4VJ470PtGCf5Vpswh7p2ukaqBGFTnsfzxUBetoWBWymHMxbIG0Cmx7Y9qDZzr648w== - -"@rollup/rollup-linux-x64-musl@4.18.0": - version "4.18.0" - resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.18.0.tgz#f1186afc601ac4f4fc25fac4ca15ecbee3a1874d" - integrity sha512-LKaqQL9osY/ir2geuLVvRRs+utWUNilzdE90TpyoX0eNqPzWjRm14oMEE+YLve4k/NAqCdPkGYDaDF5Sw+xBfg== - -"@rollup/rollup-win32-arm64-msvc@4.18.0": - version "4.18.0" - resolved "https://registry.yarnpkg.com/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.18.0.tgz#ed6603e93636a96203c6915be4117245c1bd2daf" - integrity sha512-7J6TkZQFGo9qBKH0pk2cEVSRhJbL6MtfWxth7Y5YmZs57Pi+4x6c2dStAUvaQkHQLnEQv1jzBUW43GvZW8OFqA== - -"@rollup/rollup-win32-ia32-msvc@4.18.0": - version "4.18.0" - resolved "https://registry.yarnpkg.com/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.18.0.tgz#14e0b404b1c25ebe6157a15edb9c46959ba74c54" - integrity sha512-Txjh+IxBPbkUB9+SXZMpv+b/vnTEtFyfWZgJ6iyCmt2tdx0OF5WhFowLmnh8ENGNpfUlUZkdI//4IEmhwPieNg== - -"@rollup/rollup-win32-x64-msvc@4.18.0": - version "4.18.0" - resolved "https://registry.yarnpkg.com/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.18.0.tgz#5d694d345ce36b6ecf657349e03eb87297e68da4" - integrity sha512-UOo5FdvOL0+eIVTgS4tIdbW+TtnBLWg1YBCcU2KWM7nuNwRz9bksDX1bekJJCpu25N1DVWaCwnT39dVQxzqS8g== +"@rollup/rollup-android-arm-eabi@4.22.4": + version "4.22.4" + resolved "https://registry.yarnpkg.com/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.22.4.tgz#8b613b9725e8f9479d142970b106b6ae878610d5" + integrity sha512-Fxamp4aEZnfPOcGA8KSNEohV8hX7zVHOemC8jVBoBUHu5zpJK/Eu3uJwt6BMgy9fkvzxDaurgj96F/NiLukF2w== + +"@rollup/rollup-android-arm64@4.22.4": + version "4.22.4" + resolved "https://registry.yarnpkg.com/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.22.4.tgz#654ca1049189132ff602bfcf8df14c18da1f15fb" + integrity sha512-VXoK5UMrgECLYaMuGuVTOx5kcuap1Jm8g/M83RnCHBKOqvPPmROFJGQaZhGccnsFtfXQ3XYa4/jMCJvZnbJBdA== + +"@rollup/rollup-darwin-arm64@4.22.4": + version "4.22.4" + resolved "https://registry.yarnpkg.com/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.22.4.tgz#6d241d099d1518ef0c2205d96b3fa52e0fe1954b" + integrity sha512-xMM9ORBqu81jyMKCDP+SZDhnX2QEVQzTcC6G18KlTQEzWK8r/oNZtKuZaCcHhnsa6fEeOBionoyl5JsAbE/36Q== + +"@rollup/rollup-darwin-x64@4.22.4": + version "4.22.4" + resolved "https://registry.yarnpkg.com/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.22.4.tgz#42bd19d292a57ee11734c980c4650de26b457791" + integrity sha512-aJJyYKQwbHuhTUrjWjxEvGnNNBCnmpHDvrb8JFDbeSH3m2XdHcxDd3jthAzvmoI8w/kSjd2y0udT+4okADsZIw== + +"@rollup/rollup-linux-arm-gnueabihf@4.22.4": + version "4.22.4" + resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.22.4.tgz#f23555ee3d8fe941c5c5fd458cd22b65eb1c2232" + integrity sha512-j63YtCIRAzbO+gC2L9dWXRh5BFetsv0j0va0Wi9epXDgU/XUi5dJKo4USTttVyK7fGw2nPWK0PbAvyliz50SCQ== + +"@rollup/rollup-linux-arm-musleabihf@4.22.4": + version "4.22.4" + resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.22.4.tgz#f3bbd1ae2420f5539d40ac1fde2b38da67779baa" + integrity sha512-dJnWUgwWBX1YBRsuKKMOlXCzh2Wu1mlHzv20TpqEsfdZLb3WoJW2kIEsGwLkroYf24IrPAvOT/ZQ2OYMV6vlrg== + +"@rollup/rollup-linux-arm64-gnu@4.22.4": + version "4.22.4" + resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.22.4.tgz#7abe900120113e08a1f90afb84c7c28774054d15" + integrity sha512-AdPRoNi3NKVLolCN/Sp4F4N1d98c4SBnHMKoLuiG6RXgoZ4sllseuGioszumnPGmPM2O7qaAX/IJdeDU8f26Aw== + +"@rollup/rollup-linux-arm64-musl@4.22.4": + version "4.22.4" + resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.22.4.tgz#9e655285c8175cd44f57d6a1e8e5dedfbba1d820" + integrity sha512-Gl0AxBtDg8uoAn5CCqQDMqAx22Wx22pjDOjBdmG0VIWX3qUBHzYmOKh8KXHL4UpogfJ14G4wk16EQogF+v8hmA== + +"@rollup/rollup-linux-powerpc64le-gnu@4.22.4": + version "4.22.4" + resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.22.4.tgz#9a79ae6c9e9d8fe83d49e2712ecf4302db5bef5e" + integrity sha512-3aVCK9xfWW1oGQpTsYJJPF6bfpWfhbRnhdlyhak2ZiyFLDaayz0EP5j9V1RVLAAxlmWKTDfS9wyRyY3hvhPoOg== + +"@rollup/rollup-linux-riscv64-gnu@4.22.4": + version "4.22.4" + resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.22.4.tgz#67ac70eca4ace8e2942fabca95164e8874ab8128" + integrity sha512-ePYIir6VYnhgv2C5Xe9u+ico4t8sZWXschR6fMgoPUK31yQu7hTEJb7bCqivHECwIClJfKgE7zYsh1qTP3WHUA== + +"@rollup/rollup-linux-s390x-gnu@4.22.4": + version "4.22.4" + resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.22.4.tgz#9f883a7440f51a22ed7f99e1d070bd84ea5005fc" + integrity sha512-GqFJ9wLlbB9daxhVlrTe61vJtEY99/xB3C8e4ULVsVfflcpmR6c8UZXjtkMA6FhNONhj2eA5Tk9uAVw5orEs4Q== + +"@rollup/rollup-linux-x64-gnu@4.22.4": + version "4.22.4" + resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.22.4.tgz#70116ae6c577fe367f58559e2cffb5641a1dd9d0" + integrity sha512-87v0ol2sH9GE3cLQLNEy0K/R0pz1nvg76o8M5nhMR0+Q+BBGLnb35P0fVz4CQxHYXaAOhE8HhlkaZfsdUOlHwg== + +"@rollup/rollup-linux-x64-musl@4.22.4": + version "4.22.4" + resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.22.4.tgz#f473f88219feb07b0b98b53a7923be716d1d182f" + integrity sha512-UV6FZMUgePDZrFjrNGIWzDo/vABebuXBhJEqrHxrGiU6HikPy0Z3LfdtciIttEUQfuDdCn8fqh7wiFJjCNwO+g== + +"@rollup/rollup-win32-arm64-msvc@4.22.4": + version "4.22.4" + resolved "https://registry.yarnpkg.com/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.22.4.tgz#4349482d17f5d1c58604d1c8900540d676f420e0" + integrity sha512-BjI+NVVEGAXjGWYHz/vv0pBqfGoUH0IGZ0cICTn7kB9PyjrATSkX+8WkguNjWoj2qSr1im/+tTGRaY+4/PdcQw== + +"@rollup/rollup-win32-ia32-msvc@4.22.4": + version "4.22.4" + resolved "https://registry.yarnpkg.com/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.22.4.tgz#a6fc39a15db618040ec3c2a24c1e26cb5f4d7422" + integrity sha512-SiWG/1TuUdPvYmzmYnmd3IEifzR61Tragkbx9D3+R8mzQqDBz8v+BvZNDlkiTtI9T15KYZhP0ehn3Dld4n9J5g== + +"@rollup/rollup-win32-x64-msvc@4.22.4": + version "4.22.4" + resolved "https://registry.yarnpkg.com/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.22.4.tgz#3dd5d53e900df2a40841882c02e56f866c04d202" + integrity sha512-j8pPKp53/lq9lMXN57S8cFz0MynJk8OWNuUnXct/9KCpKU7DgU3bYMJhwWmcqC0UU29p8Lr0/7KEVcaM6bf47Q== "@semantic-release/commit-analyzer@^11.0.0", "@semantic-release/commit-analyzer@^11.1.0": version "11.1.0" @@ -20353,28 +20353,28 @@ rimraf@~2.6.2: glob "^7.1.3" rollup@^4.18.0: - version "4.18.0" - resolved "https://registry.yarnpkg.com/rollup/-/rollup-4.18.0.tgz#497f60f0c5308e4602cf41136339fbf87d5f5dda" - integrity sha512-QmJz14PX3rzbJCN1SG4Xe/bAAX2a6NpCP8ab2vfu2GiUr8AQcr2nCV/oEO3yneFarB67zk8ShlIyWb2LGTb3Sg== + version "4.22.4" + resolved "https://registry.yarnpkg.com/rollup/-/rollup-4.22.4.tgz#4135a6446671cd2a2453e1ad42a45d5973ec3a0f" + integrity sha512-vD8HJ5raRcWOyymsR6Z3o6+RzfEPCnVLMFJ6vRslO1jt4LO6dUo5Qnpg7y4RkZFM2DMe3WUirkI5c16onjrc6A== dependencies: "@types/estree" "1.0.5" optionalDependencies: - "@rollup/rollup-android-arm-eabi" "4.18.0" - "@rollup/rollup-android-arm64" "4.18.0" - "@rollup/rollup-darwin-arm64" "4.18.0" - "@rollup/rollup-darwin-x64" "4.18.0" - "@rollup/rollup-linux-arm-gnueabihf" "4.18.0" - "@rollup/rollup-linux-arm-musleabihf" "4.18.0" - "@rollup/rollup-linux-arm64-gnu" "4.18.0" - "@rollup/rollup-linux-arm64-musl" "4.18.0" - "@rollup/rollup-linux-powerpc64le-gnu" "4.18.0" - "@rollup/rollup-linux-riscv64-gnu" "4.18.0" - "@rollup/rollup-linux-s390x-gnu" "4.18.0" - "@rollup/rollup-linux-x64-gnu" "4.18.0" - "@rollup/rollup-linux-x64-musl" "4.18.0" - "@rollup/rollup-win32-arm64-msvc" "4.18.0" - "@rollup/rollup-win32-ia32-msvc" "4.18.0" - "@rollup/rollup-win32-x64-msvc" "4.18.0" + "@rollup/rollup-android-arm-eabi" "4.22.4" + "@rollup/rollup-android-arm64" "4.22.4" + "@rollup/rollup-darwin-arm64" "4.22.4" + "@rollup/rollup-darwin-x64" "4.22.4" + "@rollup/rollup-linux-arm-gnueabihf" "4.22.4" + "@rollup/rollup-linux-arm-musleabihf" "4.22.4" + "@rollup/rollup-linux-arm64-gnu" "4.22.4" + "@rollup/rollup-linux-arm64-musl" "4.22.4" + "@rollup/rollup-linux-powerpc64le-gnu" "4.22.4" + "@rollup/rollup-linux-riscv64-gnu" "4.22.4" + "@rollup/rollup-linux-s390x-gnu" "4.22.4" + "@rollup/rollup-linux-x64-gnu" "4.22.4" + "@rollup/rollup-linux-x64-musl" "4.22.4" + "@rollup/rollup-win32-arm64-msvc" "4.22.4" + "@rollup/rollup-win32-ia32-msvc" "4.22.4" + "@rollup/rollup-win32-x64-msvc" "4.22.4" fsevents "~2.3.2" rst-selector-parser@^2.2.3: From 213f05e8b0891440282f9fad709ea3e1728876b2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 25 Sep 2024 15:33:21 +0000 Subject: [PATCH 03/13] chore(deps-dev): Bump postcss-import from 14.0.2 to 16.1.0 (#2709) Bumps [postcss-import](https://github.com/postcss/postcss-import) from 14.0.2 to 16.1.0. - [Release notes](https://github.com/postcss/postcss-import/releases) - [Changelog](https://github.com/postcss/postcss-import/blob/master/CHANGELOG.md) - [Commits](https://github.com/postcss/postcss-import/compare/14.0.2...16.1.0) --- updated-dependencies: - dependency-name: postcss-import dependency-type: direct:development update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- package.json | 2 +- yarn.lock | 18 +++++------------- 2 files changed, 6 insertions(+), 14 deletions(-) diff --git a/package.json b/package.json index 9f5c5c45e..0bbff8edb 100644 --- a/package.json +++ b/package.json @@ -49,7 +49,7 @@ "lerna": "^7.4.2", "postcss": "8.4.43", "postcss-cli": "8.3.1", - "postcss-import": "14.0.2", + "postcss-import": "16.1.0", "postcss-loader": "8.1.1", "prettier": "2.8.8", "process": "0.11.10", diff --git a/yarn.lock b/yarn.lock index 61dbf6fad..edda78fd3 100644 --- a/yarn.lock +++ b/yarn.lock @@ -18880,10 +18880,10 @@ postcss-discard-overridden@^5.0.1: resolved "https://registry.yarnpkg.com/postcss-discard-overridden/-/postcss-discard-overridden-5.0.1.tgz#454b41f707300b98109a75005ca4ab0ff2743ac6" integrity sha512-Y28H7y93L2BpJhrdUR2SR2fnSsT+3TVx1NmVQLbcnZWwIUpJ7mfcTC6Za9M2PG6w8j7UQRfzxqn8jU2VwFxo3Q== -postcss-import@14.0.2: - version "14.0.2" - resolved "https://registry.yarnpkg.com/postcss-import/-/postcss-import-14.0.2.tgz#60eff77e6be92e7b67fe469ec797d9424cae1aa1" - integrity sha512-BJ2pVK4KhUyMcqjuKs9RijV5tatNzNa73e/32aBVE/ejYPe37iH+6vAu9WvqUkB5OAYgLHzbSvzHnorybJCm9g== +postcss-import@16.1.0: + version "16.1.0" + resolved "https://registry.yarnpkg.com/postcss-import/-/postcss-import-16.1.0.tgz#258732175518129667fe1e2e2a05b19b5654b96a" + integrity sha512-7hsAZ4xGXl4MW+OKEWCnF6T5jqBw80/EE9aXg1r2yyn1RsVEU8EtKXbijEODa+rg7iih4bKf7vlvTGYR4CnPNg== dependencies: postcss-value-parser "^4.0.0" read-cache "^1.0.0" @@ -20239,15 +20239,7 @@ resolve-url-loader@^5.0.0: postcss "^8.2.14" source-map "0.6.1" -resolve@^1.1.6, resolve@^1.1.7, resolve@^1.10.0, resolve@^1.14.2, resolve@^1.18.1: - version "1.20.0" - resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.20.0.tgz#629a013fb3f70755d6f0b7935cc1c2c5378b1975" - integrity sha512-wENBPt4ySzg4ybFQW2TT1zMQucPK95HSh/nq2CFTZVOGut2+pQvSsgtda4d26YrYcr067wjbmzOG8byDPBX63A== - dependencies: - is-core-module "^2.2.0" - path-parse "^1.0.6" - -resolve@^1.20.0, resolve@^1.22.1, resolve@^1.22.4: +resolve@^1.1.6, resolve@^1.1.7, resolve@^1.10.0, resolve@^1.14.2, resolve@^1.18.1, resolve@^1.20.0, resolve@^1.22.1, resolve@^1.22.4: version "1.22.8" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.22.8.tgz#b6c87a9f2aa06dfab52e3d70ac8cde321fa5a48d" integrity sha512-oKWePCxqpd6FlLvGV1VU0x7bkPmmCNolxzjMf4NczoDnQcIWrAF+cPtZn5i6n+RfD2d9i0tzpKnG6Yk168yIyw== From 3f6dafe6e5b268abdd6328cb1ef7e1562ee08b23 Mon Sep 17 00:00:00 2001 From: SB-venkatyadavilli <165135356+SB-venkatyadavilli@users.noreply.github.com> Date: Mon, 30 Sep 2024 16:58:06 +0530 Subject: [PATCH 04/13] fix:copy paste URL & bumping the Elements versions (#2714) fix/979 merging into main branch --- packages/elements-core/package.json | 2 +- .../src/components/Docs/HttpOperation/HttpOperation.tsx | 4 ++-- packages/elements-dev-portal/package.json | 4 ++-- packages/elements/package.json | 4 ++-- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/packages/elements-core/package.json b/packages/elements-core/package.json index 28c205989..5a9dbc6b9 100644 --- a/packages/elements-core/package.json +++ b/packages/elements-core/package.json @@ -1,6 +1,6 @@ { "name": "@stoplight/elements-core", - "version": "8.4.3", + "version": "8.4.4", "sideEffects": [ "web-components.min.js", "src/web-components/**", diff --git a/packages/elements-core/src/components/Docs/HttpOperation/HttpOperation.tsx b/packages/elements-core/src/components/Docs/HttpOperation/HttpOperation.tsx index 938616410..21dacf5da 100644 --- a/packages/elements-core/src/components/Docs/HttpOperation/HttpOperation.tsx +++ b/packages/elements-core/src/components/Docs/HttpOperation/HttpOperation.tsx @@ -159,12 +159,12 @@ function MethodPathInner({ method, path, chosenServerUrl }: MethodPathProps & { const pathElem = ( - + {chosenServerUrl} - + {path} diff --git a/packages/elements-dev-portal/package.json b/packages/elements-dev-portal/package.json index 99a82877a..ad2ec39ed 100644 --- a/packages/elements-dev-portal/package.json +++ b/packages/elements-dev-portal/package.json @@ -1,6 +1,6 @@ { "name": "@stoplight/elements-dev-portal", - "version": "2.4.4", + "version": "2.4.5", "description": "UI components for composing beautiful developer documentation.", "keywords": [], "sideEffects": [ @@ -66,7 +66,7 @@ "dependencies": { "@stoplight/markdown-viewer": "^5.7.1", "@stoplight/mosaic": "^1.53.4", - "@stoplight/elements-core": "^8.4.3", + "@stoplight/elements-core": "^8.4.4", "@stoplight/path": "^1.3.2", "@stoplight/types": "^14.0.0", "classnames": "^2.2.6", diff --git a/packages/elements/package.json b/packages/elements/package.json index bac5c8b07..1463321b6 100644 --- a/packages/elements/package.json +++ b/packages/elements/package.json @@ -1,6 +1,6 @@ { "name": "@stoplight/elements", - "version": "8.4.3", + "version": "8.4.4", "description": "UI components for composing beautiful developer documentation.", "keywords": [], "sideEffects": [ @@ -63,7 +63,7 @@ ] }, "dependencies": { - "@stoplight/elements-core": "^8.4.3", + "@stoplight/elements-core": "^8.4.4", "@stoplight/http-spec": "^7.1.0", "@stoplight/json": "^3.18.1", "@stoplight/mosaic": "^1.53.4", From 286b029823b51831a5b9ca7068d2e8a76293d0c4 Mon Sep 17 00:00:00 2001 From: Damian Bil <109211367+Relionnn@users.noreply.github.com> Date: Mon, 30 Sep 2024 16:46:47 +0200 Subject: [PATCH 05/13] feat: Read only fields are excluded from Webhook docs (PROVCON-2826) (#2718) * feat: Read only fields are excluded from Webhook docs (PROVCON-2826) * version update --- packages/elements-core/package.json | 2 +- .../src/components/Docs/HttpOperation/Body.tsx | 6 +++--- .../src/components/Docs/HttpOperation/HttpOperation.tsx | 6 +----- .../src/components/Docs/HttpOperation/Request.tsx | 4 +++- .../src/components/TryIt/Body/useTextRequestBodyState.ts | 3 ++- packages/elements-core/src/components/TryIt/TryIt.tsx | 5 ++++- packages/elements-dev-portal/package.json | 4 ++-- packages/elements/package.json | 4 ++-- 8 files changed, 18 insertions(+), 16 deletions(-) diff --git a/packages/elements-core/package.json b/packages/elements-core/package.json index 5a9dbc6b9..27dff13a4 100644 --- a/packages/elements-core/package.json +++ b/packages/elements-core/package.json @@ -1,6 +1,6 @@ { "name": "@stoplight/elements-core", - "version": "8.4.4", + "version": "8.4.5", "sideEffects": [ "web-components.min.js", "src/web-components/**", diff --git a/packages/elements-core/src/components/Docs/HttpOperation/Body.tsx b/packages/elements-core/src/components/Docs/HttpOperation/Body.tsx index f90d2792e..420e769ba 100644 --- a/packages/elements-core/src/components/Docs/HttpOperation/Body.tsx +++ b/packages/elements-core/src/components/Docs/HttpOperation/Body.tsx @@ -13,6 +13,7 @@ import { SectionSubtitle } from '../Sections'; export interface BodyProps { body: IHttpOperationRequestBody; onChange?: (requestBodyIndex: number) => void; + isHttpWebhookOperation?: boolean; } export const isBodyEmpty = (body?: BodyProps['body']) => { @@ -23,7 +24,7 @@ export const isBodyEmpty = (body?: BodyProps['body']) => { return contents.length === 0 && !description?.trim(); }; -export const Body = ({ body, onChange }: BodyProps) => { +export const Body = ({ body, onChange, isHttpWebhookOperation = false }: BodyProps) => { const [refResolver, maxRefDepth] = useSchemaInlineRefResolver(); const [chosenContent, setChosenContent] = React.useState(0); const { nodeHasChanged, renderExtensionAddon } = useOptionsCtx(); @@ -61,13 +62,12 @@ export const Body = ({ body, onChange }: BodyProps) => { )} - {isJSONSchema(schema) && ( ( )} - - - {data.responses && ( ( isCompact={isCompact} /> )} - {data.callbacks?.length ? : null} - {isCompact && tryItPanel} ); diff --git a/packages/elements-core/src/components/Docs/HttpOperation/Request.tsx b/packages/elements-core/src/components/Docs/HttpOperation/Request.tsx index 90bdcd087..6d2bff1ce 100644 --- a/packages/elements-core/src/components/Docs/HttpOperation/Request.tsx +++ b/packages/elements-core/src/components/Docs/HttpOperation/Request.tsx @@ -17,6 +17,7 @@ interface IRequestProps { operation: IHttpEndpointOperation; hideSecurityInfo?: boolean; onChange?: (requestBodyIndex: number) => void; + isHttpWebhookOperation?: boolean; } export const Request: React.FunctionComponent = ({ @@ -33,6 +34,7 @@ export const Request: React.FunctionComponent = ({ }, hideSecurityInfo, onChange, + isHttpWebhookOperation = false, }) => { if (!request || typeof request !== 'object') return null; @@ -82,7 +84,7 @@ export const Request: React.FunctionComponent = ({ )} - {body && } + {body && } ); }; diff --git a/packages/elements-core/src/components/TryIt/Body/useTextRequestBodyState.ts b/packages/elements-core/src/components/TryIt/Body/useTextRequestBodyState.ts index d6f2cc3a6..fc62347ae 100644 --- a/packages/elements-core/src/components/TryIt/Body/useTextRequestBodyState.ts +++ b/packages/elements-core/src/components/TryIt/Body/useTextRequestBodyState.ts @@ -11,9 +11,10 @@ import { useGenerateExampleFromMediaTypeContent } from '../../../utils/exampleGe export const useTextRequestBodyState = ( mediaTypeContent: IMediaTypeContent | undefined, + skipReadOnly: boolean, ): [string, React.Dispatch>] => { const initialRequestBody = useGenerateExampleFromMediaTypeContent(mediaTypeContent, undefined, { - skipReadOnly: true, + skipReadOnly, }); const [textRequestBody, setTextRequestBody] = React.useState(initialRequestBody); diff --git a/packages/elements-core/src/components/TryIt/TryIt.tsx b/packages/elements-core/src/components/TryIt/TryIt.tsx index 96c58ef59..246636174 100644 --- a/packages/elements-core/src/components/TryIt/TryIt.tsx +++ b/packages/elements-core/src/components/TryIt/TryIt.tsx @@ -98,7 +98,10 @@ export const TryIt: React.FC = ({ const [bodyParameterValues, setBodyParameterValues, isAllowedEmptyValues, setAllowedEmptyValues, formDataState] = useBodyParameterState(mediaTypeContent); - const [textRequestBody, setTextRequestBody] = useTextRequestBodyState(mediaTypeContent); + const [textRequestBody, setTextRequestBody] = useTextRequestBodyState( + mediaTypeContent, + !isHttpWebhookOperation(httpOperation), + ); const [operationAuthValue, setOperationAuthValue, setCurrentScheme] = usePersistedSecuritySchemeWithValues(); diff --git a/packages/elements-dev-portal/package.json b/packages/elements-dev-portal/package.json index ad2ec39ed..49372e5d7 100644 --- a/packages/elements-dev-portal/package.json +++ b/packages/elements-dev-portal/package.json @@ -1,6 +1,6 @@ { "name": "@stoplight/elements-dev-portal", - "version": "2.4.5", + "version": "2.4.6", "description": "UI components for composing beautiful developer documentation.", "keywords": [], "sideEffects": [ @@ -66,7 +66,7 @@ "dependencies": { "@stoplight/markdown-viewer": "^5.7.1", "@stoplight/mosaic": "^1.53.4", - "@stoplight/elements-core": "^8.4.4", + "@stoplight/elements-core": "^8.4.5", "@stoplight/path": "^1.3.2", "@stoplight/types": "^14.0.0", "classnames": "^2.2.6", diff --git a/packages/elements/package.json b/packages/elements/package.json index 1463321b6..d7a3439db 100644 --- a/packages/elements/package.json +++ b/packages/elements/package.json @@ -1,6 +1,6 @@ { "name": "@stoplight/elements", - "version": "8.4.4", + "version": "8.4.5", "description": "UI components for composing beautiful developer documentation.", "keywords": [], "sideEffects": [ @@ -63,7 +63,7 @@ ] }, "dependencies": { - "@stoplight/elements-core": "^8.4.4", + "@stoplight/elements-core": "^8.4.5", "@stoplight/http-spec": "^7.1.0", "@stoplight/json": "^3.18.1", "@stoplight/mosaic": "^1.53.4", From af20cc09773a5dd8a4252c7e73c39c590f548225 Mon Sep 17 00:00:00 2001 From: Dario Heinisch Date: Fri, 4 Oct 2024 03:43:53 -0700 Subject: [PATCH 06/13] FIX: Do not render undefined when license has not been defined (#2719) Co-authored-by: Nauman --- .../src/components/Docs/HttpService/AdditionalInfo.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/elements-core/src/components/Docs/HttpService/AdditionalInfo.tsx b/packages/elements-core/src/components/Docs/HttpService/AdditionalInfo.tsx index 89e13eb9d..882736dcf 100644 --- a/packages/elements-core/src/components/Docs/HttpService/AdditionalInfo.tsx +++ b/packages/elements-core/src/components/Docs/HttpService/AdditionalInfo.tsx @@ -31,7 +31,7 @@ export const AdditionalInfo: React.FC = ({ id, termsOfServi ? `[${license.name}](${licenseUrl})` : license?.identifier && licenseUrl ? `[${license?.identifier}](${licenseUrl})` - : undefined; + : ''; const tosLink = termsOfService ? `[Terms of Service](${termsOfService})` : ''; return contactLink || licenseLink || tosLink ? ( From dbe06b5266a15037892d8f76d729f8c5478f178a Mon Sep 17 00:00:00 2001 From: Ben Crosse <39087634+ben-smartbear@users.noreply.github.com> Date: Mon, 7 Oct 2024 11:13:31 +0100 Subject: [PATCH 07/13] sec: resolve @stoplight/react-error-boundary to v3 (#2720) --- package.json | 3 +- yarn.lock | 77 ++-------------------------------------------------- 2 files changed, 5 insertions(+), 75 deletions(-) diff --git a/package.json b/package.json index 0bbff8edb..a47076544 100644 --- a/package.json +++ b/package.json @@ -68,7 +68,8 @@ "resolutions": { "fast-xml-parser": "4.4.1", "tar": "6.2.1", - "micromatch": "4.0.8" + "micromatch": "4.0.8", + "@stoplight/react-error-boundary": "3.0.0" }, "scripts": { "demo": "yarn workspace @stoplight/elements-demo", diff --git a/yarn.lock b/yarn.lock index edda78fd3..0f03e3335 100644 --- a/yarn.lock +++ b/yarn.lock @@ -5515,70 +5515,6 @@ lodash-es "^4.17.21" read-pkg-up "^11.0.0" -"@sentry/browser@6.16.1": - version "6.16.1" - resolved "https://registry.yarnpkg.com/@sentry/browser/-/browser-6.16.1.tgz#4270ab0fbd1de425e339b3e7a364feb09f470a87" - integrity sha512-F2I5RL7RTLQF9CccMrqt73GRdK3FdqaChED3RulGQX5lH6U3exHGFxwyZxSrY4x6FedfBFYlfXWWCJXpLnFkow== - dependencies: - "@sentry/core" "6.16.1" - "@sentry/types" "6.16.1" - "@sentry/utils" "6.16.1" - tslib "^1.9.3" - -"@sentry/core@6.16.1": - version "6.16.1" - resolved "https://registry.yarnpkg.com/@sentry/core/-/core-6.16.1.tgz#d9f7a75f641acaddf21b6aafa7a32e142f68f17c" - integrity sha512-UFI0264CPUc5cR1zJH+S2UPOANpm6dLJOnsvnIGTjsrwzR0h8Hdl6rC2R/GPq+WNbnipo9hkiIwDlqbqvIU5vw== - dependencies: - "@sentry/hub" "6.16.1" - "@sentry/minimal" "6.16.1" - "@sentry/types" "6.16.1" - "@sentry/utils" "6.16.1" - tslib "^1.9.3" - -"@sentry/hub@6.16.1": - version "6.16.1" - resolved "https://registry.yarnpkg.com/@sentry/hub/-/hub-6.16.1.tgz#526e19db51f4412da8634734044c605b936a7b80" - integrity sha512-4PGtg6AfpqMkreTpL7ymDeQ/U1uXv03bKUuFdtsSTn/FRf9TLS4JB0KuTZCxfp1IRgAA+iFg6B784dDkT8R9eg== - dependencies: - "@sentry/types" "6.16.1" - "@sentry/utils" "6.16.1" - tslib "^1.9.3" - -"@sentry/minimal@6.16.1": - version "6.16.1" - resolved "https://registry.yarnpkg.com/@sentry/minimal/-/minimal-6.16.1.tgz#6a9506a92623d2ff1fc17d60989688323326772e" - integrity sha512-dq+mI1EQIvUM+zJtGCVgH3/B3Sbx4hKlGf2Usovm9KoqWYA+QpfVBholYDe/H2RXgO7LFEefDLvOdHDkqeJoyA== - dependencies: - "@sentry/hub" "6.16.1" - "@sentry/types" "6.16.1" - tslib "^1.9.3" - -"@sentry/react@^6.13.2": - version "6.16.1" - resolved "https://registry.yarnpkg.com/@sentry/react/-/react-6.16.1.tgz#d4930c4b23bcd307306a0549d20964d98caed38c" - integrity sha512-n8fOEKbym4kBi946q3AWXBNy1UKTmABj/hE2nAJbTWhi5IwdM7WBG6QCT2yq7oTHLuTxQrAwgKQc+A6zFTyVHg== - dependencies: - "@sentry/browser" "6.16.1" - "@sentry/minimal" "6.16.1" - "@sentry/types" "6.16.1" - "@sentry/utils" "6.16.1" - hoist-non-react-statics "^3.3.2" - tslib "^1.9.3" - -"@sentry/types@6.16.1": - version "6.16.1" - resolved "https://registry.yarnpkg.com/@sentry/types/-/types-6.16.1.tgz#4917607115b30315757c2cf84f80bac5100b8ac0" - integrity sha512-Wh354g30UsJ5kYJbercektGX4ZMc9MHU++1NjeN2bTMnbofEcpUDWIiKeulZEY65IC1iU+1zRQQgtYO+/hgCUQ== - -"@sentry/utils@6.16.1": - version "6.16.1" - resolved "https://registry.yarnpkg.com/@sentry/utils/-/utils-6.16.1.tgz#1b9e14c2831b6e8b816f7021b9876133bf2be008" - integrity sha512-7ngq/i4R8JZitJo9Sl8PDnjSbDehOxgr1vsoMmerIsyRZ651C/8B+jVkMhaAPgSdyJ0AlE3O7DKKTP1FXFw9qw== - dependencies: - "@sentry/types" "6.16.1" - tslib "^1.9.3" - "@sideway/address@^4.1.5": version "4.1.5" resolved "https://registry.yarnpkg.com/@sideway/address/-/address-4.1.5.tgz#4bc149a0076623ced99ca8208ba780d65a99b9d5" @@ -6458,14 +6394,7 @@ resolved "https://registry.yarnpkg.com/@stoplight/path/-/path-1.3.2.tgz#96e591496b72fde0f0cdae01a61d64f065bd9ede" integrity sha512-lyIc6JUlUA8Ve5ELywPC8I2Sdnh1zc1zmbYgVarhXIp9YeAB0ReeqmGEOWNtlHkbP2DAA1AL65Wfn2ncjK/jtQ== -"@stoplight/react-error-boundary@^2.0.0": - version "2.0.0" - resolved "https://registry.yarnpkg.com/@stoplight/react-error-boundary/-/react-error-boundary-2.0.0.tgz#63a2dcbaced4c77b4a9b6c3fb2be582de1d60236" - integrity sha512-r9cyaaH2h0kFe5c0aP+yJuY9CyXgfbBaMO6660M/wRQXqM49K5Ul7kexE4ei2cqYgo+Cd6ALl6RXSZFYwf2kCA== - dependencies: - "@sentry/react" "^6.13.2" - -"@stoplight/react-error-boundary@^3.0.0": +"@stoplight/react-error-boundary@3.0.0", "@stoplight/react-error-boundary@^2.0.0", "@stoplight/react-error-boundary@^3.0.0": version "3.0.0" resolved "https://registry.yarnpkg.com/@stoplight/react-error-boundary/-/react-error-boundary-3.0.0.tgz#aaeb7edd3ff0dbe7ab5508464038c4c88cfb4772" integrity sha512-lFuTpGy2fu4hffmRTnJot1URa9/ifVLyPPQg62WW3RYo9LsxxHF0PrnFzAeXEQb40g1kc55S/oX6zQc8YJrKXg== @@ -13935,7 +13864,7 @@ history@^5.0.0: dependencies: "@babel/runtime" "^7.7.6" -hoist-non-react-statics@^3.1.0, hoist-non-react-statics@^3.3.2: +hoist-non-react-statics@^3.1.0: version "3.3.2" resolved "https://registry.yarnpkg.com/hoist-non-react-statics/-/hoist-non-react-statics-3.3.2.tgz#ece0acaf71d62c2969c2ec59feff42a4b1a85b45" integrity sha512-/gGivxi8JPKWNm/W0jSmzcMPpfpPLc3dY/6GxhX2hQ9iGj3aDfklV4ET7NjKpSinLpJ5vafa9iiGIEZg10SfBw== @@ -22007,7 +21936,7 @@ tsconfig-paths@^4.1.2: minimist "^1.2.6" strip-bom "^3.0.0" -tslib@^1.13.0, tslib@^1.8.1, tslib@^1.9.3: +tslib@^1.13.0, tslib@^1.8.1: version "1.14.1" resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.14.1.tgz#cf2d38bdc34a134bcaf1091c41f6619e2f672d00" integrity sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg== From 360935fee10c48cc9b39e19de35ec17e5b44d00d Mon Sep 17 00:00:00 2001 From: SB-harshitajadhav <165134656+SB-harshitajadhav@users.noreply.github.com> Date: Thu, 10 Oct 2024 14:53:17 +0530 Subject: [PATCH 08/13] fix: internal schema apprears as object on logout (#2705) * fix: internal schema apprears as object * bump elements versions * reverted elements version * Added unit test case * elements versions updated * Added test cases to show error if all object has error * Added comment for test case and test description updated * Formated the testcases --------- Co-authored-by: Nauman --- packages/elements-core/package.json | 2 +- .../ref-resolving/resolvedObject.test.ts | 176 ++++++++++++++++++ .../src/utils/ref-resolving/resolvedObject.ts | 25 ++- packages/elements-dev-portal/package.json | 4 +- packages/elements/package.json | 4 +- 5 files changed, 205 insertions(+), 6 deletions(-) diff --git a/packages/elements-core/package.json b/packages/elements-core/package.json index 27dff13a4..3648d9328 100644 --- a/packages/elements-core/package.json +++ b/packages/elements-core/package.json @@ -1,6 +1,6 @@ { "name": "@stoplight/elements-core", - "version": "8.4.5", + "version": "8.4.6", "sideEffects": [ "web-components.min.js", "src/web-components/**", diff --git a/packages/elements-core/src/utils/ref-resolving/resolvedObject.test.ts b/packages/elements-core/src/utils/ref-resolving/resolvedObject.test.ts index 8144b0454..5d075c0ca 100644 --- a/packages/elements-core/src/utils/ref-resolving/resolvedObject.test.ts +++ b/packages/elements-core/src/utils/ref-resolving/resolvedObject.test.ts @@ -236,4 +236,180 @@ describe('createResolvedObject', () => { expect(resolvedObject).toEqual(originalObject); }); + + // If the schema is internal, the object contains 'x-sl-error-message' on logout. + it('removes object if contains an error for oneOf', () => { + const originalObject = { + oneOf: [ + { $ref: '#/__bundled__/0mui9s02880hl', 'x-stoplight': { id: '19c178fc05d4a' } }, + { + 'x-sl-error-message': 'You do not have permission to view this reference', + 'x-stoplight': { 'error-message': 'You do not have permission to view this reference', id: 'nezai0hyj4yak' }, + }, + { $ref: '#/__bundled__/iq2mwk8jvthd2', 'x-stoplight': { id: 'ovj32wmpxpg7p' } }, + ], + 'x-stoplight': { id: 'b73ff5df9864f' }, + }; + + const filteredObject = { + oneOf: [ + { $ref: '#/__bundled__/0mui9s02880hl', 'x-stoplight': { id: '19c178fc05d4a' } }, + { $ref: '#/__bundled__/iq2mwk8jvthd2', 'x-stoplight': { id: 'ovj32wmpxpg7p' } }, + ], + 'x-stoplight': { id: 'b73ff5df9864f' }, + }; + const resolvedObject = getOriginalObject(originalObject); + + expect(resolvedObject).toEqual(filteredObject); + }); + + it('removes object if contains an error for anyeOf', () => { + const originalObject = { + anyOf: [ + { $ref: '#/__bundled__/0mui9s02880hl', 'x-stoplight': { id: '19c178fc05d4a' } }, + { + 'x-sl-error-message': 'You do not have permission to view this reference', + 'x-stoplight': { 'error-message': 'You do not have permission to view this reference', id: 'nezai0hyj4yak' }, + }, + { $ref: '#/__bundled__/iq2mwk8jvthd2', 'x-stoplight': { id: 'ovj32wmpxpg7p' } }, + ], + 'x-stoplight': { id: 'b73ff5df9864f' }, + }; + + const filteredObject = { + anyOf: [ + { $ref: '#/__bundled__/0mui9s02880hl', 'x-stoplight': { id: '19c178fc05d4a' } }, + { $ref: '#/__bundled__/iq2mwk8jvthd2', 'x-stoplight': { id: 'ovj32wmpxpg7p' } }, + ], + 'x-stoplight': { id: 'b73ff5df9864f' }, + }; + const resolvedObject = getOriginalObject(originalObject); + + expect(resolvedObject).toEqual(filteredObject); + }); + + it('show the error if all schemas are internal for anyOf', () => { + const originalObject = { + anyOf: [ + [ + { + 'x-sl-error-message': 'You do not have permission to view this reference', + 'x-stoplight': { + 'error-message': 'You do not have permission to view this reference', + id: 'nezai0hyj4yak', + }, + }, + { + 'x-sl-error-message': 'You do not have permission to view this reference', + 'x-stoplight': { + 'error-message': 'You do not have permission to view this reference', + id: 'nezai0hyj4yak', + }, + }, + { + 'x-sl-error-message': 'You do not have permission to view this reference', + 'x-stoplight': { + 'error-message': 'You do not have permission to view this reference', + id: 'nezai0hyj4yak', + }, + }, + ], + ], + 'x-stoplight': { id: 'b73ff5df9864f' }, + }; + + const filteredObject = { + anyOf: [ + [ + { + 'x-sl-error-message': 'You do not have permission to view this reference', + 'x-stoplight': { + 'error-message': 'You do not have permission to view this reference', + id: 'nezai0hyj4yak', + }, + }, + { + 'x-sl-error-message': 'You do not have permission to view this reference', + 'x-stoplight': { + 'error-message': 'You do not have permission to view this reference', + id: 'nezai0hyj4yak', + }, + }, + { + 'x-sl-error-message': 'You do not have permission to view this reference', + 'x-stoplight': { + 'error-message': 'You do not have permission to view this reference', + id: 'nezai0hyj4yak', + }, + }, + ], + ], + 'x-stoplight': { id: 'b73ff5df9864f' }, + }; + const resolvedObject = getOriginalObject(originalObject); + + expect(resolvedObject).toEqual(filteredObject); + }); + it('show the error if all schemas are internal for oneOf', () => { + const originalObject = { + oneOf: [ + [ + { + 'x-sl-error-message': 'You do not have permission to view this reference', + 'x-stoplight': { + 'error-message': 'You do not have permission to view this reference', + id: 'nezai0hyj4yak', + }, + }, + { + 'x-sl-error-message': 'You do not have permission to view this reference', + 'x-stoplight': { + 'error-message': 'You do not have permission to view this reference', + id: 'nezai0hyj4yak', + }, + }, + { + 'x-sl-error-message': 'You do not have permission to view this reference', + 'x-stoplight': { + 'error-message': 'You do not have permission to view this reference', + id: 'nezai0hyj4yak', + }, + }, + ], + ], + 'x-stoplight': { id: 'b73ff5df9864f' }, + }; + + const filteredObject = { + oneOf: [ + [ + { + 'x-sl-error-message': 'You do not have permission to view this reference', + 'x-stoplight': { + 'error-message': 'You do not have permission to view this reference', + id: 'nezai0hyj4yak', + }, + }, + { + 'x-sl-error-message': 'You do not have permission to view this reference', + 'x-stoplight': { + 'error-message': 'You do not have permission to view this reference', + id: 'nezai0hyj4yak', + }, + }, + { + 'x-sl-error-message': 'You do not have permission to view this reference', + 'x-stoplight': { + 'error-message': 'You do not have permission to view this reference', + id: 'nezai0hyj4yak', + }, + }, + ], + ], + 'x-stoplight': { id: 'b73ff5df9864f' }, + }; + const resolvedObject = getOriginalObject(originalObject); + + expect(resolvedObject).toEqual(filteredObject); + }); }); diff --git a/packages/elements-core/src/utils/ref-resolving/resolvedObject.ts b/packages/elements-core/src/utils/ref-resolving/resolvedObject.ts index cb2406eb3..5cc071667 100644 --- a/packages/elements-core/src/utils/ref-resolving/resolvedObject.ts +++ b/packages/elements-core/src/utils/ref-resolving/resolvedObject.ts @@ -78,7 +78,30 @@ export const isResolvedObjectProxy = (someObject: object): boolean => { }; export const getOriginalObject = (resolvedObject: object): object => { - return (resolvedObject as Record)[originalObjectSymbol] || resolvedObject; + const originalObject: any = (resolvedObject as Record)[originalObjectSymbol] || resolvedObject; + if (!originalObject) { + return resolvedObject; + } + + const hasAllSchemaErrors = (array: any[]) => { + return array.every(item => item['x-sl-error-message'] !== undefined); + }; + + if (originalObject.anyOf) { + if (hasAllSchemaErrors(originalObject.anyOf)) { + return { ...originalObject, anyOf: [originalObject.anyOf] }; + } + const filteredArray = originalObject.anyOf.filter((item: { [x: string]: any }) => !item['x-sl-error-message']); + return { ...originalObject, anyOf: filteredArray }; + } else if (originalObject.oneOf) { + if (hasAllSchemaErrors(originalObject.oneOf)) { + return { ...originalObject, oneOf: [originalObject.oneOf] }; + } + const filteredArray = originalObject.oneOf.filter((item: { [x: string]: any }) => !item['x-sl-error-message']); + return { ...originalObject, oneOf: filteredArray }; + } + + return originalObject; }; export const isReference = hasRef; diff --git a/packages/elements-dev-portal/package.json b/packages/elements-dev-portal/package.json index 49372e5d7..1d10577b9 100644 --- a/packages/elements-dev-portal/package.json +++ b/packages/elements-dev-portal/package.json @@ -1,6 +1,6 @@ { "name": "@stoplight/elements-dev-portal", - "version": "2.4.6", + "version": "2.4.7", "description": "UI components for composing beautiful developer documentation.", "keywords": [], "sideEffects": [ @@ -66,7 +66,7 @@ "dependencies": { "@stoplight/markdown-viewer": "^5.7.1", "@stoplight/mosaic": "^1.53.4", - "@stoplight/elements-core": "^8.4.5", + "@stoplight/elements-core": "^8.4.6", "@stoplight/path": "^1.3.2", "@stoplight/types": "^14.0.0", "classnames": "^2.2.6", diff --git a/packages/elements/package.json b/packages/elements/package.json index d7a3439db..3a45c853e 100644 --- a/packages/elements/package.json +++ b/packages/elements/package.json @@ -1,6 +1,6 @@ { "name": "@stoplight/elements", - "version": "8.4.5", + "version": "8.4.6", "description": "UI components for composing beautiful developer documentation.", "keywords": [], "sideEffects": [ @@ -63,7 +63,7 @@ ] }, "dependencies": { - "@stoplight/elements-core": "^8.4.5", + "@stoplight/elements-core": "^8.4.6", "@stoplight/http-spec": "^7.1.0", "@stoplight/json": "^3.18.1", "@stoplight/mosaic": "^1.53.4", From fa047480f353857f3a65e35525f457972754a5dd Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Oct 2024 10:25:15 +0000 Subject: [PATCH 09/13] chore(deps): Bump http-proxy-middleware from 2.0.6 to 2.0.7 (#2728) Bumps [http-proxy-middleware](https://github.com/chimurai/http-proxy-middleware) from 2.0.6 to 2.0.7. - [Release notes](https://github.com/chimurai/http-proxy-middleware/releases) - [Changelog](https://github.com/chimurai/http-proxy-middleware/blob/v2.0.7/CHANGELOG.md) - [Commits](https://github.com/chimurai/http-proxy-middleware/compare/v2.0.6...v2.0.7) --- updated-dependencies: - dependency-name: http-proxy-middleware dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index 0f03e3335..e9c0c3b20 100644 --- a/yarn.lock +++ b/yarn.lock @@ -14082,9 +14082,9 @@ http-proxy-agent@^7.0.0: debug "^4.3.4" http-proxy-middleware@^2.0.3: - version "2.0.6" - resolved "https://registry.yarnpkg.com/http-proxy-middleware/-/http-proxy-middleware-2.0.6.tgz#e1a4dd6979572c7ab5a4e4b55095d1f32a74963f" - integrity sha512-ya/UeJ6HVBYxrgYotAZo1KvPWlgB48kUJLDePFeneHsVujFaW5WNj2NgWCAE//B1Dl02BIfYlpNgBy8Kf8Rjmw== + version "2.0.7" + resolved "https://registry.yarnpkg.com/http-proxy-middleware/-/http-proxy-middleware-2.0.7.tgz#915f236d92ae98ef48278a95dedf17e991936ec6" + integrity sha512-fgVY8AV7qU7z/MmXJ/rxwbrtQH4jBQ9m7kp3llF0liB7glmFeVZFBepQb32T3y8n8k2+AEYuMPCpinYW+/CuRA== dependencies: "@types/http-proxy" "^1.17.8" http-proxy "^1.18.1" From 3cd76bd1ec83f37a366454820f6182c8fafb6184 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Oct 2024 10:37:53 +0000 Subject: [PATCH 10/13] chore(deps): Bump markdown-to-jsx from 7.3.2 to 7.5.0 (#2725) Bumps [markdown-to-jsx](https://github.com/quantizor/markdown-to-jsx) from 7.3.2 to 7.5.0. - [Release notes](https://github.com/quantizor/markdown-to-jsx/releases) - [Changelog](https://github.com/quantizor/markdown-to-jsx/blob/main/CHANGELOG.md) - [Commits](https://github.com/quantizor/markdown-to-jsx/compare/v7.3.2...v7.5.0) --- updated-dependencies: - dependency-name: markdown-to-jsx dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index e9c0c3b20..9672b0d80 100644 --- a/yarn.lock +++ b/yarn.lock @@ -16692,9 +16692,9 @@ markdown-table@^2.0.0: repeat-string "^1.0.0" markdown-to-jsx@^7.1.8: - version "7.3.2" - resolved "https://registry.yarnpkg.com/markdown-to-jsx/-/markdown-to-jsx-7.3.2.tgz#f286b4d112dad3028acc1e77dfe1f653b347e131" - integrity sha512-B+28F5ucp83aQm+OxNrPkS8z0tMKaeHiy0lHJs3LqCyDQFtWuenaIrkaVTgAm1pf1AU85LXltva86hlaT17i8Q== + version "7.5.0" + resolved "https://registry.yarnpkg.com/markdown-to-jsx/-/markdown-to-jsx-7.5.0.tgz#42ece0c71e842560a7d8bd9f81e7a34515c72150" + integrity sha512-RrBNcMHiFPcz/iqIj0n3wclzHXjwS7mzjBNWecKKVhNTIxQepIix6Il/wZCn2Cg5Y1ow2Qi84+eJrryFRWBEWw== marked-terminal@^6.0.0: version "6.3.0" From 04fc515f2cd34ea33f31c4d70012869585b6ebdf Mon Sep 17 00:00:00 2001 From: SB-venkatyadavilli <165135356+SB-venkatyadavilli@users.noreply.github.com> Date: Mon, 28 Oct 2024 16:27:54 +0530 Subject: [PATCH 11/13] Previous fix works for Chrome but not for Safari. (#2729) * fix: copy paste URL * bump: elements versions bump up --- packages/elements-core/package.json | 2 +- .../components/Docs/HttpOperation/HttpOperation.tsx | 10 +++++----- packages/elements-dev-portal/package.json | 4 ++-- packages/elements/package.json | 4 ++-- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/packages/elements-core/package.json b/packages/elements-core/package.json index 3648d9328..0aac75aef 100644 --- a/packages/elements-core/package.json +++ b/packages/elements-core/package.json @@ -1,6 +1,6 @@ { "name": "@stoplight/elements-core", - "version": "8.4.6", + "version": "8.4.7", "sideEffects": [ "web-components.min.js", "src/web-components/**", diff --git a/packages/elements-core/src/components/Docs/HttpOperation/HttpOperation.tsx b/packages/elements-core/src/components/Docs/HttpOperation/HttpOperation.tsx index efa0c24b8..ee6a1f996 100644 --- a/packages/elements-core/src/components/Docs/HttpOperation/HttpOperation.tsx +++ b/packages/elements-core/src/components/Docs/HttpOperation/HttpOperation.tsx @@ -155,13 +155,13 @@ function MethodPathInner({ method, path, chosenServerUrl }: MethodPathProps & { const pathElem = ( - - + + {chosenServerUrl} - - - {path} + + {path} + ); diff --git a/packages/elements-dev-portal/package.json b/packages/elements-dev-portal/package.json index 1d10577b9..be450bc79 100644 --- a/packages/elements-dev-portal/package.json +++ b/packages/elements-dev-portal/package.json @@ -1,6 +1,6 @@ { "name": "@stoplight/elements-dev-portal", - "version": "2.4.7", + "version": "2.4.8", "description": "UI components for composing beautiful developer documentation.", "keywords": [], "sideEffects": [ @@ -66,7 +66,7 @@ "dependencies": { "@stoplight/markdown-viewer": "^5.7.1", "@stoplight/mosaic": "^1.53.4", - "@stoplight/elements-core": "^8.4.6", + "@stoplight/elements-core": "^8.4.7", "@stoplight/path": "^1.3.2", "@stoplight/types": "^14.0.0", "classnames": "^2.2.6", diff --git a/packages/elements/package.json b/packages/elements/package.json index 3a45c853e..a1c82140d 100644 --- a/packages/elements/package.json +++ b/packages/elements/package.json @@ -1,6 +1,6 @@ { "name": "@stoplight/elements", - "version": "8.4.6", + "version": "8.4.7", "description": "UI components for composing beautiful developer documentation.", "keywords": [], "sideEffects": [ @@ -63,7 +63,7 @@ ] }, "dependencies": { - "@stoplight/elements-core": "^8.4.6", + "@stoplight/elements-core": "^8.4.7", "@stoplight/http-spec": "^7.1.0", "@stoplight/json": "^3.18.1", "@stoplight/mosaic": "^1.53.4", From d6358d2983e6ae930eaebe1f9fe70de1409386f7 Mon Sep 17 00:00:00 2001 From: Omar Ilias EL MIMOUNI Date: Tue, 5 Nov 2024 05:00:50 -0500 Subject: [PATCH 12/13] Fix license URL vs identifier precedence issue in AdditionalInfo component (#2724) * Fix AdditionalInfo component to prioritize license URL over identifier * Update AdditionalInfo stories to reflect license URL vs identifier logic * Add unit tests for license URL precedence in AdditionalInfo component * Fix linting errors in AdditionalInfo and HttpService.spec files --------- Co-authored-by: Nauman --- .../HttpService/AdditionalInfo.stories.ts | 15 +++++---- .../Docs/HttpService/AdditionalInfo.tsx | 13 ++++++-- .../Docs/HttpService/HttpService.spec.tsx | 33 +++++++++++++++++++ 3 files changed, 53 insertions(+), 8 deletions(-) diff --git a/packages/elements-core/src/components/Docs/HttpService/AdditionalInfo.stories.ts b/packages/elements-core/src/components/Docs/HttpService/AdditionalInfo.stories.ts index 4cf7568ed..edea89fb7 100644 --- a/packages/elements-core/src/components/Docs/HttpService/AdditionalInfo.stories.ts +++ b/packages/elements-core/src/components/Docs/HttpService/AdditionalInfo.stories.ts @@ -10,8 +10,9 @@ const meta: Meta = { export default meta; type Story = StoryObj; -export const LicenseNameAndURL: Story = { - name: 'License Name with URL', +// Story when only the license URL is provided +export const LicenseWithOnlyURL: Story = { + name: 'License with only URL', args: { id: 'id', license: { @@ -21,8 +22,9 @@ export const LicenseNameAndURL: Story = { }, }; -export const LicenseNameAndIdentifier: Story = { - name: 'License Name and Identifier', +// Story when only the license identifier is provided +export const LicenseWithOnlyIdentifier: Story = { + name: 'License with only Identifier', args: { id: 'id', license: { @@ -32,8 +34,9 @@ export const LicenseNameAndIdentifier: Story = { }, }; -export const LicenseIdentifierAndNameAndUrl: Story = { - name: 'License Identifier, Name and URL', +// Story when both the license URL and identifier are provided (URL should take precedence) +export const LicenseWithURLAndIdentifier: Story = { + name: 'License with URL and Identifier (URL takes precedence)', args: { id: 'id', license: { diff --git a/packages/elements-core/src/components/Docs/HttpService/AdditionalInfo.tsx b/packages/elements-core/src/components/Docs/HttpService/AdditionalInfo.tsx index 882736dcf..22045de9e 100644 --- a/packages/elements-core/src/components/Docs/HttpService/AdditionalInfo.tsx +++ b/packages/elements-core/src/components/Docs/HttpService/AdditionalInfo.tsx @@ -24,8 +24,17 @@ export const AdditionalInfo: React.FC = ({ id, termsOfServi : ''; //use spdx to look up url for license identifier if available - const licenseUrl = - license?.url || license?.identifier ? `https://spdx.org/licenses/${license?.identifier}.html` : undefined; + // The licenseUrl is determined based on the mutual exclusivity of the `url` and `identifier` fields. + // If a `license.url` is provided, it takes precedence over the `license.identifier`. + // This is because the OpenAPI specification defines `url` and `identifier` as mutually exclusive fields, + // meaning you should use either one or the other, but not both. If both are provided, the `url` should be used. + // See: https://spec.openapis.org/oas/latest.html#license-object + const licenseUrl = license?.url + ? license?.url + : license?.identifier + ? `https://spdx.org/licenses/${license?.identifier}.html` + : undefined; + const licenseLink = license?.name && licenseUrl ? `[${license.name}](${licenseUrl})` diff --git a/packages/elements-core/src/components/Docs/HttpService/HttpService.spec.tsx b/packages/elements-core/src/components/Docs/HttpService/HttpService.spec.tsx index 747532853..ae6c8cd78 100644 --- a/packages/elements-core/src/components/Docs/HttpService/HttpService.spec.tsx +++ b/packages/elements-core/src/components/Docs/HttpService/HttpService.spec.tsx @@ -267,6 +267,39 @@ describe('HttpService', () => { expect(title).toBeInTheDocument(); }); + it('should render additional information with SPDX license identifier', () => { + const contact = { + name: 'Developer', + email: 'developer@stoplight.io', + url: 'https://stoplight.io/contact-us/', + }; + + const license = { + name: 'MIT License', + identifier: 'MIT', + }; + + render( + , + ); + + const licenseLink = screen.getByText('MIT License'); + expect(licenseLink).toHaveAttribute('href', 'https://spdx.org/licenses/MIT.html'); + }); + + it('should prefer license URL over SPDX identifier if both are provided', () => { + const license = { + name: 'MIT License', + url: 'https://opensource.org/licenses/MIT', + identifier: 'MIT', + }; + + render(); + + const licenseLink = screen.getByText('MIT License'); + expect(licenseLink).toHaveAttribute('href', 'https://opensource.org/licenses/MIT'); + }); + it('should not render if contact, license, and terms of service do not exist', () => { render(); From c4fc26383fc6811adc8e8dc8726c895a5f924069 Mon Sep 17 00:00:00 2001 From: Mariano Cano Date: Tue, 5 Nov 2024 04:04:19 -0800 Subject: [PATCH 13/13] feat: add object with deepObject style in query parameters (#2631) This commit adds support for using objects with the deepObject style in the TryIt component. A parameter `id` with the value `{"role": "admin", "firstName": "Alex"}` will create the query parameters `id[role]=admin&id[firstName]=Alex`. Co-authored-by: Nauman --- .../operations/operation-parameters.ts | 8 +++++ .../src/__fixtures__/operations/put-todos.ts | 8 +++++ .../src/components/TryIt/TryIt.spec.tsx | 6 ++++ .../components/TryIt/build-request.spec.ts | 5 +++- .../src/components/TryIt/build-request.ts | 29 +++++++++++++------ 5 files changed, 46 insertions(+), 10 deletions(-) diff --git a/packages/elements-core/src/__fixtures__/operations/operation-parameters.ts b/packages/elements-core/src/__fixtures__/operations/operation-parameters.ts index 672a5f2ef..144b03d59 100644 --- a/packages/elements-core/src/__fixtures__/operations/operation-parameters.ts +++ b/packages/elements-core/src/__fixtures__/operations/operation-parameters.ts @@ -207,6 +207,14 @@ export const httpOperation: IHttpOperation = { style: HttpParamStyles.Form, explode: false, }, + { + schema: { + type: 'object', + }, + name: 'deep_object', + style: HttpParamStyles.DeepObject, + explode: true, + }, { schema: { type: 'boolean', diff --git a/packages/elements-core/src/__fixtures__/operations/put-todos.ts b/packages/elements-core/src/__fixtures__/operations/put-todos.ts index 176ce51ff..d5ebc272c 100644 --- a/packages/elements-core/src/__fixtures__/operations/put-todos.ts +++ b/packages/elements-core/src/__fixtures__/operations/put-todos.ts @@ -411,6 +411,14 @@ export const httpOperation: IHttpOperation = { name: 'pairs', style: HttpParamStyles.Form, }, + { + id: '?http-query-pagination?', + schema: { + type: 'object', + }, + name: 'pagination', + style: HttpParamStyles.DeepObject, + }, { id: '?http-query-items?', schema: { diff --git a/packages/elements-core/src/components/TryIt/TryIt.spec.tsx b/packages/elements-core/src/components/TryIt/TryIt.spec.tsx index 6f1ee8c30..162d8cc64 100644 --- a/packages/elements-core/src/components/TryIt/TryIt.spec.tsx +++ b/packages/elements-core/src/components/TryIt/TryIt.spec.tsx @@ -204,6 +204,7 @@ describe('TryIt', () => { 'limit*', 'super_duper_long_parameter_name_with_unnecessary_text*', 'completed', + 'deep_object', 'default_style_items', 'items', 'items_not_exploded', @@ -283,6 +284,9 @@ describe('TryIt', () => { const pairsField = screen.getByLabelText('pairs'); userEvent.type(pairsField, '{ "nestedKey": "nestedValue" }'); + const pagination = screen.getByLabelText('pagination'); + userEvent.type(pagination, '{ "first": 50, "after": "cursor" }'); + const itemsField = screen.getByLabelText('items'); userEvent.type(itemsField, '["first", "second"]'); @@ -312,6 +316,8 @@ describe('TryIt', () => { expect(queryParams.get('optional_value_with_default')).toBeNull(); expect(queryParams.get('nestedKey')).toBe('nestedValue'); expect(queryParams.get('pairs')).toBeNull(); + expect(queryParams.get('pagination[first]')).toBe('50'); + expect(queryParams.get('pagination[after]')).toBe('cursor'); expect(queryParams.getAll('items')).toEqual(['first', 'second']); // assert that headers are passed const headers = new Headers(fetchMock.mock.calls[0][1]!.headers); diff --git a/packages/elements-core/src/components/TryIt/build-request.spec.ts b/packages/elements-core/src/components/TryIt/build-request.spec.ts index 366ee6d9f..d8a52ee26 100644 --- a/packages/elements-core/src/components/TryIt/build-request.spec.ts +++ b/packages/elements-core/src/components/TryIt/build-request.spec.ts @@ -36,7 +36,7 @@ describe('Build Request', () => { }).toThrowError('JSON array expected'); }); - it('Supports form style', () => { + it('Supports form and deepObject style', () => { const params = getQueryParams({ httpOperation, parameterValues: { @@ -46,6 +46,7 @@ describe('Build Request', () => { default_style_items: '["first","second"]', nested: '{"key":"value"}', nested_not_exploded: '{"key":"value"}', + deep_object: '{"key":"value", "number": 2}', }, }); @@ -58,6 +59,8 @@ describe('Build Request', () => { { name: 'default_style_items', value: 'second' }, { name: 'key', value: 'value' }, { name: 'nested_not_exploded', value: 'key,value' }, + { name: 'deep_object[key]', value: 'value' }, + { name: 'deep_object[number]', value: '2' }, ]); }); diff --git a/packages/elements-core/src/components/TryIt/build-request.ts b/packages/elements-core/src/components/TryIt/build-request.ts index 19c45aad5..0c1f9ea37 100644 --- a/packages/elements-core/src/components/TryIt/build-request.ts +++ b/packages/elements-core/src/components/TryIt/build-request.ts @@ -71,7 +71,7 @@ export const getQueryParams = ({ const explode = param.explode ?? true; - if (param.schema?.type === 'object' && param.style === 'form' && value) { + if (param.schema?.type === 'object' && value) { let nested: Dictionary; try { nested = JSON.parse(value); @@ -80,15 +80,26 @@ export const getQueryParams = ({ throw new Error(`Cannot use param value "${value}". JSON object expected.`); } - if (explode) { - acc.push(...Object.entries(nested).map(([name, value]) => ({ name, value: value.toString() }))); + if (param.style === 'form') { + if (explode) { + acc.push(...Object.entries(nested).map(([name, value]) => ({ name, value: value.toString() }))); + } else { + acc.push({ + name: param.name, + value: Object.entries(nested) + .map(entry => entry.join(',')) + .join(','), + }); + } + } else if (param.style === 'deepObject') { + acc.push( + ...Object.entries(nested).map(([name, value]) => ({ + name: `${param.name}[${name}]`, + value: value.toString(), + })), + ); } else { - acc.push({ - name: param.name, - value: Object.entries(nested) - .map(entry => entry.join(',')) - .join(','), - }); + acc.push({ name: param.name, value }); } } else if (param.schema?.type === 'array' && value) { let nested: string[];