Skip to content

Commit

Permalink
Test user agent in browser
Browse files Browse the repository at this point in the history
  • Loading branch information
falkodev committed Oct 6, 2024
1 parent 1b6304d commit 965cb34
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions server/modules/asset/ui/src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import { DotLottie } from '@lottiefiles/dotlottie-web'
export default () => {
apos.util.onReady(async () => {
const ua = window.navigator.userAgent
console.log('ua ====> ', ua)
const iosDevice = !!ua.match(/iPad/i) || !!ua.match(/iPhone/i) || (!!ua.match(/Macintosh/i) && !ua.match(/Chrome/i))
if (iosDevice) {
document.body.classList.add('pdl-ios-device')
Expand Down

0 comments on commit 965cb34

Please sign in to comment.