diff --git a/.editorconfig b/.editorconfig index 6bf8660..2913db5 100644 --- a/.editorconfig +++ b/.editorconfig @@ -1,29 +1,68 @@ -# EditorConfig is awesome: https://EditorConfig.org -# -# Use as master: https://github.com/TYPO3-Documentation/T3DocTeam/blob/main/.editorconfig +# EditorConfig is awesome: http://EditorConfig.org # top-most EditorConfig file root = true -[{*.rst,*.rst.txt}] +# Unix-style newlines with a newline ending every file +[*] charset = utf-8 end_of_line = lf +indent_style = space +indent_size = 4 insert_final_newline = true trim_trailing_whitespace = true -indent_style = space + +# TS/JS-Files +[*.{ts,js,mjs}] +indent_size = 2 + +# JSON-Files +[*.json] +indent_style = tab + +# ReST-Files +[*.{rst,rst.txt}] indent_size = 4 max_line_length = 80 -# MD-Files +# Markdown-Files [*.md] -charset = utf-8 -end_of_line = lf -insert_final_newline = true -trim_trailing_whitespace = true -indent_style = space -indent_size = 4 max_line_length = 80 +# YAML-Files +[*.{yaml,yml}] +indent_size = 2 + +# NEON-Files +[*.neon] +indent_size = 2 +indent_style = tab + +# stylelint +[.stylelintrc] +indent_size = 2 + +# package.json +[package.json] +indent_size = 2 + +# TypoScript +[*.{typoscript,tsconfig}] +indent_size = 2 + +# XLF-Files +[*.xlf] +indent_style = tab + +# SQL-Files +[*.sql] +indent_style = tab +indent_size = 2 + +# .htaccess +[{_.htaccess,.htaccess}] +indent_style = tab + [Makefile] # Use tabs for indentation (Makefiles require tabs) indent_style = tab diff --git a/Documentation/Global/Be/Infobox.rst b/Documentation/Global/Be/Infobox.rst index 575c529..1adcd94 100644 --- a/Documentation/Global/Be/Infobox.rst +++ b/Documentation/Global/Be/Infobox.rst @@ -7,14 +7,22 @@ Be.infobox ViewHelper `` ====================================== +.. figure:: /Images/BeInfoboxWithHTML.png + :alt: A screenshot demonstrating a complex infobox with HTML content + + See example `Infobox with HTML content, icon and links `_ + .. typo3:viewhelper:: be.infobox :source: ../../Global.json - :display: tags,description,gitHubLink,arguments + :display: tags,description,gitHubLink + :noindex: + +.. contents:: Table of contents .. _typo3-fluid-be-infobox-states: -States -====== +Severity states of the Be.infobox ViewHelper +============================================ The Infobox provides different context-sensitive states that can be used to provide an additional visual feedback to the @@ -24,27 +32,91 @@ user to underline the meaning of the information. Possible values are in range from ``-2`` to ``2``. Please choose a meaningful value from the following list. -``-2`` - Notices (Default) -``-1`` - Information -``0`` - Positive feedback -``1`` - Warnings -``2`` - Error +.. tabs:: + + .. group-tab:: Screenshot + + .. figure:: /Images/BeInfobox.png + :alt: A screenshot demonstrating all possible infobox colors and states. + + A demonstration of all possible states + + .. group-tab:: Numeral values + + ``-2`` + Notices (Default) + ``-1`` + Information + ``0`` + Positive feedback + ``1`` + Warnings + ``2`` + Error + + .. group-tab:: Code example + + It is considered best practice to use the states from + :php:`\TYPO3\CMS\Fluid\ViewHelpers\Be\InfoboxViewHelper` together with the + `Constant ViewHelper `_: + + .. literalinclude:: _Infobox/_States.html + :caption: EXT:my_extension/Resources/Private/Backend/Templates/MyModule.html .. _typo3-fluid-be-infobox-example: Examples ======== -Simple:: +Info box of level notice with a static title and a static text: + +.. code-block:: html + :caption: EXT:my_extension/Resources/Private/Backend/Templates/MyModule.html + + your box content - your box content +Warning box with disabled icon: -All options:: +.. code-block:: html + :caption: EXT:my_extension/Resources/Private/Backend/Templates/MyModule.html - + +Success box with custom icon: + +.. code-block:: html + :caption: EXT:my_extension/Resources/Private/Backend/Templates/MyModule.html + + + + +.. _typo3-fluid-be-infobox-example-html: + +Infobox with HTML content, icon and links +----------------------------------------- + +You can find this example in the TYPO3 backend module +:guilabel:`System > DB Check > Manage Reference Index` if +:composer:`typo3/cms-lowlevel` is installed. + +.. literalinclude:: _Infobox/_ReferenceIndex.html + :caption: EXT:lowlevel/Resources/Private/Templates/ReferenceIndex.html + +.. _typo3-fluid-be-infobox-arguments: + +Arguments +========= + +.. typo3:viewhelper:: be.infobox + :source: ../../Global.json + :display: arguments-only diff --git a/Documentation/Global/Be/_Infobox/_ReferenceIndex.html b/Documentation/Global/Be/_Infobox/_ReferenceIndex.html new file mode 100644 index 0000000..6cedb18 --- /dev/null +++ b/Documentation/Global/Be/_Infobox/_ReferenceIndex.html @@ -0,0 +1,18 @@ + +

{f:translate(key:'LLL:EXT:lowlevel/Resources/Private/Language/locallang.xlf:checkScript')}

+

+ {f:translate(key:'LLL:EXT:lowlevel/Resources/Private/Language/locallang.xlf:checkScript_check_description')}
+ php {binaryPath} referenceindex:update -c +

+

+ {f:translate(key:'LLL:EXT:lowlevel/Resources/Private/Language/locallang.xlf:checkScript_update_description')}
+ php {binaryPath} referenceindex:update +

+

+ {f:translate(key:'LLL:EXT:lowlevel/Resources/Private/Language/locallang.xlf:checkScript_moreDetails')} + {ReadmeLocation} +

+
diff --git a/Documentation/Global/Be/_Infobox/_States.html b/Documentation/Global/Be/_Infobox/_States.html new file mode 100644 index 0000000..4e25a8f --- /dev/null +++ b/Documentation/Global/Be/_Infobox/_States.html @@ -0,0 +1,25 @@ + + + + + diff --git a/Documentation/Global/Be/_Infobox/_Warning.html b/Documentation/Global/Be/_Infobox/_Warning.html new file mode 100644 index 0000000..4e25a8f --- /dev/null +++ b/Documentation/Global/Be/_Infobox/_Warning.html @@ -0,0 +1,25 @@ + + + + + diff --git a/Documentation/Images/BeInfobox.png b/Documentation/Images/BeInfobox.png new file mode 100644 index 0000000..74e7fbd Binary files /dev/null and b/Documentation/Images/BeInfobox.png differ diff --git a/Documentation/Images/BeInfoboxWithHTML.png b/Documentation/Images/BeInfoboxWithHTML.png new file mode 100644 index 0000000..59790b4 Binary files /dev/null and b/Documentation/Images/BeInfoboxWithHTML.png differ