Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ISSUE-136: Adds '#description_display' => 'before' to avoid warning #137

Merged
merged 2 commits into from
Nov 9, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions src/Controller/AmiRowAutocompleteHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -247,6 +247,7 @@ public static function ajaxPreviewAmiSet($form, FormStateInterface $form_state)
$output['json'] = [
'#type' => 'details',
'#title' => t('JSON Data'),
'#description_display' => 'before',
'#open' => FALSE,
];
$output['json']['data'] = [
Expand Down Expand Up @@ -277,6 +278,7 @@ public static function ajaxPreviewAmiSet($form, FormStateInterface $form_state)
'#type' => 'codemirror',
'#title' => t('Original JSON of an ADO <b>{{ dataOriginal.keyname }}</b> :'),
'#description' => t('This data structure will contain the original values (before modification) of an ADO only when updating. Sadly we can not at this time preview it during an AMI set preview.'),
'#description_display' => 'before',
'#rows' => 60,
'#value' => json_encode('{}', JSON_PRETTY_PRINT),
'#codemirror' => [
Expand Down Expand Up @@ -366,6 +368,7 @@ public static function ajaxPreviewAmiSet($form, FormStateInterface $form_state)
'#type' => 'details',
'#open' => TRUE,
'#title' => 'HTML Output',
'#description_display' => 'before',
'messages' => [
'#markup' => $message,
'#attributes' => [
Expand All @@ -388,6 +391,7 @@ public static function ajaxPreviewAmiSet($form, FormStateInterface $form_state)
$output['preview'] = [
'#type' => 'details',
'#open' => TRUE,
'#description_display' => 'before',
'#title' => t('Syntax error'),
'error' => [
'#markup' => $message,
Expand All @@ -401,6 +405,7 @@ public static function ajaxPreviewAmiSet($form, FormStateInterface $form_state)
$output['preview'] = [
'#type' => 'details',
'#open' => TRUE,
'#description_display' => 'before',
'#title' => !$file ? t('AMI Set has no CSV File'): t('AMI Set has no data for chosen row.'),
'error' => [
'#markup' => t('The AMI set is empty.'),
Expand Down