Christopher Kolstad
53354224fc
chore: Bump biome and configure husky ( #6589 )
...
Upgrades biome to 1.6.1, and updates husky pre-commit hook.
Most changes here are making type imports explicit.
2024-03-18 13:58:05 +01:00
Fredrik Strand Oseberg
f381718fd6
fix: icon imports ( #6499 )
...
Based on this article:
https://mui.com/material-ui/guides/minimizing-bundle-size/ importing
from `'@mui/icons-material'` instead of specifying the actual path to
the icon like `import Delete from '@mui/icons-material/Delete';` can be
up to six time slower. This change changes all named imports in Unleash
referencing the `@mui/icons-material` to default imports.
This reduced the amount of modules we had to process when building the
frontend from 15206 to 4746
Before:
<img width="1016" alt="Skjermbilde 2024-03-11 kl 14 19 58"
src="https://github.com/Unleash/unleash/assets/16081982/f137d24a-6557-4183-a40f-f62a33524520 ">
After:
<img width="1237" alt="Skjermbilde 2024-03-11 kl 14 20 32"
src="https://github.com/Unleash/unleash/assets/16081982/05a27d6a-2c3f-4409-9862-7188ab4b9c72 ">
Build time locally decreased by around 50%
Before:
<img width="1504" alt="Skjermbilde 2024-03-11 kl 14 31 45"
src="https://github.com/Unleash/unleash/assets/16081982/bc931559-b022-47ed-9f8f-c87401578518 ">
After:
<img width="1219" alt="Skjermbilde 2024-03-11 kl 14 27 00"
src="https://github.com/Unleash/unleash/assets/16081982/3c3a8d6b-576d-45c3-aa40-cc5f95d9df2b ">
2024-03-12 10:56:10 +01:00
renovate[bot]
c7498dcac6
chore(deps): update dependency @biomejs/biome to v1.4.0 ( #5288 )
...
[![Mend Renovate logo
banner](https://app.renovatebot.com/images/banner.svg )](https://renovatebot.com )
This PR contains the following updates:
| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [@biomejs/biome](https://biomejs.dev )
([source](https://togithub.com/biomejs/biome )) | [`1.3.3` ->
`1.4.0`](https://renovatebot.com/diffs/npm/@biomejs%2fbiome/1.3.3/1.4.0 )
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@biomejs%2fbiome/1.4.0?slim=true )](https://docs.renovatebot.com/merge-confidence/ )
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@biomejs%2fbiome/1.4.0?slim=true )](https://docs.renovatebot.com/merge-confidence/ )
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@biomejs%2fbiome/1.3.3/1.4.0?slim=true )](https://docs.renovatebot.com/merge-confidence/ )
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@biomejs%2fbiome/1.3.3/1.4.0?slim=true )](https://docs.renovatebot.com/merge-confidence/ )
|
---
### Release Notes
<details>
<summary>biomejs/biome (@​biomejs/biome)</summary>
###
[`v1.4.0`](https://togithub.com/biomejs/biome/blob/HEAD/CHANGELOG.md#140-2023-11-27 )
[Compare
Source](af24597c18...889593e3f9
)
##### CLI
- Remove the CLI options from the `lsp-proxy`, as they were never meant
to be passed to that command. Contributed by
[@​ematipico](https://togithub.com/ematipico )
- Add option `--config-path` to `lsp-proxy` and `start` commands. It's
now possible to tell the Daemon server to load `biome.json` from a
custom path. Contributed by
[@​ematipico](https://togithub.com/ematipico )
- Add new `--diagnostic-level` option to let users control the level of
diagnostics printed by the CLI. Possible values are: `"info"`, `"warn"`,
`"hint"`. Contributed by
[@​simonxabris](https://togithub.com/simonxabris )
- Add option `--line-feed` to the `format` command. Contributed by
[@​SuperchupuDev](https://togithub.com/SuperchupuDev )
- Add option `--bracket-same-line` to the `format` command. Contributed
by [@​faultyserve](https://togithub.com/faultyserve )
- Add option `--bracket-spacing` to the `format` command. Contributed by
[@​faultyserve](https://togithub.com/faultyserve )
##### Bug fixes
- Fix the command `format`, now it returns a non-zero exit code when if
there pending diffs. Contributed by
[@​ematipico](https://togithub.com/ematipico )
##### Configuration
- Add option `formatter.lineFeed`. Contributed by
[@​SuperchupuDev](https://togithub.com/SuperchupuDev )
- Add option `javascript.formatter.bracketSameLine`. Contributed by
[@​faultyserve](https://togithub.com/faultyserve )
- Add option `javascript.formatter.bracketSpacing`. Contributed by
[@​faultyserve](https://togithub.com/faultyserve )
##### Formatter
##### New features
- Add a new option
[`--line-ending`](https://biomejs.dev/reference/configuration/#formatterlineending ).
This option allows changing the type of line endings. Contributed by
[@​SuperchupuDev](https://togithub.com/SuperchupuDev )
- Added a new option called `--bracket-spacing` to the formatter. This
option allows you to control whether spaces are inserted around the
brackets of object literals.
[#​627](https://togithub.com/biomejs/biome/issues/627 ).
Contributed by [@​faultyserver](https://togithub.com/faultyserver )
- Added a new option called `--bracket-same-line` to the formatter. This
option allows you to control whether spaces are inserted around the
brackets of object literals.
[#​627](https://togithub.com/biomejs/biome/issues/627 ).
Contributed by [@​faultyserver](https://togithub.com/faultyserver )
##### Bug fixes
- Fix [#​832](https://togithub.com/biomejs/biome/issues/832 ), the
formatter no longer keeps an unnecessary trailing comma in type
parameter lists. Contributed by
[@​Conaclos](https://togithub.com/Conaclos )
- Fix [#​301](https://togithub.com/biomejs/biome/issues/301 ), the
formatter should not break before the `in` keyword. Contributed by
[@​ematipico](https://togithub.com/ematipico )
##### Linter
##### Promoted rules
-
[a11y/noInteractiveElementToNoninteractiveRole](https://biomejs.dev/linter/rules/no-interactive-element-to-noninteractive-role )
-
[complexity/noThisInStatic](https://biomejs.dev/linter/rules/no-this-in-static )
-
[complexity/useArrowFunction](https://biomejs.dev/linter/rules/use-arrow-function )
-
[correctness/noEmptyCharacterClassInRegex](https://biomejs.dev/linter/rules/no-empty-character-class-in-regex )
-
[correctness/noInvalidNewBuiltin](https://biomejs.dev/linter/rules/no-invalid-new-builtin )
-
[style/noUselessElse](https://biomejs.dev/linter/rules/no-useless-else )
-
[style/useAsConstAssertion](https://biomejs.dev/linter/rules/use-as-const-assertion )
-
[style/useShorthandAssign](https://biomejs.dev/linter/rules/use-shorthand-assign )
-
[suspicious/noApproximativeNumericConstant](https://biomejs.dev/linter/rules/no-approximative-numeric-constant )
-
[suspicious/noMisleadingInstantiator](https://biomejs.dev/linter/rules/no-misleading-instantiator )
-
[suspicious/noMisrefactoredShorthandAssign](https://biomejs.dev/linter/rules/no-misrefactored-shorthand-assign )
The following rules are now recommended:
- [a11y/noAccessKey](https://biomejs.dev/linter/rules/no-access-key )
-
[a11y/useHeadingContent](https://biomejs.dev/linter/rules/use-heading-content )
-
[complexity/useSimpleNumberKeys](https://biomejs.dev/linter/use-simple-number-keys )
The following rules are now deprecated:
-
[correctness/noNewSymbol](https://biomejs.dev/linter/rules/no-new-symbol )
The rule is replaced by
[correctness/noInvalidNewBuiltin](https://biomejs.dev/linter/rules/no-invalid-new-builtin )
##### New features
- Add
[noDefaultExport](https://biomejs.dev/linter/rules/no-default-export )
which disallows `export default`. Contributed by
[@​Conaclos](https://togithub.com/Conaclos )
- Add
[noAriaHiddenOnFocusable](https://biomejs.dev/linter/rules/no-aria-hidden-on-focusable )
which reports hidden and focusable elements. Contributed by
[@​vasucp1207](https://togithub.com/vasucp1207 )
- Add
[noImplicitAnyLet](https://biomejs.dev/linter/rules/no-implicit-any-let )
that reports variables declared with `let` and without initialization
and type annotation. Contributed by
[@​TaKO8Ki](https://togithub.com/TaKO8Ki ) and
[@​b4s36t4](https://togithub.com/b4s36t4 )
- Add [useAwait](https://biomejs.dev/linter/rules/use-await ) that
reports `async` functions that don't use an `await` expression.
- Add
[useValidAriaRole](https://biomejs.dev/linter/rules/use-valid-aria-role ).
Contributed by [@​vasucp1207](https://togithub.com/vasucp1207 )
- Add [useRegexLiterals](https://biomejs.dev/linter/use-regex-literals )
that suggests turning call to the regex constructor into regex literals.
COntributed by [@​Yuiki](https://togithub.com/Yuiki )
##### Enhancements
- Add an unsafe code fix for
[a11y/useAriaActivedescendantWithTabindex](https://biomejs.dev/linter/rules/use-aria-activedescendant-with-tabindex )
##### Bug fixes
- Fix [#​639](https://togithub.com/biomejs/biome/issues/639 ) by
ignoring unused TypeScript's mapped key. Contributed by
[@​Conaclos](https://togithub.com/Conaclos )
- Fix [#​565](https://togithub.com/biomejs/biome/issues/565 ) by
handling several `infer` with the same name in extends clauses of
TypeScript's conditional types. Contributed by
[@​Conaclos](https://togithub.com/Conaclos )
- Fix [#​653](https://togithub.com/biomejs/biome/issues/653 ).
[noUnusedImports](https://biomejs.dev/linter/rules/no-unused-imports )
now correctly removes the entire line where the unused `import` is.
Contributed by [@​Conaclos](https://togithub.com/Conaclos )
- Fix [#​607](https://togithub.com/biomejs/biome/issues/609 )
`useExhaustiveDependencies`, ignore optional chaining, Contributed by
[@​msdlisper](https://togithub.com/msdlisper )
- Fix [#​676](https://togithub.com/biomejs/biome/issues/676 ), by
using the correct node for the `"noreferrer"` when applying the code
action. Contributed by
[@​ematipico](https://togithub.com/ematipico )
- Fix [#​455](https://togithub.com/biomejs/biome/issues/455 ). The
CLI can now print complex emojis to the console correctly.
- Fix [#​727](https://togithub.com/biomejs/biome/issues/727 ).
[noInferrableTypes](https://biomejs.dev/linter/rules/no-inferrable-types )
now correctly keeps type annotations when the initialization expression
is `null`. Contributed by
[@​Conaclos](https://togithub.com/Conaclos )
- Fix [#​784](https://togithub.com/biomejs/biome/issues/784 ),
[noSvgWithoutTitle](https://biomejs.dev/linter/rules/no-svg-without-title )
fixes false-positives to `aria-label` and reports svg's role attribute
is implicit. Contributed by
[@​unvalley](https://togithub.com/unvalley )
- Fix [#​834](https://togithub.com/biomejs/biome/issues/834 ) that
made
[noUselessLoneBlockStatements](https://biomejs.dev/linter/rules/no-useless-lone-block-statements )
reports block statements of switch clauses. Contributed by
[@​vasucp1207](https://togithub.com/vasucp1207 )
- Fix [#​783](https://togithub.com/biomejs/biome/issues/834 ) that
made
[noUselessLoneBlockStatements](https://biomejs.dev/linter/rules/no-useless-lone-block-statements )
reports block statements of `try-catch` structures. Contributed by
[@​hougesen](https://togithub.com/hougesen )
- Fix [#​69](https://togithub.com/biomejs/biome/issues/69 ) that
made
[correctness/noUnnecessaryContinue](https://biomejs.dev/linter/rules/no-unnecessary-continue )
incorrectly reports a `continue` used to break a switch clause.
Contributed by [@​TaKO8Ki](https://togithub.com/TaKO8Ki )
- Fix [#​664](https://togithub.com/biomejs/biome/issues/664 ) by
improving the diagnostic of
[style/useNamingConvention](https://biomejs.dev/linter/use-naming-convention )
when double capital are detected in strict camel case mode. Contributed
by [@​vasucp1207](https://togithub.com/vasucp1207 )
- Fix [#​643](https://togithub.com/biomejs/biome/issues/643 ) that
erroneously parsed the option of
[complexity/useExhaustiveDependencies](https://biomejs.dev/linter/use-naming-convention ).
Contributed by [@​arendjr](https://togithub.com/arendjr )
##### Parser
##### Bug fixes
- Fix [#​846](https://togithub.com/biomejs/biome/issues/846 ) that
erroneously parsed `<const T,>() => {}` as a JSX tag instead of an arrow
function when both TypeScript and JSX are enabled.
##### VSCode
</details>
---
### Configuration
📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).
🚦 **Automerge**: Enabled.
♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.
🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.
---
- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box
---
This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/ ). View
repository job log
[here](https://developer.mend.io/github/Unleash/unleash ).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy40Ni4wIiwidXBkYXRlZEluVmVyIjoiMzcuNTkuOCIsInRhcmdldEJyYW5jaCI6Im1haW4ifQ==-->
---------
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Christopher Kolstad <chriswk@getunleash.io>
2023-11-28 09:32:00 +00:00
Thomas Heartman
be699962b1
chore: remove segments oss splash ( #5359 )
...
This change removes the oss segments splash screen that was introduced
in https://github.com/Unleash/unleash/pull/5053 .
2023-11-17 13:39:43 +00:00
Thomas Heartman
8954277d20
chore(ui): add splash screen for oss segments ( #5053 )
...
This PR adds a splash screen for segments being open-sourced.
It looks like this:
![image](https://github.com/Unleash/unleash/assets/17786332/bf8766e6-b9cc-4f0b-a6d1-f6e89e21d844 )
## About the changes
I've more or less wholesale copied the demo dialog that @nunogois
implemented. I've put it in the `splash` directory for now (because
that's where it seemed most appropriate). The reason for straight
copying it instead of extending existing functionality is primarily that
this should be short-lived and deleted after the next release or so. So
isolating all the changes into a single directory seems like a good
idea.
## Discussion points
Because OSS installations don't connect to Unleash, we can't use feature
flags to control the rollout here. Instead, we must just assume that OSS
users will want to see it. If there is a better way we can control this,
that'd be great. I'd love to be able to use time constraints to not show
this after a certain date, for instance, but I don't think that's
something we can do right now?
The splash is also set to display on any page you're at when you first
load unleash. However, closing the dialog (either by closing or by
asking to see segments) will store that in localstorage, and you won't
be shown the dialog again.
---------
Co-authored-by: Nuno Góis <github@nunogois.com>
2023-10-19 08:28:14 +02:00
Nuno Góis
4167a60588
feat: biome lint frontend ( #4903 )
...
Follows up on https://github.com/Unleash/unleash/pull/4853 to add Biome
to the frontend as well.
![image](https://github.com/Unleash/unleash/assets/14320932/1906faf1-fc29-4172-a4d4-b2716d72cd65 )
Added a few `biome-ignore` to speed up the process but we may want to
check and fix them in the future.
2023-10-02 13:25:46 +01:00
NicolaeUnleash
705462f0cf
feat: dark theme v1 ( #3298 )
...
## About the changes
Creating the first version of the Dark theme
Refactor: colors variables
Refactor: use theme variable instead
- this change will help us to use MuiCssBaseline, and we can use classes
directly for easy customization when we can't identify MUI classes
Refactor: adjusting some files components
- i’ve touched also the structure of some files, not only the colors
variables (but only to adjust the style, not functionality)
Fix: dark mode persistence on refresh (by Nuno)
Feat: dark mode sees light logos, and light mode sees dark logos (by
Nuno)
---------
Co-authored-by: Nuno Góis <github@nunogois.com>
2023-03-22 16:37:40 +02:00
sjaanus
b631618532
Makestyles refactor #7/1 ( #2805 )
2023-01-03 16:30:59 +02:00
Thomas Heartman
d5fbd0b743
refactor: move docs into new structure / fix links for SEO ( #2416 )
...
## What
This (admittedly massive) PR updates the "physical" documentation
structure and fixes url inconsistencies and SEO problems reported by
marketing. The main points are:
- remove or move directories : advanced, user_guide, deploy, api
- move the files contained within to the appropriate one of topics,
how-to, tutorials, or reference
- update internal doc links and product links to the content
- create client-side redirects for all the urls that have changed.
A number of the files have been renamed in small ways to better match
their url and to make them easier to find. Additionally, the top-level
api directory has been moved to /reference/api/legacy/unleash (see the
discussion points section for more on this).
## Why
When moving our doc structure to diataxis a while back, we left the
"physical' files lying where they were, because it didn't matter much to
the new structure. However, that did introduce some inconsistencies with
where you place docs and how we organize them.
There's also the discrepancies in whether urls us underscores or hyphens
(which isn't necessarily the same as their file name), which has been
annoying me for a while, but now has also been raised by marketing as an
issue in terms of SEO.
## Discussion points
The old, hand-written API docs have been moved from /api to
/reference/api/legacy/unleash. There _is_ a /reference/api/unleash
directory, but this is being populated by the OpenAPI plugin, and mixing
those could only cause trouble. However, I'm unsure about putting
/legacy/ in the title, because the API isn't legacy, the docs are. Maybe
we could use another path? Like /old-docs/ or something? I'd appreciate
some input on this.
2022-11-22 09:05:30 +00:00
Ivar Conradi Østhus
ef965d66de
feat: Open-Source Strategy Constraints ( #2112 )
...
This commits lift the flags and makes Strategy Constraints
available to all users of Unleash.
Read more in the docs:
https://docs.getunleash.io/advanced/strategy_constraints
Enjoy!
@ivarconr
Author and maintainer
2022-09-30 10:45:34 +02:00
sellinjaanus
797cd8c28f
chore: remove splash environment ( #1108 )
...
* chore: remove splash environment
* Remove related images aswell
Co-authored-by: sighphyre <liquidwicked64@gmail.com>
2022-06-21 16:31:14 +03:00
olav
d8143c6ff4
chore: update react-router to v6 ( #946 )
...
* refactor: fix child selector warnings
* refactor: update react-router-dom
* refactor: use BrowserRouter as in react-router docs
* refactor: replace Redirect with Navigate
* refactor: replace Switch with Routes
* refactor: replace useHistory with useNavigate
* refactor: replace useParams types with useRequiredPathParam
* refactor: replace NavLink activeStyle with callback
* refactor: fix matchPath arg order
* refactor: Remove unused link state
* refactor: delete broken snapshot test
* refactor: render 404 page without redirect
* refactor: normalize path parameter names
* refactor: fix Route component usage
2022-05-05 13:42:18 +02:00
olav
35262e404b
refactor: clean up strategy parameter types ( #944 )
...
* refactor: fix splash page button background color
* refactor: regenerate OpenAPI client
* refactor: clean up strategy parameter types
* refactor: remove index signature from IConstraint
* refactor: fix never-seen status in features list
2022-05-04 15:16:34 +02:00
olav
24c11332b5
chore: update MUI to v5 ( #923 )
...
* refactor: update mui packages
* refactor: run mui codemods
* refactor: format files after codemods
* refactor: fix broken types
* refactor: clean up theme
* refactor: fix broken tests
* refactor: replace @mui/styles with tss-react
* refactor: move breakpoints into classes for tss
* refactor: fix crash on missing feature description
* refactor: remove void classNames
* refactor: adjust styles to new defaults
* refactor: remove broken rollout slider e2e test
* refactor: fix duplicate e2e testid
* refactor: update makeStyles after rebase
* refactor: add missing snapshot after rebase
* refactor: fix TableCellSortable focus styles
* refactor: use 1.4 as the default line-height
* refactor: hide webkit search field icons
* refactor: fix select box label
* refactor: make AutocompleteBox smaller
* refactor: make heading smaller
* refactor: fix toast close icon color
* refactor: update snapshots
* refactor: add missing test event awaits
* refactor: fix default button line-height
2022-05-02 15:52:41 +02:00
Tymoteusz Czech
23a874d051
Refactor: convert jsx files to typescript ( #881 )
...
* refactor: convert remaining js files to typescript
* refactor: conditionally render remove index
* refactor: dialog component to tsx
* refactor: migrate some files from jsx to tsx
* refactor: convert dropdown element to tsx
* refactor: feature toggle list to tsx
* refactor: update context name in use overrides
* refactor: variant overrides to tsx
refactor: remove unused strategy constraint file
* fix: tsx imports
* fix: update refectored components after rebase
* refactor: rename report list files to tsx
* fix: project health list types
* refactor: addon form - add types
* refactor: copy feature component types
* fix: projects toggle style after tsx refactor
* refactor: update ts types from openapi
* fix: ts refactor changes after review
* fix: header title prop
* fix: update after PR comments
* add test to useoverrides hook
* fix conditionally render time ago
* fix: toggle list empty tooltip
* fix: remove unused variable
* remove unused variable
* fix: remove faulty snapshot
2022-05-02 12:52:33 +02:00
olav
49b8e7329e
refactor: convert auth tests from Cypress to Jest ( #864 )
...
* refactor: replace data-test with data-testid
* refactor: add Jest tests for auth pages
* refactor: remove Cypress tests for auth pages
* refactor: remove questionable snapshots
* refactor: share test server setup/teardown
* refactor: restore auth page flex layout
* refactor: use toBeInTheDocument
* refactor: change recent data-test attrs to data-testid
2022-04-08 13:13:45 +02:00
olav
6efa9fe75c
fix: hide splash screens from API users ( #852 )
...
* refactor: add missing user isAPI field
* fix: hide splash screens from API users
Co-authored-by: Ivar Conradi Østhus <ivarconr@gmail.com>
2022-04-05 20:34:23 +02:00
olav
f309553a5f
refactor: port some things to TS ( #833 )
...
* refactor: remove unused securityLogger
* refactor: port commonStyles to TS
* refactor: port testIds to TS
* refactor: move app.css into themes
* refactor: use absolute import paths
* refactor: port LayoutPicker to TS
* refactor: port routes to TS
* refactor: port ScrollTop to TS
* refactor: update unused/missing ScrollTop exceptions
* refactor: remove unused route flags field
* refactor: change constants ext to TS
* refactor: remove unused testData file
* refactor: port styles to TS
* refactor: wait before typing in auth spec
2022-04-01 10:28:15 +02:00
olav
cfc2338e78
refactor: use camel case for files and dirs ( #817 )
2022-03-25 12:34:20 +01:00
olav
cc0b9f7291
refactor: avoid splash pages in e2e tests ( #810 )
2022-03-23 12:45:23 +01:00
olav
2a307523d6
feat: add operators splash page ( #802 )
...
* refactor: fix crash on null-valued project description
* refactor: remove unused layout prop
* refactor: use routes for splash components
* feat: add operators splash page
* refactor: fix styling issues
* refactor: add some comments
2022-03-22 08:23:51 +01:00