From e7c86512ec8b59d210c6b1a0722b16e4eb7e8437 Mon Sep 17 00:00:00 2001 From: Javier Eguiluz Date: Mon, 1 Apr 2019 10:20:41 +0200 Subject: [PATCH 1/2] Added docs for the missing Intl polyfills --- components/polyfill_intl_grapheme.rst | 10 ++-- components/polyfill_intl_icu.rst | 10 ++-- components/polyfill_intl_idn.rst | 45 +++++++++++++++++ components/polyfill_intl_messageformatter.rst | 50 +++++++++++++++++++ components/polyfill_intl_normalizer.rst | 9 ++-- 5 files changed, 113 insertions(+), 11 deletions(-) create mode 100644 components/polyfill_intl_idn.rst create mode 100644 components/polyfill_intl_messageformatter.rst diff --git a/components/polyfill_intl_grapheme.rst b/components/polyfill_intl_grapheme.rst index bad42f179fc..7e064f944d9 100644 --- a/components/polyfill_intl_grapheme.rst +++ b/components/polyfill_intl_grapheme.rst @@ -50,9 +50,11 @@ Provided Functions .. seealso:: - The :doc:`polyfill-intl-icu ` and - :doc:`polyfill-intl-normalizer ` - components provide polyfills for other classes and functions related to the - Intl PHP extension. + Symfony provides more polyfills for other classes and functions related to + the Intl PHP extension: + :doc:`polyfill-intl-icu `, + :doc:`polyfill-intl-idn `, + :doc:`polyfill-intl-messageformatter `, + and :doc:`polyfill-intl-normalizer `. .. _`PHP intl extension`: https://secure.php.net/manual/en/book.intl.php diff --git a/components/polyfill_intl_icu.rst b/components/polyfill_intl_icu.rst index 4dc7c503afc..2835ad39f14 100644 --- a/components/polyfill_intl_icu.rst +++ b/components/polyfill_intl_icu.rst @@ -46,9 +46,11 @@ Provided Functions .. seealso:: - The :doc:`polyfill-intl-grapheme ` and - :doc:`polyfill-intl-normalizer ` - components provide polyfills for other classes and functions related to the - Intl PHP extension. + Symfony provides more polyfills for other classes and functions related to + the Intl PHP extension: + :doc:`polyfill-intl-grapheme `, + :doc:`polyfill-intl-idn `, + :doc:`polyfill-intl-messageformatter `, + and :doc:`polyfill-intl-normalizer `. .. _`PHP intl extension`: https://secure.php.net/manual/en/book.intl.php diff --git a/components/polyfill_intl_idn.rst b/components/polyfill_intl_idn.rst new file mode 100644 index 00000000000..59f6d8be5c1 --- /dev/null +++ b/components/polyfill_intl_idn.rst @@ -0,0 +1,45 @@ +.. index:: + single: Polyfill + single: IDN + single: Components; Polyfill + +The Symfony Polyfill / Intl IDN Component +========================================= + + This component provides a collection of functions related to IDN when the + Intl extension is not installed. + +Installation +------------ + +.. code-block:: terminal + + $ composer require symfony/polyfill-intl-idn + +Alternatively, you can clone the ``_ repository. + +.. include:: /components/require_autoload.rst.inc + +Usage +----- + +Once this component is installed in your application, you can use the following +functions, no matter if the `PHP intl extension`_ is installed or not in your +server. + +Provided Functions +~~~~~~~~~~~~~~~~~~ + +* :phpfunction:`idn_to_ascii` +* :phpfunction:`idn_to_utf8` + +.. seealso:: + + Symfony provides more polyfills for other classes and functions related to + the Intl PHP extension: + :doc:`polyfill-intl-grapheme `, + :doc:`polyfill-intl-icu `, + :doc:`polyfill-intl-messageformatter `, + and :doc:`polyfill-intl-normalizer `. + +.. _`PHP intl extension`: https://secure.php.net/manual/en/book.intl.php diff --git a/components/polyfill_intl_messageformatter.rst b/components/polyfill_intl_messageformatter.rst new file mode 100644 index 00000000000..96b7cd18a91 --- /dev/null +++ b/components/polyfill_intl_messageformatter.rst @@ -0,0 +1,50 @@ +.. index:: + single: Polyfill + single: Normalizer + single: Components; Polyfill + +The Symfony Polyfill / Intl MessageFormatter Component +====================================================== + + This component provides a fallback implementation for the ``MessageFormatter`` + class to users who run PHP versions without the ``intl`` extension. + +Installation +------------ + +.. code-block:: terminal + + $ composer require symfony/polyfill-intl-messageformatter + +Alternatively, you can clone the ``_ repository. + +.. include:: /components/require_autoload.rst.inc + +Usage +----- + +Once this component is installed in your application, you can use the following +classes and functions, no matter if the `PHP intl extension`_ is installed or +not in your server. + +Provided Classes +~~~~~~~~~~~~~~~~ + +* :phpclass:`IntlException` +* :phpclass:`MessageFormatter` + +Provided Functions +~~~~~~~~~~~~~~~~~~ + +* :phpfunction:`msgfmt_format_message` + +.. seealso:: + + Symfony provides more polyfills for other classes and functions related to + the Intl PHP extension: + :doc:`polyfill-intl-grapheme `, + :doc:`polyfill-intl-idn `, + :doc:`polyfill-intl-icu `, + and :doc:`polyfill-intl-normalizer `. + +.. _`PHP intl extension`: https://secure.php.net/manual/en/book.intl.php diff --git a/components/polyfill_intl_normalizer.rst b/components/polyfill_intl_normalizer.rst index 4604f29a259..da64d63cd14 100644 --- a/components/polyfill_intl_normalizer.rst +++ b/components/polyfill_intl_normalizer.rst @@ -40,8 +40,11 @@ Provided Functions .. seealso:: - The :doc:`polyfill-intl-grapheme ` and - :doc:`polyfill-intl-icu ` components provide - polyfills for other classes and functions related to the Intl PHP extension. + Symfony provides more polyfills for other classes and functions related to + the Intl PHP extension: + :doc:`polyfill-intl-grapheme `, + :doc:`polyfill-intl-idn `, + :doc:`polyfill-intl-icu `, + and :doc:`polyfill-intl-messageformatter `. .. _`PHP intl extension`: https://secure.php.net/manual/en/book.intl.php From 06f16b521ba2e1a252c5e8c60c81ea584f7ff957 Mon Sep 17 00:00:00 2001 From: Javier Eguiluz Date: Mon, 1 Apr 2019 10:22:34 +0200 Subject: [PATCH 2/2] - --- components/polyfill_intl_messageformatter.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/polyfill_intl_messageformatter.rst b/components/polyfill_intl_messageformatter.rst index 96b7cd18a91..91f93f0b771 100644 --- a/components/polyfill_intl_messageformatter.rst +++ b/components/polyfill_intl_messageformatter.rst @@ -1,6 +1,6 @@ .. index:: single: Polyfill - single: Normalizer + single: MessageFormatter single: Components; Polyfill The Symfony Polyfill / Intl MessageFormatter Component