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

Draggable links #3710

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Conversation

theSherwood
Copy link
Contributor

Hi @Jermolene,

I added startactions and endactions to the link widget so that its draggable behavior is like the draggable widget. I then changed list-links-draggable macro and the list-tagged-draggable macro so that they would support that new link behavior. As far as I can tell, these changes are entirely backwards compatible.

I also fixed what I saw as a minor formatting issue in list-links-draggable. The position of the closing </$type$> tag was placed before the final droppable-placeholder, causing that final placeholder to be of a different format from the rest of the placeholders in the list. I moved the closing tag to include the trailing placeholder.

Best wishes,
Adam

#3700

@Jermolene
Copy link
Owner

Hi @admls apologies for the delayed response.

Adding the startactions and endactions attributes to the link widget is a great idea. I need to check carefully about moving the closing </$type$> because I faintly remember that it was intentional, but of course can't recall the details...

@theSherwood
Copy link
Contributor Author

Hi @Jermolene,

Thanks! I think it will allow for some nice ui functionality. I've been looking at links specifically because I've been using Firefox and the draggable buttons don't seem to work there. But it occurs to me the same functionality could probably be extended to buttons with similar ease (for Chrome users at least). I'll take a look at it when I get the chance.

The </$type$> tag is for the container element of the list. The list items have a $subtype$ tag that defaults to <li>. That last droppable placeholder is a

with no option to change it by passing in any parameters to the macro. So it doesn't end up styled like the other list elements (i.e., not bullet point). But if it is within the </$type$> tag, it will end up being in the place you expect (i.e., indented to the same degree as the other list items with a predictable amount of padding between it and the last list item). If it falls outside the </$type$> tag it isn't entirely clear that it belongs to the list because of this formatting difference.

@theSherwood
Copy link
Contributor Author

@Jermolene What could I do to help resolve this?

@twMat
Copy link
Contributor

twMat commented Nov 28, 2020

If I understand this correctly, it would be a partial solution to the request in #2563 i.e to feature drag'n drop translusion, i.e to DnD a link and have it display as {{title}} instead of [[title]]. I'm guessing it would only be a partial solution because the request would ideally be solved with a general way to DnD any link i.e not necessarily ones defined with the full linkwidget.

@saqimtiaz
Copy link
Contributor

saqimtiaz commented Nov 28, 2020

I need to check carefully about moving the closing </$type$> because I faintly remember that it was intentional, but of course can't recall the details...

@Jermolene it has been a while but I remember editing the macro to move the closing </$type$> as well, as has been done in this PR. Otherwise it is not possible for the final droppable placeholder to consistently styled with the other placeholders.

@Jermolene
Copy link
Owner

Thanks @saqimtiaz, I'll commit that change separately.

Jermolene added a commit that referenced this pull request Nov 29, 2020
@saqimtiaz
Copy link
Contributor

@Jermolene there is merit to the actual purpose of this PR, which is to add drag start and drag end actions to the LinkWidget akin to the DraggableWidget.

Do we want to re-do this PR to resolve conflicts and implement that? If so I can try and look at it in the coming week.

@Jermolene
Copy link
Owner

@Jermolene there is merit to the actual purpose of this PR, which is to add drag start and drag end actions to the LinkWidget akin to the DraggableWidget.

Do we want to re-do this PR to resolve conflicts and implement that? If so I can try and look at it in the coming week.

Indeed, I just dealt with the typo to put it to bed, I'd still be interested in the rest of this PR, probably for v5.1.24.

@saqimtiaz
Copy link
Contributor

bump

@Jermolene
Copy link
Owner

Thanks @theSherwood @saqimtiaz there's some conflicts to be resolved, but I also noticed that your signature on the contributors license agreement is under a different username (@admls), which would be worth updating with another PR to tiddlywiki-com.

@joshuafontany
Copy link
Contributor

@Jermolene @theSherwood @saqimtiaz This seems worth including in an upcoming release. I may have time to resolve these conflicts this week. Thoughts?

@saqimtiaz
Copy link
Contributor

@joshuafontany I would welcome that.

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

Successfully merging this pull request may close these issues.

None yet

5 participants