Skip to content

Commit 8e940b8

Browse files
committed
Update comments
1 parent 58dd266 commit 8e940b8

File tree

3 files changed

+16
-14
lines changed

3 files changed

+16
-14
lines changed

packages/mui-material-next/src/FormControl/FormControl.test.js

+10-10
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@ import { expect } from 'chai';
33
import { spy } from 'sinon';
44
import { describeConformance, act, createRenderer, fireEvent } from 'test/utils';
55
import FormControl, { formControlClasses as classes } from '@mui/material-next/FormControl';
6-
// TODO: replace with material-next/OutlinedInput
6+
// TODO v6: replace with material-next/FilledInput
77
import InputBase from '@mui/material-next/InputBase';
8-
// TODO: replace with material-next/Select
8+
// TODO v6: replace with material-next/Select
99
import Select from '@mui/material/Select';
1010
import useFormControl from './useFormControl';
1111

@@ -177,7 +177,7 @@ describe('<FormControl />', () => {
177177
{flag ? (
178178
<InputBase />
179179
) : (
180-
// TODO: use material-next/Select
180+
// TODO v6: use material-next/Select
181181
<Select native>
182182
<option value="">empty</option>
183183
</Select>
@@ -196,14 +196,14 @@ describe('<FormControl />', () => {
196196
});
197197
});
198198

199-
// TODO: needs Outlined|FilledInput + FormControl integrated
199+
// TODO v6: needs FilledInput + FormControl integrated
200200
// eslint-disable-next-line mocha/no-skipped-tests
201201
describe.skip('input', () => {
202202
it('should be filled when a value is set', () => {
203203
const readContext = spy();
204204
render(
205205
<FormControl>
206-
{/* TODO: use material-next/OutlinedInput */}
206+
{/* TODO v6: use material-next/FilledInput */}
207207
<InputBase value="bar" />
208208
<TestComponent contextCallback={readContext} />
209209
</FormControl>,
@@ -215,7 +215,7 @@ describe('<FormControl />', () => {
215215
const readContext = spy();
216216
render(
217217
<FormControl>
218-
{/* TODO: use material-next/OutlinedInput */}
218+
{/* TODO v6: use material-next/FilledInput */}
219219
<InputBase inputProps={{ value: 'bar' }} />
220220
<TestComponent contextCallback={readContext} />
221221
</FormControl>,
@@ -227,7 +227,7 @@ describe('<FormControl />', () => {
227227
const readContext = spy();
228228
render(
229229
<FormControl>
230-
{/* TODO: use material-next/OutlinedInput */}
230+
{/* TODO v6: use material-next/FilledInput */}
231231
<InputBase defaultValue="bar" />
232232
<TestComponent contextCallback={readContext} />
233233
</FormControl>,
@@ -239,7 +239,7 @@ describe('<FormControl />', () => {
239239
const readContext = spy();
240240
render(
241241
<FormControl>
242-
{/* TODO: use material-next/OutlinedInput */}
242+
{/* TODO v6: use material-next/FilledInput */}
243243
<InputBase endAdornment={<div />} />
244244
<TestComponent contextCallback={readContext} />
245245
</FormControl>,
@@ -251,7 +251,7 @@ describe('<FormControl />', () => {
251251
const readContext = spy();
252252
render(
253253
<FormControl>
254-
{/* TODO: use material-next/OutlinedInput */}
254+
{/* TODO v6: use material-next/FilledInput */}
255255
<InputBase startAdornment={<div />} />
256256
<TestComponent contextCallback={readContext} />
257257
</FormControl>,
@@ -260,7 +260,7 @@ describe('<FormControl />', () => {
260260
});
261261
});
262262

263-
// TODO: needs material-next/Select + FormControl integrated
263+
// TODO v6: needs material-next/Select + FormControl integrated
264264
// eslint-disable-next-line mocha/no-skipped-tests
265265
describe.skip('select', () => {
266266
it('should not be adorned without a startAdornment', () => {

packages/mui-material-next/src/FormControl/formControlState.js

+2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1+
// TODO v6: decide whether to update/refactor this, keep as-is, or drop it
12
export default function formControlState({ props, states, muiFormControl }) {
3+
// for every prop in `states` that is undefined, set it with the value from formControlContext
24
return states.reduce((acc, state) => {
35
acc[state] = props[state];
46

packages/mui-material-next/src/InputBase/InputBase.test.js

+4-4
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ describe('<InputBase />', () => {
137137
);
138138
const input = getByRole('textbox');
139139

140-
// TODO: refactor this test with @testing-library/user-event
140+
// TODO v6: refactor this test with @testing-library/user-event
141141
// simulating user input: gain focus, key input (keydown, (input), change, keyup), blur
142142
act(() => {
143143
input.focus();
@@ -215,7 +215,7 @@ describe('<InputBase />', () => {
215215
});
216216

217217
describe('prop: slots', () => {
218-
// TODO: figure out if this is covered by describeConformance
218+
// TODO v6: figure out if this is covered by describeConformance
219219
it('should accept any html component', () => {
220220
const { getByTestId } = render(
221221
<InputBase
@@ -638,7 +638,7 @@ describe('<InputBase />', () => {
638638
expect(getByTestId('adornment')).not.to.equal(null);
639639
});
640640

641-
// TODO: use material-next/Select
641+
// TODO v6: use material-next/Select
642642
it('should allow a Select as an adornment', () => {
643643
render(
644644
<InputBase
@@ -670,7 +670,7 @@ describe('<InputBase />', () => {
670670
});
671671

672672
describe('prop: focused', () => {
673-
// TODO: use material-next/TextField
673+
// TODO v6: use material-next/TextField
674674
// eslint-disable-next-line mocha/no-skipped-tests
675675
it.skip('should render correct border color with `ThemeProvider` imported from `@emotion/react`', function test() {
676676
if (/jsdom/.test(window.navigator.userAgent)) {

0 commit comments

Comments
 (0)