Change a block of text into a card?

I have migrated many posts and a lot of it looks great, but some tweaks are needed.

In some posts, I need to convert a section into a Markdown or HTML card to fix something, but it seems like to do this I have to make a new card and cut and paste the text into it. Is there a way to just highlight a block and convert it into a card?

I have a lot of these to do (mostly involving broken footnotes) so any shortcuts would help.

Edit: actually, cutting and pasting destroys links, so that doesn’t work at all. :thinking:

What about creating a snippet?

Snippets are very cool! I’ve been using them for some repeated Markdown I need.

But I don’t think they help here.

What I have is for each article a set of up to a few dozen citations, where I have a link in the text going to, say “#1”, and then at the bottom in the references part, a number, a link, a citation, and a quote–something like:


[1] The Neurology of Narrative
Kay Young, Jeffrey L. Saver
From: SubStance Issue 94/95 (Volume 30, Number 1&2), 2001 pp. 72-84

“Abstract
Narrative is the inescapable frame of human existence. Thinkers as diverse as Aristotle, Barthes, and Bruner have recognized the centrality of narrative in human cognition, but have scanted its neurobiologic underpinning. Recent advances in cognitive neuroscience suggest a regionally distributed neural network mediates the creation of narrative in the human central nervous system. Fundamental network components include: 1) the amygdalo-hippocampal system, responsible for initial encoding of episodic and autobiographical memories, 2) the left peri-Sylvian region, where language is formulated, and 3) the frontal cortices and their subcortical connections, where individuals and entities are organized into real and fictional temporal narrative frames. We describe four types of dysnarrativia, states of narrative impairment experienced by individuals with discrete focal damage in different regions of this neural network subserving human self-narrative. Patients with these syndromes illustrate the inseparable connection between narrativity and personhood. Brain- injured individuals may lose their linguistic or visuospatial competencies and still be recognizably the same persons. Individuals who have lost the ability to construct narrative, however, have lost their selves.”


But the code that makes the link in the text go to the citation anchor at the bottom is broken–None of them survived the migration.

What I’ve been doing is manually making a new Markdown block to replace the first line of each citation like this:

<a name=1>[1]</a>[The Neurology of Narrative](http://mtw160-198.ippl.jhu.edu/login?auth=0&type=summary&url=/journals/substance/v030/30.1young.pdf)

That works, but it’s kind of a pain, because I have to manually create a new block, and grab the link text and the link url separately to cut and paste into the new block. I have already made a snippet for the anchor code to modify, but it only helps a little.

And it doesn’t help to make a snippet of the whole thing because (a) I almost never use the same citation+quote twice across the site, and (b) making it into a snippet still doesn’t allow me to edit the section as Markdown.

I’m stuck in some kind of hidden Markdown in every article, where I am looking at the rendered Markdown, but can’t actually edit it as Markdown even though it obviously is. That’s really the crux of the issue!

Gotcha. You’re right that Snippet won’t help here.

It sounds like the issue stems from how the content was imported. One option might be to try importing some of the content again, using a different strategy, like converting everything to HTML first…

1 Like

Oof. It actually was originally in HTML. haha

But I’ve already sunk a lot of time into editing the results, so probably the most expedient way forward is to manually edit the remainder.

Do you have any extra insight about why I can’t edit the Markdown in the online editor? I can add new Markdown around existing text, but I can’t seem to access the underlying code in the editor at all, and sometimes it interacts with editing in weird, unpredictable ways because it’s invisible.

There is no markdown stored in the editor unless you are writing inside a markdown card. We do have markdown expansions so you can write as if you’re writing markdown and it will auto-convert to rich text but there’s no underlying markdown code.

Ghost hasn’t used a markdown editor since pre-1.0. Posts either use mobiledoc or more recently lexical as the underlying content format.

2 Likes

OK. Yeah–It’s not in a card at all. If it were I could edit the card to see the underlying text.

All I know is that it’s somehow in a WYSIWYG format that I can’t (or don’t know how to) modify directly. I was (wrongly) assuming that meant it was in md.

Is there a way to modify the mobiledoc/lexical through the online interface? Or am I stuck with that in all the migrated posts?

You can download the current state of your content - look in settings > labs :slight_smile:

Awesome. Thanks.

I’m probably overthinking all of this and just need to do the expedient thing.

If you have questions about the migration it would be best to reach out to support so they can help you directly.

You’re right. Sorry to air it here.