Skip to content

Commit 273c35f

Browse files
committed
Initial translation of api/directives.md to portuguese
1 parent dc1b3b0 commit 273c35f

File tree

1 file changed

+62
-62
lines changed

1 file changed

+62
-62
lines changed

src/api/directives.md

Lines changed: 62 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,28 @@
1-
# Directives
1+
# Diretivas
22

33
## v-text
44

5-
- **Expects:** `string`
5+
- **Espera:** `string`
66

7-
- **Details:**
7+
- **Detalhes:**
88

99
Updates the element's [textContent](https://developer.mozilla.org/en-US/docs/Web/API/Node/textContent). If you need to update the part of `textContent`, you should use [mustache interpolations](/guide/template-syntax.html#text) instead
1010

11-
- **Example:**
11+
- **Exemplo:**
1212

1313
```html
1414
<span v-text="msg"></span>
1515
<!-- same as -->
1616
<span>{{msg}}</span>
1717
```
1818

19-
- **See also:** [Data Binding Syntax - Interpolations](../guide/template-syntax.html#text)
19+
- **Ver também:** [Data Binding Syntax - Interpolations](../guide/template-syntax.html#text)
2020

2121
## v-html
2222

23-
- **Expects:** `string`
23+
- **Espera:** `string`
2424

25-
- **Details:**
25+
- **Detalhes:**
2626

2727
Updates the element's [innerHTML](https://developer.mozilla.org/en-US/docs/Web/API/Element/innerHTML). **Note that the contents are inserted as plain HTML - they will not be compiled as Vue templates**. If you find yourself trying to compose templates using `v-html`, try to rethink the solution by using components instead.
2828

@@ -32,47 +32,47 @@
3232

3333
In [single-file components](../guide/single-file-component.html), `scoped` styles will not apply to content inside `v-html`, because that HTML is not processed by Vue's template compiler. If you want to target `v-html` content with scoped CSS, you can instead use [CSS modules](https://vue-loader.vuejs.org/en/features/css-modules.html) or an additional, global `<style>` element with a manual scoping strategy such as BEM.
3434

35-
- **Example:**
35+
- **Exemplo:**
3636

3737
```html
3838
<div v-html="html"></div>
3939
```
4040

41-
- **See also:** [Data Binding Syntax - Interpolations](../guide/template-syntax.html#raw-html)
41+
- **Ver também:** [Data Binding Syntax - Interpolations](../guide/template-syntax.html#raw-html)
4242

4343
## v-show
4444

45-
- **Expects:** `any`
45+
- **Espera:** `any`
4646

47-
- **Usage:**
47+
- **Uso:**
4848

4949
Toggles the element's `display` CSS property based on the truthy-ness of the expression value.
5050

5151
This directive triggers transitions when its condition changes.
5252

53-
- **See also:** [Conditional Rendering - v-show](../guide/conditional.html#v-show)
53+
- **Ver também:** [Conditional Rendering - v-show](../guide/conditional.html#v-show)
5454

5555
## v-if
5656

57-
- **Expects:** `any`
57+
- **Espera:** `any`
5858

59-
- **Usage:**
59+
- **Uso:**
6060

6161
Conditionally render the element based on the truthy-ness of the expression value. The element and its contained directives / components are destroyed and re-constructed during toggles. If the element is a `<template>` element, its content will be extracted as the conditional block.
6262

6363
This directive triggers transitions when its condition changes.
6464

6565
When used together, `v-if` has a higher priority than `v-for`. We don't recommend using these two directives together on one element — see the [list rendering guide](../guide/list.html#v-for-with-v-if) for details.
6666

67-
- **See also:** [Conditional Rendering - v-if](../guide/conditional.html#v-if)
67+
- **Ver também:** [Conditional Rendering - v-if](../guide/conditional.html#v-if)
6868

6969
## v-else
7070

71-
- **Does not expect expression**
71+
- **Não espera expressão**
7272

7373
- **Restriction:** previous sibling element must have `v-if` or `v-else-if`.
7474

75-
- **Usage:**
75+
- **Uso:**
7676

7777
Denote the "else block" for `v-if` or a `v-if`/`v-else-if` chain.
7878

@@ -85,15 +85,15 @@
8585
</div>
8686
```
8787

88-
- **See also:** [Conditional Rendering - v-else](../guide/conditional.html#v-else)
88+
- **Ver também:** [Conditional Rendering - v-else](../guide/conditional.html#v-else)
8989

9090
## v-else-if
9191

92-
- **Expects:** `any`
92+
- **Espera:** `any`
9393

9494
- **Restriction:** previous sibling element must have `v-if` or `v-else-if`.
9595

96-
- **Usage:**
96+
- **Uso:**
9797

9898
Denote the "else if block" for `v-if`. Can be chained.
9999

@@ -112,13 +112,13 @@
112112
</div>
113113
```
114114

115-
- **See also:** [Conditional Rendering - v-else-if](../guide/conditional.html#v-else-if)
115+
- **Ver também:** [Conditional Rendering - v-else-if](../guide/conditional.html#v-else-if)
116116

117117
## v-for
118118

119-
- **Expects:** `Array | Object | number | string | Iterable`
119+
- **Espera:** `Array | Object | number | string | Iterable`
120120

121-
- **Usage:**
121+
- **Uso:**
122122

123123
Render the element or template block multiple times based on the source data. The directive's value must use the special syntax `alias in expression` to provide an alias for the current element being iterated on:
124124

@@ -148,18 +148,18 @@
148148

149149
The detailed usage for `v-for` is explained in the guide section linked below.
150150

151-
- **See also:**
151+
- **Ver também:**
152152
- [List Rendering](../guide/list.html)
153153

154154
## v-on
155155

156-
- **Shorthand:** `@`
156+
- **Forma abreviada:** `@`
157157

158-
- **Expects:** `Function | Inline Statement | Object`
158+
- **Espera:** `Function | Inline Statement | Object`
159159

160-
- **Argument:** `event`
160+
- **Argumento:** `event`
161161

162-
- **Modifiers:**
162+
- **Modificadores:**
163163

164164
- `.stop` - call `event.stopPropagation()`.
165165
- `.prevent` - call `event.preventDefault()`.
@@ -172,7 +172,7 @@
172172
- `.middle` - only trigger handler for middle button mouse events.
173173
- `.passive` - attaches a DOM event with `{ passive: true }`.
174174

175-
- **Usage:**
175+
- **Uso:**
176176

177177
Attaches an event listener to the element. The event type is denoted by the argument. The expression can be a method name, an inline statement, or omitted if there are modifiers present.
178178

@@ -182,7 +182,7 @@
182182

183183
`v-on` also supports binding to an object of event/listener pairs without an argument. Note when using the object syntax, it does not support any modifiers.
184184

185-
- **Example:**
185+
- **Exemplo:**
186186

187187
```html
188188
<!-- method handler -->
@@ -231,23 +231,23 @@
231231
<my-component @my-event="handleThis(123, $event)"></my-component>
232232
```
233233

234-
- **See also:**
234+
- **Ver também:**
235235
- [Event Handling](../guide/events.html)
236236
- [Components - Custom Events](../guide/component-basics.html#listening-to-child-components-events)
237237

238238
## v-bind
239239

240-
- **Shorthand:** `:`
240+
- **Forma abreviada:** `:`
241241

242-
- **Expects:** `any (with argument) | Object (without argument)`
242+
- **Espera:** `any (with argument) | Object (without argument)`
243243

244-
- **Argument:** `attrOrProp (optional)`
244+
- **Argumento:** `attrOrProp (optional)`
245245

246-
- **Modifiers:**
246+
- **Modificadores:**
247247

248248
- `.camel` - transform the kebab-case attribute name into camelCase.
249249

250-
- **Usage:**
250+
- **Uso:**
251251

252252
Dynamically bind one or more attributes, or a component prop to an expression.
253253

@@ -257,7 +257,7 @@
257257

258258
When used without an argument, can be used to bind an object containing attribute name-value pairs. Note in this mode `class` and `style` does not support Array or Objects.
259259

260-
- **Example:**
260+
- **Exemplo:**
261261

262262
```html
263263
<!-- bind an attribute -->
@@ -305,53 +305,53 @@
305305

306306
`.camel` is not needed if you are using string templates, or compiling with `vue-loader`/`vueify`.
307307

308-
- **See also:**
308+
- **Ver também:**
309309
- [Class and Style Bindings](../guide/class-and-style.html)
310310
- [Components - Props](../guide/component-basics.html#passing-data-to-child-components-with-props)
311311

312312
## v-model
313313

314-
- **Expects:** varies based on value of form inputs element or output of components
314+
- **Espera:** varies based on value of form inputs element or output of components
315315

316-
- **Limited to:**
316+
- **Limitado a:**
317317

318318
- `<input>`
319319
- `<select>`
320320
- `<textarea>`
321321
- components
322322

323-
- **Modifiers:**
323+
- **Modificadores:**
324324

325325
- [`.lazy`](../guide/forms.html#lazy) - listen to `change` events instead of `input`
326326
- [`.number`](../guide/forms.html#number) - cast valid input string to numbers
327327
- [`.trim`](../guide/forms.html#trim) - trim input
328328

329-
- **Usage:**
329+
- **Uso:**
330330

331331
Create a two-way binding on a form input element or a component. For detailed usage and other notes, see the Guide section linked below.
332332

333-
- **See also:**
333+
- **Ver também:**
334334
- [Form Input Bindings](../guide/forms.html)
335335
- [Components - Form Input Components using Custom Events](../guide/component-custom-events.html#v-model-arguments)
336336

337337
## v-slot
338338

339-
- **Shorthand:** `#`
339+
- **Forma abreviada:** `#`
340340

341-
- **Expects:** JavaScript expression that is valid in a function argument position (supports destructuring in [supported environments](../guide/component-slots.html#destructuring-slot-props)). Optional - only needed if expecting props to be passed to the slot.
341+
- **Espera:** JavaScript expression that is valid in a function argument position (supports destructuring in [supported environments](../guide/component-slots.html#destructuring-slot-props)). Optional - only needed if expecting props to be passed to the slot.
342342

343-
- **Argument:** slot name (optional, defaults to `default`)
343+
- **Argumento:** slot name (optional, defaults to `default`)
344344

345-
- **Limited to:**
345+
- **Limitado a:**
346346

347347
- `<template>`
348348
- [components](../guide/component-slots.html#abbreviated-syntax-for-lone-default-slots) (for a lone default slot with props)
349349

350-
- **Usage:**
350+
- **Uso:**
351351

352352
Denote named slots or slots that expect to receive props.
353353

354-
- **Example:**
354+
- **Exemplo:**
355355

356356
```html
357357
<!-- Named slots -->
@@ -386,32 +386,32 @@
386386

387387
For more details, see the links below.
388388

389-
- **See also:**
389+
- **Ver também:**
390390
- [Components - Slots](../guide/component-slots.html)
391391

392392
## v-pre
393393

394-
- **Does not expect expression**
394+
- **Não espera expressão**
395395

396-
- **Usage:**
396+
- **Uso:**
397397

398398
Skip compilation for this element and all its children. You can use this for displaying raw mustache tags. Skipping large numbers of nodes with no directives on them can also speed up compilation.
399399

400-
- **Example:**
400+
- **Exemplo:**
401401

402402
```html
403403
<span v-pre>{{ this will not be compiled }}</span>
404404
```
405405

406406
## v-cloak
407407

408-
- **Does not expect expression**
408+
- **Não espera expressão**
409409

410-
- **Usage:**
410+
- **Uso:**
411411

412412
This directive will remain on the element until the associated component instance finishes compilation. Combined with CSS rules such as `[v-cloak] { display: none }`, this directive can be used to hide un-compiled mustache bindings until the component instance is ready.
413413

414-
- **Example:**
414+
- **Exemplo:**
415415

416416
```css
417417
[v-cloak] {
@@ -429,9 +429,9 @@
429429

430430
## v-once
431431

432-
- **Does not expect expression**
432+
- **Não espera expressão**
433433

434-
- **Details:**
434+
- **Detalhes:**
435435

436436
Render the element and component **once** only. On subsequent re-renders, the element/component and all its children will be treated as static content and skipped. This can be used to optimize update performance.
437437

@@ -451,18 +451,18 @@
451451
</ul>
452452
```
453453

454-
- **See also:**
454+
- **Ver também:**
455455
- [Data Binding Syntax - interpolations](../guide/template-syntax.html#text)
456456

457457
## v-is
458458

459459
> Note: this section only affects cases where Vue templates are directly written in the page's HTML.
460460
461-
- **Expects:** string literal
461+
- **Espera:** string literal
462462

463-
- **Limited to:** native HTML elements
463+
- **Limitado a:** native HTML elements
464464

465-
- **Usage:** When using in-DOM templates, the template is subject to native HTML parsing rules. Some HTML elements, such as `<ul>`, `<ol>`, `<table>` and `<select>` have restrictions on what elements can appear inside them, and some elements such as `<li>`, `<tr>`, and `<option>` can only appear inside certain other elements. As a workaround, we can use `v-is` directive on these elements:
465+
- **Uso:** When using in-DOM templates, the template is subject to native HTML parsing rules. Some HTML elements, such as `<ul>`, `<ol>`, `<table>` and `<select>` have restrictions on what elements can appear inside them, and some elements such as `<li>`, `<tr>`, and `<option>` can only appear inside certain other elements. As a workaround, we can use `v-is` directive on these elements:
466466

467467
```html
468468
<table>

0 commit comments

Comments
 (0)