Skip to content

Commit

Permalink
Merge branch 'rjsf-team:master' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
jacqueswho authored Jan 25, 2022
2 parents 9e2dff9 + 3c1d465 commit 36f57b3
Show file tree
Hide file tree
Showing 57 changed files with 1,520 additions and 637 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2.4.1
uses: actions/setup-node@v2.5.1
with:
node-version: ${{ matrix.node-version }}
- run: npm ci
Expand Down Expand Up @@ -74,7 +74,7 @@ jobs:
uses: crazy-max/[email protected]
with:
keep_history: true
target-branch: gh-pages
target_branch: gh-pages
build_dir: dist
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand All @@ -87,7 +87,7 @@ jobs:
# steps:
# - uses: actions/checkout@v2
# - name: Use Node.js 14.x
# uses: actions/setup-node@v2.4.1
# uses: actions/setup-node@v2.5.1
# with:
# node-version: 14.x
# - run: npm ci
Expand All @@ -103,7 +103,7 @@ jobs:
steps:
- uses: actions/checkout@v2
- name: Setup Python
uses: actions/setup-python@v2.2.2
uses: actions/setup-python@v2.3.1
with:
python-version: 3.6
- run: pip install -r requirements.docs.txt
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
steps:
- uses: actions/checkout@v2
- name: Use Node.js 14.x
uses: actions/setup-node@v2.4.1
uses: actions/setup-node@v2.5.1
with:
node-version: 14.x
- run: npm ci
Expand Down
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -131,4 +131,5 @@ yarn.lock
coverage
.nyc_output

venv
venv
*.orig
21 changes: 17 additions & 4 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,22 @@ it according to semantic versioning. For example, if your PR adds a breaking cha
should change the heading of the (upcoming) version to include a major version bump.
-->
# v3.3.1 (upcoming)

# v3.3.0

