prepare 0.4.15; fix an extra big changebox in edit mode; improve docs (pypi syntax highlighting)

This commit is contained in:
Artur Barseghyan 2015-01-27 23:51:26 +01:00
parent 9da581c41d
commit fc2b7470e3
27 changed files with 71 additions and 63 deletions

View file

@ -15,6 +15,12 @@ are used for versioning (schema follows below):
0.3.4 to 0.4).
- All backwards incompatible changes are mentioned in this document.
0.4.15
-------------------------------------
2015-01-27
- Fix the "large" checkboxes in edit mode - now shown small as they should be.
0.4.14
-------------------------------------
2015-01-26

View file

@ -19,8 +19,8 @@ Key concepts
- Each form consists of elements. Form elements are divided
into two groups:
- (a) form fields (input field, textarea, hidden field, file field, etc.).
- (b) content (presentational) elements (text, image, embed video, etc.).
(a) form fields (input field, textarea, hidden field, file field, etc.).
(b) content (presentational) elements (text, image, embed video, etc.).
- Number of form elements is not limited.
- Each form may contain handlers. Handler processes the form data (for example,
@ -154,7 +154,7 @@ If quick installer doesn't work for you, see the manual steps on running the
Installation
===============================================
1. Install latest stable version from PyPI:
(1) Install latest stable version from PyPI:
.. code-block:: none
@ -172,9 +172,9 @@ Or latest stable version from BitBucket:
$ pip install -e hg+https://bitbucket.org/barseghyanartur/django-fobi@stable#egg=django-fobi
2. Add `fobi` to ``INSTALLED_APPS`` of the your projects' Django settings.
Furthermore, all themes and plugins to be used, shall be added to the
``INSTALLED_APPS`` as well.
(2) Add `fobi` to ``INSTALLED_APPS`` of the your projects' Django settings.
Furthermore, all themes and plugins to be used, shall be added to the
``INSTALLED_APPS`` as well.
.. code-block:: python
@ -221,8 +221,8 @@ Or latest stable version from BitBucket:
# ...
)
3. Make appropriate changes to the ``TEMPLATE_CONTEXT_PROCESSORS`` of the your
projects' Django settings.
(3) Make appropriate changes to the ``TEMPLATE_CONTEXT_PROCESSORS`` of the your
projects' Django settings.
And the following to the context processors.
@ -237,7 +237,7 @@ And the following to the context processors.
Make sure that ``django.core.context_processors.request`` is in
``TEMPLATE_CONTEXT_PROCESSORS`` too.
4. Configure URLs
(4) Configure URLs
Add the following line to urlpatterns of your urls module.

View file

