Skip to content

Commit 76c700f

Browse files
feat: member invite resource selection break with many projects (#7295)
1 parent 2a18499 commit 76c700f

File tree

5 files changed

+21
-17
lines changed

5 files changed

+21
-17
lines changed

.changeset/witty-jeans-hope.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'hive': patch
3+
---
4+
5+
Fixes a UI bug in MembershipInvitation modal when there are many projects/targets/services.

packages/web/app/src/components/organization/members/invitations.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -195,11 +195,10 @@ function MemberInvitationForm(props: {
195195
);
196196
}
197197

198-
// TODO: fix visibility when screen is too small (height - elements are not visible... - this can happen when there's a lot of roles)
199198
return (
200199
<Form {...form}>
201200
<form onSubmit={form.handleSubmit(onSubmit)}>
202-
<DialogContent className="min-w-[800px]">
201+
<DialogContent className="min-w-[800px] max-w-[70vw]">
203202
<DialogHeader>
204203
<DialogTitle>Membership Invitation</DialogTitle>
205204
<DialogDescription>

packages/web/app/src/components/organization/members/resource-selector.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -807,10 +807,10 @@ export function ResourceSelector(props: {
807807
</div>
808808
</div>
809809
</div>
810-
<div className="mt-0 flex min-h-[250px] flex-wrap rounded-sm">
810+
<div className="mt-0 flex h-64 flex-wrap rounded-sm">
811811
{/** Projects Content */}
812812
{showProjectsTab && (
813-
<div className="flex flex-1 flex-col border pt-2">
813+
<div className="flex h-full flex-1 flex-col overflow-auto border pt-2">
814814
<div className="text-muted-foreground mb-1 px-2 text-xs uppercase">
815815
access granted
816816
</div>
@@ -859,7 +859,7 @@ export function ResourceSelector(props: {
859859
{/** Targets Content */}
860860
<div
861861
className={cn(
862-
'flex flex-1 flex-col border-y border-r pt-2',
862+
'flex h-full flex-1 flex-col overflow-auto border-y border-r pt-2',
863863
!showProjectsTab && 'border-l',
864864
)}
865865
>
@@ -933,7 +933,7 @@ export function ResourceSelector(props: {
933933
)}
934934
</div>
935935

936-
<div className="flex flex-1 flex-col border-y border-r">
936+
<div className="flex h-full flex-1 flex-col overflow-auto border-y border-r">
937937
{/** Services Content */}
938938
{serviceAppsState === ServicesAppsState.service && (
939939
<div className="py-2">

pnpm-lock.yaml

Lines changed: 10 additions & 10 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

scripts/seed-organization.mts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ await PromisePool.withConcurrency(10)
2828
.for(new Array(100).fill(null))
2929
.process(() => org.createProject());
3030

31-
console.log('Create 200 orgainzation members');
31+
console.log('Create 100 organization members');
3232
await PromisePool.withConcurrency(10)
3333
.for(new Array(100).fill(null))
3434
.process(() => org.inviteAndJoinMember());

0 commit comments

Comments
 (0)