You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
### Enable Service Principal Registration at Permission Scope Approval Time
43
-
When an SPFx solution requires access to APIs we allow administrators to pre-approve those permission scopes for the whole tenant in the "API Access" page in Tenant Admin.
44
43
45
-
However, previously we assumed and required that API to be already present in the tenant (either via an app principal or Service Principal in case of multi-tenant APIs) and, if that's not the case, we generated an error during the permissions scope approval.
44
+
When a SPFx solution requires access to APIs, we allow administrators to pre-approve those permission scopes for the whole tenant in the "API Access" page in Tenant Admin.
45
+
46
+
Previously it was assumed and required that API to be already present in the tenant (either via an app principal or Service Principal in case of multi-tenant APIs) and, if that's not the case, there was an error during the permissions scope approval.
46
47
47
48
Now developers are able to specify **optional** attributes `appId` and `replyUrl` in `webApiPermissionRequests` section of `package-solution.json`.
48
49
49
-
### New Action types for media - General Availability.
50
+
When these attributes are present, administartors are presented standard Azure AD app registration consent as part of the API approval process.
51
+
52
+
### New Action types for media - General Availability
53
+
54
+
Media upload action type is now generally available.
55
+
56
+
* [Media upload in Adaptive Card Extension](viva/get-started/actions/media-upload/MediaUploadDocumentation.md)
57
+
* [Tutorial - Create an Adaptive Card Extension with the select media action](viva/get-started/actions/media-upload/MediaUploadTutorial.md)
58
+
* [Explore Media Upload capability via property pane of card-designer card in Adaptive Card Extension](viva/get-started/actions/media-upload/MediaUploadPropertyPane.md)
50
59
51
60
```typescript
52
61
ISPFxAdaptiveCard.actions?: (
@@ -60,6 +69,7 @@ ISPFxAdaptiveCard.actions?: (
60
69
```
61
70
62
71
The ___location actions can be configured as shown below:
72
+
63
73
```typescript
64
74
actions: [
65
75
{
@@ -76,6 +86,7 @@ The ___location actions can be configured as shown below:
76
86
```
77
87
78
88
The SelectMedia action can be configured as shown below:
89
+
79
90
```typescript
80
91
actions: [
81
92
{
@@ -89,21 +100,19 @@ The SelectMedia action can be configured as shown below:
Based on received feedback, we "relaxed" applied ESLint rules to removed forced opinionated coding styles practices.
102
-
Also, all the rules are added directly to the `eslintrc.js` file for simpler further modifications.
110
+
111
+
Based on the received feedback from the ecosystem, we "relaxed" applied ESLint rules to removed forced opinionated coding styles practices. These rules are now also added directly to the `eslintrc.js` file for simpler further modifications in environment level.
When an ACE is loaded on a page we load both the card view and quick view. However, we don't need load the quick view until it is interacted with.
106
-
By defer loading a quick view, we will gain performance when loading an ACE.
114
+
115
+
When an ACE is loaded on a page we load both the card view and quick view. However, we don't need load the quick view until it is interacted with. By defer loading a quick view, we will gain performance when loading an ACE.
Copy file name to clipboardExpand all lines: docs/spfx/viva/get-started/actions/media-upload/MediaUploadDocumentation.md
+20-21Lines changed: 20 additions & 21 deletions
Original file line number
Diff line number
Diff line change
@@ -1,38 +1,37 @@
1
1
---
2
2
title: Media upload in Adaptive Card Extension
3
3
description: Media upload is a new action that the SharePoint Adaptive Card Extension framework supports, which enables third party developers to upload data content to sharepoint.
4
-
ms.date: 07/20/2022
4
+
ms.date: 08/09/2022
5
5
---
6
6
# Media upload in Adaptive Card Extension
7
7
8
8
> [!NOTE]
9
-
> The media upload capability in Adaptive Card Extension will be available in SPFx v1.15.
9
+
> The media upload capability in Adaptive Card Extension is available in SPFx v1.15.2.
10
10
>
11
11
> So make sure that you have installed it before proceeding further.
12
12
>
13
-
> For more information on installing the SPFx v1.15 Preview, see [SharePoint Framework v1.15 release notes](../../../../release-1.15.md).
13
+
> For more information on installing the SPFx v1.15.2, see [SharePoint Framework v1.15.2 release notes](../../../../release-1.15.2.md).
14
14
>
15
15
> This tutorial also assumes that you have already built a SharePoint Adaptive Card Extension.
16
16
>
17
17
> To learn how to create your first SharePoint Adaptive Card Extension, try out [this tutorial](../../../get-started/build-first-sharepoint-adaptive-card-extension.md).
18
18
19
+
## Action type for media upload
19
20
20
-
### Action type for media upload
21
+
### Select Media
21
22
22
-
#### Select Media
23
-
24
-
This allows users to upload media content via an ACE. The current size limitation is 1MB per image. A user may specify any image type to be uploaded. **Note**: _If an image type is not specified then an error indicating only images can be uploaded will show up._
23
+
Allows users to upload media content via an Adaptice Card Extension (ACE). The current size limitation is 1 MB per image. A user may specify any image type to be uploaded. **Note**: _If an image type isn't specified, then an error indicating only images can be uploaded will show up._
25
24
26
25
The ACE action for Select Media is: `VivaAction.SelectMedia`.
27
26
28
27
The parameters that it takes are as follows:
29
28
30
-
-`mediaType`: This is set to image by default as audio is still under works.
31
-
-`allowMultipleCapture`[OPTIONAL]: This enables multiple files to be added at once.
29
+
-`mediaType`: Currently set as image by default. Audio option will be supported in future.
30
+
-`allowMultipleCapture`[OPTIONAL]: Enables multiple files to be added at once.
32
31
- This is enabled by default.
33
-
-`maxSizePerFile`[OPTIONAL]: The limitation for the file size to be uploaded, suggested limitation is 1mb.
34
-
-`supportedFileFormats`[OPTIONAL]: This is a space delimited format on allowed types. If none are supplied then standard image files are used for type checking.
35
-
- Any file which is attempted to be upload that doesn't match the allowed type results in an error message stating: _This isn't a file type we support. You can only upload images._
32
+
-`maxSizePerFile`[OPTIONAL]: The limitation for the file size to be uploaded, suggested limitation is 1 MB.
33
+
-`supportedFileFormats`[OPTIONAL]: Space delimited format on allowed types. If none are supplied, then standard image files are used for type checking.
34
+
- Any file that is attempted to be upload that doesn't match the allowed type results in an error message stating: _This isn't a file type we support. You can only upload images._
36
35
37
36
```typescript
38
37
{
@@ -55,13 +54,13 @@ The parameters that it takes are as follows:
55
54
}
56
55
```
57
56
58
-
###Tutorial and Examples
57
+
## Tutorial and Examples
59
58
60
59
You can take a look at [this tutorial](./MediaUploadTutorial.md) which goes over a step by step guide on how to create a card with the available media upload action.
61
60
62
61
1.**Upload an image**
63
62
64
-
In your template json file add the following action:
63
+
In your template json file, add the following action:
65
64
66
65
```json
67
66
"actions": [
@@ -78,7 +77,7 @@ You can take a look at [this tutorial](./MediaUploadTutorial.md) which goes over
78
77
79
78
1. **Upload multiple images**
80
79
81
-
In your template json file add the following action:
80
+
In your template json file, add the following action:
82
81
83
82
```json
84
83
"actions": [
@@ -96,7 +95,7 @@ You can take a look at [this tutorial](./MediaUploadTutorial.md) which goes over
96
95
97
96
1. **Upload only JPG images**
98
97
99
-
In your template json file add the following action:
98
+
In your template json file, add the following action:
100
99
101
100
```json
102
101
"actions": [
@@ -114,7 +113,7 @@ You can take a look at [this tutorial](./MediaUploadTutorial.md) which goes over
114
113
115
114
1. **Upload allow only small images to be uploaded**
116
115
117
-
In your template json file add the following action:
116
+
In your template json file, add the following action:
118
117
119
118
```json
120
119
"actions": [
@@ -130,14 +129,14 @@ You can take a look at [this tutorial](./MediaUploadTutorial.md) which goes over
130
129
]
131
130
```
132
131
133
-
### Access media upload action via card-designer card's property pane
132
+
## Access media upload action via card-designer card's property pane
134
133
135
-
If you don't want to write up a new ACE but still wich to see the media upload in action, be sure to explore [this tutorial](./MediaUploadPropertyPane.md) which allows you to explore this through the property pane.
134
+
If you don't want to write up a new ACE but still want to see the media upload in action, be sure to explore [this tutorial](./MediaUploadPropertyPane.md) which allows you to explore this through the property pane.
136
135
137
136
> [!NOTE]
138
-
> The media upload action can be added on the card view, buttons ofthe card view, or inside the quick view itself.
137
+
> The media upload action can be added on the card view, buttons of the card view, or inside the quick view itself.
139
138
140
-
### Availability of media upload action
139
+
## Availability of media upload action
141
140
142
141
> [!NOTE]
143
142
> Currently this feature is not supported in teams mobile and will throw an error indicating that this.
Copy file name to clipboardExpand all lines: docs/spfx/viva/get-started/actions/media-upload/MediaUploadPropertyPane.md
+9-9Lines changed: 9 additions & 9 deletions
Original file line number
Diff line number
Diff line change
@@ -1,15 +1,15 @@
1
1
---
2
2
title: Explore Media Upload capability via property pane of card-designer card in Adaptive Card Extension
3
-
description: Media Upload is a new action that the SharePoint Adaptive Card Extension framework supports. In this tutorial we will see how we can explore this capability via the property pane of the card-designer card.
4
-
ms.date: 07/21/2022
3
+
description: Media Upload is a new action that the SharePoint Adaptive Card Extension framework supports. In this tutorial we'll see how we can explore this capability via the property pane of the card-designer card.
4
+
ms.date: 08/09/2022
5
5
ms.localizationpriority: high
6
6
---
7
7
8
8
# Explore Media Upload capability via property pane of card-designer card in Adaptive Card Extension.
9
9
10
-
In this tutorial we will see how we can explore this capability via the property pane of the card-designer card.
10
+
In this tutorial we'll see how we can explore this capability via the property pane of the card-designer card.
11
11
12
-
We will:
12
+
we'll:
13
13
14
14
- Update the card strings
15
15
- Introduce media upload actions on the card view, primary button, and secondary button.
@@ -20,31 +20,31 @@ Here, click on the '+' icon in the middle of the page, and add the `card-designe
20
20
21
21
Next, click the pencil icon adjacent to this card to open the property pane.
22
22
23
-
###Update the card strings
23
+
## Update the card strings
24
24
25
25
Here, first set the `Card size` to `Large`.
26
26
27
27
To provide descriptive labels, change `Title` to `Media Upload`, `Heading` to `Media Upload Demo` and `description` to `Demo Media Upload Actions`.
28
28
29
29

30
30
31
-
###Adding action on Card View
31
+
## Adding action on Card View
32
32
33
33
Under `Actions`, click the drop-down menu of `Card action` and select `Select media` option. By default **Images** is the only media type to be captured.
34
34
35
35
Set the expected file formats as **png** and **jpg**.
36
36
37
37

38
38
39
-
###Adding action on Primary button
39
+
## Adding action on Primary button
40
40
41
41
Next, for the `Primary Button`, set the `Title` to `Select single media` and from its action drop-down menu, select `Select Media`.
42
42
43
43
Ensure that `Allow Multiple Capture` is toggled off.
44
44
45
45

46
46
47
-
###Adding action on Secondary button
47
+
## Adding action on Secondary button
48
48
49
49
Change the size of the card from Medium to Large.
50
50
@@ -54,7 +54,7 @@ Finally, for the `Secondary Button`, set the `Title` to `Select multiple media`
54
54
55
55

56
56
57
-
###Try the Select Media action
57
+
## Try the Select Media action
58
58
59
59
Now close the property pane and click `Preview` from the top right hand corner of the page:
Copy file name to clipboardExpand all lines: docs/spfx/viva/get-started/actions/media-upload/MediaUploadTutorial.md
+9-9Lines changed: 9 additions & 9 deletions
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
---
2
-
title: Create an Adpative Card Extension with the select media action
3
-
description: Step by step guid on how to create an Adaptive Card Extension with the select media action.
2
+
title: Create an Adaptive Card Extension with the select media action
3
+
description: Step by step guide on how to create an Adaptive Card Extension with the select media action.
4
4
ms.date: 07/25/2022
5
5
ms.localizationpriority: high
6
6
---
@@ -43,21 +43,21 @@ When you use the gulp task **serve**, by default it will launch a browser with t
43
43
44
44
- Change the `enter-your-SharePoint-site` ___domain to the URL of your SharePoint tenant and site you want to use for testing. For example: `https://contoso.sharepoint.com/sites/devsite/_layouts/workbench.aspx`.
45
45
46
-
At this point, if you do `gulp serve`, then you will see the `MediaUpload` card:
46
+
At this point, if you do `gulp serve`, then you'll see the `MediaUpload` card:
47
47
48
48

49
49
50
50
## Add media upload action to your Adaptive Card Extension
51
51
52
-
At this point we have out of the box Adaptive Card Extension code. Now it's time to flare things up with selecting media from the Card and Quick views.
52
+
At this point, we have out of the box Adaptive Card Extension code. Now it's time to flare things up with selecting media from the Card and Quick views.
53
53
54
-
In the Card View, we will provide a button which will perform the following actions:
54
+
In the Card View, we'll provide a button that will perform the following actions:
55
55
56
56
- Upload an image file
57
57
58
58
### Update the labels that will show up on the card
59
59
60
-
Before we start adding the actions, let us first update the strings that you will see on the card.
60
+
Before we start adding the actions, let us first update the strings that you'll see on the card.
61
61
62
62
For this, locate and open the following file in your project: **./src/adaptiveCardExtensions/mediaUpload/loc/en-us.js**
63
63
@@ -89,7 +89,7 @@ to the `IMediaUploadAdaptiveCardExtensionStrings` interface.
89
89
90
90
### Add actions on the Card View
91
91
92
-
As mentioned earlier, on the Card View, we will add a button, which will allow the user to upload a png file when clicking the Card View.
92
+
As mentioned earlier, on the Card View, we'll add a button, which will allow the user to upload a png file when clicking the Card View.
93
93
94
94
Locate and open the following file in your project: **./src/adaptiveCardExtensions/mediaUpload/cardView/CardView.ts**
95
95
@@ -134,7 +134,7 @@ With the changes made so far, your Card View would look like:
134
134
135
135
### Add actions on the Quick View
136
136
137
-
In the Quick View, we will introduce buttons for 3 actions:
137
+
In the Quick View, we will introduce buttons for three actions:
138
138
139
139
- Upload a png file
140
140
- Upload a jpg file
@@ -192,7 +192,7 @@ After adding these actions, your Quick View would look like:
192
192
193
193
### Set up the state for our Adaptive Card Extension
194
194
195
-
So far we have created our Card View and Quick View. If you do a `gulp serve` at this point, then you will be able to perform the actions that were described above.
195
+
So far we have created our Card View and Quick View. If you do a `gulp serve` at this point, then you'll be able to perform the actions that were described above.
0 commit comments