Ticket #2698 (assigned enhancement)

Opened 22 months ago

Last modified 21 months ago

markdown preview

Reported by: shevski Owned by: toby
Priority: minor Milestone: demo phase 4
Component: ckan Keywords: demo-theme
Cc: Repository: ckan
Theme: none

Description

for description / other fields with markdown support

Change History

comment:1 Changed 21 months ago by toby

I think this would be really helpful/nice

comment:2 Changed 21 months ago by aron.carroll

  • Owner changed from aron.carroll to toby
  • Status changed from new to assigned

We need an api endpoint that can render a markdown string on submission.

  • Client posts a string of text to the endpoint.
  • Server responds with a 200, text/html response containing the rendered markdown.
  • Server returns a 400 and empty body if the content is not valid markdown.
  • Server returns a 500 and empty body if something else crashes.

Alternatively for better error handling we could use a JSON transport.

  • Client posts a blob of json containing a "content" key with the markdown string.
  • Server returns a 200 (application/json) and blob of json with a "content" key with the rendered markdown.
  • Server returns a 400 (application/json) and blob of json with a "error" key containing a useful message for the user.
  • Server returns a 500 (application/json) and blob of json with a "error" key containing a useful message for the user.

comment:3 Changed 21 months ago by toby

  • Milestone changed from demo phase 5 to demo phase 4
Note: See TracTickets for help on using tickets.