Skip to content
This repository has been archived by the owner on Mar 29, 2021. It is now read-only.

Feedback on 2.4.1 #20

Closed
metallikat36 opened this issue Apr 10, 2016 · 8 comments
Closed

Feedback on 2.4.1 #20

metallikat36 opened this issue Apr 10, 2016 · 8 comments

Comments

@metallikat36
Copy link

Okay, so I have tested the plugin and here is all my feedback:

  1. FYI, your active installs of the plugin went from like 50 down to 30. Probably because the update messed up posts already published with citations in them. For me, what it did is it made all the tooltips blank. I could fix this by editing the article, enabling smart biblio mode, and then moving my references list (which was presently above the smart biblio line) to be below the line. Though due to funny list auto-formatting things, that is actually more difficult than it sounds. You basically have to cut/paste one item at a time for the list auto-formatting to not mess things up. Though perhaps it could have been easier had I done it in text mode rather than WYSIWYG mode. In any case, I wouldn't feel bad about it, as the development of the plugin is totally worth it.
  2. FYI, sent you a small thank you $$.
  3. The general URL entry works fine as far as I can tell. Thanks a lot. Ideally, it would be automatically able to parse all the other info just after entering the URL, but it's okay as is.
  4. The smart biblio feature also seems to work fine as far as I can tell. This is totally workable. Though the ideal way to do this would actually not generate the references list at all, until you actually clicked Publish (or clicked a "Regenerate References List" button). This way, you could reorder sentences that have inline references in your post all you want, and when you publish, the inline citation numbers will always be in ascending order. This is what I described in my original thread about this, but I understand if this is just way too complicated. For this to work, there wouldn't actually be any such thing as "inline citations". Actually there would only be "inline references". The citation number is something assigned on the fly once you click Publish (or a button called "Regenerate References List"). Anyway, just making sure you understand the concept. Even if this appears doable, it does have some caveats. If you ever decide to work on this, let me know and I can help you brainstorm on this. I have some ideas....You see, I can give you an example of why this feature would be cool. Say I write an article with citations 1 to 100. Then I suddenly realize I want to add a new reference to the very first sentence of the article. It has citation number 101. Now my article looks sloppy for having citations 101, 1, 2, 3...100. And if I were to try to fix this by putting that new reference as number 1 on the ordered list, then all the other references on the list get bumped up by one index, which then makes all the inline citations off by one. So there is no easy way to make sure inline citation numbers are always in ideal order at present. Also there is no easy way to delete a reference from the reference list without getting citations off by one.
  5. Keep in mind such a development as described in number 5 might affect how one would implement a collapsible reference. Though maybe not.
  6. FYI, you need to change the dashboard CSS documentation to say "#abt-smart-bib" rather than ".abt-smart-bib", which is what it presently says. The first selector works. The latter selector does not.
  7. The CSS arrow styling selectors you have written do not do anything for me:
    .abt_arrow_up { border-color: transparent transparent magenta; } .abt_arrow_down { border-color: magenta transparent transparent; }
  8. I don't know what .abt_tooltip_touch_close is. Do I need to know? Is that like an X button to close a tooltip or something? If so, I don't see it.
  9. FYI, tooltips now work in Mozilla. I tested IE through the following website:
    https://www.browserstack.com/start
    The "Live" tab lets you test live browsers live. The tooltips do not seem to appear on IE still.
  10. Indentation issue, I already mentioned. Just repeating it for my own mental organization.
  11. I'm having a new issue with favicons not showing up on new posts I make. I don't think it has anything to do with ABT plugin, but just wanted to mention it to make sure. I still have the problem when I deactivate ABT, so it's probably unrelated.
  12. Inserting multiple comma-separated PMIDs at once is buggy. There are 4 cases:
    a) When I am not in smart-biblio mode, and I add 2 PMIDs, it seems to work.
    b) When I am not in smart-biblio mode and I add 3 PMIDs, it just makes the loading-wheel spin forever
    c) when I am in smart-biblio mode, and I add 2 PMIDs, sometimes it works, and sometimes it does nothing at all.
    d) when I am in smart-biblio mode and I add 3 PMIDs, it adds 1 inline citation number (should add three) and does not add nothing to the references list.
  13. I think I may have already mentioned this to you. If so, sorry for duplication. I test mobile devices by using online tools. On mobile it appears that the horizontal location of the tooltip arrow does not stay with the citation number.

