Skip to content

Commit

Permalink
[fc] Repository: plone.restapi
Browse files Browse the repository at this point in the history
Branch: refs/heads/master
Date: 2023-06-29T17:59:08-07:00
Author: David Glick (davisagli) <david@glicksoftware.com>
Commit: plone/plone.restapi@e8105b1

Update file extension for documentation news items for consistency with other projects

Files changed:
M pyproject.toml
  • Loading branch information
davisagli committed Jun 30, 2023
1 parent 5c5d7a2 commit 1359026
Showing 1 changed file with 7 additions and 64 deletions.
71 changes: 7 additions & 64 deletions last_commit.txt
Original file line number Diff line number Diff line change
@@ -1,72 +1,15 @@
Repository: plone.app.z3cform
Repository: plone.restapi


Branch: refs/heads/master
Date: 2023-06-26T16:48:49+02:00
Author: Jens W. Klein (jensens) <jk@kleinundpartner.at>
Commit: https://github.com/plone/plone.app.z3cform/commit/806175d46a07d09bd4bb8c42dc1177d7c24e69b3
Date: 2023-06-29T17:59:08-07:00
Author: David Glick (davisagli) <david@glicksoftware.com>
Commit: https://github.com/plone/plone.restapi/commit/e8105b1b21edc0cc43b9e0673105e6ad28c729c5

use html 5 email field for plone.schema email fields
Update file extension for documentation news items for consistency with other projects

Files changed:
A plone/app/z3cform/templates/email_input.pt
A plone/app/z3cform/widgets/email.py
M plone/app/z3cform/interfaces.py
M plone/app/z3cform/widgets.zcml
M pyproject.toml

b'diff --git a/plone/app/z3cform/interfaces.py b/plone/app/z3cform/interfaces.py\nindex c48fe2e..b76b214 100644\n--- a/plone/app/z3cform/interfaces.py\n+++ b/plone/app/z3cform/interfaces.py\n@@ -69,6 +69,9 @@ class IRichTextWidget(patextfield_IRichTextWidget):\n class ILinkWidget(ITextWidget):\n """Marker interface for the enhanced link widget."""\n \n+class IEmailWidget(ITextWidget):\n+ """Marker interface for the dumb email widget."""\n+\n \n class ISingleCheckBoxBoolWidget(ISingleCheckBoxWidget):\n """Marker interface for the SingleCheckboxBoolWidget."""\ndiff --git a/plone/app/z3cform/templates/email_input.pt b/plone/app/z3cform/templates/email_input.pt\nnew file mode 100644\nindex 0000000..f234b39\n--- /dev/null\n+++ b/plone/app/z3cform/templates/email_input.pt\n@@ -0,0 +1,52 @@\n+<html xmlns="http://www.w3.org/1999/xhtml"\n+ xmlns:tal="http://xml.zope.org/namespaces/tal"\n+ tal:omit-tag=""\n+>\n+ <input class=""\n+ id=""\n+ accesskey=""\n+ alt=""\n+ lang=""\n+ maxlength=""\n+ name=""\n+ size=""\n+ style=""\n+ tabindex=""\n+ title=""\n+ type="email"\n+ value=""\n+ tal:attributes="\n+ id view/id;\n+ name view/name;\n+ required python:view.required and \'required\' or None;\n+ class python:\'form-control {0}{1}\'.format(view.klass, view.error and \' is-invalid\' or \'\');\n+ style view/style;\n+ title view/title;\n+ lang view/lang;\n+ onclick view/onclick;\n+ ondblclick view/ondblclick;\n+ onmousedown view/onmousedown;\n+ onmouseup view/onmouseup;\n+ onmouseover view/onmouseover;\n+ onmousemove view/onmousemove;\n+ onmouseout view/onmouseout;\n+ onkeypress view/onkeypress;\n+ onkeydown view/onkeydown;\n+ onkeyup view/onkeyup;\n+ value view/value;\n+ disabled view/disabled;\n+ tabindex view/tabindex;\n+ onfocus view/onfocus;\n+ onblur view/onblur;\n+ onchange view/onchange;\n+ readonly view/readonly;\n+ alt view/alt;\n+ accesskey view/accesskey;\n+ onselect view/onselect;\n+ size view/size;\n+ maxlength view/maxlength;\n+ placeholder view/placeholder;\n+ autocapitalize view/autocapitalize;\n+ "\n+ />\n+</html>\ndiff --git a/plone/app/z3cform/widgets.zcml b/plone/app/z3cform/widgets.zcml\nindex 2e81315..613e130 100644\n--- a/plone/app/z3cform/widgets.zcml\n+++ b/plone/app/z3cform/widgets.zcml\n@@ -206,6 +206,20 @@\n mode="input"\n />\n \n+ <!-- email -->\n+ <adapter\n+ factory=".widgets.email.EmailFieldWidget"\n+ for="plone.schema.email.IEmail\n+ plone.app.z3cform.interfaces.IPloneFormLayer"\n+ />\n+\n+ <z3c:widgetTemplate\n+ widget=".interfaces.IEmailWidget"\n+ template="templates/email_input.pt"\n+ layer=".interfaces.IPloneFormLayer"\n+ mode="input"\n+ />\n+\n <!-- z3c.form overrides -->\n \n <z3c:widgetTemplate\ndiff --git a/plone/app/z3cform/widgets/email.py b/plone/app/z3cform/widgets/email.py\nnew file mode 100644\nindex 0000000..dc029ac\n--- /dev/null\n+++ b/plone/app/z3cform/widgets/email.py\n@@ -0,0 +1,18 @@\n+from plone.app.z3cform.interfaces import IEmailWidget\n+from z3c.form.browser.text import TextWidget as z3cform_TextWidget\n+from z3c.form.interfaces import IFieldWidget\n+from z3c.form.widget import FieldWidget\n+from zope.interface import implementer\n+from zope.interface import implementer_only\n+\n+import json\n+\n+\n+@implementer_only(IEmailWidget)\n+class EmailWidget(z3cform_TextWidget):\n+ """Implementation of dumb email widget.\n+ """\n+\n+@implementer(IFieldWidget)\n+def EmailFieldWidget(field, request):\n+ return FieldWidget(field, EmailWidget(request))\n'

Repository: plone.app.z3cform


Branch: refs/heads/master
Date: 2023-06-26T17:08:33+02:00
Author: Jens W. Klein (jensens) <jk@kleinundpartner.at>
Commit: https://github.com/plone/plone.app.z3cform/commit/fc0b4541eb7fa4b4d59be6ecb75a228147091159

prettify

Files changed:
M plone/app/z3cform/interfaces.py
M plone/app/z3cform/widgets/email.py

b'diff --git a/plone/app/z3cform/interfaces.py b/plone/app/z3cform/interfaces.py\nindex b76b214..0315605 100644\n--- a/plone/app/z3cform/interfaces.py\n+++ b/plone/app/z3cform/interfaces.py\n@@ -69,6 +69,7 @@ class IRichTextWidget(patextfield_IRichTextWidget):\n class ILinkWidget(ITextWidget):\n """Marker interface for the enhanced link widget."""\n \n+\n class IEmailWidget(ITextWidget):\n """Marker interface for the dumb email widget."""\n \ndiff --git a/plone/app/z3cform/widgets/email.py b/plone/app/z3cform/widgets/email.py\nindex dc029ac..17d76ef 100644\n--- a/plone/app/z3cform/widgets/email.py\n+++ b/plone/app/z3cform/widgets/email.py\n@@ -5,13 +5,11 @@\n from zope.interface import implementer\n from zope.interface import implementer_only\n \n-import json\n-\n \n @implementer_only(IEmailWidget)\n class EmailWidget(z3cform_TextWidget):\n- """Implementation of dumb email widget.\n- """\n+ """Implementation of dumb email widget."""\n+\n \n @implementer(IFieldWidget)\n def EmailFieldWidget(field, request):\n'

