Skip to content

Commit 53119a5

Browse files
committed
Update 2-ui\1-document\09-size-and-scroll\article.md
1 parent c32a903 commit 53119a5

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

2-ui/1-document/09-size-and-scroll/article.md

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Dimensioni dell'elemento e scorrimento
22

3-
Ci sono molte proprietà JavaScript che ci consentono di leggere informazioni circa la larghezza di un elemento, l'altezza e le altre caratteristiche geometriche.
3+
Ci sono molte proprietà JavaScript che ci consentono di leggere informazioni circa la larghezza, l'altezza di un elemento e le altre caratteristiche geometriche.
44

55
Spesso ne abbiamo bisogno quando spostiamo o posizioniamo gli elementi in JavaScript.
66

@@ -23,31 +23,31 @@ Useremo l'elemento indicato a seguire come esempio di tali proprietà:
2323
</style>
2424
```
2525

26-
It has the border, padding and scrolling. The full set of features. There are no margins, as they are not the part of the element itself, and there are no special properties for them.
26+
Questo elemento possiede bordi, padding e barra di scorrimento: l'intero insieme delle proprietà. Non ci sono margini, in quanto questi non fanno parte dell'elemento stesso, e non ci sono proprietà speciali.
2727

28-
The element looks like this:
28+
L'elemento ha questo aspetto:
2929

3030
![](metric-css.svg)
3131

32-
You can [open the document in the sandbox](sandbox:metric).
32+
Potete [visualizzare il documento nella sandbox](sandbox:metric).
3333

34-
```smart header="Mind the scrollbar"
35-
The picture above demonstrates the most complex case when the element has a scrollbar. Some browsers (not all) reserve the space for it by taking it from the content (labeled as "content width" above).
34+
```smart header="Prestate attenzione alla barra di scorrimento"
35+
L'immagine sopra rappresenta il caso più complesso in cui l'elemento ha una barra di scorrimento. Alcuni browser (non tutti) ricavano lo spazio per la barra prendendolo dall'area del contenuto (indicata sopra come "content width").
3636
37-
So, without scrollbar the content width would be `300px`, but if the scrollbar is `16px` wide (the width may vary between devices and browsers) then only `300 - 16 = 284px` remains, and we should take it into account. That's why examples from this chapter assume that there's a scrollbar. Without it, some calculations are simpler.
37+
Senza la barra di scorrimento, pertanto, l'area del contenuto sarebbe `300px`, ma se la barra di scorrimento è larga `16px` (la larghezza è variabile in base al dispositivo ed al browser) allora rimane soltanto `300 - 16 = 284px`, ed è questa la misura che dovremmo tenere in considerazione. Ecco perché gli esempi di questo capitolo presumono che ci sia una barra di scorrimento. Senza questa, alcuni calcoli sono più semplici.
3838
```
3939

40-
```smart header="The `padding-bottom` area may be filled with text"
41-
Usually paddings are shown empty on our illustrations, but if there's a lot of text in the element and it overflows, then browsers show the "overflowing" text at `padding-bottom`, that's normal.
40+
```smart header="L'area del `padding-bottom` può essere riempita dal testo"
41+
Di solito gli spazi definiti dai padding sono rappresentati vuoti nelle immagini, ma se c'è molto testo nell'elemento ed eccede l'area del contenuto, in quel caso è normale che il browser mostri il testo eccedente nel `padding-bottom`.
4242
```
4343
44-
## Geometry
44+
## Proprietà geometriche
4545
46-
Here's the overall picture with geometry properties:
46+
Ecco un'immagine riassuntiva delle proprietà geometriche:
4747
4848
![](metric-all.svg)
4949
50-
Values of these properties are technically numbers, but these numbers are "of pixels", so these are pixel measurements.
50+
I valori di tali proprietà sono tecnicamente numerici, ma questi numeri sono pixel, quindi si tratta delle dimensioni in pixel.
5151
5252
Let's start exploring the properties starting from the outside of the element.
5353

0 commit comments

Comments
 (0)