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

playground is completely broken #3576

Closed
4 tasks done
xiaolongkipsi opened this issue Apr 4, 2023 · 1 comment · Fixed by #3583
Closed
4 tasks done

playground is completely broken #3576

xiaolongkipsi opened this issue Apr 4, 2023 · 1 comment · Fixed by #3583
Labels

Comments

@xiaolongkipsi
Copy link

Prerequisites

What theme are you using?

core

Version

5.x

Current Behavior

No response

Expected Behavior

No response

Steps To Reproduce

No response

Environment

- OS:
- Node:
- npm:

Anything else?

No response

@xiaolongkipsi xiaolongkipsi added bug needs triage Initial label given, to be assigned correct labels and assigned labels Apr 4, 2023
@isuvorov
Copy link

isuvorov commented Apr 5, 2023

Error disappear if remove ObjectFieldTemplate from templates={{}}

The Error message:

Uncaught Error: Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: undefined. You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.

Check the render method of `ObjectField2`.

@heath-freenome heath-freenome removed the needs triage Initial label given, to be assigned correct labels and assigned label Apr 5, 2023
heath-freenome added a commit to heath-freenome/react-jsonschema-form that referenced this issue Apr 5, 2023
Fixes rjsf-team#3576 and rjsf-team#3579 by only passing `templates` with non-`undefined` values
Fixes rjsf-team#3578 by using `TextField` to render the label key input value

- Updated `@rjsf/material-ui` and `@rjsf/mui` to use the `TextField` as the input for the label key value rather than attempting to cobble one togther
  - Updated the snapshots accordingly
- Updated the `Playground` component to only pass `templates` with values that aren't undefined to the main `Form`
- Updated the `CHANGELOG.md` accordingly
heath-freenome added a commit that referenced this issue Apr 5, 2023
Fixes #3576 and #3579 by only passing `templates` with non-`undefined` values
Fixes #3578 by using `TextField` to render the label key input value

- Updated `@rjsf/material-ui` and `@rjsf/mui` to use the `TextField` as the input for the label key value rather than attempting to cobble one togther
  - Updated the snapshots accordingly
- Updated the `Playground` component to only pass `templates` with values that aren't undefined to the main `Form`
- Updated the `CHANGELOG.md` accordingly
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants