Skip to content

Commit d1d5fd8

Browse files
author
Siddhartha Bingi
committed
Increase category field limit from 2 to 5 for time series splitting
Signed-off-by: Siddhartha Bingi <sidbingi@amazon.com>
1 parent 0645781 commit d1d5fd8

File tree

2 files changed

+17
-2
lines changed

2 files changed

+17
-2
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
.categoryFieldComboBox {
2+
// Ensure the combo box can handle multiple selections
3+
.euiComboBoxPill {
4+
max-width: 100%;
5+
white-space: nowrap;
6+
overflow: hidden;
7+
text-overflow: ellipsis;
8+
}
9+
10+
.euiComboBox__inputWrap {
11+
max-height: 150px; // Adjust height to accommodate more selections
12+
overflow-y: auto;
13+
}
14+
}

public/pages/ConfigureModel/components/CategoryField/CategoryField.tsx

+3-2
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ import {
3333
validateCategoryField,
3434
} from '../../../../utils/utils';
3535
import { ModelConfigurationFormikValues } from '../../models/interfaces';
36+
import './CategoryField.module.scss';
3637

3738
interface CategoryFieldProps {
3839
isEdit: boolean;
@@ -74,7 +75,7 @@ export function CategoryField(props: CategoryFieldProps) {
7475
style={{ lineHeight: 'normal' }}
7576
>
7677
Split a single time series into multiple time series based on
77-
categorical fields. You can select up to 2.{' '}
78+
categorical fields. You can select up to 5.{' '}
7879
<EuiLink href={`${BASE_DOCS_LINK}/ad`} target="_blank">
7980
Learn more
8081
</EuiLink>
@@ -155,7 +156,7 @@ export function CategoryField(props: CategoryFieldProps) {
155156
onChange={(options) => {
156157
const selection = options.map((option) => option.label);
157158
if (!isEmpty(selection)) {
158-
if (selection.length <= 2) {
159+
if (selection.length <= 5) {
159160
form.setFieldValue('categoryField', selection);
160161
}
161162
} else {

0 commit comments

Comments
 (0)