Commit afec6e93 authored by Cristiano Silva's avatar Cristiano Silva
Browse files

Change viewport to prevent zoom on mobile

parent 765ce62d
Pipeline #1808 passed with stages
in 3 minutes and 5 seconds
...@@ -9156,7 +9156,8 @@ body { ...@@ -9156,7 +9156,8 @@ body {
background: #fff; background: #fff;
color: #000; color: #000;
overflow: hidden; overflow: hidden;
overflow-y: auto; } overflow-y: auto;
min-height: 100%; }
html { html {
min-height: 100vh; min-height: 100vh;
...@@ -9165,11 +9166,9 @@ html { ...@@ -9165,11 +9166,9 @@ html {
html, html,
body { body {
width: 100%; width: 100%;
height: 100%;
margin: 0; margin: 0;
padding: 0; padding: 0;
position: relative; position: relative; }
min-height: 100%; }
.btn-primary:focus, .btn-primary.focus { .btn-primary:focus, .btn-primary.focus {
box-shadow: none; box-shadow: none;
......
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -29,4 +29,17 @@ function drupalpt_form_system_theme_settings_alter(&$form, FormStateInterface $f ...@@ -29,4 +29,17 @@ function drupalpt_form_system_theme_settings_alter(&$form, FormStateInterface $f
'bg-white' => t('White'), 'bg-white' => t('White'),
'bg-transparent' => t('Transparent'), 'bg-transparent' => t('Transparent'),
); );
}
function drupalpt_page_attachments_alter(array &$page) {
$viewport = array(
'#type' => 'html_tag',
'#tag' => 'meta',
'#attributes' => array(
'name' => 'viewport',
'content' => 'width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no',
),
);
$page['#attached']['html_head'][] = [$viewport, 'viewport'];
} }
\ No newline at end of file
...@@ -14,6 +14,7 @@ body { ...@@ -14,6 +14,7 @@ body {
color: #000; color: #000;
overflow: hidden; overflow: hidden;
overflow-y: auto; overflow-y: auto;
min-height: 100%;
} }
html { html {
...@@ -24,11 +25,9 @@ html { ...@@ -24,11 +25,9 @@ html {
html, html,
body { body {
width: 100%; width: 100%;
height: 100%;
margin: 0; margin: 0;
padding: 0; padding: 0;
position: relative; position: relative;
min-height: 100%;
} }
.btn-primary:focus, .btn-primary.focus { .btn-primary:focus, .btn-primary.focus {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment