Skip to content

Commit 72fea07

Browse files
[Excel PowerPoint] (content addins) add support for unified manifest (#4668)
* [Excel PowerPoint] (content addins) add support for unified manifest * Add note about preview status * two small fixes * Apply suggestions from code review Co-authored-by: Elizabeth Samuel <[email protected]> * add update to requirements property reference doc * add note about requirements child properties * clarify use of requirements property * requirements property removed * Update ms.date in content-add-ins.md --------- Co-authored-by: Elizabeth Samuel <[email protected]>
1 parent 1c8eda8 commit 72fea07

File tree

1 file changed

+37
-2
lines changed

1 file changed

+37
-2
lines changed

docs/design/content-add-ins.md

Lines changed: 37 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: Content Office Add-ins
33
description: Content add-ins are surfaces that can be embedded directly into Excel or PowerPoint documents that give users access to interface controls that run code to modify documents or display data from a data source.
4-
ms.date: 06/27/2024
4+
ms.date: 02/12/2025
55
ms.topic: overview
66
ms.localizationpriority: medium
77
---
@@ -41,11 +41,46 @@ For Mac, the personality menu measures 26x26 pixels, but floats 8 pixels in from
4141

4242
## Implementation
4343

44-
There are minor differences in the manifests between content add-ins and add-ins that use task panes.
44+
There are minor differences in the manifests between content add-ins and add-ins that use task panes. Open the tab for the type of manifest you're using.
45+
46+
# [Unified manifest for Microsoft 365](#tab/jsonmanifest)
47+
48+
> [!NOTE]
49+
> The unified manifest is available in Excel, PowerPoint, and Word as a developer preview. For Outlook, it's generally available and can be used in production add-ins.
50+
51+
Configure the manifest with the following steps.
52+
53+
1. Add a "contentRuntimes" child array to the extension object in the "extensions" array.
54+
1. Remove the "runtimes" property if it is present. The "runtimes" array is for task pane or mail add-ins. These cannot be combined with a content add-in.
55+
1. Add an anonymous content runtime object in the "contentRuntimes" array.
56+
1. Set the "id" property of the object to a descriptive name.
57+
1. Set the "code.page" object to the full URL of the custom content that you want to embed in the document.
58+
1. Optionally, set the "requestedWidth" and "requestedHeight" properties to a size between 32 and 1000 pixels. If these properties aren't used, the Office application determines the size.
59+
1. Optionally, set the "disableSnapshot" property to `true` to prevent Office from saving a snapshot of the content component with the document.
60+
61+
The following is an example of a "contentRuntimes" property.
62+
63+
```json
64+
"contentRuntimes": [
65+
{
66+
"id": "ContentRuntime",
67+
"code": {
68+
"page": "https://localhost:3000/content.html"
69+
},
70+
"requestedWidth": 100,
71+
"requestedHeight": 100,
72+
"disableSnapshot": true,
73+
}
74+
]
75+
```
76+
77+
# [XML Manifest](#tab/xmlmanifest)
4578

4679
- For the **\<[OfficeApp](/javascript/api/manifest/officeapp)\>** element, set the `xsi:type` attribute to `"ContentApp"`.
4780
- In the **\<[DefaultSettings](/javascript/api/manifest/defaultsettings)\>** element, add the **\<[RequestedHeight](/javascript/api/manifest/requestedheight)\>** and **\<[RequestedWidth](/javascript/api/manifest/requestedwidth)\>** elements.
4881

82+
---
83+
4984
For a sample that implements a content add-in, see [Excel Content Add-in Humongous Insurance](https://github.com/OfficeDev/Excel-Content-Add-in-Humongous-Insurance) on GitHub.
5085

5186
To create your own content add-in, see the [Excel content add-in quick start](../quickstarts/excel-quickstart-content.md) and [PowerPoint content add-in quick start](../quickstarts/powerpoint-quickstart-content.md).

0 commit comments

Comments
 (0)