From 991da9bf0975e595f7cc584cdf2ea6cb8a14b7ad Mon Sep 17 00:00:00 2001 From: Masahiro FUJIMOTO Date: Thu, 14 Oct 2021 00:57:05 +0900 Subject: CSS 変換の各ページの変換準備 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- files/ja/web/css/translate/index.html | 119 ---------------------------------- 1 file changed, 119 deletions(-) delete mode 100644 files/ja/web/css/translate/index.html (limited to 'files/ja/web/css/translate/index.html') diff --git a/files/ja/web/css/translate/index.html b/files/ja/web/css/translate/index.html deleted file mode 100644 index c006580ae4..0000000000 --- a/files/ja/web/css/translate/index.html +++ /dev/null @@ -1,119 +0,0 @@ ---- -title: translate -slug: Web/CSS/translate -tags: - - CSS - - CSS Property - - CSS 変形 - - Experimental - - Reference - - Transforms -translation_of: Web/CSS/translate ---- -
{{CSSRef}}{{SeeCompatTable}}
- -

translateCSS のプロパティで、平行移動による変形を独自に、 {{CSSxRef("transform")}} プロパティから独立して指定することができます。これは一般的なユーザーインターフェイスの用途に適しており、 transform の値で指定する変形関数を正確に思い出す必要がなくなります。

- -

構文

- -
/* キーワード値 */
-translate: none;
-
-/* 単一の値 */
-translate: 100px;
-translate: 50%;
-
-/* 二つの値 */
-translate: 100px 200px;
-translate: 50% 105px;
-
-/* 三つの値 */
-translate: 50% 105px 5rem;
-
- -

- -
-
単一の {{cssxref("<length-percentage>")}} 値
-
単一の {{cssxref("<length>")}} または {{cssxref("<percentage>")}} 値で、 X 軸および Y 軸方向が同じ移動量の二次元の平行移動を指定します。 translate() (二次元の平行移動) 関数に単一の値を指定したものと同等です。
-
二つの {{cssxref("<length-percentage>")}} 値
-
二つの {{cssxref("<length>")}} または {{cssxref("<percentage>")}} 値で、二次元の平行移動における X および Y 軸方向の移動量を (それぞれ) 指定します。 translate() (二次元の平行移動) 関数に二つの値を指定したものと同等です。
-
三つの値
-
二つの {{cssxref("<length-percentage>")}} 値と一つの {{cssxref("<length>")}} 値で、三次元の平行移動における X, Y, Z 軸の移動量を (それぞれ) 指定します。 translate3d() (三次元の平行移動) 関数と同等です。
-
none
-
平行移動が適用されないことを指定します。
-
- -

形式文法

- -{{CSSSyntax}} - -

- -

HTML

- -
<div>
-  <p class="translate">Translation</p>
-</div>
- -

CSS

- -
* {
-  box-sizing: border-box;
-}
-
-html {
-  font-family: sans-serif;
-}
-
-div {
-  width: 150px;
-  margin: 0 auto;
-}
-
-p {
-  padding: 10px 5px;
-  border: 3px solid black;
-  border-radius: 20px;
-  width: 150px;
-  font-size: 1.2rem;
-  text-align: center;
-}
-
-.translate {
-  transition: translate 1s;
-}
-
-div:hover .translate {
-  translate: 200px 50px;
-}
-
- -

結果

- -

{{EmbedLiveSample('Examples')}}

- -

仕様書

- - - - - - - - - - - - - - - - -
仕様書状態備考
{{SpecName('CSS Transforms 2', '#individual-transforms', 'individual transforms')}}{{Spec2('CSS Transforms 2')}}初回定義
- -

{{CSSInfo}}

- -

ブラウザーの対応

- -

{{Compat("css.properties.translate")}}

-- cgit v1.2.3-54-g00ecf