Skip to content

Commit 1a5959e

Browse files
committed
Merge branch '4.4' into 5.3
* 4.4: Split a conditional doc include into two separate doc includes
2 parents cd9b737 + 350d4e0 commit 1a5959e

26 files changed

+52
-107
lines changed

reference/forms/types/choice.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -217,17 +217,15 @@ compound
217217
This option specifies if a form is compound. The value is by default
218218
overridden by the value of the ``expanded`` option.
219219

220-
.. include:: /reference/forms/types/options/empty_data.rst.inc
221-
:end-before: DEFAULT_PLACEHOLDER
220+
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
222221

223222
The actual default value of this option depends on other field options:
224223

225224
* If ``multiple`` is ``false`` and ``expanded`` is ``false``, then ``''``
226225
(empty string);
227226
* Otherwise ``[]`` (empty array).
228227

229-
.. include:: /reference/forms/types/options/empty_data.rst.inc
230-
:start-after: DEFAULT_PLACEHOLDER
228+
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
231229

232230
error_bubbling
233231
~~~~~~~~~~~~~~

reference/forms/types/collection.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -393,13 +393,11 @@ Not all options are listed here - only the most applicable to this type:
393393

394394
.. include:: /reference/forms/types/options/by_reference.rst.inc
395395

396-
.. include:: /reference/forms/types/options/empty_data.rst.inc
397-
:end-before: DEFAULT_PLACEHOLDER
396+
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
398397

399398
The default value is ``[]`` (empty array).
400399

401-
.. include:: /reference/forms/types/options/empty_data.rst.inc
402-
:start-after: DEFAULT_PLACEHOLDER
400+
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
403401

404402
error_bubbling
405403
~~~~~~~~~~~~~~

reference/forms/types/color.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -64,13 +64,11 @@ These options inherit from the :doc:`FormType </reference/forms/types/form>`:
6464

6565
.. include:: /reference/forms/types/options/disabled.rst.inc
6666

67-
.. include:: /reference/forms/types/options/empty_data.rst.inc
68-
:end-before: DEFAULT_PLACEHOLDER
67+
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
6968

7069
The default value is ``''`` (the empty string).
7170

72-
.. include:: /reference/forms/types/options/empty_data.rst.inc
73-
:start-after: DEFAULT_PLACEHOLDER
71+
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
7472

7573
.. include:: /reference/forms/types/options/error_bubbling.rst.inc
7674

reference/forms/types/country.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -93,17 +93,15 @@ These options inherit from the :doc:`FormType </reference/forms/types/form>`:
9393

9494
.. include:: /reference/forms/types/options/disabled.rst.inc
9595

96-
.. include:: /reference/forms/types/options/empty_data.rst.inc
97-
:end-before: DEFAULT_PLACEHOLDER
96+
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
9897

9998
The actual default value of this option depends on other field options:
10099

101100
* If ``multiple`` is ``false`` and ``expanded`` is ``false``, then ``''``
102101
(empty string);
103102
* Otherwise ``[]`` (empty array).
104103

105-
.. include:: /reference/forms/types/options/empty_data.rst.inc
106-
:start-after: DEFAULT_PLACEHOLDER
104+
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
107105

108106
.. include:: /reference/forms/types/options/help.rst.inc
109107

reference/forms/types/currency.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -74,17 +74,15 @@ These options inherit from the :doc:`FormType </reference/forms/types/form>`:
7474

7575
.. include:: /reference/forms/types/options/disabled.rst.inc
7676

77-
.. include:: /reference/forms/types/options/empty_data.rst.inc
78-
:end-before: DEFAULT_PLACEHOLDER
77+
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
7978

8079
The actual default value of this option depends on other field options:
8180

8281
* If ``multiple`` is ``false`` and ``expanded`` is ``false``, then ``''``
8382
(empty string);
8483
* Otherwise ``[]`` (empty array).
8584

86-
.. include:: /reference/forms/types/options/empty_data.rst.inc
87-
:start-after: DEFAULT_PLACEHOLDER
85+
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
8886

8987
.. include:: /reference/forms/types/options/help.rst.inc
9088

reference/forms/types/email.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,13 +37,11 @@ These options inherit from the :doc:`FormType </reference/forms/types/form>`:
3737

3838
.. include:: /reference/forms/types/options/disabled.rst.inc
3939

40-
.. include:: /reference/forms/types/options/empty_data.rst.inc
41-
:end-before: DEFAULT_PLACEHOLDER
40+
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
4241

4342
The default value is ``''`` (the empty string).
4443

45-
.. include:: /reference/forms/types/options/empty_data.rst.inc
46-
:start-after: DEFAULT_PLACEHOLDER
44+
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
4745

4846
.. include:: /reference/forms/types/options/error_bubbling.rst.inc
4947

reference/forms/types/entity.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -288,17 +288,15 @@ type:
288288

289289
.. include:: /reference/forms/types/options/disabled.rst.inc
290290

291-
.. include:: /reference/forms/types/options/empty_data.rst.inc
292-
:end-before: DEFAULT_PLACEHOLDER
291+
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
293292

294293
The actual default value of this option depends on other field options:
295294

296295
* If ``multiple`` is ``false`` and ``expanded`` is ``false``, then ``''``
297296
(empty string);
298297
* Otherwise ``[]`` (empty array).
299298

300-
.. include:: /reference/forms/types/options/empty_data.rst.inc
301-
:start-after: DEFAULT_PLACEHOLDER
299+
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
302300

303301
.. include:: /reference/forms/types/options/error_bubbling.rst.inc
304302

reference/forms/types/form.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,7 @@ option on the form.
5353

5454
.. _reference-form-option-empty-data:
5555

56-
.. include:: /reference/forms/types/options/empty_data.rst.inc
57-
:end-before: DEFAULT_PLACEHOLDER
56+
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
5857

5958
The actual default value of this option depends on other field options:
6059

@@ -65,8 +64,7 @@ The actual default value of this option depends on other field options:
6564
* If ``data_class`` is not set and ``compound`` is ``false``, then ``''``
6665
(empty string).
6766

68-
.. include:: /reference/forms/types/options/empty_data.rst.inc
69-
:start-after: DEFAULT_PLACEHOLDER
67+
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
7068

7169
.. _reference-form-option-error-bubbling:
7270

reference/forms/types/hidden.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -50,13 +50,11 @@ These options inherit from the :doc:`FormType </reference/forms/types/form>`:
5050

5151
.. include:: /reference/forms/types/options/data.rst.inc
5252

53-
.. include:: /reference/forms/types/options/empty_data.rst.inc
54-
:end-before: DEFAULT_PLACEHOLDER
53+
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
5554

5655
The default value is ``''`` (the empty string).
5756

58-
.. include:: /reference/forms/types/options/empty_data.rst.inc
59-
:start-after: DEFAULT_PLACEHOLDER
57+
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
6058

6159
.. include:: /reference/forms/types/options/error_mapping.rst.inc
6260

reference/forms/types/integer.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -89,13 +89,11 @@ These options inherit from the :doc:`FormType </reference/forms/types/form>`:
8989

9090
.. include:: /reference/forms/types/options/disabled.rst.inc
9191

92-
.. include:: /reference/forms/types/options/empty_data.rst.inc
93-
:end-before: DEFAULT_PLACEHOLDER
92+
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
9493

9594
The default value is ``''`` (the empty string).
9695

97-
.. include:: /reference/forms/types/options/empty_data.rst.inc
98-
:start-after: DEFAULT_PLACEHOLDER
96+
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
9997

10098
.. include:: /reference/forms/types/options/error_bubbling.rst.inc
10199

reference/forms/types/language.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -114,17 +114,15 @@ These options inherit from the :doc:`FormType </reference/forms/types/form>`:
114114

115115
.. include:: /reference/forms/types/options/disabled.rst.inc
116116

117-
.. include:: /reference/forms/types/options/empty_data.rst.inc
118-
:end-before: DEFAULT_PLACEHOLDER
117+
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
119118

120119
The actual default value of this option depends on other field options:
121120

122121
* If ``multiple`` is ``false`` and ``expanded`` is ``false``, then ``''``
123122
(empty string);
124123
* Otherwise ``[]`` (empty array).
125124

126-
.. include:: /reference/forms/types/options/empty_data.rst.inc
127-
:start-after: DEFAULT_PLACEHOLDER
125+
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
128126

129127
.. include:: /reference/forms/types/options/help.rst.inc
130128

reference/forms/types/locale.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -87,17 +87,15 @@ These options inherit from the :doc:`FormType </reference/forms/types/form>`:
8787

8888
.. include:: /reference/forms/types/options/disabled.rst.inc
8989

90-
.. include:: /reference/forms/types/options/empty_data.rst.inc
91-
:end-before: DEFAULT_PLACEHOLDER
90+
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
9291

9392
The actual default value of this option depends on other field options:
9493

9594
* If ``multiple`` is ``false`` and ``expanded`` is ``false``, then ``''``
9695
(empty string);
9796
* Otherwise ``[]`` (empty array).
9897

99-
.. include:: /reference/forms/types/options/empty_data.rst.inc
100-
:start-after: DEFAULT_PLACEHOLDER
98+
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
10199

102100
.. include:: /reference/forms/types/options/help.rst.inc
103101

reference/forms/types/money.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -111,13 +111,11 @@ These options inherit from the :doc:`FormType </reference/forms/types/form>`:
111111

112112
.. include:: /reference/forms/types/options/disabled.rst.inc
113113

114-
.. include:: /reference/forms/types/options/empty_data.rst.inc
115-
:end-before: DEFAULT_PLACEHOLDER
114+
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
116115

117116
The default value is ``''`` (the empty string).
118117

119-
.. include:: /reference/forms/types/options/empty_data.rst.inc
120-
:start-after: DEFAULT_PLACEHOLDER
118+
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
121119

122120
.. include:: /reference/forms/types/options/error_bubbling.rst.inc
123121

reference/forms/types/number.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -76,13 +76,11 @@ These options inherit from the :doc:`FormType </reference/forms/types/form>`:
7676

7777
.. include:: /reference/forms/types/options/disabled.rst.inc
7878

79-
.. include:: /reference/forms/types/options/empty_data.rst.inc
80-
:end-before: DEFAULT_PLACEHOLDER
79+
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
8180

8281
The default value is ``''`` (the empty string).
8382

84-
.. include:: /reference/forms/types/options/empty_data.rst.inc
85-
:start-after: DEFAULT_PLACEHOLDER
83+
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
8684

8785
.. include:: /reference/forms/types/options/error_bubbling.rst.inc
8886

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
``empty_data``
2+
~~~~~~~~~~~~~~
3+
4+
**type**: ``mixed``

reference/forms/types/options/empty_data.rst.inc renamed to reference/forms/types/options/empty_data_description.rst.inc

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,3 @@
1-
``empty_data``
2-
~~~~~~~~~~~~~~
3-
4-
**type**: ``mixed``
5-
6-
.. This file should only be included with start-after or end-before that's
7-
set to this placeholder value. Its purpose is to let us include only
8-
part of this file.
9-
10-
DEFAULT_PLACEHOLDER
11-
121
This option determines what value the field will *return* when the submitted
132
value is empty (or missing). It does not set an initial value if none is
143
provided when the form is rendered in a view.

reference/forms/types/password.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -59,13 +59,11 @@ These options inherit from the :doc:`FormType </reference/forms/types/form>`:
5959

6060
.. include:: /reference/forms/types/options/disabled.rst.inc
6161

62-
.. include:: /reference/forms/types/options/empty_data.rst.inc
63-
:end-before: DEFAULT_PLACEHOLDER
62+
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
6463

6564
The default value is ``''`` (the empty string).
6665

67-
.. include:: /reference/forms/types/options/empty_data.rst.inc
68-
:start-after: DEFAULT_PLACEHOLDER
66+
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
6967

7068
.. include:: /reference/forms/types/options/error_bubbling.rst.inc
7169

reference/forms/types/percent.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -105,13 +105,11 @@ These options inherit from the :doc:`FormType </reference/forms/types/form>`:
105105

