Skip to content

Commit 976c2b9

Browse files
authored
chore(compat): add deprecation notice for all components (#8368)
1 parent 37d4510 commit 976c2b9

File tree

6 files changed

+12
-0
lines changed

6 files changed

+12
-0
lines changed

packages/compat/src/components/Loader/index.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,8 @@ export interface LoaderPropTypes extends CommonProps {
3939
*
4040
* The `Loader` signals that an operation is currently being executed. It uses as little space as possible to allow the user to interact with the UI.
4141
* It can be used to signal a data update on an already existing dataset, or where an expansion will happen.
42+
*
43+
* @deprecated Please use the `BusyIndicator` component instead.
4244
*/
4345
const Loader = forwardRef<HTMLDivElement, LoaderPropTypes>((props, ref) => {
4446
const { className, type = LoaderType.Indeterminate, progress = '0px', slot, style, delay = 0, ...rest } = props;

packages/compat/src/components/OverflowToolbarButton/index.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@ export interface OverflowToolbarButtonPropTypes extends Omit<ButtonPropTypes, 'c
2525
* The `OverflowToolbarButton` represents a push button that shows its text only when in the overflow area of a `Toolbar`.
2626
*
2727
* __Note:__ This component is only compatible with the `Toolbar` component from the `@ui5/webcomponents-react-compat` package.
28+
*
29+
* @deprecated Please use the `Toolbar` component from `@ui5/webcomponents-react` instead. You can achieve the same behavior via `ToolbarItem` and the `:state(overflowed)` CSS pseudo class.
2830
*/
2931
const OverflowToolbarButton = forwardRef<ButtonDomRef, OverflowToolbarButtonPropTypes>((props, ref) => {
3032
const { children, ...rest } = props;

packages/compat/src/components/OverflowToolbarToggleButton/index.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,8 @@ export interface OverflowToolbarToggleButtonPropTypes extends Omit<ToggleButtonP
2828
* The `OverflowToolbarToggleButton` represents a toggle button that shows its text only when in the overflow area of a `Toolbar`.
2929
*
3030
* __Note:__ This component is only compatible with the `Toolbar` component from the `@ui5/webcomponents-react-compat` package.
31+
*
32+
* @deprecated Please use the `Toolbar` component from `@ui5/webcomponents-react` instead. You can achieve the same behavior via `ToolbarItem` and the `:state(overflowed)` CSS pseudo class.
3133
*/
3234
const OverflowToolbarToggleButton = forwardRef<ToggleButtonDomRef, OverflowToolbarToggleButtonPropTypes>(
3335
(props, ref) => {

packages/compat/src/components/Toolbar/index.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,8 @@ const OVERFLOW_BUTTON_WIDTH = 36 + 8 + 8; // width + padding end + spacing start
143143
* __Note:__ To prevent duplicate child `id`s in the DOM, all child `id`s get an `-overflow` suffix. This is especially important when popovers are opened by id.
144144
*
145145
* __Note:__ When using React 19 with `StrictMode` enabled, overflow behavior may not work reliably. This only affects development mode, as `StrictMode` is not applied in production.
146+
*
147+
* @deprecated Please use the `Toolbar` component from `@ui5/webcomponents-react` instead.
146148
*/
147149
const Toolbar = forwardRef<HTMLDivElement, ToolbarPropTypes>((props, ref) => {
148150
const {

packages/compat/src/components/ToolbarSeparator/index.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ export type ToolbarSeparatorPropTypes = CommonProps;
1212
* Creates a visual separator between the preceding and succeeding `Toolbar` item.
1313
*
1414
* __Note:__ This component is only compatible with the `Toolbar` component from the `@ui5/webcomponents-react-compat` package.
15+
*
16+
* @deprecated Please use the `Toolbar` component from `@ui5/webcomponents-react` instead.
1517
*/
1618
const ToolbarSeparator = forwardRef<HTMLDivElement, ToolbarSeparatorPropTypes>((props, ref) => {
1719
const { style, className, ...rest } = props;

packages/compat/src/components/ToolbarSpacer/index.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ export type ToolbarSpacerPropTypes = CommonProps;
66
* Adds horizontal space between the items used within a `Toolbar`.
77
*
88
* __Note:__ This component is only compatible with the `Toolbar` component from the `@ui5/webcomponents-react-compat` package.
9+
*
10+
* @deprecated Please use the `Toolbar` component from `@ui5/webcomponents-react` instead.
911
*/
1012
const ToolbarSpacer = forwardRef<HTMLSpanElement, ToolbarSpacerPropTypes>((props, ref) => {
1113
return <span ref={ref} style={{ flexGrow: 1 }} className="spacer" {...props} data-component-name="ToolbarSpacer" />;

0 commit comments

Comments
 (0)