Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(components/tool/app): Create specific methods to determine each … #661

Merged
merged 5 commits into from
May 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions components/tool/app/src/core.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,8 @@ import {Capacitor, CapacitorCookies, CapacitorHttp} from '@capacitor/core'
export const getApp = () => App
export const getHttp = () => CapacitorHttp
export const getPlatform = () => Capacitor.getPlatform()
export const isIos = () => Capacitor.getPlatform() === 'ios'
export const isAndroid = () => Capacitor.getPlatform() === 'android'
export const isWeb = () => Capacitor.getPlatform() === 'web'
export const isNative = () => Capacitor.isNativePlatform()
export const setCookie = async props => CapacitorCookies.setCookie(props)
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
"@s-ui/js-compiler": "1",
"@s-ui/lint": "4",
"@s-ui/precommit": "3",
"@s-ui/studio": "11",
"@s-ui/studio": "11.40.0",
"@wojtekmaj/enzyme-adapter-react-17": "0.4.1",
"enzyme": "3.11.0",
"jest": "26.6.3",
Expand Down Expand Up @@ -87,4 +87,4 @@
"stylelint": {
"extends": "./node_modules/@s-ui/lint/stylelint.config.js"
}
}
}
Loading