@byline/richtext-lexical 0.10.0 → 0.10.2
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/field/plugins/admonition-plugin/admonition-modal.d.ts.map +1 -1
- package/dist/field/plugins/inline-image-plugin/inline-image-modal.js +1 -1
- package/dist/field/plugins/layout-plugin/insert-layout-modal.d.ts.map +1 -1
- package/dist/field/plugins/link-plugin/link/link-modal.js +1 -1
- package/dist/richtext-field.js +1 -1
- package/package.json +4 -4
- package/src/field/plugins/admonition-plugin/admonition-modal.tsx +1 -9
- package/src/field/plugins/inline-image-plugin/inline-image-modal.tsx +5 -5
- package/src/field/plugins/layout-plugin/insert-layout-modal.tsx +1 -8
- package/src/field/plugins/link-plugin/link/link-modal.tsx +1 -1
- package/src/richtext-field.tsx +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"admonition-modal.d.ts","sourceRoot":"","sources":["../../../../src/field/plugins/admonition-plugin/admonition-modal.tsx"],"names":[],"mappings":"AAEA;;;;;;GAMG;AAEH,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;
|
|
1
|
+
{"version":3,"file":"admonition-modal.d.ts","sourceRoot":"","sources":["../../../../src/field/plugins/admonition-plugin/admonition-modal.tsx"],"names":[],"mappings":"AAEA;;;;;;GAMG;AAEH,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAO9B,OAAO,KAAK,EAAE,qBAAqB,EAAuB,MAAM,SAAS,CAAA;AAEzE,OAAO,wBAAwB,CAAA;AAe/B,wBAAgB,eAAe,CAAC,EAC9B,IAAY,EACZ,QAAQ,EACR,OAAO,EACP,IAAI,EAAE,aAAa,GACpB,EAAE,qBAAqB,GAAG,KAAK,CAAC,SAAS,CA2IzC"}
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
3
3
|
import { useMemo, useState } from "react";
|
|
4
4
|
import { getCollectionDefinition } from "@byline/core";
|
|
5
|
-
import { RelationPicker } from "@byline/ui/react/fields";
|
|
6
5
|
import { Button, Checkbox, CloseIcon, ErrorText, IconButton, Input, Label, Modal, RadioGroup, RadioGroupItem } from "@byline/ui";
|
|
6
|
+
import { RelationPicker } from "@byline/ui/react/fields";
|
|
7
7
|
import { useEditorConfig } from "../../config/editor-config-context.js";
|
|
8
8
|
import { useModalFormState } from "../../shared/useModalFormState.js";
|
|
9
9
|
import { isAltTextValid, positionOptions } from "./fields.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"insert-layout-modal.d.ts","sourceRoot":"","sources":["../../../../src/field/plugins/layout-plugin/insert-layout-modal.tsx"],"names":[],"mappings":"AAEA;;;;;;GAMG;AAEH;;;;;;GAMG;AAEH,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAA;
|
|
1
|
+
{"version":3,"file":"insert-layout-modal.d.ts","sourceRoot":"","sources":["../../../../src/field/plugins/layout-plugin/insert-layout-modal.tsx"],"names":[],"mappings":"AAEA;;;;;;GAMG;AAEH;;;;;;GAMG;AAEH,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAA;AAcnC,OAAO,2BAA2B,CAAA;AAElC,wBAAgB,iBAAiB,CAAC,EAChC,IAAY,EACZ,OAAO,EACP,QAAQ,GACT,EAAE;IACD,IAAI,EAAE,OAAO,CAAA;IACb,OAAO,EAAE,MAAM,IAAI,CAAA;IACnB,QAAQ,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAA;CACnC,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CAkDpB"}
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
3
3
|
import { useMemo, useState } from "react";
|
|
4
4
|
import { getClientConfig, getCollectionDefinition } from "@byline/core";
|
|
5
|
-
import { RelationPicker } from "@byline/ui/react/fields";
|
|
6
5
|
import { Button, Checkbox, CloseIcon, IconButton, Input, Label, Modal, RadioGroup, RadioGroupItem, Select } from "@byline/ui";
|
|
6
|
+
import { RelationPicker } from "@byline/ui/react/fields";
|
|
7
7
|
import { useEditorConfig } from "../../../config/editor-config-context.js";
|
|
8
8
|
import { useModalFormState } from "../../../shared/useModalFormState.js";
|
|
9
9
|
import { validateUrl } from "../../../utils/url.js";
|
package/dist/richtext-field.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { ErrorText, Label } from "@byline/ui";
|
|
2
3
|
import { LocaleBadge } from "@byline/ui/react/fields";
|
|
3
4
|
import { useFieldError, useFieldValue } from "@byline/ui/react/forms";
|
|
4
|
-
import { ErrorText, Label } from "@byline/ui";
|
|
5
5
|
import classnames from "classnames";
|
|
6
6
|
import { defaultEditorConfig } from "./field/config/default.js";
|
|
7
7
|
import { EditorField } from "./field/editor-field.js";
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"private": false,
|
|
4
4
|
"type": "module",
|
|
5
5
|
"license": "MPL-2.0",
|
|
6
|
-
"version": "0.10.
|
|
6
|
+
"version": "0.10.2",
|
|
7
7
|
"engines": {
|
|
8
8
|
"node": ">=20.9.0"
|
|
9
9
|
},
|
|
@@ -71,9 +71,9 @@
|
|
|
71
71
|
"npm-run-all": "^4.1.5",
|
|
72
72
|
"prism-react-renderer": "^2.4.1",
|
|
73
73
|
"react-error-boundary": "^6.1.1",
|
|
74
|
-
"@byline/client": "0.10.
|
|
75
|
-
"@byline/
|
|
76
|
-
"@byline/
|
|
74
|
+
"@byline/client": "0.10.2",
|
|
75
|
+
"@byline/ui": "0.10.2",
|
|
76
|
+
"@byline/core": "0.10.2"
|
|
77
77
|
},
|
|
78
78
|
"peerDependencies": {
|
|
79
79
|
"react": "^19.0.0",
|
|
@@ -11,15 +11,7 @@
|
|
|
11
11
|
import type React from 'react'
|
|
12
12
|
import { useEffect, useState } from 'react'
|
|
13
13
|
|
|
14
|
-
import {
|
|
15
|
-
Button,
|
|
16
|
-
CloseIcon,
|
|
17
|
-
IconButton,
|
|
18
|
-
Input,
|
|
19
|
-
Modal,
|
|
20
|
-
RadioGroup,
|
|
21
|
-
RadioGroupItem,
|
|
22
|
-
} from '@byline/ui'
|
|
14
|
+
import { Button, CloseIcon, IconButton, Input, Modal, RadioGroup, RadioGroupItem } from '@byline/ui'
|
|
23
15
|
|
|
24
16
|
import { admonitionTypeOptions, getInitialState, validateFields } from './fields'
|
|
25
17
|
import type { AdmonitionType } from '../../nodes/admonition-node/types'
|
|
@@ -13,7 +13,6 @@ import { useMemo, useState } from 'react'
|
|
|
13
13
|
|
|
14
14
|
import type { CollectionDefinition, StoredFileValue } from '@byline/core'
|
|
15
15
|
import { getCollectionDefinition } from '@byline/core'
|
|
16
|
-
import { RelationPicker } from '@byline/ui/react/fields'
|
|
17
16
|
import {
|
|
18
17
|
Button,
|
|
19
18
|
Checkbox,
|
|
@@ -26,6 +25,7 @@ import {
|
|
|
26
25
|
RadioGroup,
|
|
27
26
|
RadioGroupItem,
|
|
28
27
|
} from '@byline/ui'
|
|
28
|
+
import { RelationPicker } from '@byline/ui/react/fields'
|
|
29
29
|
|
|
30
30
|
import { useEditorConfig } from '../../config/editor-config-context'
|
|
31
31
|
import { useModalFormState } from '../../shared/useModalFormState'
|
|
@@ -161,10 +161,10 @@ export const InlineImageModal: React.FC<InlineImageModalProps> = ({
|
|
|
161
161
|
const persistedRelation = editorSettings.embedRelationsOnSave
|
|
162
162
|
? state.documentRelation
|
|
163
163
|
: {
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
164
|
+
targetDocumentId: state.documentRelation.targetDocumentId,
|
|
165
|
+
targetCollectionId: state.documentRelation.targetCollectionId,
|
|
166
|
+
targetCollectionPath: state.documentRelation.targetCollectionPath,
|
|
167
|
+
}
|
|
168
168
|
const data: InlineImageData = {
|
|
169
169
|
documentRelation: persistedRelation,
|
|
170
170
|
src: preferred?.url ?? pickedImage.storageUrl ?? '',
|
|
@@ -19,14 +19,7 @@
|
|
|
19
19
|
import type * as React from 'react'
|
|
20
20
|
import { useState } from 'react'
|
|
21
21
|
|
|
22
|
-
import {
|
|
23
|
-
Button,
|
|
24
|
-
CloseIcon,
|
|
25
|
-
IconButton,
|
|
26
|
-
Modal,
|
|
27
|
-
Select,
|
|
28
|
-
type SelectValue,
|
|
29
|
-
} from '@byline/ui'
|
|
22
|
+
import { Button, CloseIcon, IconButton, Modal, Select, type SelectValue } from '@byline/ui'
|
|
30
23
|
|
|
31
24
|
const layouts: SelectValue[] = [
|
|
32
25
|
{ label: '2 columns (equal width)', value: '1fr 1fr' },
|
|
@@ -13,7 +13,6 @@ import { useMemo, useState } from 'react'
|
|
|
13
13
|
|
|
14
14
|
import type { CollectionDefinition } from '@byline/core'
|
|
15
15
|
import { getClientConfig, getCollectionDefinition } from '@byline/core'
|
|
16
|
-
import { RelationPicker } from '@byline/ui/react/fields'
|
|
17
16
|
import {
|
|
18
17
|
Button,
|
|
19
18
|
Checkbox,
|
|
@@ -27,6 +26,7 @@ import {
|
|
|
27
26
|
Select,
|
|
28
27
|
type SelectValue,
|
|
29
28
|
} from '@byline/ui'
|
|
29
|
+
import { RelationPicker } from '@byline/ui/react/fields'
|
|
30
30
|
|
|
31
31
|
import { useEditorConfig } from '../../../config/editor-config-context'
|
|
32
32
|
import { useModalFormState } from '../../../shared/useModalFormState'
|
package/src/richtext-field.tsx
CHANGED
|
@@ -9,9 +9,9 @@
|
|
|
9
9
|
import type React from 'react'
|
|
10
10
|
|
|
11
11
|
import type { RichTextField as FieldType } from '@byline/core'
|
|
12
|
+
import { ErrorText, Label } from '@byline/ui'
|
|
12
13
|
import { LocaleBadge } from '@byline/ui/react/fields'
|
|
13
14
|
import { useFieldError, useFieldValue } from '@byline/ui/react/forms'
|
|
14
|
-
import { ErrorText, Label } from '@byline/ui'
|
|
15
15
|
import cx from 'classnames'
|
|
16
16
|
|
|
17
17
|
import { defaultEditorConfig } from './field/config/default'
|