@teambit/renaming 0.0.232 → 0.0.235

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.
@@ -59,7 +59,7 @@ class ScopeRenameCmd {
59
59
 
60
60
  const title = _chalk().default.green(`successfully replaced "${oldName}" scope with "${newName}"`);
61
61
 
62
- const renamedIdsStr = scopeRenamedComponentIds.length ? `\n${_chalk().default.bold('the following components were affected by this scope-name change:')}\n${scopeRenamedComponentIds.join('\n')}` : '';
62
+ const renamedIdsStr = scopeRenamedComponentIds.length ? `\n${_chalk().default.bold('the following components were affected by this scope-name change:')}\n${scopeRenamedComponentIds.map(c => c.changeScope(newName)).join('\n')}` : '';
63
63
  const refactoredStr = refactoredIds.length ? `\n\n${_chalk().default.bold('the following components have been refactored:')}\n${refactoredIds.join('\n')}` : '';
64
64
  return `${title}\n${renamedIdsStr}${refactoredStr}`;
65
65
  }
@@ -1 +1 @@
1
- {"version":3,"names":["ScopeRenameCmd","constructor","renaming","name","description","report","oldName","newName","refactor","scopeRenamedComponentIds","refactoredIds","renameScope","title","chalk","green","renamedIdsStr","length","bold","join","refactoredStr"],"sources":["scope-rename.cmd.ts"],"sourcesContent":["import { Command, CommandOptions } from '@teambit/cli';\nimport chalk from 'chalk';\nimport { RenamingMain } from './renaming.main.runtime';\n\nexport class ScopeRenameCmd implements Command {\n name = 'rename <current-scope-name> <new-scope-name>';\n description = \"Renames the scope name for all components with the specified 'current scope name'\";\n arguments = [\n { name: 'current-scope-name', description: 'the scope name to be replaced by another scope name' },\n { name: 'new-scope-name', description: 'a new scope name to replace the current scope name' },\n ];\n options = [\n [\n 'r',\n 'refactor',\n 'update the import statements in all dependent components to the new package name (that contains the new scope name)',\n ],\n ] as CommandOptions;\n group = 'development';\n\n constructor(private renaming: RenamingMain) {}\n\n async report([oldName, newName]: [string, string], { refactor }: { refactor?: boolean }) {\n const { scopeRenamedComponentIds, refactoredIds } = await this.renaming.renameScope(oldName, newName, { refactor });\n const title = chalk.green(`successfully replaced \"${oldName}\" scope with \"${newName}\"`);\n const renamedIdsStr = scopeRenamedComponentIds.length\n ? `\\n${chalk.bold(\n 'the following components were affected by this scope-name change:'\n )}\\n${scopeRenamedComponentIds.join('\\n')}`\n : '';\n const refactoredStr = refactoredIds.length\n ? `\\n\\n${chalk.bold('the following components have been refactored:')}\\n${refactoredIds.join('\\n')}`\n : '';\n return `${title}\\n${renamedIdsStr}${refactoredStr}`;\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AACA;EAAA;;EAAA;IAAA;EAAA;;EAAA;AAAA;;AAGO,MAAMA,cAAN,CAAwC;EAgB7CC,WAAW,CAASC,QAAT,EAAiC;IAAA,KAAxBA,QAAwB,GAAxBA,QAAwB;IAAA,8CAfrC,8CAeqC;IAAA,qDAd9B,mFAc8B;IAAA,mDAbhC,CACV;MAAEC,IAAI,EAAE,oBAAR;MAA8BC,WAAW,EAAE;IAA3C,CADU,EAEV;MAAED,IAAI,EAAE,gBAAR;MAA0BC,WAAW,EAAE;IAAvC,CAFU,CAagC;IAAA,iDATlC,CACR,CACE,GADF,EAEE,UAFF,EAGE,qHAHF,CADQ,CASkC;IAAA,+CAFpC,aAEoC;EAAE;;EAElC,MAANC,MAAM,CAAC,CAACC,OAAD,EAAUC,OAAV,CAAD,EAAuC;IAAEC;EAAF,CAAvC,EAA6E;IACvF,MAAM;MAAEC,wBAAF;MAA4BC;IAA5B,IAA8C,MAAM,KAAKR,QAAL,CAAcS,WAAd,CAA0BL,OAA1B,EAAmCC,OAAnC,EAA4C;MAAEC;IAAF,CAA5C,CAA1D;;IACA,MAAMI,KAAK,GAAGC,gBAAA,CAAMC,KAAN,CAAa,0BAAyBR,OAAQ,iBAAgBC,OAAQ,GAAtE,CAAd;;IACA,MAAMQ,aAAa,GAAGN,wBAAwB,CAACO,MAAzB,GACjB,KAAIH,gBAAA,CAAMI,IAAN,CACH,mEADG,CAEH,KAAIR,wBAAwB,CAACS,IAAzB,CAA8B,IAA9B,CAAoC,EAHxB,GAIlB,EAJJ;IAKA,MAAMC,aAAa,GAAGT,aAAa,CAACM,MAAd,GACjB,OAAMH,gBAAA,CAAMI,IAAN,CAAW,gDAAX,CAA6D,KAAIP,aAAa,CAACQ,IAAd,CAAmB,IAAnB,CAAyB,EAD/E,GAElB,EAFJ;IAGA,OAAQ,GAAEN,KAAM,KAAIG,aAAc,GAAEI,aAAc,EAAlD;EACD;;AA9B4C"}
1
+ {"version":3,"names":["ScopeRenameCmd","constructor","renaming","name","description","report","oldName","newName","refactor","scopeRenamedComponentIds","refactoredIds","renameScope","title","chalk","green","renamedIdsStr","length","bold","map","c","changeScope","join","refactoredStr"],"sources":["scope-rename.cmd.ts"],"sourcesContent":["import { Command, CommandOptions } from '@teambit/cli';\nimport chalk from 'chalk';\nimport { RenamingMain } from './renaming.main.runtime';\n\nexport class ScopeRenameCmd implements Command {\n name = 'rename <current-scope-name> <new-scope-name>';\n description = \"Renames the scope name for all components with the specified 'current scope name'\";\n arguments = [\n { name: 'current-scope-name', description: 'the scope name to be replaced by another scope name' },\n { name: 'new-scope-name', description: 'a new scope name to replace the current scope name' },\n ];\n options = [\n [\n 'r',\n 'refactor',\n 'update the import statements in all dependent components to the new package name (that contains the new scope name)',\n ],\n ] as CommandOptions;\n group = 'development';\n\n constructor(private renaming: RenamingMain) {}\n\n async report([oldName, newName]: [string, string], { refactor }: { refactor?: boolean }) {\n const { scopeRenamedComponentIds, refactoredIds } = await this.renaming.renameScope(oldName, newName, { refactor });\n const title = chalk.green(`successfully replaced \"${oldName}\" scope with \"${newName}\"`);\n const renamedIdsStr = scopeRenamedComponentIds.length\n ? `\\n${chalk.bold(\n 'the following components were affected by this scope-name change:'\n )}\\n${scopeRenamedComponentIds.map((c) => c.changeScope(newName)).join('\\n')}`\n : '';\n const refactoredStr = refactoredIds.length\n ? `\\n\\n${chalk.bold('the following components have been refactored:')}\\n${refactoredIds.join('\\n')}`\n : '';\n return `${title}\\n${renamedIdsStr}${refact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EAFJ;IAGA,OAAQ,GAAET,KAAM,KAAIG,aAAc,GAAEO,aAAc,EAAlD;EACD;;AA9B4C"}
package/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@teambit/renaming",
3
- "version": "0.0.232",
3
+ "version": "0.0.235",
4
4
  "homepage": "https://bit.dev/teambit/component/renaming",
5
5
  "main": "dist/index.js",
6
6
  "componentId": {
7
7
  "scope": "teambit.component",
8
8
  "name": "renaming",
9
- "version": "0.0.232"
9
+ "version": "0.0.235"
10
10
  },
11
11
  "dependencies": {
12
12
  "chalk": "2.4.2",
@@ -14,14 +14,14 @@
14
14
  "@babel/runtime": "7.12.18",
15
15
  "core-js": "^3.0.0",
16
16
  "@teambit/harmony": "0.3.3",
17
- "@teambit/cli": "0.0.555",
18
- "@teambit/component": "0.0.828",
19
- "@teambit/graphql": "0.0.828",
17
+ "@teambit/cli": "0.0.556",
18
+ "@teambit/component": "0.0.831",
19
+ "@teambit/graphql": "0.0.831",
20
20
  "@teambit/bit-error": "0.0.394",
21
- "@teambit/deprecation": "0.0.828",
22
- "@teambit/new-component-helper": "0.0.232",
23
- "@teambit/refactoring": "0.0.125",
24
- "@teambit/workspace": "0.0.828"
21
+ "@teambit/deprecation": "0.0.831",
22
+ "@teambit/new-component-helper": "0.0.235",
23
+ "@teambit/refactoring": "0.0.128",
24
+ "@teambit/workspace": "0.0.831"
25
25
  },
26
26
  "devDependencies": {
27
27
  "@types/react": "^17.0.8",
@@ -32,7 +32,7 @@
32
32
  "@types/node": "12.20.4"
33
33
  },
34
34
  "peerDependencies": {
35
- "@teambit/legacy": "1.0.338",
35
+ "@teambit/legacy": "1.0.339",
36
36
  "react-dom": "^16.8.0 || ^17.0.0",
37
37
  "react": "^16.8.0 || ^17.0.0"
38
38
  },
@@ -1,5 +1,5 @@
1
- import * as compositions_0 from '/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.component_renaming@0.0.232/dist/renaming.composition.js';
2
- import * as overview_0 from '/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.component_renaming@0.0.232/dist/renaming.docs.mdx';
1
+ import * as compositions_0 from '/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.component_renaming@0.0.235/dist/renaming.composition.js';
2
+ import * as overview_0 from '/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.component_renaming@0.0.235/dist/renaming.docs.mdx';
3
3
 
4
4
  export const compositions = [compositions_0];
5
5
  export const overview = [overview_0];