@ -5,14 +5,14 @@ Bootstrap3 theme
-----------------------------------------------
Dashboard
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1. Dashboard
(1) Dashboard
.. image:: _static/bootstrap3/01_dashboard.png
:scale: 80 %
Create a form
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2. Create a form
(2) Create a form
.. image:: _static/bootstrap3/02_create_form.png
:scale: 80 %
@ -21,22 +21,22 @@ View/edit form
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Form elements
+++++++++++++++++++++++++++++++++++++++++++++++
3. Edit form - form elements tab active, no elements yet
(3) Edit form - form elements tab active, no elements yet
.. image:: _static/bootstrap3/03_edit_form_-_form_elements_tab_active_-_no_elements_yet.png
:scale: 80 %
4. Edit form - form elements tab active, add a form element menu
(4) Edit form - form elements tab active, add a form element menu
.. image:: _static/bootstrap3/04_edit_form_-_form_elements_tab_active_-_add_element_menu.png
:scale: 80 %
5. Edit form - add a form element (URL plugin)
(5) Edit form - add a form element (URL plugin)
.. image:: _static/bootstrap3/05_edit_form_-_add_form_element_url_plugin.png
:scale: 80 %
6. Edit form - form elements tab active, with form elements
(6) Edit form - form elements tab active, with form elements
.. image:: _static/bootstrap3/06_edit_form_-_form_elements_tab_active_-_with_elements.png
:scale: 80 %
@ -44,57 +44,57 @@ Form elements
Form handlers
+++++++++++++++++++++++++++++++++++++++++++++++
7. Edit form - form handlers tab active, no handlers yet
(7) Edit form - form handlers tab active, no handlers yet
.. image:: _static/bootstrap3/07_edit_form_-_form_handlers_tab_active_-_no_handlers_yet.png
:scale: 80 %
8. Edit form - form handlers tab tactive, add form handler menu
(8) Edit form - form handlers tab tactive, add form handler menu
.. image:: _static/bootstrap3/08_edit_form_-_form_handlers_tab_active_-_add_handler_menu.png
:scale: 80 %
9. Edit form - add a form handler (Mail plugin)
(9) Edit form - add a form handler (Mail plugin)
.. image:: _static/bootstrap3/09_edit_form_-_add_form_handler_mail_plugin.png
:scale: 80 %
10. Edit form - form handlers tab active, with form handlers
(10) Edit form - form handlers tab active, with form handlers
.. image:: _static/bootstrap3/10_edit_form_-_form_handlers_tab_active_with_handlers.png
:scale: 80 %
11. Edit form - form properties tab active
(11) Edit form - form properties tab active
.. image:: _static/bootstrap3/11_edit_form_-_form_properties_tab_active.png
:scale: 80 %
12. View form
(12) View form
.. image:: _static/bootstrap3/12_view_form.png
:scale: 80 %
13. View form - form submitted (thanks page)
(13) View form - form submitted (thanks page)
.. image:: _static/bootstrap3/13_view_form_-_form_submitted.png
:scale: 80 %
14. Edit form - add a form element (Video plugin)
(14) Edit form - add a form element (Video plugin)
.. image:: _static/bootstrap3/14_edit_form_-_add_form_element_video_plugin.png
:scale: 80 %
15. Edit form - add a form element (Boolean plugin)
(15) Edit form - add a form element (Boolean plugin)
.. image:: _static/bootstrap3/15_edit_form_-_add_form_element_boolean_plugin.png
:scale: 80 %
16. Edit form
(16) Edit form
.. image:: _static/bootstrap3/16_edit_form.png
:scale: 80 %
17. View form
(17) View form
.. image:: _static/bootstrap3/17_view_form.png
:scale: 80 %
@ -103,32 +103,32 @@ Simple theme
-----------------------------------------------
View/edit form
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1. Edit form - form elements tab active, with form elements
(1) Edit form - form elements tab active, with form elements
.. image:: _static/simple/01_edit_form_-_form_elements_tab_active_with_elements.png
:scale: 80 %
2. Edit form - form elements tab active, add a form element menu
(2) Edit form - form elements tab active, add a form element menu
.. image:: _static/simple/02_edit_form_-_form_elements_tab_active_add_elements_menu.png
:scale: 80 %
3. Edit form - add a form element (Hidden plugin)
(3) Edit form - add a form element (Hidden plugin)
.. image:: _static/simple/03_edit_form_-_add_form_element_hidden.png
:scale: 80 %
4. Edit form - form handlers tab active, with form handlers
(4) Edit form - form handlers tab active, with form handlers
.. image:: _static/simple/04_edit_form_-_form_handlers_tab_active_with_handlers.png
:scale: 80 %
5. Edit form - form properties tab active
(5) Edit form - form properties tab active
.. image:: _static/simple/05_edit_form_-_form_properties_tab_active.png
:scale: 80 %
6. View form
(6) View form
.. image:: _static/simple/06_view_form.png
:scale: 80 %

View file

@ -214,6 +214,8 @@ Must haves
example as much as possible.
- Improve the "simple" theme for Django 1.6 and Django 1.7 (tiny bits of
styling).
- Finish the Input plugin (some properties of it, like "type" aren't anyhow
used, while they should be).
- Edit form test.
- Edit form element tests.
- Edit from handler tests.

View file