Repository: plone.app.z3cform


Branch: refs/heads/master
Date: 2023-06-26T17:11:22+02:00
Author: Jens W. Klein (jensens) <jk@kleinundpartner.at>
Commit: https://github.com/plone/plone.app.z3cform/commit/c02001a1a91d454eb2cb403b46fa176eca2a9bef

document new feature

Files changed:
A news/173.feature
M setup.py

b'diff --git a/news/173.feature b/news/173.feature\nnew file mode 100644\nindex 00000000..3571c3d6\n--- /dev/null\n+++ b/news/173.feature\n@@ -0,0 +1,3 @@\n+Introduce new Email-Widget which is used for `plone.schema.email.IEmail` fields.\n+It uses the input type `email`.\n+[jensens]\n\\ No newline at end of file\ndiff --git a/setup.py b/setup.py\nindex 4e496dad..6e6aa6df 100644\n--- a/setup.py\n+++ b/setup.py\n@@ -8,7 +8,7 @@ def read(*rnames):\n return open(os.path.join(os.path.dirname(__file__), *rnames)).read()\n \n \n-version = "4.2.2.dev0"\n+version = "4.3.0.dev0"\n \n long_description = (\n read("README.rst")\n'

Repository: plone.app.z3cform


Branch: refs/heads/master
Date: 2023-06-29T17:33:44+02:00
Author: Peter Mathis (petschki) <petschki@users.noreply.github.com>
Commit: https://github.com/plone/plone.app.z3cform/commit/eb6f007d986596b19b72e347cbd4262ddc527165

Merge pull request #173 from plone/email-input

Use html 5 email field for plone.schema email fields

Files changed:
A news/173.feature
A plone/app/z3cform/templates/email_input.pt
A plone/app/z3cform/widgets/email.py
M plone/app/z3cform/interfaces.py
M plone/app/z3cform/widgets.zcml
M setup.py

