Reference: Blueprints#
This page contains documentation for available blueprints registered in the factory. This list is auto-generated and contains documentation of the following packages:
yafowil (core package)
yafowil.widget.ace
yafowil.widget.array
yafowil.widget.autocomplete
yafowil.widget.chosen
yafowil.widget.cron
yafowil.widget.datetime
yafowil.widget.dict
yafowil.widget.dynatree
yafowil.widget.image
yafowil.widget.location
yafowil.widget.multiselect
yafowil.widget.recaptcha
yafowil.widget.richtext
yafowil.widget.select2
yafowil.widget.slider
yafowil.widget.wysihtml5
ace#
Add-on blueprint yafowil.widget.ace .
Properties
name |
default |
description |
---|---|---|
mode | 'python' |
ACE Mode.
|
required | False global |
Whether this value is required or not.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
theme | 'github' |
ACE Theme.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
array#
Add-on widget yafowil.widget.array.
Properties
name |
default |
description |
---|---|---|
add | True |
Render
|
class | 'array' |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
error_class | 'error' |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
remove | True |
Render
|
required | False |
Whether this value is required or not.
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
sort | True |
Render
|
static | False |
Array is immutable. No Array actions are rendered. If True,
|
table_class | None |
CSS classes rendered on array table.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
|
autocomplete#
Add-on blueprint yafowil.widget.autocomplete utilizing
jquery.ui.autocomplete
to offer the user a selection based on the input
given so far.
Properties
name |
default |
description |
---|---|---|
class | 'autocomplete' |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
delay | '300' |
Delay in milliseconds.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
minLength | '1' |
Minimum input length to trigger autocomplete.
|
required | False global |
Whether this value is required or not.
|
required_class | 'required' |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
source | required/ not set | Autocomplete source as python iterable or string defining JSON view callback.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
-/- |
-/- |
-/- |
checkbox#
Single checkbox blueprint.
Properties
name |
default |
description |
---|---|---|
autofocus | None global |
Whether this field gets the focus automatically or not (if browser supports it).
|
checked | None |
Set ‘checked’ attribute explicit. If not given, compute by value.
|
class | 'checkbox' |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
data | {} global |
Additional data rendered as HTML5 data attributes on DOM Element.
|
disabled | False |
Flag whether checkbox is disabled.
|
display_proxy | False global |
If ‘True’ and widget mode ‘display’, widget value gets rendered as hidden input.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
format | 'bool' |
Data-type of the extracted value. One out of
|
required | False global |
Whether this value is required or not.
|
required_class | 'required' |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
size | None global |
Allowed input size.
|
title | None global |
Optional help text to be rendered in the title attribute.
|
vocabulary | {True: 'Yes', False: 'No', <UNSET>: 'Unset'} |
In display mode and if
|
with_label | False |
Render empty label tag after visible checkbox in order to make checkbox UI customizable via CSS like so: input.large_checkbox {
display: none;
}
input.large_checkbox + label {
width: 59px;
height: 60px;
background: url('/checkbox_large.png');
}
input.large_checkbox:checked + label {
background: url('/checkbox_large_selected.png');
}
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
chosen#
Add-on blueprint yafowil.widget.chosen .
Properties
name |
default |
description |
---|---|---|
allow_single_deselect | None |
Allow deselection of single elements.
|
class | 'chosen' |
Common CSS-class to put on.
|
data | {} global |
Additional data rendered as HTML5 data attributes on DOM Element.
|
disable_search | None |
Disable search at all.
|
disable_search_threshold | None |
Disable the threshold, when the search popup opens.
|
disabled | None global |
Disables input.
|
max_selected_options | None |
Maximum number of selected options.
|
multivalued | False |
|
new_values | None |
Allow adding new values. For: yafowil js integration. Values: [True|False|None (default)].
|
no_results_text | None |
Text for no results.
|
placeholder_text | None |
Placeholder text.
|
required | False global |
Whether this value is required or not.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
search_contains | None |
Search also for substrings. Allowed values [True|False|None]. When using None or just not setting this value, the default of the Javascript widget is used.
|
single_backstroke_delete | None |
A single backstroke deletes the selected option.
|
template | '%s' global |
Format string with pythons built-in string format template. If a callable
is given it will be used instead and is called with
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
compound#
A blueprint to create a compound of widgets. This blueprint creates a node. A node can contain sub-widgets.
Properties
name |
default |
description |
---|---|---|
structural | False global |
If a compound is structural, it will be omitted in the dotted-path levels and will not have an own runtime-data.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
cron#
Add-on blueprint yafowil.widget.cron .
Properties
name |
default |
description |
---|---|---|
class | 'crontab widget' |
CSS classes for cron widget wrapper DOM element. |
emptyvalue | required/ not set | If cron rule value empty, return as extracted value.
|
lang | None |
End year. Defaults to current year + 9 |
required | False global |
Whether this value is required or not.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
datetime#
Add-on blueprint yafowil.widget.datetime .
Properties
name |
default |
description |
---|---|---|
class | 'datetime' |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
dateinput_class | 'dateinput' |
CSS class rendered on date input field. |
datepicker | False |
Flag whether date picker is enabled.
|
datepicker_class | 'datepicker' |
Flag whether date picker is enabled.
|
delimiter | '.' |
Delimiter used to render date in input field.
|
disabled | False |
Disables input.
|
empty_display_value | None |
Value to display if no datetime value set. Used if widget mode is |
emptyvalue | required/ not set | If configured and received value in request is empty, return as extracted value.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
format | '%Y.%m.%d %H:%M' |
Pattern accepted by
|
locale | 'iso' |
Date input format locale.
|
required | False global |
Whether this value is required or not.
|
required_class | 'required' |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
time | False |
Flag whether time input should be rendered.
|
timeinput_class | 'timeinput' |
CSS class rendered on time input field. |
timepicker | False |
Flag whether time picker is enabled.
|
timepicker_class | 'timepicker' |
jquery.ui timepicker binds to this class.
|
tzinfo | None |
Python datetime tzinfo object.
|
unset_display_value | required/ not set |
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
dict#
Add-on widget yafowil.widget.dict.
Properties
name |
default |
description |
---|---|---|
class | None global |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
error_class | 'error' |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
head | {} |
B/C Labels for dict keys and values columns. Expect a dict containing
|
key_class | 'keyfield' |
CSS classes rendered on key input fields.
|
key_label | <UNSET> |
Label for dict keys column.
|
required | False global |
Whether this value is required or not.
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
static | False |
Flag whether dict is immutable.
|
table_class | 'dictwidget' |
CSS classes rendered on dict table.
|
value_class | 'valuefield' |
CSS classes rendered on value input fields.
|
value_label | <UNSET> |
Label for dict values column.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
div#
Blueprint rendering a ‘<div>’ element.
This is a hybrid blueprint. Check leaf
property for details.
Properties
name |
default |
description |
---|---|---|
class | None |
CSS classes for div tag.
|
class_add | None global |
Additional CSS-class to put on.
|
data | None |
Dict containing data attributes for div tag. |
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
id | None |
Id attribute for div tag.
|
leaf | None global |
Leaf property can be used in conjunction with If set True, it causes bypassing auto delegation of extraction and rendering
to This is useful if mixing blueprints which renders and handles compounds on it’s own with blueprints using hybrid rendering and extraction in order to prevent side effects due to multiple child rendering and extraction.
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
email#
Email (HTML5) input blueprint.
Properties
name |
default |
description |
---|---|---|
allowed_datatypes | [<class 'bytes'>, <class 'str'>] |
List of allowed datatypes. If
|
class | 'email' |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
datatype | None global |
Callable for converting extracted value to output datatype.
Custom converter callables must raise one out of the following exceptions if conversion fails:
|
datatype_message | None global |
Custom extraction error message if
|
display_proxy | False global |
If ‘True’ and widget mode ‘display’, widget value gets rendered as hidden input.
|
emptyvalue | required/ not set | If configured and received value in request is empty, return as extracted value.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
required | False global |
Whether this value is required or not.
|
required_class | 'required' |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
template | '%s' global |
Format string with pythons built-in string format template. If a callable
is given it will be used instead and is called with
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
error#
Renders a tag with an error-message and the prior rendered output.
Properties
name |
default |
description |
---|---|---|
class | 'error' |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
message_class | 'errormessage' |
CSS class to apply to inner message-tag.
|
message_tag | 'div' |
HTML tag to use to enclose each error message.
|
position | 'inner-before' |
Error can be rendered at 3 different positions:
|
render_empty | False |
Render tag even if there is no error message.
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
tag | 'div' |
HTML tag to use to enclose all error messages.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
-/- |
|
|
-/- |
-/- |
field#
Renders a div with an class field around the prior rendered output. This is supposed to be used for styling and grouping purposes.
Properties
name |
default |
description |
---|---|---|
class | 'field' |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
witherror | None |
Put the class given with this property on the div if an error happened.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
-/- |
|
|
-/- |
-/- |
fieldset#
Renders a fieldset around the prior rendered output.
Properties
name |
default |
description |
---|---|---|
class | None |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
legend | False |
Content of legend tag if legend should be rendered.
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
structural | False global |
If a compound is structural, it will be omitted in the dotted-path levels and will not have an own runtime-data.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
file#
A basic file upload blueprint.
Properties
name |
default |
description |
---|---|---|
accept | None |
Accepted mimetype.
|
autofocus | None global |
Whether this field gets the focus automatically or not (if browser supports it).
|
class | None global |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
placeholder | None global |
Whether this input has a placeholder value or not (if browser supports it).
|
required | False global |
Whether this value is required or not.
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
form#
A html-form element as a compound of widgets.
Properties
name |
default |
description |
---|---|---|
action | required/ not set | Target web address (URL) to send the form to.
|
class | None global |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
enctype | 'multipart/form-data' |
Encryption type of the form. Only relevant for method
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
method | 'post' |
One out of
|
novalidate | True |
Flag whether HTML5 form validation should be suppressed.
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
structural | False global |
If a compound is structural, it will be omitted in the dotted-path levels and will not have an own runtime-data.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
help#
Renders a tag with an help-message and the prior rendered output.
Properties
name |
default |
description |
---|---|---|
class | 'help' |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
help | '' |
Help text.
|
position | 'before' |
Help can be rendered at 3 different positions:
|
render_empty | False |
Render tag even if there is no help message.
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
tag | 'div' |
HTML tag to use to enclose all help messages.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
-/- |
|
|
-/- |
-/- |
image#
Add-on widget yafowil.widget.image.
Properties
name |
default |
description |
---|---|---|
accept | 'image/*' |
Accepted mimetype of image.
|
alt | '' |
Image alternative text.
|
autofocus | None global |
Whether this field gets the focus automatically or not (if browser supports it).
|
class | 'image' |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
crop | None |
Crop extracted file to size at offset. The created cropped image gets placed
in the return value returned by file extractor under key
|
error_class | 'error' |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
maxdpi | None |
Maximum DPI of image defined as 2-tuple containing (x, y).
|
maxsize | None |
Maximum size of image defined as 2-tuple containing (width, height) in pixel as integer.
|
mindpi | None |
Minimum DPI of image defined as 2-tuple containing (x, y).
|
minsize | None |
Minimum size of image defined as 2-tuple containing (width, height) in pixel as integer.
|
placeholder | None global |
Whether this input has a placeholder value or not (if browser supports it).
|
required | False |
Whether this value is required or not.
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
scales | None |
Scales to create on extraction. Scales are defined as dict, where the key
represents the scale name and the value is a 2-tuple containing (width, height)
in pixel. The created scales get placed in the return value returned by file
extractor under key
|
src | None |
Image URL if image present and displaying is desired.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
label#
Label blueprint.
Properties
name |
default |
description |
---|---|---|
class | None global |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
for | None |
Optional dottedpath of widget to be labled
|
label | required/ not set | Text to be displayed as a label.
|
position | 'before' |
Label can be rendered at 3 different positions:
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
-/- |
|
|
-/- |
-/- |
lines#
Lines blueprint. Renders a textarea and extracts lines as list.
Properties
name |
default |
description |
---|---|---|
allowed_datatypes | <UNSET> global |
List of allowed datatypes. If
|
autofocus | None global |
Whether this field gets the focus automatically or not (if browser supports it).
|
class | 'lines' |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
cols | 40 |
Number of characters.
|
data | {} global |
Additional data rendered as HTML5 data attributes on DOM Element.
|
datatype | None global |
Callable for converting extracted value to output datatype.
Custom converter callables must raise one out of the following exceptions if conversion fails:
|
datatype_message | None global |
Custom extraction error message if
|
disabled | None global |
Disables input.
|
display_proxy | False global |
If ‘True’ and widget mode ‘display’, widget value gets rendered as hidden input.
|
emptyvalue | required/ not set | If configured and received value in request is empty, return as extracted value.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
placeholder | None global |
Whether this input has a placeholder value or not (if browser supports it).
|
readonly | None |
Flag textarea is readonly.
|
required | False global |
Whether this value is required or not.
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
rows | 8 |
Number of lines.
|
title | None global |
Optional help text to be rendered in the title attribute.
|
wrap | None |
Either
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
location#
Add-on blueprint yafowil.widget.location
Properties
name |
default |
description |
---|---|---|
class | 'location' |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
error_class | 'error' |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
lat | 47.2667 |
Initial map center point latitude (north/south).
|
lon | 11.3833 |
Initial map center point longitude (east/west).
|
min_zoom | 2 |
Maximum map zoom level. |
required | False |
Whether this value is required or not.
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
zoom | 12 |
Initial map zoom level.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
multiselect#
Add-on blueprint yafowil.widget.multiselect .
Properties
name |
default |
description |
---|---|---|
autofocus | None global |
Whether this field gets the focus automatically or not (if browser supports it).
|
block_class | required/ not set |
|
class | 'multiselect' |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
data | {} global |
Additional data rendered as HTML5 data attributes on DOM Element.
|
datatype | None global |
Callable for converting extracted value to output datatype.
Custom converter callables must raise one out of the following exceptions if conversion fails:
|
disabled | None global |
Disables input.
|
emptyvalue | required/ not set | If configured and received value in request is empty, return as extracted value.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
format | 'block' |
|
label_checkbox_class | required/ not set |
|
label_radio_class | required/ not set |
|
listing_label_position | required/ not set |
|
listing_tag | required/ not set |
|
multivalued | True |
|
placeholder | None global |
Whether this input has a placeholder value or not (if browser supports it).
|
required | False global |
Whether this value is required or not.
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
size | None |
Allowed input size.
|
template | '%s' global |
Format string with pythons built-in string format template. If a callable
is given it will be used instead and is called with
|
title | None global |
Optional help text to be rendered in the title attribute.
|
vocabulary | required/ not set |
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
number#
Number blueprint (HTML5).
Properties
name |
default |
description |
---|---|---|
allowed_datatypes | [<class 'int'>, <class 'float'>, 'int', 'integer', 'float'] |
List of allowed datatypes. If
|
class | 'number' |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
datatype | <class 'float'> |
Callable for converting extracted value to output datatype. Allowed datatypes
are
|
datatype_message | None global |
Custom extraction error message if
|
display_proxy | False global |
If ‘True’ and widget mode ‘display’, widget value gets rendered as hidden input.
|
emptyvalue | <UNSET> |
If configured and received value in request is empty, return as extracted value.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
max | None |
Maximum value.
|
min | None |
Minimum value.
|
required | False global |
Whether this value is required or not.
|
required_class | 'required' |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
step | None |
Stepping value must be in.
|
template | '%s' global |
Format string with pythons built-in string format template. If a callable
is given it will be used instead and is called with
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
password#
Password blueprint.
The password is never rendered to markup, instead
yafowil.common.PASSWORD_NOCHANGE_VALUE
is set as value
property on
dom element. See yafowil.common.password_extractor
for details on
password extraction.
Properties
name |
default |
description |
---|---|---|
ascii | False |
Flag ascii check should performed.
|
autocomplete | None global |
Switch autocomplete explizit to
|
autofocus | None global |
Whether this field gets the focus automatically or not (if browser supports it).
|
class | 'password' |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
data | {} global |
Additional data rendered as HTML5 data attributes on DOM Element.
|
disabled | None global |
Disables input.
|
displayplaceholder | '********' |
Placeholder shown in display mode if password was set.
|
emptyvalue | required/ not set | If configured and received value in request is empty, return as extracted value.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
minlength | -1 |
Minimum length of password.
|
placeholder | None global |
Whether this input has a placeholder value or not (if browser supports it).
|
required | False global |
Whether this value is required or not.
|
required_class | 'required' |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
size | None global |
Maximum length of password.
|
strength | -1 |
Integer value <= 4. Define how many rules must apply to consider a password valid.
|
title | None global |
Optional help text to be rendered in the title attribute.
|
weak_password_message | 'Password too weak' global |
Message shown if password is not strong enough.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
proxy#
Bypass arguments out of form namespace using a hidden field.
Properties
name |
default |
description |
---|---|---|
allowed_datatypes | <UNSET> global |
List of allowed datatypes. If
|
class | None |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
datatype | None global |
Callable for converting extracted value to output datatype.
Custom converter callables must raise one out of the following exceptions if conversion fails:
|
datatype_message | None global |
Custom extraction error message if
|
emptyvalue | required/ not set | If configured and received value in request is empty, return as extracted value.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
richtext#
Add-on blueprint yafowil.widget.richtext .
Properties
name |
default |
description |
---|---|---|
cols | 80 |
Number of characters. |
mimetypes | ['text/html'] |
List of mimetypes. |
mimetypes_class | '' |
CSS class to be set on mimetypes selection. |
mimetypes_data | {} |
Dict containing data attributes to render on mimetypes selection. |
readonly | None |
Flag for readonly. |
required | False global |
Whether this value is required or not.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
rows | 25 |
Number of lines. |
wrap | None |
Either |
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
search#
Search blueprint (HTML5).
Properties
name |
default |
description |
---|---|---|
class | 'search' |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
display_proxy | False global |
If ‘True’ and widget mode ‘display’, widget value gets rendered as hidden input.
|
emptyvalue | required/ not set | If configured and received value in request is empty, return as extracted value.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
required | False global |
Whether this value is required or not.
|
required_class | 'required' |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
template | '%s' global |
Format string with pythons built-in string format template. If a callable
is given it will be used instead and is called with
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
select#
Selection Blueprint. Single selection as dropdown or radio-buttons. Multiple selection as selection-list or as checkboxes.
Properties
name |
default |
description |
---|---|---|
allowed_datatypes | <UNSET> global |
List of allowed datatypes. If
|
autofocus | None global |
Whether this field gets the focus automatically or not (if browser supports it).
|
block_class | None |
CSS class to render on selection if block format.
|
checkbox_label_class | None |
CSS class to render on checkbox labels. |
checkbox_wrapper_class | None |
CSS class to render on checkbox wrapper. |
class | 'select' |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
data | {} global |
Additional data rendered as HTML5 data attributes on DOM Element.
|
datatype | None global |
Callable for converting extracted value to output datatype.
Custom converter callables must raise one out of the following exceptions if conversion fails:
|
datatype_message | None global |
Custom extraction error message if
|
disabled | None global |
Disables the whole widget or single selections. To disable the whole widget
set the value to ‘True’. To disable single selection pass a iterable of keys to
disable, i.e.
|
display_proxy | False global |
If ‘True’ and widget mode ‘display’, widget value gets rendered as hidden input.
|
emptyvalue | required/ not set | If configured and received value in request is empty, return as extracted value.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
format | 'block' |
Every value except ‘block’ results in either a list of radio buttons or checkboxes depending on the ‘multivalued’ property.
|
label_checkbox_class | None |
CSS class to render on checkbox labels. This property is deprecated and will be remove as of yafowil 2.2. Use
|
label_radio_class | None |
CSS class to render on radio button labels. This property is deprecated and will be remove as of yafowil 2.2. Use
|
listing_label_position | 'inner-after' |
Label position if format is ‘single’. Behaves the same way as label widget position property.
|
listing_tag | 'div' |
Desired rendering tag for selection if selection format is ‘single’. Valid values are ‘div’ and ‘ul’.
|
multivalued | None |
Flag whether multiple items can be selected.
|
placeholder | None global |
Whether this input has a placeholder value or not (if browser supports it).
|
radio_label_class | None |
CSS class to render on radio button labels. |
radio_wrapper_class | None |
CSS class to render on radio button wrapper. |
required | False global |
Whether this value is required or not.
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
size | None |
Size of input if multivalued and format ‘block’.
|
template | '%s' global |
Format string with pythons built-in string format template. If a callable
is given it will be used instead and is called with
|
title | None global |
Optional help text to be rendered in the title attribute.
|
vocabulary | required/ not set | Vocabulary to be used for the selection list. Expects a dict-like or an
iterable or a callable which returns one of both first. An iterable can consist
out of strings or out of tuples with
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
select2#
Properties
name |
default |
description |
---|---|---|
adaptContainerCssClass | None |
Function that filters/renames css classes as they are copied from the source tag to the select2 container tag: adaptContainerCssClass(clazz)
The default implementation applies all classes without modification.
|
adaptDropdownCssClass | None |
Function that filters/renames css classes as they are copied from the source tag to the select2 dropdown tag: adaptDropdownCssClass(clazz)
The default implementation always returns null thereby filtering out all classes.
|
ajax | None |
Options for the built in ajax query function. This object acts as a shortcut for having to manually write a function that performs ajax requests. The built-in function supports more advanced features such as throttling and dropping out-of-order responses. In order for this function to work Select2 should be attached to a input type=’hidden’ tag instead of a select.
|
ajaxurl | None |
Ajax URL to JSON view returning an array of objects like: [{id: 'id', text: 'text'}]
|
allowClear | None |
Whether or not a clear button is displayed when the select box has a selection. The button, when clicked, resets the value of the select box back to the placeholder, thus this option is only available when the placeholder is specified. This option only works when the placeholder is specified. When attached to a select an option with an empty value must be provided. This is the option that will be selected when the button is pressed since a select box requires at least one selection option. Also, note that this option only works with non-multi-value based selects because multi-value selects always provide such a button for every selected option.
|
closeOnSelect | None |
If set to false the dropdown is not closed after a selection is made, allowing for rapid selection of multiple items. By default this option is set to true. Only applies when configured in multi-select mode.
|
containerCss | None |
Inline css that will be added to select2’s container. Either an object containing css property/value key pairs or a function that returns such an object.
|
containerCssClass | None |
Css class that will be added to select2’s container tag.
|
createSearchChoice | None |
Creates a new selectable choice from user’s search term. Allows creation of choices not available via the query function. Useful when the user can create choices on the fly, eg for the ‘tagging’ usecase: createSearchChoice(term)
If the function returns undefined or null no choice will be created. If a new choice is created it is displayed first in the selection list so that user may select it by simply pressing enter. When used in combination with input[type=hidden] tag care must be taken to sanitize the id attribute of the choice object, especially stripping , as it is used as a value separator.
|
createSearchChoicePosition | None |
Define the position where to insert element created by createSearchChoice. The following values are supported:
|
data | None |
Options for the built in query function that works with arrays. If this element contains an array, each element in the array must contain id and text keys. Alternatively, this element can be specified as an object in which results key must contain the data as an array and a text key can either be the name of the key in data items that contains text or a function that retrieves the text given a data element from the array.
|
dropdownAutoWidth | None |
When set to true attempts to automatically size the width of the dropdown based on content inside.
|
dropdownCss | None |
Inline css that will be added to select2’s dropdown container. Either an object containing css property/value key pairs or a function that returns such an object.
|
dropdownCssClass | None |
Css class that will be added to select2’s dropdown container.
|
escapeMarkup | None |
String escapeMarkup(String markup) Function used to post-process markup returned from formatter functions. By default this function escapes html entities to prevent javascript injection.
|
formatInputTooLong | None |
String containing “Search input too long” message, or Function used to render the message: formatInputTooLong(term, maxLength)
|
formatInputTooShort | None |
String containing “Search input too short” message, or Function used to render the message: formatInputTooShort(term, minLength)
|
formatLoadMore | None |
String containing “Loading more results” message, or Function used to render the message: formatLoadMore(pageNumber)
|
formatNoMatches | None |
String containing “No matches” message, or Function used to render the message: formatNoMatches(term)
|
formatResult | None |
Function used to render a result that the user can select: formatResult(object, container, query)
The default implementation expects the object to have a text property that is returned. The implementation may choose to append elements directly to the provided container object, or return a single value and have it automatically appended. When attached to a select the original <option> (or <optgroup>) element is accessible inside the specified function through the property item.element: format(item) {
var originalOption = item.element;
return item.text
}
|
formatResultCssClass | None |
Function used to add css classes to result elements: formatResultCssClass(object)
By default when attached to a select css classes from options will be automatically copied.
|
formatSearching | None |
String containing “Searching…” message, or Function used to render the message that is displayed while search is in progress: formatSearching()
|
formatSelection | None |
Function used to render the current selection: formatSelection(object, container)
The default implementation expects the object to have a text property that is returned. The implementation may choose to append elements directly to the provided container object, or return a single value and have it automatically appended. When attached to a select the original <option> (or <optgroup>) element is accessible inside the specified function through the property item.element: format(item) {
var originalOption = item.element;
return item.text
}
|
formatSelectionTooBig | None |
String containing “You cannot select any more choices” message, or Function used to render the message: formatSelectionTooBig(maxSize)
|
id | None |
Function used to get the id from the choice object or a string representing the key under which the id is stored: id(object)
The default implementation expects the object to have a id property that is returned.
|
initSelection | None |
Called when Select2 is created to allow the user to initialize the selection based on the value of the element select2 is attached to. Essentially this is an id->object mapping function: initSelection(element, callback)
This function will only be called when there is initial input to be processed.
|
inputtag | False |
Render widget as input element instead of selection.
|
loadMorePadding | None |
Defines how many pixels need to be below the fold before the next page is loaded. The default value is 0 which means the result list needs to be scrolled all the way to the bottom for the next page of results to be loaded. This option can be used to trigger the load sooner, possibly resulting in a smoother user experience.
|
matcher | None |
Used to determine whether or not the search term matches an option when a built-in query function is used. The built in query function is used when Select2 is attached to a select, or the local or tags helpers are used: matcher(term, text, option)
The default implementation is case insensitive and matches anywhere in the term: function(term, text) {
return text.toUpperCase().indexOf(term.toUpperCase()) >= 0;
}
|
maximumInputLength | None |
Maximum number of characters that can be entered for an input.
|
maximumSelectionSize | None |
The maximum number of items that can be selected in a multi-select control. If this number is less than 1 selection is not limited. Once the number of selected items reaches the maximum specified the contents of the dropdown will be populated by the formatSelectionTooBig function.
|
minimumInputLength | None |
Number of characters necessary to start a search.
|
minimumResultsForSearch | None |
The minimum number of results that must be initially (after opening the dropdown for the first time) populated in order to keep the search field. This is useful for cases where local data is used with just a few results, in which case the search box is not very useful and wastes screen space. The option can be set to a negative value to permanently hide the search field. Only applies to single-value select boxes.
|
multiple | None |
Whether or not Select2 allows selection of multiple values. When Select2 is attached to a select element this value will be ignored and select’s multiple attribute will be used instead.
|
nextSearchTerm | None |
Function used to determine what the next search term should be. Function can be used when the dropdown is configured in single and multi-select mode. It is triggered after selecting an item. In single mode it is also triggered after initSelection (when provided).
|
openOnEnter | None |
If set to true the dropdown is opened when the user presses the enter key and Select2 is closed. By default this option is enabled.
|
placeholder | None |
Initial value that is selected if no other selection is made. The placeholder can also be specified as a data-placeholder attribute on the select or input element that Select2 is attached to. Note that because browsers assume the first option element is selected in non-multi-value select boxes an empty first option element must be provided (<option></option>) for the placeholder to work.
|
placeholderOption | None |
When attached to a select resolves the option that should be used as the placeholder. Can either be a function which given the select element should return the option element or a string first to indicate that the first option should be used. This option is useful when Select2’s default of using the first option only if it has no value and no text is not suitable.
|
query | None |
Function used to query results for the search term: query(options)
In order for this function to work Select2 should be attached to a input type=’hidden’ tag instead of a select.
|
required | False global |
Whether this value is required or not.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
selectOnBlur | None |
Set to true if you want Select2 to select the currently highlighted option when it is blurred.
|
separator | None |
Separator character or string used to delimit ids in value attribute of the multi-valued selects. The default delimiter is the , character.
|
sortResults | None |
Used to sort the results list for searching right before display. Useful for sorting matches by relevance to the user’s search term: sortResults(results, container, query)
Defaults to no sorting: function(results, container, query) {
return results;
}
|
tags | None |
Puts Select2 into ‘tagging’ mode where the user can add new choices and pre-existing tags are provided via this options attribute which is either an array or a function that returns an array of objects or strings. If strings are used instead of objects they will be converted into an object that has an id and text attribute equal to the value of the string.
|
tokenSeparators | None |
An array of strings that define token separators for the default tokenizer function. By default, this option is set to an empty array which means tokenization using the default tokenizer is disabled. Usually it is sensible to set this option to a value similar to [‘,’, ‘ ‘].
|
tokenizer | None |
A tokenizer function can process the input typed into the search field after every keystroke and extract and select choices. This is useful, for example, in tagging scenarios where the user can create tags quickly by separating them with a comma or a space instead of pressing enter. Tokenizer only applies to multi-selects: tokenizer(input, selection, selectCallback, opts)
|
width | None |
Controls the width style attribute of the Select2 container div. The following values are supported:
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
slider#
Add-on blueprint yafowil.widget.slider .
Properties
name |
default |
description |
---|---|---|
change | None |
Optional Javascript
|
data | {} |
Additional data redered as HTML data attributes on slider wrapper DOM Element.
|
height | None |
Height of slider if orientation is
|
max | None |
Maximum slider value value. Defaults to 100.
|
min | None |
Minimum slider value. Defaults to 0.
|
orientation | None |
Slider Orientation. Either
|
range | None |
Slider Range. Either
|
show_value | False |
Show value in addition to slider.
|
slide | None |
Optional Javascript
|
step | None |
Snap slider to increments.
|
unit | '' |
Slider value unit.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
submit#
Submit action inside the form
Properties
name |
default |
description |
---|---|---|
action | True |
Marks this widget as an action. One out of
|
class | None global |
Common CSS-class to put on.
|
expression | True |
Flag or expression callable whether this action is available to the user or not.
|
handler | required/ not set | Handler is a callable which get called if this action performs. It expects two
parameters:
|
label | required/ not set | Label of the submit.
|
next | required/ not set | Next is a callable expected to return the web address. It expects a request as the only parameter.
|
skip | False |
Skips action and only perform next. One out of
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
-/- |
|
|
-/- |
-/- |
table#
<table>
compound widget for table creation.
Properties
name |
default |
description |
---|---|---|
class | None global |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
id | required/ not set | Value of table id attribute.
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
structural | False global |
If a compound is structural, it will be omitted in the dotted-path levels and will not have an own runtime-data.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
tag#
Render HTML tags with text. Useful for rendering headings etc.
Properties
name |
default |
description |
---|---|---|
class | None global |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
data | {} global |
Additional data rendered as HTML5 data attributes on DOM Element.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
tag | required/ not set | HTML tag name.
|
text | required/ not set | Tag contents.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
-/- |
|
|
-/- |
-/- |
tbody#
<tbody>
compound widget for table creation.
Properties
name |
default |
description |
---|---|---|
structural | False global |
If a compound is structural, it will be omitted in the dotted-path levels and will not have an own runtime-data.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
td#
<td>
compound widget for table creation.
Properties
name |
default |
description |
---|---|---|
class | None global |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
colspan | required/ not set | Value of colspan attribute.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
id | required/ not set | Value of id attribute.
|
leaf | None global |
Leaf property can be used in conjunction with If set True, it causes bypassing auto delegation of extraction and rendering
to This is useful if mixing blueprints which renders and handles compounds on it’s own with blueprints using hybrid rendering and extraction in order to prevent side effects due to multiple child rendering and extraction.
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
rowspan | required/ not set | Value of rowspan attribute.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
text#
One line text input blueprint.
Properties
name |
default |
description |
---|---|---|
allowed_datatypes | <UNSET> global |
List of allowed datatypes. If
|
autocomplete | None global |
Switch autocomplete explizit to
|
autofocus | None global |
Whether this field gets the focus automatically or not (if browser supports it).
|
class | 'text' |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
data | {} global |
Additional data rendered as HTML5 data attributes on DOM Element.
|
datatype | None global |
Callable for converting extracted value to output datatype.
Custom converter callables must raise one out of the following exceptions if conversion fails:
|
datatype_message | None global |
Custom extraction error message if
|
disabled | False |
Flag input field is disabled.
|
display_proxy | False global |
If ‘True’ and widget mode ‘display’, widget value gets rendered as hidden input.
|
emptyvalue | required/ not set | If configured and received value in request is empty, return as extracted value.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
placeholder | None global |
Whether this input has a placeholder value or not (if browser supports it).
|
required | False global |
Whether this value is required or not.
|
required_class | 'required' |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
size | None global |
Allowed input size.
|
template | '%s' global |
Format string with pythons built-in string format template. If a callable
is given it will be used instead and is called with
|
title | None global |
Optional help text to be rendered in the title attribute.
|
type | 'text' |
Type of input tag. |
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
textarea#
HTML textarea blueprint.
Properties
name |
default |
description |
---|---|---|
autofocus | None global |
Whether this field gets the focus automatically or not (if browser supports it).
|
class | 'textarea' |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
cols | 80 |
Number of characters.
|
data | {} global |
Additional data rendered as HTML5 data attributes on DOM Element.
|
disabled | None global |
Disables input.
|
display_proxy | False global |
If ‘True’ and widget mode ‘display’, widget value gets rendered as hidden input.
|
emptyvalue | required/ not set | If configured and received value in request is empty, return as extracted value.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
placeholder | None global |
Whether this input has a placeholder value or not (if browser supports it).
|
readonly | None |
Flag textarea is readonly.
|
required | False global |
Whether this value is required or not.
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
rows | 25 |
Number of lines.
|
template | '%s' global |
Format string with pythons built-in string format template. If a callable
is given it will be used instead and is called with
|
title | None global |
Optional help text to be rendered in the title attribute.
|
wrap | None |
Either
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
th#
<th>
compound widget for table creation.
Properties
name |
default |
description |
---|---|---|
class | None global |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
colspan | required/ not set | Value of colspan attribute.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
id | required/ not set | Value of id attribute.
|
label | required/ not set | Explicit th content. If absent, rendered markup from downstream blueprint(s) is used.
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
rowspan | required/ not set | Value of rowspan attribute.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
-/- |
|
|
-/- |
-/- |
thead#
<thead>
compound widget for table creation.
Properties
name |
default |
description |
---|---|---|
structural | False global |
If a compound is structural, it will be omitted in the dotted-path levels and will not have an own runtime-data.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
time#
Add-on blueprint yafowil.widget.datetime .
Properties
name |
default |
description |
---|---|---|
class | 'time' |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
daytime | False |
Flag whether value is day of time. Setting this property or ‘timepicker’ property above to True results in day time range validation.
|
disabled | False |
Disables input.
|
emptyvalue | required/ not set | If configured and received value in request is empty, return as extracted value.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
format | 'string' |
Define widget value and extraction format. Either ‘string’, ‘number’ or ‘tuple’.
|
required | False global |
Whether this value is required or not.
|
required_class | 'required' |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
timeinput_class | 'timeinput' |
CSS class rendered on time input field. |
timepicker | False |
Flag whether time picker is enabled.
|
timepicker_class | 'timepicker' |
jquery.ui timepicker binds to this class.
|
unit | 'hours' |
Only considered if ‘format’ is ‘number’. If unit is ‘hours’ value is float, otherwise integer.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
tr#
<tr>
compound widget for table creation.
Properties
name |
default |
description |
---|---|---|
class | None global |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
id | required/ not set | Value of id attribute.
|
required_class | None global |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
structural | False global |
If a compound is structural, it will be omitted in the dotted-path levels and will not have an own runtime-data.
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
url#
URL aka web address (HTML5) input blueprint.
Properties
name |
default |
description |
---|---|---|
class | 'url' |
Common CSS-class to put on.
|
class_add | None global |
Additional CSS-class to put on.
|
display_proxy | False global |
If ‘True’ and widget mode ‘display’, widget value gets rendered as hidden input.
|
emptyvalue | required/ not set | If configured and received value in request is empty, return as extracted value.
|
error_class | None global |
CSS-class to put on in case of error.
|
error_class_default | 'error' global |
Fallback CSS-class to put on in case of error if no specific class was given.
|
required | False global |
Whether this value is required or not.
|
required_class | 'required' |
CSS-class to put on in case if required condition was not met.
|
required_class_default | 'required' global |
CSS-class to apply if required condition was not met - if no specific class was given.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
template | '%s' global |
Format string with pythons built-in string format template. If a callable
is given it will be used instead and is called with
|
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |
wysihtml5#
Add-on blueprint yafowil.widget.wysihtml5 .
Properties
name |
default |
description |
---|---|---|
color | None |
Show the color styles toolbar buttons. Options: bootstrap-wysihtml5. Values: [True|False|None (use default)].
|
cols | 80 |
Number of characters. |
emphasis | None |
Show the emphasis toolbar buttons. Options: bootstrap-wysihtml5. Values: [True|False|None (use default)].
|
font-styles | None |
Show the font styles toolbar buttons. Options: bootstrap-wysihtml5. Values: [True|False|None (use default)].
|
html | None |
Show the html toolbar button. Options: bootstrap-wysihtml5. Values: [True|False|None (use default)].
|
image | None |
Show the image toolbar buttons. Options: bootstrap-wysihtml5. Values: [True|False|None (use default)].
|
justify | None |
Show the justify styles toolbar buttons. Options: bootstrap-wysihtml5. Values: [True|False|None (use default)].
|
link | None |
Show the link toolbar button. Options: bootstrap-wysihtml5. Values: [True|False|None (use default)].
|
lists | None |
Show the list toolbar buttons. Options: bootstrap-wysihtml5. Values: [True|False|None (use default)].
|
readonly | None |
Flag for readonly. |
required | False global |
Whether this value is required or not.
|
required_message | 'Mandatory field was empty' global |
Message to be shown if required condition was not met.
|
rows | 10 |
Number of lines. |
size | None |
Size of toolbar buttons. Options: bootstrap-wysihtml5. Values: [‘lg’|’sm’|’sx’|None (default)].
|
wrap | None |
Either |
Chains
extractors |
edit renderers |
display renderers |
preprocessors |
builders |
---|---|---|---|---|
|
|
|
-/- |
-/- |