It might be an idea to use Linkit when adding a spotlight with a link? And that might also be an idea for the links list. What do you guys think?
| Comment | File | Size | Author |
|---|---|---|---|
| #13 | panopoly_wysiwyg-spotlight-linkit-2173535-13.patch | 585 bytes | dsnopek |
| #11 | panopoly_test-spotlight-linkit-2173535-11.patch | 756 bytes | dsnopek |
| #10 | panopoly_widgets-spotlight-linkit-2173535-10.patch | 638 bytes | dsnopek |
Comments
Comment #1
caschbre commentedWhile I've used linkit with wysiwyg, I haven't tried it with 'link' fields. Is that what you're referring to? And does linkit work with 'link' fields now?
Comment #2
lsolesen commentedI thought it did. It can be attached to fields, the description on the project page says. However, I haven't tried i yet myself. Just thought it would be a nice addition, when it is a dependency of panopoly anyways.
Comment #3
caschbre commentedI'll check this out and see if it works with link fields.
Comment #4
caschbre commentedSo it looks like linkit 3.x allows linkit profiles to be configured for use on non-wysiwyg fields. Unfortunately there is not an upgrade path from linkit 2.x -> 3.x. I created another issue regarding the upgrade.
Related: #2186541: Upgrade linkit module 3.1+
Comment #5
caschbre commentedComment #6
caschbre commentedMarking this postponed until #2186541: Upgrade linkit module 3.1+ is resolved.
We could alternatively try to write our own way of using linkit 2.x on fields but I think that may be wasted effort that we could better spend on getting panopoly upgraded to linkit 3.x.
Comment #7
caschbre commentedNote: a patch needs review at #2186541: Upgrade linkit module 3.1+ that can open up the way to get this issue resolved.
Comment #8
caschbre commentedSo after some digging, it doesn't look like we can easily use linkit for spotlight. The issue is spotlight has a custom field type as opposed to using the link field. Looks like I'll be able to get linkit (3.x) working with the links widget though.
Comment #9
dsnopekNo longer postponed on Linkit 3, although, it sounds like that didn't help anyway...
Comment #10
dsnopekThis issue which was recently committed to Linkit would make this possible:
#2651404: Allow Linkit support for any eligible element type
I've attached a simple patch that uses it, which depends on the patch in #2013965: ability to link images placed with image widget. We'll also need a patch to update the version of Linkit we're using to add just that patch, and some tests.
Comment #11
dsnopekHere's an additional Behat test scenario!
EDIT: Test build on Travis: https://travis-ci.org/panopoly/panopoly/builds/147644296
Comment #12
dsnopekAh, yeah, this fails tests because it depends on the latest -dev of Linkit, which I'm running locally (where the tests pass) but we haven't integrated it into Panopoly yet.
Comment #13
dsnopekAdding a patch to update Linkit and include the patch from dev that we need to make this work. Then I'll try on Travis again!
EDIT: Here's the Travis build: https://travis-ci.org/panopoly/panopoly/builds/188957455
Comment #15
dsnopekPassed tests, so, committed!