Skip to content

Commit dd28787

Browse files
committed
Minor spelling, style guide, syntax fixes
1 parent 06225a3 commit dd28787

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

docs/backend/widgets.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ myst:
1515
See the chapter {doc}`training:mastering-plone/dexterity_reference` from the Mastering Plone 6 Training.
1616
```
1717

18-
Widgets render HTML code for input and parse HTTP `post` request input in Plone.
18+
Widgets render HTML code for input and parse the input from an HTTP `post` request in Plone.
1919

2020
Plone stores widgets as the `widgets` attribute of a form.
2121
Plone presents widgets as an ordered dict-like `Widgets` class.
@@ -30,8 +30,9 @@ When an HTTP `post` request comes in, Zope publisher automatically converts `<se
3030

3131
## Widget reference
3232

33-
```{note}
34-
In VS Code editor, you can install the [Plone Snippets](https://marketplace.visualstudio.com/items?itemName=Derico.plone-vs-snippets) extension. This will give you snippets for most fields, widgets and autoform directives in Python and XML based schemas.
33+
```{tip}
34+
In VS Code editor, you can install the [Plone Snippets](https://marketplace.visualstudio.com/items?itemName=Derico.plone-vs-snippets) extension.
35+
This will give you snippets for most fields, widgets, and autoform directives in Python and XML based schemas.
3536
```
3637

3738
You can find the default widgets in the browser package in `z3c.form`.
@@ -61,6 +62,7 @@ The main widgets are:
6162
- Time Widget
6263
- DateTime Picker
6364

65+
6466
## Changing a field's widget
6567

6668
You can change the widget that you use for a field in several ways.
@@ -74,7 +76,7 @@ This model is defined as a `zope.schema` based schema, but extra hints can be su
7476

7577
By default, `z3c.form` picks a widget based on the type of your field.
7678
You can change the widget using the `widget` directive if you want users to enter or view data in a different format.
77-
For example, you can change the widget for the `human` boolean field to use "yes" and "no" radio buttons instead of its default checkbox:
79+
For example, you can change the widget for the `human` boolean field to use `yes` and `no` radio buttons instead of its default checkbox:
7880

7981
```{code-block} python
8082
:emphasize-lines: 7
@@ -513,7 +515,7 @@ You can override widget templates as instructed for `z3c.form`.
513515
You might want to customize this widget frame for your own form.
514516
Below is an example of how to do it.
515517

516-
Copy [`widget.pt`](https://github.com/plone/plone.app.z3cform/blob/master/plone/app/z3cform/templates/widget.pt) to your own package, rename it as ``demo-widget.pt`` and edit it.
518+
Copy [`widget.pt`](https://github.com/plone/plone.app.z3cform/blob/master/plone/app/z3cform/templates/widget.pt) to your own package, rename it as `demo-widget.pt`, and edit it.
517519

518520
Then add the following code to `configure.zcml`.
519521
Remember to fix the path of the template according to your own paths.
@@ -555,7 +557,7 @@ class MyForm(...):
555557

556558
## Combined widgets
557559

558-
You can combine several widgets into one with `z3c.form.browser.multil.MultiWidget` and `z3c.form.browser.object.ObjectWidget` classes.
560+
You can combine several widgets into one with `z3c.form.browser.multi.MultiWidget` and `z3c.form.browser.object.ObjectWidget` classes.
559561

560562
The following example shows how to create an input widget with minimum and maximum values.
561563

@@ -570,9 +572,7 @@ from z3c.form.object import registerFactoryAdapter
570572

571573
class IMinMax(zope.interface.Interface):
572574
""" Helper schema for min and max fields """
573-
574575
min = zope.schema.Float(required=False)
575-
576576
max = zope.schema.Float(required=False)
577577

578578

0 commit comments

Comments
 (0)