Skip to content

Add indent and outdent toolbar buttons#555

Open
kmantel wants to merge 1 commit into
Ionaru:masterfrom
kmantel:in-out-dent
Open

Add indent and outdent toolbar buttons#555
kmantel wants to merge 1 commit into
Ionaru:masterfrom
kmantel:in-out-dent

Conversation

@kmantel

@kmantel kmantel commented Aug 7, 2023

Copy link
Copy Markdown

Use commands 'tabAndIndentMarkdownList' and
'shiftTabAndUnindentMarkdownList' assigned to keyboard shortcuts.

Use commands 'tabAndIndentMarkdownList' and
'shiftTabAndUnindentMarkdownList' assigned to keyboard shortcuts.
@kmantel

kmantel commented Aug 7, 2023

Copy link
Copy Markdown
Author

Solves #232

@Ionaru

Ionaru commented Aug 20, 2023

Copy link
Copy Markdown
Owner

Thank you for the contribution!

It all looks good to me except for one small thing: the placement of the buttons when enabled is maybe a little strange. I'd expect them closer to (maybe next to?) the unordered-list and ordered-list buttons like they are in MS Word.

image

I'll leave the choice to you, just say "merge" and I'll click merge. :)

LGTM

@kmantel

kmantel commented Aug 20, 2023

Copy link
Copy Markdown
Author

Thank you for the contribution!

It all looks good to me except for one small thing: the placement of the buttons when enabled is maybe a little strange. I'd expect them closer to (maybe next to?) the unordered-list and ordered-list buttons like they are in MS Word.

image

I'll leave the choice to you, just say "merge" and I'll click merge. :)

LGTM

I just added everything to the end, so it wasn't a calculated choice. Do you mean this part setting the default toolbar?

https://github.com/kmantel/easy-markdown-editor/blob/4d35093129d6388a955ab85a473167b9f24e09a7/src/js/easymde.js#L1705-L1718

   'indent': {
        name: 'indent',
        action: indent,
        className: iconClassMap['indent'],
        noDisable: true,
        title: 'Indent',
    },
    'outdent': {
        name: 'outdent',
        action: outdent,
        className: iconClassMap['outdent'],
        noDisable: true,
        title: 'Outdent',
    },

I don't mind moving them between whatever elements you prefer.

@kmantel

kmantel commented Aug 21, 2023

Copy link
Copy Markdown
Author

And I have been using outdent to the left of indent like in that image, so I'll change that as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants