Skip to content

Component doesn't render #68

Closed Answered by Tsabary
Tsabary asked this question in Q&A
Aug 7, 2023 · 9 comments · 4 replies
Discussion options

You must be logged in to vote

@NishargShah I found the source of the problem and the solution.

As mentioned, the issue was with applying @tailwind base.
When doing so, we were applying some base styles which could be found in the preflight file right here.

The style that was causing this issue is the default image maxWidth:

img,
video {
  max-width: 100%;  <---- This one
  height: auto;
}

I've copied the library to play with it, and the way to fix this issue is simply adding maxWidth:"none", to imgNonResponsive in styles.ts.

const imgNonResponsive: React.CSSProperties = {
  ...absPos,
  zIndex: 1,
  userSelect: "none",
  maxWidth:"none", <--- Add this
};

When this is added everything works just fine.

Replies: 9 comments 4 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
2 replies
@Tsabary
Comment options

@Tsabary
Comment options

Comment options

You must be logged in to vote
2 replies
@NishargShah
Comment options

@marcuspx
Comment options

Answer selected by Tsabary
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants
Converted from issue

This discussion was converted from issue #67 on August 09, 2023 09:04.