diff --git a/scripts/plop/plopfile.js b/scripts/plop/plopfile.js index 49a8e415..2b5a6d54 100644 --- a/scripts/plop/plopfile.js +++ b/scripts/plop/plopfile.js @@ -1,5 +1,6 @@ export default function (plop) { plop.setHelper('tagWithoutPrefix', tag => tag.replace(/^sl-/, '')); + plop.setHelper('tagToHumanReadableName', tag => tag.replace(/^sl-/, '').replace(/-/g, ' ')); plop.setHelper('tagToTitle', tag => { const withoutPrefix = plop.getHelper('tagWithoutPrefix'); diff --git a/scripts/plop/templates/component/component.hbs b/scripts/plop/templates/component/component.hbs index 203b8665..eef7cd98 100644 --- a/scripts/plop/templates/component/component.hbs +++ b/scripts/plop/templates/component/component.hbs @@ -15,7 +15,7 @@ import styles from './{{ tagWithoutPrefix tag }}.styles'; * @slot - The default slot. * @slot example - An example slot. * - * @csspart base - The component's base wrapper. + * @csspart {{ tagWithoutPrefix tag }} - The internal wrapper for the {{ tagToHumanReadableName tag }}. * * @cssproperty --example - An example CSS custom property. */