1
0
mirror of https://github.com/Unleash/unleash.git synced 2024-12-22 19:07:54 +01:00
Commit Graph

2241 Commits

Author SHA1 Message Date
Tymoteusz Czech
257013c56a
fix: integration multiselector (#4683)
Input should use state set outside and derive "all selected" from it.
This was not the case causing issues when loading a form with "wildcard"
pre-selected.
2023-09-14 14:01:40 +02:00
Tymoteusz Czech
e8d5f0cf56
fix: integrations text review (#4706)
## About the changes
Update copy

Co-authored-by: Thomas Heartman <thomas@getunleash.ai>
2023-09-14 12:01:29 +00:00
Mateusz Kwasniewski
878780f068
feat: playground custom properties are nested (#4686) 2023-09-14 12:28:28 +02:00
Tymoteusz Czech
66c790fbf1
fix: Integrations quality updates (#4677)
Fix issues uncovered when reviewing integrations list and form.

- YouTube CSP
- Text content and formatting
- Margins
- Update old integration icons
- Fix headers in dark theme
2023-09-14 10:17:33 +02:00
Thomas Heartman
9bdee12ad9
feat: stop regexes with whitespace (#4681)
This PR stops regexes with whitespace from being added as feature naming
patterns.
2023-09-14 07:56:23 +00:00
Thomas Heartman
ab4c1e0193
feat: add feature naming pattern tracking (#4678)
This PR adds plausible metrics for feature naming patterns. The changes
are tracked whenever the form is submitted and the naming pattern has
changed. We track three different actions:
- added :: if there was no pattern before and now there is one
- removed :: if there was a pattern before and now there is none
- changed :: if there was a pattern before and now there is a different
one

The corresponding event type has been created in plausible.
2023-09-14 09:32:15 +02:00
Thomas Heartman
7eb00758e0
refactor: simplify flag naming tooltip (#4685)
This PR simplifies the flag naming tooltip considerably. It now only
contains an example of a pattern and what it will match. It also updates
the link in the form section description to point directly to a regex
cheat sheet instead of a general regex reference document.

There's a few reasons for doing this:
1. The text preceding the input already explains what the pattern does
and explains that it is a regex.
2. The text preceding the input also contains a link to a regex cheat
sheet (which is arguably a better place to explain regexes than a
tooltip).
3. The tooltip was very long. While a lot of the information there was
useful, it would also be hard to use. Imagine a user checking the
tooltip, scrolling all the way down, but accidentally moving the mouse a
bit and the tooltip disappearing. They would have to scroll all the way
down again. Or maybe they need to remember what it was they just looked
at. It would be more useful to have the information on a separate page.
4. The tooltip is not accessible by keyboard. This means that users who
use a keyboard to navigate the UI would not be able to scroll or
otherwise navigate the tooltip, potentially leaving them in the dark.


![image](https://github.com/Unleash/unleash/assets/17786332/88a74ad9-181a-44ba-9eb9-4818c081442f)
2023-09-14 08:09:01 +02:00
Fredrik Strand Oseberg
78273e4ff3
chore: dora cleanup (#4676)
This PR adds: 
* Generated types for useProjectDoraMetrics
* Mobile enhancements
* Tooltips

---------

Co-authored-by: Thomas Heartman <thomas@getunleash.ai>
2023-09-13 15:50:42 +02:00
andreas-unleash
8b452084f3
fix: validation for variant payload number type (#4671)
Adds validation to number type for variants

---------

Signed-off-by: andreas-unleash <andreas@getunleash.ai>
2023-09-13 10:23:39 +03:00
Nuno Góis
4de8ea2553
fix: post global events even when filtering by env (#4672)
https://linear.app/unleash/issue/2-1276/deal-with-events-without-an-environment

This makes it so that global events (events not tied to a specific
environment) are always received, no matter the configured environment
filter.

It also includes a respective test and small sentence on the UI
explaining the behavior.


![image](https://github.com/Unleash/unleash/assets/14320932/021a3622-78fe-45af-b68c-dde0813f32f0)
2023-09-13 08:22:18 +01:00
Thomas Heartman
43878230b7
UI: make project settings / creation form full-width (#4675)
This PR makes the project settings / creation forms grow to take up the
full available width, so that it is in line with the new designs.
2023-09-13 06:38:18 +00:00
Thomas Heartman
f49cc8cd33
feat: update UI to add hints about implicit ^ and $ (#4667)
This PR updates the UI to reflect the changes to the implicit ^ and $
that we now add. The changes are:

1. Show input adornments for ^ and $ when you create a pattern.
2. Mention that ^ and $ are added implicitly in description.
3. Checks the example you provide against the pattern with added ^ and $
+ adds a test for that.

Points 1 and 2:

![image](https://github.com/Unleash/unleash/assets/17786332/88c610b4-444b-4a83-a50a-4b7639614a86)


## Discussion point:

I have not touched the information about the pattern yet as the PR that
updates that is still in review (#4656), but it would be prudent to also
update that info to make it clearer. I can address that in a follow-up
PR.
2023-09-13 06:22:55 +00:00
Thomas Heartman
03d6ed0c32
ui: update design for feature naming pattern info (#4656)
This PR updates the design for the feature naming pattern info. In doing
so, I've extracted the information into a single component.

It also, on @nicolaesocaciu's behest, makes the new toggle form inputs
wider when they have room to grow.

Light mode:

![image](https://github.com/Unleash/unleash/assets/17786332/0923cf95-18e3-4524-8402-7f42a0ac94ec)


Dark mode:

![image](https://github.com/Unleash/unleash/assets/17786332/c2a07f73-8973-42d0-b94a-d7dc4ec38a25)

For copying features it looks like this:


![image](https://github.com/Unleash/unleash/assets/17786332/2a39f17b-4d86-408c-8f3b-5f2b24e82c81)
2023-09-13 08:05:58 +02:00
Tymoteusz Czech
ed6547b6f1
fix: integrations UI (#4670)
## About the changes
UI adjustments - text, spacing

Co-authored-by: NicolaeUnleash <103567375+NicolaeUnleash@users.noreply.github.com>
2023-09-12 15:45:51 +03:00
Tymoteusz Czech
dbaa386697
feat: Edge integration page (#4657)
## About the changes

![image](https://github.com/Unleash/unleash/assets/2625371/6f4dcf7f-c3cf-45a2-9525-2965c31b6d89)
2023-09-12 14:25:38 +02:00
Jaanus Sellin
980461ef18
feat: hide project settings for OSS (#4662) 2023-09-12 09:39:55 +03:00
andreas-unleash
1cd0edb11a
feat: variant with number payload (#4654)
Adds `number` as possible payload type for variant.
Adds a flag to enable the feature
Updates all relevant models and schemas
Adds the option to the UI

Closes: #
[1-1357](https://linear.app/unleash/issue/1-1357/support-number-in-variant-payload)

---------

Signed-off-by: andreas-unleash <andreas@getunleash.ai>
2023-09-11 16:57:42 +03:00
Tymoteusz Czech
f88e15c45c
Fix: integrations form (#4655)
## About the changes
Fix submitting integrations form
2023-09-11 12:26:40 +00:00
Mateusz Kwasniewski
ba73d9a0d1
feat: keyboard navigation in search (#4651) 2023-09-11 12:53:31 +02:00
Jaanus Sellin
77fbac01e4
feat: remove newApplicationsList feature flag (#4653) 2023-09-11 12:28:43 +02:00
Tymoteusz Czech
a9ac81a089
feat: useUiFlag shorthand hook (#4566)
## About the changes
Instead of this:
```ts
const { uiConfig } = useUiConfig();
const myFlag = Boolean(uiConfig?.flags?.myFlag)
```
we can have this:
```ts
const myFlag = useUiFlag("myFlag")
```
With the same type safety, less verbose and more purposeful code.

### Important files
- `frontend/src/hooks/useUiFlag.ts`


## Discussion points
Can we in the future share flags between frontend and backend? Right now
adding a new flag has to be done in 4 different places (backend flag
keys list, backend flags defaults config, backend experimental server
options, frontend type).

Most ergonomic option is to pull config directly from Unleash. 
Issue, based on previous user feedback:
https://github.com/Unleash/unleash/issues/4565
Internal feature request document:
[docs.google.com/document/d/1Sx0q...](https://docs.google.com/document/d/1Sx0qKZXUVUCjuY5F4MOh1ieOM1A2_jE58zEA7jaM_1g/edit?usp=sharing)
2023-09-11 10:01:20 +02:00
Fredrik Strand Oseberg
26ade79d66
Fix/dora polish (#4645)
This PR includes:
* Tests for retrieving lead time per feature toggle and project average
* Feedback component
2023-09-08 14:18:58 +02:00
Jaanus Sellin
0b5a7b7d36
feat: add plausible to integrations (#4647) 2023-09-08 15:01:12 +03:00
Nuno Góis
61174a1d9c
fix: multi project roles UI improvements (#4646)
https://linear.app/unleash/issue/2-1373/small-ui-fixes-and-improvements

- Update group root role `HelpIcon` tooltip to reflect the new behavior;
- Fixes a crash on groups search where `description` could be
`undefined`;
 - Improves `RoleDescription` design;
 - Fixes the role label in `ProjectGroupView`;
 

![image](https://github.com/Unleash/unleash/assets/14320932/f16ebe98-9408-4edd-8e2b-1e56ba2ad5c6)
2023-09-08 11:42:58 +01:00
Tymoteusz Czech
b835efc0ad
feat: edge integrations page (#4639) 2023-09-08 10:49:30 +02:00
Tymoteusz Czech
042e8d097a
feat: link to request integration (#4634)
## About the changes

![image](https://github.com/Unleash/unleash/assets/2625371/5c0852d2-28cf-4272-8892-e36de782ab61)

https://linear.app/unleash/issue/1-1343/request-integration
2023-09-08 11:46:27 +03:00
Tymoteusz Czech
dff0420ca8
feat: proxy and edge integration cards (#4636) 2023-09-08 10:45:37 +02:00
Jaanus Sellin
c59b83b07b
feat: integration urls, ux (#4640) 2023-09-08 10:21:11 +03:00
Jaanus Sellin
cd2eac23ef
feat: official sdks (#4637) 2023-09-07 16:19:52 +03:00
Tymoteusz Czech
e97859af91
Integrations form (#4622)
## About the changes
Redesigned/refactored integrations form.


![image](https://github.com/Unleash/unleash/assets/2625371/9f3ad019-e367-4f89-932d-539d7a370f88)

Closes
[1-1298/resesign-of-integrations-form](https://linear.app/unleash/issue/1-1298/resesign-of-integrations-form)
2023-09-07 10:27:46 +00:00
Tymoteusz Czech
2be77fb55e
feat: integration sections (#4631)
Co-authored-by: sjaanus <sellinjaanus@gmail.com>
2023-09-07 09:20:12 +00:00
Jaanus Sellin
1d414db982
feat: jira plugin page (#4627)
![image](https://github.com/Unleash/unleash/assets/964450/b58d3d27-4939-42b0-bf0d-51a31aa93dde)


![image](https://github.com/Unleash/unleash/assets/964450/acceedc4-9d53-461a-910f-b60dae0d6b6a)
2023-09-07 11:51:50 +03:00
Thomas Heartman
3b754ec7ed
1-1342: show flag naming pattern info when you copy toggles (#4629)
Because you need to match the pattern when copying toggles, it's
important that we show the required information to the user.

This change adds information about the pattern to the page. This isn't
its final design, but it's more important that the information is
there (to avoid user frustration) than that it is pretty.
2023-09-07 10:22:13 +02:00
Nuno Góis
cfbf47d6bd
refactor: clean up no longer used PAT methods (#4621)
This cleans up some PAT-related methods that are no longer used.
2023-09-07 09:48:55 +02:00
Thomas Heartman
90395b974b
1-1315: revalidate feature name whenever the project changes (#4628)
This change makes it so that the flag name is revalidated against the
new
project pattern whenever you change the target project for a flag.

The validation is not run if the name is empty, if there is no
pattern, or if there is no validation method.

This solves the case where you input a name, then change the project,
and where the name isn't valid for the new project. Previously, it
wouldn't revalidate, but now it does.
2023-09-07 09:15:59 +02:00
Mateusz Kwasniewski
15015f78f3
feat: Plausible search (#4625) 2023-09-07 08:21:37 +02:00
Thomas Heartman
31ed96d8f3
1-1320: allow you to update example with no pattern + update state better (#4623)
While having a pattern when you have no example doesn't make a lot of
sense, it's a problem that you can't delete the example after deleting
the pattern: you previously had to remove the example before the
pattern.

This PR fixes that by always allowing you to update the example, even if
there is no pattern. Our server doesn't currently accept submitting an
example with no pattern, but we could allow that if we want to (and
probably just discard it on the back-end).

This PR also updates the validation of the example and the regex. There
were more unhandled edge cases previously where the validation would
disappear or be wrong. This should be fixed now. The new logic is that,
whenever you update the either the pattern or the example, we check:
- if you have an error in your pattern, no pattern, or no example, then
delete the example error if it exists
- have a well-formed pattern and an example then check if the example
matches the pattern and add/delete an error accordingly

This does have some consequences: editing the pattern can render your
example invalid. You'll also get immediate feedback instead of when you
switch focus. I think this is often a bad pattern (giving the user too
much negative feedback), but in terms of working with regexes, I think
it might be a good thing. We also give immediate feedback today, so I
don't think this is a regression.

Any thoughts are welcome.
2023-09-07 08:18:18 +02:00
Mateusz Kwasniewski
a0fbad26bf
feat: persistent search queries (#4624) 2023-09-06 15:46:10 +02:00
Nuno Góis
af9756e1e1
fix: prevent 404 on auth settings hook (#4619)
Since `auth/{auth_type}/settings` is an Enterprise route, this prevents
404s when we try to use the hook to fetch auth settings in
non-Enterprise instances by using the conditional `useEnterpriseSWR`
hook.
2023-09-06 13:35:02 +01:00
Thomas Heartman
34d595b5a6
refactor: use conditionally render instead of && (#4620)
For consistency and readability.
2023-09-06 11:51:04 +00:00
Mateusz Kwasniewski
caff040a88
feat: Clickable search filter options (#4618) 2023-09-06 12:50:42 +02:00
Thomas Heartman
1ffa0b86d9
1-1307: Show info about flag naming patterns before making mistakes (#4616)
This PR adds info about a project's flag naming pattern to the flag
creation form. This way, it's displayed before the user tries to create
a flag, so that they have all the necessary information before making
mistakes.


![image](https://github.com/Unleash/unleash/assets/17786332/7a3fb036-5315-4c2b-934d-004da6b364a3)
2023-09-06 12:14:17 +02:00
Mateusz Kwasniewski
2b85eed5b5
feat: Search UI improvements (#4613) 2023-09-06 10:50:20 +02:00
Thomas Heartman
73b7cc0b5a
1-1319: add feature naming pattern descriptions (#4612)
This PR adds a feature naming pattern description to the project form.
It's rendered as a multi-line input field. The description is also
stored in the db.

This adapts most of @andreas-unleash's PR #4599 with some minor changes
(using description instead of prompt). Actually displaying this data to
the users will come in a later PR.


![image](https://github.com/Unleash/unleash/assets/17786332/b96d2dbb-2b90-4adf-bc83-cdc534c507ea)
2023-09-06 08:13:28 +00:00
Nuno Góis
c3216ac941
fix: group roles assumption, refactor group types (#4576)
Does what it says on the tin, should help with cleaning up
https://github.com/Unleash/unleash/pull/4512 and respective schema
changes.

---------

Co-authored-by: Gastón Fournier <gaston@getunleash.io>
2023-09-05 20:30:20 +01:00
Mateusz Kwasniewski
41858a4952
feat: Search suggestion selectable (#4610) 2023-09-05 15:31:31 +02:00
Tymoteusz Czech
47a59224bb
Integration card component (#4557)
![image](https://github.com/Unleash/unleash/assets/2625371/42364fdb-1ff1-48c4-9756-a145a39e45b9)


## About the changes
<!-- Describe the changes introduced. What are they and why are they
being introduced? Feel free to also add screenshots or steps to view the
changes if they're visual. -->

<!-- Does it close an issue? Multiple? -->
Closes #

<!-- (For internal contributors): Does it relate to an issue on public
roadmap? -->
<!--
Relates to [roadmap](https://github.com/orgs/Unleash/projects/10) item:
#
-->

### Important files
<!-- PRs can contain a lot of changes, but not all changes are equally
important. Where should a reviewer start looking to get an overview of
the changes? Are any files particularly important? -->


## Discussion points
<!-- Anything about the PR you'd like to discuss before it gets merged?
Got any questions or doubts? -->
2023-09-05 12:14:03 +00:00
Tymoteusz Czech
c19bd615b9
fix: reset selected toggle after archive or revive (#4606)
<!-- Thanks for creating a PR! To make it easier for reviewers and
everyone else to understand what your changes relate to, please add some
relevant content to the headings below. Feel free to ignore or delete
sections that you don't think are relevant. Thank you! ❤️ -->

## About the changes
When archiving or reviving feature toggles, when toggles disappear from
table, actions bar should also disappear.

<!-- Does it close an issue? Multiple? -->
Closes
https://linear.app/unleash/issue/1-1293/bulk-revive-modal-doesnt-go-away
2023-09-05 11:44:28 +02:00
Thomas Heartman
d5edcc33e6
add descriptions in form (#4608)
This PR adds descriptions of the various feature flag naming input
fields in the project settings form. It also wraps the feature naming
fields in a fieldset to group them semantically.


![image](https://github.com/Unleash/unleash/assets/17786332/a8d5c2c6-3381-4b76-89a1-18316c2e5193)
2023-09-05 09:22:52 +00:00
Jaanus Sellin
53f90d37c5
feat: feature naming patterns (#4591)
Adds a first iteration of feature flag naming patterns. Currently behind a flag.

Signed-off-by: andreas-unleash <andreas@getunleash.ai>
Co-authored-by: Thomas Heartman <thomas@getunleash.io>
Co-authored-by: andreas-unleash <andreas@getunleash.ai>
Co-authored-by: Thomas Heartman <thomas@getunleash.ai>
2023-09-04 11:53:33 +00:00