@atcute/leaflet 1.0.2 → 1.0.3

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.
Files changed (29) hide show
  1. package/dist/lexicons/index.d.ts +4 -0
  2. package/dist/lexicons/index.js +4 -0
  3. package/dist/lexicons/index.js.map +1 -1
  4. package/dist/lexicons/types/pub/leaflet/blocks/code.d.ts +14 -0
  5. package/dist/lexicons/types/pub/leaflet/blocks/code.js +9 -0
  6. package/dist/lexicons/types/pub/leaflet/blocks/code.js.map +1 -0
  7. package/dist/lexicons/types/pub/leaflet/blocks/math.d.ts +12 -0
  8. package/dist/lexicons/types/pub/leaflet/blocks/math.js +7 -0
  9. package/dist/lexicons/types/pub/leaflet/blocks/math.js.map +1 -0
  10. package/dist/lexicons/types/pub/leaflet/pages/linearDocument.d.ts +3 -1
  11. package/dist/lexicons/types/pub/leaflet/pages/linearDocument.js +4 -0
  12. package/dist/lexicons/types/pub/leaflet/pages/linearDocument.js.map +1 -1
  13. package/dist/lexicons/types/pub/leaflet/publication.d.ts +30 -0
  14. package/dist/lexicons/types/pub/leaflet/publication.js +41 -0
  15. package/dist/lexicons/types/pub/leaflet/publication.js.map +1 -1
  16. package/dist/lexicons/types/pub/leaflet/theme/backgroundImage.d.ts +14 -0
  17. package/dist/lexicons/types/pub/leaflet/theme/backgroundImage.js +9 -0
  18. package/dist/lexicons/types/pub/leaflet/theme/backgroundImage.js.map +1 -0
  19. package/dist/lexicons/types/pub/leaflet/theme/color.d.ts +27 -0
  20. package/dist/lexicons/types/pub/leaflet/theme/color.js +17 -0
  21. package/dist/lexicons/types/pub/leaflet/theme/color.js.map +1 -0
  22. package/lib/lexicons/index.ts +4 -0
  23. package/lib/lexicons/types/pub/leaflet/blocks/code.ts +17 -0
  24. package/lib/lexicons/types/pub/leaflet/blocks/math.ts +15 -0
  25. package/lib/lexicons/types/pub/leaflet/pages/linearDocument.ts +4 -0
  26. package/lib/lexicons/types/pub/leaflet/publication.ts +52 -0
  27. package/lib/lexicons/types/pub/leaflet/theme/backgroundImage.ts +17 -0
  28. package/lib/lexicons/types/pub/leaflet/theme/color.ts +28 -0
  29. package/package.json +3 -3
@@ -1,5 +1,7 @@
1
+ export * as PubLeafletBlocksCode from './types/pub/leaflet/blocks/code.js';
1
2
  export * as PubLeafletBlocksHeader from './types/pub/leaflet/blocks/header.js';
2
3
  export * as PubLeafletBlocksImage from './types/pub/leaflet/blocks/image.js';
4
+ export * as PubLeafletBlocksMath from './types/pub/leaflet/blocks/math.js';
3
5
  export * as PubLeafletBlocksText from './types/pub/leaflet/blocks/text.js';
4
6
  export * as PubLeafletBlocksUnorderedList from './types/pub/leaflet/blocks/unorderedList.js';
5
7
  export * as PubLeafletBlocksWebsite from './types/pub/leaflet/blocks/website.js';
@@ -8,3 +10,5 @@ export * as PubLeafletGraphSubscription from './types/pub/leaflet/graph/subscrip
8
10
  export * as PubLeafletPagesLinearDocument from './types/pub/leaflet/pages/linearDocument.js';
9
11
  export * as PubLeafletPublication from './types/pub/leaflet/publication.js';
10
12
  export * as PubLeafletRichtextFacet from './types/pub/leaflet/richtext/facet.js';
13
+ export * as PubLeafletThemeBackgroundImage from './types/pub/leaflet/theme/backgroundImage.js';
14
+ export * as PubLeafletThemeColor from './types/pub/leaflet/theme/color.js';
@@ -1,5 +1,7 @@
1
+ export * as PubLeafletBlocksCode from './types/pub/leaflet/blocks/code.js';
1
2
  export * as PubLeafletBlocksHeader from './types/pub/leaflet/blocks/header.js';
2
3
  export * as PubLeafletBlocksImage from './types/pub/leaflet/blocks/image.js';
4
+ export * as PubLeafletBlocksMath from './types/pub/leaflet/blocks/math.js';
3
5
  export * as PubLeafletBlocksText from './types/pub/leaflet/blocks/text.js';
4
6
  export * as PubLeafletBlocksUnorderedList from './types/pub/leaflet/blocks/unorderedList.js';
5
7
  export * as PubLeafletBlocksWebsite from './types/pub/leaflet/blocks/website.js';
@@ -8,4 +10,6 @@ export * as PubLeafletGraphSubscription from './types/pub/leaflet/graph/subscrip
8
10
  export * as PubLeafletPagesLinearDocument from './types/pub/leaflet/pages/linearDocument.js';
9
11
  export * as PubLeafletPublication from './types/pub/leaflet/publication.js';
10
12
  export * as PubLeafletRichtextFacet from './types/pub/leaflet/richtext/facet.js';
