@esri/hub-common 14.177.1 → 14.179.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/esm/content/HubContent.js +5 -0
- package/dist/esm/content/HubContent.js.map +1 -1
- package/dist/esm/content/_internal/ContentSchema.js +5 -0
- package/dist/esm/content/_internal/ContentSchema.js.map +1 -1
- package/dist/esm/content/_internal/ContentUiSchemaSettings.js +5 -23
- package/dist/esm/content/_internal/ContentUiSchemaSettings.js.map +1 -1
- package/dist/esm/content/_internal/computeProps.js +1 -0
- package/dist/esm/content/_internal/computeProps.js.map +1 -1
- package/dist/esm/content/_internal/getDownloadsSection.js +135 -0
- package/dist/esm/content/_internal/getDownloadsSection.js.map +1 -0
- package/dist/esm/content/_internal/shouldShowDownloadsConfiguration.js +23 -0
- package/dist/esm/content/_internal/shouldShowDownloadsConfiguration.js.map +1 -0
- package/dist/esm/content/edit.js +40 -3
- package/dist/esm/content/edit.js.map +1 -1
- package/dist/esm/downloads/_internal/additional-resources/utils.js +23 -0
- package/dist/esm/downloads/_internal/additional-resources/utils.js.map +1 -0
- package/dist/esm/downloads/_internal/getDownloadConfigurationDisplayFormats.js +75 -0
- package/dist/esm/downloads/_internal/getDownloadConfigurationDisplayFormats.js.map +1 -0
- package/dist/esm/downloads/_internal/getDownloadFlow.js +26 -0
- package/dist/esm/downloads/_internal/getDownloadFlow.js.map +1 -0
- package/dist/esm/downloads/_internal/getDownloadFormatsByFlow.js +28 -0
- package/dist/esm/downloads/_internal/getDownloadFormatsByFlow.js.map +1 -0
- package/dist/esm/downloads/fetchDownloadFile.js +20 -0
- package/dist/esm/downloads/fetchDownloadFile.js.map +1 -1
- package/dist/esm/downloads/fetchDownloadFormats.js +4 -0
- package/dist/esm/downloads/fetchDownloadFormats.js.map +1 -1
- package/dist/esm/downloads/getDownloadConfiguration.js +52 -0
- package/dist/esm/downloads/getDownloadConfiguration.js.map +1 -0
- package/dist/esm/downloads/getDownloadFormats.js +59 -0
- package/dist/esm/downloads/getDownloadFormats.js.map +1 -0
- package/dist/esm/downloads/index.js +2 -0
- package/dist/esm/downloads/index.js.map +1 -1
- package/dist/esm/events/HubEvent.js +2 -2
- package/dist/esm/events/HubEvent.js.map +1 -1
- package/dist/esm/events/api/orval/api/orval-events.js.map +1 -1
- package/dist/esm/events/edit.js +6 -1
- package/dist/esm/events/edit.js.map +1 -1
- package/dist/node/content/HubContent.js +5 -0
- package/dist/node/content/HubContent.js.map +1 -1
- package/dist/node/content/_internal/ContentSchema.js +5 -0
- package/dist/node/content/_internal/ContentSchema.js.map +1 -1
- package/dist/node/content/_internal/ContentUiSchemaSettings.js +5 -23
- package/dist/node/content/_internal/ContentUiSchemaSettings.js.map +1 -1
- package/dist/node/content/_internal/computeProps.js +1 -0
- package/dist/node/content/_internal/computeProps.js.map +1 -1
- package/dist/node/content/_internal/getDownloadsSection.js +139 -0
- package/dist/node/content/_internal/getDownloadsSection.js.map +1 -0
- package/dist/node/content/_internal/shouldShowDownloadsConfiguration.js +27 -0
- package/dist/node/content/_internal/shouldShowDownloadsConfiguration.js.map +1 -0
- package/dist/node/content/edit.js +39 -2
- package/dist/node/content/edit.js.map +1 -1
- package/dist/node/downloads/_internal/additional-resources/utils.js +28 -0
- package/dist/node/downloads/_internal/additional-resources/utils.js.map +1 -0
- package/dist/node/downloads/_internal/getDownloadConfigurationDisplayFormats.js +79 -0
- package/dist/node/downloads/_internal/getDownloadConfigurationDisplayFormats.js.map +1 -0
- package/dist/node/downloads/_internal/getDownloadFlow.js +30 -0
- package/dist/node/downloads/_internal/getDownloadFlow.js.map +1 -0
- package/dist/node/downloads/_internal/getDownloadFormatsByFlow.js +32 -0
- package/dist/node/downloads/_internal/getDownloadFormatsByFlow.js.map +1 -0
- package/dist/node/downloads/fetchDownloadFile.js +20 -0
- package/dist/node/downloads/fetchDownloadFile.js.map +1 -1
- package/dist/node/downloads/fetchDownloadFormats.js +4 -0
- package/dist/node/downloads/fetchDownloadFormats.js.map +1 -1
- package/dist/node/downloads/getDownloadConfiguration.js +56 -0
- package/dist/node/downloads/getDownloadConfiguration.js.map +1 -0
- package/dist/node/downloads/getDownloadFormats.js +63 -0
- package/dist/node/downloads/getDownloadFormats.js.map +1 -0
- package/dist/node/downloads/index.js +2 -0
- package/dist/node/downloads/index.js.map +1 -1
- package/dist/node/events/HubEvent.js +2 -2
- package/dist/node/events/HubEvent.js.map +1 -1
- package/dist/node/events/api/orval/api/orval-events.js.map +1 -1
- package/dist/node/events/edit.js +7 -1
- package/dist/node/events/edit.js.map +1 -1
- package/dist/types/content/_internal/getDownloadsSection.d.ts +13 -0
- package/dist/types/content/_internal/shouldShowDownloadsConfiguration.d.ts +13 -0
- package/dist/types/core/types/IHubEditableContent.d.ts +57 -1
- package/dist/types/downloads/_internal/additional-resources/utils.d.ts +19 -0
- package/dist/types/downloads/_internal/getDownloadConfigurationDisplayFormats.d.ts +10 -0
- package/dist/types/downloads/_internal/getDownloadFlow.d.ts +11 -0
- package/dist/types/downloads/_internal/getDownloadFormatsByFlow.d.ts +11 -0
- package/dist/types/downloads/fetchDownloadFormats.d.ts +2 -0
- package/dist/types/downloads/getDownloadConfiguration.d.ts +11 -0
- package/dist/types/downloads/getDownloadFormats.d.ts +9 -0
- package/dist/types/downloads/index.d.ts +2 -0
- package/dist/types/events/api/orval/api/orval-events.d.ts +9 -1
- package/dist/types/events/edit.d.ts +1 -0
- package/package.json +1 -1
|
@@ -52,6 +52,49 @@ export interface IHubEditableContent extends IHubItemEntity, IWithSlug, IWithPer
|
|
|
52
52
|
* This is a discriminated union of the possible additional props.
|
|
53
53
|
*/
|
|
54
54
|
export declare type IExtendedProps = IContentExtendedProps | IServiceExtendedProps;
|
|
55
|
+
/**
|
|
56
|
+
* Represents the download process that the configuration was created for
|
|
57
|
+
*/
|
|
58
|
+
export declare type DownloadFlowType = "createReplica" | "paging" | "exportImage";
|
|
59
|
+
/**
|
|
60
|
+
* Represents the storage object for configuring a single download format
|
|
61
|
+
* TODO: Should this be IDownloadFormatConfigurationStorage?
|
|
62
|
+
*/
|
|
63
|
+
export interface IDownloadFormatConfiguration {
|
|
64
|
+
/**
|
|
65
|
+
* Key that identifies the download format.
|
|
66
|
+
*/
|
|
67
|
+
key: string;
|
|
68
|
+
/**
|
|
69
|
+
* Whether the download format should be hidden from the UI
|
|
70
|
+
*/
|
|
71
|
+
hidden?: boolean;
|
|
72
|
+
}
|
|
73
|
+
/**
|
|
74
|
+
* Represents the display object for configuring a single download format.
|
|
75
|
+
* To be used in editing contexts rather than user-facing contexts.
|
|
76
|
+
*/
|
|
77
|
+
export interface IDownloadFormatConfigurationDisplay extends IDownloadFormatConfiguration {
|
|
78
|
+
/**
|
|
79
|
+
* Translated label to display for the download format
|
|
80
|
+
*/
|
|
81
|
+
label: string;
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* Represents the configurations for downloading an item
|
|
85
|
+
*/
|
|
86
|
+
export interface IEntityDownloadConfiguration {
|
|
87
|
+
/**
|
|
88
|
+
* Indicates the download flow that the configuration was created for
|
|
89
|
+
* (i.e., the download process that would have been used at the time of configuration)
|
|
90
|
+
*/
|
|
91
|
+
flowType: DownloadFlowType;
|
|
92
|
+
/**
|
|
93
|
+
* Configuration for the download formats that are available for the item.
|
|
94
|
+
* Saved in the order that they should be displayed in the UI.
|
|
95
|
+
*/
|
|
96
|
+
formats: IDownloadFormatConfiguration[];
|
|
97
|
+
}
|
|
55
98
|
/**
|
|
56
99
|
* Optional enrichments that are common to all content types
|
|
57
100
|
*/
|
|
@@ -68,6 +111,10 @@ export interface IBaseExtendedProps {
|
|
|
68
111
|
* Convenience links to additional resources specified in the formal item metadata
|
|
69
112
|
*/
|
|
70
113
|
additionalResources?: IHubAdditionalResource[];
|
|
114
|
+
/**
|
|
115
|
+
* Download configuration for the item
|
|
116
|
+
*/
|
|
117
|
+
downloads?: IEntityDownloadConfiguration;
|
|
71
118
|
}
|
|
72
119
|
/**
|
|
73
120
|
* Enrichments specific to items that are not backed by a service
|
|
@@ -104,4 +151,13 @@ export interface IServiceExtendedProps extends IBaseExtendedProps {
|
|
|
104
151
|
*/
|
|
105
152
|
serverExtractFormats?: string[];
|
|
106
153
|
}
|
|
107
|
-
export declare type IHubContentEditor = IHubItemEntityEditor<IHubEditableContent> & {
|
|
154
|
+
export declare type IHubContentEditor = IHubItemEntityEditor<IHubEditableContent> & {
|
|
155
|
+
/**
|
|
156
|
+
* Download formats that should be rendered in the editing UI.
|
|
157
|
+
*
|
|
158
|
+
* NOTE: The formats present in this array may or may not be actually accessible.
|
|
159
|
+
* Product has asked that in certain cases, we display formats that _could_ be available
|
|
160
|
+
* if the user were to make the necessary changes to the item / service.
|
|
161
|
+
*/
|
|
162
|
+
downloadFormats?: IDownloadFormatConfigurationDisplay[];
|
|
163
|
+
};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { IDownloadFormatConfiguration } from "../../../core/types/IHubEditableContent";
|
|
2
|
+
/**
|
|
3
|
+
* @private
|
|
4
|
+
* Determines if the given download format configuration is for
|
|
5
|
+
* an additional resource.
|
|
6
|
+
*
|
|
7
|
+
* @param config IDownloadFormatConfiguration
|
|
8
|
+
* @returns boolean
|
|
9
|
+
*/
|
|
10
|
+
export declare function isAdditionalResourceConfiguration(config: IDownloadFormatConfiguration): boolean;
|
|
11
|
+
/**
|
|
12
|
+
* @private
|
|
13
|
+
* Get's the index of the additional resource from the given
|
|
14
|
+
* download format configuration.
|
|
15
|
+
*
|
|
16
|
+
* @param config IDownloadFormatConfiguration
|
|
17
|
+
* @returns number - The index of the additional resource
|
|
18
|
+
*/
|
|
19
|
+
export declare function getAdditionalResourceIndex(config: IDownloadFormatConfiguration): number;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { IDownloadFormatConfigurationDisplay, IHubEditableContent } from "../../core/types/IHubEditableContent";
|
|
2
|
+
/**
|
|
3
|
+
* @private
|
|
4
|
+
* Returns configuration objects for each download format that should be displayed
|
|
5
|
+
* in the editing experience of a content entity. This function should not be used
|
|
6
|
+
* to calculate the download formats that should be present on the live UI.
|
|
7
|
+
* @param entity entity to get download format configurations for
|
|
8
|
+
* @returns download format configurations to display
|
|
9
|
+
*/
|
|
10
|
+
export declare function getDownloadConfigurationDisplayFormats(entity: IHubEditableContent): IDownloadFormatConfigurationDisplay[];
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { DownloadFlowType, IHubEditableContent } from "../../core";
|
|
2
|
+
/**
|
|
3
|
+
* @private
|
|
4
|
+
* Determines the download flow that will be used for the current entity.
|
|
5
|
+
* If the entity cannot be downloaded, returns null.
|
|
6
|
+
*
|
|
7
|
+
* @param entity the entity to get the download flow for
|
|
8
|
+
* @param isEnterprise whether the the download will be executed in an enterprise environment
|
|
9
|
+
* @returns the download flow that will be used for the current entity
|
|
10
|
+
*/
|
|
11
|
+
export declare function getDownloadFlow(entity: IHubEditableContent, isEnterprise?: boolean): DownloadFlowType;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { DownloadFlowType, IHubEditableContent } from "../../core/types/IHubEditableContent";
|
|
2
|
+
import { IDynamicDownloadFormat } from "../types";
|
|
3
|
+
/**
|
|
4
|
+
* @private
|
|
5
|
+
* Get the download formats for a given download flow and entity.
|
|
6
|
+
*
|
|
7
|
+
* @param downloadFlow DownloadFlowType
|
|
8
|
+
* @param entity IHubEditableContent
|
|
9
|
+
* @returns IDynamicDownloadFormat[]
|
|
10
|
+
*/
|
|
11
|
+
export declare function getDownloadFormatsByFlow(downloadFlow: DownloadFlowType, entity: IHubEditableContent): IDynamicDownloadFormat[];
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { IDownloadFormat, IFetchDownloadFormatsOptions } from "./types";
|
|
2
2
|
/**
|
|
3
|
+
* DEPRECATED: This will be removed in the next breaking version. Use "getDownloadFormats()" instead.
|
|
4
|
+
*
|
|
3
5
|
* Fetches download formats for the given entity. Also folds in any additional resources defined on the entity.
|
|
4
6
|
* @param options options to refine / filter the results of the fetchDownloadFormats operation
|
|
5
7
|
* @returns a promise that resolves with the download formats
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { IEntityDownloadConfiguration, IHubEditableContent } from "../core/types/IHubEditableContent";
|
|
2
|
+
/**
|
|
3
|
+
* Returns the download configuration for an entity at this moment in time.
|
|
4
|
+
*
|
|
5
|
+
* If no configuration exists, a default configuration is returned based on the entity's current download flow.
|
|
6
|
+
* If a configuration exists but is no longer valid, the default configuration will also be returned.
|
|
7
|
+
*
|
|
8
|
+
* @param entity entity to get download configuration for
|
|
9
|
+
* @returns the current download configuration for the entity
|
|
10
|
+
*/
|
|
11
|
+
export declare function getDownloadConfiguration(entity: IHubEditableContent): IEntityDownloadConfiguration;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { IDownloadFormat, IFetchDownloadFormatsOptions } from "./types";
|
|
2
|
+
/**
|
|
3
|
+
* Gets available download formats / additional resources for the given entity in the order they have been configured.
|
|
4
|
+
* If a format has been configured to be hidden, it will not be included in the results.
|
|
5
|
+
*
|
|
6
|
+
* @param options options to refine / filter the results of the fetchDownloadFormats operation
|
|
7
|
+
* @returns The available download formats and additional resources
|
|
8
|
+
*/
|
|
9
|
+
export declare function getDownloadFormats(options: IFetchDownloadFormatsOptions): IDownloadFormat[];
|
|
@@ -212,6 +212,14 @@ export declare type GetEventsParams = {
|
|
|
212
212
|
* Comma separated string list of relation fields to include in response. Example: associations,creator,location,onlineMeeting,registrations
|
|
213
213
|
*/
|
|
214
214
|
include?: string;
|
|
215
|
+
/**
|
|
216
|
+
* Comma separated string list of edit groupIds that event is not shared to
|
|
217
|
+
*/
|
|
218
|
+
withoutEditGroups?: string;
|
|
219
|
+
/**
|
|
220
|
+
* Comma separated string list of read groupIds that event is not shared to
|
|
221
|
+
*/
|
|
222
|
+
withoutReadGroups?: string;
|
|
215
223
|
/**
|
|
216
224
|
* the max amount of events to return
|
|
217
225
|
*/
|
|
@@ -241,7 +249,7 @@ export declare type GetEventsParams = {
|
|
|
241
249
|
*/
|
|
242
250
|
startDateTimeBefore?: string;
|
|
243
251
|
/**
|
|
244
|
-
* comma separated string list of event statuses. Example:
|
|
252
|
+
* comma separated string list of event statuses. Example: PLANNED,CANCELED,REMOVED
|
|
245
253
|
*/
|
|
246
254
|
status?: string;
|
|
247
255
|
/**
|
|
@@ -25,6 +25,7 @@ export declare function createHubEvent(partialEvent: Partial<IHubEvent>, request
|
|
|
25
25
|
* @returns promise that resolves a IHubEvent
|
|
26
26
|
*/
|
|
27
27
|
export declare function updateHubEvent(partialEvent: Partial<IHubEvent>, requestOptions: IHubRequestOptions): Promise<IHubEvent>;
|
|
28
|
+
export declare function deleteHubEvent(id: string, requestOptions: IHubRequestOptions): Promise<void>;
|
|
28
29
|
/**
|
|
29
30
|
* @private
|
|
30
31
|
* Create an Event registration
|