@fluidframework/odsp-driver 2.53.1 → 2.61.0-355054
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/.mocharc.cjs +1 -2
- package/CHANGELOG.md +4 -0
- package/README.md +19 -0
- package/api-report/{odsp-driver.legacy.alpha.api.md → odsp-driver.legacy.beta.api.md} +31 -31
- package/dist/checkUrl.d.ts +1 -1
- package/dist/checkUrl.js +1 -1
- package/dist/checkUrl.js.map +1 -1
- package/dist/constants.d.ts +2 -2
- package/dist/constants.js +2 -2
- package/dist/constants.js.map +1 -1
- package/dist/contractsPublic.d.ts +1 -1
- package/dist/contractsPublic.js.map +1 -1
- package/dist/createOdspCreateContainerRequest.d.ts +1 -1
- package/dist/createOdspCreateContainerRequest.js +1 -1
- package/dist/createOdspCreateContainerRequest.js.map +1 -1
- package/dist/createOdspUrl.d.ts +1 -1
- package/dist/createOdspUrl.js +1 -1
- package/dist/createOdspUrl.js.map +1 -1
- package/dist/epochTracker.d.ts +4 -4
- package/dist/epochTracker.js +1 -1
- package/dist/epochTracker.js.map +1 -1
- package/dist/fetchSnapshot.d.ts +1 -1
- package/dist/fetchSnapshot.js +1 -1
- package/dist/fetchSnapshot.js.map +1 -1
- package/dist/getFileLink.js +1 -1
- package/dist/getFileLink.js.map +1 -1
- package/dist/legacy.d.ts +2 -1
- package/dist/odspCache.d.ts +4 -4
- package/dist/odspCache.js.map +1 -1
- package/dist/odspDocumentService.d.ts.map +1 -1
- package/dist/odspDocumentService.js +4 -4
- package/dist/odspDocumentService.js.map +1 -1
- package/dist/odspDocumentServiceFactory.d.ts +2 -2
- package/dist/odspDocumentServiceFactory.js +2 -2
- package/dist/odspDocumentServiceFactory.js.map +1 -1
- package/dist/odspDocumentServiceFactoryCore.d.ts +1 -1
- package/dist/odspDocumentServiceFactoryCore.js +1 -1
- package/dist/odspDocumentServiceFactoryCore.js.map +1 -1
- package/dist/odspDriverUrlResolver.d.ts +1 -1
- package/dist/odspDriverUrlResolver.js +1 -1
- package/dist/odspDriverUrlResolver.js.map +1 -1
- package/dist/odspDriverUrlResolverForShareLink.d.ts +2 -2
- package/dist/odspDriverUrlResolverForShareLink.js +1 -1
- package/dist/odspDriverUrlResolverForShareLink.js.map +1 -1
- package/dist/odspFluidFileLink.d.ts +4 -4
- package/dist/odspFluidFileLink.js +4 -4
- package/dist/odspFluidFileLink.js.map +1 -1
- package/dist/odspPublicUtils.d.ts +2 -2
- package/dist/odspPublicUtils.js +1 -1
- package/dist/odspPublicUtils.js.map +1 -1
- package/dist/odspUtils.d.ts +2 -2
- package/dist/odspUtils.js +1 -1
- package/dist/odspUtils.js.map +1 -1
- package/dist/packageVersion.d.ts +1 -1
- package/dist/packageVersion.d.ts.map +1 -1
- package/dist/packageVersion.js +1 -1
- package/dist/packageVersion.js.map +1 -1
- package/dist/prefetchLatestSnapshot.d.ts +1 -1
- package/dist/prefetchLatestSnapshot.js +1 -1
- package/dist/prefetchLatestSnapshot.js.map +1 -1
- package/internal.d.ts +1 -1
- package/legacy.d.ts +1 -1
- package/lib/checkUrl.d.ts +1 -1
- package/lib/checkUrl.js +1 -1
- package/lib/checkUrl.js.map +1 -1
- package/lib/constants.d.ts +2 -2
- package/lib/constants.js +2 -2
- package/lib/constants.js.map +1 -1
- package/lib/contractsPublic.d.ts +1 -1
- package/lib/contractsPublic.js.map +1 -1
- package/lib/createOdspCreateContainerRequest.d.ts +1 -1
- package/lib/createOdspCreateContainerRequest.js +1 -1
- package/lib/createOdspCreateContainerRequest.js.map +1 -1
- package/lib/createOdspUrl.d.ts +1 -1
- package/lib/createOdspUrl.js +1 -1
- package/lib/createOdspUrl.js.map +1 -1
- package/lib/epochTracker.d.ts +4 -4
- package/lib/epochTracker.js +1 -1
- package/lib/epochTracker.js.map +1 -1
- package/lib/fetchSnapshot.d.ts +1 -1
- package/lib/fetchSnapshot.js +1 -1
- package/lib/fetchSnapshot.js.map +1 -1
- package/lib/getFileLink.js +1 -1
- package/lib/getFileLink.js.map +1 -1
- package/lib/legacy.d.ts +2 -1
- package/lib/odspCache.d.ts +4 -4
- package/lib/odspCache.js.map +1 -1
- package/lib/odspDocumentService.d.ts.map +1 -1
- package/lib/odspDocumentService.js +4 -4
- package/lib/odspDocumentService.js.map +1 -1
- package/lib/odspDocumentServiceFactory.d.ts +2 -2
- package/lib/odspDocumentServiceFactory.js +2 -2
- package/lib/odspDocumentServiceFactory.js.map +1 -1
- package/lib/odspDocumentServiceFactoryCore.d.ts +1 -1
- package/lib/odspDocumentServiceFactoryCore.js +1 -1
- package/lib/odspDocumentServiceFactoryCore.js.map +1 -1
- package/lib/odspDriverUrlResolver.d.ts +1 -1
- package/lib/odspDriverUrlResolver.js +1 -1
- package/lib/odspDriverUrlResolver.js.map +1 -1
- package/lib/odspDriverUrlResolverForShareLink.d.ts +2 -2
- package/lib/odspDriverUrlResolverForShareLink.js +1 -1
- package/lib/odspDriverUrlResolverForShareLink.js.map +1 -1
- package/lib/odspFluidFileLink.d.ts +4 -4
- package/lib/odspFluidFileLink.js +4 -4
- package/lib/odspFluidFileLink.js.map +1 -1
- package/lib/odspPublicUtils.d.ts +2 -2
- package/lib/odspPublicUtils.js +1 -1
- package/lib/odspPublicUtils.js.map +1 -1
- package/lib/odspUtils.d.ts +2 -2
- package/lib/odspUtils.js +1 -1
- package/lib/odspUtils.js.map +1 -1
- package/lib/packageVersion.d.ts +1 -1
- package/lib/packageVersion.d.ts.map +1 -1
- package/lib/packageVersion.js +1 -1
- package/lib/packageVersion.js.map +1 -1
- package/lib/prefetchLatestSnapshot.d.ts +1 -1
- package/lib/prefetchLatestSnapshot.js +1 -1
- package/lib/prefetchLatestSnapshot.js.map +1 -1
- package/lib/tsdoc-metadata.json +1 -1
- package/package.json +21 -21
- package/src/checkUrl.ts +1 -1
- package/src/constants.ts +2 -2
- package/src/contractsPublic.ts +1 -1
- package/src/createOdspCreateContainerRequest.ts +1 -1
- package/src/createOdspUrl.ts +1 -1
- package/src/epochTracker.ts +4 -4
- package/src/fetchSnapshot.ts +1 -1
- package/src/getFileLink.ts +1 -1
- package/src/odspCache.ts +4 -4
- package/src/odspDocumentService.ts +5 -4
- package/src/odspDocumentServiceFactory.ts +2 -2
- package/src/odspDocumentServiceFactoryCore.ts +1 -1
- package/src/odspDriverUrlResolver.ts +1 -1
- package/src/odspDriverUrlResolverForShareLink.ts +2 -2
- package/src/odspFluidFileLink.ts +4 -4
- package/src/odspPublicUtils.ts +2 -2
- package/src/odspUtils.ts +2 -2
- package/src/packageVersion.ts +1 -1
- package/src/prefetchLatestSnapshot.ts +1 -1
package/.mocharc.cjs
CHANGED
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -7,6 +7,25 @@ The ODSP Fluid service is not a publicly available service, and currently it is
|
|
|
7
7
|
to connect to it. This driver is present as an illustration of a different Fluid driver implementation.
|
|
8
8
|
Developers should not depend on this driver for their own solutions.
|
|
9
9
|
|
|
10
|
+
## Telemetry Event names to SPO API mapping:
|
|
11
|
+
|
|
12
|
+
These event names are suffixed by `_end` in case they are successful API calls or by `_cancel` in case they are failures.
|
|
13
|
+
In the table I have used the failure ones.
|
|
14
|
+
|
|
15
|
+
| Event Name | Endpoint | Notes |
|
|
16
|
+
|:---|:---|:---|
|
|
17
|
+
| fluid:telemetry:OdspDriver:TreesLatest_cancel | `/_api/v2.1/drives/DRIVEID/items/ITEMID/opStream/snapshots/trees/latest?ump=1` | Error when fetching snapshot from storage, typically during document load. (Storage Call) |
|
|
18
|
+
| fluid:telemetry:OdspDriver:GetDeltas_cancel<br>fluid:telemetry:OdspDriver:OpsFetch_cancel | `/_api/v2.1/drives/DRIVEID/items/ITEMID/opStream?ump=1&filter=sequenceNumber ge START and sequenceNumber le END` | Error when fetching ops from the storage. (Storage Call) |
|
|
19
|
+
| fluid:telemetry:OdspDriver:JoinSession_cancel | `/_api/v2.1/drives/DRIVEID/items/ITEMID/opStream/joinSession?ump=1` | Error when getting the details needed to connect to socket. It is also called every 15 mins to renew session. (Storage Call) |
|
|
20
|
+
| fluid:telemetry:BlobManager:AttachmentReadBlob_cancel<br>fluid:telemetry:OdspDriver:readDataBlob_cancel | `/_api/v2.1/drives/DRIVEID/items/ITEMID/opStream/attachments/BLOB_ID/content` | Error when reading attachment blobs (e.g. images). (Storage Call) |
|
|
21
|
+
| fluid:telemetry:OdspDriver:createBlob_cancel | `/_api/v2.1/drives/DRIVEID/items/ITEMID/opStream/attachment/content` | Error when creating an attachment blob (e.g. an inserted image). (Storage Call) |
|
|
22
|
+
| fluid:telemetry:OdspDriver:CreateNewFile_cancel | `/_api/v2.1/drives/DRIVEID/items/root:%2f<path>.fluid:/opStream/snapshots/snapshot?ump=1` | Error when creating a new Fluid file, during Container Attach. (Storage Call) |
|
|
23
|
+
| fluid:telemetry:OdspDriver:createNewEmptyFile_cancel | `/_api/v2.1/drives/DRIVEID/items/root://FILEPATH/FILENAME:/content?@name.conflictBehavior=rename&select=id,name,parentReference&ump=1` | Error when creating a new empty Fluid file. When we have attachment blobs in detached container, we first create empty file, then upload attachment blobs and then upload summary so that summary can refer to those blobs. (Storage Call) |
|
|
24
|
+
| fluid:telemetry:OdspDriver:uploadSummary_cancel | `/_api/v2.1/drives/DRIVEID/items/ITEMID/opStream/snapshots/snapshot` | Error when uploading Fluid summary to storage. (Storage Call) |
|
|
25
|
+
| fluid:telemetry:OdspDriver:RedeemShareLink_cancel | `_api/v2.0/shares/${encodedShareUrl}/driveItem` | Error when redeeming the share link after single Round Trip redeem during snapshot fetch already failed. [Read more about single RT Redeem here.](#snapshot-api) |
|
|
26
|
+
| OdspDriver:odspFileLink_cancel<br>OdspDriver:getShareLink_cancel | `/_api/v2.0/drives/${driveId}/items/${itemId}?select=webUrl,webDavUrl,sharepointIds` | Error when fetching sharing link with `requestName` = `getFileItemLite` in Telemetry. `getShareLink` event is parent of `odspFileLink` event. |
|
|
27
|
+
| OdspDriver:odspFileLink_cancel<br>OdspDriver:getShareLink_cancel | `/_api/web/GetFileById(@a1)/ListItemAllFields/GetSharingInformation?@a1=guid${encodeURIComponent(`'${fileItem.sharepointIds.listItemUniqueId}'`)}` | Error when fetching sharing link with `requestName` = `getSharingInformation` in Telemetry. `getShareLink` event is parent of `odspFileLink` event. |
|
|
28
|
+
|
|
10
29
|
<!-- AUTO-GENERATED-CONTENT:START (LIBRARY_README_HEADER) -->
|
|
11
30
|
|
|
12
31
|
<!-- prettier-ignore-start -->
|
|
@@ -1,25 +1,25 @@
|
|
|
1
|
-
##
|
|
1
|
+
## Beta API Report File for "@fluidframework/odsp-driver"
|
|
2
2
|
|
|
3
3
|
> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
|
|
4
4
|
|
|
5
5
|
```ts
|
|
6
6
|
|
|
7
|
-
// @
|
|
7
|
+
// @beta @legacy
|
|
8
8
|
export function checkUrl(documentUrl: URL): DriverPreCheckInfo | undefined;
|
|
9
9
|
|
|
10
|
-
// @
|
|
10
|
+
// @beta @legacy
|
|
11
11
|
export function createLocalOdspDocumentServiceFactory(localSnapshot: Uint8Array | string): IDocumentServiceFactory;
|
|
12
12
|
|
|
13
|
-
// @
|
|
13
|
+
// @beta @legacy
|
|
14
14
|
export function createOdspCreateContainerRequest(siteUrl: string, driveId: string, filePath: string, fileName: string, createShareLinkType?: ISharingLinkKind, containerPackageInfo?: IContainerPackageInfo | undefined): IRequest;
|
|
15
15
|
|
|
16
|
-
// @
|
|
16
|
+
// @beta @legacy
|
|
17
17
|
export function createOdspUrl(l: OdspFluidDataStoreLocator): string;
|
|
18
18
|
|
|
19
|
-
// @
|
|
19
|
+
// @beta @legacy
|
|
20
20
|
export function encodeOdspFluidDataStoreLocator(locator: OdspFluidDataStoreLocator): string;
|
|
21
21
|
|
|
22
|
-
// @
|
|
22
|
+
// @beta @legacy
|
|
23
23
|
export class EpochTracker implements IPersistedFileCache {
|
|
24
24
|
constructor(cache: IPersistedCache, fileEntry: IFileEntry, logger: ITelemetryLoggerExt, clientIsSummarizer?: boolean | undefined);
|
|
25
25
|
// (undocumented)
|
|
@@ -53,19 +53,19 @@ export class EpochTracker implements IPersistedFileCache {
|
|
|
53
53
|
protected validateEpochFromResponse(epochFromResponse: string | undefined, fetchType: FetchTypeInternal, fromCache?: boolean): void;
|
|
54
54
|
}
|
|
55
55
|
|
|
56
|
-
// @
|
|
56
|
+
// @beta @legacy (undocumented)
|
|
57
57
|
export type FetchType = "blob" | "createBlob" | "createFile" | "joinSession" | "ops" | "test" | "snapshotTree" | "treesLatest" | "uploadSummary" | "push" | "versions" | "renameFile";
|
|
58
58
|
|
|
59
|
-
// @
|
|
59
|
+
// @beta @legacy (undocumented)
|
|
60
60
|
export type FetchTypeInternal = FetchType | "cache";
|
|
61
61
|
|
|
62
|
-
// @
|
|
62
|
+
// @beta @legacy
|
|
63
63
|
export function getHashedDocumentId(driveId: string, itemId: string): Promise<string>;
|
|
64
64
|
|
|
65
|
-
// @
|
|
65
|
+
// @beta @legacy
|
|
66
66
|
export function getLocatorFromOdspUrl(url: URL, requireFluidSignature?: boolean): OdspFluidDataStoreLocator | undefined;
|
|
67
67
|
|
|
68
|
-
// @
|
|
68
|
+
// @beta @legacy (undocumented)
|
|
69
69
|
export interface ICacheAndTracker {
|
|
70
70
|
// (undocumented)
|
|
71
71
|
cache: IOdspCache;
|
|
@@ -73,7 +73,7 @@ export interface ICacheAndTracker {
|
|
|
73
73
|
epochTracker: EpochTracker;
|
|
74
74
|
}
|
|
75
75
|
|
|
76
|
-
// @
|
|
76
|
+
// @beta @legacy
|
|
77
77
|
export interface INonPersistentCache {
|
|
78
78
|
readonly fileUrlCache: PromiseCache<string, IOdspResolvedUrl>;
|
|
79
79
|
readonly sessionJoinCache: PromiseCache<string, {
|
|
@@ -83,12 +83,12 @@ export interface INonPersistentCache {
|
|
|
83
83
|
readonly snapshotPrefetchResultCache: PromiseCache<string, IPrefetchSnapshotContents>;
|
|
84
84
|
}
|
|
85
85
|
|
|
86
|
-
// @
|
|
86
|
+
// @beta @legacy
|
|
87
87
|
export interface IOdspCache extends INonPersistentCache {
|
|
88
88
|
readonly persistedCache: IPersistedFileCache;
|
|
89
89
|
}
|
|
90
90
|
|
|
91
|
-
// @
|
|
91
|
+
// @beta @legacy (undocumented)
|
|
92
92
|
export interface IOdspResponse<T> {
|
|
93
93
|
// (undocumented)
|
|
94
94
|
content: T;
|
|
@@ -100,7 +100,7 @@ export interface IOdspResponse<T> {
|
|
|
100
100
|
propsToLog: ITelemetryBaseProperties;
|
|
101
101
|
}
|
|
102
102
|
|
|
103
|
-
// @
|
|
103
|
+
// @beta @legacy
|
|
104
104
|
export interface IPersistedFileCache {
|
|
105
105
|
// (undocumented)
|
|
106
106
|
get(entry: IEntry): Promise<any>;
|
|
@@ -110,7 +110,7 @@ export interface IPersistedFileCache {
|
|
|
110
110
|
removeEntries(): Promise<void>;
|
|
111
111
|
}
|
|
112
112
|
|
|
113
|
-
// @
|
|
113
|
+
// @beta @legacy (undocumented)
|
|
114
114
|
export interface IPrefetchSnapshotContents extends ISnapshot {
|
|
115
115
|
// (undocumented)
|
|
116
116
|
fluidEpoch: string;
|
|
@@ -118,7 +118,7 @@ export interface IPrefetchSnapshotContents extends ISnapshot {
|
|
|
118
118
|
prefetchStartTime: number;
|
|
119
119
|
}
|
|
120
120
|
|
|
121
|
-
// @
|
|
121
|
+
// @beta @deprecated @legacy (undocumented)
|
|
122
122
|
export interface ISnapshotContents {
|
|
123
123
|
// (undocumented)
|
|
124
124
|
blobs: Map<string, ArrayBuffer>;
|
|
@@ -130,24 +130,24 @@ export interface ISnapshotContents {
|
|
|
130
130
|
snapshotTree: ISnapshotTree;
|
|
131
131
|
}
|
|
132
132
|
|
|
133
|
-
// @
|
|
133
|
+
// @beta @legacy
|
|
134
134
|
export function isOdspResolvedUrl(resolvedUrl: IResolvedUrl): resolvedUrl is IOdspResolvedUrl;
|
|
135
135
|
|
|
136
|
-
// @
|
|
136
|
+
// @beta @legacy
|
|
137
137
|
export const locatorQueryParamName = "nav";
|
|
138
138
|
|
|
139
|
-
// @
|
|
139
|
+
// @beta @legacy (undocumented)
|
|
140
140
|
export const OdcApiSiteOrigin = "https://my.microsoftpersonalcontent.com";
|
|
141
141
|
|
|
142
|
-
// @
|
|
142
|
+
// @beta @legacy (undocumented)
|
|
143
143
|
export const OdcFileSiteOrigin = "https://1drv.ms";
|
|
144
144
|
|
|
145
|
-
// @
|
|
145
|
+
// @beta @legacy
|
|
146
146
|
export class OdspDocumentServiceFactory extends OdspDocumentServiceFactoryCore {
|
|
147
147
|
constructor(getStorageToken: TokenFetcher<OdspResourceTokenFetchOptions>, getWebsocketToken: TokenFetcher<OdspResourceTokenFetchOptions> | undefined, persistedCache?: IPersistedCache, hostPolicy?: HostStoragePolicy);
|
|
148
148
|
}
|
|
149
149
|
|
|
150
|
-
// @
|
|
150
|
+
// @beta @legacy
|
|
151
151
|
export class OdspDocumentServiceFactoryCore implements IDocumentServiceFactory, IRelaySessionAwareDriverFactory {
|
|
152
152
|
constructor(getStorageToken: TokenFetcher<OdspResourceTokenFetchOptions>, getWebsocketToken: TokenFetcher<OdspResourceTokenFetchOptions> | undefined, persistedCache?: IPersistedCache, hostPolicy?: HostStoragePolicy);
|
|
153
153
|
// (undocumented)
|
|
@@ -166,14 +166,14 @@ export class OdspDocumentServiceFactoryCore implements IDocumentServiceFactory,
|
|
|
166
166
|
get snapshotPrefetchResultCache(): PromiseCache<string, IPrefetchSnapshotContents>;
|
|
167
167
|
}
|
|
168
168
|
|
|
169
|
-
// @
|
|
169
|
+
// @beta @legacy
|
|
170
170
|
export class OdspDriverUrlResolver implements IUrlResolver {
|
|
171
171
|
constructor();
|
|
172
172
|
getAbsoluteUrl(resolvedUrl: IResolvedUrl, relativeUrl: string, packageInfoSource?: IContainerPackageInfo): Promise<string>;
|
|
173
173
|
resolve(request: IRequest): Promise<IOdspResolvedUrl>;
|
|
174
174
|
}
|
|
175
175
|
|
|
176
|
-
// @
|
|
176
|
+
// @beta @legacy
|
|
177
177
|
export class OdspDriverUrlResolverForShareLink implements IUrlResolver {
|
|
178
178
|
constructor(shareLinkFetcherProps?: ShareLinkFetcherProps | undefined, logger?: ITelemetryBaseLogger, appName?: string | undefined, getContext?: ((resolvedUrl: IOdspResolvedUrl, dataStorePath: string) => Promise<string | undefined>) | undefined, containerPackageInfo?: IContainerPackageInfo | undefined);
|
|
179
179
|
appendDataStorePath(requestUrl: URL, pathToAppend: string): string | undefined;
|
|
@@ -183,7 +183,7 @@ export class OdspDriverUrlResolverForShareLink implements IUrlResolver {
|
|
|
183
183
|
resolve(request: IRequest): Promise<IOdspResolvedUrl>;
|
|
184
184
|
}
|
|
185
185
|
|
|
186
|
-
// @
|
|
186
|
+
// @beta @legacy (undocumented)
|
|
187
187
|
export interface OdspFluidDataStoreLocator extends IOdspUrlParts {
|
|
188
188
|
// (undocumented)
|
|
189
189
|
appName?: string;
|
|
@@ -197,16 +197,16 @@ export interface OdspFluidDataStoreLocator extends IOdspUrlParts {
|
|
|
197
197
|
fileVersion?: string;
|
|
198
198
|
}
|
|
199
199
|
|
|
200
|
-
// @
|
|
200
|
+
// @beta @deprecated @legacy
|
|
201
201
|
export function prefetchLatestSnapshot(resolvedUrl: IResolvedUrl, getStorageToken: TokenFetcher<OdspResourceTokenFetchOptions>, persistedCache: IPersistedCache, forceAccessTokenViaAuthorizationHeader: boolean, logger: ITelemetryBaseLogger, hostSnapshotFetchOptions: ISnapshotOptions | undefined, enableRedeemFallback?: boolean, fetchBinarySnapshotFormat?: boolean, snapshotFormatFetchType?: SnapshotFormatSupportType, odspDocumentServiceFactory?: OdspDocumentServiceFactory): Promise<boolean>;
|
|
202
202
|
|
|
203
|
-
// @
|
|
203
|
+
// @beta @legacy
|
|
204
204
|
export interface ShareLinkFetcherProps {
|
|
205
205
|
identityType: IdentityType;
|
|
206
206
|
tokenFetcher: TokenFetcher<OdspResourceTokenFetchOptions>;
|
|
207
207
|
}
|
|
208
208
|
|
|
209
|
-
// @
|
|
209
|
+
// @beta @legacy
|
|
210
210
|
export enum SnapshotFormatSupportType {
|
|
211
211
|
// (undocumented)
|
|
212
212
|
Binary = 1,
|
|
@@ -216,7 +216,7 @@ export enum SnapshotFormatSupportType {
|
|
|
216
216
|
JsonAndBinary = 2
|
|
217
217
|
}
|
|
218
218
|
|
|
219
|
-
// @
|
|
219
|
+
// @beta @legacy
|
|
220
220
|
export function storeLocatorInOdspUrl(url: URL, locator: OdspFluidDataStoreLocator): void;
|
|
221
221
|
|
|
222
222
|
// (No @packageDocumentation comment for this package)
|
package/dist/checkUrl.d.ts
CHANGED
|
@@ -9,7 +9,7 @@ import type { DriverPreCheckInfo } from "@fluidframework/driver-definitions/inte
|
|
|
9
9
|
* Instead, this should be used as a lightweight check that can filter out easily detectable unsupported URLs
|
|
10
10
|
* before the entire Fluid loading process needs to be kicked off.
|
|
11
11
|
* @legacy
|
|
12
|
-
* @
|
|
12
|
+
* @beta
|
|
13
13
|
*/
|
|
14
14
|
export declare function checkUrl(documentUrl: URL): DriverPreCheckInfo | undefined;
|
|
15
15
|
//# sourceMappingURL=checkUrl.d.ts.map
|
package/dist/checkUrl.js
CHANGED
|
@@ -12,7 +12,7 @@ const odspFluidFileLink_js_1 = require("./odspFluidFileLink.js");
|
|
|
12
12
|
* Instead, this should be used as a lightweight check that can filter out easily detectable unsupported URLs
|
|
13
13
|
* before the entire Fluid loading process needs to be kicked off.
|
|
14
14
|
* @legacy
|
|
15
|
-
* @
|
|
15
|
+
* @beta
|
|
16
16
|
*/
|
|
17
17
|
function checkUrl(documentUrl) {
|
|
18
18
|
const locator = (0, odspFluidFileLink_js_1.getLocatorFromOdspUrl)(documentUrl);
|
package/dist/checkUrl.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"checkUrl.js","sourceRoot":"","sources":["../src/checkUrl.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAIH,iEAA+D;AAE/D;;;;;;;GAOG;AACH,SAAgB,QAAQ,CAAC,WAAgB;IACxC,MAAM,OAAO,GAAG,IAAA,4CAAqB,EAAC,WAAW,CAAC,CAAC;IAEnD,IAAI,CAAC,OAAO,EAAE,CAAC;QACd,OAAO,SAAS,CAAC;IAClB,CAAC;IAED,IAAI,UAA8B,CAAC;IACnC,IAAI,CAAC;QACJ,IAAI,OAAO,EAAE,OAAO,EAAE,CAAC;YACtB,UAAU,GAAG,IAAI,GAAG,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC,MAAM,CAAC;QAC/C,CAAC;IACF,CAAC;IAAC,MAAM,CAAC;QACR,aAAa;IACd,CAAC;IAED,OAAO;QACN,eAAe,EAAE,OAAO,EAAE,oBAAoB;QAC9C,uEAAuE;QACvE,mBAAmB,EAAE,UAAU,CAAC,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,SAAS;KAC1D,CAAC;AACH,CAAC;AArBD,4BAqBC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { DriverPreCheckInfo } from \"@fluidframework/driver-definitions/internal\";\n\nimport { getLocatorFromOdspUrl } from \"./odspFluidFileLink.js\";\n\n/**\n * A check that returns DriverPreCheckInfo if the URL format is likely supported by this driver.\n * Note that returning information here is NOT a full guarantee that resolve will ultimately be successful.\n * Instead, this should be used as a lightweight check that can filter out easily detectable unsupported URLs\n * before the entire Fluid loading process needs to be kicked off.\n * @legacy\n * @
|
|
1
|
+
{"version":3,"file":"checkUrl.js","sourceRoot":"","sources":["../src/checkUrl.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAIH,iEAA+D;AAE/D;;;;;;;GAOG;AACH,SAAgB,QAAQ,CAAC,WAAgB;IACxC,MAAM,OAAO,GAAG,IAAA,4CAAqB,EAAC,WAAW,CAAC,CAAC;IAEnD,IAAI,CAAC,OAAO,EAAE,CAAC;QACd,OAAO,SAAS,CAAC;IAClB,CAAC;IAED,IAAI,UAA8B,CAAC;IACnC,IAAI,CAAC;QACJ,IAAI,OAAO,EAAE,OAAO,EAAE,CAAC;YACtB,UAAU,GAAG,IAAI,GAAG,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC,MAAM,CAAC;QAC/C,CAAC;IACF,CAAC;IAAC,MAAM,CAAC;QACR,aAAa;IACd,CAAC;IAED,OAAO;QACN,eAAe,EAAE,OAAO,EAAE,oBAAoB;QAC9C,uEAAuE;QACvE,mBAAmB,EAAE,UAAU,CAAC,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,SAAS;KAC1D,CAAC;AACH,CAAC;AArBD,4BAqBC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { DriverPreCheckInfo } from \"@fluidframework/driver-definitions/internal\";\n\nimport { getLocatorFromOdspUrl } from \"./odspFluidFileLink.js\";\n\n/**\n * A check that returns DriverPreCheckInfo if the URL format is likely supported by this driver.\n * Note that returning information here is NOT a full guarantee that resolve will ultimately be successful.\n * Instead, this should be used as a lightweight check that can filter out easily detectable unsupported URLs\n * before the entire Fluid loading process needs to be kicked off.\n * @legacy\n * @beta\n */\nexport function checkUrl(documentUrl: URL): DriverPreCheckInfo | undefined {\n\tconst locator = getLocatorFromOdspUrl(documentUrl);\n\n\tif (!locator) {\n\t\treturn undefined;\n\t}\n\n\tlet siteOrigin: string | undefined;\n\ttry {\n\t\tif (locator?.siteUrl) {\n\t\t\tsiteOrigin = new URL(locator?.siteUrl).origin;\n\t\t}\n\t} catch {\n\t\t// Drop error\n\t}\n\n\treturn {\n\t\tcodeDetailsHint: locator?.containerPackageName,\n\t\t// Add the snapshot endpoint, which has the same domain as the site URL\n\t\tcriticalBootDomains: siteOrigin ? [siteOrigin] : undefined,\n\t};\n}\n"]}
|
package/dist/constants.d.ts
CHANGED
|
@@ -4,12 +4,12 @@
|
|
|
4
4
|
*/
|
|
5
5
|
/**
|
|
6
6
|
* @legacy
|
|
7
|
-
* @
|
|
7
|
+
* @beta
|
|
8
8
|
*/
|
|
9
9
|
export declare const OdcApiSiteOrigin = "https://my.microsoftpersonalcontent.com";
|
|
10
10
|
/**
|
|
11
11
|
* @legacy
|
|
12
|
-
* @
|
|
12
|
+
* @beta
|
|
13
13
|
*/
|
|
14
14
|
export declare const OdcFileSiteOrigin = "https://1drv.ms";
|
|
15
15
|
//# sourceMappingURL=constants.d.ts.map
|
package/dist/constants.js
CHANGED
|
@@ -7,12 +7,12 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
7
7
|
exports.OdcFileSiteOrigin = exports.OdcApiSiteOrigin = void 0;
|
|
8
8
|
/**
|
|
9
9
|
* @legacy
|
|
10
|
-
* @
|
|
10
|
+
* @beta
|
|
11
11
|
*/
|
|
12
12
|
exports.OdcApiSiteOrigin = "https://my.microsoftpersonalcontent.com";
|
|
13
13
|
/**
|
|
14
14
|
* @legacy
|
|
15
|
-
* @
|
|
15
|
+
* @beta
|
|
16
16
|
*/
|
|
17
17
|
exports.OdcFileSiteOrigin = "https://1drv.ms";
|
|
18
18
|
//# sourceMappingURL=constants.js.map
|
package/dist/constants.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../src/constants.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH;;;GAGG;AACU,QAAA,gBAAgB,GAAG,yCAAyC,CAAC;AAE1E;;;GAGG;AACU,QAAA,iBAAiB,GAAG,iBAAiB,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\n/**\n * @legacy\n * @
|
|
1
|
+
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../src/constants.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH;;;GAGG;AACU,QAAA,gBAAgB,GAAG,yCAAyC,CAAC;AAE1E;;;GAGG;AACU,QAAA,iBAAiB,GAAG,iBAAiB,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\n/**\n * @legacy\n * @beta\n */\nexport const OdcApiSiteOrigin = \"https://my.microsoftpersonalcontent.com\";\n\n/**\n * @legacy\n * @beta\n */\nexport const OdcFileSiteOrigin = \"https://1drv.ms\";\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"contractsPublic.js","sourceRoot":"","sources":["../src/contractsPublic.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAgBH;;GAEG;AACH,IAAY,iBAWX;AAXD,WAAY,iBAAiB;IAC5B;;;OAGG;IACH,oEAA+C,CAAA;IAC/C;;;OAGG;IACH,sEAAiD,CAAA;AAClD,CAAC,EAXW,iBAAiB,iCAAjB,iBAAiB,QAW5B;AASD;;GAEG;AACH,IAAY,qBAIX;AAJD,WAAY,qBAAqB;IAChC,oGAAoG;IACpG,wGAAwG;IACxG,kEAAyC,CAAA;AAC1C,CAAC,EAJW,qBAAqB,qCAArB,qBAAqB,QAIhC;AASD;;GAEG;AACH,IAAY,kBAMX;AAND,WAAY,kBAAkB;IAC7B;;;OAGG;IACH,mCAAa,CAAA;AACd,CAAC,EANW,kBAAkB,kCAAlB,kBAAkB,QAM7B","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { IOdspUrlParts } from \"@fluidframework/odsp-driver-definitions/internal\";\n\n/**\n * @legacy\n * @
|
|
1
|
+
{"version":3,"file":"contractsPublic.js","sourceRoot":"","sources":["../src/contractsPublic.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAgBH;;GAEG;AACH,IAAY,iBAWX;AAXD,WAAY,iBAAiB;IAC5B;;;OAGG;IACH,oEAA+C,CAAA;IAC/C;;;OAGG;IACH,sEAAiD,CAAA;AAClD,CAAC,EAXW,iBAAiB,iCAAjB,iBAAiB,QAW5B;AASD;;GAEG;AACH,IAAY,qBAIX;AAJD,WAAY,qBAAqB;IAChC,oGAAoG;IACpG,wGAAwG;IACxG,kEAAyC,CAAA;AAC1C,CAAC,EAJW,qBAAqB,qCAArB,qBAAqB,QAIhC;AASD;;GAEG;AACH,IAAY,kBAMX;AAND,WAAY,kBAAkB;IAC7B;;;OAGG;IACH,mCAAa,CAAA;AACd,CAAC,EANW,kBAAkB,kCAAlB,kBAAkB,QAM7B","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { IOdspUrlParts } from \"@fluidframework/odsp-driver-definitions/internal\";\n\n/**\n * @legacy\n * @beta\n */\nexport interface OdspFluidDataStoreLocator extends IOdspUrlParts {\n\tdataStorePath: string;\n\tappName?: string;\n\tcontainerPackageName?: string;\n\tfileVersion?: string;\n\tcontext?: string;\n}\n\n/**\n * @internal\n */\nexport enum SharingLinkHeader {\n\t/**\n\t * Can be used in request made to resolver, to tell the resolver that the passed in URL is a sharing link\n\t * which can be redeemed at server to get permissions.\n\t */\n\tisSharingLinkToRedeem = \"isSharingLinkToRedeem\",\n\t/**\n\t * When isSharingLinkToRedeem is true, this header can be used to tell the server that the redemption of the sharing link\n\t * is meant to be non-durable.\n\t */\n\tisRedemptionNonDurable = \"isRedemptionNonDurable\",\n}\n\n/**\n * @internal\n */\nexport interface ISharingLinkHeader {\n\t[SharingLinkHeader.isSharingLinkToRedeem]: boolean;\n\t[SharingLinkHeader.isRedemptionNonDurable]: boolean;\n}\n/**\n * @internal\n */\nexport enum ClpCompliantAppHeader {\n\t// Can be used in request made to resolver, to tell the resolver that the host app is CLP compliant.\n\t// Odsp will not return Classified, labeled, or protected documents if the host app cannot support them.\n\tisClpCompliantApp = \"X-CLP-Compliant-App\",\n}\n\n/**\n * @internal\n */\nexport interface IClpCompliantAppHeader {\n\t[ClpCompliantAppHeader.isClpCompliantApp]: boolean;\n}\n\n/**\n * @internal\n */\nexport enum FileMetadataHeader {\n\t/**\n\t * ETag (entity tag) identifier for a specific version of the file.\n\t * When provided, it will be sent to the snapshot API in the If-Match header.\n\t */\n\teTag = \"eTag\",\n}\n/**\n * @internal\n */\nexport interface IFileMetadataHeader {\n\t[FileMetadataHeader.eTag]: string;\n}\n\ndeclare module \"@fluidframework/core-interfaces\" {\n\texport interface IRequestHeader\n\t\textends Partial<ISharingLinkHeader>,\n\t\t\tPartial<IClpCompliantAppHeader>,\n\t\t\tPartial<IFileMetadataHeader> {}\n}\n"]}
|
|
@@ -16,7 +16,7 @@ import type { ISharingLinkKind } from "@fluidframework/odsp-driver-definitions/i
|
|
|
16
16
|
* @param containerPackageInfo - Container package information which will be used to extract the container package name.
|
|
17
17
|
* If not given that means that the container package does not have a name.
|
|
18
18
|
* @legacy
|
|
19
|
-
* @
|
|
19
|
+
* @beta
|
|
20
20
|
*/
|
|
21
21
|
export declare function createOdspCreateContainerRequest(siteUrl: string, driveId: string, filePath: string, fileName: string, createShareLinkType?: ISharingLinkKind, containerPackageInfo?: IContainerPackageInfo | undefined): IRequest;
|
|
22
22
|
//# sourceMappingURL=createOdspCreateContainerRequest.d.ts.map
|
|
@@ -18,7 +18,7 @@ const odspUtils_js_1 = require("./odspUtils.js");
|
|
|
18
18
|
* @param containerPackageInfo - Container package information which will be used to extract the container package name.
|
|
19
19
|
* If not given that means that the container package does not have a name.
|
|
20
20
|
* @legacy
|
|
21
|
-
* @
|
|
21
|
+
* @beta
|
|
22
22
|
*/
|
|
23
23
|
function createOdspCreateContainerRequest(siteUrl, driveId, filePath, fileName, createShareLinkType, containerPackageInfo) {
|
|
24
24
|
const shareLinkRequestParams = (0, odspUtils_js_1.buildOdspShareLinkReqParams)(createShareLinkType);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"createOdspCreateContainerRequest.js","sourceRoot":"","sources":["../src/createOdspCreateContainerRequest.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAGH,0EAGqD;AAGrD,iDAAsF;AAEtF;;;;;;;;;;;;GAYG;AACH,SAAgB,gCAAgC,CAC/C,OAAe,EACf,OAAe,EACf,QAAgB,EAChB,QAAgB,EAChB,mBAAsC,EACtC,oBAAwD;IAExD,MAAM,sBAAsB,GAAG,IAAA,0CAA2B,EAAC,mBAAmB,CAAC,CAAC;IAChF,MAAM,gBAAgB,GAAa;QAClC,GAAG,EAAE,GAAG,OAAO,YAAY,kBAAkB,CAAC,OAAO,CAAC,SAAS,kBAAkB,CAChF,QAAQ,CACR,GAAG,oBAAoB,CAAC,CAAC,CAAC,yBAAyB,IAAA,sCAAuB,EAAC,oBAAoB,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,GAAG,sBAAsB,CAAC,CAAC,CAAC,IAAI,sBAAsB,EAAE,CAAC,CAAC,CAAC,EAAE,EAAE;QACvK,OAAO,EAAE;YACR,CAAC,uBAAY,CAAC,SAAS,CAAC,EAAE;gBACzB,QAAQ;aACR;SACD;KACD,CAAC;IACF,OAAO,gBAAgB,CAAC;AACzB,CAAC;AApBD,4EAoBC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { IRequest } from \"@fluidframework/core-interfaces\";\nimport {\n\tDriverHeader,\n\ttype IContainerPackageInfo,\n} from \"@fluidframework/driver-definitions/internal\";\nimport type { ISharingLinkKind } from \"@fluidframework/odsp-driver-definitions/internal\";\n\nimport { buildOdspShareLinkReqParams, getContainerPackageName } from \"./odspUtils.js\";\n\n/**\n * Create the request object with url and headers for creating a new file on OneDrive Sharepoint\n * @param siteUrl - Base url for OneDrive\n * @param driveId - drive identifier\n * @param filePath - path where file needs to be created\n * @param fileName - name of the new file to be created\n * @param createShareLinkType - type of sharing link you would like to create for this file. ShareLinkTypes\n * will be deprecated soon, so for any new implementation please provide createShareLinkType of type ShareLink\n * @param containerPackageInfo - Container package information which will be used to extract the container package name.\n * If not given that means that the container package does not have a name.\n * @legacy\n * @
|
|
1
|
+
{"version":3,"file":"createOdspCreateContainerRequest.js","sourceRoot":"","sources":["../src/createOdspCreateContainerRequest.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAGH,0EAGqD;AAGrD,iDAAsF;AAEtF;;;;;;;;;;;;GAYG;AACH,SAAgB,gCAAgC,CAC/C,OAAe,EACf,OAAe,EACf,QAAgB,EAChB,QAAgB,EAChB,mBAAsC,EACtC,oBAAwD;IAExD,MAAM,sBAAsB,GAAG,IAAA,0CAA2B,EAAC,mBAAmB,CAAC,CAAC;IAChF,MAAM,gBAAgB,GAAa;QAClC,GAAG,EAAE,GAAG,OAAO,YAAY,kBAAkB,CAAC,OAAO,CAAC,SAAS,kBAAkB,CAChF,QAAQ,CACR,GAAG,oBAAoB,CAAC,CAAC,CAAC,yBAAyB,IAAA,sCAAuB,EAAC,oBAAoB,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,GAAG,sBAAsB,CAAC,CAAC,CAAC,IAAI,sBAAsB,EAAE,CAAC,CAAC,CAAC,EAAE,EAAE;QACvK,OAAO,EAAE;YACR,CAAC,uBAAY,CAAC,SAAS,CAAC,EAAE;gBACzB,QAAQ;aACR;SACD;KACD,CAAC;IACF,OAAO,gBAAgB,CAAC;AACzB,CAAC;AApBD,4EAoBC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { IRequest } from \"@fluidframework/core-interfaces\";\nimport {\n\tDriverHeader,\n\ttype IContainerPackageInfo,\n} from \"@fluidframework/driver-definitions/internal\";\nimport type { ISharingLinkKind } from \"@fluidframework/odsp-driver-definitions/internal\";\n\nimport { buildOdspShareLinkReqParams, getContainerPackageName } from \"./odspUtils.js\";\n\n/**\n * Create the request object with url and headers for creating a new file on OneDrive Sharepoint\n * @param siteUrl - Base url for OneDrive\n * @param driveId - drive identifier\n * @param filePath - path where file needs to be created\n * @param fileName - name of the new file to be created\n * @param createShareLinkType - type of sharing link you would like to create for this file. ShareLinkTypes\n * will be deprecated soon, so for any new implementation please provide createShareLinkType of type ShareLink\n * @param containerPackageInfo - Container package information which will be used to extract the container package name.\n * If not given that means that the container package does not have a name.\n * @legacy\n * @beta\n */\nexport function createOdspCreateContainerRequest(\n\tsiteUrl: string,\n\tdriveId: string,\n\tfilePath: string,\n\tfileName: string,\n\tcreateShareLinkType?: ISharingLinkKind,\n\tcontainerPackageInfo?: IContainerPackageInfo | undefined,\n): IRequest {\n\tconst shareLinkRequestParams = buildOdspShareLinkReqParams(createShareLinkType);\n\tconst createNewRequest: IRequest = {\n\t\turl: `${siteUrl}?driveId=${encodeURIComponent(driveId)}&path=${encodeURIComponent(\n\t\t\tfilePath,\n\t\t)}${containerPackageInfo ? `&containerPackageName=${getContainerPackageName(containerPackageInfo)}` : \"\"}${shareLinkRequestParams ? `&${shareLinkRequestParams}` : \"\"}`,\n\t\theaders: {\n\t\t\t[DriverHeader.createNew]: {\n\t\t\t\tfileName,\n\t\t\t},\n\t\t},\n\t};\n\treturn createNewRequest;\n}\n"]}
|
package/dist/createOdspUrl.d.ts
CHANGED
|
@@ -7,7 +7,7 @@ import type { OdspFluidDataStoreLocator } from "./contractsPublic.js";
|
|
|
7
7
|
* Encodes ODC/SPO information into a URL format that can be handled by the Loader
|
|
8
8
|
* @param l -The property bag of necessary properties to locate a Fluid data store and craft a url for it
|
|
9
9
|
* @legacy
|
|
10
|
-
* @
|
|
10
|
+
* @beta
|
|
11
11
|
*/
|
|
12
12
|
export declare function createOdspUrl(l: OdspFluidDataStoreLocator): string;
|
|
13
13
|
//# sourceMappingURL=createOdspUrl.d.ts.map
|
package/dist/createOdspUrl.js
CHANGED
|
@@ -12,7 +12,7 @@ exports.createOdspUrl = void 0;
|
|
|
12
12
|
* Encodes ODC/SPO information into a URL format that can be handled by the Loader
|
|
13
13
|
* @param l -The property bag of necessary properties to locate a Fluid data store and craft a url for it
|
|
14
14
|
* @legacy
|
|
15
|
-
* @
|
|
15
|
+
* @beta
|
|
16
16
|
*/
|
|
17
17
|
function createOdspUrl(l) {
|
|
18
18
|
let odspUrl = `${l.siteUrl}?driveId=${encodeURIComponent(l.driveId)}&itemId=${encodeURIComponent(l.itemId)}&path=${encodeURIComponent(l.dataStorePath)}`;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"createOdspUrl.js","sourceRoot":"","sources":["../src/createOdspUrl.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAIH;;GAEG;AAEH;;;;;GAKG;AACH,SAAgB,aAAa,CAAC,CAA4B;IACzD,IAAI,OAAO,GAAG,GAAG,CAAC,CAAC,OAAO,YAAY,kBAAkB,CACvD,CAAC,CAAC,OAAO,CACT,WAAW,kBAAkB,CAAC,CAAC,CAAC,MAAM,CAAC,SAAS,kBAAkB,CAAC,CAAC,CAAC,aAAa,CAAC,EAAE,CAAC;IACvF,IAAI,CAAC,CAAC,oBAAoB,EAAE,CAAC;QAC5B,OAAO,IAAI,yBAAyB,kBAAkB,CAAC,CAAC,CAAC,oBAAoB,CAAC,EAAE,CAAC;IAClF,CAAC;IACD,IAAI,CAAC,CAAC,WAAW,EAAE,CAAC;QACnB,OAAO,IAAI,gBAAgB,kBAAkB,CAAC,CAAC,CAAC,WAAW,CAAC,EAAE,CAAC;IAChE,CAAC;IAED,OAAO,OAAO,CAAC;AAChB,CAAC;AAZD,sCAYC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { OdspFluidDataStoreLocator } from \"./contractsPublic.js\";\n\n/*\n * Per https://github.com/microsoft/FluidFramework/issues/1556, isolating createOdspUrl() in its own file.\n */\n\n/**\n * Encodes ODC/SPO information into a URL format that can be handled by the Loader\n * @param l -The property bag of necessary properties to locate a Fluid data store and craft a url for it\n * @legacy\n * @
|
|
1
|
+
{"version":3,"file":"createOdspUrl.js","sourceRoot":"","sources":["../src/createOdspUrl.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAIH;;GAEG;AAEH;;;;;GAKG;AACH,SAAgB,aAAa,CAAC,CAA4B;IACzD,IAAI,OAAO,GAAG,GAAG,CAAC,CAAC,OAAO,YAAY,kBAAkB,CACvD,CAAC,CAAC,OAAO,CACT,WAAW,kBAAkB,CAAC,CAAC,CAAC,MAAM,CAAC,SAAS,kBAAkB,CAAC,CAAC,CAAC,aAAa,CAAC,EAAE,CAAC;IACvF,IAAI,CAAC,CAAC,oBAAoB,EAAE,CAAC;QAC5B,OAAO,IAAI,yBAAyB,kBAAkB,CAAC,CAAC,CAAC,oBAAoB,CAAC,EAAE,CAAC;IAClF,CAAC;IACD,IAAI,CAAC,CAAC,WAAW,EAAE,CAAC;QACnB,OAAO,IAAI,gBAAgB,kBAAkB,CAAC,CAAC,CAAC,WAAW,CAAC,EAAE,CAAC;IAChE,CAAC;IAED,OAAO,OAAO,CAAC;AAChB,CAAC;AAZD,sCAYC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { OdspFluidDataStoreLocator } from \"./contractsPublic.js\";\n\n/*\n * Per https://github.com/microsoft/FluidFramework/issues/1556, isolating createOdspUrl() in its own file.\n */\n\n/**\n * Encodes ODC/SPO information into a URL format that can be handled by the Loader\n * @param l -The property bag of necessary properties to locate a Fluid data store and craft a url for it\n * @legacy\n * @beta\n */\nexport function createOdspUrl(l: OdspFluidDataStoreLocator): string {\n\tlet odspUrl = `${l.siteUrl}?driveId=${encodeURIComponent(\n\t\tl.driveId,\n\t)}&itemId=${encodeURIComponent(l.itemId)}&path=${encodeURIComponent(l.dataStorePath)}`;\n\tif (l.containerPackageName) {\n\t\todspUrl += `&containerPackageName=${encodeURIComponent(l.containerPackageName)}`;\n\t}\n\tif (l.fileVersion) {\n\t\todspUrl += `&fileVersion=${encodeURIComponent(l.fileVersion)}`;\n\t}\n\n\treturn odspUrl;\n}\n"]}
|
package/dist/epochTracker.d.ts
CHANGED
|
@@ -9,12 +9,12 @@ import type { INonPersistentCache, IOdspCache, IPersistedFileCache } from "./ods
|
|
|
9
9
|
import { type IOdspResponse } from "./odspUtils.js";
|
|
10
10
|
/**
|
|
11
11
|
* @legacy
|
|
12
|
-
* @
|
|
12
|
+
* @beta
|
|
13
13
|
*/
|
|
14
14
|
export type FetchType = "blob" | "createBlob" | "createFile" | "joinSession" | "ops" | "test" | "snapshotTree" | "treesLatest" | "uploadSummary" | "push" | "versions" | "renameFile";
|
|
15
15
|
/**
|
|
16
16
|
* @legacy
|
|
17
|
-
* @
|
|
17
|
+
* @beta
|
|
18
18
|
*/
|
|
19
19
|
export type FetchTypeInternal = FetchType | "cache";
|
|
20
20
|
export declare const Odsp409Error = "Odsp409Error";
|
|
@@ -33,7 +33,7 @@ export declare const Odsp409Error = "Odsp409Error";
|
|
|
33
33
|
* It also validates the epoch value received in response of fetch calls. If the epoch does not match,
|
|
34
34
|
* then it also clears all the cached entries for the given container.
|
|
35
35
|
* @legacy
|
|
36
|
-
* @
|
|
36
|
+
* @beta
|
|
37
37
|
*/
|
|
38
38
|
export declare class EpochTracker implements IPersistedFileCache {
|
|
39
39
|
protected readonly cache: IPersistedCache;
|
|
@@ -105,7 +105,7 @@ export declare class EpochTrackerWithRedemption extends EpochTracker {
|
|
|
105
105
|
}
|
|
106
106
|
/**
|
|
107
107
|
* @legacy
|
|
108
|
-
* @
|
|
108
|
+
* @beta
|
|
109
109
|
*/
|
|
110
110
|
export interface ICacheAndTracker {
|
|
111
111
|
cache: IOdspCache;
|
package/dist/epochTracker.js
CHANGED
|
@@ -31,7 +31,7 @@ exports.Odsp409Error = "Odsp409Error";
|
|
|
31
31
|
* It also validates the epoch value received in response of fetch calls. If the epoch does not match,
|
|
32
32
|
* then it also clears all the cached entries for the given container.
|
|
33
33
|
* @legacy
|
|
34
|
-
* @
|
|
34
|
+
* @beta
|
|
35
35
|
*/
|
|
36
36
|
class EpochTracker {
|
|
37
37
|
constructor(cache, fileEntry, logger, clientIsSummarizer) {
|