13
+ export * as PubLeafletThemeBackgroundImage from './types/pub/leaflet/theme/backgroundImage.js';
14
+ export * as PubLeafletThemeColor from './types/pub/leaflet/theme/color.js';
11
15
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../lib/lexicons/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,sBAAsB,MAAM,sCAAsC,CAAC;AAC/E,OAAO,KAAK,qBAAqB,MAAM,qCAAqC,CAAC;AAC7E,OAAO,KAAK,oBAAoB,MAAM,oCAAoC,CAAC;AAC3E,OAAO,KAAK,6BAA6B,MAAM,6CAA6C,CAAC;AAC7F,OAAO,KAAK,uBAAuB,MAAM,uCAAuC,CAAC;AACjF,OAAO,KAAK,kBAAkB,MAAM,iCAAiC,CAAC;AACtE,OAAO,KAAK,2BAA2B,MAAM,2CAA2C,CAAC;AACzF,OAAO,KAAK,6BAA6B,MAAM,6CAA6C,CAAC;AAC7F,OAAO,KAAK,qBAAqB,MAAM,oCAAoC,CAAC;AAC5E,OAAO,KAAK,uBAAuB,MAAM,uCAAuC,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../lib/lexicons/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,oBAAoB,MAAM,oCAAoC,CAAC;AAC3E,OAAO,KAAK,sBAAsB,MAAM,sCAAsC,CAAC;AAC/E,OAAO,KAAK,qBAAqB,MAAM,qCAAqC,CAAC;AAC7E,OAAO,KAAK,oBAAoB,MAAM,oCAAoC,CAAC;AAC3E,OAAO,KAAK,oBAAoB,MAAM,oCAAoC,CAAC;AAC3E,OAAO,KAAK,6BAA6B,MAAM,6CAA6C,CAAC;AAC7F,OAAO,KAAK,uBAAuB,MAAM,uCAAuC,CAAC;AACjF,OAAO,KAAK,kBAAkB,MAAM,iCAAiC,CAAC;AACtE,OAAO,KAAK,2BAA2B,MAAM,2CAA2C,CAAC;AACzF,OAAO,KAAK,6BAA6B,MAAM,6CAA6C,CAAC;AAC7F,OAAO,KAAK,qBAAqB,MAAM,oCAAoC,CAAC;AAC5E,OAAO,KAAK,uBAAuB,MAAM,uCAAuC,CAAC;AACjF,OAAO,KAAK,8BAA8B,MAAM,8CAA8C,CAAC;AAC/F,OAAO,KAAK,oBAAoB,MAAM,oCAAoC,CAAC"}
@@ -0,0 +1,14 @@
1
+ import * as v from '@atcute/lexicons/validations';
2
+ declare const _mainSchema: v.ObjectSchema<{
3
+ $type: v.OptionalSchema<v.LiteralSchema<"pub.leaflet.blocks.code">, undefined>;
4
+ language: v.OptionalSchema<v.StringSchema<string>, undefined>;
5
+ plaintext: v.StringSchema<string>;
6
+ syntaxHighlightingTheme: v.OptionalSchema<v.StringSchema<string>, undefined>;
7
+ }>;
8
+ type main$schematype = typeof _mainSchema;
9
+ export interface mainSchema extends main$schematype {
10
+ }
11
+ export declare const mainSchema: mainSchema;
12
+ export interface Main extends v.InferInput<typeof mainSchema> {
13
+ }
14
+ export {};
@@ -0,0 +1,9 @@
1
+ import * as v from '@atcute/lexicons/validations';
2
+ const _mainSchema = /*#__PURE__*/ v.object({
3
+ $type: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.literal('pub.leaflet.blocks.code')),
4
+ language: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.string()),
5
+ plaintext: /*#__PURE__*/ v.string(),
6
+ syntaxHighlightingTheme: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.string()),
7
+ });
8
+ export const mainSchema = _mainSchema;
9
+ //# sourceMappingURL=code.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"code.js","sourceRoot":"","sources":["../../../../../../lib/lexicons/types/pub/leaflet/blocks/code.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,CAAC,MAAM,8BAA8B,CAAC;AAElD,MAAM,WAAW,GAAG,aAAa,CAAC,CAAC,CAAC,MAAM,CAAC;IAC1C,KAAK,EAAE,aAAa,CAAC,CAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,CAAC,CAAC,OAAO,CAAC,yBAAyB,CAAC,CAAC;IACnF,QAAQ,EAAE,aAAa,CAAC,CAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC;IAC5D,SAAS,EAAE,aAAa,CAAC,CAAC,CAAC,MAAM,EAAE;IACnC,uBAAuB,EAAE,aAAa,CAAC,CAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC;CAC3E,CAAC,CAAC;AAMH,MAAM,CAAC,MAAM,UAAU,GAAG,WAAyB,CAAC"}
@@ -0,0 +1,12 @@
1
+ import * as v from '@atcute/lexicons/validations';
2
+ declare const _mainSchema: v.ObjectSchema<{
3
+ $type: v.OptionalSchema<v.LiteralSchema<"pub.leaflet.blocks.math">, undefined>;
4
+ tex: v.StringSchema<string>;
5
+ }>;
6
+ type main$schematype = typeof _mainSchema;
7
+ export interface mainSchema extends main$schematype {
8
+ }
9
+ export declare const mainSchema: mainSchema;
10
+ export interface Main extends v.InferInput<typeof mainSchema> {
11
+ }
12
+ export {};
@@ -0,0 +1,7 @@
1
+ import * as v from '@atcute/lexicons/validations';
2
+ const _mainSchema = /*#__PURE__*/ v.object({
3
+ $type: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.literal('pub.leaflet.blocks.math')),
4
+ tex: /*#__PURE__*/ v.string(),
5
+ });
6
+ export const mainSchema = _mainSchema;
7
+ //# sourceMappingURL=math.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"math.js","sourceRoot":"","sources":["../../../../../../lib/lexicons/types/pub/leaflet/blocks/math.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,CAAC,MAAM,8BAA8B,CAAC;AAElD,MAAM,WAAW,GAAG,aAAa,CAAC,CAAC,CAAC,MAAM,CAAC;IAC1C,KAAK,EAAE,aAAa,CAAC,CAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,CAAC,CAAC,OAAO,CAAC,yBAAyB,CAAC,CAAC;IACnF,GAAG,EAAE,aAAa,CAAC,CAAC,CAAC,MAAM,EAAE;CAC7B,CAAC,CAAC;AAMH,MAAM,CAAC,MAAM,UAAU,GAAG,WAAyB,CAAC"}
@@ -1,13 +1,15 @@
1
1
  import * as v from '@atcute/lexicons/validations';
