-
Notifications
You must be signed in to change notification settings - Fork 395
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
Added mention of HTML5 fields in the docs #326
Conversation
Looks like you used a different email than the one associated with your GitHub account. If you want to change that, you can use |
Thanks for that! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It would be great if you could please use the proper backtick notation in your change.
------------ | ||
|
||
In addition to basic HTML fields, WTForms also supplies fields for the HTML5 | ||
standard. These fields can be accessed under the `wtforms.fields.html5` namespace. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Decorate `wtforms.fields.html5`
as :mod:`wtforms.fields.html5`
.
In addition to basic HTML fields, WTForms also supplies fields for the HTML5 | ||
standard. These fields can be accessed under the `wtforms.fields.html5` namespace. | ||
In reality, these fields are just convenience fields that extend basic fields | ||
and implement HTML5 specific widgets. These widgets are located in the `wtforms.widgets.html5` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use :mod:
here as well.
namespace and can be overridden or modified just like any other widget. | ||
|
||
.. autoclass:: SearchField(default field arguments) | ||
Represents an `<input type="search">` field |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use ``
instead of `
to decorate all HTML code.
Represents an `<input type="datetime-local">` field | ||
|
||
.. autoclass:: IntegerField(default field arguments) | ||
Represents an `<input type="number">` field with the `step="1"` attribute |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also use ``
instead of `
here and below for the HTML step
attribute.
Thanks for the suggestions. I'll clean these up tomorrow and push them up |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All the classes already have docstrings, they shouldn't be copied into the docs, autoclass
will take care of that.
Cool. I'm still learning how Sphinx works. Thanks for the heads up! |
I'm having some issues with building. Sphinx doesn't seem to like the fact that these classes are in the |
@davidism, what are the changes that still need to be done to get this sorted? This seems like something that really should be in the docs so I'm happy to make the changes myself. |
Does it build? Looks fine otherwise. |
It didn't build, it needed a few changes so I made those and merged it in a separate PR #409 but it should also realise this has been merged too. |
Per request of #275, adding the HTML5 fields to the Fields documentation