-
Notifications
You must be signed in to change notification settings - Fork 33
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
Portable Text: Nested lists / bullets render wrong HTML #690
Comments
Confirmed I have the same issue. |
Would you be able to provide some portable text that renders wrongly? 🙏 |
documentFile.ts
blockContent.ts is a default one from sanity blog template
If I just try to copy-paste from sanity studio body input here it removes all list and it's a plain paragraphs: Wstęp: o mnie Przygotowanie do zmiany administratora Wybór właściwego przewodnika Metoda 5 kroków Forma zarządzania nieruchomością wspólną. Dwa rodzaje zarządu we Wspólnocie Mieszkaniowej – od tego trzeba zacząć? (...)
[1 min video from my sanity studio](https://komododecks.com/recordings/BQooB3WJBWHe832Niq2n) |
I think you should be able to copy-paste the JSON by inspecting your document within the studio. |
"tableOfContent": [ |
Hi, not sure if this is something related to this bug but I am experiencing issues with lists rendering with Nuxt3. I am passing the following serializer to the const serializers = {
types: {
code: Code,
callout: Callout,
seoImage: SeoImage,
video: VideoImage
},
list: {
// Ex. 1: customizing common list types
bullet: List,
number: NumberedList,
// bullet: (_, { slots }) => h('ul', { class: 'simple-list' }, slots.default?.()),
// number: (_, { slots }) => h('ol', { class: 'digit-list' }, slots.default?.()),
},
listItem: {
// Ex. 1: customizing common list types
// bullet: ({ slots }) => h('li', { class: 'list-item' }, slots),
// number: ({ slots }) => h('li', { class: 'list-item' }, slots),
bullet: ListItem,
number: ListItem
},
styles: {
'blockquote': BlockQuote,
},
marks: {
'externalLink': Link,
'internalLink': InternalLink,
'strike-through': 's',
'keyboard': 'kbd',
'highlight': 'mark'
}
} I have some custom types, styles and marks that renders fine, but list and listItem do not render as pointed out at all. I have tried the two ways shown in the code: as a Vue Component and as inline definition (commented) but none of both work. In fact, it does not show the list on the rendered HTML. Is this bug still open? Is this behaviour related o is a new bug? I am using: |
Version
module: 1.6.0
nuxt: 3.2.2
What is expected?
Nested lists HTML format such as
What is actually happening?
Steps to reproduce
Standard blocks with list markDefs
Additional information
Checklist
The text was updated successfully, but these errors were encountered: