crazko/krystal

TypeError: document.querySelector(...) is null

Closed this issue · 4 comments

Here is an attempt to make krystal and multicolumn plug in work together.
This is done using the ensemble feature of multicolumn - you can save a particular layout, storyview, stylesheets tiddlers, pagetemplate to a particular ensemble. So when we load that particular ensemble, all these will be automatically loaded.

Check this demo - https://multicolumn-krystal.tiddlyhost.com/

But I encountered one problem -

image

Is this related to krystal plug in.

@crazko Can you take a look at this.

Use this link. https://multicolumn-krystal.tiddlyhost.com/

You will see an error message on opening the wiki.

image

Close the error message and click on the Krystal link in the topbar.

image

Now open few tiddlers in the Horizontal layout

image

In this image, you can see that I have opened many tiddlers, but none of the tiddlers stacked at the right side show their titles.
Any possible reason for the error message and tiddler titles missing you can think of

Hi @arunnbabu81 ,

The functionality of horizontal scrolling, stacking tiddlers, vertical title for
stacked tiddlers, etc, is implemented in krystal/plugin.js basically. From
your demo site, header() function in krystal/plugin.js is complaining a
TypeError, which is due to missing .krystal-header element (that top
navbar). This is a sign of something going wrong and it may be the cause of
your reported issue. I didn't spend time in debugging your demo and couldn't
provide you with more detail. However, I'm guessing it's a plugin conflict.

As a suggestion, enabling multiple plugins which serve a similar/same purpose,
may impose some non-trivial code conflicts which can take time to debug and
resolve. If you find nothing buggy in the two conflicting plugins themselves,
in most cases you probably want to write a new plugin with some glue code to
make them seamlessly work together. Also, if you find something buggy in Krystal
itself, or any ideas on improving existing code-base to make it more compatible
with other plugins in general, you are welcome to create a new issue or PR.

This is not a bug related to Krystal. I suggest closing this issue.

As I told in the first post this is an attempt to see whether multicolumn and Krystal plug in will work together. And the error message seen is due the conflict between these two plug ins. I was interested in knowing whether this conflict can be resolved?

Still a bug when switch to an alternative layout when krystal is installed.