Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • documentation/doc
  • PhilH/doc
  • louis.csn/doc
  • fabien4vo/doc
  • rngadam/doc
  • anastasia/doc
6 results
Show changes
Showing
with 447 additions and 142 deletions
......@@ -32,6 +32,7 @@ templates_path = []
exclude_patterns = []
autosectionlabel_prefix_document = True
# -- Options for HTML output -------------------------------------------------
......
......@@ -23,8 +23,9 @@ This component uses the following mixins:
Please check their documentation to know more about their capabilities.
Attributes
----------
Specific attributes
-------------------
``permission``
~~~~~~~~~~~~~~
......@@ -35,10 +36,19 @@ Attributes
Displays the element if the user has not the specified right
Possible values:
- `acl:Read <https://github.com/solid/web-access-control-spec#aclread>`__
- `acl:Write <https://github.com/solid/web-access-control-spec#aclwrite>`__
- `acl:Append <https://github.com/solid/web-access-control-spec#aclappend>`__
- `acl:Control <https://github.com/solid/web-access-control-spec#aclcontrol>`__
Mixin attributes
-----------------
**From store-mixin :**
.. include:: ../Mixins/store-mixin.rst
:start-line: 21
:end-before: Events
\ No newline at end of file
.. _sib-auth:
sib-auth
================
========
Allows your users to login via a given OIDC provider.
Installation
--------------
Initialize ``sib-auth`` in your HTML file:
Initialize ``sib-auth`` in your HTML file :
.. code:: html
......@@ -19,7 +19,7 @@ Installation
</sib-auth>
`You'll find here the detail of the attributes configuration. <https://github.com/IdentityModel/oidc-client-js/wiki#usermanager>`__
`You'll find here the detail of the attributes configuration. <https://github.com/IdentityModel/oidc-client-js/wiki#usermanager>`__
Set an OIDC provider to your server
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
......@@ -90,7 +90,7 @@ Example:
</sib-auth>
Methods
------------------
-------
``login``
~~~~~~~~~
......
......@@ -23,6 +23,27 @@ This component uses the following mixins:
Please check their documentation to know more about their capabilities.
Mixin attributes
-----------------
**From list-mixin :**
.. include:: ../Mixins/list-mixin.rst
:start-line: 25
**From next-mixin :**
.. include:: ../Mixins/next-mixin.rst
:start-line: 21
**From store-mixin :**
.. include:: ../Mixins/store-mixin.rst
:start-line: 21
:end-before: Events
Events
-------
......
......@@ -21,8 +21,8 @@ This component uses the following mixin:
Please check their documentation to know more about its capabilities.
Attributes
----------
Specific attributes
-------------------
``data-src``
~~~~~~~~~~~~
......@@ -32,13 +32,19 @@ Attributes
~~~~~~~~~~~~~~
The text to display on the delete button.
``confirmation-message``
~~~~~~~~~~~~~~~~~~~~~~~~~
*Available from version 0.13*
**Migrated to the validation mixin page in version 0.16**
Add this attribute to create a dialog box linked with the button of the solid-delete.
Its value matches the message displayed in the dialog box.
Mixin attributes
-----------------
**From next-mixin :**
.. include:: ../Mixins/next-mixin.rst
:start-line: 21
**From validation-mixin :**
.. include:: ../Mixins/validation-mixin.rst
:start-line: 17
Events
......
......@@ -29,7 +29,6 @@ Mixins
------
This component uses the following mixins:
* :ref:`required-mixin <required-mixin>`
* :ref:`counter-mixin <counter-mixin>`
* :ref:`federation-mixin <federation-mixin>`
* :ref:`filter-mixin <filter-mixin>`
......@@ -38,6 +37,8 @@ This component uses the following mixins:
* :ref:`list-mixin <list-mixin>`
* :ref:`next-mixin <next-mixin>`
* :ref:`paginate-mixin <paginate-mixin>`
* :ref:`required-mixin <required-mixin>`
* :ref:`paginate-mixin <server-pagination-mixin>`
* :ref:`sorter-mixin <sorter-mixin>`
* :ref:`store-mixin <store-mixin>`
* :ref:`widget-mixin <widget-mixin>`
......@@ -45,24 +46,88 @@ This component uses the following mixins:
Please check their documentation to know more about their capabilities.
Attributes
----------
Specific attributes
-------------------
``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.
List of fields displayed.
By default, all displayed fields are direct children of ``<solid-display>``.
More details on its use below (in **widget-mixin attributes**).
``child-[field]``
~~~~~~~~~~~~~
add attribute ``[field]`` to all children.
~~~~~~~~~~~~~~~~~
Add attribute ``[field]`` to all children.
Mixin attributes
-----------------
**From counter-mixin :**
.. include:: ../Mixins/counter-mixin.rst
:start-line: 17
**From filter-mixin :**
.. include:: ../Mixins/filter-mixin.rst
:start-line: 18
**From grouper-mixin :**
.. include:: ../Mixins/grouper-mixin.rst
:start-line: 18
**From highlighter-mixin :**
.. include:: ../Mixins/highlighter-mixin.rst
:start-line: 17
**From list-mixin :**
.. include:: ../Mixins/list-mixin.rst
:start-line: 25
**From next-mixin :**
.. include:: ../Mixins/next-mixin.rst
:start-line: 21
**From paginate-mixin :**
.. include:: ../Mixins/paginate-mixin.rst
:start-line: 17
**From required-mixin :**
.. include:: ../Mixins/required-mixin.rst
:start-line: 17
**From sorter-mixin :**
.. include:: ../Mixins/sorter-mixin.rst
:start-line: 17
**From store-mixin :**
.. include:: ../Mixins/store-mixin.rst
:start-line: 21
:end-before: Events
**From widget-mixin :**
.. include:: ../Mixins/widget-mixin.rst
:start-line: 18
Widgets
-------
By default, the widget used is ``<solid-display-div>``. Cf the
`Widget <https://docs.startinblox.com/import_documentation/Widgets/Reference.html>`__ page for more info.
By default, the widget used is ``<solid-display-div>``. Cf the
:ref:`Widget <reference>` page for more info.
Events
......
......@@ -29,19 +29,24 @@ This component uses the following mixins:
Please check their documentation to know more about their capabilities.
Attributes
----------
Specific attributes
-------------------
``fields``
~~~~~~~~~~
List of fields used to perform the search.
More details on its use below (in **widget-mixin attributes**).
.. _label-field-sfs:
``label-[field]``
~~~~~~~~~~~~~~~~~
When displaying a form, the default labels are the fields names of the model.
If you want something fancier, you can set this attribute.
i.e. ``label-username="Your name"``
.. _submit-button-sfs:
``submit-button``
~~~~~~~~~~~~~~~~~
*Available from version 0.13*
......@@ -49,12 +54,19 @@ Attributes
Text of the submit button to create in the search form. If the attribute is not defined,
no button will be added and the form will trigger the search on change.
.. _class-submit-button-sfs:
``class-submit-button``
~~~~~~~~~~~~~~~~~~~~~~~
Define the ``class`` of the ``div`` containing the submit button.
.. _range-field-sfs:
``range-[field]``
~~~~~~~~~~~~~~~~~
URL of a container which list the accepted values
for the field ``[field]``. It’s particularly useful with a dropdown
for the field ``[field]``. It’s particularly useful with a dropdown or multipleselect
field.
.. _enum-field-sfs:
``enum-[field]``
~~~~~~~~~~~~~~~~
*Available from version 0.13*
......@@ -70,6 +82,7 @@ Attributes
* ``enum-[field]="value1 = a, value2 = b, value3 = c"``: each value will be displayed
and "a", "b", "c" will be loaded in value attribute.
.. _start-value-field:
``start-value-[field]``
~~~~~~~~~~~~~~~~~~~~~~~
*Available from version 0.15*
......@@ -78,6 +91,7 @@ Attributes
Only usable with ``solid-form-rangedate`` and ``solid-form-rangenumber``.
In ``solid-form-rangedate``, it can be defined to ``today``.
.. _end-value-field:
``end-value-[field]``
~~~~~~~~~~~~~~~~~~~~~
*Available from version 0.15*
......@@ -86,6 +100,7 @@ Attributes
Only usable with ``solid-form-rangedate`` and ``solid-form-rangenumber``.
In ``solid-form-rangedate``, it can be defined to ``today``.
.. _autocomplete-field-sfs:
``autocomplete-[field]``
~~~~~~~~~~~~~~~~~~~~~~~~
*Available from version 0.15*
......@@ -93,10 +108,81 @@ Attributes
Equal to the value ``off``, it cancels the automatic entry of values in the relevant ``[field]``.
It can be added to ``inputs``, ``textarea`` and ``select``.
.. _search-placeholder-field:
``search-placeholder-[field]``
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
*Available from version 0.17*
Allows to modify "searchPlaceholder" displayed in the search bar (from SlimSelect plugin).
Its value by default is "Search" in English, "Rechercher" in French.
**It works only with the autocompletion feature.**
.. _search-text-field:
``search-text-[field]``
~~~~~~~~~~~~~~~~~~~~~~~
*Available from version 0.17*
Allows to modify "searchText" displayed when no value is found (from SlimSelect plugin).
Its value by default is "No result" in English, "Aucun résultat" in French.
**It works only with the autocompletion feature.**
.. code:: html
<solid-form-search
id="filter-multiselectautocomp"
fields="skills"
widget-skills="solid-form-multipleselect-autocompletion-placeholder"
placeholder-skills="Please, pick a value"
search-text-skills="Nothing found"
search-placeholder-skills="Searching..."
></solid-form-search>
<solid-display
data-src="data/list/users.jsonld"
fields="username, skills"
multiple-skills
filtered-by="filter-multiselectautocomp"
></solid-display>
.. _auto-range-field:
``auto-range-[field]``
~~~~~~~~~~~~~~~~~~~~~~~
*Available from version 0.17*
Dynamically populates a dropdown based on the values of the ``solid-display``(s) associated.
For each ``solid-display``, it will look for its ``field`` values, and add them to the dropdown.
Each value is displayed only once.
``field`` can target a ``container`` or a ``resource``.
In this example below, ``auto-range-skills ``attribute catches all skill values for all users in the ``data-src`` `data/list/users` and displays in the dropdown all skills once :
.. code:: html
<solid-form-search
id="filter-autorange"
fields="skills"
auto-range-skills
></solid-form-search>
<solid-display
data-src="data/list/users.jsonld"
fields="username, skills"
multiple-skills
filtered-by="filter-autorange"
></solid-display>
Mixin attributes
-----------------
**From widget-mixin :**
.. include:: ../Mixins/widget-mixin.rst
:start-line: 18
Widgets
-------
By default, the widget used is ``<solid-form-label-text>``. Cf the
`Widget Form <https://docs.startinblox.com/import_documentation/Widgets/form-widgets.html>`__ page for more info.
By default, the widget used is ``<solid-form-label-text>``. Cf the
:ref:`Widget <reference>` page for more info.
Events
......
......@@ -2,14 +2,31 @@
solid-form
==========
Receives the URL of a ressource via its ``data-src`` attribute, and
displays a form to edit the resource. If given the URL of a container of
ressources, and displays a creation form to add a resource to the
container.
The `solid-form` component serves dual purposes: editing existing resources
and creating new resources within a container.
Editing a Resource
-------------------
The `solid-form` component receives the URL of a resource via its `data-src` attribute
and displays a form for editing the resource.
.. code:: html
<solid-form data-src="http://example.com/resource/123/"></solid-form>
Creating a Resource
-------------------
If provided with the URL of a container of resources, the `solid-form` component displays
a form for creating a new resource and adding it to the container.
.. code:: html
<solid-form data-src="http://server/todos/"></solid-form>
<solid-form data-src="http://example.com/container/"></solid-form>
Mixins
------
......@@ -20,50 +37,44 @@ This component uses the following mixins:
* :ref:`validation-mixin <validation-mixin>`
* :ref:`widget-mixin <widget-mixin>`
Please check their documentation to know more about their capabilities.
Please refer to their documentation for more details about their capabilities.
Attributes
----------
``fields``
~~~~~~~~~~
List of the fields used to create the form (by default, all of them are used).
Specific attributes
-------------------
``label-[field]``
~~~~~~~~~~~~~~~~~
When displaying a form, the default labels are the fields names of the model.
If you want something fancier, you can set this attribute.
i.e. ``label-username="Your name"``
.. _autocomplete-field-sf:
``autocomplete-[field]``
~~~~~~~~~~~~~~~~~~~~~~~~
*Available from version 0.15*
``naked``
~~~~~~~~~
When the attribute is set, the submit button will be
removed. It’s particularly useful to prevent the nested forms to
display their own submit button.
When set to ``off``, it disables the automatic entry of values in the specified ``[field]``.
This attribute can be added to ``inputs``, ``textarea`` and ``select``.
``upload-url-[field]``
~~~~~~~~~~~~~~~~~~~~~~
URL to upload file for field ``[field]``, it
automatically set ``widget-[field]`` to ``solid-form-file`` if net defined.
It’s particularly useful with a dropdown field.
``submit-button``
~~~~~~~~~~~~~~~~~
Text of the submit button of the form.
.. _autosave:
``autosave``
~~~~~~~~~~~~
*Available from version 0.16*
``range-[field]``
~~~~~~~~~~~~~~~~~
URL of a container which list the accepted values
for the field ``[field]``. It’s particularly useful with a dropdown
field.
If this attribute is defined, each change in an input will trigger a request to update the resource.
This attribute works only when editing resources, not creating them.
.. _class-submit-button-sf:
``class-submit-button``
~~~~~~~~~~~~~~~~~~~~~~~
Define the ``class`` of the ``div`` containing the submit button.
.. _enum-field-sf:
``enum-[field]``
~~~~~~~~~~~~~~~~
*Available from version 0.13*
List of values of your choice for the field ``[field]``.
They have to be filled manually and must be separated by commas.
It’s particularly useful with a dropdown or radio field.
Specifies a list of values for the specified ``[field]``.
These values must be be filled manually and separated by commas.
This is particularly useful for dropdown or radio fields.
Two formats are possible:
* ``enum-[field]="value 1, value 2, value 3"`` : each value will be displayed
......@@ -72,90 +83,158 @@ Attributes
* ``enum-[field]="value1 = a, value2 = b, value3 = c"``: each value will be displayed
and "a", "b", "c" will be loaded in value attribute.
``fields``
~~~~~~~~~~
Specifies the list of fields used to create the form. By default, all fields are used.
More details can be found in the **widget-mixin attributes** section
.. _label-field-sf:
``label-[field]``
~~~~~~~~~~~~~~~~~
When displaying a form, the default labels are the field names of the model.
To customize a label, use this attribute, i.e. ``label-username="Your name"``
.. _max-field:
``max-[field]``
~~~~~~~~~~~~~~~
Specifies the maximum value for the specified ``[field]``.
This attribute works only with ``solid-form-number`` and ``solid-form-time`` widgets.
.. _maxlength-field:
``maxlength-[field]``
~~~~~~~~~~~~~~~~~~~~~
*Available from version 0.16*
Specifies the maximum number of characters that can be typed for the specified ``[field]``.
This attribute works only with ``solid-form-text``, ``solid-form-email`` or ``solid-form-password`` and ``solid-form-textarea`` widgets.
.. _min-field:
``min-[field]``
~~~~~~~~~~~~~~~
Specifies the minimum value for the specified ``[field]``.
This attribute works only with ``solid-form-number`` and ``solid-form-time`` widgets.
.. _minlength-field:
``minlength-[field]``
~~~~~~~~~~~~~~~~~~~~~
*Available from version 0.16*
Specifies the minimum number of characters that can be typed for the specified ``[field]``.
This attribute works only with ``solid-form-text``, ``solid-form-email`` or ``solid-form-password`` and ``solid-form-textarea`` widgets.
.. _naked:
``naked``
~~~~~~~~~
When set, this attribute removes the submit button. This is particularly useful to prevent the nested forms to
display their own submit button.
.. _order-asc-field:
.. _order-desc-field:
``order-asc-[field]`` or ``order-desc-[field]``
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Name of the field used to order the range list ``[field]``.
Specifies the field used to order the range list ``[field]``.
i.e. ``order-asc-users="username"``
.. _partial:
``partial``
~~~~~~~~~~~
Add this attribute when the form does not include
all the fields of the resource to update.
``min-[field]``
~~~~~~~~~~~~~~~
Add this attribute for the field ``[field]`` to define its minimum value.
It works only with ``solid-form-number`` and ``solid-form-time`` widgets.
Use this attribute when the form does not include all the fields of the resource that you want to update.
This indicates that only the provided fields should be updated, leaving the unspecified fields unchanged.
``max-[field]``
~~~~~~~~~~~~~~~
Add this attribute for the field ``[field]`` to define its maximum value.
It works only with ``solid-form-number`` and ``solid-form-time`` widgets.
.. _pattern-field:
``pattern-[field]``
~~~~~~~~~~~~~~~
*Available from version 0.13*
Add this attribute for the field ``[field]`` to define a regular expression to check the input's value.
It works only with a ``solid-form-text`` widget.
ASpecifies a regular expression to validate the input's value for the specified ``[field]``.
This attribute works only with a ``solid-form-text`` widget.
``title-[field]``
.. _range-field-sf:
``range-[field]``
~~~~~~~~~~~~~~~~~
*Available from version 0.13*
Specifies the URL of a container that lists the accepted values for the specified ``[field]``.
This is particularly useful with a dropdown field.
Add this attribute for the field ``[field]`` to precise extra information about an element.
It works only with a ``solid-form-text`` widget.
``confirmation-message``
~~~~~~~~~~~~~~~~~~~~~~~~
.. _required-field:
``required-[field]``
~~~~~~~~~~~~~~~~~~~~
Makes the specified ``[field]`` required by adding the ``required`` attribute to the input.
.. _step-field:
``step-[field]``
~~~~~~~~~~~~~~~~
*Available from version 0.16*
Specifies the stepping interval number for the specified ``[field]`` based on the ``min-[field]`` value. This attribute works with:
- ``solid-form-time`` widget : The value is given in seconds (default value is 60).
- ``solid-form-number`` widget : The default value is 1.
.. _submit-button-sf:
``submit-button``
~~~~~~~~~~~~~~~~~
Specifies the text of the form's submit button.
.. _title-field:
``title-[field]``
~~~~~~~~~~~~~~~~~
*Available from version 0.13*
**Migrated to the validation mixin page in version 0.16**
Add this attribute to create a dialog box linked with the submit button of the solid-form.
Its value matches the message displayed in the dialog box.
Adds extra information about the specified ``[field]``.
This attribute works only with a ``solid-form-text`` widget.
``autocomplete-[field]``
~~~~~~~~~~~~~~~~~~~~~~~~
*Available from version 0.15*
Equal to the value ``off``, it cancels the automatic entry of values in the relevant ``[field]``.
It can be added to ``inputs``, ``textarea`` and ``select``.
.. _upload-url-field:
``upload-url-[field]``
~~~~~~~~~~~~~~~~~~~~~~
Specifies the URL to upload a file for the specified ``[field]``. This attribute automatically sets
``widget-[field]`` to ``solid-form-file`` if not defined.
This is particularly useful with a dropdown field.
``autosave``
~~~~~~~~~~~~
*Available from version 0.16*
If the attribute is defined, each change in an input will trigger a request to update the resource.
This attribute works only when editing resources, not creating them.
Mixin attributes
-----------------
**From next-mixin :**
``maxlength-[field]``
~~~~~~~~~~~~~~~~~~~~~
*Available from version 0.16*
.. include:: ../Mixins/next-mixin.rst
:start-line: 21
Add this attribute for the field ``[field]`` to define the maximum number of characters that can be typed.
It works only with ``solid-form-text``, ``solid-form-email`` or ``solid-form-password`` and ``solid-form-textarea`` widgets.
**From store-mixin :**
``minlength-[field]``
~~~~~~~~~~~~~~~~~~~~~
*Available from version 0.16*
.. include:: ../Mixins/store-mixin.rst
:start-line: 21
:end-before: Events
Add this attribute for the field ``[field]`` to define the minimum number of characters that can be typed.
It works only with ``solid-form-text``, ``solid-form-email`` or ``solid-form-password`` and ``solid-form-textarea`` widgets.
**From validation-mixin :**
.. include:: ../Mixins/validation-mixin.rst
:start-line: 17
``step-[field]``
~~~~~~~~~~~~~~~~
*Available from version 0.16*
**From widget-mixin :**
.. include:: ../Mixins/widget-mixin.rst
:start-line: 18
Add this attribute for the field ``[field]`` to define the stepping interval number to use as constraint validation. Its based on the ``min-[field]`` value.
It works with :
- ``solid-form-time`` widget : Its value is given in seconds (default value is 60).
- ``solid-form-number`` widget : Its default value is 1.
Widgets
-------
By default, the widget used is ``<solid-form-label-text>``. Cf the
`Widget <https://docs.startinblox.com/import_documentation/Widgets/Reference.html>`__ page for more info.
By default, the widget used is ``<solid-form-label-text>``. Cf the
:ref:`Widget <reference>` page for more info.
Events
......@@ -167,4 +246,4 @@ Events
``save``
~~~~~~~~~~~~~~
Triggered when the response of the submit has been received (successfull or not)
Triggered when the response of the submit has been received successfully
......@@ -13,16 +13,6 @@ of fields needed to display the resources properly:
respectively ``http://www.w3.org/2003/01/geo/wgs84_pos#lat`` and ``http://www.w3.org/2003/01/geo/wgs84_pos#lng``.
How to use
----------
The ``solid-map`` module needs to be imported independantly from the core, like following:
.. code:: html
<script type="module" src="https://unpkg.com/@startinblox/core/dist/components/solid-map.js"></script>
Mixins
------
......@@ -40,8 +30,8 @@ This component uses the following mixins:
Please check their documentation to know more about their capabilities.
Attributes
----------
Specific attributes
-------------------
Like for ``solid-display``, fields can be displayed and filters or searching capabilities can be
added to interact with the list of data being displayed.
......@@ -50,12 +40,55 @@ added to interact with the list of data being displayed.
~~~~~~~~~~
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.
More details on its use below (in **widget-mixin attributes**).
``clustering``
~~~~~~~~~~~~~~
*Available from version 0.16*
If this attribute is defined, markers spacially close are grouped in clusters.
Mixin attributes
-----------------
**From counter-mixin :**
.. include:: ../Mixins/counter-mixin.rst
:start-line: 17
**From filter-mixin :**
.. include:: ../Mixins/filter-mixin.rst
:start-line: 18
**From grouper-mixin :**
.. include:: ../Mixins/grouper-mixin.rst
:start-line: 18
**From list-mixin :**
.. include:: ../Mixins/list-mixin.rst
:start-line: 25
**From next-mixin :**
.. include:: ../Mixins/next-mixin.rst
:start-line: 21
**From store-mixin :**
.. include:: ../Mixins/store-mixin.rst
:start-line: 21
:end-before: Events
**From widget-mixin :**
.. include:: ../Mixins/widget-mixin.rst
:start-line: 18
Events
-------
......
......@@ -53,12 +53,13 @@ Displays a menu and handle the navigation for you.
- ``use-hash``: If you can't rewrite the URLs on your server, you
might want to set this attribute to use ``location.hash`` instead of
``location.pathname`` as URLs.
- ``keep-url``: It freezes the URL of all the ``<solid-route>`` included. Usefull to freeze the URL when a pop-up is displayed.
``<solid-route>`` attributes:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- ``use-id``: indicates that the route takes an id.
- ``name``: The name of the route. Must match the id of the view
- ``name``: The name of the route. Must match the ``data-view`` of the view
that is to be displayed. The same name is used as a url identifier as
well.
- ``rdf-type``: Can be used as an alternative of ``name``. The
......@@ -68,6 +69,12 @@ Displays a menu and handle the navigation for you.
``<solid-router>``. It is automatically added/removed by
``<solid-router>`` and should not be tinkered manually.
``<div data-view=[name]>`` attributes:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- ``view-title``: allows to change the ``title`` of the page when a user navigates to this view.
- ``view-description``: allows to change the ``<meta name="description">`` of the page when the user navigates to this view.
solid-link
----------
......@@ -78,7 +85,7 @@ solid-link
- ``data-src``: The resource you want to use in your view. Often
used to show more details about this resource, by adding the
``bind-resource`` attribute to a component.
``bind-resources`` attribute to a component (more details about ``bind-resources`` below).
Example:
......@@ -91,7 +98,7 @@ solid-analytics
Manage browsing statistics.
Sign in on a web analytics service and set ``<sib-analytics>`` inside
Sign in on a web analytics service and set ``<solid-analytics>`` inside
``<body>``, at the begining for example.
``<solid-analytics>`` accepts the following attributes:
......@@ -102,14 +109,14 @@ Sign in on a web analytics service and set ``<sib-analytics>`` inside
necessary to specify the url attribute.
- ``id``: id of the website on the service.
Type ``'debug'`` allow to test sib-analytics. It will display the route
Type ``'debug'`` allow to test solid-analytics. It will display the route
on the console each time a navigation is triggered.
Example :
.. code:: html
<sib-analytics type="matomo" url="https://matomo.example.com/" id="1234"></sib-analytics>
<solid-analytics type="matomo" url="https://matomo.example.com/" id="1234"></solid-analytics>
Interacting with the router
---------------------------
......@@ -144,17 +151,14 @@ accordingly.
More informations about this in the :ref:`sib-auth documentation<bind-user>`.
Navigate with an event
~~~~~~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~~~~~~
To trigger a route change through javascript, you can trigger a
``requestNavigation`` event anywhere on the DOM.
The detail part must have at least one of these two parameters:
* ``route``: the name of the route to activate
* ``resource``: a resource that will be
passed to all elements with the ``bind-resources`` attribute. If no
route name is given, the router tries to find a route that has a
``rdf-type`` that matches the type of the resource.
* ``resource``: a resource that will be passed to all elements with the ``bind-resources`` attribute. If no route name is given, the router tries to find a route that has a ``rdf-type`` that matches the type of the resource.
Events
------
......