Skip to content

Conversation

@RyoWakabayashi
Copy link

I suggest adding an attribute that allows the modal to be hidden when mounted

if show_on_mounted is set to false, the modal is not displayed when mounted

modal

)

attr(:show_on_mounted, :boolean,
default: false,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm this would mean everyone who upgrades will have their modals stop working? maybe we could reverse it - "hide_on_mounted", defaults to false?

unless show_on_mounted do
%JS{}
|> JS.remove_class("overflow-hidden", to: "body")
|> JS.hide(to: "#modal-overlay")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just wondering why we need to hide so many things?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Certainly there was no need to hide so much.

I'll Add commits immediately.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants