mirror of
https://github.com/grafana/grafana.git
synced 2025-02-20 11:48:34 -06:00
UI: Remove deprecated getFormStyles function (#49945)
This commit is contained in:
parent
b6a329c268
commit
05e501c641
@ -1,31 +0,0 @@
|
||||
import { GrafanaTheme2 } from '@grafana/data';
|
||||
|
||||
import { stylesFactory } from '../../themes';
|
||||
import { ComponentSize } from '../../types/size';
|
||||
import { getButtonStyles, ButtonVariant } from '../Button';
|
||||
import { getInputStyles } from '../Input/Input';
|
||||
|
||||
import { getCheckboxStyles } from './Checkbox';
|
||||
import { getFieldValidationMessageStyles } from './FieldValidationMessage';
|
||||
import { getLabelStyles } from './Label';
|
||||
import { getLegendStyles } from './Legend';
|
||||
|
||||
/** @deprecated */
|
||||
export const getFormStyles = stylesFactory(
|
||||
(theme: GrafanaTheme2, options: { variant: ButtonVariant; size: ComponentSize; invalid: boolean }) => {
|
||||
console.warn('getFormStyles is deprecated');
|
||||
|
||||
return {
|
||||
label: getLabelStyles(theme),
|
||||
legend: getLegendStyles(theme.v1),
|
||||
fieldValidationMessage: getFieldValidationMessageStyles(theme),
|
||||
button: getButtonStyles({
|
||||
theme,
|
||||
variant: options.variant,
|
||||
size: options.size,
|
||||
}),
|
||||
input: getInputStyles({ theme, invalid: options.invalid }),
|
||||
checkbox: getCheckboxStyles(theme),
|
||||
};
|
||||
}
|
||||
);
|
@ -190,7 +190,6 @@ export { InputControl } from './InputControl';
|
||||
export { Button, LinkButton, ButtonVariant, ToolbarButton, ButtonGroup, ToolbarButtonRow, ButtonProps } from './Button';
|
||||
export { ValuePicker } from './ValuePicker/ValuePicker';
|
||||
export { fieldMatchersUI } from './MatchersUI/fieldMatchersUI';
|
||||
export { getFormStyles } from './Forms/getFormStyles';
|
||||
export { Link } from './Link/Link';
|
||||
|
||||
export { Label } from './Forms/Label';
|
||||
|
Loading…
Reference in New Issue
Block a user