Sitecore / jss

Software development kit for JavaScript developers building web applications with Sitecore Experience Platform
https://jss.sitecore.com
Apache License 2.0
261 stars 275 forks source link

Rendering Parameters templates don't inherit from Standard Rendering Parameters #427

Closed slate1325 closed 2 years ago

slate1325 commented 4 years ago

Description

Rendering Parameters templates created during app deployment don't inherit from the 'Standard Rendering Parameters' template. This affects updating presentation details of a rendering for other fields, such as Datasource and cache parameters.

Expected behavior

Rendering Parameters templates created during app deployment should include the 'Standard Rendering Parameters' as a base template

Steps To Reproduce

  1. Add params to a component
  2. Deploy the app
  3. View Presentation details for an item using the component and click to edit the component
  4. Notice the only section available is 'data' and the default sitecore sections are missing

Possible Fix

Your Environment

Screenshots

missing template component properties

erzr commented 4 years ago

This was discussed a little on Slack, adding some details from that conversation:

Did this address the issue @slate1325?

slate1325 commented 4 years ago

This was discussed a little on Slack, adding some details from that conversation:

  • ExpandRenderingParametersTemplates does not set inherits on the rendering parameters template during import. should be able to inherit from ExpandRenderingParametersTemplates and override what you need there to set it.
  • CreateTemplateDefFromRenderingParametersDefs is the method you would override to set this.

Did this address the issue @slate1325?

@erzr , working on the fix now. Will keep you posted.

Thanks!

slate1325 commented 4 years ago

Created a github repo that addresses the issue: https://github.com/slate1325/JSS-Import-Rendering-Parameters-Template

ambrauer commented 3 years ago

Just a heads up, a backlog item has been added to address this issue in a future release. Thanks for reporting the issue.

markgibbons25 commented 3 years ago

Looks like this is still an issue? I'm new to jss so just wondering what is the impact of overriding generated rendering parameters to inherit from Standard Rendering Parameters template?

ambrauer commented 3 years ago

@markgibbons25 Just confirmed, this is still an open issue (I've poked to get prioritized). Using the workaround in the patch linked above to inherit the Standard Rendering Parameters template should have no detrimental impact, and in fact is what the proper fix will likely look like.

addy-pathania commented 2 years ago

This would be fixed in the next release (20.0.0)