## @rjsf/semantic-ui
- "semantic-ui-react" dependency updated to v1.3.1 (https://github.com/rjsf-team/react-jsonschema-form/pull/2590)
- fixed an issue where all semantic props overwritten when a single [semantic theme-specific prop](https://react-jsonschema-form.readthedocs.io/en/latest/api-reference/themes/semantic-ui/uiSchema/) is passed in ([issue 2619](https://github.com/rjsf-team/react-jsonschema-form/issues/2619)) (https://github.com/rjsf-team/react-jsonschema-form/pull/2590)

# v3.2.2 (upcoming)

# v3.2.1

## @rjsf/core
- Don't crash when non-object formData is passed in to a schema item with additionalProperties (https://github.com/rjsf-team/react-jsonschema-form/pull/2595)
- Upgrade jsonpointer to 5.0.0 to address security vulnerability (https://github.com/rjsf-team/react-jsonschema-form/pull/2599)

# v3.2.1 (upcoming)

# v3.2.0

Expand All @@ -25,8 +39,7 @@ should change the heading of the (upcoming) version to include a major version b
- bootstrap-4 TextWidget wrappers now pull from registry, add rootSchema to Registry, fix FieldProps.onFocus type to match WidgetProps (https://github.com/rjsf-team/react-jsonschema-form/pull/2519)
- Added global `readonly` flag to the `Form` (https://github.com/rjsf-team/react-jsonschema-form/pull/2554)
- Fix to allow changing `additionalProperties` to falsy values (https://github.com/rjsf-team/react-jsonschema-form/pull/2540)
- Pass uiSchema to custom Boolean widget (https://github.com/rjsf-team/react-jsonschema-form/pull/2587)

- Pass uiSchema to custom Boolean widget (https://github.com/rjsf-team/react-jsonschema-form/pull/2587
## @rjsf/bootstrap-4
- bootstrap-4 TextWidget wrappers now pull from registry, add rootSchema to Registry, fix FieldProps.onFocus type to match WidgetProps (https://github.com/rjsf-team/react-jsonschema-form/pull/2519)

Expand All @@ -45,7 +58,7 @@ should change the heading of the (upcoming) version to include a major version b
- Take into account implicitly defined types when rendering labels for fields (https://github.com/rjsf-team/react-jsonschema-form/pull/2502)

## @rjsf/antd
- Add default Form export to @rjsf/antd (https://github.com/rjsf-team/react-jsonschema-form/pull/2514)
- Add default Form export to @rjsf/antd (https://github.com/rjsf-team/react-jsonschema-form/pull/2514)

## @rjsf/fluent-ui
- Make material-ui and fluent-ui pull TextWidget from the registry; remove registry prop from <div> in TextWidget (https://github.com/rjsf-team/react-jsonschema-form/pull/2515)
Expand Down
2 changes: 1 addition & 1 deletion lerna.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@
"packages": [
"packages/*"
],
"version": "3.2.0"
"version": "3.2.1"
}
65 changes: 47 additions & 18 deletions packages/antd/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions packages/antd/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@rjsf/antd",
"version": "3.2.0",
"version": "3.2.1",
"description": "Ant Design theme, fields and widgets for react-jsonschema-form",
"main": "dist/cjs/index.js",
"module": "dist/es/index.js",
Expand Down Expand Up @@ -44,7 +44,7 @@
"@babel/preset-env": "^7.10.3",
"@babel/preset-react": "^7.0.0",
"@babel/register": "^7.4.4",
"@rjsf/core": "^3.2.0",
"@rjsf/core": "^3.2.1",
"antd": "^4.0.0",
"atob": "^2.0.3",
"babel-eslint": "^10.0.1",
Expand All @@ -67,7 +67,7 @@
"react-dom": "^16.8.6",
"react-test-renderer": "^16.13.1",
"rimraf": "^3.0.2",
"style-loader": "^1.0.0",
"style-loader": "^2.0.0",
"webpack": "^4.20.2",
"webpack-cli": "^3.1.2",
"webpack-dev-middleware": "^3.4.0",
Expand Down
3 changes: 1 addition & 2 deletions packages/antd/src/templates/FieldTemplate/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ const FieldTemplate = ({
label,
onDropPropertyClick,
onKeyChange,
rawDescription,
rawErrors,
rawHelp,
readonly,
Expand Down Expand Up @@ -64,7 +63,7 @@ const FieldTemplate = ({
) : (
<Form.Item
colon={colon}
// extra={!!rawDescription && description}
extra={description}
hasFeedback={schema.type !== 'array' && schema.type !== 'object'}
help={(!!rawHelp && help) || (!!rawErrors && renderFieldErrors())}
htmlFor={id}
Expand Down
35 changes: 35 additions & 0 deletions packages/antd/test/Form.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -94,4 +94,39 @@ describe("single fields", () => {
.toJSON();
expect(tree).toMatchSnapshot();
});
test("field with description", () => {
const schema = {
type: "object",
properties: {
"my-field": {
type: "string",
description: "some description",
}
}
};
const tree = renderer
.create(<Form schema={schema} />)
.toJSON();
expect(tree).toMatchSnapshot();
});
test("field with description in uiSchema", () => {
const schema = {
type: "object",
properties: {
"my-field": {
type: "string",
description: "some description",
}
}
};
const uiSchema = {
"my-field": {
"ui:description": "some other description",
},
};
const tree = renderer
.create(<Form schema={schema} uiSchema={uiSchema} />)
.toJSON();
expect(tree).toMatchSnapshot();
});
});
14 changes: 14 additions & 0 deletions packages/antd/test/__snapshots__/Array.test.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -281,6 +281,13 @@ exports[`array fields fixed array 1`] = `
/>
</div>
</div>
<div
className="ant-form-item-extra"
>
<span
id="root_0__description"
/>
</div>
</div>
</div>
</div>
Expand Down Expand Up @@ -432,6 +439,13 @@ exports[`array fields fixed array 1`] = `
</div>
</div>
</div>
<div
className="ant-form-item-extra"
>
<span
id="root_1__description"
/>
</div>
</div>
</div>
</div>
Expand Down
Loading

0 comments on commit 36f57b3

Please sign in to comment.