Skip to content

Conversation

shunsaker
Copy link

Support for HeadingLevel in collapsible sections
See #1686

@jansenbe jansenbe self-assigned this Sep 4, 2025
@jansenbe jansenbe added the area: pages API 📄 Working with modern pages label Sep 4, 2025
@jansenbe
Copy link
Contributor

jansenbe commented Sep 4, 2025

@shunsaker : nice work!

Question: if the default is 2, I think it's also needed to ensure HeadingLevel value is initialized to 2. We cannot assume every page has this value in it's json payload + we need to support creating pages where developers don't set the heading level

@shunsaker
Copy link
Author

shunsaker commented Sep 4, 2025

@shunsaker : nice work!

Question: if the default is 2, I think it's also needed to ensure HeadingLevel value is initialized to 2. We cannot assume every page has this value in it's json payload + we need to support creating pages where developers don't set the heading level

@jansenbe
I thought about that. When it is empty sharepoint makes it 2, so it seemed okay to leave it empty and tell Json not to serialize it if it is 0. Which is exactly what it does today because it can't set that property

@jansenbe
Copy link
Contributor

jansenbe commented Sep 4, 2025

Thx @shunsaker : I'll do some testing with the PR

@shunsaker
Copy link
Author

@jansenbe Bump. Have a minor feature blocked by this

jansenbe pushed a commit that referenced this pull request Sep 25, 2025
@jansenbe jansenbe merged commit fe7abf4 into pnp:dev Sep 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: pages API 📄 Working with modern pages
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants