chore(i18n,learn): processed translations (#44936)
This commit is contained in:
@@ -8,7 +8,7 @@ dashedName: render-conditionally-from-props
|
||||
|
||||
# --description--
|
||||
|
||||
ここまで、いつ、何をレンダーするのかを条件で決める方法として、`if/else`、`&&`、および三項演算子 (` 条件 ? True の場合の式 : False の場合の式`) を使用する方法を紹介しました。 しかし、まだ説明していない重要なトピックが一つあります。それは、これらの概念はそのいずれかまたはすべてを、React の別の強力な機能である props と組み合わせることができる、ということです。 props を使用してコードを条件付きでレンダーすることは、React の開発者にとってはごく一般的な作業です。つまり、与えられた prop の値を利用することで、何を表示するかを自動的に決めることができます。
|
||||
So far, you've seen how to use `if/else`, `&&`, and the ternary operator (`condition ? expressionIfTrue : expressionIfFalse`) to make conditional decisions about what to render and when. However, there's one important topic left to discuss that lets you combine any or all of these concepts with another powerful React feature: props. Using props to conditionally render code is very common with React developers — that is, they use the value of a given prop to automatically make decisions about what to render.
|
||||
|
||||
このチャレンジでは、props に基づいてレンダー処理を決定する子コンポーネントを設定します。 また、三項演算子も使用しますが、前のチャレンジで説明した他のいくつかの概念が、このチャレンジでも同じように役立つかもしれません。
|
||||
|
||||
|
@@ -27,8 +27,8 @@ dashedName: circles-of-given-radius-through-two-points
|
||||
|
||||
<ul>
|
||||
<li>2点が直径上にある場合は、1 点を返します。 ただし、半径もゼロの場合は、<code>"Radius Zero"</code> を返します。</li>
|
||||
<li>2点が完全に一致する場合は、 <code>"Coincident point. Infinite solutions" </code> を返します。</li>
|
||||
<li>2点が直径よりも離れている場合は、<code>"No intersection. Points further apart than circle diameter" </code>を返します。</li>
|
||||
<li>If points are coincident, return <code>"Coincident point. Infinite solutions"</code>.</li>
|
||||
<li>If points are farther apart than the diameter, return <code>"No intersection. Points further apart than circle diameter"</code>.</li>
|
||||
</ul>
|
||||
|
||||
**入力例**
|
||||
@@ -61,13 +61,13 @@ assert.deepEqual(getCircles(...testCases[0]), answers[0]);
|
||||
assert.deepEqual(getCircles(...testCases[1]), answers[1]);
|
||||
```
|
||||
|
||||
`getCircles([0.1234, 0.9876], [0.1234, 0.9876], 2.0)` は `Coincident point. Infinite solutions `を返します。
|
||||
`getCircles([0.1234, 0.9876], [0.1234, 0.9876], 2.0)` should return `Coincident point. Infinite solutions`
|
||||
|
||||
```js
|
||||
assert.deepEqual(getCircles(...testCases[2]), answers[2]);
|
||||
```
|
||||
|
||||
`getCircles([0.1234, 0.9876], [0.8765, 0.2345], 0.5)` は、`No intersection. Points further apart than circle diameter ` を返します。
|
||||
`getCircles([0.1234, 0.9876], [0.8765, 0.2345], 0.5)` should return `No intersection. Points further apart than circle diameter`
|
||||
|
||||
```js
|
||||
assert.deepEqual(getCircles(...testCases[3]), answers[3]);
|
||||
|
@@ -36,7 +36,7 @@ assert(
|
||||
);
|
||||
```
|
||||
|
||||
`discordianDate(new Date(2012, 1, 29))` は `"Setting Orange, the 60th day of Chaos in the YOLD 3178. Celebrate St. Tib\'s Day!" ` を返します。
|
||||
`discordianDate(new Date(2012, 1, 29))` should return `"Setting Orange, the 60th day of Chaos in the YOLD 3178. Celebrate St. Tib\'s Day!"`.
|
||||
|
||||
```js
|
||||
assert(
|
||||
@@ -54,7 +54,7 @@ assert(
|
||||
);
|
||||
```
|
||||
|
||||
`discordianDate(new Date(2010, 0, 5))` は `"Setting Orange, the 5th day of Chaos in the YOLD 3176. Celebrate Mungday!" ` を返します。
|
||||
`discordianDate(new Date(2010, 0, 5))` should return `"Setting Orange, the 5th day of Chaos in the YOLD 3176. Celebrate Mungday!"`.
|
||||
|
||||
```js
|
||||
assert(
|
||||
@@ -63,7 +63,7 @@ assert(
|
||||
);
|
||||
```
|
||||
|
||||
`discordianDate(new Date(2011, 4, 3))` は `"Pungenday, the 50th day of Discord in the YOLD 3177. Celebrate Discoflux!" ` を返します。
|
||||
`discordianDate(new Date(2011, 4, 3))` should return `"Pungenday, the 50th day of Discord in the YOLD 3177. Celebrate Discoflux!"`.
|
||||
|
||||
```js
|
||||
assert(
|
||||
|
@@ -168,7 +168,7 @@ assert.deepEqual(markov(rules[1], tests[1]), outputs[1]);
|
||||
assert.deepEqual(markov(rules[2], tests[2]), outputs[2]);
|
||||
```
|
||||
|
||||
`markov(["_+1 -> _1+","1+1 -> 11+","1! -> !1",",! -> !+","_! -> _","1*1 -> x,@y","1x -> xX","X, -> 1,1","X1 -> 1X","_x -> _X",",x -> ,X","y1 -> 1y","y_ -> _","1@1 -> x,@y","1@_ -> @_",",@_ -> !_","++ -> +","_1 -> 1","1+_ -> 1","_+_ -> "],"_1111*11111_")` は「11111111111111111111」を返します。
|
||||
`markov(["_+1 -> _1+","1+1 -> 11+","1! -> !1",",! -> !+","_! -> _","1*1 -> x,@y","1x -> xX","X, -> 1,1","X1 -> 1X","_x -> _X",",x -> ,X","y1 -> 1y","y_ -> _","1@1 -> x,@y","1@_ -> @_",",@_ -> !_","++ -> +","_1 -> 1","1+_ -> 1","_+_ -> "],"_1111*11111_")` should return "11111111111111111111".
|
||||
|
||||
```js
|
||||
assert.deepEqual(markov(rules[3], tests[3]), outputs[3]);
|
||||
|
@@ -22,7 +22,7 @@ dashedName: factorial
|
||||
<li><code>4! = 4 * 3 * 2 * 1 = 24</code></li>
|
||||
</ul>
|
||||
|
||||
**注記:** `0! = 1`
|
||||
**Note:** `0! = 1`
|
||||
|
||||
# --hints--
|
||||
|
||||
|
Reference in New Issue
Block a user