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

3.17.0 #1757

Merged
merged 66 commits into from
Feb 6, 2024
Merged

3.17.0 #1757

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
66 commits
Select commit Hold shift + click to select a range
5db10f8
Refactor DynamicForm to use RenderListDataAsStream
Sep 28, 2023
d42db42
Amended ControlsTest config propertyPane
Sep 29, 2023
d9281fa
Added form validation to Dynamic Form
Oct 3, 2023
f02dbb8
Implemented Custom Formatting for Dynamic Form body
Oct 3, 2023
d5b0f42
Refactor of DynamicForm, DynamicField, ControlsTestWebPart, added exp…
Oct 6, 2023
a9577b7
Added tests and fixes.
Oct 7, 2023
10095b9
Fixes to desired functionality
Oct 7, 2023
faf2780
Added custom filter to PeoplePicker selection
GuidoZam Oct 7, 2023
e4cf220
Applied recommended changes following review
Oct 9, 2023
8cbac7d
Merge branch 'dev' into dynamic-form-list-customization
Oct 9, 2023
e13cff8
Fixes and cleanup following merge from 'dev'
Oct 9, 2023
801bb06
Merge branch 'dev' into dynamic-form-list-customization
Oct 9, 2023
08ac2e8
Fixes and cleanup following merge with 'dev'
Oct 9, 2023
62e483e
Amendment of FormulaEvaluation and CustomFormatting classes to reduce…
Oct 9, 2023
ee7931d
Merge branch 'dev' into dynamic-form-list-customization
Oct 17, 2023
6882aa0
Use stringMatchOption instead of deprecated stringMatchId #1688
lafe Nov 13, 2023
276c0f8
Align heading styles and font sizes with OOB SharePoint
mbice Nov 21, 2023
d28e93c
3.17.0
AJIXuMuK Nov 25, 2023
5a6ea2a
3.17.0 initial
AJIXuMuK Nov 25, 2023
c60c83d
pre-commit
AJIXuMuK Nov 25, 2023
77add1c
Bump the npm_and_yarn at /. security update group with 1 update
dependabot[bot] Nov 26, 2023
15b93ab
Merge pull request #1711 from pnp/dependabot/npm_and_yarn/spfx-fast-s…
joelfmrodrigues Nov 26, 2023
2648fbb
Added file handling in DynamicForm (#1625)
GuidoZam Nov 27, 2023
b529622
Updating release notes following PR #1625 merge
michaelmaillot Nov 27, 2023
f0f11aa
Fixing DynamicForm Icon import (OUIFR => FluentUI)
michaelmaillot Nov 27, 2023
085ce2f
Bump @types/lodash from 4.14.194 to 4.14.202
dependabot[bot] Nov 27, 2023
8d665e8
Merge branch 'dev' into dynamic-form-list-customization
Dec 1, 2023
e027b1a
Tweaks to code and test web part to accomodate changes made in #1625
Dec 1, 2023
3cd6f18
Merge pull request #1672 from t0mgerman/dynamic-form-list-customization
AJIXuMuK Dec 2, 2023
96adfe3
changelog
AJIXuMuK Dec 2, 2023
6352e5a
pre-commit
AJIXuMuK Dec 2, 2023
56afb24
view picker in docs
AJIXuMuK Dec 2, 2023
17d2d2b
#1715 fixed the disable issue on field override control when "onBefor…
Dec 4, 2023
e852e18
Fix #1719
GuidoZam Dec 16, 2023
1c50fa8
Merge pull request #1725 from GuidoZam/fix-iconify-react-dependency
joelfmrodrigues Dec 21, 2023
085381f
changelog
joelfmrodrigues Dec 21, 2023
4a24d81
release notes
joelfmrodrigues Dec 21, 2023
0314111
Merge v3.16.1 release into dev
michaelmaillot Jan 7, 2024
286854e
Merge branch 'dev' into peoplepicker-resultFilter
joelfmrodrigues Jan 8, 2024
a2e97d5
Merge pull request #1673 from GuidoZam/peoplepicker-resultFilter
joelfmrodrigues Jan 8, 2024
b69815e
changelog
joelfmrodrigues Jan 8, 2024
d63b92b
release notes
joelfmrodrigues Jan 8, 2024
1d282a3
Fixing the bugfix #1718
IRRDC Jan 11, 2024
7796507
Updating PR #1736: Removed useless second default case
IRRDC Jan 16, 2024
0065dab
Merge remote-tracking branch 'upstream/dev' into dev
IRRDC Jan 16, 2024
76bc8fd
Restoring changes removed by merge
IRRDC Jan 17, 2024
d58bb93
Merge pull request #1736 from IRRDC/dev
michaelmaillot Jan 18, 2024
e2d3983
Fixing multi taxonomy field (loading + saving existing item)
michaelmaillot Jan 19, 2024
5e1fd37
Update package-lock.json following PR #1725
michaelmaillot Jan 19, 2024
9aa101f
Fixing Issue - 1669 - PeoplePicker returns no results with webAbsolut…
NishkalankBezawada Jan 23, 2024
618e21d
Merge pull request #1704 from lafe/MissingTaxonomyPickerSuggestions-1688
joelfmrodrigues Jan 30, 2024
a9182ed
changelog
jrodriguesStorm Jan 30, 2024
c15a91c
Merge branch 'feature/rich-text-align-heading-styles-with-sharepoint-…
jrodriguesStorm Jan 30, 2024
4dc5f51
git push origin devMerge branch 'mbice-feature/rich-text-align-headin…
jrodriguesStorm Jan 30, 2024
b7806cf
Merge pull request #1706 from mbice/feature/rich-text-align-heading-s…
joelfmrodrigues Jan 30, 2024
cebde1a
Merge branch 'dev' of https://github.com/SharePoint/sp-dev-fx-control…
jrodriguesStorm Jan 30, 2024
5b3e93c
changelog
jrodriguesStorm Jan 30, 2024
e1dccf2
Merge pull request #1713 from pnp/dependabot/npm_and_yarn/dev/types/l…
joelfmrodrigues Jan 30, 2024
dbd91d6
Merge pull request #1716 from wuxiaojun514/dev
joelfmrodrigues Jan 30, 2024
72de471
changelog
jrodriguesStorm Jan 30, 2024
cf2a4d2
Merge pull request #1742 from NishkalankBezawada/Issue-1669-New
michaelmaillot Feb 3, 2024
17afeaf
Merge branch 'dev' of https://github.com/pnp/sp-dev-fx-controls-react…
michaelmaillot Feb 3, 2024
bfa8a5e
Update release notes + changelog following PR #1742
michaelmaillot Feb 3, 2024
bb9bda4
Merge pull request #1739 from pnp/fix/dynamicform-taxonomy-multi
michaelmaillot Feb 5, 2024
3d7c7de
Update release notes + changelog following PR #1739
michaelmaillot Feb 5, 2024
289b059
Merge branch 'master' of https://github.com/pnp/sp-dev-fx-controls-re…
joelfmrodrigues Feb 6, 2024
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
6 changes: 5 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,11 @@ obj
*.tgz

# VSCode
.vscode
.vscode/*

# Included VSCode files
!.vscode/example-tasks.json
!.vscode/example-launch.json

# Documentation
docs/documentation/site
Expand Down
44 changes: 44 additions & 0 deletions .vscode/example-launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
{
/**
* Populate and rename this file to launch.json to configure debugging
*/
"version": "0.2.0",
"configurations": [
{
"name": "Hosted workbench (chrome)",
"type": "chrome",
"request": "launch",
"url": "https://enter-your-SharePoint-site.sharepoint.com/sites/mySite/_layouts/15/workbench.aspx",
"webRoot": "${workspaceRoot}",
"sourceMaps": true,
"sourceMapPathOverrides": {
"webpack:///.././src/*": "${webRoot}/src/*",
"webpack:///../../../src/*": "${webRoot}/src/*",
"webpack:///../../../../src/*": "${webRoot}/src/*",
"webpack:///../../../../../src/*": "${webRoot}/src/*"
},
"preLaunchTask": "npm: serve",
"runtimeArgs": [
"--remote-debugging-port=9222",
]
},
{
"name": "Hosted workbench (edge)",
"type": "edge",
"request": "launch",
"url": "https://enter-your-SharePoint-site.sharepoint.com/sites/mySite/_layouts/15/workbench.aspx",
"webRoot": "${workspaceRoot}",
"sourceMaps": true,
"sourceMapPathOverrides": {
"webpack:///.././src/*": "${webRoot}/src/*",
"webpack:///../../../src/*": "${webRoot}/src/*",
"webpack:///../../../../src/*": "${webRoot}/src/*",
"webpack:///../../../../../src/*": "${webRoot}/src/*"
},
"preLaunchTask": "npm: serve",
"runtimeArgs": [
"--remote-debugging-port=9222",
]
},
]
}
30 changes: 30 additions & 0 deletions .vscode/example-tasks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
{
/**
* Populate and rename this file to launch.json to configure debugging
*/
"version": "2.0.0",
"tasks": [
{
"type": "npm",
"script": "serve",
"isBackground": true,
"problemMatcher": {
"owner": "custom",
"pattern": {
"regexp": "."
},
"background": {
"activeOnStart": true,
"beginsPattern": "Starting 'bundle'",
"endsPattern": "\\[\\sFinished\\s\\]"
}
},
"label": "npm: serve",
"detail": "gulp bundle --custom-serve --max_old_space_size=4096 && fast-serve",
"group": {
"kind": "build",
"isDefault": true
}
},
]
}
28 changes: 28 additions & 0 deletions CHANGELOG.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,33 @@
{
"versions": [
{
"version": "3.17.0",
"changes":{
"new": [],
"enhancements": [
"`DyanmicForm`: Added file handling [#1625](https://github.com/pnp/sp-dev-fx-controls-react/pull/1625)",
"`DynamicForm`: Custom Formatting and Validation, ControlsTestWebPart updates [#1672](https://github.com/pnp/sp-dev-fx-controls-react/pull/1672)",
"`PeoplePicker`: Added custom filter to PeoplePicker selection [#1657](https://github.com/pnp/sp-dev-fx-controls-react/issues/1657)",
"`RichText`: Align RichText heading styles and font sizes with OOB SharePoint text web part [#1706](https://github.com/pnp/sp-dev-fx-controls-react/pull/1706)"
],
"fixes": [
"Build fails due to missing @iconify/react dependency after upgrade to 3.16.0 [#1719](https://github.com/pnp/sp-dev-fx-controls-react/issues/1719)",
"`ModernTaxonomyPicker`: not displaying suggestions when typing in values - API not found error [#1688](https://github.com/pnp/sp-dev-fx-controls-react/issues/1688)",
"`DynamicForm`: Disable issue on fieldOverrides field control when onBeforeSubmit return true [#1715](https://github.com/pnp/sp-dev-fx-controls-react/issues/1715)",
"`PeoplePicker`: PeoplePicker returns no results with webAbsoluteUrl and ensureUser [#1669](https://github.com/pnp/sp-dev-fx-controls-react/issues/1669)",
"`DynamicForm`: [DynamicForm] Fixing multi taxonomy field (loading + saving existing item) [#1739](https://github.com/pnp/sp-dev-fx-controls-react/pull/1739)"
]
},
"contributions": [
"[Guido Zambarda](https://github.com/GuidoZam)",
"[Lars Fernhomberg](https://github.com/lafe)",
"[Mark Bice](https://github.com/mbice)",
"[Michaël Maillot](https://github.com/michaelmaillot)",
"[Nishkalank Bezawada](https://github.com/NishkalankBezawada)",
"[Tom G](https://github.com/t0mgerman)",
"[wuxiaojun514](https://github.com/wuxiaojun514)"
]
},
{
"version": "3.16.2",
"changes": {
Expand Down
21 changes: 21 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,26 @@
# Releases

## 3.17.0

### Enhancements

- `DyanmicForm`: Added file handling [#1625](https://github.com/pnp/sp-dev-fx-controls-react/pull/1625)
- `DynamicForm`: Custom Formatting and Validation, ControlsTestWebPart updates [#1672](https://github.com/pnp/sp-dev-fx-controls-react/pull/1672)
- `PeoplePicker`: Added custom filter to PeoplePicker selection [#1657](https://github.com/pnp/sp-dev-fx-controls-react/issues/1657)
- `RichText`: Align RichText heading styles and font sizes with OOB SharePoint text web part [#1706](https://github.com/pnp/sp-dev-fx-controls-react/pull/1706)

### Fixes

- Build fails due to missing @iconify/react dependency after upgrade to 3.16.0 [#1719](https://github.com/pnp/sp-dev-fx-controls-react/issues/1719)
- `ModernTaxonomyPicker`: not displaying suggestions when typing in values - API not found error [#1688](https://github.com/pnp/sp-dev-fx-controls-react/issues/1688)
- `DynamicForm`: Disable issue on fieldOverrides field control when onBeforeSubmit return true [#1715](https://github.com/pnp/sp-dev-fx-controls-react/issues/1715)
- `PeoplePicker`: PeoplePicker returns no results with webAbsoluteUrl and ensureUser [#1669](https://github.com/pnp/sp-dev-fx-controls-react/issues/1669)
- `DynamicForm`: [DynamicForm] Fixing multi taxonomy field (loading + saving existing item) [#1739](https://github.com/pnp/sp-dev-fx-controls-react/pull/1739)

### Contributors

Special thanks to our contributors (in alphabetical order): [Guido Zambarda](https://github.com/GuidoZam), [Lars Fernhomberg](https://github.com/lafe), [Mark Bice](https://github.com/mbice), [Michaël Maillot](https://github.com/michaelmaillot), [Nishkalank Bezawada](https://github.com/NishkalankBezawada), [Tom G](https://github.com/t0mgerman), [wuxiaojun514](https://github.com/wuxiaojun514).

## 3.16.2

### Fixes
Expand Down
21 changes: 21 additions & 0 deletions docs/documentation/docs/about/release-notes.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,26 @@
# Releases

## 3.17.0

### Enhancements

- `DyanmicForm`: Added file handling [#1625](https://github.com/pnp/sp-dev-fx-controls-react/pull/1625)
- `DynamicForm`: Custom Formatting and Validation, ControlsTestWebPart updates [#1672](https://github.com/pnp/sp-dev-fx-controls-react/pull/1672)
- `PeoplePicker`: Added custom filter to PeoplePicker selection [#1657](https://github.com/pnp/sp-dev-fx-controls-react/issues/1657)
- `RichText`: Align RichText heading styles and font sizes with OOB SharePoint text web part [#1706](https://github.com/pnp/sp-dev-fx-controls-react/pull/1706)

### Fixes

- Build fails due to missing @iconify/react dependency after upgrade to 3.16.0 [#1719](https://github.com/pnp/sp-dev-fx-controls-react/issues/1719)
- `ModernTaxonomyPicker`: not displaying suggestions when typing in values - API not found error [#1688](https://github.com/pnp/sp-dev-fx-controls-react/issues/1688)
- `DynamicForm`: Disable issue on fieldOverrides field control when onBeforeSubmit return true [#1715](https://github.com/pnp/sp-dev-fx-controls-react/issues/1715)
- `PeoplePicker`: PeoplePicker returns no results with webAbsoluteUrl and ensureUser [#1669](https://github.com/pnp/sp-dev-fx-controls-react/issues/1669)
- `DynamicForm`: [DynamicForm] Fixing multi taxonomy field (loading + saving existing item) [#1739](https://github.com/pnp/sp-dev-fx-controls-react/pull/1739)

### Contributors

Special thanks to our contributors (in alphabetical order): [Guido Zambarda](https://github.com/GuidoZam), [Lars Fernhomberg](https://github.com/lafe), [Mark Bice](https://github.com/mbice), [Michaël Maillot](https://github.com/michaelmaillot), [Nishkalank Bezawada](https://github.com/NishkalankBezawada), [Tom G](https://github.com/t0mgerman), [wuxiaojun514](https://github.com/wuxiaojun514).

## 3.16.2

### Fixes
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
13 changes: 13 additions & 0 deletions docs/documentation/docs/controls/DynamicForm.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,17 @@ import { DynamicForm } from "@pnp/spfx-controls-react/lib/DynamicForm";
```
![DynamicForm](../assets/DynamicForm.png)

## File selection

To upload a file when creating a new document in a document library you need to specify:
- enableFileSelection: Set this parameter to true to enable file selection.
- contentTypeId: This parameter specifies the target content type ID of the document you are creating.
- supportedFileExtensions: This parameter is optional and is used to specify the supported file extensions if they are different from the default ones.

Enabling the file selection will display a new button on top of the form that allow the user to select a file from the recent files, browsing OneDrive or select and upload a file from the computer.

![DynamicFormWithFileSelection](../assets/DynamicFormWithFileSelection.png)

## Implementation

The `DynamicForm` can be configured with the following properties:
Expand All @@ -38,13 +49,15 @@ The `DynamicForm` can be configured with the following properties:
| contentTypeId | string | no | content type ID |
| disabled | boolean | no | Allows form to be disabled. Default value is `false`|
| disabledFields | string[] | no | InternalName of fields that should be disabled. Default value is `false`|
| enableFileSelection | boolean | no | Specify if the form should support the creation of a new list item in a document library attaching a file to it. This option is only available for document libraries and works only when the contentTypeId is specified and has a base type of type Document. Default value is `false`|
| hiddenFields | string[] | no | InternalName of fields that should be hidden. Default value is `false`|
| onListItemLoaded | (listItemData: any) => Promise<void> | no | List item loaded handler. Allows to access list item information after it's loaded.|
| onBeforeSubmit | (listItemData: any) => Promise<boolean> | no | Before submit handler. Allows to modify the object to be submitted or cancel the submission. To cancel, return `true`.|
| onSubmitted | (listItemData: any, listItem?: IItem) => void | no | Method that returns listItem data JSON object and PnPJS list item instance (`IItem`). |
| onSubmitError | (listItemData: any, error: Error) => void | no | Handler of submission error. |
| onCancelled | () => void | no | Handler when form has been cancelled. |
| returnListItemInstanceOnSubmit | boolean | no | Specifies if `onSubmitted` event should pass PnPJS list item (`IItem`) as a second parameter. Default - `true` |
| supportedFileExtensions | string[] | no | Specify the supported file extensions for the file picker. Only used when enableFileSelection is `true`. Default value is `["docx", "doc", "pptx", "ppt", "xlsx", "xls", "pdf"]`. |
| webAbsoluteUrl | string | no | Absolute Web Url of target site (user requires permissions). |
| fieldOverrides | {[columnInternalName: string] : {(fieldProperties: IDynamicFieldProps): React.ReactElement\<IDynamicFieldProps\>}} | no | Key value pair for fields you want to override. Key is the internal field name, value is the function to be called for the custom element to render. |
| respectEtag | boolean | no | Specifies if the form should respect the ETag of the item. Default - `true` |
Expand Down
1 change: 1 addition & 0 deletions docs/documentation/docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,7 @@ The following controls are currently available:
- [TreeView](./controls/TreeView) (Tree View)
- [UploadFiles](./controls/UploadFiles) (Upload Files)
- [VariantThemeProvider](./controls/VariantThemeProvider) (Variant Theme Provider)
- [ViewPicker](./controls/ViewPicker.md) (View Picker Control)
- [WebPartTitle](./controls/WebPartTitle) (Customizable web part title control)


Expand Down
1 change: 1 addition & 0 deletions docs/documentation/mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ nav:
- TreeView: 'controls/TreeView.md'
- UploadFiles: 'controls/UploadFiles.md'
- VariantThemeProvider: 'controls/VariantThemeProvider.md'
- ViewPicker: 'controls/ViewPicker.md'
- WebPartTitle: 'controls/WebPartTitle.md'
- 'Field Controls':
- 'Getting started': 'controls/fields/main.md'
Expand Down
Loading
Loading