b'diff --git a/news/173.feature b/news/173.feature\nnew file mode 100644\nindex 0000000..3571c3d\n--- /dev/null\n+++ b/news/173.feature\n@@ -0,0 +1,3 @@\n+Introduce new Email-Widget which is used for `plone.schema.email.IEmail` fields.\n+It uses the input type `email`.\n+[jensens]\n\\ No newline at end of file\ndiff --git a/plone/app/z3cform/interfaces.py b/plone/app/z3cform/interfaces.py\nindex c48fe2e..0315605 100644\n--- a/plone/app/z3cform/interfaces.py\n+++ b/plone/app/z3cform/interfaces.py\n@@ -70,6 +70,10 @@ class ILinkWidget(ITextWidget):\n """Marker interface for the enhanced link widget."""\n \n \n+class IEmailWidget(ITextWidget):\n+ """Marker interface for the dumb email widget."""\n+\n+\n class ISingleCheckBoxBoolWidget(ISingleCheckBoxWidget):\n """Marker interface for the SingleCheckboxBoolWidget."""\n \ndiff --git a/plone/app/z3cform/templates/email_input.pt b/plone/app/z3cform/templates/email_input.pt\nnew file mode 100644\nindex 0000000..f234b39\n--- /dev/null\n+++ b/plone/app/z3cform/templates/email_input.pt\n@@ -0,0 +1,52 @@\n+<html xmlns="http://www.w3.org/1999/xhtml"\n+ xmlns:tal="http://xml.zope.org/namespaces/tal"\n+ tal:omit-tag=""\n+>\n+ <input class=""\n+ id=""\n+ accesskey=""\n+ alt=""\n+ lang=""\n+ maxlength=""\n+ name=""\n+ size=""\n+ style=""\n+ tabindex=""\n+ title=""\n+ type="email"\n+ value=""\n+ tal:attributes="\n+ id view/id;\n+ name view/name;\n+ required python:view.required and \'required\' or None;\n+ class python:\'form-control {0}{1}\'.format(view.klass, view.error and \' is-invalid\' or \'\');\n+ style view/style;\n+ title view/title;\n+ lang view/lang;\n+ onclick view/onclick;\n+ ondblclick view/ondblclick;\n+ onmousedown view/onmousedown;\n+ onmouseup view/onmouseup;\n+ onmouseover view/onmouseover;\n+ onmousemove view/onmousemove;\n+ onmouseout view/onmouseout;\n+ onkeypress view/onkeypress;\n+ onkeydown view/onkeydown;\n+ onkeyup view/onkeyup;\n+ value view/value;\n+ disabled view/disabled;\n+ tabindex view/tabindex;\n+ onfocus view/onfocus;\n+ onblur view/onblur;\n+ onchange view/onchange;\n+ readonly view/readonly;\n+ alt view/alt;\n+ accesskey view/accesskey;\n+ onselect view/onselect;\n+ size view/size;\n+ maxlength view/maxlength;\n+ placeholder view/placeholder;\n+ autocapitalize view/autocapitalize;\n+ "\n+ />\n+</html>\ndiff --git a/plone/app/z3cform/widgets.zcml b/plone/app/z3cform/widgets.zcml\nindex 2e81315..613e130 100644\n--- a/plone/app/z3cform/widgets.zcml\n+++ b/plone/app/z3cform/widgets.zcml\n@@ -206,6 +206,20 @@\n mode="input"\n />\n \n+ <!-- email -->\n+ <adapter\n+ factory=".widgets.email.EmailFieldWidget"\n+ for="plone.schema.email.IEmail\n+ plone.app.z3cform.interfaces.IPloneFormLayer"\n+ />\n+\n+ <z3c:widgetTemplate\n+ widget=".interfaces.IEmailWidget"\n+ template="templates/email_input.pt"\n+ layer=".interfaces.IPloneFormLayer"\n+ mode="input"\n+ />\n+\n <!-- z3c.form overrides -->\n \n <z3c:widgetTemplate\ndiff --git a/plone/app/z3cform/widgets/email.py b/plone/app/z3cform/widgets/email.py\nnew file mode 100644\nindex 0000000..17d76ef\n--- /dev/null\n+++ b/plone/app/z3cform/widgets/email.py\n@@ -0,0 +1,16 @@\n+from plone.app.z3cform.interfaces import IEmailWidget\n+from z3c.form.browser.text import TextWidget as z3cform_TextWidget\n+from z3c.form.interfaces import IFieldWidget\n+from z3c.form.widget import FieldWidget\n+from zope.interface import implementer\n+from zope.interface import implementer_only\n+\n+\n+@implementer_only(IEmailWidget)\n+class EmailWidget(z3cform_TextWidget):\n+ """Implementation of dumb email widget."""\n+\n+\n+@implementer(IFieldWidget)\n+def EmailFieldWidget(field, request):\n+ return FieldWidget(field, EmailWidget(request))\ndiff --git a/setup.py b/setup.py\nindex 949d4c8..5348fb3 100644\n--- a/setup.py\n+++ b/setup.py\n@@ -3,7 +3,7 @@\n from setuptools import setup\n \n \n-version = "4.2.2.dev0"\n+version = "4.3.0.dev0"\n \n long_description = (\n f"{Path(\'README.rst\').read_text()}\\n"\n'
b'diff --git a/pyproject.toml b/pyproject.toml\nindex 9c721fead..057abc235 100644\n--- a/pyproject.toml\n+++ b/pyproject.toml\n@@ -25,6 +25,6 @@ name = "Internal:"\n showcontent = true\n \n [[tool.towncrier.type]]\n-directory = "doc"\n+directory = "documentation"\n name = "Documentation:"\n showcontent = true\n\\ No newline at end of file\n'

0 comments on commit 1359026

Please sign in to comment.