2022-01-16 13:13:07 -08:00
|
|
|
# frozen_string_literal: true
|
2021-12-30 08:59:44 -08:00
|
|
|
|
2022-01-16 13:13:07 -08:00
|
|
|
require "uri"
|
|
|
|
|
|
|
|
class QuestionMarkdown < Redcarpet::Render::StripDown
|
2021-12-30 08:59:44 -08:00
|
|
|
include Rails.application.routes.url_helpers
|
|
|
|
include SharedMarkers
|
|
|
|
|
2023-02-15 14:52:10 -08:00
|
|
|
def paragraph(text) = "<p>#{text.gsub("\n", '<br>')}</p>"
|
2022-01-16 13:13:07 -08:00
|
|
|
|
|
|
|
def link(link, _title, _content)
|
|
|
|
process_link(link)
|
|
|
|
end
|
|
|
|
end
|