mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-03 16:51:40 +09:00
Change behavior of \@mobile directive in template v2 #2510
This commit is contained in:
parent
82195c3e14
commit
800eb2f444
4 changed files with 15 additions and 5 deletions
|
|
@ -945,6 +945,16 @@ class Template
|
|||
return count($args) ? in_array((string)$validator_id, $args, true) : true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if the current visitor is using a mobile device for v2.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
protected function _v2_isMobile(): bool
|
||||
{
|
||||
return UA::isMobile() && (config('mobile.tablets') || !UA::isTablet());
|
||||
}
|
||||
|
||||
/**
|
||||
* Lang shortcut for v2.
|
||||
*
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue