From 1831066259a5d15b5b763592ece10d22bbcf6d8e Mon Sep 17 00:00:00 2001 From: Michael Vogel Date: Mon, 2 Nov 2015 23:12:09 +0100 Subject: [PATCH 1/2] Vier is now a little bit more mobile ready. --- view/theme/vier/mobile.css | 51 ++++++++++++++++++++++++++++++++++++++ view/theme/vier/theme.php | 6 ++++- 2 files changed, 56 insertions(+), 1 deletion(-) create mode 100644 view/theme/vier/mobile.css diff --git a/view/theme/vier/mobile.css b/view/theme/vier/mobile.css new file mode 100644 index 0000000000..198846e790 --- /dev/null +++ b/view/theme/vier/mobile.css @@ -0,0 +1,51 @@ +aside, header, #nav-events-link, #search-box, #nav-admin-link, #activitiy-by-date-tab, #shared-links-tab { + display: none; +} + +.hide-comments-outer { + width: calc(100% - 105px); +} + +section { + /* left: calc((100% - (784px)) / 2); */ + left: 0px; + width: calc(100% - 20px); + max-width: 100%; + padding: 10px; +} + +body, section, nav .nav-menu, div.pager, ul.tabs, .wall-item-container .wall-item-ago, .wall-item-network, +.type-link blockquote, .type-video blockquote { + font-size: 16px; +} + +nav { + min-width: 480px; +} + +.wall-item-container .wall-item-content { +/* margin-left: -70px; + padding-top: 25px; */ +} + +.wall-item-container .wall-item-content img { + max-width: 400px; +} + +nav ul { + margin-left: 0px; +} + +.wall-item-container .wall-item-content .type-link img.attachment-image, .type-link img.attachment-image, .type-video img.attachment-image { + max-width: 400px; +} + +.wall-item-container.thread_level_2, +.wall-item-container.thread_level_3, +.wall-item-container.thread_level_4, +.wall-item-container.thread_level_5, +.wall-item-container.thread_level_6, +.wall-item-container.thread_level_7 { + margin-left: 60px; + width: calc(100% - 70px); +} diff --git a/view/theme/vier/theme.php b/view/theme/vier/theme.php index 51e1e36f62..7db984e267 100644 --- a/view/theme/vier/theme.php +++ b/view/theme/vier/theme.php @@ -26,10 +26,14 @@ function vier_init(&$a) { if ($a->argv[0].$a->argv[1] === "profile".$a->user['nickname'] or $a->argv[0] === "network" && local_user()) { vier_community_info(); - $a->page['htmlhead'] .= ""; + $a->page['htmlhead'] .= "\n"; } + if ($a->is_mobile || $a->is_tablet) + $a->page['htmlhead'] .= ''."\n"; + $a->page['htmlhead'] .= <<< EOT +