1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-02-14 00:19:16 +01:00
unleash.unleash/frontend
renovate[bot] 6602e664a1
chore(deps): update testing-library monorepo (#9247)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
|
[@testing-library/react](https://redirect.github.com/testing-library/react-testing-library)
| [`16.1.0` ->
`16.2.0`](https://renovatebot.com/diffs/npm/@testing-library%2freact/16.1.0/16.2.0)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@testing-library%2freact/16.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@testing-library%2freact/16.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@testing-library%2freact/16.1.0/16.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@testing-library%2freact/16.1.0/16.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
|
[@testing-library/user-event](https://redirect.github.com/testing-library/user-event)
| [`14.5.2` ->
`14.6.1`](https://renovatebot.com/diffs/npm/@testing-library%2fuser-event/14.5.2/14.6.1)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@testing-library%2fuser-event/14.6.1?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@testing-library%2fuser-event/14.6.1?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@testing-library%2fuser-event/14.5.2/14.6.1?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@testing-library%2fuser-event/14.5.2/14.6.1?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

<details>
<summary>testing-library/react-testing-library
(@&#8203;testing-library/react)</summary>

###
[`v16.2.0`](https://redirect.github.com/testing-library/react-testing-library/releases/tag/v16.2.0)

[Compare
Source](https://redirect.github.com/testing-library/react-testing-library/compare/v16.1.0...v16.2.0)

##### Features

- Add support for React error handlers
([#&#8203;1354](https://redirect.github.com/testing-library/react-testing-library/issues/1354))
([9618c51](9618c51337))

</details>

<details>
<summary>testing-library/user-event
(@&#8203;testing-library/user-event)</summary>

###
[`v14.6.1`](https://redirect.github.com/testing-library/user-event/releases/tag/v14.6.1)

[Compare
Source](https://redirect.github.com/testing-library/user-event/compare/v14.6.0...v14.6.1)

##### Bug Fixes

- correct description for `delay` option
([#&#8203;1175](https://redirect.github.com/testing-library/user-event/issues/1175))
([2edf14d](2edf14d2e7))
- **keyboard:** add `ContextMenu` to `defaultKeyMap`
([#&#8203;1079](https://redirect.github.com/testing-library/user-event/issues/1079))
([3e471d1](3e471d1feb))
- **keyboard:** add brackets to `defaultKeyMap`
([#&#8203;1226](https://redirect.github.com/testing-library/user-event/issues/1226))
([543ecb0](543ecb0ea9))
- **keyboard:** walk through radio group per arrow keys
([#&#8203;1049](https://redirect.github.com/testing-library/user-event/issues/1049))
([bf8111c](bf8111ca9f))
- **pointer:** dispatch mouse events if `pointerdown` is
`defaultPrevented`
([#&#8203;1121](https://redirect.github.com/testing-library/user-event/issues/1121))
([f681f7b](f681f7bbfe))
- **pointer:** set `button` and `buttons` properties on `PointerEvent`
([#&#8203;1219](https://redirect.github.com/testing-library/user-event/issues/1219))
([6614f72](6614f7282c))
- **pointer:** use `1` as default value for `PointerEvent.width` and
`PointerEvent.height`
([#&#8203;1224](https://redirect.github.com/testing-library/user-event/issues/1224))
([f0468d0](f0468d04d7))
- prevent `click` event loop on form-associated custom element
([#&#8203;1238](https://redirect.github.com/testing-library/user-event/issues/1238))
([465fc7e](465fc7eb49))
- prevent `click` event on non-focusable control
([#&#8203;1130](https://redirect.github.com/testing-library/user-event/issues/1130))
([e429094](e429094865))
- **upload:** apply `accept` filter more leniently
([#&#8203;1064](https://redirect.github.com/testing-library/user-event/issues/1064))
([a344ad4](a344ad4dfe))

###
[`v14.6.0`](https://redirect.github.com/testing-library/user-event/releases/tag/v14.6.0)

[Compare
Source](https://redirect.github.com/testing-library/user-event/compare/v14.5.2...v14.6.0)

##### Features

- dispatch `FocusEvent` in hidden documents
([#&#8203;1252](https://redirect.github.com/testing-library/user-event/issues/1252))
([1ed8b15](1ed8b1557b))

##### Bug Fixes

- **clipboard:** await `DataTransferItem.getAsString()` callback
([#&#8203;1251](https://redirect.github.com/testing-library/user-event/issues/1251))
([7b11b0e](7b11b0e88a))
- **event:** assign pointer coords to MouseEvent
([#&#8203;1039](https://redirect.github.com/testing-library/user-event/issues/1039))
([8528972](8528972577))
- **pointer:** check `PointerCoords.x` in `isDifferentPointerPosition`
([#&#8203;1216](https://redirect.github.com/testing-library/user-event/issues/1216))
([75edef5](75edef5c06))
- **pointer:** check all fields of `PointerCoords` in
`isDifferentPointerPosition()`
([#&#8203;1229](https://redirect.github.com/testing-library/user-event/issues/1229))
([5f3d28f](5f3d28fe3a))

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "after 7pm every weekday,before 5am
every weekday" in timezone Europe/Madrid, Automerge - At any time (no
schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Whenever PR is behind base branch, or you tick the
rebase/retry checkbox.

👻 **Immortal**: This PR will be recreated if closed unmerged. Get
[config
help](https://redirect.github.com/renovatebot/renovate/discussions) if
that's undesired.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/).
View the [repository job
log](https://developer.mend.io/github/Unleash/unleash).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4xNDUuMCIsInVwZGF0ZWRJblZlciI6IjM5LjE0NS4wIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJkZXBlbmRlbmNpZXMiXX0=-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-02-06 18:46:58 +00:00
..
.yarn/releases
cypress
public
scripts
src chore: remove sortProjectRoles flag (#9226) 2025-02-06 19:40:10 +01:00
.editorconfig
.gitignore
.npmignore
.nvmrc
.yarnrc.yml
check-imports.rc
cypress.config.ts
cypress.d.ts
index.html
index.js
orval.config.js
package.json chore(deps): update testing-library monorepo (#9247) 2025-02-06 18:46:58 +00:00
README.md
tsconfig.json
tsconfig.node.json
vercel.json
vite.config.mts
yarn.lock chore(deps): update testing-library monorepo (#9247) 2025-02-06 18:46:58 +00:00

frontend

This directory contains the Unleash Admin UI frontend app.

Run with a local instance of the unleash-api

Refer to the Contributing to Unleash guide for instructions. The frontend dev server runs (in port 3000) simultaneously with the backend dev server (in port 4242):

yarn install
yarn dev

Run with a sandbox instance of the Unleash API

Alternatively, instead of running unleash-api on localhost, you can use a remote instance:

cd ./frontend
yarn install
yarn run start:sandbox

Running end-to-end tests

We have a set of Cypress tests that run on the build before a PR can be merged so it's important that you check these yourself before submitting a PR. On the server the tests will run against the deployed Heroku app so this is what you probably want to test against:

yarn run start:sandbox

In a different shell, you can run the tests themselves:

yarn run e2e:heroku

If you need to test against patches against a local server instance, you'll need to run that, and then run the end to end tests using:

yarn run e2e

You may also need to test that a feature works against the enterprise version of unleash. Assuming the Heroku instance is still running, this can be done by:

yarn run start:enterprise
yarn run e2e

Generating the OpenAPI client

The frontend uses an OpenAPI client generated from the backend's OpenAPI spec. Whenever there are changes to the backend API, the client should be regenerated:

For now we only use generated types (src/openapi/models). We will use methods (src/openapi/apis) for new features soon.

yarn gen:api
rm -rf src/openapi/apis

clean up src/openapi/index.ts imports, only keep first line export * from './models';

This script assumes that you have a running instance of the enterprise backend at http://localhost:4242. The new OpenAPI client will be generated from the runtime schema of this instance. The target URL can be changed by setting the UNLEASH_OPENAPI_URL env var.

Analyzing bundle size

npx vite-bundle-visualizer in the root of the frontend directory