2
+ import * as PubLeafletBlocksCode from '../blocks/code.js';
2
3
  import * as PubLeafletBlocksHeader from '../blocks/header.js';
3
4
  import * as PubLeafletBlocksImage from '../blocks/image.js';
5
+ import * as PubLeafletBlocksMath from '../blocks/math.js';
4
6
  import * as PubLeafletBlocksText from '../blocks/text.js';
5
7
  import * as PubLeafletBlocksUnorderedList from '../blocks/unorderedList.js';
6
8
  import * as PubLeafletBlocksWebsite from '../blocks/website.js';
7
9
  declare const _blockSchema: v.ObjectSchema<{
8
10
  $type: v.OptionalSchema<v.LiteralSchema<"pub.leaflet.pages.linearDocument#block">, undefined>;
9
11
  alignment: v.OptionalSchema<v.StringSchema<(string & {}) | "#textAlignCenter" | "#textAlignLeft" | "#textAlignRight">, undefined>;
10
- readonly block: v.VariantSchema<readonly [PubLeafletBlocksHeader.mainSchema, PubLeafletBlocksImage.mainSchema, PubLeafletBlocksText.mainSchema, PubLeafletBlocksUnorderedList.mainSchema, PubLeafletBlocksWebsite.mainSchema], boolean>;
12
+ readonly block: v.VariantSchema<readonly [PubLeafletBlocksCode.mainSchema, PubLeafletBlocksHeader.mainSchema, PubLeafletBlocksImage.mainSchema, PubLeafletBlocksMath.mainSchema, PubLeafletBlocksText.mainSchema, PubLeafletBlocksUnorderedList.mainSchema, PubLeafletBlocksWebsite.mainSchema], boolean>;
11
13
  }>;
12
14
  declare const _mainSchema: v.ObjectSchema<{
13
15
  $type: v.OptionalSchema<v.LiteralSchema<"pub.leaflet.pages.linearDocument">, undefined>;
@@ -1,6 +1,8 @@
1
1
  import * as v from '@atcute/lexicons/validations';
2
+ import * as PubLeafletBlocksCode from '../blocks/code.js';
2
3
  import * as PubLeafletBlocksHeader from '../blocks/header.js';
3
4
  import * as PubLeafletBlocksImage from '../blocks/image.js';
5
+ import * as PubLeafletBlocksMath from '../blocks/math.js';
4
6
  import * as PubLeafletBlocksText from '../blocks/text.js';
5
7
  import * as PubLeafletBlocksUnorderedList from '../blocks/unorderedList.js';
6
8
  import * as PubLeafletBlocksWebsite from '../blocks/website.js';
@@ -10,8 +12,10 @@ const _blockSchema = /*#__PURE__*/ v.object({
10
12
  /*#__PURE__*/ v.string()),
11
13
  get block() {
12
14
  return /*#__PURE__*/ v.variant([
15
+ PubLeafletBlocksCode.mainSchema,
13
16
  PubLeafletBlocksHeader.mainSchema,
14
17
  PubLeafletBlocksImage.mainSchema,
18
+ PubLeafletBlocksMath.mainSchema,
15
19
  PubLeafletBlocksText.mainSchema,
16
20
  PubLeafletBlocksUnorderedList.mainSchema,
17
21
  PubLeafletBlocksWebsite.mainSchema,
@@ -1 +1 @@
1
- {"version":3,"file":"linearDocument.js","sourceRoot":"","sources":["../../../../../../lib/lexicons/types/pub/leaflet/pages/linearDocument.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,CAAC,MAAM,8BAA8B,CAAC;AAClD,OAAO,KAAK,sBAAsB,MAAM,qBAAqB,CAAC;AAC9D,OAAO,KAAK,qBAAqB,MAAM,oBAAoB,CAAC;AAC5D,OAAO,KAAK,oBAAoB,MAAM,mBAAmB,CAAC;AAC1D,OAAO,KAAK,6BAA6B,MAAM,4BAA4B,CAAC;AAC5E,OAAO,KAAK,uBAAuB,MAAM,sBAAsB,CAAC;AAEhE,MAAM,YAAY,GAAG,aAAa,CAAC,CAAC,CAAC,MAAM,CAAC;IAC3C,KAAK,EAAE,aAAa,CAAC,CAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,CAAC,CAAC,OAAO,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aAAa,CAAC,CAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,CAAC,CAAC,KAAK,CAAC,WAAW,CAAC,CAAC,CAAC;IACrE,CAAC;CACD,CAAC,CAAC;AACH,MAAM,sBAAsB,GAAG,aAAa,CAAC,CAAC,CAAC,OAAO,CAAC,kDAAkD,CAAC,CAAC;AAC3G,MAAM,oBAAoB,GAAG,aAAa,CAAC,CAAC,CAAC,OAAO,CAAC,gDAAgD,CAAC,CAAC;AACvG,MAAM,qBAAqB,GAAG,aAAa,CAAC,CAAC,CAAC,OAAO,CAAC,iDAAiD,CAAC,CAAC;AAczG,MAAM,CAAC,MAAM,WAAW,GAAG,YAA2B,CAAC;AACvD,MAAM,CAAC,MAAM,UAAU,GAAG,WAAyB,CAAC;AACpD,MAAM,CAAC,MAAM,qBAAqB,GAAG,sBAA+C,CAAC;AACrF,MAAM,CAAC,MAAM,mBAAmB,GAAG,oBAA2C,CAAC;AAC/E,MAAM,CAAC,MAAM,oBAAoB,GAAG,qBAA6C,CAAC"}
@@ -1,17 +1,47 @@
1
1
  import * as v from '@atcute/lexicons/validations';
2
+ import * as PubLeafletThemeBackgroundImage from './theme/backgroundImage.js';
3
+ import * as PubLeafletThemeColor from './theme/color.js';
2
4
  declare const _mainSchema: v.RecordSchema<v.ObjectSchema<{
3
5
  $type: v.LiteralSchema<"pub.leaflet.publication">;
4
6
  base_path: v.OptionalSchema<v.FormattedStringSchema<"uri">, undefined>;
5
7
  description: v.OptionalSchema<v.SchemaWithConstraint<v.StringSchema<string>, readonly [v.StringLengthConstraint<0, 2000>]>, undefined>;
6
8
  icon: v.OptionalSchema<v.BlobSchema, undefined>;
7
9
  name: v.SchemaWithConstraint<v.StringSchema<string>, readonly [v.StringLengthConstraint<0, 2000>]>;
10
+ readonly preferences: v.OptionalSchema<preferencesSchema, undefined>;
11
+ readonly theme: v.OptionalSchema<themeSchema, undefined>;
8
12
  }>, v.FormattedStringSchema<"tid">>;
13
+ declare const _preferencesSchema: v.ObjectSchema<{
14
+ $type: v.OptionalSchema<v.LiteralSchema<"pub.leaflet.publication#preferences">, undefined>;
15
+ showInDiscover: v.OptionalSchema<v.BooleanSchema, true>;
16
+ }>;
17
+ declare const _themeSchema: v.ObjectSchema<{
18
+ $type: v.OptionalSchema<v.LiteralSchema<"pub.leaflet.publication#theme">, undefined>;
19
+ readonly accentBackground: v.OptionalSchema<v.VariantSchema<readonly [PubLeafletThemeColor.rgbSchema, PubLeafletThemeColor.rgbaSchema], boolean>, undefined>;
20
+ readonly accentText: v.OptionalSchema<v.VariantSchema<readonly [PubLeafletThemeColor.rgbSchema, PubLeafletThemeColor.rgbaSchema], boolean>, undefined>;
21
+ readonly backgroundColor: v.OptionalSchema<v.VariantSchema<readonly [PubLeafletThemeColor.rgbSchema, PubLeafletThemeColor.rgbaSchema], boolean>, undefined>;
22
+ readonly backgroundImage: v.OptionalSchema<PubLeafletThemeBackgroundImage.mainSchema, undefined>;
23
+ readonly pageBackground: v.OptionalSchema<v.VariantSchema<readonly [PubLeafletThemeColor.rgbSchema, PubLeafletThemeColor.rgbaSchema], boolean>, undefined>;
24
+ readonly primary: v.OptionalSchema<v.VariantSchema<readonly [PubLeafletThemeColor.rgbSchema, PubLeafletThemeColor.rgbaSchema], boolean>, undefined>;
25
+ showPageBackground: v.OptionalSchema<v.BooleanSchema, false>;
26
+ }>;
9
27
  type main$schematype = typeof _mainSchema;
28
+ type preferences$schematype = typeof _preferencesSchema;
29
+ type theme$schematype = typeof _themeSchema;
10
30
  export interface mainSchema extends main$schematype {
11
31
  }
32
+ export interface preferencesSchema extends preferences$schematype {
33
+ }
34
+ export interface themeSchema extends theme$schematype {
35
+ }
12
36
  export declare const mainSchema: mainSchema;
37
+ export declare const preferencesSchema: preferencesSchema;
38
+ export declare const themeSchema: themeSchema;
13
39
  export interface Main extends v.InferInput<typeof mainSchema> {
14
40
  }
41
+ export interface Preferences extends v.InferInput<typeof preferencesSchema> {
42
+ }
43
+ export interface Theme extends v.InferInput<typeof themeSchema> {
44
+ }
15
45
  declare module '@atcute/lexicons/ambient' {
16
46
  interface Records {
17
47
  'pub.leaflet.publication': mainSchema;
@@ -1,4 +1,6 @@
1
1
  import * as v from '@atcute/lexicons/validations';
2
+ import * as PubLeafletThemeBackgroundImage from './theme/backgroundImage.js';
3
+ import * as PubLeafletThemeColor from './theme/color.js';
2
4
  const _mainSchema = /*#__PURE__*/ v.record(
3
5
  /*#__PURE__*/ v.tidString(),
4
6
  /*#__PURE__*/ v.object({
@@ -8,6 +10,45 @@ const _mainSchema = /*#__PURE__*/ v.record(
8
10
  /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.string(), [/*#__PURE__*/ v.stringLength(0, 2000)])),
9
11
  icon: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.blob()),
10
12
  name: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.string(), [/*#__PURE__*/ v.stringLength(0, 2000)]),
13
+ get preferences() {
14
+ return /*#__PURE__*/ v.optional(preferencesSchema);
15
+ },
16
+ get theme() {
17
+ return /*#__PURE__*/ v.optional(themeSchema);
18
+ },
11
19
  }));
20
+ const _preferencesSchema = /*#__PURE__*/ v.object({
21
+ $type: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.literal('pub.leaflet.publication#preferences')),
22
+ showInDiscover: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.boolean(), true),
23
+ });
24
+ const _themeSchema = /*#__PURE__*/ v.object({
25
+ $type: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.literal('pub.leaflet.publication#theme')),
26
+ get accentBackground() {
27
+ return /*#__PURE__*/ v.optional(
28
+ /*#__PURE__*/ v.variant([PubLeafletThemeColor.rgbSchema, PubLeafletThemeColor.rgbaSchema]));
29
+ },
30
+ get accentText() {
31
+ return /*#__PURE__*/ v.optional(
32
+ /*#__PURE__*/ v.variant([PubLeafletThemeColor.rgbSchema, PubLeafletThemeColor.rgbaSchema]));
33
+ },
34
+ get backgroundColor() {
35
+ return /*#__PURE__*/ v.optional(
36
+ /*#__PURE__*/ v.variant([PubLeafletThemeColor.rgbSchema, PubLeafletThemeColor.rgbaSchema]));
37
+ },
38
+ get backgroundImage() {
39
+ return /*#__PURE__*/ v.optional(PubLeafletThemeBackgroundImage.mainSchema);
40
+ },
41
+ get pageBackground() {
42
+ return /*#__PURE__*/ v.optional(
43
+ /*#__PURE__*/ v.variant([PubLeafletThemeColor.rgbSchema, PubLeafletThemeColor.rgbaSchema]));
44
+ },
45
+ get primary() {
46
+ return /*#__PURE__*/ v.optional(
47
+ /*#__PURE__*/ v.variant([PubLeafletThemeColor.rgbSchema, PubLeafletThemeColor.rgbaSchema]));
48
+ },
49
+ showPageBackground: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.boolean(), false),
50
+ });
12
51
  export const mainSchema = _mainSchema;
52
+ export const preferencesSchema = _preferencesSchema;
53
+ export const themeSchema = _themeSchema;
13
54
  //# sourceMappingURL=publication.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"publication.js","sourceRoot":"","sources":["../../../../../lib/lexicons/types/pub/leaflet/publication.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,CAAC,MAAM,8BAA8B,CAAC;AAGlD,MAAM,WAAW,GAAG,aAAa,CAAC,CAAC,CAAC,MAAM;AACzC,aAAa,CAAC,CAAC,CAAC,SAAS,EAAE;AAC3B,aAAa,CAAC,CAAC,CAAC,MAAM,CAAC;IACtB,KAAK,EAAE,aAAa,CAAC,CAAC,CAAC,OAAO,CAAC,yBAAyB,CAAC;IACzD,SAAS,EAAE,aAAa,CAAC,CAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,CAAC,CAAC,gBAAgB,EAAE,CAAC;IACvE,WAAW,EAAE,aAAa,CAAC,CAAC,CAAC,QAAQ;IACpC,aAAa,CAAC,CAAC,CAAC,SAAS,CAAC,aAAa,CAAC,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,aAAa,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,EAAE,IAAI,CAAC,C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C;IACD,IAAI,eAAe;QAClB,OAAO,aAAa,CAAC,CAAC,CAAC,QAAQ;QAC9B,aAAa,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,oBAAoB,CAAC,SAAS,EAAE,oBAAoB,CAAC,UAAU,CAAC,CAAC,CAC1F,CAAC;IACH,CAAC;IACD,IAAI,eAAe;QAClB,OAAO,aAAa,CAAC,CAAC,CAAC,QAAQ,CAAC,8BAA8B,CAAC,UAAU,CAAC,CAAC;IAC5E,CAAC;IACD,IAAI,cAAc;QACjB,OAAO,aAAa,CAAC,CAAC,CAAC,QAAQ;QAC9B,aAAa,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,oBAAoB,CAAC,SAAS,EAAE,oBAAoB,CAAC,UAAU,CAAC,CAAC,CAC1F,CAAC;IACH,CAAC;IACD,IAAI,OAAO;QACV,OAAO,aAAa,CAAC,CAAC,CAAC,QAAQ;QAC9B,aAAa,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,oBAAoB,CAAC,SAAS,EAAE,oBAAoB,CAAC,UAAU,CAAC,CAAC,CAC1F,CAAC;IACH,CAAC;IACD,kBAAkB,EAAE,aAAa,CAAC,CAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,CAAC,CAAC,OAAO,EAAE,EAAE,KAAK,CAAC;CAC9E,CAAC,CAAC;AAUH,MAAM,CAAC,MAAM,UAAU,GAAG,WAAyB,CAAC;AACpD,MAAM,CAAC,MAAM,iBAAiB,GAAG,kBAAuC,CAAC;AACzE,MAAM,CAAC,MAAM,WAAW,GAAG,YAA2B,CAAC"}
@@ -0,0 +1,14 @@
1
+ import * as v from '@atcute/lexicons/validations';
2
+ declare const _mainSchema: v.ObjectSchema<{
3
+ $type: v.OptionalSchema<v.LiteralSchema<"pub.leaflet.theme.backgroundImage">, undefined>;
4
+ image: v.BlobSchema;
5
+ repeat: v.OptionalSchema<v.BooleanSchema, undefined>;
6
+ width: v.OptionalSchema<v.IntegerSchema, undefined>;
7
+ }>;
8
+ type main$schematype = typeof _mainSchema;
9
+ export interface mainSchema extends main$schematype {
10
+ }
11
+ export declare const mainSchema: mainSchema;
12
+ export interface Main extends v.InferInput<typeof mainSchema> {
13
+ }
14
+ export {};
@@ -0,0 +1,9 @@
1
+ import * as v from '@atcute/lexicons/validations';
2
+ const _mainSchema = /*#__PURE__*/ v.object({
3
+ $type: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.literal('pub.leaflet.theme.backgroundImage')),
4
+ image: /*#__PURE__*/ v.blob(),
5
+ repeat: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.boolean()),
6
+ width: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.integer()),
7
+ });
8
+ export const mainSchema = _mainSchema;
9
+ //# sourceMappingURL=backgroundImage.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"backgroundImage.js","sourceRoot":"","sources":["../../../../../../lib/lexicons/types/pub/leaflet/theme/backgroundImage.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,CAAC,MAAM,8BAA8B,CAAC;AAElD,MAAM,WAAW,GAAG,aAAa,CAAC,CAAC,CAAC,MAAM,CAAC;IAC1C,KAAK,EAAE,aAAa,CAAC,CAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,CAAC,CAAC,OAAO,CAAC,mCAAmC,CAAC,CAAC;IAC7F,KAAK,EAAE,aAAa,CAAC,CAAC,CAAC,IAAI,EAAE;IAC7B,MAAM,EAAE,aAAa,CAAC,CAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,CAAC,CAAC,OAAO,EAAE,CAAC;IAC3D,KAAK,EAAE,aAAa,CAAC,CAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,CAAC,CAAC,OAAO,EAAE,CAAC;CAC1D,CAAC,CAAC;AAMH,MAAM,CAAC,MAAM,UAAU,GAAG,WAAyB,CAAC"}
@@ -0,0 +1,27 @@
1
+ import * as v from '@atcute/lexicons/validations';
2
+ declare const _rgbSchema: v.ObjectSchema<{
3
+ $type: v.OptionalSchema<v.LiteralSchema<"pub.leaflet.theme.color#rgb">, undefined>;
4
+ b: v.SchemaWithConstraint<v.IntegerSchema, readonly [v.IntegerRangeConstraint<0, 255>]>;
5
+ g: v.SchemaWithConstraint<v.IntegerSchema, readonly [v.IntegerRangeConstraint<0, 255>]>;
6
+ r: v.SchemaWithConstraint<v.IntegerSchema, readonly [v.IntegerRangeConstraint<0, 255>]>;
7
+ }>;
8
+ declare const _rgbaSchema: v.ObjectSchema<{
9
+ $type: v.OptionalSchema<v.LiteralSchema<"pub.leaflet.theme.color#rgba">, undefined>;
10
+ a: v.SchemaWithConstraint<v.IntegerSchema, readonly [v.IntegerRangeConstraint<0, 100>]>;
11
+ b: v.SchemaWithConstraint<v.IntegerSchema, readonly [v.IntegerRangeConstraint<0, 255>]>;
12
+ g: v.SchemaWithConstraint<v.IntegerSchema, readonly [v.IntegerRangeConstraint<0, 255>]>;
13
+ r: v.SchemaWithConstraint<v.IntegerSchema, readonly [v.IntegerRangeConstraint<0, 255>]>;
14
+ }>;
15
+ type rgb$schematype = typeof _rgbSchema;
16
+ type rgba$schematype = typeof _rgbaSchema;
17
+ export interface rgbSchema extends rgb$schematype {
18
+ }
19
+ export interface rgbaSchema extends rgba$schematype {
20
+ }
21
+ export declare const rgbSchema: rgbSchema;
22
+ export declare const rgbaSchema: rgbaSchema;
23
+ export interface Rgb extends v.InferInput<typeof rgbSchema> {
24
+ }
25
+ export interface Rgba extends v.InferInput<typeof rgbaSchema> {
26
+ }
27
+ export {};
@@ -0,0 +1,17 @@
1
+ import * as v from '@atcute/lexicons/validations';
2
+ const _rgbSchema = /*#__PURE__*/ v.object({
3
+ $type: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.literal('pub.leaflet.theme.color#rgb')),
4
+ b: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.integer(), [/*#__PURE__*/ v.integerRange(0, 255)]),
5
+ g: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.integer(), [/*#__PURE__*/ v.integerRange(0, 255)]),
6
+ r: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.integer(), [/*#__PURE__*/ v.integerRange(0, 255)]),
7
+ });
8
+ const _rgbaSchema = /*#__PURE__*/ v.object({
9
+ $type: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.literal('pub.leaflet.theme.color#rgba')),
10
+ a: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.integer(), [/*#__PURE__*/ v.integerRange(0, 100)]),
11
+ b: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.integer(), [/*#__PURE__*/ v.integerRange(0, 255)]),
12
+ g: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.integer(), [/*#__PURE__*/ v.integerRange(0, 255)]),
13
+ r: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.integer(), [/*#__PURE__*/ v.integerRange(0, 255)]),
14
+ });
15
+ export const rgbSchema = _rgbSchema;
16
+ export const rgbaSchema = _rgbaSchema;
17
+ //# sourceMappingURL=color.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"color.js","sourceRoot":"","sources":["../../../../../../lib/lexicons/types/pub/leaflet/theme/color.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,CAAC,MAAM,8BAA8B,CAAC;AAElD,MAAM,UAAU,GAAG,aAAa,CAAC,CAAC,CAAC,MAAM,CAAC;IACzC,KAAK,EAAE,aAAa,CAAC,CAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,CAAC,CAAC,OAAO,CAAC,6BAA6B,CAAC,CAAC;IACvF,CAAC,EAAE,aAAa,CAAC,CAAC,CAAC,SAAS,CAAC,aAAa,CAAC,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,aAAa,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC,CAAC;IAC/F,CAAC,EAAE,aAAa,CAAC,CAAC,CAAC,SAAS,CAAC,aAAa,CAAC,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,aAAa,CAAC,CAAC,C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,CAAC"}
@@ -1,5 +1,7 @@
1
+ export * as PubLeafletBlocksCode from './types/pub/leaflet/blocks/code.js';
1
2
  export * as PubLeafletBlocksHeader from './types/pub/leaflet/blocks/header.js';
