@dev.fast/review-share-protocol 0.1.2 → 0.3.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/LICENSE +21 -0
- package/dist/index.d.ts +77 -37
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +48 -59
- package/dist/index.js.map +1 -1
- package/package.json +8 -9
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 dev.fast
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/dist/index.d.ts
CHANGED
|
@@ -1,63 +1,103 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
-
export declare const SHARE_FORMAT = "review-share/
|
|
3
|
-
|
|
4
|
-
export declare const MAX_SHARE_OBJECT_BYTES: number;
|
|
2
|
+
export declare const SHARE_FORMAT = "review-share/2";
|
|
3
|
+
/** UTF-8 bytes of a bundle's JSON, as uploaded and as stored. */
|
|
5
4
|
export declare const MAX_SHARE_BYTES: number;
|
|
6
|
-
export declare const MAX_SHARE_OBJECTS = 2048;
|
|
7
|
-
export declare const objectIdSchema: z.ZodString;
|
|
8
5
|
export declare const shareIdSchema: z.ZodUUID;
|
|
9
6
|
export declare const capabilitySchema: z.ZodString;
|
|
10
|
-
export declare const shareObjectSchema: z.ZodObject<{
|
|
11
|
-
id: z.ZodString;
|
|
12
|
-
size: z.ZodNumber;
|
|
13
|
-
sha256: z.ZodString;
|
|
14
|
-
}, z.core.$strict>;
|
|
15
7
|
export declare const sharePathSchema: z.ZodString;
|
|
16
8
|
/** The published identity is independent of the author's credential transport. */
|
|
17
9
|
export declare function normalizeGitHubRemote(remote: string): string;
|
|
18
10
|
export declare const gitHubRepositoryUrlSchema: z.ZodString;
|
|
19
|
-
|
|
20
|
-
|
|
11
|
+
/** An excerpt is the lines a board references. */
|
|
12
|
+
export declare const shareSourceSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
13
|
+
kind: z.ZodLiteral<"excerpt">;
|
|
14
|
+
file: z.ZodString;
|
|
15
|
+
commit: z.ZodString;
|
|
16
|
+
fromLine: z.ZodNumber;
|
|
17
|
+
lines: z.ZodArray<z.ZodString>;
|
|
18
|
+
}, z.core.$strict>], "kind">;
|
|
19
|
+
export declare const shareBundleSchema: z.ZodObject<{
|
|
20
|
+
format: z.ZodLiteral<"review-share/2">;
|
|
21
21
|
reviewId: z.ZodString;
|
|
22
22
|
version: z.ZodNumber;
|
|
23
23
|
title: z.ZodString;
|
|
24
|
-
snapshot: z.ZodString
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
id: z.ZodString;
|
|
28
|
-
size: z.ZodNumber;
|
|
29
|
-
sha256: z.ZodString;
|
|
24
|
+
snapshot: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
25
|
+
images: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
26
|
+
png: z.ZodBase64;
|
|
30
27
|
}, z.core.$strict>>;
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
mimeType: z.ZodEnum<{
|
|
39
|
-
"application/json": "application/json";
|
|
40
|
-
"image/png": "image/png";
|
|
28
|
+
traces: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
29
|
+
maps: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
30
|
+
commits: z.ZodArray<z.ZodUnknown>;
|
|
31
|
+
selections: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodObject<{
|
|
32
|
+
side: z.ZodEnum<{
|
|
33
|
+
base: "base";
|
|
34
|
+
head: "head";
|
|
41
35
|
}>;
|
|
42
|
-
|
|
43
|
-
|
|
36
|
+
file: z.ZodString;
|
|
37
|
+
fromLine: z.ZodNumber;
|
|
38
|
+
toLine: z.ZodNumber;
|
|
39
|
+
pins: z.ZodOptional<z.ZodObject<{
|
|
40
|
+
repositoryId: z.ZodString;
|
|
41
|
+
head: z.ZodString;
|
|
42
|
+
base: z.ZodOptional<z.ZodString>;
|
|
43
|
+
}, z.core.$strict>>;
|
|
44
|
+
}, z.core.$strict>>>;
|
|
45
|
+
sources: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
46
|
+
kind: z.ZodLiteral<"excerpt">;
|
|
47
|
+
file: z.ZodString;
|
|
48
|
+
commit: z.ZodString;
|
|
49
|
+
fromLine: z.ZodNumber;
|
|
50
|
+
lines: z.ZodArray<z.ZodString>;
|
|
51
|
+
}, z.core.$strict>], "kind">>;
|
|
44
52
|
repository: z.ZodOptional<z.ZodObject<{
|
|
45
53
|
cloneUrl: z.ZodString;
|
|
46
54
|
}, z.core.$strict>>;
|
|
47
55
|
}, z.core.$strict>;
|
|
48
|
-
export type
|
|
49
|
-
export type
|
|
56
|
+
export type ShareBundle = z.infer<typeof shareBundleSchema>;
|
|
57
|
+
export type ShareSource = z.infer<typeof shareSourceSchema>;
|
|
50
58
|
export declare const createShareSchema: z.ZodObject<{
|
|
51
59
|
requestId: z.ZodUUID;
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
60
|
+
bundle: z.ZodObject<{
|
|
61
|
+
format: z.ZodLiteral<"review-share/2">;
|
|
62
|
+
reviewId: z.ZodString;
|
|
63
|
+
version: z.ZodNumber;
|
|
64
|
+
title: z.ZodString;
|
|
65
|
+
snapshot: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
66
|
+
images: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
67
|
+
png: z.ZodBase64;
|
|
68
|
+
}, z.core.$strict>>;
|
|
69
|
+
traces: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
70
|
+
maps: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
71
|
+
commits: z.ZodArray<z.ZodUnknown>;
|
|
72
|
+
selections: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodObject<{
|
|
73
|
+
side: z.ZodEnum<{
|
|
74
|
+
base: "base";
|
|
75
|
+
head: "head";
|
|
76
|
+
}>;
|
|
77
|
+
file: z.ZodString;
|
|
78
|
+
fromLine: z.ZodNumber;
|
|
79
|
+
toLine: z.ZodNumber;
|
|
80
|
+
pins: z.ZodOptional<z.ZodObject<{
|
|
81
|
+
repositoryId: z.ZodString;
|
|
82
|
+
head: z.ZodString;
|
|
83
|
+
base: z.ZodOptional<z.ZodString>;
|
|
84
|
+
}, z.core.$strict>>;
|
|
85
|
+
}, z.core.$strict>>>;
|
|
86
|
+
sources: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
87
|
+
kind: z.ZodLiteral<"excerpt">;
|
|
88
|
+
file: z.ZodString;
|
|
89
|
+
commit: z.ZodString;
|
|
90
|
+
fromLine: z.ZodNumber;
|
|
91
|
+
lines: z.ZodArray<z.ZodString>;
|
|
92
|
+
}, z.core.$strict>], "kind">>;
|
|
93
|
+
repository: z.ZodOptional<z.ZodObject<{
|
|
94
|
+
cloneUrl: z.ZodString;
|
|
95
|
+
}, z.core.$strict>>;
|
|
55
96
|
}, z.core.$strict>;
|
|
56
97
|
}, z.core.$strict>;
|
|
57
|
-
export declare function shareLink(origin: string,
|
|
98
|
+
export declare function shareLink(origin: string, capability: string): string;
|
|
58
99
|
export declare function parseShareLink(value: string): {
|
|
59
100
|
origin: string;
|
|
60
|
-
shareId: string;
|
|
61
101
|
capability: string;
|
|
62
102
|
};
|
|
63
103
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,YAAY,mBAAmB,CAAC;AAE7C,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,YAAY,mBAAmB,CAAC;AAE7C,iEAAiE;AACjE,eAAO,MAAM,eAAe,QAAmB,CAAC;AAEhD,eAAO,MAAM,aAAa,WAAW,CAAC;AAEtC,eAAO,MAAM,gBAAgB,aAA0C,CAAC;AAExE,eAAO,MAAM,eAAe,aAazB,CAAC;AAEJ,kFAAkF;AAClF,wBAAgB,qBAAqB,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CA8B5D;AAED,eAAO,MAAM,yBAAyB,aAMgC,CAAC;AAMvE,kDAAkD;AAClD,eAAO,MAAM,iBAAiB;;;;;;4BAQ5B,CAAC;AAgBH,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kBAiB5B,CAAC;AAEH,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAE5D,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAE5D,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kBAG5B,CAAC;AAEH,wBAAgB,SAAS,CAAC,MAAM,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,MAAM,CAEpE;AAED,wBAAgB,cAAc,CAAC,KAAK,EAAE,MAAM;IAaxC,MAAM;IACN,UAAU;EAIb"}
|
package/dist/index.js
CHANGED
|
@@ -1,19 +1,9 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
-
export const SHARE_FORMAT = "review-share/
|
|
3
|
-
|
|
4
|
-
export const
|
|
5
|
-
export const MAX_SHARE_BYTES = 128 * 1024 * 1024;
|
|
6
|
-
export const MAX_SHARE_OBJECTS = 2048;
|
|
7
|
-
export const objectIdSchema = z.string().regex(/^[a-f0-9]{64}$/);
|
|
2
|
+
export const SHARE_FORMAT = "review-share/2";
|
|
3
|
+
/** UTF-8 bytes of a bundle's JSON, as uploaded and as stored. */
|
|
4
|
+
export const MAX_SHARE_BYTES = 16 * 1024 * 1024;
|
|
8
5
|
export const shareIdSchema = z.uuid();
|
|
9
6
|
export const capabilitySchema = z.string().regex(/^[A-Za-z0-9_-]{43}$/);
|
|
10
|
-
export const shareObjectSchema = z
|
|
11
|
-
.strictObject({
|
|
12
|
-
id: objectIdSchema,
|
|
13
|
-
size: z.number().int().min(0).max(MAX_SHARE_OBJECT_BYTES),
|
|
14
|
-
sha256: objectIdSchema,
|
|
15
|
-
})
|
|
16
|
-
.refine((object) => object.id === object.sha256, "Object ID must match its digest.");
|
|
17
7
|
export const sharePathSchema = z
|
|
18
8
|
.string()
|
|
19
9
|
.min(1)
|
|
@@ -51,68 +41,67 @@ export const gitHubRepositoryUrlSchema = z.string().refine((value) => {
|
|
|
51
41
|
return false;
|
|
52
42
|
}
|
|
53
43
|
}, "Use a canonical GitHub HTTPS repository URL without credentials.");
|
|
54
|
-
|
|
55
|
-
|
|
44
|
+
const commitSchema = z.string().regex(/^[a-f0-9]{40}([a-f0-9]{24})?$/);
|
|
45
|
+
const sideSchema = z.enum(["base", "head"]);
|
|
46
|
+
/** An excerpt is the lines a board references. */
|
|
47
|
+
export const shareSourceSchema = z.discriminatedUnion("kind", [
|
|
48
|
+
z.strictObject({
|
|
49
|
+
kind: z.literal("excerpt"),
|
|
50
|
+
file: sharePathSchema,
|
|
51
|
+
commit: commitSchema,
|
|
52
|
+
fromLine: z.number().int().positive(),
|
|
53
|
+
lines: z.array(z.string()).min(1),
|
|
54
|
+
}),
|
|
55
|
+
]);
|
|
56
|
+
const lineRangeSchema = z.strictObject({
|
|
57
|
+
side: sideSchema,
|
|
58
|
+
file: sharePathSchema,
|
|
59
|
+
fromLine: z.number().int().positive(),
|
|
60
|
+
toLine: z.number().int().positive(),
|
|
61
|
+
pins: z
|
|
62
|
+
.strictObject({
|
|
63
|
+
repositoryId: z.string(),
|
|
64
|
+
head: z.string(),
|
|
65
|
+
base: z.string().optional(),
|
|
66
|
+
})
|
|
67
|
+
.optional(),
|
|
68
|
+
});
|
|
69
|
+
export const shareBundleSchema = z.strictObject({
|
|
56
70
|
format: z.literal(SHARE_FORMAT),
|
|
57
71
|
reviewId: z.string().min(1).max(256),
|
|
58
72
|
version: z.number().int().nonnegative(),
|
|
59
73
|
title: z.string().min(1).max(4096),
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
}))
|
|
70
|
-
.max(MAX_SHARE_OBJECTS),
|
|
74
|
+
/** Validated against the document schema by the reader. */
|
|
75
|
+
snapshot: z.record(z.string(), z.unknown()),
|
|
76
|
+
images: z.record(z.string(), z.strictObject({ png: z.base64() })),
|
|
77
|
+
traces: z.record(z.string(), z.unknown()),
|
|
78
|
+
maps: z.record(z.string(), z.unknown()),
|
|
79
|
+
commits: z.array(z.unknown()),
|
|
80
|
+
/** Each reference's lines, resolved where the board was shared. */
|
|
81
|
+
selections: z.record(z.string(), z.array(lineRangeSchema)),
|
|
82
|
+
sources: z.array(shareSourceSchema),
|
|
71
83
|
repository: z
|
|
72
84
|
.strictObject({ cloneUrl: gitHubRepositoryUrlSchema })
|
|
73
85
|
.optional(),
|
|
74
|
-
})
|
|
75
|
-
.superRefine((manifest, context) => {
|
|
76
|
-
const ids = new Set(manifest.objects.map((object) => object.id));
|
|
77
|
-
const fail = (message) => context.addIssue({ code: "custom", message });
|
|
78
|
-
if (ids.size !== manifest.objects.length)
|
|
79
|
-
fail("Duplicate object ID.");
|
|
80
|
-
if (manifest.objects.reduce((size, object) => size + object.size, 0) >
|
|
81
|
-
MAX_SHARE_BYTES)
|
|
82
|
-
fail("Share exceeds the total byte limit.");
|
|
83
|
-
for (const id of [
|
|
84
|
-
manifest.snapshot,
|
|
85
|
-
manifest.presentation,
|
|
86
|
-
...manifest.resources.map((resource) => resource.object),
|
|
87
|
-
])
|
|
88
|
-
if (!ids.has(id))
|
|
89
|
-
fail("Reference to an undeclared object.");
|
|
90
|
-
if (new Set(manifest.resources.map((resource) => resource.id)).size !==
|
|
91
|
-
manifest.resources.length)
|
|
92
|
-
fail("Duplicate resource ID.");
|
|
93
|
-
for (const resource of manifest.resources)
|
|
94
|
-
if ((resource.kind === "image") !== (resource.mimeType === "image/png"))
|
|
95
|
-
fail("Resource MIME type does not match its kind.");
|
|
96
86
|
});
|
|
97
87
|
export const createShareSchema = z.strictObject({
|
|
98
88
|
requestId: z.uuid(),
|
|
99
|
-
|
|
100
|
-
sha256: objectIdSchema,
|
|
101
|
-
size: z.number().int().positive().max(MAX_SHARE_MANIFEST_BYTES),
|
|
102
|
-
}),
|
|
89
|
+
bundle: shareBundleSchema,
|
|
103
90
|
});
|
|
104
|
-
export function shareLink(origin,
|
|
105
|
-
return new URL(`/s/${
|
|
91
|
+
export function shareLink(origin, capability) {
|
|
92
|
+
return new URL(`/s/${capabilitySchema.parse(capability)}`, origin).href;
|
|
106
93
|
}
|
|
107
94
|
export function parseShareLink(value) {
|
|
108
95
|
const url = new URL(value);
|
|
109
|
-
if (url.protocol !== "https:" ||
|
|
110
|
-
|
|
111
|
-
|
|
96
|
+
if (url.protocol !== "https:" ||
|
|
97
|
+
url.username ||
|
|
98
|
+
url.password ||
|
|
99
|
+
url.hash ||
|
|
100
|
+
[...url.searchParams.keys()].some((key) => key !== "app"))
|
|
101
|
+
throw new Error("Use an HTTPS Whiteboard share link.");
|
|
112
102
|
return {
|
|
113
103
|
origin: url.origin,
|
|
114
|
-
|
|
115
|
-
capability: capabilitySchema.parse(url.hash.slice(1)),
|
|
104
|
+
capability: capabilitySchema.parse(/^\/s\/([^/]+)$/.exec(url.pathname)?.[1]),
|
|
116
105
|
};
|
|
117
106
|
}
|
|
118
107
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,MAAM,CAAC,MAAM,YAAY,GAAG,gBAAgB,CAAC;AAE7C,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,MAAM,CAAC,MAAM,YAAY,GAAG,gBAAgB,CAAC;AAE7C,iEAAiE;AACjE,MAAM,CAAC,MAAM,eAAe,GAAG,EAAE,GAAG,IAAI,GAAG,IAAI,CAAC;AAEhD,MAAM,CAAC,MAAM,aAAa,GAAG,CAAC,CAAC,IAAI,EAAE,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EzD,MAAM,IAAI,KAAK,CAAC,qCAAqC,CAAC,CAAC;IAEzD,OAAO;QACL,MAAM,EAAE,GAAG,CAAC,MAAM;QAClB,UAAU,EAAE,gBAAgB,CAAC,KAAK,CAChC,gBAAgB,CAAC,IAAI,CAAC,GAAG,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,CACzC;KACF,CAAC;AACJ,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dev.fast/review-share-protocol",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.0",
|
|
4
4
|
"description": "Portable immutable Review sharing envelope.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -23,19 +23,18 @@
|
|
|
23
23
|
"access": "public",
|
|
24
24
|
"registry": "https://registry.npmjs.org"
|
|
25
25
|
},
|
|
26
|
-
"scripts": {
|
|
27
|
-
"build": "pnpm -w exec tsc -p packages/review-share-protocol/tsconfig.build.json",
|
|
28
|
-
"test": "vitest run --config vitest.config.ts",
|
|
29
|
-
"typecheck": "pnpm -w exec tsc -p packages/review-share-protocol/tsconfig.json --noEmit",
|
|
30
|
-
"prepublishOnly": "pnpm run build && pnpm run test"
|
|
31
|
-
},
|
|
32
26
|
"dependencies": {
|
|
33
|
-
"zod": "4.
|
|
27
|
+
"zod": "4.6.5"
|
|
34
28
|
},
|
|
35
29
|
"devDependencies": {
|
|
36
30
|
"vitest": "4.1.11"
|
|
37
31
|
},
|
|
38
32
|
"engines": {
|
|
39
33
|
"node": ">=22"
|
|
34
|
+
},
|
|
35
|
+
"scripts": {
|
|
36
|
+
"build": "pnpm -w exec tsc -p packages/review-share-protocol/tsconfig.build.json",
|
|
37
|
+
"test": "vitest run --config vitest.config.ts",
|
|
38
|
+
"typecheck": "pnpm -w exec tsc -p packages/review-share-protocol/tsconfig.json --noEmit"
|
|
40
39
|
}
|
|
41
|
-
}
|
|
40
|
+
}
|