Add Line Spacing adjustment to WYSIWYG #2384

Closed
opened 2026-02-05 03:53:31 +03:00 by OVERLORD · 4 comments
Owner

Originally created by @bpaul24 on GitHub (Sep 10, 2021).

Describe the feature you'd like
The ability to adjust the line spacing when creating new pages in a book when using the WYSIWYG format.

Describe the benefits this feature would bring to BookStack users
This would allow lists on pages such as steps in a KB article to look better and not make pages larger than necessary due to line spacing.

Additional context
I understand line spacing in WYSIWYG can be done using SHIFT+Enter but adding a sub step down to step "I" can't be single spaced without making the entire page single spaced, which is currently not an option. Furthermore, step "E" is then also not double spaced and can't be single spaced properly.

tempsnip

Originally created by @bpaul24 on GitHub (Sep 10, 2021). **Describe the feature you'd like** The ability to adjust the line spacing when creating new pages in a book when using the WYSIWYG format. **Describe the benefits this feature would bring to BookStack users** This would allow lists on pages such as steps in a KB article to look better and not make pages larger than necessary due to line spacing. **Additional context** I understand line spacing in WYSIWYG can be done using SHIFT+Enter but adding a sub step down to step "I" can't be single spaced without making the entire page single spaced, which is currently not an option. Furthermore, step "E" is then also not double spaced and can't be single spaced properly. ![tempsnip](https://user-images.githubusercontent.com/90465951/132878482-8856c970-97f9-48a4-ab75-1af08155e5bc.png)
Author
Owner

@ssddanbrown commented on GitHub (Sep 12, 2021):

Hi @bpaul24,
I wouldn't really want to introduce an new option/configuration/control for a minor styling preference unless it's highly desired, which I would not consider this to be since I can't remember it being requested before.

There should be a way to achieve this via some custom CSS though via the "Custom HTML Head Content". I would look to offer such an example solution but I'm not really sure I understand what your desired output would be based upon your "Additional context" details.

@ssddanbrown commented on GitHub (Sep 12, 2021): Hi @bpaul24, I wouldn't really want to introduce an new option/configuration/control for a minor styling preference unless it's highly desired, which I would not consider this to be since I can't remember it being requested before. There should be a way to achieve this via some custom CSS though via the "Custom HTML Head Content". I would look to offer such an example solution but I'm not really sure I understand what your desired output would be based upon your "Additional context" details.
Author
Owner

@bpaul24 commented on GitHub (Sep 13, 2021):

Hi @ssddanbrown,
Below is a screenshot of the desired output I am looking for. As you can see each line of text is dropped down one line as opposed to twol. Single line spacing just changes the amount of space between each line for the entire text field. I do appreciate you taking a look at this and thank you for your time.

tempsnip2

@bpaul24 commented on GitHub (Sep 13, 2021): Hi @ssddanbrown, Below is a screenshot of the desired output I am looking for. As you can see each line of text is dropped down one line as opposed to twol. Single line spacing just changes the amount of space between each line for the entire text field. I do appreciate you taking a look at this and thank you for your time. ![tempsnip2](https://user-images.githubusercontent.com/90465951/133079811-35aeb076-c90a-42d8-9f95-a97918e58722.png)
Author
Owner

@ssddanbrown commented on GitHub (Sep 13, 2021):

@bpaul24 Okay. If you're not already on the latest version of BookStack it might be worth updating as I did do some work in the latest feature release to make lists more consistent. Here's what a nested list looks like on my instance:

Screenshot from 2021-09-13 13-59-01

Otherwise, the following content in the "Custom HTML Head Content" could add additional spacing between list items if desired:

<style>
	.page-content li {
		margin-top: 0.5em;
	}
</style>

You could adjust the 0.5 value up or down to change spacing. The em unit used sets spacing relative to the text size of the list items.

@ssddanbrown commented on GitHub (Sep 13, 2021): @bpaul24 Okay. If you're not already on the latest version of BookStack it might be worth updating as I did do some work in the latest feature release to make lists more consistent. Here's what a nested list looks like on my instance: ![Screenshot from 2021-09-13 13-59-01](https://user-images.githubusercontent.com/8343178/133088021-8852a7ca-b50a-4f9b-96ea-e9e697d83f15.png) Otherwise, the following content in the "Custom HTML Head Content" could add additional spacing between list items if desired: ```html <style> .page-content li { margin-top: 0.5em; } </style> ``` You could adjust the `0.5` value up or down to change spacing. The `em` unit used sets spacing relative to the text size of the list items.
Author
Owner

@ssddanbrown commented on GitHub (Sep 18, 2021):

Since the above workaround has been provided I'll close this off.

@ssddanbrown commented on GitHub (Sep 18, 2021): Since the above workaround has been provided I'll close this off.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/BookStack#2384