1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-10-13 11:17:26 +02:00
unleash.unleash/frontend/src/component/common
Thomas Heartman d32990ec4c
fix: make loader not exlpode to 100vh in unnecessary locations (#7589)
This change fixes an issue with the loader where it would explode its
parent component to 100vh even when that was not called for.

To do so, I've added the a new `type` prop to the component, to
distinguish between `fullscreen` and `inline` usage. The `fullscreen`
type sets the height to 100vh, while the `inline` type sets it to
100%.

Now, this doesn't directly make the loader fullscreen (it just makes
sure it's at least as tall as the screen), so maybe the prop name is
misleading. I'd be happy to change it (or to even extract this into
two separate components) if that's preferable. Other potential prop
names could be `height`, which is very direct, or `usage`, which I
think better describes what we do. Like with `type`, I'd like to
communicate the intended behavior more that the actual implementation,
so I'm leaning towards either `type` or `usage`.

## Screenies

I've gone through all the usages of the loader, and checked how each one
works. Here they are:

### Loader in environment variants

I wasn't able to trigger this manually, but it's apparently there

Old (ignore the banner placement; that's firefox's screenshot tool
acting up)

![image](https://github.com/user-attachments/assets/f5d0a709-6815-4838-9ad4-c8f79a54ad0e)

New:

![image](https://github.com/user-attachments/assets/c7538146-b8af-4253-89ed-55d1eb37d6a5)

### Project setting forms

Old:

![image](https://github.com/user-attachments/assets/f8b55899-4483-470a-8d3a-3d11761ec8c7)

New:

![image](https://github.com/user-attachments/assets/29157004-6662-494b-9939-2f34977a9c63)

### Rollout strategy

Old:

![image](https://github.com/user-attachments/assets/5c699a06-37bd-4b3b-a3e3-f613ca7c88d5)

New (no discernible change):

![image](https://github.com/user-attachments/assets/f52178fe-9d26-4ebb-bd48-8a1c4a7e2f04)

### Advanced playground

Old:

![image](https://github.com/user-attachments/assets/43f7183b-cefc-4e29-961e-5d7e18d29be9)

New:

![image](https://github.com/user-attachments/assets/082d94dc-36e0-483c-b7a9-bd75e727c0d5)

### Loading screen / initial redirect

Old:

![image](https://github.com/user-attachments/assets/dbb8b1af-d585-4d48-8431-5379afd4f653)

New (no new component props):

![image](https://github.com/user-attachments/assets/842e766f-0ea7-4396-9696-b88509e24d77)

New (with new props):

![image](https://github.com/user-attachments/assets/e6ffd303-f24e-478d-88d9-b4fa57f307e4)
2024-07-15 14:41:45 +02:00
..
AnimateOnMount feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
Announcer
ApiError
ApiTokenTable feat: show orphaned API tokens (#7569) 2024-07-11 14:06:22 +02:00
AutocompleteBox
Badge fix: badge should render children 0 value (#6981) 2024-05-06 13:24:52 +03:00
BatchSelectionActionsBar feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
BreadcrumbNav
CheckmarkBadge
Codebox
ConditionallyRender
ConstraintAccordion feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
CreateButton
DateTimePicker
Dialogue feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
DividerText
DropdownMenu
EnterpriseBadge
EnvironmentIcon
ExperimentalFeedback
FavoriteIconButton
FeatureArchiveDialog chore: rename toggle to flag #1 (#7092) 2024-05-21 15:18:00 +03:00
FeatureStaleDialog chore: rename toggle to flag #1 (#7092) 2024-05-21 15:18:00 +03:00
FeatureStatusChip chore: rename toggle to flag #2 (#7097) 2024-05-22 08:20:11 +03:00
Feedback
FilterDateItem feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
FormSwitch
FormTemplate feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
GeneralSelect Chore: visually hide labels in the create project form (#7015) 2024-05-13 07:33:06 +02:00
Gradient feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
GridCol feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
GridRow feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
GuidanceIndicator feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
HelpIcon
Highlighter
HtmlTooltip fix: prevent project cell overflow on api keys table (#7472) 2024-07-02 12:10:02 +02:00
Input chore: update input field text sizes (#7107) 2024-05-22 13:26:22 +02:00
InputCaption
InputListField
InstanceStatus feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
ItemList
Limit feat: API Tokens limit - UI (#7561) 2024-07-12 14:44:46 +02:00
Loader fix: make loader not exlpode to 100vh in unnecessary locations (#7589) 2024-07-15 14:41:45 +02:00
LoginRedirect
MainHeader
Markdown
MultiActionButton feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
MultipleRoleSelect feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
NewConstraintAccordion feat: constraints values limit in a strategy UI (#7557) 2024-07-08 15:08:16 +02:00
NoItems feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
NotFound feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
Notifications feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
OperatorUpgradeAlert
PageContent feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
PageHeader feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
PasswordField
PercentageCircle
PermissionButton feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
PermissionGuard
PermissionHOC
PermissionIconButton Feat: feature view created by field - frontend (#7382) 2024-06-13 13:00:57 +02:00
PermissionSwitch chore: use HTML (custom) tooltip for permission switches (#7355) 2024-06-11 14:03:35 +02:00
PremiumFeature
PrettifyLargeNumber
Proclamation
ProjectSelect fix: Project select should not expand when selecting multiple projects (#6811) 2024-04-10 12:34:11 +03:00
ProtectedRoute
ReactJSONEditor
ResponsiveButton feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
RoleBadge
RoleDescription
RoleSelect
ScreenReaderOnly feat: filter by user when interacting with the avatar (#7347) 2024-06-11 12:15:35 +02:00
ScrollTop
Search feat: track interaction with search (#7526) 2024-07-03 12:27:20 +03:00
SegmentItem
SidebarModal
SidePanelList
SkipNavLink
StaleDataNotification
Sticky feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
StrategyItemContainer feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
StrategySeparator
StrategyVariantsUpgradeAlert
StringTruncator
Table API tokens - virtualized table (#7531) 2024-07-09 13:22:55 +02:00
TabNav feat: upgrade from react v17 to v18 (#7265) 2024-06-11 13:59:52 +03:00
ThemeMode
ToastRenderer
TooltipLink
TooltipResolver feat: command menu items can have description as tooltip now (#7455) 2024-06-26 12:39:53 +03:00
UpdateButton
UserAvatar feat: filter by user when interacting with the avatar (#7347) 2024-06-11 12:15:35 +02:00
VariantInfoAlert chore: rename toggle to flag #2 (#7097) 2024-05-22 08:20:11 +03:00
VerticalTabs fix: project settings table overflow (#7288) 2024-06-05 14:05:41 +02:00
common.module.scss
flags.ts
index.jsx
select.tsx
util.test.ts fix: prevent strategy variant weight from going into negative numbers on Frontend (#7460) 2024-06-27 09:06:59 +00:00
util.ts fix: prevent strategy variant weight from going into negative numbers on Frontend (#7460) 2024-06-27 09:06:59 +00:00