infinitered / thesis-phoenix

A lightweight, bolt-on, intuitive content editing system for Elixir/Phoenix websites. Star this repo and follow along with our progress!
Other
645 stars 62 forks source link

Add support for modals #167

Open praveenperera opened 5 years ago

praveenperera commented 5 years ago

I was able to get modal editing working with some simple css

#thesis-editor {
  z-index: 2000 !important;
}

However one problem I am having is that if, I make a content area that triggers the modal to open, I am unable to edit that content area without opening the modal.

My current hacky workaround with jQuery is:

$("div.thesis-content").click(function(e) {
  if ($("body").hasClass("thesis-editing")) {
    e.stopPropagation();
    e.preventDefault();
  }
});
jamonholmgren commented 5 years ago

Hey @praveenperera ! Thanks for the issue. Sorry it's taken me so long, I've been traveling.

I'll take a look when I can -- about to head to another conference.

jamonholmgren commented 5 years ago

Hey @praveenperera, I wonder if this workaround is sufficient for now. I'm not sure if it's worth trying to handle this case in Thesis itself. Thoughts?

praveenperera commented 5 years ago

For me the work around is fine, we could wait and see if other people run into similar problems.