From 1dc9a511fcbdf82bd5529681b617ca441471f4cd Mon Sep 17 00:00:00 2001
From: Alex Pott <alex.a.pott@googlemail.com>
Date: Mon, 10 Jun 2019 12:57:33 +0300
Subject: [PATCH] Issue #3016064 by yogeshmpawar, vacho, msankhala, singhkiran,
 deepanker_bhalla, gambry, dpi: Improve documentation for Datetime and
 Datelist #date_timezone property

---
 core/lib/Drupal/Core/Datetime/Element/Datelist.php | 7 ++++---
 core/lib/Drupal/Core/Datetime/Element/Datetime.php | 7 ++++---
 2 files changed, 8 insertions(+), 6 deletions(-)

diff --git a/core/lib/Drupal/Core/Datetime/Element/Datelist.php b/core/lib/Drupal/Core/Datetime/Element/Datelist.php
index d81f39a3eb64..68dc02288441 100644
--- a/core/lib/Drupal/Core/Datetime/Element/Datelist.php
+++ b/core/lib/Drupal/Core/Datetime/Element/Datelist.php
@@ -147,9 +147,9 @@ public static function valueCallback(&$element, $input, FormStateInterface $form
    *   - #date_increment: The increment to use for minutes and seconds, i.e.
    *     '15' would show only :00, :15, :30 and :45. Defaults to 1 to show every
    *     minute.
-   *   - #date_timezone: The local timezone to use when displaying or
-   *     interpreting dates. Defaults to the value returned by
-   *     drupal_get_user_timezone().
+   *   - #date_timezone: The Time Zone Identifier (TZID) to use when displaying
+   *     or interpreting dates, i.e: 'Asia/Kolkata'. Defaults to the value
+   *     returned by drupal_get_user_timezone().
    *
    * Example usage:
    * @code
@@ -160,6 +160,7 @@ public static function valueCallback(&$element, $input, FormStateInterface $form
    *     '#date_text_parts' => array('year'),
    *     '#date_year_range' => '2010:2020',
    *     '#date_increment' => 15,
+   *     '#date_timezone' => 'Asia/Kolkata'
    *   );
    * @endcode
    *
diff --git a/core/lib/Drupal/Core/Datetime/Element/Datetime.php b/core/lib/Drupal/Core/Datetime/Element/Datetime.php
index 4b6afaadf3a1..118e8263fc34 100644
--- a/core/lib/Drupal/Core/Datetime/Element/Datetime.php
+++ b/core/lib/Drupal/Core/Datetime/Element/Datetime.php
@@ -188,9 +188,9 @@ public static function valueCallback(&$element, $input, FormStateInterface $form
    *     "seconds"-component will not be shown in the input. Used for HTML5 step
    *     values and jQueryUI datepicker settings. Defaults to 1 to show every
    *     second.
-   *   - #date_timezone: The local timezone to use when displaying or
-   *     interpreting dates. Defaults to the value returned by
-   *     drupal_get_user_timezone().
+   *   - #date_timezone: The Time Zone Identifier (TZID) to use when displaying
+   *     or interpreting dates, i.e: 'Asia/Kolkata'. Defaults to the value
+   *     returned by drupal_get_user_timezone().
    *
    * Example usage:
    * @code
@@ -200,6 +200,7 @@ public static function valueCallback(&$element, $input, FormStateInterface $form
    *     '#date_date_element' => 'date',
    *     '#date_time_element' => 'none',
    *     '#date_year_range' => '2010:+3',
+   *     '#date_timezone' => 'Asia/Kolkata',
    *   );
    * @endcode
    *
-- 
GitLab