Skip to content

Commit 364512a

Browse files
authored
Merge pull request #6532 from AndyButland/forms/release-13.3-14.1
Release notes and additional documentation for Forms 13.3 and 14.2.
2 parents 7c602a2 + d0a3af6 commit 364512a

File tree

32 files changed

+620
-61
lines changed

32 files changed

+620
-61
lines changed

13/umbraco-forms/developer/configuration/README.md

Lines changed: 47 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,12 @@ For illustration purposes, the following structure represents the full set of op
5757
"AutocompleteAttribute": "",
5858
"DaysToRetainSubmittedRecordsFor": 0,
5959
"DaysToRetainApprovedRecordsFor": 0,
60-
"DaysToRetainRejectedRecordsFor": 0
60+
"DaysToRetainRejectedRecordsFor": 0,
61+
"ShowPagingOnMultiPageForms": "None",
62+
"PagingDetailsFormat": "Page {0} of {1}",
63+
"PageCaptionFormat": "Page {0}",
64+
"ShowSummaryPageOnMultiPageForms": false,
65+
"SummaryLabel": "Summary of Entry"
6166
},
6267
"RemoveProvidedEmailTemplate": false,
6368
"RemoveProvidedFormTemplates": false,
@@ -88,7 +93,8 @@ For illustration purposes, the following structure represents the full set of op
8893
"UseSemanticFieldsetRendering": false,
8994
"DisableClientSideValidationDependencyCheck": false,
9095
"DisableRelationTracking": false,
91-
"TrackRenderedFormsStorageMethod": "TempData"
96+
"TrackRenderedFormsStorageMethod": "TempData",
97+
"EnableMultiPageFormSettings": false
9298
},
9399
"Security": {
94100
"DisallowedFileUploadExtensions": "config,exe,dll,asp,aspx",
@@ -104,7 +110,9 @@ For illustration purposes, the following structure represents the full set of op
104110
},
105111
"FieldTypes": {
106112
"DatePicker": {
107-
"DatePickerYearRange": 10
113+
"DatePickerYearRange": 10,
114+
"DatePickerFormat": "LL",
115+
"DatePickerFormatForValidation": ""
108116
},
109117
"Recaptcha2": {
110118
"PublicKey": "",
@@ -305,6 +313,26 @@ Applies as per `DaysToRetainSubmittedRecordsFor` but for records in the 'approve
305313

306314
Applies as per `DaysToRetainSubmittedRecordsFor` but for records in the 'rejected' state.
307315

316+
### ShowPagingOnMultiPageForms
317+
318+
Defines whether and where paging details are displayed for multi-page forms.
319+
320+
### PagingDetailsFormat
321+
322+
Defines the paging details format for multi-page forms.
323+
324+
### PageCaptionFormat
325+
326+
Defines the page caption format for multi-page forms.
327+
328+
### ShowSummaryPageOnMultiPageForms
329+
330+
Defines whether summary pages are on by default for multi-page forms.
331+
332+
### SummaryLabel
333+
334+
Defines the default summary label for multi-page forms.
335+
308336
## Package options configuration
309337

310338
### IgnoreWorkFlowsOnEdit
@@ -420,6 +448,14 @@ To switch to this storage mechanism change the value of this setting from the de
420448

421449
We expect `HttpContextItems` to be the default option from Forms 14 onwards.
422450

451+
## EnableMultiPageFormSettings
452+
453+
This setting determines whether [multi-page form settings](../../editor/creating-a-form/form-settings.md#multi-page-forms) are available to editors.
454+
455+
By default the value is `false`. This ensures that, in an upgrade scenario, before the feature is used the necessary styling and/or theme updates can be prepared.
456+
457+
To make the feature available to editors set the value to `true`.
458+
423459
## Security configuration
424460

425461
### DisallowedFileUploadExtensions
@@ -484,6 +520,14 @@ For more information, see the [Headless/AJAX Forms](../ajaxforms.md) article.
484520

485521
This setting is used to configure the Date Picker form field range of years that is available in the date picker. By default this is a small range of 10 years.
486522

523+
#### DatePickerFormat
524+
525+
A custom date format can be provided in [momentjs format](https://momentjscom.readthedocs.io/en/latest/moment/01-parsing/03-string-format/) if you want to override the default.
526+
527+
#### DatePickerFormatForValidation
528+
529+
If a custom date format is provided it will be used on the client-side. A matching string in [C# date format](https://learn.microsoft.com/en-us/dotnet/standard/base-types/custom-date-and-time-format-strings) should be provided, so that server-side validation will match the expected format of the entry.
530+
487531
### reCAPTCHA v2 field type configuration
488532

489533
#### PublicKey & PrivateKey

13/umbraco-forms/developer/configuration/type-details.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,8 @@ The intention is to be able to make available details such as IDs, aliases and p
5252
**Settings:**
5353

5454
* `Placeholder`
55+
* `ShowLabel`
56+
* `AriaLabel`
5557

5658
</details>
5759

@@ -502,6 +504,7 @@ The intention is to be able to make available details such as IDs, aliases and p
502504
* `UseCurrentPage`
503505
* `DocType`
504506
* `ValueField`
507+
* `CaptionField`
505508
* `ListGrandChildren`
506509
* `OrderBy`
507510

13/umbraco-forms/developer/extending/adding-a-fieldtype.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,16 @@ If working with Umbraco 9 or earlier versions, you'll find the `Views\Partials\F
106106

107107
For Umbraco 10 and above, we've moved to [distributing the theme as part of a Razor Class Library](../../upgrading/version-specific.md#views-and-client-side-files) so the folder won't exist. However, you can create it for your custom field type. If you would like to reference the partial views of the default theme, you can download them as mentioned in the [Themes](../themes.md) article.
108108

109+
### Read-only partial view
110+
111+
When rendering a multi-page form, editors have the option to display a summary page where the entries can be viewed before submitting.
112+
113+
To support this, a read-only view of the field is necessary.
114+
115+
For most fields, nothing is required here, as the default read-only display defined in the built-in `ReadOnly.cshtml` file suffices.
116+
117+
However, if you want to provide a custom read-only display for your field, you can do so by creating a second partial view. This should be named with a `.ReadOnly` suffix. For this example, you would create `FieldType.Slider.ReadOnly.cshtml`.
118+
109119
## Umbraco backoffice view
110120

111121
The final step involves building the HTML view which will be rendered in Umbraco as an example of how our end result will look:

13/umbraco-forms/developer/security.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ Within the _Form Security_ tree, each user with a backoffice account is listed.
1313
* _Manage forms_ - user can create and edit form definitions
1414
* _View entries_ - user can view the submitted entries
1515
* _Edit entries_ - user can edit the submitted entries
16+
* _Delete entries_ - user can delete the submitted entries
1617
* _Manage datasources_ - user can create and edit datasource definitions
1718
* _Manage prevalue sources_ - user can create and edit prevalue source definitions
1819

13/umbraco-forms/developer/themes.md

Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,78 @@ Umbraco Forms conditional JavaScript logic depends on some CSS classes currently
4141

4242
If adding or amending client-side scripts, you need to copy the `Script.cshtml` file from the `default` themes folder. In your copy, amend the `.js` references to reference your own script files.
4343

44+
### Shipping Themes in a Razor Class Library
45+
46+
Umbraco Forms provides it's built-in themes as part of a Razor Class Library for ease of distribution. This can be useful for custom themes, particularly those used in multiple solutions or released as an Umbraco package.
47+
48+
From Forms 13.3 it is possible to do this for custom themes.
49+
50+
1. Create a new Razor Class Library project to hold the theme.
51+
2. Create the necessary Partial Views for your theme within `Views\Partials\Forms\Themes\<my-custom-theme>`.
52+
3. Provide the names of the files in your theme via an implementation of `ITheme`.
53+
* For example, if only overriding a single file, your class would look like the code snippet below:
54+
55+
```csharp
56+
using Umbraco.Forms.Core.Interfaces;
57+
58+
public class MyCustomTheme : ITheme
59+
{
60+
private const string FilePathFormat = "{0}/{1}/{2}.cshtml";
61+
62+
public virtual string Name => "my-custom-theme";
63+
64+
public virtual IEnumerable<string> Files =>
65+
[
66+
string.Format(FilePathFormat, Core.Constants.System.ThemesPath, Name, "FieldTypes/FieldType.Textfield"),
67+
];
68+
}
69+
```
70+
71+
4. Register the themes you want to use via a composer:
72+
73+
```csharp
74+
public class MyComposer : IComposer
75+
{
76+
public void Compose(IUmbracoBuilder builder)
77+
{
78+
builder.Themes()
79+
.Add<MyCustomTheme>();
80+
}
81+
}
82+
```
83+
84+
Your theme will now be available in the Theme Picker and the partial view files will be used when rendering forms.
85+
86+
#### Email Templates
87+
88+
Email templates provided for the send email workflow can be provided in a Razor Class Library similar to the Theme files.
89+
90+
The partial view will be created in `Views\Partials\Forms\Emails`.
91+
92+
It's made available via an implementation of `IEmailTemplate`:
93+
94+
```csharp
95+
using Umbraco.Forms.Core.Interfaces;
96+
97+
public class MyCustomEmailTemplate : IEmailTemplate
98+
{
99+
public virtual string FileName => "My-Custom-Email-Template.cshtml";
100+
}
101+
```
102+
103+
And registered with:
104+
105+
```csharp
106+
public class MyComposer : IComposer
107+
{
108+
public void Compose(IUmbracoBuilder builder)
109+
{
110+
builder.EmailTemplates()
111+
.Add<MyCustomEmailTemplate>();
112+
}
113+
}
114+
```
115+
44116
## Using a Theme
45117

46118
To use a theme with a Form use the "Insert Form" macro where you will be presented with the options of the form you wish to insert along with an option to pick a theme. This displays the list of theme folders found at `Views/Partials/Forms/Themes`.

13/umbraco-forms/editor/creating-a-form/fieldtypes/date.md

Lines changed: 3 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -4,28 +4,15 @@ The date picker uses a front-end library called [Pikaday](https://github.com/dbu
44

55
![Date picker on frontend](images/date-picker.png)
66

7-
Pikaday date picker can be localised based on the page the Form is rendered on.
7+
Pikaday date picker can be localized based on the page the Form is rendered on.
88

99
The date picker displays the picked date in the required locale. Using JavaScript, a hidden field is updated with a standard date format to send to the server for storing record submissions. This avoids the locale mixing up the dates.
1010

1111
To achieve localized date, a Razor partial view is included at `/Views/Partials/Forms/Themes/default/DatePicker.cshtml`.
1212

1313
The **DatePicker.cshtml** includes the `moment-with-locales.min.js` library to help with the date locale formatting and the appropriate changes to Pikaday to support the locales. If you wish to use a different DatePicker component, edit the **DatePicker.cshtml** file as per your needs.
1414

15-
## Configure the Year range
15+
## Configure the date picker
1616

17-
The Date picker has a configuration setting to control the number of years shown in the picker. The default value is 10 years.
17+
The Date picker has [configuration settings](../../../developer/configuration/README.md#date-picker-field-type-configuration) to control the number of years shown in the picker and the date format.
1818

19-
You can configure the settings in the `appSettings.json` file:
20-
21-
```json
22-
"Forms": {
23-
"FieldTypes": {
24-
"DatePicker": {
25-
"DatePickerYearRange": 10
26-
}
27-
}
28-
}
29-
```
30-
31-
Update `DatePickerYearRange` to a higher number (for example: 100) to increase the numbers of years available in the Date picker.

13/umbraco-forms/editor/creating-a-form/form-settings.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,24 @@ The autocomplete setting for the overall form can be changed from the default of
5757

5858
<figure><img src="images/FormSettingsAutocomplete.png" alt=""><figcaption><p>Form Settings Autocomplete</p></figcaption></figure>
5959

60+
### Multi-page forms
61+
62+
The settings available in this section allow you to customize how multi-page forms are presented to site visitors.
63+
64+
<figure><img src="images/multi-page-forms.png" alt=""><figcaption><p>Multi-Page Form Settings</p></figcaption></figure>
65+
66+
| Option | Description |
67+
| -------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
68+
| **Paging display** | Select whether paging information is displayed at the top and/or bottom of the form. |
69+
| **Paging display format** | Provide a format string for the paging details. By default `Page {0} of {1}` is used which will be replaced as, for example, `Page 1 of 4`. |
70+
| **Page caption format** | Provide a format string for rendering the page captions. By default `Page {0}` is used which will be replaced as, for example, `Page 1`. If a caption for the page has been provided, it will be used instead. |
71+
| **Show summary page** | Select whether a summary page is displayed at the end of multi-page forms, where a user can review their entry before submitting. |
72+
| **Summary heading** | Provide the heading for the summary page. |
73+
74+
{% hint style="info" %}
75+
These options will only be available if [the feature is configured for display](../../developer/configuration/README.md#enablemultipageformsettings).
76+
{% endhint %}
77+
6078
### Moderation
6179

6280
Enabling this feature allows the moderator to manage the approval status of a form. This can be used in a number of scenarios. For example, if the form submission will be publicly shown, you can control which are published.
25.4 KB
Loading

13/umbraco-forms/release-notes.md

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,36 @@ If you are upgrading to a new major version, you can find information about the
1717

1818
This section contains the release notes for Umbraco Forms 13 including all changes for this version.
1919

20+
#### [**13.3.0-rc1**](https://github.com/umbraco/Umbraco.Forms.Issues/issues?q=is%3Aissue+is%3Aclosed+label%3Arelease%2F13.3.0) **(October 25th 2024)**
21+
22+
##### Multi-step forms
23+
24+
The 13.3 release of Forms contains features that can improve the user experience of completing multi-page forms.
25+
26+
We have added the option for [editors to choose to display paging details on the forms](./editor/creating-a-form/form-settings.md#multi-page-forms). This will allow those completing forms to get a better understanding of progress as well as see details of the pages still to be completed. [#281](https://github.com/umbraco/Umbraco.Forms.Issues/issues/281) [#648](https://github.com/umbraco/Umbraco.Forms.Issues/issues/648).
27+
28+
These options are enabled and configured by editors in the Forms settings section on a per-form basis. We also provide a [configuration-based toggle for the feature as a whole](./developer/configuration/README.md#enablemultipageformsettings). In this way, editors can be given access to use the feature only once the styling or theme is prepared.
29+
30+
##### Ship themes in Razor Class Libraries
31+
32+
Forms ships it's themes and email templates as part of a razor class library for ease of distribution. With this release we make that feature [available to your own custom themes and templates](./developer/themes.md#shipping-themes-in-a-razor-class-library) (or those created by package developers) [#795](https://github.com/umbraco/Umbraco.Forms.Issues/issues/795).
33+
34+
##### Date picker field type
35+
36+
We have made a couple of updates to the Date Picker field type. The format for the field can now be provided in configuration [#1276](https://github.com/umbraco/Umbraco.Forms.Issues/issues/1276). And you can now override and localize the aria-label provided for assistive technologies such as screen readers [https://github.com/umbraco/Umbraco.Forms.Issues/issues/1082](https://github.com/umbraco/Umbraco.Forms.Issues/issues/1082).
37+
38+
##### Finer grained entries permissions
39+
40+
To allow finer control over editor permissions, we have introduced a "delete entries" setting for users and user groups. Thus you can now give editors explicit permissions to view, edit, or delete entries [#1303](https://github.com/umbraco/Umbraco.Forms.Issues/issues/1303).
41+
42+
##### Other
43+
44+
Other bug fixes included in the release:
45+
46+
* Fix issue with single checkbox triggering a condition on a field on a subsequent page [#1304](https://github.com/umbraco/Umbraco.Forms.Issues/issues/1304).
47+
* Improve cross-platform check when exporting to Excel.
48+
* Fixed issue where sensitive data flag on a field could not be set for new fields added to a form [#1309](https://github.com/umbraco/Umbraco.Forms.Issues/issues/1309).
49+
2050
#### [**13.2.5**](https://github.com/umbraco/Umbraco.Forms.Issues/issues?q=is%3Aissue+is%3Aclosed+label%3Arelease%2F13.2.5) **(October 3rd 2024)**
2151

2252
* Handled "chunked" authentication cookie in protection of file uploads saved in the media file system [#11](https://github.com/umbraco/Umbraco.Forms.Issues/issues/11#issuecomment-2376788751).

14/umbraco-forms/SUMMARY.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@
3434

3535
## Developer
3636

37+
* [Property Editors](developer/property-editors.md)
3738
* [Preparing Your Frontend](developer/prepping-frontend.md)
3839
* [Rendering Forms](developer/rendering-forms.md)
3940
* [Rendering Forms Scripts](developer/rendering-scripts.md)

0 commit comments

Comments
 (0)