--- title: zoom slug: conflicting/Web/CSS/@viewport_e065ce90bde08c9679692adbe64f6518 tags: - '@viewport' - At-rule descriptor - CSS - CSS Descriptor - Graphics - Layout - Reference - Web translation_of: Web/CSS/@viewport translation_of_original: Web/CSS/@viewport/zoom original_slug: Web/CSS/@viewport/zoom --- <div>{{CSSRef}}</div> <p><strong><code>zoom</code></strong> は <a href="/ja/docs/Web/CSS">CSS</a> の記述子で、 {{cssxref("@viewport")}} <a href="/ja/docs/Web/CSS/At-rule">アット規則</a>で定義された文書の表示倍率の初期値を設定します。</p> <p><em>表示倍率</em> が <code>1.0</code> または <code>100%</code> が、拡大縮小なしに対応します。より大きい値は拡大、より小さい値は縮小です。</p> <h2 id="Syntax" name="Syntax">構文</h2> <pre class="brush:css notranslate">/* キーワード値 */ zoom: auto; /* <number> 値 */ zoom: 0.8; zoom: 2.0; /* <percentage> 値 */ zoom: 150%; </pre> <h3 id="Values" name="Values">値</h3> <dl> <dt><code>auto</code></dt> <dd>{{glossary("user agent", "ユーザーエージェント")}}が文書の表示倍率の初期値を設定します。ユーザーエージェントは表示倍率を決めるために、文書が表示されるキャンバス領域の寸法を使用することがあります。</dd> <dt>{{cssxref("<number>")}}</dt> <dd>表示倍率として使われる非負の数値です。</dd> <dt>{{cssxref("<percentage>")}}</dt> <dd>表示倍率として使われる非負のパーセント値です。</dd> </dl> <h2 id="Formal_definition" name="Formal_definition">公式定義</h2> <p>{{cssinfo}}</p> <h2 id="Formal_syntax" name="Formal_syntax">形式文法</h2> {{csssyntax}} <h2 id="Examples" name="Examples">例</h2> <h3 id="Setting_viewport_zoom_factor" name="Setting_viewport_zoom_factor">ビューポートの zoom 係数の設定</h3> <pre class="notranslate"><code>@viewport { zoom: 2.0; }</code></pre> <h2 id="Specifications" name="Specifications">仕様書</h2> <table class="standard-table"> <thead> <tr> <th scope="col">仕様書</th> <th scope="col">状態</th> <th scope="col">備考</th> </tr> </thead> <tbody> <tr> <td>{{SpecName('CSS3 Device', '#the-lsquozoomrsquo-descriptor', '"zoom" descriptor')}}</td> <td>{{Spec2('CSS3 Device')}}</td> <td>初回定義</td> </tr> </tbody> </table> <h2 id="Browser_compatibility" name="Browser_compatibility">ブラウザーの互換性</h2> <div class="hidden">このページの互換性一覧表は構造化データから生成されています。データに協力していただけるのであれば、 <a class="external" href="https://github.com/mdn/browser-compat-data">https://github.com/mdn/browser-compat-data</a> をチェックアウトしてプルリクエストを送信してください。</div> <p>{{Compat("css.at-rules.viewport.zoom")}}</p> <h2 id="See_also" name="See_also">関連情報</h2> <ul> <li>{{cssxref("@viewport")}}</li> </ul>