2
3
  export * as PubLeafletBlocksImage from './types/pub/leaflet/blocks/image.js';
4
+ export * as PubLeafletBlocksMath from './types/pub/leaflet/blocks/math.js';
3
5
  export * as PubLeafletBlocksText from './types/pub/leaflet/blocks/text.js';
4
6
  export * as PubLeafletBlocksUnorderedList from './types/pub/leaflet/blocks/unorderedList.js';
5
7
  export * as PubLeafletBlocksWebsite from './types/pub/leaflet/blocks/website.js';
@@ -8,3 +10,5 @@ export * as PubLeafletGraphSubscription from './types/pub/leaflet/graph/subscrip
8
10
  export * as PubLeafletPagesLinearDocument from './types/pub/leaflet/pages/linearDocument.js';
9
11
  export * as PubLeafletPublication from './types/pub/leaflet/publication.js';
10
12
  export * as PubLeafletRichtextFacet from './types/pub/leaflet/richtext/facet.js';
13
+ export * as PubLeafletThemeBackgroundImage from './types/pub/leaflet/theme/backgroundImage.js';
14
+ export * as PubLeafletThemeColor from './types/pub/leaflet/theme/color.js';
@@ -0,0 +1,17 @@
1
+ import type {} from '@atcute/lexicons';
2
+ import * as v from '@atcute/lexicons/validations';
3
+
4
+ const _mainSchema = /*#__PURE__*/ v.object({
5
+ $type: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.literal('pub.leaflet.blocks.code')),
6
+ language: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.string()),
7
+ plaintext: /*#__PURE__*/ v.string(),
8
+ syntaxHighlightingTheme: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.string()),
9
+ });
10
+
11
+ type main$schematype = typeof _mainSchema;
12
+
13
+ export interface mainSchema extends main$schematype {}
14
+
15
+ export const mainSchema = _mainSchema as mainSchema;
16
+
17
+ export interface Main extends v.InferInput<typeof mainSchema> {}
@@ -0,0 +1,15 @@
1
+ import type {} from '@atcute/lexicons';
2
+ import * as v from '@atcute/lexicons/validations';
3
+
4
+ const _mainSchema = /*#__PURE__*/ v.object({
5
+ $type: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.literal('pub.leaflet.blocks.math')),
6
+ tex: /*#__PURE__*/ v.string(),
7
+ });
8
+
9
+ type main$schematype = typeof _mainSchema;
10
+
11
+ export interface mainSchema extends main$schematype {}
12
+
13
+ export const mainSchema = _mainSchema as mainSchema;
14
+
15
+ export interface Main extends v.InferInput<typeof mainSchema> {}
@@ -1,7 +1,9 @@
1
1
  import type {} from '@atcute/lexicons';
