Skip to content

Commit 5674a9e

Browse files
authored
merge: pull request #173 from texonom/deps/major-react-monorepo
deps: Update react monorepo to v19 (major)
2 parents ccbde91 + 6cf7030 commit 5674a9e

File tree

5 files changed

+63
-72
lines changed

5 files changed

+63
-72
lines changed

packages/nreact/package.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -41,13 +41,13 @@
4141
"devDependencies": {
4242
"@types/lodash.throttle": "^4.1.9",
4343
"@types/node": "^20.17.16",
44-
"@types/react": "^18.3.18",
44+
"@types/react": "^19.0.8",
4545
"clipboard-copy": "^4.0.1",
4646
"date-fns": "^2.30.0",
4747
"format-number": "^3.0.0",
4848
"lodash.throttle": "^4.1.1",
49-
"react": "^18.3.1",
50-
"react-dom": "^18.3.1"
49+
"react": "^19.0.0",
50+
"react-dom": "^19.0.0"
5151
},
5252
"peerDependencies": {
5353
"react": ">=16",

packages/nreact/src/block.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -371,7 +371,7 @@ export const Block: React.FC<BlockProps> = props => {
371371
</ol>
372372
)
373373

374-
let output: JSX.Element | null = null
374+
let output: React.JSX.Element | null = null
375375

376376
if (block.content)
377377
output = (

packages/nreact/src/third-party/code.tsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,13 +24,13 @@ export const Code: React.FC<{
2424
className?: string
2525
}> = ({ block, defaultLanguage = 'typescript', className }) => {
2626
const [isCopied, setIsCopied] = React.useState(false)
27-
const copyTimeout = React.useRef<number>()
27+
const copyTimeout = React.useRef<number>(null)
2828
const { recordMap } = useNotionContext()
2929
const content = getBlockTitle(block, recordMap)
3030
const language = (block.properties?.language?.[0]?.[0] || defaultLanguage).toLowerCase()
3131
const caption = block.properties.caption
3232

33-
const codeRef = React.useRef()
33+
const codeRef = React.useRef(null)
3434
React.useEffect(() => {
3535
if (codeRef.current)
3636
try {

packages/ntypes/src/api.ts

+2
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,8 @@ export interface SearchResult {
8888
isNavigable: boolean
8989
score: number
9090
highlight: {
91+
// <gzkNfoUU>query</gzkNfoUU> else for bold
92+
title: string
9193
pathText: string
9294
text: string
9395
}

pnpm-lock.yaml

+55-66
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)