[ADF-3425] Minor edits to doc files (#3667)

This commit is contained in:
Andy Stark
2018-08-07 17:36:15 +01:00
committed by Eugenio Romano
parent 18a21a59a5
commit cb7a6b0a7a
4 changed files with 39 additions and 31 deletions

View File

@@ -1,7 +1,7 @@
---
Added: v2.1.0
Status: Active
Last reviewed: 2018-04-16
Last reviewed: 2018-08-07
---
# Content Metadata Card component
@@ -124,7 +124,7 @@ A final example shows the same process applied to a custom preset called "kitten
### Layout oriented config
You can also go beyond the aspect oriented configuration if you need to configure the groups and properties in a more detailed way. With this type of configuration any property of any aspect/type
can be "cherry picked" and grouped into an accordion drawer, along wwith a translatable title
can be "cherry picked" and grouped into an accordion drawer, along with a translatable title
defined in the preset configuration.
#### Basic elements

View File

@@ -1,7 +1,7 @@
---
Added: v2.0.0
Status: Active
Last reviewed: 2018-05-04
Last reviewed: 2018-08-07
---
# Upload Drag Area Component
@@ -53,19 +53,21 @@ export class AppComponent {
| error | [`EventEmitter`](https://angular.io/api/core/EventEmitter)`<Object>` | Emitted when an error occurs. |
| success | [`EventEmitter`](https://angular.io/api/core/EventEmitter)`<Object>` | Emitted when the file is uploaded successfully. |
## Intercepting uploads
## Details
You can intercept the upload process by utilizing the `beginUpload` event.
### Intercepting uploads
You can intercept the upload process using the `beginUpload` event.
The event has a type of [`UploadFilesEvent`](../../lib/content-services/upload/components/upload-files.event.ts) and provides the following APIs:
- **files**: get access to the [`FileInfo`](../../lib/core/utils/file-utils.ts) objects that are prepared for the upload
- **pauseUpload**: pause the upload and perform additional tasks, like showing the confirmation dialog
- **resumeUpload**: resume the upload process
- **files**: accesses the [`FileInfo`](../../lib/core/utils/file-utils.ts) objects that are prepared for the upload
- **pauseUpload**: pauses the upload and performs additional tasks, like showing the confirmation dialog
- **resumeUpload**: resumes the upload process
## Example
### Example
Wire the `beginUpload` event at the template level
Wire the `beginUpload` event at the template level:
```html
<adf-upload-drag-area (beginUpload)="onBeginUpload($event)" ...>
@@ -73,7 +75,7 @@ Wire the `beginUpload` event at the template level
</adf-upload-drag-area>
```
Create the `onBeginUpload` handler that invokes a confirmation dialog
Create the `onBeginUpload` handler that invokes a confirmation dialog:
```ts
import { UploadFilesEvent, ConfirmDialogComponent } from '@alfresco/adf-content-services';
@@ -106,5 +108,5 @@ export class MyComponent {
}
```
The example above is going to raise confirmation dialog every time a user uploads more than 1 file.
That can be either 2 or more files, or a folder with multiple entries.
The example above shows a confirmation dialog every time a user uploads more than 1 file.
This could be either a selection of 2 or more files, or a folder with multiple entries.