Phonegap(cordova)とIBMWorklightを使用してサンプルのハイブリッドモバイルアプリを作成しようとしています。iPadとiPhoneをターゲットデバイスとして追加しました。
アプリ内のWebコンテンツは、CSS @mediaクエリを使用して、レスポンシブコンテンツになります。
私が直面している問題は、iPad / iPhoneでアプリケーションを起動すると、作成したメディアクエリが認識されないことです。デバイスの向きのアプローチと最大幅のアプローチを使用してCSSを切り替えてみました。まだ成功していません。
デバイス幅アプローチで使用されたコードは
/* Portrait */
@media screen and (max-width: 768px) {
/* Portrait styles since iPad in portrait has device width 768px */
/* Landscape */
@media screen and (max-width: 1024px) {
/* Landscape styles since iPad in landscape has device width 1024px */
}
オリエンテーションのために私は試しました
/* Portrait */
@media screen and (orientation:portrait) {
/* Portrait styles */
/* Landscape */
@media screen and (orientation:landscape) {
/* Landscape styles */
}
IBM Worklight、phonegapでレスポンシブWebアプリを作成する方法を誰かが提案できますか