-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
chore: snapshot notebook template #17413
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One tiny thing in the template but can be updated once we get to the root cause of lists
@@ -68,11 +69,56 @@ export const LOCAL_NOTEBOOK_TEMPLATES: NotebookType[] = [ | |||
], | |||
}, | |||
{ type: 'paragraph', content: [{ type: 'text', text: '- List ' }] }, | |||
{ type: 'paragraph', content: [{ type: 'text', text: '1. Numbered list' }] }, | |||
{ | |||
type: 'bulletList', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would this not need to be orderedList
if we're including numbers?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That might be the hook to grab hold of...
This was just from me typing into the UI. Weirdly the numbered list appears to work correctly but -
and *
lists don't
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm switching this up...
Will make a set of "if the JSONContent is correct" stories so we know we render valid JSONContent"
And then we can figure out how to test
"if someone types blah
then we would render <template>blah</template>
or whatevs
7014a14
to
27a2e90
Compare
cy.get('li').contains('Notebooks').should('exist').click() | ||
cy.get('[data-attr="new-notebook"]').click() | ||
// we don't actually get a new notebook because the API is mocked | ||
// so, press enter twice to "exit" the timestamp block we start in |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe we should also be able to press esc
to remove the insertion suggestion if that's what this is trying to achieve
📸 UI snapshots have been updated1 snapshot changes in total. 0 added, 1 modified, 0 deleted:
Triggered by this commit. |
> ul { | ||
list-style: initial; | ||
> p { | ||
display: inline-block; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a reason we needed this? It makes the blinking cursor invisible in an empty list item. Removing it doesn't affect anything as far as I can see
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
At the point I added it it stopped the text dropping below the bullet point... may have been chance or fixed accidentally after that
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No worries, I think the styles got a little mixed up since but was pretty easy to fix in #17521
At some point lists stopped working in notebooks :/
This doesn't fix that (or at least not yet)
Update the introduction to render the formatting examples and add a story for it so we get a snapshot of rendered types