Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Just tried v4 beta with bPress #224

Closed
ajtruckle opened this issue Feb 19, 2020 · 30 comments
Closed

Just tried v4 beta with bPress #224

ajtruckle opened this issue Feb 19, 2020 · 30 comments

Comments

@ajtruckle
Copy link

The reason it did not show before was because we did not have the TinyMCE toolbar showing on the front end. So that is good.

I have just tested in my staging sight and in principle it was working for bbPress. The hover toolbar is there etc. But, there is one big issue. Please look:

v4-beta

Once I hit submit to the issue it is showing the enlighter syntax styles code and the raw code underneath.

@ajtruckle
Copy link
Author

The element that is visible is:

<pre class="enlighter-raw">&lt;xsl:template name="MEMORIAL-WEEKEND"&gt;
  &lt;!-- 1. Is there a Special Event associated with this week? --&gt;
  &lt;!-- 2. Is it the Memorial? --&gt;
  &lt;!-- 3. Is the Memorial at the Weekend? --&gt;
  &lt;!-- If the answers are all Yes then we must display the Special Event information. --&gt;
  &lt;xsl:if test="@SpecialEvent=1 and SpecialEvent/Date/@Memorial=1 and SpecialEvent/Date/@MidweekEvent=0"&gt;
    &lt;table class="tableWeekend"&gt;
      &lt;tr&gt;
        &lt;!-- We need to use a colspan of 4 for consitency with the logic of the SpecialEvent template. --&gt;
        &lt;td class ="cellWEEKEND" colspan="4"&gt;
          &lt;div class="textWEEKEND" style="float:left"&gt;
            &lt;xsl:value-of select="//Labels/PTS_WeekendMeeting"/&gt;
          &lt;/div&gt;
        &lt;/td&gt;
      &lt;/tr&gt;
      &lt;xsl:apply-templates select="SpecialEvent"/&gt;
    &lt;/table&gt;
  &lt;/xsl:if&gt;
&lt;/xsl:template&gt;</pre>

Is there a setting I have not ticked, or is this a bug with something?

@AndiDittrich
Copy link
Member

it's your theme ....

@ajtruckle
Copy link
Author

How do I fix this then? As you know, I was not having this issue with the previous EnlighterJS.

@AndiDittrich
Copy link
Member

but you've had a lot of other issue ...

normally this behaviour should never appear...there must be some weak selectors used by bbPress or the theme.

maybe i should remove the bbPress support from the plugin since it causes such issues :(

@ajtruckle
Copy link
Author

No! You can't remove bbPress!! Please! I love this plugin and it is the only one that works with bbPress. This is the only issue I have encountered with the beta.

@AndiDittrich
Copy link
Member

but this issue is very serious... can you post the url to this testpost ?

@ajtruckle
Copy link
Author

I have just compared the two topics in my live site and the staging site.

The only difference is that on the live site it has display: none; and on your beta it does not.

Old: <pre style="display: none;">
Beta: <pre class="enlighter-raw">

As soon as I manually change it:

<pre class="enlighter-raw" style="display: none;">

Problem solved.

@ajtruckle
Copy link
Author

I don't want to post a url to a test post because I don't like exposing the staging site url. I am happy to create a public forum again with this test code if required. But I personally think we are just lacking this display: none;. Please advise. Thanks.

@AndiDittrich
Copy link
Member

that's not solved ;) something is overriding the enlighter-raw styles which already includes display: none

@ajtruckle
Copy link
Author

It is the bbPress styling, here:

style-pack

If you just add !important to your class then it takes precedence according to my testing here.

@ajtruckle
Copy link
Author

result

See?

@AndiDittrich
Copy link
Member

AndiDittrich commented Feb 19, 2020

i see but !important attribute should never be used by libraries such way... a better solution might to replace the pre tag with a div

the issue is still caused by the bbPress id selector ..

@ajtruckle
Copy link
Author

i see but !important attribute should never be used by libraries such way... a better solution might to replace the pre tag with a div

Ok, only you can decide that I guess!

the issue is still caused by the bbPress id selector ..

Ok, sorry about that. From what I can tell this is the only issue. I tried editing a post and editing the code settings to highlight lines and it worked.

Once you are happy to confirm a way forward (as I know it is late there!) I will be happy to try it again, first on the staging and then on my live site.

@AndiDittrich
Copy link
Member

thanks for the hint regarding bbPress

@ajtruckle
Copy link
Author

I realise too that we can't use !important because when you want to toggle the code ... :)

@ajtruckle
Copy link
Author

ajtruckle commented Feb 19, 2020

The only other thing I have noticed (and this might be because it is beta) in the old version when you hovered over your toolbar buttons - over the code view) it showed tooltips. In the beta it does not (in bbPress anyway). Other than that observation, looks great.

Confirmed, normal posts (like Gutenberg blocks) also don't show the tooltip on your hover menu either. So it is not just a bbPress matter.

hover

If you don't mind, I will delete the staging site now and I will happily re-create it and try your updated v4 beta when you are ready.

@AndiDittrich
Copy link
Member

tooltipps are not implemented yet. the old version uses generic title attributes which was not suitable for a modern react/jsx based app.

@ajtruckle
Copy link
Author

tooltipps are not implemented yet. the old version uses generic title attributes which was not suitable for a modern react/jsx based app.

Then I think for the most part this was a very successful test exercise with v4 beta in bbPress. Just the one issue. I will delete the staging now until I here from you and I will test. Night!

@ajtruckle
Copy link
Author

The alternative is to do it like your older version and use inline styles instead of a class.

Does it need a class? It is raw code and thus as plain as possible. Or, maybe just use inline for bbPress mode.

Just ideas. I am sure you thought of them already along with your other suggestion of div.

Heck, my alarm just gone off. Time to get up. Early start at work.

@AndiDittrich
Copy link
Member

the EnlighterJS library is a monolithic component and doesn't have any "bbPress" mode or similar - it has to work in a generic way.

@ajtruckle
Copy link
Author

ajtruckle commented Feb 20, 2020

the EnlighterJS library is a monolithic component and doesn't have any "bbPress" mode or similar - it has to work in a generic way.

Understood. So hopefully it will be ok with a div Like you said. If that also didn’t work I would have to go over to the BBPress forum for advice.

I let us hope it will just be ok. #excited.

@ajtruckle
Copy link
Author

More positive news. With my "live" site and the current EnlighterJS my topics mess up when I choose to not show line numbers (theme style issue).

But, the same does not happen with the new version. They display and render fine! :) So that is good. Is it hard to try changing the pre to a div?

@AndiDittrich
Copy link
Member

great! it's already changed in the v3.2 branch

@ajtruckle
Copy link
Author

great! it's already changed in the v3.2 branch

Does that mean there is a branch I can download? I can't see any recent commits.

@AndiDittrich
Copy link
Member

AndiDittrich commented Feb 20, 2020

no - i'm talking about EnlighterJS not Enlighter Wordpress Plugin

@ajtruckle
Copy link
Author

Is this not that then?
14F9C496-B293-4FEF-B7F6-9176C59D1F8E

@AndiDittrich
Copy link
Member

you're not familiar with git ?

the development is done locally, when a stable stage is reached it will be pushed to the origin repository. v3.2 is the current development branch projected as next release - there is no preview version available

@ajtruckle
Copy link
Author

I getcha. I use TortoiseGit with BitBucket. Understood.

@AndiDittrich
Copy link
Member

v4.1 is out including EnlighterJS v3.2.0 - this should address to bbPress issue

@ajtruckle
Copy link
Author

Yep, the tips are showing. :)

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

No branches or pull requests

2 participants