-
Notifications
You must be signed in to change notification settings - Fork 243
[dev] [Marfuen] mariano/more-ui-pages #2064
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -93,55 +93,51 @@ export function VendorHeader({ vendor, isEditSheetOpen, onEditSheetOpenChange }: | |
|
|
||
| return ( | ||
| <> | ||
| <div className="mb-4 space-y-1"> | ||
| <div className="flex flex-wrap items-center gap-2"> | ||
| <h1 className="text-lg font-semibold text-foreground">{vendor.name}</h1> | ||
| {certifications.filter((cert) => cert.status === 'verified').length > 0 && ( | ||
| <div className="flex flex-wrap items-center gap-2"> | ||
| {certifications | ||
| .filter((cert) => { | ||
| // Only show verified certifications | ||
| return cert.status === 'verified'; | ||
| }) | ||
| .map((cert, index) => { | ||
| const IconComponent = getCertificationIcon(cert); | ||
|
|
||
| if (!IconComponent) return null; | ||
|
|
||
| const iconContent = ( | ||
| <div | ||
| className={cn( | ||
| 'inline-flex items-center justify-center', | ||
| 'transition-all duration-300 ease-out', | ||
| 'w-[24px] h-[28px] shrink-0 overflow-hidden', // Proportionally smaller | ||
| cert.url && ['cursor-pointer', 'hover:scale-[1.02]', 'active:scale-[0.99]'], | ||
| )} | ||
| title={cert.type} // Show full text on hover | ||
| <div className="mb-4 space-y-2"> | ||
| {certifications.filter((cert) => cert.status === 'verified').length > 0 && ( | ||
| <div className="flex flex-wrap items-center gap-2"> | ||
| {certifications | ||
| .filter((cert) => { | ||
| // Only show verified certifications | ||
| return cert.status === 'verified'; | ||
| }) | ||
| .map((cert, index) => { | ||
| const IconComponent = getCertificationIcon(cert); | ||
|
|
||
| if (!IconComponent) return null; | ||
|
|
||
| const iconContent = ( | ||
| <div | ||
| className={cn( | ||
| 'inline-flex items-center justify-center', | ||
| 'transition-all duration-300 ease-out', | ||
| 'w-[24px] h-[28px] shrink-0 overflow-hidden', // Proportionally smaller | ||
| cert.url && ['cursor-pointer', 'hover:scale-[1.02]', 'active:scale-[0.99]'], | ||
| )} | ||
| title={cert.type} // Show full text on hover | ||
| > | ||
| <IconComponent className="h-[24px] w-[24px] max-h-[24px] max-w-[24px]" /> | ||
| </div> | ||
| ); | ||
|
|
||
| if (cert.url) { | ||
| return ( | ||
| <Link | ||
| key={`${cert.type}-${index}`} | ||
| href={cert.url} | ||
| target="_blank" | ||
| rel="noopener noreferrer" | ||
| className="inline-block" | ||
| > | ||
| <IconComponent className="h-[24px] w-[24px] max-h-[24px] max-w-[24px]" /> | ||
| </div> | ||
| {iconContent} | ||
| </Link> | ||
| ); | ||
| } | ||
|
|
||
| if (cert.url) { | ||
| return ( | ||
| <Link | ||
| key={`${cert.type}-${index}`} | ||
| href={cert.url} | ||
| target="_blank" | ||
| rel="noopener noreferrer" | ||
| className="inline-block" | ||
| > | ||
| {iconContent} | ||
| </Link> | ||
| ); | ||
| } | ||
|
|
||
| return <div key={`${cert.type}-${index}`}>{iconContent}</div>; | ||
| })} | ||
| </div> | ||
| )} | ||
| </div> | ||
| {vendor.description && <p className="text-sm text-muted-foreground">{vendor.description}</p>} | ||
| return <div key={`${cert.type}-${index}`}>{iconContent}</div>; | ||
| })} | ||
| </div> | ||
| )} | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Vendor description removed from displayMedium Severity The |
||
| {links.length > 0 && ( | ||
| <div className="flex flex-wrap items-center gap-2 pt-2"> | ||
| {links.map((link, index) => { | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -63,7 +63,6 @@ const getRiskColor = (level: string) => { | |
| }; | ||
|
|
||
| const probabilityLevels = ['Very Likely', 'Likely', 'Possible', 'Unlikely', 'Very Unlikely']; | ||
| const probabilityNumbers = ['5', '4', '3', '2', '1']; | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Unused constant
|
||
| const probabilityLabels = [ | ||
| 'Very Likely (5)', | ||
| 'Likely (4)', | ||
|
|
@@ -183,7 +182,10 @@ export function RiskMatrixChart({ | |
| </div> | ||
| </CardHeader> | ||
| <CardContent> | ||
| <div className="relative"> | ||
| <div className="relative pl-10"> | ||
| <div className="pointer-events-none absolute left-0 top-1/2 -translate-y-1/2 -rotate-90 text-xs text-muted-foreground"> | ||
| Likelihood | ||
| </div> | ||
| <div> | ||
| <div className="grid grid-cols-6 rounded-lg"> | ||
| <div className="h-12" /> | ||
|
|
@@ -194,11 +196,8 @@ export function RiskMatrixChart({ | |
| ))} | ||
| {probabilityLevels.map((probability, rowIdx) => ( | ||
| <div key={probability} className="contents"> | ||
| <div | ||
| className="mr-4 flex flex-col items-center justify-center" | ||
| title={probabilityLabels[rowIdx]} | ||
| > | ||
| <span className="text-xs">{probabilityNumbers[rowIdx]}</span> | ||
| <div className="mr-4 flex flex-col items-end justify-center text-right"> | ||
| <span className="text-xs">{probabilityLevels[rowIdx]}</span> | ||
| </div> | ||
| {impactLevels.map((impact, colIdx) => { | ||
| const cell = riskData.find( | ||
|
|
@@ -230,8 +229,11 @@ export function RiskMatrixChart({ | |
| </div> | ||
| ))} | ||
| </div> | ||
| <div className="mt-2 flex justify-center"> | ||
| <span className="text-xs">{'Impact'}</span> | ||
| <div className="mt-2 grid grid-cols-6"> | ||
| <div /> | ||
| <div className="col-span-5 flex justify-center"> | ||
| <span className="text-xs">Impact</span> | ||
| </div> | ||
| </div> | ||
| </div> | ||
| </div> | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TaskItems no longer visible when viewing a task
Medium Severity
The
TaskItemscomponent was previously rendered unconditionally on the vendor detail page, making tasks always visible. After this change,TaskItemsis wrapped in{!isViewingTask && (...)}, so whenisViewingTaskis true, the tasks list is no longer accessible. This behavioral regression removes functionality users may rely on when viewing a task in context.Additional Locations (1)
apps/app/src/app/(app)/[orgId]/vendors/[vendorId]/components/VendorPageClient.tsx#L100-L102