Skip to content
Snippets Groups Projects
Commit 49611da0 authored by Matthieu Fesselier's avatar Matthieu Fesselier
Browse files

update: presentation fixes

parent 6362e15e
No related branches found
No related tags found
2 merge requests!19Enum dropdown radio solid-form-search,!6Core 0.10
Showing with 153 additions and 91 deletions
......@@ -39,14 +39,14 @@ Please check their documentation to know more about their capabilities.
Attributes
----------
fields
~~~~~~
``fields``
~~~~~~~~~~
By default, all displayed fields are direct children of
``<solid-display>``. Make sure you don’t give your set the same name as
a field as it would result in an infinite loop.
child-xyz
~~~~~~~~~~~~~~~~
``child-xyz``
~~~~~~~~~~~~~
add attribute ``xyz`` to all children.
......
......@@ -45,8 +45,7 @@ added to interact with the list of data being displayed.
``fields``
~~~~~~~~~~
List of the fields to display in a popup which opens when a marker is clicked. If the attribute is not defined, no popup will show up.
List of the fields to display in a popup which opens when a marker is clicked. If the attribute is not defined, no popup will show up.
Events
-------
......
......@@ -14,7 +14,7 @@ Attributes
----------
``counter-template``
~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~~~~~
Template used to show the number of resources.
It takes a string in which you can use HTML
tags, and the ``counter`` variable to add the number.
......
......@@ -34,7 +34,7 @@ Attributes
``group-by-widget``
~~~~~~~~~~~~~~~~~~~
*default: ``solid-group-div``*
default: ``solid-group-div``
The name of the widget to use as a group widget.
......
highlighter-mixin
==========
=================
The highlighter mixin is a post-processor mixin, compatible with list-mixin.
It provides the ability to put some resources at the top of the list, depending of the values of their properties.
......@@ -14,7 +14,7 @@ Attributes
----------
``highlight-[field]``
~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~~~~~
Put the resource at the top of the list if ``[field]`` is equal to the attribute value.
In this example, all the users with a ``first_name`` equal to ``pierre`` will be at the beginning of the list.
......
......@@ -63,8 +63,8 @@ Attributes
~~~~~~~~~~~~~~~~~~
The widget to be used to display the ``[field]``
default-widget
~~~~~~~~~~~~~~~~
``default-widget``
~~~~~~~~~~~~~~~~~~
The widget to use for all the fields, except if a specific one is defined for a field.
``action-[field]``
......
......@@ -3,26 +3,46 @@ Display widgets
Startin'blox provides a list of default widgets to display content:
- ``solid-display-value``: Displays the value.
- ``solid-display-div``: Displays the ``value`` inside a ``<div>``
HTML tag.
- ``solid-display-labelled-div``: Displays the ``value`` inside a
``<div>`` HTML tag, after the ``label`` contained in a ``<label>``
HTML tag
- ``solid-display-multiline``:Displays the ``value`` inside a
``<div>``, ``\n`` are replaced by ``<br>``.
- ``solid-display-labelled-boolean``: Displays the ``label`` inside a
``<label>`` HTML tag if the ``value`` is true
- ``solid-display-img``: Inserts the ``value`` as the src attribute
value of an ``<img>`` HTML tag.
- ``solid-display-mailto``: Displays a link inside a ``<a>`` HTML tag
with a ``mailto:value`` as path. If a label is defined for this
field, it’s displayed as the content of the link.
- ``solid-display-tel``: Displays a link inside a ``<a>`` HTML tag
with a ``tel:value`` as path
- ``solid-display-link``: Displays a link inside a ``<a>`` HTML tag
with the value as path, and the label as text content
- ``solid-display-date``: Displays a date in the browser’s default
locale format
- ``solid-display-date-time``: Displays a date and a time in the
browser’s default locale format
``solid-display-value``
~~~~~~~~~~~~~~~~~~~~~~~
Displays the value.
``solid-display-div``
~~~~~~~~~~~~~~~~~~~~~
Displays the ``value`` inside a ``<div>`` HTML tag.
``solid-display-labelled-div``
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Displays the ``value`` inside a ``<div>`` HTML tag, after the ``label`` contained in a ``<label>`` HTML tag.
``solid-display-multiline``
~~~~~~~~~~~~~~~~~~~~~~~~~~~
Displays the ``value`` inside a ``<div>``, ``\n`` are replaced by ``<br>``.
``solid-display-labelled-boolean``
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Displays the ``label`` inside a ``<label>`` HTML tag if the ``value`` is true.
``solid-display-img``
~~~~~~~~~~~~~~~~~~~~~
Inserts the ``value`` as the src attribute value of an ``<img>`` HTML tag.
``solid-display-mailto``
~~~~~~~~~~~~~~~~~~~~~~~~~
Displays a link inside a ``<a>`` HTML tag with a ``mailto:value`` as path. If a label is defined for this field, it’s displayed as the content of the link.
``solid-display-tel``
~~~~~~~~~~~~~~~~~~~~~
Displays a link inside a ``<a>`` HTML tag with a ``tel:value`` as path.
``solid-display-link``
~~~~~~~~~~~~~~~~~~~~~~
Displays a link inside a ``<a>`` HTML tag with the value as path, and the label as text content.
``solid-display-date``
~~~~~~~~~~~~~~~~~~~~~~
Displays a date in the browser’s default locale format.
``solid-display-date-time``
~~~~~~~~~~~~~~~~~~~~~~~~~~~
Displays a date and a time in the browser’s default locale format.
......@@ -3,40 +3,65 @@ Form widgets
Startin'blox provides a list of default widgets to use in a form:
Form widgets
~~~~~~~~~~~~
- ``solid-form-label-text``: Inserts an ``<input/>`` HTML tag of type
“text”, in a ``<label>`` HTML tag.
- ``solid-form-checkbox``: Inserts an ``<input/>`` HTML tag of type
“checkbox”, in a ``<label>`` HTML tag.
- ``solid-form-date``: Inserts an ``<input/>`` HTML tag of type
“date”, in a ``<label>`` HTML tag.
- ``solid-form-range-date``:
- ``solid-form-json``: Inserts an ``<input/>`` HTML tag of type
“text”, in a ``<label>`` HTML tag, and with its ``value`` converted
from JSON to string
- ``solid-form-placeholder-text``: Inserts an ``<input/>`` HTML tag
of type “text”, with the ``label`` as placeholder.
- ``solid-form-textarea``: Inserts an ``<textarea>`` HTML tag in a
``<label>`` HTML tag.
- ``solid-form-dropdown``: Inserts a ``<select>`` HTML tag to select
a unique value from a list. The list is provided via the
``range-xyz``, which expects a container’s URL. **xyz** is the name
of the field using the ``solid-form-dropdown`` widget.
- ``solid-form-placeholder-dropdown``: Inserts a ``<select>`` HTML
tag to select a unique value from a list. It has no label but a
default disabled value as a label
- ``solid-form-auto-completion``: Inserts a ``<input />`` HTML tag
and load an autocomplete plugin. The list is provided via the
``range-xyz``, which expects a container’s URL. **xyz** is the name
of the field using the ``solid-form-auto-completion`` widget.
- ``solid-form-number``: Inserts an ``<input/>`` HTML tag of type
“number”, in a ``<label>`` HTML tag.
- ``solid-form-range-number``:
- ``solid-form-file``: Inserts an ``<input/>`` and an
``<input type="file"/>``. when a file is selected it’s uploaded, URL
of file is returned by request and set as the ``<input/>`` value. The
upload URL is provided via the ``upload-url`` attribute.
- ``solid-form-hidden``: Inserts an ``<input/>`` HTML tag of type
“hidden”, in a ``<label>`` HTML tag.
\ No newline at end of file
``solid-form-label-text``
~~~~~~~~~~~~~~~~~~~~~~~~~
Inserts an ``<input/>`` HTML tag of type “text”, in a ``<label>`` HTML tag.
``solid-form-checkbox``
~~~~~~~~~~~~~~~~~~~~~~~
Inserts an ``<input/>`` HTML tag of type “checkbox”, in a ``<label>`` HTML tag.
``solid-form-date``
~~~~~~~~~~~~~~~~~~~
Inserts an ``<input/>`` HTML tag of type “date”, in a ``<label>`` HTML tag.
``solid-form-range-date``
~~~~~~~~~~~~~~~~~~~~~~~~~
``solid-form-json``
~~~~~~~~~~~~~~~~~~~
Inserts an ``<input/>`` HTML tag of type “text”, in a ``<label>`` HTML tag, and with its ``value`` converted from JSON to string
``solid-form-placeholder-text``
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Inserts an ``<input/>`` HTML tag of type “text”, with the ``label`` as placeholder.
``solid-form-textarea``
~~~~~~~~~~~~~~~~~~~~~~~
Inserts an ``<textarea>`` HTML tag in a ``<label>`` HTML tag.
``solid-form-dropdown``
~~~~~~~~~~~~~~~~~~~~~~~
Inserts a ``<select>`` HTML tag to select a unique value from a list.
The list is provided via the ``range-xyz``, which expects a container’s URL.
**xyz** is the name of the field using the ``solid-form-dropdown`` widget.
``solid-form-placeholder-dropdown``
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Inserts a ``<select>`` HTML tag to select a unique value from a list.
It has no label but a default disabled value as a label
``solid-form-auto-completion``
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Inserts a ``<input />`` HTML tag and load an autocomplete plugin.
The list is provided via the ``range-xyz``, which expects a container’s URL.
**xyz** is the name of the field using the ``solid-form-auto-completion`` widget.
``solid-form-number``
~~~~~~~~~~~~~~~~~~~~~
Inserts an ``<input/>`` HTML tag of type “number”, in a ``<label>`` HTML tag.
``solid-form-range-number``
~~~~~~~~~~~~~~~~~~~~~~~~~~~
``solid-form-file``
~~~~~~~~~~~~~~~~~~~
Inserts an ``<input/>`` and an ``<input type="file"/>``.
When a file is selected it’s uploaded, URL of file is returned by request and set as the ``<input/>`` value.
The upload URL is provided via the ``upload-url`` attribute.
``solid-form-hidden``
~~~~~~~~~~~~~~~~~~~~~
Inserts an ``<input/>`` HTML tag of type “hidden”, in a ``<label>`` HTML tag.
\ No newline at end of file
......@@ -3,13 +3,18 @@ Multiple widgets
Startin'blox provides a list of default widgets to handle multiples:
Multiple widgets
~~~~~~~~~~~~~~~~
- ``solid-multiple`` (default for display): Inserts all the widgets
in a ``<solid-multiple>`` tag.
- ``solid-multiple-form`` (default for forms): Inserts all the
widgets in a ``<solid-multiple-form>`` tag, with a “remove” button for
each widget, and an “add” button.
- ``solid-multiple-select``: Inserts all the values as ``<option>``
in a ``<select>`` tag with a ``multiple`` attribute.
``solid-multiple``
~~~~~~~~~~~~~~~~~~
*default for display*
Inserts all the widgets in a ``<solid-multiple>`` tag.
``solid-multiple-form``
~~~~~~~~~~~~~~~~~~~~~~~
*default for forms*
Inserts all the widgets in a ``<solid-multiple-form>`` tag, with a “remove” button for each widget, and an “add” button.
``solid-multiple-select``
~~~~~~~~~~~~~~~~~~~~~~~~~
Inserts all the values as ``<option>`` in a ``<select>`` tag with a ``multiple`` attribute.
......@@ -4,16 +4,29 @@ Other widgets
Set widgets
~~~~~~~~~~~
- ``solid-set-default`` (default): Inserts content directly in the
set tag.
- ``solid-set-div``: Inserts content in a ``<div/>`` HTML tag
- ``solid-set-ul``: Inserts content in a ``<ul/>`` HTML tag
- ``solid-set-fieldset``: Inserts content in a ``<fieldset/>`` HTML
tag
``solid-set-default``
+++++++++++++++++++++
*default*
Inserts content directly in the set tag.
``solid-set-div``
+++++++++++++++++
Inserts content in a ``<div/>`` HTML tag.
``solid-set-ul``
++++++++++++++++
Inserts content in a ``<ul/>`` HTML tag.
``solid-set-fieldset``
++++++++++++++++++++++
Inserts content in a ``<fieldset/>`` HTML tag.
Actions widgets
~~~~~~~~~~~~~~~
- ``solid-action``: Displays a link inside a ``<solid-link>`` tag with
``src`` for the ``data-src`` attribute, ``value`` for the ``next``
attribute and ``label`` as text content
``solid-action``
++++++++++++++++
Displays a link inside a ``<solid-link>`` tag with ``src`` for the ``data-src`` attribute,
``value`` for the ``next`` attribute and ``label`` as text content.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment