Safari for iPhone 1.1.1 の修正点と問題

確認は iPod touch 1.1.1(3A110a) で行った。
Release Notes

  • viewport で device-width, device-height が使える。
<meta name="viewport" content=" width=device-width " />
  • 自身または上位のタグの lang 属性でテキストフィールドの入力メソッドが変更される。
    • ページ読み込み後に変更した場合も入力メソッドは変更される。
    • input タグの onfocus で変更しても間に合わない。
<head lang="ja">
<body>
  <input type="text" /> <!-- 日本語入力 -->
  <input type="text" lang="en" /> <!-- 英語入力 -->
  <input type="text" onfocus="this.lang='en'" /> <!-- 初回のみ日本語入力 -->
  <div lang="en">
    <input type="text" /> <!-- 英語入力 -->
  • body.onorientationchange イベント追加。
  • window.orientation プロパティ追加。値は 90, 0, -90。
  • window.onscroll イベント実装。
  • window.scrollTo(), scrollBy() 実装。
    • scrollTo(0, 0) を認識しない。
scrollTo(0, 1); // 動く
scrollTo(1, 0); // 動く
scrollTo(0, 0); // 動かない
scrollTo(1, 0); scrollBy(-1, 0) // 暫定対処
  • window.pageXOffset, pageYOffset, innerWidth, innerHeight プロパティ実装。
    • div などの offsetTop, offsetWidth, clientWidth, innerWidth, scrollWidth 等はすべて undefined。
  • window.console 追加。
console.log('log text');