[ACS-6620] Use extensions instead of content key for viewer extensions (#3610)

This commit is contained in:
MichalKinas 2024-01-25 23:30:17 +01:00 committed by GitHub
parent c3a51f09aa
commit 3f04f05da5
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 12 additions and 12 deletions

View File

@ -33,7 +33,7 @@ All the customizations are stored in the `features` section of the configuration
"viewer": { "viewer": {
"toolbarActions:": [], "toolbarActions:": [],
"openWith": [], "openWith": [],
"content": [] "extensions": []
}, },
"sidebar": [], "sidebar": [],
"content-metadata-presets": [] "content-metadata-presets": []
@ -397,7 +397,7 @@ declared in the `rules` section:
Viewer component in ACA supports the following extension points: Viewer component in ACA supports the following extension points:
- Content Viewers - Viewer extensions
- Toolbar actions - Toolbar actions
- `More` toolbar actions - `More` toolbar actions
- `Open With` actions - `Open With` actions
@ -419,9 +419,9 @@ Viewer component in ACA supports the following extension points:
} }
``` ```
### Content View ### Viewer extensions
You can provide custom components that render a particular type of the content based on extensions. You can provide custom components that render a particular type of the content based on file extensions.
```json ```json
{ {
@ -431,7 +431,7 @@ You can provide custom components that render a particular type of the content b
"features": { "features": {
"viewer": { "viewer": {
"content": [ "extensions": [
{ {
"id": "app.viewer.pdf", "id": "app.viewer.pdf",
"fileExtension": "pdf", "fileExtension": "pdf",

View File

@ -33,7 +33,7 @@ ACA は、次の拡張ポイントのセットをサポートします:
"viewer": { "viewer": {
"toolbarActions:": [], "toolbarActions:": [],
"openWith": [], "openWith": [],
"content": [] "extensions": []
}, },
"sidebar": [], "sidebar": [],
"content-metadata-presets": [] "content-metadata-presets": []
@ -376,7 +376,7 @@ ACA の Viewer コンポーネントは、次の拡張ポイントをサポー
"features": { "features": {
"viewer": { "viewer": {
"content": [], "extensions": [],
"toolbarActions:": [], "toolbarActions:": [],
"openWith": [] "openWith": []
} }
@ -396,7 +396,7 @@ ACA の Viewer コンポーネントは、次の拡張ポイントをサポー
"features": { "features": {
"viewer": { "viewer": {
"content": [ "extensions": [
{ {
"id": "app.viewer.pdf", "id": "app.viewer.pdf",
"fileExtension": "pdf", "fileExtension": "pdf",

View File

@ -72,7 +72,7 @@ You also need to provide in your `app.extension.json` its details:
"$description": "my viewer plugin", "$description": "my viewer plugin",
"features": { "features": {
"viewer": { "viewer": {
"content": [ "extensions": [
{ {
"id": "my.custom.viewer", "id": "my.custom.viewer",
"fileExtension": ["png", "jpg"], "fileExtension": ["png", "jpg"],
@ -93,7 +93,7 @@ You can also use the `*` wildcard symbol to make your custom viewer implementati
"$description": "my viewer plugin", "$description": "my viewer plugin",
"features": { "features": {
"viewer": { "viewer": {
"content": [ "extensions": [
{ {
"id": "my.custom.viewer", "id": "my.custom.viewer",
"fileExtension": "*", "fileExtension": "*",

View File

@ -807,7 +807,7 @@
"items": { "$ref": "#/definitions/contentActionRef" }, "items": { "$ref": "#/definitions/contentActionRef" },
"minItems": 1 "minItems": 1
}, },
"content": { "extensions": {
"description": "Viewer content extensions", "description": "Viewer content extensions",
"type": "array", "type": "array",
"items": { "$ref": "#/definitions/viewerExtensionRef" }, "items": { "$ref": "#/definitions/viewerExtensionRef" },

View File

@ -1204,7 +1204,7 @@
} }
] ]
}, },
"content": [ "extensions": [
{ {
"id": "app.viewer.pdf", "id": "app.viewer.pdf",
"disabled": true, "disabled": true,