Christophx
Injected live reload iframe isn't hidden
In my app, the live reload iframe that’s injected into the html of every page isn’t hidden.
<iframe hidden="" src="/phoenix/live_reload/frame"></iframe>
It has a height of 150 and its pushing everything else up on the page. Why is it visible?
Marked As Solved
harmon25
I noticed this also. The following CSS does the trick of hiding it.
iframe[src="/phoenix/live_reload/frame"] {
display: none;
}
Also Liked
zzq
Specifically, maybe something like this:
[hidden] {
display: none !important;
}
This is the same as the default style rule for hidden, just with !important so that it overrides the tailwind’s display: block reset for iframes. (And indeed, so that it overrides style rules that set display in general: it’s unlikely that you anywhere want the hidden attribute to not actually hide the element it’s on.)
LostKobrakai
Just to mention this as well. This is because of css tailwind does apply. By default the hidden attribute should work as expected. For tailwind I’d suggest adding css to make hidden actually do its job.
Popular in Questions
Other popular topics
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #deployment
- #library
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #channels
- #elixirconf
- #exunit
- #discussion
- #code-sync
- #javascript
- #podcasts
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #elixir-ls
- #phoenix_html
- #iex
- #blog-post
- #graphql
- #genstage
- #ai
- #websockets
- #supervisor
- #advent-of-code
- #elixirconf-us
- #distillery
- #processes
- #forms
- #api
- #metaprogramming
- #security
- #performance








