Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bump to react 18 #1364

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50,251 changes: 30,488 additions & 19,763 deletions package-lock.json

Large diffs are not rendered by default.

17 changes: 9 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@
"test": "jest"
},
"dependencies": {
"@ant-design/icons": "4.4.0",
"@docusaurus/core": "2.1.0",
"@docusaurus/preset-classic": "2.1.0",
"@ant-design/icons": "5.4.0",
"@docusaurus/core": "3.4.0",
"@docusaurus/preset-classic": "3.4.0",
"@emotion/react": "11.7.1",
"@emotion/styled": "11.6.0",
"@mui/material": "5.4.1",
Expand All @@ -31,12 +31,13 @@
"@types/jest": "26.0.20",
"@types/lodash": "4.14.168",
"@types/lz-string": "1.3.34",
"@types/react": "17.0.39",
"@types/react-dom": "17.0.11",
"@types/react": "18.3.3",
"@types/react-dom": "18.3.0",
"@types/simpl-schema": "1.12.2",
"@types/warning": "3.0.0",
"@types/ws": "8.5.11",
"ajv": "8.0.5",
"antd": "4.10.3",
"antd": "4.24.16",
"classnames": "^2.0.0",
"core-js": "3.8.3",
"csstype": "3.0.10",
Expand All @@ -52,8 +53,8 @@
"lz-string": "1.4.4",
"parcel": "2.9.2",
"raw-loader": "4.0.2",
"react": "17.0.2",
"react-dom": "17.0.2",
"react": "18.3.1",
"react-dom": "18.3.1",
"react-feather": "2.0.9",
"react-frame-component": "4.1.3",
"react-test-renderer": "17.0.2",
Expand Down
2 changes: 1 addition & 1 deletion packages/uniforms-antd/src/NumField.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ export type NumFieldProps = FieldProps<
// FIXME: Why `onReset` fails with `wrapField`?
Omit<InputNumberProps, 'onReset'>,
// FIXME: `unknown` ref; see https://github.com/vazco/uniforms/discussions/1230#discussioncomment-5158439
{ decimal?: boolean; inputRef?: Ref<unknown> }
{ decimal?: boolean; inputRef?: Ref<HTMLInputElement> }
>;

function Num(props: NumFieldProps) {
Expand Down
4 changes: 2 additions & 2 deletions packages/uniforms-antd/src/TextField.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Input, { InputProps } from 'antd/lib/input';
import Input, { InputProps, InputRef } from 'antd/lib/input';
import React, { Ref } from 'react';
import { FieldProps, connectField, filterDOMProps } from 'uniforms';

Expand All @@ -7,7 +7,7 @@ import wrapField from './wrapField';
export type TextFieldProps = FieldProps<
string,
Omit<InputProps, 'onReset'>,
{ inputRef?: Ref<Input> }
{ inputRef?: Ref<InputRef> }
>;

function Text(props: TextFieldProps) {
Expand Down
1 change: 1 addition & 0 deletions packages/uniforms/__suites__/render-zod.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ export function renderWithZod<Props, Schema extends ZodObject<ZodRawShape>>({
wrapper({ children }) {
const bridge = new ZodBridge({ schema });
return (
// @ts-expect-error
<AutoForm {...autoFormProps} schema={bridge} children={children} />
);
},
Expand Down
1 change: 1 addition & 0 deletions packages/uniforms/__suites__/render.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ export function render<P, Model extends UnknownObject>(
model={model}
schema={bridge}
>
{/* @ts-expect-error */}
{children}
</AutoForm>
);
Expand Down
3 changes: 2 additions & 1 deletion packages/uniforms/src/BaseForm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import clone from 'lodash/clone';
import get from 'lodash/get';
import omit from 'lodash/omit';
import setWith from 'lodash/setWith';
import React, { Component, SyntheticEvent } from 'react';
import React, { Component, SyntheticEvent, ReactNode } from 'react';

import { Bridge } from './Bridge';
import { changedKeys } from './changedKeys';
Expand All @@ -29,6 +29,7 @@ export type BaseFormProps<Model extends UnknownObject> = {
readOnly?: boolean;
schema: Bridge;
showInlineError?: boolean;
children?: ReactNode;
};

export type BaseFormState<Model extends UnknownObject> = {
Expand Down
Loading
Loading