Chore: Remove menuShouldPortal deprecation warning (#45211) (#45221)

* Chore: Remove Select deprecation

* remove unused import

* Update lockfile

(cherry picked from commit 947b8b8d3b)

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
This commit is contained in:
Grot (@grafanabot)andAshley Harrison authored and GitHub committed 2022-02-10 12:58:19 +01:00
1 parent 4c55c450c3
commit 3fda778e6d
2 files changed
+2 -6

No files matched your search

@@ -20,7 +20,6 @@ import { useTheme2 } from '../../themes';
import { getSelectStyles } from './getSelectStyles';
import { cleanValue, findSelectedValue } from './utils';
import { ActionMeta, SelectBaseProps, SelectValue } from './types';
import { deprecationWarning } from '@grafana/data';
interface ExtraValuesIndicatorProps {
maxVisibleValues?: number | undefined;
@@ -119,6 +118,7 @@ export function SelectBase<T>({
maxVisibleValues,
menuPlacement = 'auto',
menuPosition,
// TODO change this to default to true for Grafana 9
menuShouldPortal = false,
noOptionsMessage = 'No options found',
onBlur,
@@ -139,9 +139,6 @@ export function SelectBase<T>({
width,
isValidNewOption,
}: SelectBaseProps<T>) {
if (menuShouldPortal === false) {
deprecationWarning('SelectBase', 'menuShouldPortal={false}', 'menuShouldPortal={true}');
}
const theme = useTheme2();
const styles = getSelectStyles(theme);
@@ -46,9 +46,8 @@ export interface SelectCommonProps<T> {
menuPlacement?: 'auto' | 'bottom' | 'top';
menuPosition?: 'fixed' | 'absolute';
/**
* @deprecated
* Setting to true will portal the menu to `document.body`.
* This property will soon be removed and portalling will be the default behavior.
* This property will soon default to true and portalling will be the default behavior.
*/
menuShouldPortal?: boolean;
/** The message to display when no options could be found */