Holy guacamole. I hope all this feedback is considered helpful information rather than a pain in the ***!

David

@dsifford
Copy link
Owner

Thanks again for all your help and suggestions David.

To touch on each of your points individually...

FYI, your active installs of the plugin went from like 50 down to 30.

Oh well; ya win some, ya lose some. I think as the bugs get worked out people will come back. Not terribly worried.

FYI, sent you a small thank you $$.

You totally did not have to do that. Your help and suggestions have been more than enough in return! But I appreciate it nevertheless 👍

The general URL entry works fine as far as I can tell. Thanks a lot. Ideally, it would be automatically able to parse all the other info just after entering the URL, but it's okay as is.

I was going to pursue having stuff autopopulate, but unfortunately most WP sites will have trouble with CORS requests. I decided to not take the headache and just do it the way it is.

Though the ideal way to do this would actually not generate the references list at all, until you actually clicked Publish (or clicked a "Regenerate References List" button). This way, you could reorder sentences that have inline references in your post all you want

Good thoughts. The only issue with going about it that way is that you and everybody else would have to stay committed to having the plugin installed for the long haul. The moment somebody uninstalls the plugin, everything would fall apart. Having said that, I'm not totally opposed to the idea.

Keep in mind such a development as described in number 5 might affect how one would implement a collapsible reference. Though maybe not.

It certainly would. Good point.

FYI, you need to change the dashboard CSS documentation to say "#abt-smart-bib" rather than ".abt-smart-bib", which is what it presently says. The first selector works. The latter selector does not.

I'll open a new issue for this. Thanks

The CSS arrow styling selectors you have written do not do anything for me:
.abt_arrow_up { border-color: transparent transparent magenta; } .abt_arrow_down { border-color: magenta transparent transparent; }

Try adding !important to the selectors and let me know if that works or not.

So, for example:

.abt_arrow_up { 
  border-color: transparent transparent magenta !important; 
} 
.abt_arrow_down { 
  border-color: magenta transparent transparent !important; 
}

I don't know what .abt_tooltip_touch_close is. Do I need to know? Is that like an X button to close a tooltip or something? If so, I don't see it.

That selector is for the close button on mobile view. There's a little circle with an X on the top right that mobile users have to touch for the tooltip to close.

The "Live" tab lets you test live browsers live. The tooltips do not seem to appear on IE still.

Thanks for letting me know. I believe I already opened an issue for this. It'll be fixed on the next update.

I'm having a new issue with favicons not showing up on new posts I make. I don't think it has anything to do with ABT plugin

Yeah, I don't do anything that messes with the favicons in this plugin so it's likely unrelated.

Inserting multiple comma-separated PMIDs at once is buggy

Hmm.. Interesting. Any way you could send me a screencast of that?

I think I may have already mentioned this to you. If so, sorry for duplication. I test mobile devices by using online tools. On mobile it appears that the horizontal location of the tooltip arrow does not stay with the citation number.

This was fixed to my knowledge. Perhaps you're still using a cached version of one of the older plugin files?

Thanks again!

@metallikat36
Copy link
Author

*Re Proposed Regenerate References feature: * A way to implement this kind of "regeneration" of citations and references that would not be a problem if people wanted to stop using the plugin could be as follows. As of right now, if you deactivate the plugin, you see [cite num ="x"] in the articles, and you see a references list at the end. This is alright, since those citations still make sense. So presumably this is a state a person can still delete the plugin in and consider it to be acceptable. So if the final state of a "regeneration" mode was just the same as this, then there would not be any additional irritation caused relative to the present state of deactivating the plugin.

In other words, say you are editing a post that has inline citations in it (i.e. [cite num="x"], [cite num="y"], etc), and of course there is also a reference list at the end. Then say you clicked a "regenerate citations/references" button. Then an algorithm goes and does a bunch of switching things around. CItation 2 turns into citation 6, and citation 5 turns into citation whatever. And reference 4 is moved to number 9 on the list. And reference 23 is moved to number whatever on the list, etc. Okay, so the code does its thing, and now you are still left with a post that is no more cumbersome than it is at present, should the user want to stop using the plugin.