@ -19,8 +19,8 @@ Key concepts
- Each form consists of elements. Form elements are divided
into two groups:
- (a) form fields (input field, textarea, hidden field, file field, etc.).
- (b) content (presentational) elements (text, image, embed video, etc.).
(a) form fields (input field, textarea, hidden field, file field, etc.).
(b) content (presentational) elements (text, image, embed video, etc.).
- Number of form elements is not limited.
- Each form may contain handlers. Handler processes the form data (for example,

View file

@ -61,7 +61,7 @@ for static_dir in static_dirs:
for locale_dir in locale_dirs:
locale_files += [os.path.join(locale_dir, f) for f in os.listdir(locale_dir)]
version = '0.4.14'
version = '0.4.15'
install_requires = [
'Pillow>=2.0.0',

View file

@ -1,6 +1,6 @@
__title__ = 'django-fobi'
__version__ = '0.4.14'
__build__ = 0x00001d
__version__ = '0.4.15'
__build__ = 0x00001e
__author__ = 'Artur Barseghyan <artur.barseghyan@gmail.com>'
__copyright__ = 'Copyright (c) 2014-2015 Artur Barseghyan'
__license__ = 'GPL 2.0/LGPL 2.1'

View file

@ -41,10 +41,10 @@ class BooleanSelectForm(forms.Form, BaseFormFieldPluginForm):
initial = forms.BooleanField(
label = _("Initial"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)
required = forms.BooleanField(
label = _("Required"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)

View file

@ -52,5 +52,5 @@ class DateInputForm(forms.Form, BaseFormFieldPluginForm):
required = forms.BooleanField(
label = _("Required"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)

View file

@ -71,5 +71,5 @@ class DateDropDownInputForm(forms.Form, BaseFormFieldPluginForm):
required = forms.BooleanField(
label = _("Required"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)

View file

@ -52,5 +52,5 @@ class DateTimeInputForm(forms.Form, BaseFormFieldPluginForm):
required = forms.BooleanField(
label = _("Required"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)

View file

@ -54,5 +54,5 @@ class FileInputForm(forms.Form, BaseFormFieldPluginForm):
required = forms.BooleanField(
label = _("Required"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)

View file

@ -48,5 +48,5 @@ class HiddenInputForm(forms.Form, BaseFormFieldPluginForm):
required = forms.BooleanField(
label = _("Required"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)

View file

@ -81,7 +81,7 @@ class InputForm(forms.Form, BaseFormFieldPluginForm):
required = forms.BooleanField(
label = _("Required"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)
placeholder = forms.CharField(
label = _("Placeholder"),
@ -93,17 +93,17 @@ class InputForm(forms.Form, BaseFormFieldPluginForm):
autocomplete_value = forms.BooleanField(
label = _("Auto-complete (HTML5 autocomplete)"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)
autofocus_value = forms.BooleanField(
label = _("Auto-focus (HTML5 autofocus)"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)
disabled_value = forms.BooleanField(
label = _("Disabled"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)
#formnovalidate_value = forms.BooleanField(
# label = _("Skip validation (HTML5 formnovalidate)"),
@ -128,7 +128,7 @@ class InputForm(forms.Form, BaseFormFieldPluginForm):
multiple_value = forms.BooleanField(
label = _("Multiple (HTML5 multiple)"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)
pattern_value = forms.CharField(
label = _("Pattern (HTML5 pattern)"),
@ -138,7 +138,7 @@ class InputForm(forms.Form, BaseFormFieldPluginForm):
readonly_value = forms.BooleanField(
label = _("Read-only (HTML readonly)"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)
step_value = forms.IntegerField(
label = _("Step (HTML5 step)"),

View file

@ -59,7 +59,7 @@ class IntegerInputForm(forms.Form, BaseFormFieldPluginForm):
required = forms.BooleanField(
label = _("Required"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)
placeholder = forms.CharField(
label = _("Placeholder"),

View file

@ -55,7 +55,7 @@ class PasswordInputForm(forms.Form, BaseFormFieldPluginForm):
required = forms.BooleanField(
label = _("Required"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)
placeholder = forms.CharField(
label = _("Placeholder"),

View file

@ -68,5 +68,5 @@ class RadioInputForm(forms.Form, BaseFormFieldPluginForm):
required = forms.BooleanField(
label = _("Required"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)

View file

@ -68,5 +68,5 @@ class SelectInputForm(forms.Form, BaseFormFieldPluginForm):
required = forms.BooleanField(
label = _("Required"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)

View file

@ -56,7 +56,7 @@ class SelectModelObjectInputForm(forms.Form, BaseFormFieldPluginForm):
required = forms.BooleanField(
label = _("Required"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)
def __init__(self, *args, **kwargs):

View file

@ -68,5 +68,5 @@ class SelectMultipleInputForm(forms.Form, BaseFormFieldPluginForm):
required = forms.BooleanField(
label = _("Required"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)

View file

@ -56,7 +56,7 @@ class SelectMultipleModelObjectsInputForm(forms.Form, BaseFormFieldPluginForm):
required = forms.BooleanField(
label = _("Required"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)
def __init__(self, *args, **kwargs):

View file

@ -55,7 +55,7 @@ class TextInputForm(forms.Form, BaseFormFieldPluginForm):
required = forms.BooleanField(
label = _("Required"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)
placeholder = forms.CharField(
label = _("Placeholder"),

View file

@ -47,7 +47,7 @@ class TextareaForm(forms.Form, BaseFormFieldPluginForm):
required = forms.BooleanField(
label = _("Required"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)
placeholder = forms.CharField(
label = _("Placeholder"),

View file

@ -55,7 +55,7 @@ class URLInputForm(forms.Form, BaseFormFieldPluginForm):
required = forms.BooleanField(
label = _("Required"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)
placeholder = forms.CharField(
label = _("Placeholder"),

View file

@ -55,7 +55,7 @@ class CaptchaInputForm(forms.Form, BaseFormFieldPluginForm):
required = forms.BooleanField(
label = _("Required"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)
#placeholder = forms.CharField(
# label = _("Placeholder"),

View file

@ -55,7 +55,7 @@ class HoneypotInputForm(forms.Form, BaseFormFieldPluginForm):
required = forms.BooleanField(
label = _("Required"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)
#placeholder = forms.CharField(
# label = _("Placeholder"),

View file

@ -55,7 +55,7 @@ class ReCaptchaInputForm(forms.Form, BaseFormFieldPluginForm):
required = forms.BooleanField(
label = _("Required"),
required = False,
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_html_class})
widget = forms.widgets.CheckboxInput(attrs={'class': theme.form_element_checkbox_html_class})
)
#placeholder = forms.CharField(
# label = _("Placeholder"),