106106
.. include:: /reference/forms/types/options/disabled.rst.inc
107107

108-
.. include:: /reference/forms/types/options/empty_data.rst.inc
109-
:end-before: DEFAULT_PLACEHOLDER
108+
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
110109

111110
The default value is ``''`` (the empty string).
112111

113-
.. include:: /reference/forms/types/options/empty_data.rst.inc
114-
:start-after: DEFAULT_PLACEHOLDER
112+
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
115113

116114
.. include:: /reference/forms/types/options/error_bubbling.rst.inc
117115

reference/forms/types/range.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -52,13 +52,11 @@ These options inherit from the :doc:`FormType </reference/forms/types/form>`:
5252

5353
.. include:: /reference/forms/types/options/disabled.rst.inc
5454

55-
.. include:: /reference/forms/types/options/empty_data.rst.inc
56-
:end-before: DEFAULT_PLACEHOLDER
55+
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
5756

5857
The default value is ``''`` (the empty string).
5958

60-
.. include:: /reference/forms/types/options/empty_data.rst.inc
61-
:start-after: DEFAULT_PLACEHOLDER
59+
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
6260

6361
.. include:: /reference/forms/types/options/error_bubbling.rst.inc
6462

reference/forms/types/search.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,13 +37,11 @@ These options inherit from the :doc:`FormType </reference/forms/types/form>`:
3737

3838
.. include:: /reference/forms/types/options/disabled.rst.inc
3939

40-
.. include:: /reference/forms/types/options/empty_data.rst.inc
41-
:end-before: DEFAULT_PLACEHOLDER
40+
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
4241

4342
The default value is ``''`` (the empty string).
4443

45-
.. include:: /reference/forms/types/options/empty_data.rst.inc
46-
:start-after: DEFAULT_PLACEHOLDER
44+
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
4745

4846
.. include:: /reference/forms/types/options/error_bubbling.rst.inc
4947

reference/forms/types/tel.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,13 +43,11 @@ These options inherit from the :doc:`FormType </reference/forms/types/form>`:
4343

4444
.. include:: /reference/forms/types/options/disabled.rst.inc
4545

46-
.. include:: /reference/forms/types/options/empty_data.rst.inc
47-
:end-before: DEFAULT_PLACEHOLDER
46+
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
4847

4948
The default value is ``''`` (the empty string).
5049

51-
.. include:: /reference/forms/types/options/empty_data.rst.inc
52-
:start-after: DEFAULT_PLACEHOLDER
50+
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
5351

5452
.. include:: /reference/forms/types/options/error_bubbling.rst.inc
5553

reference/forms/types/text.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,15 +27,13 @@ These options inherit from the :doc:`FormType </reference/forms/types/form>`:
2727

2828
.. include:: /reference/forms/types/options/disabled.rst.inc
2929

30-
.. include:: /reference/forms/types/options/empty_data.rst.inc
31-
:end-before: DEFAULT_PLACEHOLDER
30+
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
3231

3332
From an HTTP perspective, submitted data is always a string or an array of strings.
3433
So by default, the form will treat any empty string as null. If you prefer to get
3534
an empty string, explicitly set the ``empty_data`` option to an empty string.
3635

37-
.. include:: /reference/forms/types/options/empty_data.rst.inc
38-
:start-after: DEFAULT_PLACEHOLDER
36+
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
3937

4038
.. include:: /reference/forms/types/options/error_bubbling.rst.inc
4139

reference/forms/types/textarea.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,13 +33,11 @@ These options inherit from the :doc:`FormType </reference/forms/types/form>`:
3333

3434
.. include:: /reference/forms/types/options/disabled.rst.inc
3535

36-
.. include:: /reference/forms/types/options/empty_data.rst.inc
37-
:end-before: DEFAULT_PLACEHOLDER
36+
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
3837

3938
The default value is ``''`` (the empty string).
4039

41-
.. include:: /reference/forms/types/options/empty_data.rst.inc
42-
:start-after: DEFAULT_PLACEHOLDER
40+
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
4341

4442
.. include:: /reference/forms/types/options/error_bubbling.rst.inc
4543

0 commit comments

Comments
 (0)