Skip to content

Commit

Permalink
Add comments referencing issue
Browse files Browse the repository at this point in the history
See: #7167
  • Loading branch information
ggdouglas committed Jan 14, 2025
1 parent 23e52d0 commit d529f56
Show file tree
Hide file tree
Showing 14 changed files with 19 additions and 0 deletions.
1 change: 1 addition & 0 deletions packages/core/test/context-menu/contextMenuTests.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ describe("ContextMenu", () => {
document.body.appendChild(containerElement);
});
afterEach(() => {
// TODO(React 18): Replace deprecated ReactDOM methods. See: https://github.com/palantir/blueprint/issues/7167
// eslint-disable-next-line deprecation/deprecation
ReactDOM.unmountComponentAtNode(containerElement!);
containerElement!.remove();
Expand Down
1 change: 1 addition & 0 deletions packages/core/test/forms/textAreaTests.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ describe("<TextArea>", () => {
});

afterEach(() => {
// TODO(React 18): Replace deprecated ReactDOM methods. See: https://github.com/palantir/blueprint/issues/7167
// eslint-disable-next-line deprecation/deprecation
ReactDOM.unmountComponentAtNode(containerElement!);
containerElement!.remove();
Expand Down
1 change: 1 addition & 0 deletions packages/core/test/slider/multiSliderTests.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ describe("<MultiSlider>", () => {
});

afterEach(() => {
// TODO(React 18): Replace deprecated ReactDOM methods. See: https://github.com/palantir/blueprint/issues/7167
// eslint-disable-next-line deprecation/deprecation
ReactDOM.unmountComponentAtNode(testsContainerElement);
testsContainerElement.remove();
Expand Down
1 change: 1 addition & 0 deletions packages/core/test/toast/overlayToasterTests.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ function unmountReact16Toaster(containerElement: HTMLElement) {
if (toasterRenderRoot == null) {
throw new Error("No elements were found under Toaster container.");
}
// TODO(React 18): Replace deprecated ReactDOM methods. See: https://github.com/palantir/blueprint/issues/7167
// eslint-disable-next-line deprecation/deprecation
ReactDOM.unmountComponentAtNode(toasterRenderRoot);
}
Expand Down
1 change: 1 addition & 0 deletions packages/core/test/toast/toasterTests.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ describe("Toaster", () => {
});

afterEach(() => {
// TODO(React 18): Replace deprecated ReactDOM methods. See: https://github.com/palantir/blueprint/issues/7167
// eslint-disable-next-line deprecation/deprecation
ReactDOM.unmountComponentAtNode(testsContainerElement);
});
Expand Down
1 change: 1 addition & 0 deletions packages/core/test/tree/treeTests.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ describe("<Tree>", () => {
});

afterEach(() => {
// TODO(React 18): Replace deprecated ReactDOM methods. See: https://github.com/palantir/blueprint/issues/7167
// eslint-disable-next-line deprecation/deprecation
ReactDOM.unmountComponentAtNode(testsContainerElement);
});
Expand Down
1 change: 1 addition & 0 deletions packages/datetime/test/components/dateRangeInputTests.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ describe("<DateRangeInput>", () => {
});
afterEach(() => {
if (containerElement !== undefined) {
// TODO(React 18): Replace deprecated ReactDOM methods. See: https://github.com/palantir/blueprint/issues/7167
// eslint-disable-next-line deprecation/deprecation
ReactDOM.unmountComponentAtNode(containerElement);
containerElement.remove();
Expand Down
2 changes: 2 additions & 0 deletions packages/datetime/test/components/timePickerTests.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ describe("<TimePicker>", () => {
});

afterEach(() => {
// TODO(React 18): Replace deprecated ReactDOM methods. See: https://github.com/palantir/blueprint/issues/7167
// eslint-disable-next-line deprecation/deprecation
ReactDOM.unmountComponentAtNode(testsContainerElement);
});
Expand Down Expand Up @@ -748,6 +749,7 @@ describe("<TimePicker>", () => {
}

function renderTimePicker(props?: Partial<TimePickerProps>) {
// TODO(React 18): Replace deprecated ReactDOM methods. See: https://github.com/palantir/blueprint/issues/7167
// eslint-disable-next-line deprecation/deprecation
timePicker = ReactDOM.render<TimePickerProps>(
<TimePicker onChange={onTimePickerChange} {...props} />,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ describe("<DateRangeInput3>", () => {

afterEach(() => {
if (containerElement !== undefined) {
// TODO(React 18): Replace deprecated ReactDOM methods. See: https://github.com/palantir/blueprint/issues/7167
// eslint-disable-next-line deprecation/deprecation
ReactDOM.unmountComponentAtNode(containerElement);
containerElement.remove();
Expand Down
1 change: 1 addition & 0 deletions packages/table/test/common/internal/scrollUtilsTests.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -339,6 +339,7 @@ describe("scrollUtils", () => {

function mountElementsWithContentSize(contentWidth: number, contentHeight: number) {
// HACKHACK: `as unknown as HTMLElement` cast is sketchy
// TODO(React 18): Replace deprecated ReactDOM methods. See: https://github.com/palantir/blueprint/issues/7167
// eslint-disable-next-line deprecation/deprecation
return ReactDOM.render<React.HTMLProps<HTMLDivElement>>(
<div style={parentStyle}>
Expand Down
2 changes: 2 additions & 0 deletions packages/table/test/harness.ts
Original file line number Diff line number Diff line change
Expand Up @@ -215,12 +215,14 @@ export class ReactHarness {

public mount(component: React.ReactElement<any>) {
// wrap in a root provider to avoid console warnings
// TODO(React 18): Replace deprecated ReactDOM methods. See: https://github.com/palantir/blueprint/issues/7167
// eslint-disable-next-line deprecation/deprecation
ReactDOM.render(React.createElement(BlueprintProvider, { children: component }), this.container);
return new ElementHarness(this.container);
}

public unmount() {
// TODO(React 18): Replace deprecated ReactDOM methods. See: https://github.com/palantir/blueprint/issues/7167
// eslint-disable-next-line deprecation/deprecation
ReactDOM.unmountComponentAtNode(this.container);
}
Expand Down
2 changes: 2 additions & 0 deletions packages/table/test/locatorTests.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ describe("Locator", () => {
// ".body" will be the scrollable region.
containerElement = document.createElement("div");
document.body.appendChild(containerElement);
// TODO(React 18): Replace deprecated ReactDOM methods. See: https://github.com/palantir/blueprint/issues/7167
// eslint-disable-next-line deprecation/deprecation
ReactDOM.render(
<div className="table-wrapper" style={style}>
Expand All @@ -76,6 +77,7 @@ describe("Locator", () => {
});

afterEach(() => {
// TODO(React 18): Replace deprecated ReactDOM methods. See: https://github.com/palantir/blueprint/issues/7167
// eslint-disable-next-line deprecation/deprecation
ReactDOM.unmountComponentAtNode(containerElement);
});
Expand Down
2 changes: 2 additions & 0 deletions packages/table/test/quadrants/tableQuadrantStackTests.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -559,6 +559,7 @@ describe("TableQuadrantStack", () => {
});

afterEach(() => {
// TODO(React 18): Replace deprecated ReactDOM methods. See: https://github.com/palantir/blueprint/issues/7167
// eslint-disable-next-line deprecation/deprecation
ReactDOM.unmountComponentAtNode(container);
onScroll.resetHistory();
Expand Down Expand Up @@ -716,6 +717,7 @@ describe("TableQuadrantStack", () => {
function renderIntoDom(element: React.JSX.Element) {
const containerElement = document.createElement("div");
document.body.appendChild(containerElement);
// TODO(React 18): Replace deprecated ReactDOM methods. See: https://github.com/palantir/blueprint/issues/7167
// eslint-disable-next-line deprecation/deprecation
const component = ReactDOM.render<any>(element, containerElement);
return {
Expand Down
2 changes: 2 additions & 0 deletions packages/table/test/table2Tests.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ describe("<Table2>", function (this) {
afterEach(() => {
harness.unmount();
if (containerElement !== undefined) {
// TODO(React 18): Replace deprecated ReactDOM methods. See: https://github.com/palantir/blueprint/issues/7167
// eslint-disable-next-line deprecation/deprecation
ReactDOM.unmountComponentAtNode(containerElement);
containerElement.remove();
Expand Down Expand Up @@ -1499,6 +1500,7 @@ describe("<Table2>", function (this) {
// get native DOM nodes
const tableNode = table.getDOMNode();
const tableBodySelector = `.${Classes.TABLE_BODY_VIRTUAL_CLIENT}`;
// TODO(React 18): Replace deprecated ReactDOM methods. See: https://github.com/palantir/blueprint/issues/7167
// eslint-disable-next-line deprecation/deprecation
const tableBodyNode = ReactDOM.findDOMNode(tableNode.querySelector(tableBodySelector));

Expand Down

0 comments on commit d529f56

Please sign in to comment.