In more other words...The idea I previously gave you of having only "inline references" would be totally scrapped. There would still be both inline citations and a reference list at the end , both of which would still be generated using the present smart biblio mode. But there would be an additional feature that if you click it, it does does crazy re-ordering of the references list and re-numbering of inline citations.

Anyway, I've been thinking about the algorithm for how that might work. It's doable, but could be a real pain. If you get tempted, let me know and I will write up some pseudo code. Basically, it's feasibility would depend on being able to find specific instances of "[cite num= “i”]" within a post, for a given "i". If that's not possible then I think the only way to implement such a feature would have to involve pissing people off who wanted to stop using the plugin.

Re: color of arrows) Adding !important, fixed it. Now I can color my arrows. Ideally I would also want a border for the arrows, which would seamlessly blend into the border of the rest of the tooltip. But that's no big deal, and it is fine the way it is.

Re: Arrow alignment of tooltip on mobile: See this url:
http://mobiletest.me/iphone_5_emulator/?u=http://www.earthmedresearch.org/wordpress-resources-at-siteground/
See how the first instance of citation [3] tooltip has the arrow misaligned. But this could be because this is an emulator, and that this problem does not happen on an actual mobile. I don't have a mobile device so I can't tell you. I cleared my cache.

Re close button on mobile tooltips
I don't see a close button on the above mobile emulator tooltips. But again, that just could be because it's an emulator and isn't perfect.

Re multiple PMID bugs:
I will send you send you something more about it shortly...

@metallikat36
Copy link
Author

Okay, I figured out the issue with multiple PMIDs. It works fine, unless you input a PMID that does not exist. For example, 1234568 does not exist in pubmed. That's why I was getting the bugs. So maybe you need a try, catch block or something.

@dsifford
Copy link
Owner

Re:Proposed "Regenerated References" feature

I've thought about this a bit more as well and I think the way to pull it off would be to store a hidden <span> element of JSON-encoded citation data to pull references from after inserting. Each [cite num=xxx] would instead have to be some type of citation id that can be cross-referenced in the json. Then, when the user clicks generate, it can just add them in order of occurrence in the json to the bibliography...

