Skip to content
Snippets Groups Projects
Commit 6d58c2ce authored by skaught's avatar skaught
Browse files

Resolve #3424736 sshop settings are hard to find

parent 2b2dc3cc
No related branches found
No related tags found
1 merge request!23Resolve #3424736 sshop settings are hard to find
......@@ -52,7 +52,7 @@ function sshop_preprocess_page(&$vars) {
$display_theme_credits = theme_get_setting('display_theme_credits');
if (!empty($display_theme_credits)) {
$vars['theme_credits']['#markup'] = t(
'Build by <a rel="nofollow" href="@url">OPTASY</a>',
'Built by <a rel="nofollow" href="@url">OPTASY</a>',
['@url' => 'https://www.optasy.com']
);
}
......@@ -128,36 +128,39 @@ function sshop_form_system_theme_settings_alter(&$form, FormStateInterface $form
$form['general']['container']['fluid_container']['#default_value'] = 1;
$form['general']['container']['fluid_container']['#disabled'] = TRUE;
$form['general']['container']['fluid_container']['#description'] = t('SShop theme works with fluid container only.');
// Footer copyrights settings.
$form['sshop_settings']['sshop_settings'] = [
'#type' => 'details',
'#title' => t('SShop Settings'),
$form['sshop_wrap'] = [
'#type' => 'container',
'#weight' => -20,
'#prefix' =>'<h3>' . t('SShop Settings') . '</h3>',
'#collapsible' => TRUE,
'#collapsed' => FALSE,
];
$form['sshop_settings']['sshop_settings']['copyright_text'] = [
$form['sshop_wrap']['footer']=[
'#type' => 'fieldset',
'#weight' => -10,
'#title'=> t ('Footer Region')
];
$form['sshop_wrap']['footer']['copyright_text'] = [
'#type' => 'textfield',
'#title' => t('Enter copyright text'),
'#default_value' => theme_get_setting('copyright_text'),
'#description' => t('Use @year placeholder for define current year.'),
];
$form['sshop_settings']['sshop_settings']['display_theme_credits'] = [
$form['sshop_wrap']['footer']['display_theme_credits'] = [
'#type' => 'checkbox',
'#title' => t('Display theme credits'),
'#default_value' => theme_get_setting('display_theme_credits'),
];
$message = t('
Do you need help to customize this theme? We can help!<br>
- web: <a href="@url">https://www.optasy.com</a><br>
- e-mail: <a href="mailto:@email">contact@optasy.com</a><br>
- phone: (416) 243.2431
',
$message = t('<h3>Do you need help to customize this theme?</h3>
<p>We can help!</p>
<ul>
<li>web: <a href="@url">https://www.optasy.com</a></li>
<li>e-mail: <a href="mailto:@email">contact@optasy.com</a></li>
<li>phone: (416) 243.2431</li>
</ul>',
['@url' => 'https://www.optasy.com', '@email' => 'contact@optasy.com']
);
\Drupal::messenger()->addMessage($message);
\Drupal::messenger()->addMessage($message, 'custom');
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment