@aurodesignsystem-dev/auro-cli 0.0.0-pr246.0 → 0.0.0-pr251.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,9 +1,9 @@
1
- import{cemSorterPlugin as o}from"@wc-toolkit/cem-sorter";import{jsxTypesPlugin as i}from"@wc-toolkit/jsx-types";import d from"fs/promises";function p(){return{name:"add-dts-exports-plugin",packageLinkPhase({customElementsManifest:s}){let n=s.modules.filter(e=>e.path.endsWith("src/index.js")),t=[];if(n[0].exports.forEach(e=>{t.push(e.name)}),t.length===0){console.warn("No exports found for 'src/index.js'. Skipping export statement addition.");return}let r=`declare global {
1
+ import{cemSorterPlugin as x}from"@wc-toolkit/cem-sorter";import{jsxTypesPlugin as h}from"@wc-toolkit/jsx-types";import P from"node:fs/promises";function a(){return{name:"add-dts-exports-plugin",packageLinkPhase({customElementsManifest:n}){let r=n.modules.filter(t=>t.path.endsWith("src/index.js"));if(r.length===0){console.warn("No module found with path ending in 'src/index.js'. Skipping export statement addition.");return}let s=[],e=r[0];if(!e.exports||e.exports.length===0){console.warn("No exports found for 'src/index.js'. Skipping export statement addition.");return}e.exports.forEach(t=>{s.push(t.name)});let o=`declare global {
2
2
  namespace svelteHTML {
3
3
  interface IntrinsicElements extends CustomElements {}
4
4
  }
5
5
  }
6
6
 
7
7
 
8
- export { ${t.join(", ")} } from "./index.js";
9
- `;d.appendFile("dist/index.d.ts",r).then(()=>{console.info("Appended export statements to index.d.ts")}).catch(e=>{console.error(`Error appending to index.d.ts: ${e.message}`)})}}}var u={globs:["src/**/*.*js","scripts/wca/**/*.*js"],litelement:!0,packagejson:!0,dependencies:!0,quiet:!0,plugins:[o({deprecatedLast:!0}),i({fileName:"index.d.ts",outdir:"dist",excludeCssCustomProperties:!0}),p()]};export{u as default};
8
+ export { ${s.join(", ")} } from "./index.js";
9
+ `;P.appendFile("dist/index.d.ts",o).then(()=>{console.info("Appended export statements to index.d.ts")}).catch(t=>{console.error(`Error appending to index.d.ts: ${t.message}`)})}}}function m(){return{name:"force-private-plugin",packageLinkPhase({customElementsManifest:n,context:r}){!r.forcePrivateProperties||r.forcePrivateProperties.size===0||n.modules?.forEach(s=>{s.declarations?.forEach(e=>{let o=r.forcePrivateProperties.get(e.name);if(o&&o.length>0&&("members"in e&&e.members&&e.members.forEach(t=>{o.includes(t.name)&&(console.log(`Found member '${t.name}' in ${e.name}, marking as private`),t.privacy="private")}),"attributes"in e&&e.attributes&&"customElement"in e&&e.customElement)){let t=e;t.attributes&&(t.attributes=t.attributes.filter(i=>o.includes(i.name)?(console.log(`Found attribute '${i.name}' in ${e.name}, removing from manifest`),!1):!0))}})})},analyzePhase({ts:n,node:r,context:s}){if(r.kind!==n.SyntaxKind.ClassDeclaration)return;let e=r.name?.getText();if(!e)return;let o=(t,i)=>{t?.forEach(l=>{l?.tags?.forEach(c=>{if(c.tagName.getText()==="forcePrivate"){let{comment:p}=c,u=[];if(typeof p=="string"){let f=p.match(/['"]([^'"]+)['"]/g);f&&(u=f.map(g=>g.replace(/['"]/g,"")))}s.forcePrivateProperties||(s.forcePrivateProperties=new Map);let d=s.forcePrivateProperties.get(e)||[];s.forcePrivateProperties.set(e,[...d,...u])}})})};o(r?.jsDoc,"class"),r.members?.forEach(t=>{o(t?.jsDoc,"member")})}}}var C={globs:["src/**/*.*js","scripts/wca/**/*.*js"],litelement:!0,packagejson:!0,dependencies:!0,quiet:!0,plugins:[x({deprecatedLast:!0}),h({fileName:"index.d.ts",outdir:"dist",excludeCssCustomProperties:!0}),a(),m()]};export{C as default};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aurodesignsystem-dev/auro-cli",
3
- "version": "0.0.0-pr246.0",
3
+ "version": "0.0.0-pr251.0",
4
4
  "description": "A cli tool to support the Auro Design System",
5
5
  "repository": {
6
6
  "type": "git",