pnp / modernization

All modernization tooling and guidance
http://aka.ms/sppnp-modernize
MIT License
156 stars 86 forks source link

How do i have the titles of CEWP's on Publishing pages carried over to modern? #120

Closed russgove closed 5 years ago

russgove commented 5 years ago

[ ] Bug [ ] Enhancement

Problem Area

[ ] Page Transformation: Error during the setup/use of the Page Transformation UI solution (did you check our troubleshooting guide?) [ ] Page Transformation: Error during the use of page transformation from PnP PowerShell [ ] Page Transformation: Error during the use of page transformation from .Net [x] Page Transformation: Page is not looking correct after transformation [ ] Modernization Scanner: something went wrong...

Expected or Desired Behavior

Content editor webparts on classic pages have the title set in the webpart properties and the Chrome Type set to Title Only: image

Webpart title should be displayed after page is migrated.

Observed Behavior

webpart title is not displayed after webpart is migrated.

On old publishing page I have this: image

After Migration it is this: image

I'm using the oob webpart mappings

jansenbe commented 5 years ago

Let me investigate this one first

jansenbe commented 5 years ago

Based on a quick look we can use the ChromeType parameter to check if the web part is configured to show a title or not. Makes sense to take this in account as then the content better matches with was on screen on the classic page.

jansenbe commented 5 years ago

Fixed in https://github.com/SharePoint/sp-dev-modernization/commit/19a48357aff914ae2b62445075851e2da1666fd7.

russgove commented 5 years ago

Hi Bert, I downloaded the latest sp-dev-modernization and reran with the latest bits, but I still dont see the title. Stepping thouhg the code you added I see that wp.Properties has no 'ChromeType' property. But its definitely set on the webpage. [image: image.png]

Am i missing something?

On Sun, Apr 14, 2019 at 5:58 AM Bert Jansen notifications@github.com wrote:

Closed #120 https://github.com/SharePoint/sp-dev-modernization/issues/120.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/SharePoint/sp-dev-modernization/issues/120#event-2274655352, or mute the thread https://github.com/notifications/unsubscribe-auth/ACTRnHHrj0Xcp2OyJNvjAJQfHBNto2RRks5vgvvOgaJpZM4cuXLj .

russgove commented 5 years ago

Ah, I see ... I needed to add the ChromeType to the webpart mapping file. Working great now!

russgove commented 5 years ago

Same issue with summary links webpart. I'll open a new issue.