Skip to content

Commit d8124c5

Browse files
authored
Merge pull request #1000 from pnp/v2-dev
v2.9.0 merge
2 parents 5e1531e + 05a3fe8 commit d8124c5

34 files changed

+489
-128
lines changed

CHANGELOG.JSON

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,32 @@
11
{
22
"versions": [
3+
{
4+
"version": "2.9.0",
5+
"changes": {
6+
"new": [],
7+
"enhancements": [
8+
"`FilePicker`: spanish translation for Stock Images labels [#946](https://github.com/pnp/sp-dev-fx-controls-react/pull/946)",
9+
"`FilePicker`: Add support for a defaultFolderAbsolutePath prop [#947](https://github.com/pnp/sp-dev-fx-controls-react/pull/947)",
10+
"`DynamicForm`: Returning PnPJS `IItem` in `onSubmitted` event based on `returnListItemInstanceOnSubmit` property [#944](https://github.com/pnp/sp-dev-fx-controls-react/pull/944)",
11+
"`DateTimePicker`: Add property for minutes dropdown increment [#939](https://github.com/pnp/sp-dev-fx-controls-react/issues/939)",
12+
"`DynamicForm`: Principal Types support [#956](https://github.com/pnp/sp-dev-fx-controls-react/pull/956)",
13+
"`Dynamic Form`: Show field descriptions [#975](https://github.com/pnp/sp-dev-fx-controls-react/issues/975)"
14+
],
15+
"fixes": [
16+
"`RichText`: Image button is checked when hyperlink is added to the text [#948](https://github.com/pnp/sp-dev-fx-controls-react/issues/948)",
17+
"`RichText`: impossible to display link with the text equal to the url [#949](https://github.com/pnp/sp-dev-fx-controls-react/issues/949)",
18+
"`ComboBoxListItemPicker`: defaultSelectedItems not working [#954](https://github.com/pnp/sp-dev-fx-controls-react/issues/954)",
19+
"`PeoplePicker`: Default selected items for groups [#958](https://github.com/pnp/sp-dev-fx-controls-react/issues/958)"
20+
]
21+
},
22+
"contributions": [
23+
"[Alexey Morozov](https://github.com/a1exymoroz)",
24+
"[Daniel Stratton](https://github.com/gobigfoot)",
25+
"[Ketill Antoníus Ágústsson](https://github.com/Katli95)",
26+
"[Ravichandran Krishnasamy](https://github.com/ravichandran-blog)",
27+
"[Sergio Ortega Martín](https://github.com/sortegamartin)"
28+
]
29+
},
330
{
431
"version": "2.8.0",
532
"changes": {

CHANGELOG.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,27 @@
11
# Releases
22

3+
## 2.9.0
4+
5+
### Enhancements
6+
7+
- `FilePicker`: spanish translation for Stock Images labels [#946](https://github.com/pnp/sp-dev-fx-controls-react/pull/946)
8+
- `FilePicker`: Add support for a defaultFolderAbsolutePath prop [#947](https://github.com/pnp/sp-dev-fx-controls-react/pull/947)
9+
- `DynamicForm`: Returning PnPJS `IItem` in `onSubmitted` event based on `returnListItemInstanceOnSubmit` property [#944](https://github.com/pnp/sp-dev-fx-controls-react/pull/944)
10+
- `DateTimePicker`: Add property for minutes dropdown increment [#939](https://github.com/pnp/sp-dev-fx-controls-react/issues/939)
11+
- `DynamicForm`: Principal Types support [#956](https://github.com/pnp/sp-dev-fx-controls-react/pull/956)
12+
- `Dynamic Form`: Show field descriptions [#975](https://github.com/pnp/sp-dev-fx-controls-react/issues/975)
13+
14+
### Fixes
15+
16+
- `RichText`: Image button is checked when hyperlink is added to the text [#948](https://github.com/pnp/sp-dev-fx-controls-react/issues/948)
17+
- `RichText`: impossible to display link with the text equal to the url [#949](https://github.com/pnp/sp-dev-fx-controls-react/issues/949)
18+
- `ComboBoxListItemPicker`: defaultSelectedItems not working [#954](https://github.com/pnp/sp-dev-fx-controls-react/issues/954)
19+
- `PeoplePicker`: Default selected items for groups [#958](https://github.com/pnp/sp-dev-fx-controls-react/issues/958)
20+
21+
### Contributors
22+
23+
Special thanks to our contributors (in alphabetical order): [Alexey Morozov](https://github.com/a1exymoroz), [Daniel Stratton](https://github.com/gobigfoot), [Ketill Antoníus Ágústsson](https://github.com/Katli95), [Ravichandran Krishnasamy](https://github.com/ravichandran-blog), [Sergio Ortega Martín](https://github.com/sortegamartin).
24+
325
## 2.8.0
426

527
### New control(s)

docs/documentation/docs/about/release-notes.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,27 @@
11
# Releases
22

3+
## 2.9.0
4+
5+
### Enhancements
6+
7+
- `FilePicker`: spanish translation for Stock Images labels [#946](https://github.com/pnp/sp-dev-fx-controls-react/pull/946)
8+
- `FilePicker`: Add support for a defaultFolderAbsolutePath prop [#947](https://github.com/pnp/sp-dev-fx-controls-react/pull/947)
9+
- `DynamicForm`: Returning PnPJS `IItem` in `onSubmitted` event based on `returnListItemInstanceOnSubmit` property [#944](https://github.com/pnp/sp-dev-fx-controls-react/pull/944)
10+
- `DateTimePicker`: Add property for minutes dropdown increment [#939](https://github.com/pnp/sp-dev-fx-controls-react/issues/939)
11+
- `DynamicForm`: Principal Types support [#956](https://github.com/pnp/sp-dev-fx-controls-react/pull/956)
12+
- `Dynamic Form`: Show field descriptions [#975](https://github.com/pnp/sp-dev-fx-controls-react/issues/975)
13+
14+
### Fixes
15+
16+
- `RichText`: Image button is checked when hyperlink is added to the text [#948](https://github.com/pnp/sp-dev-fx-controls-react/issues/948)
17+
- `RichText`: impossible to display link with the text equal to the url [#949](https://github.com/pnp/sp-dev-fx-controls-react/issues/949)
18+
- `ComboBoxListItemPicker`: defaultSelectedItems not working [#954](https://github.com/pnp/sp-dev-fx-controls-react/issues/954)
19+
- `PeoplePicker`: Default selected items for groups [#958](https://github.com/pnp/sp-dev-fx-controls-react/issues/958)
20+
21+
### Contributors
22+
23+
Special thanks to our contributors (in alphabetical order): [Alexey Morozov](https://github.com/a1exymoroz), [Daniel Stratton](https://github.com/gobigfoot), [Ketill Antoníus Ágústsson](https://github.com/Katli95), [Ravichandran Krishnasamy](https://github.com/ravichandran-blog), [Sergio Ortega Martín](https://github.com/sortegamartin).
24+
325
## 2.8.0
426

527
### New control(s)

docs/documentation/docs/controls/DateTimePicker.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,7 @@ The `DateTimePicker` control can be configured with the following properties:
7171
| placeholder | string | no | Placeholder text for the DatePicker. |
7272
| maxDate | Date | no | The maximum allowable date. |
7373
| minDate | Date | no | The minimum allowable date. |
74+
| minutesIncrementStep | MinutesIncrement | no | Specifies minutes' increment step for `TimeDisplayControlType.Dropdow` |
7475

7576
Enum `TimeDisplayControlType`
7677

@@ -103,4 +104,9 @@ Interface `IDateTimePickerStrings` extends [IDatePickerStrings](https://develope
103104
| amDesignator | string | no | Used as AM designator when 12-hour clock is used. |
104105
| pmDesignator | string | no | Used as PM designator when 12-hour clock is used. |
105106

107+
Type `MinutesIncrement`
108+
```typescript
109+
type MinutesIncrement = 1 | 5 | 10 | 15 | 30;
110+
```
111+
106112
![](https://telemetry.sharepointpnp.com/sp-dev-fx-controls-react/wiki/controls/DateTimePicker)

docs/documentation/docs/controls/DynamicForm.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ This control can dynamically generate SharePoint list or SharePoint document lib
88
- Import the following modules to your component:
99

1010
```TypeScript
11-
import { DynamicForm } from "fx-controls-react/lib/DynamicForm";
11+
import { DynamicForm } from "@pnp/spfx-controls-react/lib/DynamicForm";
1212
```
1313

1414
- Use the DynamicForm control in your code as follows:
@@ -38,6 +38,7 @@ The `DynamicForm` can be configured with the following properties:
3838
| contentTypeId | string | no | content type ID |
3939
| disabled | boolean | no | Option allow to be enable or disable. Default value is `false`|
4040
| onBeforeSubmit | (listItemData: any) => Promise<boolean> | no | Before submit handler. Allows to modify the object to be submitted or cancel the submission. |
41-
| onSubmitted | (listItem: any) => void | no | Method that returns listItem data JSON object. |
41+
| onSubmitted | (listItemData: any, listItem?: IItem) => void | no | Method that returns listItem data JSON object and PnPJS list item instance (`IItem`). |
4242
| onSubmitError | (listItemData: any, error: Error) => void | no | Handler of submission error. |
4343
| onCancelled | () => void | no | Handler when form has been cancelled. |
44+
| returnListItemInstanceOnSubmit | boolean | no | Specifies if `onSubmitted` event should pass PnPJS list item (`IItem`) as a second parameter. Default - `true` |

docs/documentation/docs/controls/FilePicker.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,8 @@ The FilePicker component can be configured with the following properties:
7575
| label | string | no | Specifies the text describing the file picker. |
7676
| buttonLabel | string | no | Specifies the label of the file picker button. |
7777
| buttonIcon | string | no | In case it is provided the file picker will be rendered as an action button. |
78-
buttonIconProps | IIconProps | no | In case it is provided the file picker will be rendered as an Icon the and all can define Properties for Icon |
78+
| buttonIconProps | IIconProps | no | In case it is provided the file picker will be rendered as an Icon the and all can define Properties for Icon |
79+
| defaultFolderAbsolutePath | string | no | Optional string parameter to set a default active folder/library for the SiteFilesTab. E.g. `"https://contoso.sharepoint.com/teams/siteName/documentLibrary/Folder 1/SubFolder 1"` |
7980
| onSave | (filePickerResult: IFilePickerResult[]) => void | yes | Handler when the file has been selected and picker has been closed. |
8081
| onChange | (filePickerResult: IFilePickerResult[]) => void | no | Handler when the file selection has been changed. |
8182
| onCancel | () => void | no | Handler when file picker has been cancelled. |

package-lock.json

Lines changed: 5 additions & 13 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "@pnp/spfx-controls-react",
33
"description": "Reusable React controls for SharePoint Framework solutions",
4-
"version": "2.8.0",
4+
"version": "2.9.0",
55
"engines": {
66
"node": ">=10"
77
},

src/common/telemetry/version.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
export const version: string = "2.8.0";
1+
export const version: string = "2.9.0";

src/controls/dateTimePicker/DateTimePicker.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,8 @@ export class DateTimePicker extends React.Component<IDateTimePickerProps, IDateT
211211
placeholder,
212212
showLabels,
213213
minDate,
214-
maxDate
214+
maxDate,
215+
minutesIncrementStep
215216
} = this.props;
216217

217218
const hours: number = value != null ? value.getHours() : this.state.hours;
@@ -242,6 +243,7 @@ export class DateTimePicker extends React.Component<IDateTimePickerProps, IDateT
242243
<div className={styles.picker}>
243244
<MinutesComponent disabled={disabled}
244245
value={minutes}
246+
minutesIncrementStep={minutesIncrementStep}
245247
onChange={this.dropdownMinutesChanged}
246248
timeDisplayControlType={timeDisplayControlType || TimeDisplayControlType.Text} />
247249
</div>

0 commit comments

Comments
 (0)