diff --git a/webui/src/components/Label.tsx b/webui/src/components/Label.tsx index 13c913c92fcd633f45505e3b0f35761e9de4c2db..bbe7c1588ac994dca046046c360960816ef966c2 100644 --- a/webui/src/components/Label.tsx +++ b/webui/src/components/Label.tsx @@ -23,20 +23,24 @@ const getTextColor = (background: string) => : common.black; // And black on light ones // Create a style object from the label RGB colors -const createStyle = (color: Color) => ({ +const createStyle = (color: Color, maxWidth?: string) => ({ backgroundColor: _rgb(color), color: getTextColor(_rgb(color)), borderBottomColor: darken(_rgb(color), 0.2), margin: '3px', + maxWidth: maxWidth, }); -type Props = { label: LabelFragment }; -function Label({ label }: Props) { +type Props = { + label: LabelFragment; + maxWidth?: string; +}; +function Label({ label, maxWidth }: Props) { return ( ); } diff --git a/webui/src/pages/bug/Bug.tsx b/webui/src/pages/bug/Bug.tsx index 3cb48ecde214cd24675ebb7d73bc9106e3a19e29..5f3dfd035fe03f152c472da0a9a81d62c0fd52e7 100644 --- a/webui/src/pages/bug/Bug.tsx +++ b/webui/src/pages/bug/Bug.tsx @@ -104,7 +104,7 @@ function Bug({ bug }: Props) { )} {bug.labels.map((l) => (
  • -
  • ))} diff --git a/webui/src/pages/bug/LabelChange.tsx b/webui/src/pages/bug/LabelChange.tsx index c40636c115c79068a99ea0ada4a68e56de057a05..fd466ab88fc34c4191a4bbf86c53f66fa4b6dbb0 100644 --- a/webui/src/pages/bug/LabelChange.tsx +++ b/webui/src/pages/bug/LabelChange.tsx @@ -30,12 +30,12 @@ function LabelChange({ op }: Props) { {added.length > 0 && added the } {added.map((label, index) => ( -