All Questions
179
questions
1
vote
2
answers
63
views
How to show next Image from url without specifying width and height
I'm trying to show image in next js using import Image from 'next/image'; without specifying width and height.
Note that image is coming from URL and not from specific folder in project.
<Image ...
0
votes
0
answers
36
views
CSS filter property does not work in html2canvas
I currently have a div with an image and to download it I'm using the following code:
const handleDownloadAll = () => {
const downloadPromises = [polaroidContainerRef.current].map(
(...
0
votes
1
answer
269
views
Next.js and Tailwind object-cover not cropping image and rounded does not work
I am working on a Next.js site with Tailwind and I am creating cards to display a few projects. Since the images are not the same size, I am trying to align them so that all the cards look the same.
...
0
votes
0
answers
13
views
How to dynamically resize Leaflet CRS.Simple map based on viewport while maintaining standardized coordinates? [duplicate]
I'm using Leaflet to render a static image as a map. For the sake of example, let's say the image is 700px x 700px.
To create the map, I do the following:
map.current = L.map("map", {
...
0
votes
0
answers
20
views
React Navigation Swapping Icons
How to change menu icons for both <NavLink/> 'active' and CSS &:hover states?
SEE GIF: multiple rendering between states
Navigation Menu with three states:
inactive-icon (normal)
Show Blue ...
0
votes
1
answer
19
views
Why is the image going on the next line?
(https://i.sstatic.net/5oi7s.png)
The image is moving to the next line for some reason. I have tried several approaches to solve this problem. It seems to be getting better with inbuilt Image ...
1
vote
1
answer
47
views
How can I reference logo.png files with names in my React application and display them dynamically for the tech stack of my projects section?
I'm working on a web development project where I have a list of projects, each with a title, description, and a technology stack. I want to display technology icons next to the names of the ...
0
votes
2
answers
55
views
How to apply icon over an image when images are fetching from an api
I have an api that fetches the images of dogs and I want to apply heart icon (like favourite feature) over it . When clicked , that image should also get display on the favourites section. I am not ...
0
votes
0
answers
106
views
How to lazy load background images in react using react-lazy-load-image-component?
<div className="background-image"
style={{backgroundImage: `url(${imageUrl})`}} />
</div>
Also How to create common components to make them reusable for multiple images
Thank ...
0
votes
0
answers
108
views
React image mapper / area subdivision
Hi i Have a Task in which i have to make the map of Slovenia interactive in such a way that when hovered over a statistical area of Slovenia it would make a popup window (tooltip) with the basic ...
0
votes
1
answer
68
views
Image transitions with React useState
Can I add transitions when changing img src using useState()?
const [index, setIndex] = useState(0);
const images = [image1, image2];
<button onClick={()=>setIndex(1)}>Image2</button>
&...
0
votes
1
answer
52
views
Add img to HTML File Type download of React component
Here is a simplified version of my React component:
export class SomePage extends Component {
const downloadAsHTML = () => {
const element = document.createElement("a");
const ...
0
votes
0
answers
16
views
Picture not showing up in production build but shows up in dev
I ran into a problem yesterday. Never experienced it before. The images are not loading correctly in the production build, but when I check in dev build the images loads perfectly fine. Tried ...
1
vote
0
answers
550
views
How can I add a scroll bar on a component using the "React Zoom Pan Pinch" library?
Is there a way to add a scroll bar to a component that is using the react-zoom-pan-pinch library? One solution I've tried was using the 'wrapperStyle' component
wrapperStyle{{maxHeight:'1000px',...
0
votes
1
answer
39
views
Delete an image by clicking on a button
I want to delete one image by clicking on a button.
<img alt="image" src="https://image.png"/>
<button onClick={() => removeImage}>X</button>