But 2 issues come to mind with that:

  1. it'll be difficult to remember what citations the person entered using uniquely-generated IDs without some type of mechanism to check.
  2. Adding an additional citation to a citation block (e.g [cite num="1"] ==> [cite num="1,2"] would require deleting the entire block and starting over.

A reasonable way to go about doing this I think would be to do it similar to how it's currently done if you have a smart-bib enabled where the list of citations in your list pops up and you can click on each one you want in that position. Open to suggestions though.

Re: color of arrows

Yeah, it won't be possible to add a separate border color on the arrows due to the fact that the arrows themselves are borders.

Re: Arrow alignment of tooltip on mobile:

I think that's an issue with the mobiletest site and not reality. On both my personal cell phone (iphone 5s) and on chrome devtools mobile mode it looks appropriate

image

Re close button on mobile tooltips

Yeah, I think the tester is flawed. See my above screenshot for what the close button looks like.

Re multiple PMID bugs: [...] maybe you need a try, catch block or something.

I've got a few of those, but it's difficult because there are three separate async functions that happen in sequence per PMID. I'll look into better scrutinizing the error handling in future updates. 👍

@metallikat36
Copy link
Author

Just brainstorming cases that might be helpful to think about, whatever the method may be:

  • Like you said, what to do with citations blocks that have more than 1 citation in them
  • What happens when you reduce (rather than increase) the number of citations in a block (i.e. [cite num="1-2"] ==> [cite num="1"]
  • What to do with a reference you want on the list, but don't actually want to cite
  • what to do with references you cite more than once, but only want on the reference list once
  • make sure sentences can be reordered and still work with this, including reordering sentences that have citations that have multiple references ((i.e. [cite num="1-2"])

And if the user while writing a post can't see the actual citations/references they have inputted, but just see some mysterious ID, then that might make the whole thing not worth it. But I think this is not necessarily an issue if I understood your suggestion correctly.

If you are adding some kind of span tags, then if those would still be invisible to a website reader upon deactivating the plugin, then maybe that would not piss plugin users off should they want to stop using the plugin.

Food for thought: What operations would a user have to do manually right now if he wanted to make changes to his citations/references? Or say he wanted to try and manually make the post look like the citations are in ascending order? And does the plugin accommodate for these operations already?:

  1. Adding a reference/citation. This is what the plugin already does. No sweat.
  2. Deleting a citation and its acompanying reference (if any). If a user wanted to remove a citation, okay no sweat. Just delete it. But if you delete the accompanying reference, then the ordered list gets shorter by one, and this makes all the citations get out of sync. The existence of this issue might mean we need some type of more robust feature for the plugin in any case. Though I guess the user could just leave the reference alone, and just never cite it.
  3. Deleting a reference and its acompanying citation (if any). Similar issues as above. Citations will get off by one.
  4. Say you want to make the citations appear in a more ascending order. Hypothetical example: Say right now inline you see citations in the following order: 4,5,6,6,1,4,3. And you have a reference list with 1,2,3,4,5,6 obviously inorder. Note that 2 is not cited anywhere. And note that 6 and 4 are cited twice. Ya...there would just be no easy way to manually adjust the order of citations here. At best the user could perform a switch of two items. Like switch the positions of references 1 and 4 on the references list. And then switch the numbering of citations 1 and 4 in the post. Then you would have citations 1,5,6,6,4,1,3.

Say a new feature took those citations 4,5,6,6,1,4,3 and automatically renumbered/reordered them. What would the result look like. Well, it would look like 1,2,3,3,4,1,6, if I am not mistaken. Note that 1 appears twice in a somewhat non-elegant way. But this has nothing to do with a lack of the plugin feature in this example. This is just inevitable owing to the way the user wrote the article.

Regarding your popup idea, and user selecting where they want citations: I am not sure that is a good idea. That is basically asking a user to manually indicate optimal numbering of citations as best as they are able to. A robust algorithm would automatically do this better than a user would do manually in any case. And I think a robust algorithm would still be needed to accomodate such manual input anyway. Could be wrong though.

Maybe some kind of compromise is an option. Like enable three basic operations the user can do through popup windows:

  1. Insert a reference into middle of list. This would then have to increment all the citations numbers correctly. Say is a reference was inserted between 2 and 3 (i.e. now you have a 2,3,4, where 3 is the new thing you inserted), and say you previously had a citation that said cit[1-5] in the article. That citation, in order to be correct, would need to be changed to be cit[1-2, 4-6]. Kind of tricky. So even implementing some basic operations like this might not be all that easy.
  2. Delete a reference from middle of list. Similar things.
  3. Swap position of two items of list.

Na, I don't think implementing such basic manual operations would be any easier than implementing a completely automated thing.

I'm just thinking out loud. Nothing in this post is necessarily important.

@dsifford
Copy link
Owner

@metallikat36 Interesting ideas.

I think I may have figured out how to go about doing it, but the execution will likely take a little while.

In short, I think I might be able to add a sidebar meta box that can collect a list of references and then interop between there and the post editor.

The only way to really go about doing that is to completely ditch shortcodes and add html on the fly. I haven't totally thought this through, but I'd imagine it would be possible to reverse engineer the editor's interactive <a> tags and allow removal of references that way -- eg. click the link, a menu pops up, and you can add or remove references.

Each reference would have to be communicated to the editor using some type of unique ID and then, when the user chooses to generate a bibliography, the program could just apply a simple sort function based on reference occurrence.

Having said that, this will take a while. Fair warning.

@metallikat36
Copy link
Author

Understood. Plugin in its present state is awesome and totally workable - in fact the only workable plugin out there at present that I know of. So if this all gets too frustrating, no worries if we just scrap the whole idea.

@dsifford
Copy link
Owner

@metallikat36 Closing this issue for now. Let me know if I forgot about any of your suggestions on this next update (if so, open a new issue) 👍

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants