@seed-hypermedia/client 0.0.39 → 0.0.41
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/{chunk-PY2VJAIE.mjs → chunk-2E3HWHST.mjs} +26 -0
- package/dist/editor-types.d.ts +2 -0
- package/dist/hm-types.d.ts +7306 -2159
- package/dist/hm-types.mjs +9 -1
- package/dist/index.mjs +8 -6
- package/package.json +1 -1
package/dist/hm-types.mjs
CHANGED
|
@@ -114,6 +114,10 @@ import {
|
|
|
114
114
|
HMPublishBlobsInputSchema,
|
|
115
115
|
HMPublishBlobsOutputSchema,
|
|
116
116
|
HMPublishBlobsRequestSchema,
|
|
117
|
+
HMQueryBlockInputSchema,
|
|
118
|
+
HMQueryBlockItemSummarySchema,
|
|
119
|
+
HMQueryBlockPayloadSchema,
|
|
120
|
+
HMQueryBlockRequestSchema,
|
|
117
121
|
HMQueryInclusionSchema,
|
|
118
122
|
HMQueryRequestSchema,
|
|
119
123
|
HMQueryResultSchema,
|
|
@@ -172,7 +176,7 @@ import {
|
|
|
172
176
|
toNumber,
|
|
173
177
|
unpackHmId,
|
|
174
178
|
unpackedHmIdSchema
|
|
175
|
-
} from "./chunk-
|
|
179
|
+
} from "./chunk-2E3HWHST.mjs";
|
|
176
180
|
export {
|
|
177
181
|
BackgroundColorAnnotationSchema,
|
|
178
182
|
BlockRangeSchema,
|
|
@@ -289,6 +293,10 @@ export {
|
|
|
289
293
|
HMPublishBlobsInputSchema,
|
|
290
294
|
HMPublishBlobsOutputSchema,
|
|
291
295
|
HMPublishBlobsRequestSchema,
|
|
296
|
+
HMQueryBlockInputSchema,
|
|
297
|
+
HMQueryBlockItemSummarySchema,
|
|
298
|
+
HMQueryBlockPayloadSchema,
|
|
299
|
+
HMQueryBlockRequestSchema,
|
|
292
300
|
HMQueryInclusionSchema,
|
|
293
301
|
HMQueryRequestSchema,
|
|
294
302
|
HMQueryResultSchema,
|
package/dist/index.mjs
CHANGED
|
@@ -17,7 +17,7 @@ import {
|
|
|
17
17
|
serializeBlockRange,
|
|
18
18
|
toNumber,
|
|
19
19
|
unpackHmId
|
|
20
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-2E3HWHST.mjs";
|
|
21
21
|
|
|
22
22
|
// src/capability.ts
|
|
23
23
|
import { encode as cborEncode2 } from "@ipld/dag-cbor";
|
|
@@ -4007,7 +4007,7 @@ function hmBlockToEditorBlock(block) {
|
|
|
4007
4007
|
i += codeUnits;
|
|
4008
4008
|
}
|
|
4009
4009
|
function startLeaf(posAnnotations) {
|
|
4010
|
-
var _a2, _b2
|
|
4010
|
+
var _a2, _b2;
|
|
4011
4011
|
const newLeaf = {
|
|
4012
4012
|
type: "text",
|
|
4013
4013
|
text: "",
|
|
@@ -4034,28 +4034,30 @@ function hmBlockToEditorBlock(block) {
|
|
|
4034
4034
|
newLeaf.styles[styleKey] = true;
|
|
4035
4035
|
}
|
|
4036
4036
|
if (annotationData.type === "TextColor") {
|
|
4037
|
-
const
|
|
4037
|
+
const attrs = annotationData.attributes;
|
|
4038
|
+
const color = (attrs == null ? void 0 : attrs.value) ?? (attrs == null ? void 0 : attrs.color);
|
|
4038
4039
|
if (typeof color === "string" && color) {
|
|
4039
4040
|
;
|
|
4040
4041
|
newLeaf.styles.textColor = color;
|
|
4041
4042
|
}
|
|
4042
4043
|
}
|
|
4043
4044
|
if (annotationData.type === "BackgroundColor") {
|
|
4044
|
-
const
|
|
4045
|
+
const attrs = annotationData.attributes;
|
|
4046
|
+
const color = (attrs == null ? void 0 : attrs.value) ?? (attrs == null ? void 0 : attrs.color);
|
|
4045
4047
|
if (typeof color === "string" && color) {
|
|
4046
4048
|
;
|
|
4047
4049
|
newLeaf.styles.backgroundColor = color;
|
|
4048
4050
|
}
|
|
4049
4051
|
}
|
|
4050
4052
|
if (annotationData.type === "TextSize") {
|
|
4051
|
-
const size = (
|
|
4053
|
+
const size = (_a2 = annotationData.attributes) == null ? void 0 : _a2.value;
|
|
4052
4054
|
if (typeof size === "string" && size) {
|
|
4053
4055
|
;
|
|
4054
4056
|
newLeaf.styles.textSize = size;
|
|
4055
4057
|
}
|
|
4056
4058
|
}
|
|
4057
4059
|
if (annotationData.type === "TextFamily") {
|
|
4058
|
-
const family = (
|
|
4060
|
+
const family = (_b2 = annotationData.attributes) == null ? void 0 : _b2.value;
|
|
4059
4061
|
if (typeof family === "string" && family) {
|
|
4060
4062
|
;
|
|
4061
4063
|
newLeaf.styles.textFamily = family;
|