diff --git a/source/import_documentation/Components/Solid-Form-Search.rst b/source/import_documentation/Components/Solid-Form-Search.rst index 37383f6ad6fcb6ce550186adc6eceb2dd3142350..608fb27c03bb5d14643d3b5f09fa216c83ac122d 100644 --- a/source/import_documentation/Components/Solid-Form-Search.rst +++ b/source/import_documentation/Components/Solid-Form-Search.rst @@ -60,7 +60,7 @@ Attributes ``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: @@ -105,6 +105,41 @@ 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> + Widgets ------- By default, the widget used is ``<solid-form-label-text>``. Cf the diff --git a/source/import_documentation/Mixins/translation-mixin.rst b/source/import_documentation/Mixins/translation-mixin.rst new file mode 100644 index 0000000000000000000000000000000000000000..5404058ea634eec13a0976d84b2b1599fc3f630a --- /dev/null +++ b/source/import_documentation/Mixins/translation-mixin.rst @@ -0,0 +1,19 @@ +.. _translation-mixin: +translation-mixin +================= +*Available from version 0.17* + +The translation mixin provides an automatic translation in elements, depending on the browser language (English and French). Translations are default values, visible if no value is given by an attribute. + +The concerned elements are : + - the submit-button in :ref:`solid-form <solid-form>`, + - the button in :ref:`solid-delete <solid-delete>`, + - the confirmation message from :ref:`validation-mixin <validation-mixin>`, + - the text in modal dialog's buttons from :ref:`validation-mixin <validation-mixin>`, + - :ref:`search-placeholder-[field] <search-placeholder-[field]>` and :ref:`search-text-[field] <search-text-[field]>` attributes available with ``autocompletion`` feature (SlimSelect plugin) from :ref:`widget API reference <reference>`. + +Used by: +-------- + + * :ref:`store-mixin <store-mixin>` + * :ref:`validation-mixin <validation-mixin>` \ No newline at end of file diff --git a/source/import_documentation/Mixins/validation-mixin.rst b/source/import_documentation/Mixins/validation-mixin.rst index f1947b04875f81765d4ec43779431bccc2cd7ab2..84d1baf0247b49b24c1649418e3ef7ca82b25ced 100644 --- a/source/import_documentation/Mixins/validation-mixin.rst +++ b/source/import_documentation/Mixins/validation-mixin.rst @@ -26,7 +26,7 @@ Attributes ``confirmation-message`` ~~~~~~~~~~~~~~~~~~~~~~~~ Message displayed in the modal dialog (``confirm`` or ``dialog`` type). - The message by default is "Please, confirm your choice". + The message by default is "Please, confirm your choice" in English, "Merci de confirmer votre choix" in French. **The attributes below only concern ``dialog`` type.** @@ -34,12 +34,12 @@ Attributes .. _confirmation-submit-text: ``confirmation-submit-text`` ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - Text displayed on the submit button ("Ok" by default). + Text displayed on the submit button (by default, "Ok" in English, "Oui" in French). .. _confirmation-cancel-text: ``confirmation-cancel-text`` ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - Text displayed on the cancel button ("Cancel" by default). + Text displayed on the cancel button (by default "Cancel" in English, "Annuler" in French). .. _confirmation-submit-class: ``confirmation-submit-class`` diff --git a/source/import_documentation/Widgets/Reference.rst b/source/import_documentation/Widgets/Reference.rst index 634040aa8dcb51a0407f03463c9b434dbd9ef417..5f10c22dab6ff0888010b281d3a9fa7560f102bd 100644 --- a/source/import_documentation/Widgets/Reference.rst +++ b/source/import_documentation/Widgets/Reference.rst @@ -82,7 +82,7 @@ Features to add to the widget. You can choose as many as you want - ``label``: adds a ``label`` before the template. Uses the attribute ``name`` if ``label`` is not defined. - ``labellast``: adds a ``label`` after the template. Uses the attribute ``name`` if ``label`` is not defined. -- ``autocompletion``: initializes the ``SlimSelect`` plugin. Works only with dropdowns. +- ``autocompletion``: initializes the ``SlimSelect`` plugin. Works only with ``dropdown`` and ``multipleselect`` templates. - ``autolink``: analyzes widget content, and transforms all links in anchor. - ``mailto``: adds ``mailto:`` at the beginning of an ``href`` attribute. Works only with links. - ``tel``: adds ``tel:`` at the beginning of an ``href`` attribute. Works only with links. diff --git a/source/import_documentation/attributes-list.rst b/source/import_documentation/attributes-list.rst index 240e7678e47957f8629cbc00b3a430a04ccf375f..699ad65e825500b06acbca3ce15d1404500e08cb 100644 --- a/source/import_documentation/attributes-list.rst +++ b/source/import_documentation/attributes-list.rst @@ -282,6 +282,14 @@ List of attributes (core framework) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * :ref:`filter-mixin <filter-mixin>` +``search-placeholder-[field]`` +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + * :ref:`solid-form-search <search-placeholder-field>` + +``search-text-[field]`` +~~~~~~~~~~~~~~~~~~~~~~~ + * :ref:`solid-form-search <search-text-field>` + ``src-[field]`` ~~~~~~~~~~~~~~~ * :ref:`widget-mixin <src-field>`