fix: reproducible overflowlist (closes #1885)
This commit is contained in:
		@@ -1,5 +1,4 @@
 | 
				
			|||||||
import { JSX } from "preact"
 | 
					import { JSX } from "preact"
 | 
				
			||||||
import { randomIdNonSecure } from "../util/random"
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
const OverflowList = ({
 | 
					const OverflowList = ({
 | 
				
			||||||
  children,
 | 
					  children,
 | 
				
			||||||
@@ -13,8 +12,10 @@ const OverflowList = ({
 | 
				
			|||||||
  )
 | 
					  )
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					let numExplorers = 0
 | 
				
			||||||
export default () => {
 | 
					export default () => {
 | 
				
			||||||
  const id = randomIdNonSecure()
 | 
					  const id = `list-${numExplorers++}`
 | 
				
			||||||
 | 
					  console.log(id)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  return {
 | 
					  return {
 | 
				
			||||||
    OverflowList: (props: JSX.HTMLAttributes<HTMLUListElement>) => (
 | 
					    OverflowList: (props: JSX.HTMLAttributes<HTMLUListElement>) => (
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user