2
2
  import * as v from '@atcute/lexicons/validations';
3
+ import * as PubLeafletBlocksCode from '../blocks/code.js';
3
4
  import * as PubLeafletBlocksHeader from '../blocks/header.js';
4
5
  import * as PubLeafletBlocksImage from '../blocks/image.js';
6
+ import * as PubLeafletBlocksMath from '../blocks/math.js';
5
7
  import * as PubLeafletBlocksText from '../blocks/text.js';
6
8
  import * as PubLeafletBlocksUnorderedList from '../blocks/unorderedList.js';
7
9
  import * as PubLeafletBlocksWebsite from '../blocks/website.js';
@@ -13,8 +15,10 @@ const _blockSchema = /*#__PURE__*/ v.object({
13
15
  ),
14
16
  get block() {
15
17
  return /*#__PURE__*/ v.variant([
18
+ PubLeafletBlocksCode.mainSchema,
16
19
  PubLeafletBlocksHeader.mainSchema,
17
20
  PubLeafletBlocksImage.mainSchema,
21
+ PubLeafletBlocksMath.mainSchema,
18
22
  PubLeafletBlocksText.mainSchema,
19
23
  PubLeafletBlocksUnorderedList.mainSchema,
20
24
  PubLeafletBlocksWebsite.mainSchema,
@@ -1,6 +1,8 @@
1
1
  import type {} from '@atcute/lexicons';
2
2
  import * as v from '@atcute/lexicons/validations';
3
3
  import type {} from '@atcute/lexicons/ambient';
4
+ import * as PubLeafletThemeBackgroundImage from './theme/backgroundImage.js';
5
+ import * as PubLeafletThemeColor from './theme/color.js';
4
6
 
5
7
  const _mainSchema = /*#__PURE__*/ v.record(
6
8
  /*#__PURE__*/ v.tidString(),
@@ -12,16 +14,66 @@ const _mainSchema = /*#__PURE__*/ v.record(
12
14
  ),
13
15
  icon: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.blob()),
14
16
  name: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.string(), [/*#__PURE__*/ v.stringLength(0, 2000)]),
17
+ get preferences() {
18
+ return /*#__PURE__*/ v.optional(preferencesSchema);
19
+ },
20
+ get theme() {
21
+ return /*#__PURE__*/ v.optional(themeSchema);
22
+ },
15
23
  }),
16
24
  );
