diff --git a/src/components/CTEPubListScreen/controllers/EPubListController.js b/src/components/CTEPubListScreen/controllers/EPubListController.js index a8ca6a8e2..ee1894a84 100644 --- a/src/components/CTEPubListScreen/controllers/EPubListController.js +++ b/src/components/CTEPubListScreen/controllers/EPubListController.js @@ -43,7 +43,7 @@ class EPubListController { } uurl.openNewTab( - links.epub(newEPubData.id, Constants.EpbEditStructure, Constants.HFromNew) + links.epub(newEPubData.id, Constants.EditINote, Constants.HFromNew) ); return newEPubData; diff --git a/src/entities/EPubs/structs/EPubChapterData.js b/src/entities/EPubs/structs/EPubChapterData.js index df6305dc2..c991ef1b2 100644 --- a/src/entities/EPubs/structs/EPubChapterData.js +++ b/src/entities/EPubs/structs/EPubChapterData.js @@ -10,7 +10,7 @@ function _createChapterTitle() { } class EPubChapterData extends EPubChapterLikeData { - constructor(chapterLike, resetText = true) { + constructor(chapterLike, resetText) { super(chapterLike, resetText, _createChapterTitle); const { subChapters = [] } = chapterLike; diff --git a/src/screens/Asl/components/AslTable/index.js b/src/screens/Asl/components/AslTable/index.js index a85b82727..debb14ecc 100644 --- a/src/screens/Asl/components/AslTable/index.js +++ b/src/screens/Asl/components/AslTable/index.js @@ -55,6 +55,7 @@ const AslTable = props => { const [onePage, setOnePage] = useState([]); const [showVideo, setShowVideo] = useState(false); const [videoUrl, setVideoUrl] = useState(''); + const [selectedTerm, setSelectedTerm] = useState(null); const [style, setStyle] = useState({ left: 100, top: 100, @@ -71,7 +72,7 @@ const AslTable = props => { }) const [isDown, setIsDown] = useState(false); const [direction, setDirection] = useState(''); - + useEffect(() => { const index = (pageNumber-1) * ONE_PAGE_NUM; setOnePage(items.filter(item => item.term.toLowerCase().includes(search.toLowerCase())).slice(index, index + ONE_PAGE_NUM)); @@ -117,7 +118,10 @@ const AslTable = props => { return 'Example' } - const handleVideo = (source, uniqueASLIdentifier) => { + const handleVideo = (term) => { + setSelectedTerm(term); + const source = term.source; + const uniqueASLIdentifier = term.uniqueASLIdentifier; const hostName = window.location.hostname; if (hostName !== '') { if (source === 'ASLCORE') { @@ -227,9 +231,10 @@ const AslTable = props => { onClick={() => setShowVideo(false)} >X - + {`${selectedTerm.term} (Source:${selectedTerm.source})`}