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

[localization feature] Chinese users need "text-indent:2em" style in some paragraph #12451

Closed
conanliuhuan opened this issue Nov 30, 2018 · 9 comments
Labels
[Block] Paragraph Affects the Paragraph Block Internationalization (i18n) Issues or PRs related to internationalization efforts Needs Dev Ready for, and needs developer efforts [Type] Enhancement A suggestion for improvement.

Comments

@conanliuhuan
Copy link

Describe the solution you'd like
Chinese users need "text-indent:2em" style in some paragraph, paragraph block need an option to enable this feature.
Most Chinese paragraphs has this style, but not all. If once enabled, keep it be a default option when type the ENTER button.

Describe alternatives you've considered
I've tried to add a special class to the paragraph, for example: "text-indent-2em", then I add a custom style:
.text-indent-2em {text-indent:2em;}
This alternative need I copy the class and paste it to every paragraph when I use the ENTER button while I am writting a article. If once enabled, It's BEST to keep it be a default option when type the ENTER button

@swissspidy swissspidy added Internationalization (i18n) Issues or PRs related to internationalization efforts [Block] Paragraph Affects the Paragraph Block Needs Design Feedback Needs general design feedback. labels Nov 30, 2018
@swissspidy
Copy link
Member

We could probably add a text indention attribute to the paragraph block since we also have drop caps already. But perhaps it could also be plugin territory.

@conanliuhuan
Copy link
Author

We could probably add a text indention attribute to the paragraph block since we also have drop caps already. But perhaps it could also be plugin territory.

I am developing a WordPress theme, is there any way to extend the current paragraph block with that option? I can't find any solution on the gutenberg handbook.

@kjellr
Copy link
Contributor

kjellr commented Apr 23, 2019

I do think this could be an option. Here's a quick mockup:

Frame 2

Frame 2 1

One question though — do we want to allow users to indent and add a drop cap? Or should it be one or the other?

@karmatosed
Copy link
Member

One question though — do we want to allow users to indent and add a drop cap? Or should it be one or the other?

For me, if you have indent you should allow drop cap also. I can't see it being the most common use case but it shouldn't block.

@mapk
Copy link
Contributor

mapk commented Jul 16, 2019

When using Google docs, I've had to add the indent myself. But as I create a new paragraph, the indent was automatically applied. If I didn't want it, I just removed the indent in the margin setting ruler. Here's an example of my experience.

indent

I wonder if we could do something similar. If the user adds an indent to their first paragraph, the next one created will also have an indent.

@mapk
Copy link
Contributor

mapk commented Jan 21, 2020

After discussing this in the Design Team slack today, we felt this setting would align better in the Document setting sidebar or in the Options popover.

This is because we feel if the user wants this setting, it would be applied to all Paragraph blocks in the document and so shouldn't be an individual block setting.

@mapk mapk added Needs Design Needs design efforts. and removed Needs Design Feedback Needs general design feedback. labels Jan 21, 2020
@wittwitsan
Copy link
Member

#12451 (comment)
This mockup from @kjellr looks good to me.

I think this setting should be an individual block setting to get along with Drop Cap setting that applies to an individual block. In some Asian language, an indentation may need for some paragraph, not every single paragraph.

Applying the first-line indentation for all Paragraph blocks might lead to the complexity of turning off in some Paragraph block. However, it is possible to add a first-line indent option for all Paragraph blocks setting in Global Styles.

@MichaelArestad
Copy link
Contributor

This mockup from @kjellr looks good to me.

I agree. I think we could move forward with that.

One question though — do we want to allow users to indent and add a drop cap? Or should it be one or the other?

It's unlikely folks would need both, but might be the simplest to implement so lets go forward with that.

I wonder if we could do something similar. If the user adds an indent to their first paragraph, the next one created will also have an indent.

Super clever. If easy to do, I think that's a great idea. I don't think it's a blocker.

I think we can say this is ready to be implemented based on what I see. Nice work.

@MichaelArestad MichaelArestad added Needs Dev Ready for, and needs developer efforts and removed Needs Design Needs design efforts. labels Apr 6, 2020
@jordesign jordesign added the [Type] Enhancement A suggestion for improvement. label Aug 2, 2023
@jordesign
Copy link
Contributor

Closing this issue as a duplicate - in favour of #37462

@jordesign jordesign closed this as not planned Won't fix, can't repro, duplicate, stale Aug 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Block] Paragraph Affects the Paragraph Block Internationalization (i18n) Issues or PRs related to internationalization efforts Needs Dev Ready for, and needs developer efforts [Type] Enhancement A suggestion for improvement.
Projects
None yet
Development

No branches or pull requests

8 participants