Skip to main content

All Questions

Tagged with
0 votes
3 answers
54 views

Multi-line Truncated Text with "..." in the end

I need help with Multi-line Truncated Text. I can't cut the final word with "..." in text block with randon string number So this is my solution which cut the end of my block, but without &...
Nick's user avatar
  • 3
0 votes
1 answer
31 views

Trigger handle click on only one item at a time in a map

I am working on an app that allows the user to select a vehicle from a list. The problem I am having at the moment is that when I try to map the vehicles to a list and select a single vehicle to set ...
Joshua's user avatar
  • 331
0 votes
2 answers
31 views

How can I get the data from the API to display with the webpage becoming unresponsive?

I am building a guessing game built wtih react and "artsy.api". The guessing game can be accessed through my index page by clicking a button. <Link to="/guessing-game"> {&...
e_robinson's user avatar
0 votes
0 answers
10 views

Why is my state "detail" always empty when only trying to empty it on modal closure? [duplicate]

I am attempting to create some logic for dynamically creating a carousel if a part has more than one image to be show (detail represents that it does). However, while setting the detail works, if I ...
spencer's user avatar
  • 118
0 votes
1 answer
64 views

How to get position of a div dynamically in react?

I've been trying to create an effect similar to this one: whenever a div is hovered a bigger div covers it showing more details about the card. This is the jsx code(All classes are Tailwind css ...
lakpareek's user avatar
0 votes
0 answers
44 views

Framer-motion scrollYProgress not triggering on Nextjs 14.1.0 page.jsx

** Am experience no scroll trigger animation switch from the y-scroll to x-scroll automatically using framer motion in nextjs 14.1.0, does anyone know the solution or what I may be missing in this ...
Shitsama John's user avatar
0 votes
0 answers
42 views

dropdown is close when i click outside and whene i click in the <li> is not closed

This is my useEffect function for if i click outside of the liste it will be closed First when i click in the <li> the list is showed but when i click again in to <li> it doesn't closed ...
Soufiane Fathaoui's user avatar
0 votes
0 answers
44 views

Unable to prevent main window scroll on focus of element within a dropdown

I'm trying to use a custom drop-down menu component that shows a list of checkboxes, the size of the list can vary between users, so I've set a max height and overflow to auto to allow scrolling if ...
Amnesiac's user avatar
0 votes
1 answer
109 views

Calendar in React - 2 week layout

I want implement a 2 week calendar in my React project. I have tried to look at multiple libraries, but I can't find one that fits the layout I wanna recreate. The show more dates should just show the ...
Jonas 's user avatar
  • 59
-1 votes
1 answer
41 views

How can i get change the input text color of components that are not related each other?

i'm having this issue with my components, the thing is that i'm using at this moment 3 main components, one is called Page.jsx the other is called Pencil.jsx and the other is PencilCase.js. This is my ...
DvK's user avatar
  • 3
1 vote
1 answer
186 views

How to use CSS transitions on react useState elements?

I have a website in which I want to change between different HTML sections, and during these changes that happen in a click of an button I want for the section to for example just fade in. I made a ...
Mast3rKoo's user avatar
0 votes
0 answers
45 views

Images loading again even after preloading

I am trying to preload images and set them as background in the React HOC component, but despite loading it the css is calling and caching the Images again. interface ImagePreloaderProps { pictures:...
vhdcpatel's user avatar
1 vote
2 answers
76 views

React - Filter Mapped List

I want to only show values greater than 0 on each row. I tried filtering for black > 0 etc but it removed the whole row, whereas i just want to make a 0 into an empty string essentially. Here is my ...
Roy503's user avatar
  • 35
1 vote
0 answers
120 views

How to make an overlay that exactly covers an object-fit:contain image

Setup: I am provided a container div that can dynamically be any size and an image that can be any size. I want the image to always fit in the center of the container (with allowances for the ...
BobtheMagicMoose's user avatar
-3 votes
1 answer
67 views

What's wrong with this useRef hook DOM manipulation? [closed]

In React.js i want to implement the background color to a div element using useRef() hook but it doesn't work. const cssNav = useRef() useEffect(() => { window.scrollY > 0 ? cssNav....
Rave On Time's user avatar

15 30 50 per page
1
2 3 4 5
25