Browse Source

feat(issue-priority): Use 'Med' label in priority pills (#66272)

Also adjusts the stream column width since we don't need as much space
any longer
Malachi Willey 1 year ago
parent
commit
cf15792c37

+ 1 - 1
static/app/components/group/groupPriority.tsx

@@ -22,7 +22,7 @@ type GroupPriorityBadgeProps = {
 
 const PRIORITY_KEY_TO_LABEL: Record<PriorityLevel, string> = {
   [PriorityLevel.HIGH]: t('High'),
-  [PriorityLevel.MEDIUM]: t('Medium'),
+  [PriorityLevel.MEDIUM]: t('Med'),
   [PriorityLevel.LOW]: t('Low'),
 };
 

+ 1 - 1
static/app/components/issues/groupListHeader.tsx

@@ -84,7 +84,7 @@ const ChartWrapper = styled(Heading)<{narrowGroups: boolean}>`
 
 const PriorityWrapper = styled(Heading)<{narrowGroups: boolean}>`
   justify-content: flex-end;
-  width: 85px;
+  width: 70px;
 
   @media (max-width: ${p =>
       p.narrowGroups ? p.theme.breakpoints.large : p.theme.breakpoints.medium}) {

+ 1 - 1
static/app/components/stream/group.spec.tsx

@@ -102,7 +102,7 @@ describe('StreamGroup', function () {
     });
 
     const priorityDropdown = screen.getByRole('button', {name: 'Modify issue priority'});
-    expect(within(priorityDropdown).getByText('Medium')).toBeInTheDocument();
+    expect(within(priorityDropdown).getByText('Med')).toBeInTheDocument();
     await userEvent.click(priorityDropdown);
     await userEvent.click(screen.getByRole('menuitemradio', {name: 'High'}));
     expect(within(priorityDropdown).getByText('High')).toBeInTheDocument();

+ 1 - 1
static/app/components/stream/group.tsx

@@ -612,7 +612,7 @@ const EventCountsWrapper = styled('div')`
 `;
 
 const PriorityWrapper = styled('div')<{narrowGroups: boolean}>`
-  width: 85px;
+  width: 70px;
   margin: 0 ${space(2)};
   align-self: center;
   display: flex;

+ 1 - 1
static/app/views/issueList/actions/headers.tsx

@@ -129,7 +129,7 @@ const EventsOrUsersLabel = styled(ToolbarHeader)`
 const PriorityLabel = styled('div')<{isSavedSearchesOpen?: boolean}>`
   justify-content: flex-end;
   text-align: right;
-  width: 85px;
+  width: 70px;
   margin: 0 ${space(2)};
 
   /* prettier-ignore */