Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 14 additions & 14 deletions src/content/learn/adding-interactivity.md
Original file line number Diff line number Diff line change
Expand Up @@ -139,73 +139,73 @@ export const sculptureList = [{
name: 'Homenaje a la Neurocirugía',
artist: 'Marta Colvin Andrade',
description: 'Although Colvin is predominantly known for abstract themes that allude to pre-Hispanic symbols, this gigantic sculpture, an homage to neurosurgery, is one of her most recognizable public art pieces.',
url: 'https://i.imgur.com/Mx7dA2Y.jpg',
url: 'https://i.imgur.com.prx.react.dev/Mx7dA2Y.jpg',
alt: 'A bronze statue of two crossed hands delicately holding a human brain in their fingertips.'
}, {
name: 'Floralis Genérica',
artist: 'Eduardo Catalano',
description: 'This enormous (75 ft. or 23m) silver flower is located in Buenos Aires. It is designed to move, closing its petals in the evening or when strong winds blow and opening them in the morning.',
url: 'https://i.imgur.com/ZF6s192m.jpg',
url: 'https://i.imgur.com.prx.react.dev/ZF6s192m.jpg',
alt: 'A gigantic metallic flower sculpture with reflective mirror-like petals and strong stamens.'
}, {
name: 'Eternal Presence',
artist: 'John Woodrow Wilson',
description: 'Wilson was known for his preoccupation with equality, social justice, as well as the essential and spiritual qualities of humankind. This massive (7ft. or 2,13m) bronze represents what he described as "a symbolic Black presence infused with a sense of universal humanity."',
url: 'https://i.imgur.com/aTtVpES.jpg',
url: 'https://i.imgur.com.prx.react.dev/aTtVpES.jpg',
alt: 'The sculpture depicting a human head seems ever-present and solemn. It radiates calm and serenity.'
}, {
name: 'Moai',
artist: 'Unknown Artist',
description: 'Located on the Easter Island, there are 1,000 moai, or extant monumental statues, created by the early Rapa Nui people, which some believe represented deified ancestors.',
url: 'https://i.imgur.com/RCwLEoQm.jpg',
url: 'https://i.imgur.com.prx.react.dev/RCwLEoQm.jpg',
alt: 'Three monumental stone busts with the heads that are disproportionately large with somber faces.'
}, {
name: 'Blue Nana',
artist: 'Niki de Saint Phalle',
description: 'The Nanas are triumphant creatures, symbols of femininity and maternity. Initially, Saint Phalle used fabric and found objects for the Nanas, and later on introduced polyester to achieve a more vibrant effect.',
url: 'https://i.imgur.com/Sd1AgUOm.jpg',
url: 'https://i.imgur.com.prx.react.dev/Sd1AgUOm.jpg',
alt: 'A large mosaic sculpture of a whimsical dancing female figure in a colorful costume emanating joy.'
}, {
name: 'Ultimate Form',
artist: 'Barbara Hepworth',
description: 'This abstract bronze sculpture is a part of The Family of Man series located at Yorkshire Sculpture Park. Hepworth chose not to create literal representations of the world but developed abstract forms inspired by people and landscapes.',
url: 'https://i.imgur.com/2heNQDcm.jpg',
url: 'https://i.imgur.com.prx.react.dev/2heNQDcm.jpg',
alt: 'A tall sculpture made of three elements stacked on each other reminding of a human figure.'
}, {
name: 'Cavaliere',
artist: 'Lamidi Olonade Fakeye',
description: "Descended from four generations of woodcarvers, Fakeye's work blended traditional and contemporary Yoruba themes.",
url: 'https://i.imgur.com/wIdGuZwm.png',
url: 'https://i.imgur.com.prx.react.dev/wIdGuZwm.png',
alt: 'An intricate wood sculpture of a warrior with a focused face on a horse adorned with patterns.'
}, {
name: 'Big Bellies',
artist: 'Alina Szapocznikow',
description: "Szapocznikow is known for her sculptures of the fragmented body as a metaphor for the fragility and impermanence of youth and beauty. This sculpture depicts two very realistic large bellies stacked on top of each other, each around five feet (1,5m) tall.",
url: 'https://i.imgur.com/AlHTAdDm.jpg',
url: 'https://i.imgur.com.prx.react.dev/AlHTAdDm.jpg',
alt: 'The sculpture reminds a cascade of folds, quite different from bellies in classical sculptures.'
}, {
name: 'Terracotta Army',
artist: 'Unknown Artist',
description: 'The Terracotta Army is a collection of terracotta sculptures depicting the armies of Qin Shi Huang, the first Emperor of China. The army consisted of more than 8,000 soldiers, 130 chariots with 520 horses, and 150 cavalry horses.',
url: 'https://i.imgur.com/HMFmH6m.jpg',
url: 'https://i.imgur.com.prx.react.dev/HMFmH6m.jpg',
alt: '12 terracotta sculptures of solemn warriors, each with a unique facial expression and armor.'
}, {
name: 'Lunar Landscape',
artist: 'Louise Nevelson',
description: 'Nevelson was known for scavenging objects from New York City debris, which she would later assemble into monumental constructions. In this one, she used disparate parts like a bedpost, juggling pin, and seat fragment, nailing and gluing them into boxes that reflect the influence of Cubism’s geometric abstraction of space and form.',
url: 'https://i.imgur.com/rN7hY6om.jpg',
url: 'https://i.imgur.com.prx.react.dev/rN7hY6om.jpg',
alt: 'A black matte sculpture where the individual elements are initially indistinguishable.'
}, {
name: 'Aureole',
artist: 'Ranjani Shettar',
description: 'Shettar merges the traditional and the modern, the natural and the industrial. Her art focuses on the relationship between man and nature. Her work was described as compelling both abstractly and figuratively, gravity defying, and a "fine synthesis of unlikely materials."',
url: 'https://i.imgur.com/okTpbHhm.jpg',
url: 'https://i.imgur.com.prx.react.dev/okTpbHhm.jpg',
alt: 'A pale wire-like sculpture mounted on concrete wall and descending on the floor. It appears light.'
}, {
name: 'Hippos',
artist: 'Taipei Zoo',
description: 'The Taipei Zoo commissioned a Hippo Square featuring submerged hippos at play.',
url: 'https://i.imgur.com/6o5Vuyu.jpg',
url: 'https://i.imgur.com.prx.react.dev/6o5Vuyu.jpg',
alt: 'A group of bronze hippo sculptures emerging from the sett sidewalk as if they were swimming.'
}];
```
Expand Down Expand Up @@ -423,7 +423,7 @@ export default function Form() {
artwork: {
title: 'Blue Nana',
city: 'Hamburg',
image: 'https://i.imgur.com/Sd1AgUOm.jpg',
image: 'https://i.imgur.com.prx.react.dev/Sd1AgUOm.jpg',
}
});

Expand Down Expand Up @@ -531,7 +531,7 @@ export default function Form() {
artwork: {
title: 'Blue Nana',
city: 'Hamburg',
image: 'https://i.imgur.com/Sd1AgUOm.jpg',
image: 'https://i.imgur.com.prx.react.dev/Sd1AgUOm.jpg',
}
});

Expand Down
14 changes: 7 additions & 7 deletions src/content/learn/describing-the-ui.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ React applications are built from isolated pieces of UI called *components*. A R
function Profile() {
return (
<img
src="https://i.imgur.com/MK3eW3As.jpg"
src="https://i.imgur.com.prx.react.dev/MK3eW3As.jpg"
alt="Katherine Johnson"
/>
);
Expand Down Expand Up @@ -98,7 +98,7 @@ export default function Gallery() {
export default function Profile() {
return (
<img
src="https://i.imgur.com/QIrZWGIs.jpg"
src="https://i.imgur.com.prx.react.dev/QIrZWGIs.jpg"
alt="Alan L. Hart"
/>
);
Expand Down Expand Up @@ -131,7 +131,7 @@ export default function TodoList() {
// This doesn't quite work!
<h1>Hedy Lamarr's Todos</h1>
<img
src="https://i.imgur.com/yXOvdOSs.jpg"
src="https://i.imgur.com.prx.react.dev/yXOvdOSs.jpg"
alt="Hedy Lamarr"
class="photo"
>
Expand Down Expand Up @@ -160,7 +160,7 @@ export default function TodoList() {
<>
<h1>Hedy Lamarr's Todos</h1>
<img
src="https://i.imgur.com/yXOvdOSs.jpg"
src="https://i.imgur.com.prx.react.dev/yXOvdOSs.jpg"
alt="Hedy Lamarr"
className="photo"
/>
Expand Down Expand Up @@ -207,7 +207,7 @@ export default function TodoList() {
<h1>{person.name}'s Todos</h1>
<img
className="avatar"
src="https://i.imgur.com/7vQD0fPs.jpg"
src="https://i.imgur.com.prx.react.dev/7vQD0fPs.jpg"
alt="Gregorio Y. Zara"
/>
<ul>
Expand Down Expand Up @@ -282,7 +282,7 @@ function Card({ children }) {
```js src/utils.js
export function getImageUrl(person, size = 's') {
return (
'https://i.imgur.com/' +
'https://i.imgur.com.prx.react.dev/' +
person.imageId +
size +
'.jpg'
Expand Down Expand Up @@ -435,7 +435,7 @@ export const people = [{
```js src/utils.js
export function getImageUrl(person) {
return (
'https://i.imgur.com/' +
'https://i.imgur.com.prx.react.dev/' +
person.imageId +
's.jpg'
);
Expand Down
12 changes: 6 additions & 6 deletions src/content/learn/importing-and-exporting-components.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ In [Your First Component](/learn/your-first-component), you made a `Profile` com
function Profile() {
return (
<img
src="https://i.imgur.com/MK3eW3As.jpg"
src="https://i.imgur.com.prx.react.dev/MK3eW3As.jpg"
alt="Katherine Johnson"
/>
);
Expand Down Expand Up @@ -80,7 +80,7 @@ export default function App() {
function Profile() {
return (
<img
src="https://i.imgur.com/QIrZWGIs.jpg"
src="https://i.imgur.com.prx.react.dev/QIrZWGIs.jpg"
alt="Alan L. Hart"
/>
);
Expand Down Expand Up @@ -198,7 +198,7 @@ export default function App() {
export function Profile() {
return (
<img
src="https://i.imgur.com/QIrZWGIs.jpg"
src="https://i.imgur.com.prx.react.dev/QIrZWGIs.jpg"
alt="Alan L. Hart"
/>
);
Expand Down Expand Up @@ -286,7 +286,7 @@ export default function App() {
export function Profile() {
return (
<img
src="https://i.imgur.com/QIrZWGIs.jpg"
src="https://i.imgur.com.prx.react.dev/QIrZWGIs.jpg"
alt="Alan L. Hart"
/>
);
Expand Down Expand Up @@ -354,7 +354,7 @@ export default function Gallery() {
export function Profile() {
return (
<img
src="https://i.imgur.com/QIrZWGIs.jpg"
src="https://i.imgur.com.prx.react.dev/QIrZWGIs.jpg"
alt="Alan L. Hart"
/>
);
Expand Down Expand Up @@ -404,7 +404,7 @@ export default function Gallery() {
export default function Profile() {
return (
<img
src="https://i.imgur.com/QIrZWGIs.jpg"
src="https://i.imgur.com.prx.react.dev/QIrZWGIs.jpg"
alt="Alan L. Hart"
/>
);
Expand Down
2 changes: 1 addition & 1 deletion src/content/learn/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ You can put more complex expressions inside the JSX curly braces too, for exampl
```js
const user = {
name: 'Hedy Lamarr',
imageUrl: 'https://i.imgur.com/yXOvdOSs.jpg',
imageUrl: 'https://i.imgur.com.prx.react.dev/yXOvdOSs.jpg',
imageSize: 90,
};
Expand Down
24 changes: 12 additions & 12 deletions src/content/learn/javascript-in-jsx-with-curly-braces.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ export default function Avatar() {
return (
<img
className="avatar"
src="https://i.imgur.com/7vQD0fPs.jpg"
src="https://i.imgur.com.prx.react.dev/7vQD0fPs.jpg"
alt="Gregorio Y. Zara"
/>
);
Expand All @@ -41,15 +41,15 @@ export default function Avatar() {

</Sandpack>

Here, `"https://i.imgur.com/7vQD0fPs.jpg"` and `"Gregorio Y. Zara"` are being passed as strings.
Here, `"https://i.imgur.com.prx.react.dev/7vQD0fPs.jpg"` and `"Gregorio Y. Zara"` are being passed as strings.

But what if you want to dynamically specify the `src` or `alt` text? You could **use a value from JavaScript by replacing `"` and `"` with `{` and `}`**:

<Sandpack>

```js
export default function Avatar() {
const avatar = 'https://i.imgur.com/7vQD0fPs.jpg';
const avatar = 'https://i.imgur.com.prx.react.dev/7vQD0fPs.jpg';
const description = 'Gregorio Y. Zara';
return (
<img
Expand Down Expand Up @@ -190,7 +190,7 @@ export default function TodoList() {
<h1>{person.name}'s Todos</h1>
<img
className="avatar"
src="https://i.imgur.com/7vQD0fPs.jpg"
src="https://i.imgur.com.prx.react.dev/7vQD0fPs.jpg"
alt="Gregorio Y. Zara"
/>
<ul>
Expand Down Expand Up @@ -266,7 +266,7 @@ export default function TodoList() {
<h1>{person}'s Todos</h1>
<img
className="avatar"
src="https://i.imgur.com/7vQD0fPs.jpg"
src="https://i.imgur.com.prx.react.dev/7vQD0fPs.jpg"
alt="Gregorio Y. Zara"
/>
<ul>
Expand Down Expand Up @@ -314,7 +314,7 @@ export default function TodoList() {
<h1>{person.name}'s Todos</h1>
<img
className="avatar"
src="https://i.imgur.com/7vQD0fPs.jpg"
src="https://i.imgur.com.prx.react.dev/7vQD0fPs.jpg"
alt="Gregorio Y. Zara"
/>
<ul>
Expand Down Expand Up @@ -358,7 +358,7 @@ export default function TodoList() {
<h1>{person.name}'s Todos</h1>
<img
className="avatar"
src="https://i.imgur.com/7vQD0fPs.jpg"
src="https://i.imgur.com.prx.react.dev/7vQD0fPs.jpg"
alt="Gregorio Y. Zara"
/>
<ul>
Expand Down Expand Up @@ -388,7 +388,7 @@ Move the image URL into a property called `person.imageUrl` and read it from the
```js
const person = {
name: 'Gregorio Y. Zara',
imageUrl: "https://i.imgur.com/7vQD0fPs.jpg",
imageUrl: "https://i.imgur.com.prx.react.dev/7vQD0fPs.jpg",
theme: {
backgroundColor: 'black',
color: 'pink'
Expand Down Expand Up @@ -428,15 +428,15 @@ body > div > div { padding: 20px; }

In the object below, the full image URL is split into four parts: base URL, `imageId`, `imageSize`, and file extension.

We want the image URL to combine these attributes together: base URL (always `'https://i.imgur.com/'`), `imageId` (`'7vQD0fP'`), `imageSize` (`'s'`), and file extension (always `'.jpg'`). However, something is wrong with how the `<img>` tag specifies its `src`.
We want the image URL to combine these attributes together: base URL (always `'https://i.imgur.com.prx.react.dev/'`), `imageId` (`'7vQD0fP'`), `imageSize` (`'s'`), and file extension (always `'.jpg'`). However, something is wrong with how the `<img>` tag specifies its `src`.

Can you fix it?

<Sandpack>

```js

const baseUrl = 'https://i.imgur.com/';
const baseUrl = 'https://i.imgur.com.prx.react.dev/';
const person = {
name: 'Gregorio Y. Zara',
imageId: '7vQD0fP',
Expand Down Expand Up @@ -487,7 +487,7 @@ You can write it as `src={baseUrl + person.imageId + person.imageSize + '.jpg'}`
<Sandpack>

```js
const baseUrl = 'https://i.imgur.com/';
const baseUrl = 'https://i.imgur.com.prx.react.dev/';
const person = {
name: 'Gregorio Y. Zara',
imageId: '7vQD0fP',
Expand Down Expand Up @@ -564,7 +564,7 @@ export default function TodoList() {
```js src/utils.js
export function getImageUrl(person) {
return (
'https://i.imgur.com/' +
'https://i.imgur.com.prx.react.dev/' +
person.imageId +
person.imageSize +
'.jpg'
Expand Down
4 changes: 2 additions & 2 deletions src/content/learn/keeping-components-pure.md
Original file line number Diff line number Diff line change
Expand Up @@ -451,7 +451,7 @@ export default function App() {
```js src/utils.js hidden
export function getImageUrl(person, size = 's') {
return (
'https://i.imgur.com/' +
'https://i.imgur.com.prx.react.dev/' +
person.imageId +
size +
'.jpg'
Expand Down Expand Up @@ -549,7 +549,7 @@ export default function App() {
```js src/utils.js hidden
export function getImageUrl(person, size = 's') {
return (
'https://i.imgur.com/' +
'https://i.imgur.com.prx.react.dev/' +
person.imageId +
size +
'.jpg'
Expand Down
4 changes: 2 additions & 2 deletions src/content/learn/passing-data-deeply-with-context.md
Original file line number Diff line number Diff line change
Expand Up @@ -998,7 +998,7 @@ export const places = [{
```js src/utils.js
export function getImageUrl(place) {
return (
'https://i.imgur.com/' +
'https://i.imgur.com.prx.react.dev/' +
place.imageId +
'l.jpg'
);
Expand Down Expand Up @@ -1137,7 +1137,7 @@ export const places = [{
```js src/utils.js
export function getImageUrl(place) {
return (
'https://i.imgur.com/' +
'https://i.imgur.com.prx.react.dev/' +
place.imageId +
'l.jpg'
);
Expand Down
Loading