openlibrary icon indicating copy to clipboard operation
openlibrary copied to clipboard

Allow markdown in "Why did you choose this excerpt?" field

Open stopregionblocking opened this issue 2 years ago • 6 comments

Describe the problem that you'd like solved

See title. This could be helpful to (for example) link to other pages within explanations.

Proposal & Constraints

Additional context

Maybe there are good reasons to allow some markdown but not all of it.

Stakeholders

stopregionblocking avatar Mar 20 '24 08:03 stopregionblocking

@jimchamp may know about another similar PR we can reference which may make doing this one a good first issue for a new contributor.

It may be this one!

  • #8862

mekarpeles avatar Mar 25 '24 19:03 mekarpeles

#8862 is the correct PR. Adding the markdown editor to the excerpts field should be as simple as adding the markdown class to the textarea.

jimchamp avatar Mar 26 '24 17:03 jimchamp

Hi, may I work on this issue?

raffchen avatar Mar 29 '24 23:03 raffchen

@raffchen, you've been assigned. This file is the template for the excerpts section of the edit page.

jimchamp avatar Mar 30 '24 00:03 jimchamp

This is a little more complicated than I thought. The excerpt markdown is not being rendered correctly on book pages.

I'm also wondering if we want to let people add arbitrary links to book pages. Blocking this until the team can discuss this.

jimchamp avatar Apr 03 '24 17:04 jimchamp

So we already allow arbitrary links in description, with a regex we use to ban certain spammy links. We should make sure that regex is applied in these new fields and not just description, but then arbitrary links should be ok.

cdrini avatar Apr 08 '24 19:04 cdrini