Skip to content

Commit c4bb9d1

Browse files
committed
Reformatted code to follow suit with 4 spaces on other docs
1 parent ae7c22f commit c4bb9d1

File tree

1 file changed

+70
-70
lines changed

1 file changed

+70
-70
lines changed

docs/spfx/viva/get-started/actions/media-upload/MediaUploadDocumentation.md

Lines changed: 70 additions & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -36,22 +36,22 @@ The parameters that it takes are as follows:
3636

3737
```typescript
3838
{
39-
/**
40-
* Specify the specific media type that should be selected
41-
*/
42-
mediaType: MediaType;
43-
/**
44-
* Allow multiple images to be selected.
45-
*/
46-
allowMultipleCapture?: boolean;
47-
/**
48-
* Max file size that can be uploaded.
49-
*/
50-
maxSizePerFile?: number;
51-
/**
52-
* File formats supported for upload.
53-
*/
54-
supportedFileFormats?: string[];
39+
/**
40+
* Specify the specific media type that should be selected
41+
*/
42+
mediaType: MediaType;
43+
/**
44+
* Allow multiple images to be selected.
45+
*/
46+
allowMultipleCapture?: boolean;
47+
/**
48+
* Max file size that can be uploaded.
49+
*/
50+
maxSizePerFile?: number;
51+
/**
52+
* File formats supported for upload.
53+
*/
54+
supportedFileFormats?: string[];
5555
}
5656
```
5757

@@ -63,72 +63,72 @@ You can take a look at [this tutorial](./MediaUploadTutorial.md) which goes over
6363

6464
In your template json file add the following action:
6565

66-
```json
67-
"actions": [
68-
{
69-
"type": "VivaAction.SelectMedia",
70-
"id": "Select Media",
71-
"title": "Upload Image",
72-
"parameters": {
73-
"mediaType": "MediaType.Image"
74-
}
75-
}
76-
]
77-
```
66+
```json
67+
"actions": [
68+
{
69+
"type": "VivaAction.SelectMedia",
70+
"id": "Select Media",
71+
"title": "Upload Image",
72+
"parameters": {
73+
"mediaType": "MediaType.Image"
74+
}
75+
}
76+
]
77+
```
7878

7979
1. **Upload multiple images**
8080

81-
In your template json file add the following action:
81+
In your template json file add the following action:
8282

83-
```json
84-
"actions": [
85-
{
86-
"type": "VivaAction.SelectMedia",
87-
"id": "Select Media",
88-
"title": "Upload Image",
89-
"parameters": {
90-
"mediaType": "MediaType.Image",
91-
"allowMultipleCapture": true
92-
}
93-
}
94-
]
95-
```
83+
```json
84+
"actions": [
85+
{
86+
"type": "VivaAction.SelectMedia",
87+
"id": "Select Media",
88+
"title": "Upload Image",
89+
"parameters": {
90+
"mediaType": "MediaType.Image",
91+
"allowMultipleCapture": true
92+
}
93+
}
94+
]
95+
```
9696

9797
1. **Upload only JPG images**
9898

99-
In your template json file add the following action:
99+
In your template json file add the following action:
100100

101-
```json
102-
"actions": [
103-
{
104-
"type": "VivaAction.SelectMedia",
105-
"id": "Select Media",
106-
"title": "Upload Image",
107-
"parameters": {
108-
"mediaType": "MediaType.Image",
109-
"supportedFileFormats": "jpg"
110-
}
111-
}
112-
]
113-
```
101+
```json
102+
"actions": [
103+
{
104+
"type": "VivaAction.SelectMedia",
105+
"id": "Select Media",
106+
"title": "Upload Image",
107+
"parameters": {
108+
"mediaType": "MediaType.Image",
109+
"supportedFileFormats": "jpg"
110+
}
111+
}
112+
]
113+
```
114114

115115
1. **Upload allow only small images to be uploaded**
116116

117-
In your template json file add the following action:
117+
In your template json file add the following action:
118118

119-
```json
120-
"actions": [
121-
{
122-
"type": "VivaAction.SelectMedia",
123-
"id": "Select Media",
124-
"title": "Upload Image",
125-
"parameters": {
126-
"mediaType": "MediaType.Image",
127-
"supportedFilemaxSizePerFileFormats": 1000
128-
}
129-
}
130-
]
131-
```
119+
```json
120+
"actions": [
121+
{
122+
"type": "VivaAction.SelectMedia",
123+
"id": "Select Media",
124+
"title": "Upload Image",
125+
"parameters": {
126+
"mediaType": "MediaType.Image",
127+
"supportedFilemaxSizePerFileFormats": 1000
128+
}
129+
}
130+
]
131+
```
132132

133133
### Access media upload action via card-designer card's property pane
134134

0 commit comments

Comments
 (0)