friendsofagape / usfm-editor Goto Github PK
View Code? Open in Web Editor NEWA React component for WYSIWYG USFM editing.
Home Page: https://friendsofagape.github.io/usfm-editor/
License: MIT License
A React component for WYSIWYG USFM editing.
Home Page: https://friendsofagape.github.io/usfm-editor/
License: MIT License
In importing usfm-editor into a react app, there is a node path error. Am I missing something?
Imported is as follows in react project at 'C:/projects/react-app/':
function Editor() {
const usfmString = `\\c 1
\\v 1 This is the first verse.`;
const setUsfmString = (editedUsfm) => {console.log(editedUsfm)};
return (
<UsfmEditor usfmString={usfmString} onChange={setUsfmString}></UsfmEditor>
);
}
export default Editor;
Initial part of error message:
point
C:/projects/src/interfaces/editor.ts:903
900 | const node = Node.get(editor, path)
901 |
902 | if (!Text.isText(node)) {
> 903 | throw new Error(
| ^ 904 | `Cannot get the ${edge} point in the node at path [${at}] because it has no ${edge} text node.`
905 | )
906 | }
Next.js
0.8.0
Some time while I navigate through books and get the output of usfm. The output usfm string
has an id of the previous book and hence ends up in the wrong usfm output file for that particular book.
Surprisingly the book fetch on navigation works fine without any errors
Next.js
14.8.0
0.8.0-SNAPSHOT.5
https://github.com/Ashersam/editor-demo/blob/master/src/App.js#L25
We have updated our package to the latest from 0.8.0-SNAPSHOT.2
since we have use cases of single or multiple chapters render based on screen space and toolbar separation.
I have started implementing ChapterSelect based render and wrapped it up with the withToolBar.js
component.
Things are working except whenever I update the state on the following callbacks (onChange
, onIdentificationChange
, onVerseChange
) whatever changes I do just rerenders multiple times and comes to the original loaded state, sometimes it ends in an infinite loop. And most of these things works as expected in 0.8.0-SNAPSHOT.2
.
Next.js
0.8.0-SNAPSHOT.6
https://github.com/Ashersam/UsfmEditorNextJs/blob/main/pages/index.js
https://ashersam.github.io/UsfmEditorNextJs/
I see there's a joint verse feature for usfm-editor
editor and works well in create-react
boilerplate. But that's not happening in nextJs based application. Just getting the following prop warning on the console when we click on a verse number.
react_devtools_backend.js:2560 Warning: Failed prop type: The prop `icon` is marked as required in `JoinWithPreviousVerseButton`, but its value is `undefined`.
at JoinWithPreviousVerseButton (http://localhost:3000/_next/static/chunks/pages/index.js?ts=1624422465897:8531:26)
at VerseJoinUnjoinSubmenu (http://localhost:3000/_next/static/chunks/pages/index.js?ts=1624422465897:7757:5)
at ul
react_devtools_backend.js:2560 Warning: Failed prop type: The prop `text` is marked as required in `JoinWithPreviousVerseButton`, but its value is `undefined`.
at JoinWithPreviousVerseButton (http://localhost:3000/_next/static/chunks/pages/index.js?ts=1624422465897:8531:26)
at VerseJoinUnjoinSubmenu (http://localhost:3000/_next/static/chunks/pages/index.js?ts=1624422465897:7757:5)
at ul
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.