25
+ const _preferencesSchema = /*#__PURE__*/ v.object({
26
+ $type: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.literal('pub.leaflet.publication#preferences')),
27
+ showInDiscover: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.boolean(), true),
28
+ });
29
+ const _themeSchema = /*#__PURE__*/ v.object({
30
+ $type: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.literal('pub.leaflet.publication#theme')),
31
+ get accentBackground() {
32
+ return /*#__PURE__*/ v.optional(
33
+ /*#__PURE__*/ v.variant([PubLeafletThemeColor.rgbSchema, PubLeafletThemeColor.rgbaSchema]),
34
+ );
35
+ },
36
+ get accentText() {
37
+ return /*#__PURE__*/ v.optional(
38
+ /*#__PURE__*/ v.variant([PubLeafletThemeColor.rgbSchema, PubLeafletThemeColor.rgbaSchema]),
39
+ );
40
+ },
41
+ get backgroundColor() {
42
+ return /*#__PURE__*/ v.optional(
43
+ /*#__PURE__*/ v.variant([PubLeafletThemeColor.rgbSchema, PubLeafletThemeColor.rgbaSchema]),
44
+ );
45
+ },
46
+ get backgroundImage() {
47
+ return /*#__PURE__*/ v.optional(PubLeafletThemeBackgroundImage.mainSchema);
48
+ },
49
+ get pageBackground() {
50
+ return /*#__PURE__*/ v.optional(
51
+ /*#__PURE__*/ v.variant([PubLeafletThemeColor.rgbSchema, PubLeafletThemeColor.rgbaSchema]),
52
+ );
53
+ },
54
+ get primary() {
55
+ return /*#__PURE__*/ v.optional(
56
+ /*#__PURE__*/ v.variant([PubLeafletThemeColor.rgbSchema, PubLeafletThemeColor.rgbaSchema]),
57
+ );
58
+ },
59
+ showPageBackground: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.boolean(), false),
60
+ });
17
61
 
18
62
  type main$schematype = typeof _mainSchema;
63
+ type preferences$schematype = typeof _preferencesSchema;
64
+ type theme$schematype = typeof _themeSchema;
19
65
 
20
66
  export interface mainSchema extends main$schematype {}
67
+ export interface preferencesSchema extends preferences$schematype {}
68
+ export interface themeSchema extends theme$schematype {}
21
69
 
22
70
  export const mainSchema = _mainSchema as mainSchema;
71
+ export const preferencesSchema = _preferencesSchema as preferencesSchema;
72
+ export const themeSchema = _themeSchema as themeSchema;
23
73
 
24
74
  export interface Main extends v.InferInput<typeof mainSchema> {}
75
+ export interface Preferences extends v.InferInput<typeof preferencesSchema> {}
76
+ export interface Theme extends v.InferInput<typeof themeSchema> {}
25
77
 
26
78
  declare module '@atcute/lexicons/ambient' {
27
79
  interface Records {
@@ -0,0 +1,17 @@
1
+ import type {} from '@atcute/lexicons';
2
+ import * as v from '@atcute/lexicons/validations';
3
+
4
+ const _mainSchema = /*#__PURE__*/ v.object({
5
+ $type: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.literal('pub.leaflet.theme.backgroundImage')),
6
+ image: /*#__PURE__*/ v.blob(),
7
+ repeat: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.boolean()),
8
+ width: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.integer()),
9
+ });
10
+
11
+ type main$schematype = typeof _mainSchema;
12
+
13
+ export interface mainSchema extends main$schematype {}
14
+
15
+ export const mainSchema = _mainSchema as mainSchema;
16
+
17
+ export interface Main extends v.InferInput<typeof mainSchema> {}
@@ -0,0 +1,28 @@
1
+ import type {} from '@atcute/lexicons';
2
+ import * as v from '@atcute/lexicons/validations';
3
+
4
+ const _rgbSchema = /*#__PURE__*/ v.object({
5
+ $type: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.literal('pub.leaflet.theme.color#rgb')),
6
+ b: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.integer(), [/*#__PURE__*/ v.integerRange(0, 255)]),
7
+ g: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.integer(), [/*#__PURE__*/ v.integerRange(0, 255)]),
8
+ r: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.integer(), [/*#__PURE__*/ v.integerRange(0, 255)]),
9
+ });
10
+ const _rgbaSchema = /*#__PURE__*/ v.object({
11
+ $type: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.literal('pub.leaflet.theme.color#rgba')),
12
+ a: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.integer(), [/*#__PURE__*/ v.integerRange(0, 100)]),
13
+ b: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.integer(), [/*#__PURE__*/ v.integerRange(0, 255)]),
14
+ g: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.integer(), [/*#__PURE__*/ v.integerRange(0, 255)]),
15
+ r: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.integer(), [/*#__PURE__*/ v.integerRange(0, 255)]),
16
+ });
17
+
18
+ type rgb$schematype = typeof _rgbSchema;
19
+ type rgba$schematype = typeof _rgbaSchema;
20
+
21
+ export interface rgbSchema extends rgb$schematype {}
22
+ export interface rgbaSchema extends rgba$schematype {}
23
+
24
+ export const rgbSchema = _rgbSchema as rgbSchema;
25
+ export const rgbaSchema = _rgbaSchema as rgbaSchema;
26
+
27
+ export interface Rgb extends v.InferInput<typeof rgbSchema> {}
28
+ export interface Rgba extends v.InferInput<typeof rgbaSchema> {}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "type": "module",
3
3
  "name": "@atcute/leaflet",
4
- "version": "1.0.2",
4
+ "version": "1.0.3",
5
5
  "description": "Leaflet (pub.leaflet.*) schema definitions",
6
6
  "keywords": [
7
7
  "atcute",
@@ -24,8 +24,8 @@
24
24
  "./types/*": "./dist/lexicons/types/pub/leaflet/*.js"
25
25
  },
26
26
  "dependencies": {
27
- "@atcute/atproto": "^3.1.0",
28
- "@atcute/lexicons": "^1.1.0"
27
+ "@atcute/lexicons": "^1.1.0",
28
+ "@atcute/atproto": "^3.1.1"
29
29
  },
30
30
  "devDependencies": {
31
31
  "@atcute/leaflet": "file:",